Before proceeding, please use the forum search feature at the top of the page to check if your question has already been answered.
How do I…
I’ve got a game where these block objects need to check up, right, left and down to see 1) if there is a block adjacent to them, 2) if there is a block there what type of block is there. I’m using raycasting from each block object instance on the scene, but I’m having some trouble getting it to work.
Right now, its outputting “empty” or “” in the debug menu in the object array which stores any given block’s knowledge of what is in the 4 orthogonal squares around it. It’s not setting the right array children to “empty” and it also isn’t setting childs to the ObjectName() of the block that is there.
I’m not totally sure what’s going wrong, but its probably something with object picking cause it usually is with Gdevelop lol.
[Note: I’m using an ID system to help pick objects, each object has a unique ID number]
That doesn’t explain a lot, sorry. it’s hard to explain.
Help would be much appreciated!
Related screenshots
The red is the blocks (not very good at art)
Right now the top block is outputting:
And the bottom block is outputting:
Let me know if you have any questions.



