MCPcopy Create free account
hub / github.com/DescentDevelopers/Descent3 / ProcessButtons

Function ProcessButtons

Descent3/GameLoop.cpp:1130–1158  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1128}
1129
1130void ProcessButtons() {
1131 // If dead, any key not handled above will eand the death sequence
1132 // this shouldn't be called in ReadPlayerControls since the player is DEAD!
1133 if (Players[Player_num].flags & PLAYER_FLAGS_DEAD) {
1134 int x, y;
1135 PollControls();
1136 if (Controller->get_joy_raw_values(&x, &y) || Controller->get_mouse_raw_values(&x, &y)) {
1137 // death.
1138 mprintf(0, "here?");
1139
1140 if (Total_time_dead < DEATH_RESPAWN_TIME)
1141 return;
1142
1143 mprintf(0, "Respawning joystick death. Death time=%f\n", Total_time_dead);
1144
1145 if (Game_mode & GM_MULTI)
1146 MultiSendEndPlayerDeath(); // couldn't this be called from withing EndPlayerDeath()?
1147 else
1148 EndPlayerDeath(Player_num);
1149 // Clear keyboard
1150 ResetPersistentHUDMessage();
1151 ddio_KeyFlush();
1152 if (Controller) {
1153 Controller->flush();
1154 }
1155 }
1156 return;
1157 }
1158}
1159
1160#define GBC_FIND_ACTIVE_GOAL_0 3 // Find next primary
1161#define GBC_FIND_SPEW 19 // Find Spew

Callers 1

GameFrameFunction · 0.85

Calls 8

PollControlsFunction · 0.85
MultiSendEndPlayerDeathFunction · 0.85
EndPlayerDeathFunction · 0.85
ddio_KeyFlushFunction · 0.85
get_joy_raw_valuesMethod · 0.45
get_mouse_raw_valuesMethod · 0.45
flushMethod · 0.45

Tested by

no test coverage detected