endlessm / godot-block-coding

Block-based visual programming plugin for Godot
https://godotengine.org/asset-library/asset/3095
MIT License
279 stars 20 forks source link

Add 4 random number generation blocks #194

Closed jfcharron closed 2 months ago

jfcharron commented 2 months ago

Add 4 random number generation blocks. One for each of these godot's functions:

  1. randi
  2. randi_range(from,to)
  3. randf
  4. randf_range(from,to)
jfcharron commented 2 months ago

The Allow edits by maintainers checkbox is checked so I suppose you should be able to merge.

manuq commented 2 months ago

@jfcharron merged! I tested placing a sprite in a random vertical position and it worked like a charm: Captura desde 2024-08-15 09-07-18

I have converted the blocks to the new definition format, which uses resources. In case you want to contribute new blocks, this is now the way to do it. It is nicer because the definitions can be edited in the editor directly: Captura desde 2024-08-15 09-25-07

Thanks!