Pausing script from processing for a number of frames
#1
I know there's a way to do this... But I can't remember the way to do it.

It was something like 'pause(10)', then it'll continue the script afterward.

That's not it.... already tried that.

Any one know what I'm talking about?
Reply }
#2
Some how the problem either fixed itself or I changed some thing in another script that gave me the desired result accidentally.

But I would still like this, for future reference if ever I need it.
Reply }
#3
The pause function only works in scripts that define it. By default I think only Scene_Battle uses it.
Reply }
#4
Really? Man.... I vaguely remember there being a way to use "Call Script" to pause teh entire game for a set amount time. I originally wanted to slow a filling bar down a little, but that fixed itself [not sure how]. Now I was thinking of using it to make one of my cut scenes more dramatic by "pausing" the event at certain intervals to add to the tension.
Reply }
#5
try this:

Code:
def wait(frames)
  frame = 0
  loop do
    break if frame >= frames
    Graphics.update
    frame +=1
  end
end

then to pause for, say, 10 frames, call wait(10)
Reply }
#6
Thanks... I'll give it a shot.
Reply }
#7
Sleep(duration) works but it will completely stop everything from processing for the specified amount of frames. For example sleep(20) for 20 frames pause
Valdred
Tech Administrator of Save-Point
Reply }
#8
That's actually what I was hoping to do... so it's sleep? Never would have thought that one.
Reply }
#9
Yep

Code:
sleep(20)

Code:
sleep(40)

etc
Valdred
Tech Administrator of Save-Point
Reply }


Possibly Related Threads…
Thread Author Replies Views Last Post
   Script compatibility help Lord Vectra 3 4,549 07-25-2021, 11:42 PM
Last Post: DerVVulfman
   Adding face script on Cogwheel's RTAB Battle Status rekkatsu 15 15,683 08-25-2020, 03:09 AM
Last Post: DerVVulfman
   "Wait" in the script Whisper 13 16,023 04-28-2020, 04:06 PM
Last Post: Whisper
   Skill Cooldown script Fenriswolf 11 16,340 12-10-2019, 11:10 AM
Last Post: Fenriswolf
   Help iwth script (RGSS Player crash) Whisper 3 8,501 06-17-2017, 05:03 PM
Last Post: Whisper
   Help modifying a script Keeroh 7 10,177 06-11-2017, 04:43 PM
Last Post: DerVVulfman
Question  Mog Menu script: help me stop the crazy picture movement during transitions Zachariad 4 9,799 05-31-2017, 05:10 AM
Last Post: Zachariad
   Actor names in Quest Script jreagan406 5 8,603 03-07-2017, 08:06 AM
Last Post: JayRay
   Bizarre issue with Lanzer counter script. Steel Beast 6Beets 2 7,217 10-04-2016, 11:46 AM
Last Post: Steel Beast 6Beets
   Moonpearl script Animated Battlers help!! x(( Starmage 11 15,578 05-21-2016, 05:34 AM
Last Post: Starmage



Users browsing this thread: 2 Guest(s)