Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
O
openjazz
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
PocketInsanity
openjazz
Commits
131adf2e
Commit
131adf2e
authored
Aug 04, 2010
by
alistert
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Applied Zeartul's latest Dingoo patch.
parent
9d62e0a7
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
27 additions
and
21 deletions
+27
-21
controls.cpp
src/io/controls.cpp
+22
-20
network.h
src/io/network.h
+5
-1
No files found.
src/io/controls.cpp
View file @
131adf2e
...
@@ -37,19 +37,21 @@ Controls::Controls () {
...
@@ -37,19 +37,21 @@ Controls::Controls () {
int
count
;
int
count
;
keys
[
C_UP
].
key
=
SDLK_UP
;
keys
[
C_UP
].
key
=
SDLK_UP
;
keys
[
C_DOWN
].
key
=
SDLK_DOWN
;
keys
[
C_DOWN
].
key
=
SDLK_DOWN
;
keys
[
C_LEFT
].
key
=
SDLK_LEFT
;
keys
[
C_LEFT
].
key
=
SDLK_LEFT
;
keys
[
C_RIGHT
].
key
=
SDLK_RIGHT
;
keys
[
C_RIGHT
].
key
=
SDLK_RIGHT
;
#if defined(DINGOO)
#if defined(DINGOO)
keys
[
C_JUMP
].
key
=
SDLK_LCTRL
;
keys
[
C_JUMP
].
key
=
SDLK_LCTRL
;
keys
[
C_FIRE
].
key
=
SDLK_LALT
;
keys
[
C_FIRE
].
key
=
SDLK_LALT
;
keys
[
C_CHANGE
].
key
=
SDLK_LSHIFT
;
keys
[
C_CHANGE
].
key
=
SDLK_LSHIFT
;
keys
[
C_ENTER
].
key
=
SDLK_RETURN
;
keys
[
C_ENTER
].
key
=
SDLK_LCTRL
;
keys
[
C_ESCAPE
].
key
=
SDLK_ESCAPE
;
keys
[
C_ESCAPE
].
key
=
SDLK_ESCAPE
;
keys
[
C_STATS
].
key
=
SDLK_BACKSPACE
;
keys
[
C_STATS
].
key
=
SDLK_TAB
;
keys
[
C_PAUSE
].
key
=
SDLK_TAB
;
keys
[
C_PAUSE
].
key
=
SDLK_RETURN
;
#else
keys
[
C_YES
].
key
=
SDLK_LCTRL
;
keys
[
C_NO
].
key
=
SDLK_LALT
;
#else
#ifdef WIN32
#ifdef WIN32
keys
[
C_JUMP
].
key
=
SDLK_RALT
;
keys
[
C_JUMP
].
key
=
SDLK_RALT
;
keys
[
C_FIRE
].
key
=
SDLK_SPACE
;
keys
[
C_FIRE
].
key
=
SDLK_SPACE
;
...
@@ -64,10 +66,10 @@ Controls::Controls () {
...
@@ -64,10 +66,10 @@ Controls::Controls () {
keys
[
C_PAUSE
].
key
=
SDLK_p
;
keys
[
C_PAUSE
].
key
=
SDLK_p
;
keys
[
C_YES
].
key
=
SDLK_y
;
keys
[
C_YES
].
key
=
SDLK_y
;
keys
[
C_NO
].
key
=
SDLK_n
;
keys
[
C_NO
].
key
=
SDLK_n
;
#endif
#endif
keys
[
C_SWIM
].
key
=
keys
[
C_JUMP
].
key
;
keys
[
C_SWIM
].
key
=
keys
[
C_JUMP
].
key
;
#if defined(WIZ) || defined(GP2X)
#if defined(WIZ) || defined(GP2X)
buttons
[
C_UP
].
button
=
GP2X_BUTTON_UP
;
buttons
[
C_UP
].
button
=
GP2X_BUTTON_UP
;
buttons
[
C_DOWN
].
button
=
GP2X_BUTTON_DOWN
;
buttons
[
C_DOWN
].
button
=
GP2X_BUTTON_DOWN
;
...
@@ -96,7 +98,7 @@ Controls::Controls () {
...
@@ -96,7 +98,7 @@ Controls::Controls () {
buttons
[
C_NO
].
button
=
-
1
;
buttons
[
C_NO
].
button
=
-
1
;
#endif
#endif
buttons
[
C_SWIM
].
button
=
buttons
[
C_JUMP
].
button
;
buttons
[
C_SWIM
].
button
=
buttons
[
C_JUMP
].
button
;
axes
[
C_UP
].
axis
=
1
;
axes
[
C_UP
].
axis
=
1
;
axes
[
C_UP
].
direction
=
false
;
axes
[
C_UP
].
direction
=
false
;
...
@@ -116,7 +118,7 @@ Controls::Controls () {
...
@@ -116,7 +118,7 @@ Controls::Controls () {
axes
[
C_PAUSE
].
axis
=
-
1
;
axes
[
C_PAUSE
].
axis
=
-
1
;
axes
[
C_YES
].
axis
=
-
1
;
axes
[
C_YES
].
axis
=
-
1
;
axes
[
C_NO
].
axis
=
-
1
;
axes
[
C_NO
].
axis
=
-
1
;
for
(
count
=
0
;
count
<
CONTROLS
;
count
++
)
{
for
(
count
=
0
;
count
<
CONTROLS
;
count
++
)
{
...
@@ -128,7 +130,7 @@ Controls::Controls () {
...
@@ -128,7 +130,7 @@ Controls::Controls () {
controls
[
count
].
state
=
false
;
controls
[
count
].
state
=
false
;
}
}
return
;
return
;
...
...
src/io/network.h
View file @
131adf2e
...
@@ -32,7 +32,11 @@
...
@@ -32,7 +32,11 @@
// Constants
// Constants
// Defaults
// Defaults
#define NET_ADDRESS "192.168.0.1"
#if defined(DINGOO)
#define NET_ADDRESS "10.1.0.1"
#else
#define NET_ADDRESS "192.168.0.1"
#endif
#define NET_PORT 10052
#define NET_PORT 10052
// Timeout interval
// Timeout interval
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment