Rotate To Angle
_DNA_
Member Posts: 9
Got a brain tester for you.
Objective: Creating e.g. a long tank that moves around the map, but has 2-3 turrets that are not centered to the middle of the tank actor. These turrets rotate separate from the tank.
I have watched the tutorial on youTube about the tank and turret, which is very good. But it works if your turret is centered to the tank actor.
So how would you keep the turrets in their correct place while the tank is turning?
Regarding rotating turrets, I used Rotate to Angle( vectorToAngle(targetX - selfX, targetY - selfY) now this worked on a tutorial (Rotate Spawn from design3) but this didn't work for me. Is the above correct?
I dislike asking for help, but now after 4 days and many many cups of coffee later I need the help.
Thank you all
Regards
DNA
Objective: Creating e.g. a long tank that moves around the map, but has 2-3 turrets that are not centered to the middle of the tank actor. These turrets rotate separate from the tank.
I have watched the tutorial on youTube about the tank and turret, which is very good. But it works if your turret is centered to the tank actor.
So how would you keep the turrets in their correct place while the tank is turning?
Regarding rotating turrets, I used Rotate to Angle( vectorToAngle(targetX - selfX, targetY - selfY) now this worked on a tutorial (Rotate Spawn from design3) but this didn't work for me. Is the above correct?
I dislike asking for help, but now after 4 days and many many cups of coffee later I need the help.
Thank you all
Regards
DNA
Comments
Check this out:
http://forums.gamesalad.com/discussion/62202/linkmachine