Tales
Member
Hello!
I have a problem with collision between 2 objects.. A ray start from an object A, go to the cursor and if collision (or place_meeting, I tried the 2) with object B, something happen. The simple ray code is
and collision or place meeting in object B is
BUT I dont understand why this happen even the object A dont touch obj B!.. Im about 50 pixel away and its touching object B -.- . Visually sprite dont touch each other, so I guess its a mask problem..
But I verify the mask of both object, no problem.. I tried changing the yscalefor 0.1, its same.. I really dont know why this happen.... if someone have an idea?...
I understand a drawed object take the original mask sprite and if I dont have any sprite and only a drawed sprite, I have no mask from the draw (collision and place meeting do nothing)... I guess I misunderstood something.. but even this dont explain my collision problem..
I have a problem with collision between 2 objects.. A ray start from an object A, go to the cursor and if collision (or place_meeting, I tried the 2) with object B, something happen. The simple ray code is
GML:
draw_sprite_ext(spr_shiptirlazer01,-1,x,y,10,1,point_direction(x,y,obj_cursor.x,obj_cursor.y),-1,1)
GML:
if place_meeting(x,y,obj_tirlazer01)
{life-=0.1
lockhero=1
instance_create(x,y,obj_fumee02)}
But I verify the mask of both object, no problem.. I tried changing the yscalefor 0.1, its same.. I really dont know why this happen.... if someone have an idea?...
I understand a drawed object take the original mask sprite and if I dont have any sprite and only a drawed sprite, I have no mask from the draw (collision and place meeting do nothing)... I guess I misunderstood something.. but even this dont explain my collision problem..
Last edited: