Hi! Welcome to the forum for Platinum Arts Sandbox Free 3D Game Maker. I currently have the forums locked as I am attempting to properly update them.

In the meantime please join the new Discord Server!

If you have any questions please e-mail me through the Platinum Arts website.

creating a delay before going to a new level

Having issues not related to a specific Sandbox game mode? Get help here!
Please also read the rules for support when posting support requests.
Failure to comply with the forum rules may result in your topic being locked without resolution.
Locked
lzilberm
Member
Member
Posts: 31
Joined: January 19th, 2012, 12:54 pm
Name: lee
IRC Username: zilber

creating a delay before going to a new level

Post by lzilberm »

Hey everyone!

I was wondering if someone may be able to help with an issue I've been having. I've created a game with different levels, and getting to a certain point within the map takes you to a new level. However, I need the game to pause for two seconds before actually going to the next level. If anyone knows how to do this...it would be awesome! Thanks everyone!

~~lzilberm
arcones
Support Team
Support Team
Posts: 2734
Joined: January 13th, 2010, 12:42 pm
Name: Timothy
IRC Username: I use Steam
Location: Looking over your shoulder...
Contact:

Re: creating a delay before going to a new level

Post by arcones »

The FPS command is:

Code: Select all

sleep #
Place that in your code with the proper number and you should be good to go.

If it's RPG, I'm not sure what the command is.
Image
Want a user bar like this one? PM Leo!
lzilberm
Member
Member
Posts: 31
Joined: January 19th, 2012, 12:54 pm
Name: lee
IRC Username: zilber

Re: creating a delay before going to a new level

Post by lzilberm »

Thanks arcones!
When you say "proper number," what does that number refer to? The number of seconds?
~~lzilberm
arcones
Support Team
Support Team
Posts: 2734
Joined: January 13th, 2010, 12:42 pm
Name: Timothy
IRC Username: I use Steam
Location: Looking over your shoulder...
Contact:

Re: creating a delay before going to a new level

Post by arcones »

Yes, although it's not seconds per say. If you did:

Code: Select all

sleep 5000
That might do the trick (it might be in milliseconds, I don't remember).
Image
Want a user bar like this one? PM Leo!
lzilberm
Member
Member
Posts: 31
Joined: January 19th, 2012, 12:54 pm
Name: lee
IRC Username: zilber

Re: creating a delay before going to a new level

Post by lzilberm »

Thanks a ton!! :-D
User avatar
kddekadenz
Member
Member
Posts: 423
Joined: July 17th, 2011, 11:02 am
Name: kdd
Contact:

Re: creating a delay before going to a new level

Post by kddekadenz »

That might do the trick (it might be in milliseconds, I don't remember).
Yes, it is in miliseconds.
If it's RPG, I'm not sure what the command is.
It's the same.
Kelgar is an advanced RPG beeing developed in Sandbox
lzilberm
Member
Member
Posts: 31
Joined: January 19th, 2012, 12:54 pm
Name: lee
IRC Username: zilber

Re: creating a delay before going to a new level

Post by lzilberm »

Hey everyone...I still haven't gotten this to work...if anyone has any knowledge about this...your input is much appreciated!
:-D
chocolatepie33
Support Team
Support Team
Posts: 2458
Joined: April 27th, 2010, 5:31 pm
IRC Username: CP

Re: creating a delay before going to a new level

Post by chocolatepie33 »

to add onto arc's code:

Code: Select all

level_trigger_# = [
sleep 5000 ; sp {mapname} 
]
Should be something like that. I think.
Julius wrote:Contribute to http://www.opengameart.org NOW!
Save the wiki!
User avatar
Leo_V117
Support Team
Support Team
Posts: 1640
Joined: February 16th, 2010, 8:00 pm
Name: Leo
IRC Username: Leo_V117
Location: That one place...
Contact:

Re: creating a delay before going to a new level

Post by Leo_V117 »

To fix that code:

Code: Select all

level_trigger_# = [
    sleep 5000 [
        sp {mapname}
    ]
]
chocolatepie33
Support Team
Support Team
Posts: 2458
Joined: April 27th, 2010, 5:31 pm
IRC Username: CP

Re: creating a delay before going to a new level

Post by chocolatepie33 »

is that how the sleep command works? It executes something once the wait is over? didn't know that.
Julius wrote:Contribute to http://www.opengameart.org NOW!
Save the wiki!
Locked