T
TheRBZ
Guest
I'd like to find out how to check if x,y is occupied WITHOUT using collision masks due to my implementation of the z axis. This is why position_meeting will not work. Any ideas?
is what I've tried but the function uses collision masks so a tree in front of it blocks it from placing
It could be easier to check if a grid square is occupied but then I'd need to work out a system for that instead of using x - x mod 32.
and a gif to show what I'm on about https://gyazo.com/a9fa02d6a440703f13222eb536639087
Thanks
Code:
if !(position_meeting(mouse_x - mouse_x mod 32,mouse_y - mouse_y mod 32,obj_tree)){
tree_create(mouse_x,mouse_y,1,irandom(3)+1);
global.wood -= 10;
}
It could be easier to check if a grid square is occupied but then I'd need to work out a system for that instead of using x - x mod 32.
and a gif to show what I'm on about https://gyazo.com/a9fa02d6a440703f13222eb536639087
Thanks
Last edited by a moderator: