Turn at 45 degree angle only?

I want to make a vehicle to turn right or left but anly at a 45 degree angle, I did an IPO but cant get it to work, it turns fine the first time, but when i turn again it resets in its original direction, HUH!

The NDN

you need to use python bucko :slight_smile:
or

make property an integer for smooth moves
make left and right keys change the integer + or -
make ipo property

doogs

You don’t need Python! I think that you have done the same mistake as I did once. Try this for example: To make vehicle turns turn left and right make an ipo starts at frame 1 and stops at frame 5 the animation turns the wheels to the left. Now go to frame 10 and make the wheels face forward again. Then go to frame 15 and do the opposite of what you did on frame 5.

Now when you use the ipo in the realtime buttons make sure that the button that reads play say’s flipper.

I know this maybe confusing but I hope I helped. Ask if you want to know anything!

ndnchief: do you really have to use an IPO to make it turn??? Cos it would be very simple using a movement actuator. Assuming your vehicle’s z axis faces upwards, all you would have to do is set the dRot value for the z axis to 45 to turn one way, and -45 to turn the other.

Keith. 8)

Sorry took so long to reply, Thanks for all your replies, Im going to try gorgan-almi 's suggestion, as I have used Trojans but cant seem to get the results I want. Anyway Thanks all, will post a file, if it works, The first chance I get I will give it a try…

NDNChief, "My computer time has been almost null lately!

i got an answer with no python
similar to the ipo but “works better”
i made a soccer game where i needed to do this

get ur main character always tracking(2D) to an empty above the characters head.

vertex parent the empty to the character. create ipos for the empty for the 8 directions of motion, then create a property animation thing
when keyboard left is hit… the ipo prop. will become like 1, or the left position

you have to vertex parent the empty to the charcter
i can send u my soccer game if u like… incomplete

hmm a soccer game, did you use much python in that i reckon i could do one the only thing i need to know is how do you pass the ball and make it stick to the player you passed to?

You could probably do all that without python.

Make properties on characters if they have the ball or not.
If they have the ball, replace their mesh with a mesh that has the ball.
When they pass, set the prop to not have the ball, and use an add object actuator to add the ball.
Make the ball track to the player you passed to (this MIGHT need python, but COULD be done with logic bricks) and go that direction.