Drag Objects
I have 2 objects one is graphics and one is working as collide. graphic object is on collide object. And same time when I drag graphics object I also want to drag collide object with that. How to do this? Please help me out.
Comments
goto into the graphics actor and do this for just the touch/move part
To drag an actor it's just
Rule - Actor receives touch - pressed
Constrain Attribute: self.position.X To: game.Touches.Touch 1.X
Constrain Attribute: self.poisition.Y To: game.Touches.Touch 1.Y
Then go into the Collide Object Actor's Instance within the scene and unlock it.
Then put -
Constrain Atrribute: self.position.X To: Current Scene.Layers.Background.GraphicsActor.Position.X
Constrain Atrribute: self.position.Y To: Current Scene.Layers.Background.GraphicsActor.Position.Y
this will have the collide actor move on top of and with the graphics actor.
if you want the collide actor to not be on top of the graphics actor then at distance like
Current Scene.Layers.Background.GraphicsActor.Position.X+50
Current Scene.Layers.Background.GraphicsActor.Position.Y+50
etc...
Tshirtbooth has a video tutorial on this somewhere, searched his youtube page and couldn't find it.
hope that helps.
Storm