+2
Completed

Wait Node

PET 3 years ago updated by Lazlo Bonin (Lead Developer) 2 years ago 7

Hello there,

Would something like this be possible in Bolt?

I'm in a bit of a pickle. I want to execute a piece of code every X seconds and I don't know how to do it. The above example of a node is actually super useful because it has a Start an Update and a Finish so it provides great flexibility but it also has a "Time Left".

Thanks

Bolt Version:
Unity Version:
Platform(s):
Scripting Backend:
.NET Version (API Compatibility Level):

The existing wait node could be expanded , would be useful to have time left as an output and also 2 flows out, like a branch so it could flow one way if the time hadnt elapsed and the other whn it had elapsed if required.

+1

Funny you posted this. I am releasing a pack tomorrow called Unit Tools - Flow Control which has anything to do with control / flow. This is one of them in there, along with a Loop for Until and While. As seen below, perhaps Lazlo will want to do something himself at some point, but this is done with the same API Lazlo uses.

*I'm willing to add Start and Stop. I'll try to cram it in there by the time I put it up. 

+2

Okay, here ya go :) 


I was looking at those lastnight but couldnt get them working, Id downloaded them I think via discord but maybe was an old version. (was from very early on in discord history)

Yes those are old, and they are macros, and probably broken from an old serialization problem with bolt. These will not have that happen and are brand new Native units.  If you refresh your page in 5 seconds, I will have my new Unit Tools up. These are native API, so lighter in weight then the old stuff.

+1

Awesome! That Wait Loop is exactly what I needed!

Completed

Wait For Seconds, Cooldown and Timer should now satisfy that need.