ProtoFlux:ASync Range Loop Int: Difference between revisions

From Resonite Wiki
Add info, needs clarification
m grammar
Line 20: Line 20:
{{Stub}}<i> Missing clarification </i>
{{Stub}}<i> Missing clarification </i>


Range Loop Int is a ProtoFlux node that allows for firing a bunch of executions like a [[ProtoFlux:ASync For|ASync For Loop]] except that instead of having to go one at a time from 0->count, you can specify a Start ([[Type:Int|int]]) number, End ([[Type:Int|int]]) number, and a StepSize ([[Type:Int|int]]) which all determine the range of numbers that will come out of Current ([[Type:Int|int]]) during execution and the distance between each Current ([[Type:Int|int]]) outputted.
Range Loop Int is a ProtoFlux node that allows for firing a bunch of executions like an [[ProtoFlux:ASync For|ASync For Loop]] except that instead of having to go one at a time from 0->count, you can specify a Start ([[Type:Int|int]]) number, End ([[Type:Int|int]]) number, and a StepSize ([[Type:Int|int]]) which all determine the range of numbers that will come out of Current ([[Type:Int|int]]) during execution and the distance between each Current ([[Type:Int|int]]) outputted.


This node will do a bunch of async tasks in order in an Async context, waiting for each task to be done before moving to the next one. This is useful if you want to do a bunch of [[ProtoFlux:GET String|GET String]] requests but you need to wait for the previous one to be done before doing the next, for a specified number of times. This does not behave the same as using a [[ProtoFlux:Start ASync Task|Start ASync Task]] on every [[ProtoFlux:Range Loop Int|Range Loop Int]] iteration or even before the [[ProtoFlux:Range Loop Int|Range Loop Int]] using a [[ProtoFlux:Start ASync Task|Start ASync Task]].
This node will do a bunch of async tasks in order in an Async context, waiting for each task to be done before moving to the next one. This is useful if you want to do a bunch of [[ProtoFlux:GET String|GET String]] requests but you need to wait for the previous one to be done before doing the next, for a specified number of times. This does not behave the same as using a [[ProtoFlux:Start ASync Task|Start ASync Task]] on every [[ProtoFlux:Range Loop Int|Range Loop Int]] iteration or even before the [[ProtoFlux:Range Loop Int|Range Loop Int]] using a [[ProtoFlux:Start ASync Task|Start ASync Task]].

Revision as of 20:08, 16 February 2024

Async Range Loop
*
LoopStart
Start
LoopIteration
End
LoopEnd
StepSize
Current
Async


This article or section is a Stub. You can help the Resonite Wiki by expanding it.

Missing clarification

Range Loop Int is a ProtoFlux node that allows for firing a bunch of executions like an ASync For Loop except that instead of having to go one at a time from 0->count, you can specify a Start (int) number, End (int) number, and a StepSize (int) which all determine the range of numbers that will come out of Current (int) during execution and the distance between each Current (int) outputted.

This node will do a bunch of async tasks in order in an Async context, waiting for each task to be done before moving to the next one. This is useful if you want to do a bunch of GET String requests but you need to wait for the previous one to be done before doing the next, for a specified number of times. This does not behave the same as using a Start ASync Task on every Range Loop Int iteration or even before the Range Loop Int using a Start ASync Task.

Inputs

* (int)

Start Execution of the ASync Range Loop.

Start (int)

The number to start at when executing.

End (int)

The number to end at when executing.

TODO: Is this inclusive or exclusive?

StepSize (int)

How much to add to Start (int) per execution for the Current (int) output number.

Outputs

LoopStart (SyncResumption)

Fires when the loop starts, regardless of executions of the ASync Range Loop.

LoopIteration (SyncResumption)

Fires every time Current (int) increases by StepSize (int) and (has just or hasn't/hasn't)? hit the End (int) limit. Waits till the previous LoopIteration (SyncResumption) is done or after LoopStart (SyncResumption) is done before firing this one.

TODO: Is this inclusive or exclusive?

LoopEnd (Continuation)

Fires once the loop has finished.

Current (int)

The current number between Start (int) and End (int). has a value during every LoopIteration (SyncResumption).

Examples