Implemented kill_and_so_forth via DEL+SHIFT+B for easier debugging
This commit is contained in:
parent
4d688df531
commit
ef4e9e1e17
|
@ -1,5 +1,9 @@
|
||||||
D1X-Rebirth Changelog
|
D1X-Rebirth Changelog
|
||||||
|
|
||||||
|
20100625
|
||||||
|
--------
|
||||||
|
main/gamecntl.c: Implemented kill_and_so_forth via DEL+SHIFT+B for easier debugging
|
||||||
|
|
||||||
20100624
|
20100624
|
||||||
--------
|
--------
|
||||||
arch/ogl/gr.c, arch/sdl/gr.c, include/gr.h, main/menu.c: Added function to list valid resolutions and build resolutions menu dynamically with the resulting list
|
arch/ogl/gr.c, arch/sdl/gr.c, include/gr.h, main/menu.c: Added function to list valid resolutions and build resolutions menu dynamically with the resulting list
|
||||||
|
|
|
@ -696,6 +696,47 @@ int HandleGameKey(int key)
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// --------------------------------------------------------------------------
|
||||||
|
// Detonate reactor.
|
||||||
|
// Award player all powerups in mine.
|
||||||
|
// Place player just outside exit.
|
||||||
|
// Kill all bots in mine.
|
||||||
|
// Yippee!!
|
||||||
|
void kill_and_so_forth(void)
|
||||||
|
{
|
||||||
|
int i, j;
|
||||||
|
|
||||||
|
HUD_init_message("Killing, awarding, etc.!");
|
||||||
|
|
||||||
|
for (i=0; i<=Highest_object_index; i++) {
|
||||||
|
switch (Objects[i].type) {
|
||||||
|
case OBJ_ROBOT:
|
||||||
|
Objects[i].flags |= OF_EXPLODING|OF_SHOULD_BE_DEAD;
|
||||||
|
break;
|
||||||
|
case OBJ_POWERUP:
|
||||||
|
do_powerup(&Objects[i]);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
do_controlcen_destroyed_stuff(NULL);
|
||||||
|
|
||||||
|
for (i=0; i<Num_triggers; i++) {
|
||||||
|
if (Triggers[i].flags == TRIGGER_EXIT) {
|
||||||
|
for (j=0; j<Num_walls; j++) {
|
||||||
|
if (Walls[j].trigger == i) {
|
||||||
|
compute_segment_center(&ConsoleObject->pos, &Segments[Walls[j].segnum]);
|
||||||
|
obj_relink(ConsoleObject-Objects,Walls[j].segnum);
|
||||||
|
goto kasf_done;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
kasf_done: ;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
#ifndef RELEASE
|
#ifndef RELEASE
|
||||||
int HandleTestKey(int key)
|
int HandleTestKey(int key)
|
||||||
{
|
{
|
||||||
|
@ -867,7 +908,12 @@ int HandleTestKey(int key)
|
||||||
case KEY_DEBUGGED+KEY_ALTED+KEY_F5:
|
case KEY_DEBUGGED+KEY_ALTED+KEY_F5:
|
||||||
GameTime = i2f(0x7fff - 840); //will overflow in 14 minutes
|
GameTime = i2f(0x7fff - 840); //will overflow in 14 minutes
|
||||||
break;
|
break;
|
||||||
|
case KEY_DEBUGGED+KEY_SHIFTED+KEY_B:
|
||||||
|
if (Player_is_dead)
|
||||||
|
return 0;
|
||||||
|
|
||||||
|
kill_and_so_forth();
|
||||||
|
break;
|
||||||
case KEY_DEBUGGED+KEY_G:
|
case KEY_DEBUGGED+KEY_G:
|
||||||
GameTime = i2f(0x7fff - 600) - (F1_0*10);
|
GameTime = i2f(0x7fff - 600) - (F1_0*10);
|
||||||
HUD_init_message("GameTime %i - Reset in 10 seconds!", GameTime);
|
HUD_init_message("GameTime %i - Reset in 10 seconds!", GameTime);
|
||||||
|
|
Loading…
Reference in a new issue