#how do i make a loop without cpu overheating
1 messages · Page 1 of 1 (latest)
Then you shouldn't be using a for chip
Just set an int variable to itself + 1, modulo by the number of items in the list at whatever rate you want
If you want to go even faster, use 60hz, and if you want to go even faster and have additional CPU to spend, set the variable via a For chip to make multiple executions go through per tick. Useful if you are making something like custom AI (assuming the AI is very, very simple)
Modulo, the chip
Its the remainder of division
notice the constant repeating lines?
This is y = mod(x,5)
Once X reaches 5, it loops back down to 0
Itself, +1, modulo by number of items in list