how do you make a unit drive backwards?

how do you make a unit drive backwards?

Discuss game development here, from a distinct game project to an accessible third-party mutator, down to the interaction and design of individual units if you like.

Moderator: Moderators

Post Reply
User avatar
smartie
NOTA Developer
Posts: 146
Joined: 23 Jun 2005, 19:29

how do you make a unit drive backwards?

Post by smartie »

from way back in version 0.80.1.0

0.80.0.0:
Engine / Simulation:
- units can now move backwards

native forwards/backwards movement has been in spring for a while, but I can't find anything explaining how to use it. Anyone know how to use this?
User avatar
FLOZi
MC: Legacy & Spring 1944 Developer
Posts: 6240
Joined: 29 Apr 2005, 01:14

Re: how do you make a unit drive backwards?

Post by FLOZi »

Code: Select all

	speed  = udTable.GetFloat("maxVelocity",  0.0f) * GAME_SPEED;
	rSpeed = udTable.GetFloat("maxReverseVelocity", 0.0f) * GAME_SPEED;
From UnitDef.cpp :wink:
User avatar
smartie
NOTA Developer
Posts: 146
Joined: 23 Jun 2005, 19:29

Re: how do you make a unit drive backwards?

Post by smartie »

thanks a million :)
User avatar
Forboding Angel
Evolution RTS Developer
Posts: 14673
Joined: 17 Nov 2005, 02:43

Re: how do you make a unit drive backwards?

Post by Forboding Angel »

Don't set it too high, otherwise the units will drive backwards in somewhat awkward situations.
Post Reply

Return to “Game Development”