This topic is for asking how things blocks work and keeping track of what Iearned. I want to make better games, and if I understand how the blocks work then
Hm alright, have fun.
I accidentally clicked “Create Topic” while writing by accident.
But anyways, to start, how do the first two blocks work?
For [index] from 0 to 4 allows you loop a set amount of times while having an “index” value to keep track of the current loop. You can use it for enemy generation and such, but here’s a simple example:
The code in this case will splash numbers 0 to 4 on the simulator:
For element [value] of [list] is a block used for looping among a list’s values, with each loop being a different value based on the content of the list, you can use this for AI among multiple sprites. Here is an example similar to the other one:
This code will splash all the values of the list onto the screen, as shown on the GIF:
I hope that explains the blocks well! But one last thing: If you right click on a block then click on the “help” option, you can open up that block’s MD documentation! (However, it is quite broad in some sense.)
The MD documentations:







