Skip to content

Commit

Permalink
super slow mode: 1 minute per second
Browse files Browse the repository at this point in the history
  • Loading branch information
Pithlit committed Jul 18, 2024
1 parent bc9be2a commit 80cad77
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion src/gameGlobalInfo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -719,10 +719,21 @@ static int slowGame(lua_State* L)
return 0;
}
/// void slowGame()
/// slow down the game
/// slow down the game (factor 10)
/// Calling this function will slow the game down. Mainly usefull for a larp setup.
REGISTER_SCRIPT_FUNCTION(slowGame);

static int superSlowGame(lua_State* L)
{
gameGlobalInfo->notifyCampaignServerScenario("slowed");
engine->setGameSpeed(0.1);
return 0;
}
/// void superSlowGame()
/// slow down the game (factor 60)
/// Calling this function will slow the game down. Mainly usefull for a larp setup.
REGISTER_SCRIPT_FUNCTION(superSlowGame);

static int unslowGame(lua_State* L)
{
gameGlobalInfo->setPause(false);
Expand Down

0 comments on commit 80cad77

Please sign in to comment.