summaryrefslogtreecommitdiff
path: root/src/doom
diff options
context:
space:
mode:
Diffstat (limited to 'src/doom')
-rw-r--r--src/doom/d_main.c22
-rw-r--r--src/doom/d_player.h2
-rw-r--r--src/doom/p_floor.c6
-rw-r--r--src/doom/p_inter.c15
-rw-r--r--src/doom/p_map.c2
-rw-r--r--src/doom/p_maputl.c2
-rw-r--r--src/doom/st_stuff.c11
7 files changed, 35 insertions, 25 deletions
diff --git a/src/doom/d_main.c b/src/doom/d_main.c
index 1e9e950e..ca722dc6 100644
--- a/src/doom/d_main.c
+++ b/src/doom/d_main.c
@@ -359,16 +359,16 @@ void D_BindVariables(void)
NET_BindVariables();
#endif
- M_BindVariable("mouse_sensitivity", &mouseSensitivity);
- M_BindVariable("sfx_volume", &sfxVolume);
- M_BindVariable("music_volume", &musicVolume);
- M_BindVariable("show_messages", &showMessages);
- M_BindVariable("screenblocks", &screenblocks);
- M_BindVariable("detaillevel", &detailLevel);
- M_BindVariable("snd_channels", &snd_channels);
- M_BindVariable("vanilla_savegame_limit", &vanilla_savegame_limit);
- M_BindVariable("vanilla_demo_limit", &vanilla_demo_limit);
- M_BindVariable("show_endoom", &show_endoom);
+ M_BindIntVariable("mouse_sensitivity", &mouseSensitivity);
+ M_BindIntVariable("sfx_volume", &sfxVolume);
+ M_BindIntVariable("music_volume", &musicVolume);
+ M_BindIntVariable("show_messages", &showMessages);
+ M_BindIntVariable("screenblocks", &screenblocks);
+ M_BindIntVariable("detaillevel", &detailLevel);
+ M_BindIntVariable("snd_channels", &snd_channels);
+ M_BindIntVariable("vanilla_savegame_limit", &vanilla_savegame_limit);
+ M_BindIntVariable("vanilla_demo_limit", &vanilla_demo_limit);
+ M_BindIntVariable("show_endoom", &show_endoom);
// Multiplayer chat macros
@@ -377,7 +377,7 @@ void D_BindVariables(void)
char buf[12];
M_snprintf(buf, sizeof(buf), "chatmacro%i", i);
- M_BindVariable(buf, &chat_macros[i]);
+ M_BindStringVariable(buf, &chat_macros[i]);
}
}
diff --git a/src/doom/d_player.h b/src/doom/d_player.h
index a72c2f5f..04e47109 100644
--- a/src/doom/d_player.h
+++ b/src/doom/d_player.h
@@ -111,7 +111,7 @@ typedef struct player_s
// Is wp_nochange if not changing.
weapontype_t pendingweapon;
- boolean weaponowned[NUMWEAPONS];
+ int weaponowned[NUMWEAPONS];
int ammo[NUMAMMO];
int maxammo[NUMAMMO];
diff --git a/src/doom/p_floor.c b/src/doom/p_floor.c
index 1384ee6b..c120d616 100644
--- a/src/doom/p_floor.c
+++ b/src/doom/p_floor.c
@@ -493,6 +493,9 @@ EV_BuildStairs
floor->speed = speed;
height = sec->floorheight + stairsize;
floor->floordestheight = height;
+ // Initialize
+ floor->type = lowerFloor;
+ floor->crush = true;
texture = sec->floorpic;
@@ -536,6 +539,9 @@ EV_BuildStairs
floor->sector = sec;
floor->speed = speed;
floor->floordestheight = height;
+ // Initialize
+ floor->type = lowerFloor;
+ floor->crush = true;
ok = 1;
break;
}
diff --git a/src/doom/p_inter.c b/src/doom/p_inter.c
index c9965799..633408fe 100644
--- a/src/doom/p_inter.c
+++ b/src/doom/p_inter.c
@@ -603,8 +603,9 @@ P_TouchSpecialThing
break;
case SPR_MGUN:
- if (!P_GiveWeapon (player, wp_chaingun, special->flags&MF_DROPPED) )
- return;
+ if (!P_GiveWeapon(player, wp_chaingun,
+ (special->flags & MF_DROPPED) != 0))
+ return;
player->message = DEH_String(GOTCHAINGUN);
sound = sfx_wpnup;
break;
@@ -631,15 +632,17 @@ P_TouchSpecialThing
break;
case SPR_SHOT:
- if (!P_GiveWeapon (player, wp_shotgun, special->flags&MF_DROPPED ) )
- return;
+ if (!P_GiveWeapon(player, wp_shotgun,
+ (special->flags & MF_DROPPED) != 0))
+ return;
player->message = DEH_String(GOTSHOTGUN);
sound = sfx_wpnup;
break;
case SPR_SGN2:
- if (!P_GiveWeapon (player, wp_supershotgun, special->flags&MF_DROPPED ) )
- return;
+ if (!P_GiveWeapon(player, wp_supershotgun,
+ (special->flags & MF_DROPPED) != 0))
+ return;
player->message = DEH_String(GOTSHOTGUN2);
sound = sfx_wpnup;
break;
diff --git a/src/doom/p_map.c b/src/doom/p_map.c
index e371869a..9d3086fd 100644
--- a/src/doom/p_map.c
+++ b/src/doom/p_map.c
@@ -357,7 +357,7 @@ boolean PIT_CheckThing (mobj_t* thing)
// check for special pickup
if (thing->flags & MF_SPECIAL)
{
- solid = thing->flags&MF_SOLID;
+ solid = (thing->flags & MF_SOLID) != 0;
if (tmflags&MF_PICKUP)
{
// can remove thing
diff --git a/src/doom/p_maputl.c b/src/doom/p_maputl.c
index 916f2b64..098c2c73 100644
--- a/src/doom/p_maputl.c
+++ b/src/doom/p_maputl.c
@@ -887,7 +887,7 @@ P_PathTraverse
int count;
- earlyout = flags & PT_EARLYOUT;
+ earlyout = (flags & PT_EARLYOUT) != 0;
validcount++;
intercept_p = intercepts;
diff --git a/src/doom/st_stuff.c b/src/doom/st_stuff.c
index 9a25865c..693b6ef2 100644
--- a/src/doom/st_stuff.c
+++ b/src/doom/st_stuff.c
@@ -1261,11 +1261,12 @@ void ST_createWidgets(void)
// weapons owned
for(i=0;i<6;i++)
{
- STlib_initMultIcon(&w_arms[i],
- ST_ARMSX+(i%3)*ST_ARMSXSPACE,
- ST_ARMSY+(i/3)*ST_ARMSYSPACE,
- arms[i], (int *) &plyr->weaponowned[i+1],
- &st_armson);
+ STlib_initMultIcon(&w_arms[i],
+ ST_ARMSX+(i%3)*ST_ARMSXSPACE,
+ ST_ARMSY+(i/3)*ST_ARMSYSPACE,
+ arms[i],
+ &plyr->weaponowned[i+1],
+ &st_armson);
}
// frags sum