Advancing, or speeding up timer question

Heya everyone,

I was just wondering if there was a built in way to advance a current on going timer? for instance:

1.Timer starts, 30 mins counting down
2. Player goes to sleep/stays at an inn.
3. Timer advances by x amount of time.
The Control Timer command doesn't allow you to use variables, so you'd have to do a Script call to set it. In that case, while you could use Control Variables to GET the current time remaining into a variable, I'd just skip it and use a script call to get, modify and restart the timer.

Something like this:

Code:
new_time = $game_timer.sec - 1800$game_timer.start(new_time * Graphics.frame_rate)
or condense it into a single line:
Code:
$game_timer.start(($game_timer.sec - 1800) * Graphics.frame_rate)
If you have the editor that only has a small script call window, do it like this:
Code:
$game_timer.start(($game_timer.sec - 1800) * Graphics.frame_rate)
otherwise it'll break in the wrong place and cause your game to crash.
The Control Timer command doesn't allow you to use variables, so you'd have to do a Script call to set it. In that case, while you could use Control Variables to GET the current time remaining into a variable, I'd just skip it and use a script call to get, modify and restart the timer.

Something like this:

new_time = $game_timer.sec - 1800$game_timer.start(new_time * Graphics.frame_rate)or condense it into a single line:
Code:
$game_timer.start(($game_timer.sec - 1800) * Graphics.frame_rate)
If you have the editor that only has a small script call window, do it like this:
Code:
$game_timer.start(($game_timer.sec - 1800) * Graphics.frame_rate)
otherwise it'll break in the wrong place and cause your game to crash.
I will have to try that, thanks for the info, sorry about not getting back sooner, email never said anyone posted this time.

Original thread: https://forums.rpgmakerweb.com/threads/advancing-or-speeding-up-timer-question.35176/