Hey folks!
Trying out a small app using 2D Physics, but running into an issue, I have 2 sprites on the screen and I'm trying to make Sprite A. repel Sprite B.
IE - The closer Sprite A gets to Sprite B; Sprite B runs away.
Using physics is completely new to me though, I've got Physics On, so the sprites will fall to the bottom of the screen by default and I'm fairly confident that what I need is a force pushing against a sprite based on the position of the Sprite A.
I was thinking something like, I'm just not sure what I would use to calculate X,Y as the opposing force? Thoughts?
SetSpritePhysicsForce (SpriteB GetSpriteXByOffset(SpriteA),GetSpriteYByOffset(SpriteA),X,Y)
StepPhysics(1.0/60.0)
Thanks All
Rob
Robert Janes (Samu Games)
http://www.samugames.com/artifact