mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2026-02-17 19:11:30 +00:00
Add goto_skybox command, teleport to skybox viewpoint
This commit is contained in:
parent
79c4074499
commit
ddb0c65455
3 changed files with 19 additions and 0 deletions
|
|
@ -551,6 +551,7 @@ void D_RegisterClientCommands(void)
|
|||
COM_AddDebugCommand("goto", Command_Goto_f);
|
||||
COM_AddDebugCommand("angle", Command_Angle_f);
|
||||
COM_AddDebugCommand("respawnat", Command_RespawnAt_f);
|
||||
COM_AddDebugCommand("goto_skybox", Command_GotoSkybox_f);
|
||||
|
||||
{
|
||||
extern struct CVarList *cvlist_player;
|
||||
|
|
|
|||
|
|
@ -640,6 +640,23 @@ void Command_RespawnAt_f(void)
|
|||
D_Cheat(consoleplayer, CHEAT_RESPAWNAT, atoi(COM_Argv(1)));
|
||||
}
|
||||
|
||||
void Command_GotoSkybox_f(void)
|
||||
{
|
||||
REQUIRE_CHEATS;
|
||||
REQUIRE_INLEVEL;
|
||||
|
||||
mobj_t *skybox = players[consoleplayer].skybox.viewpoint;
|
||||
|
||||
if (P_MobjWasRemoved(skybox))
|
||||
{
|
||||
CONS_Printf("There is no visible skybox for local Player 1.\n");
|
||||
return;
|
||||
}
|
||||
|
||||
D_Cheat(consoleplayer, CHEAT_TELEPORT, skybox->x, skybox->y, skybox->z);
|
||||
D_Cheat(consoleplayer, CHEAT_ANGLE, skybox->angle);
|
||||
}
|
||||
|
||||
//
|
||||
// OBJECTPLACE (and related variables)
|
||||
//
|
||||
|
|
|
|||
|
|
@ -91,6 +91,7 @@ void Command_Grayscale_f(void);
|
|||
void Command_Goto_f(void);
|
||||
void Command_Angle_f(void);
|
||||
void Command_RespawnAt_f(void);
|
||||
void Command_GotoSkybox_f(void);
|
||||
#ifdef _DEBUG
|
||||
void Command_CauseCfail_f(void);
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue