was reading unitdef.cpp.

was reading unitdef.cpp.

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
smoth
Posts: 22309
Joined: 13 Jan 2005, 00:46

was reading unitdef.cpp.

Post by smoth »

Some interesting stuff:

Code: Select all

canSelfRepair = udTable.GetBool("canSelfRepair", false);
decloakOnFire    = udTable.GetBool("decloakOnFire",    true);

kamikazeDist = udTable.GetFloat("kamikazeDistance", -25.0f) + 25.0f; //we count 3d distance while ta count 2d distance so increase slightly
kamikazeUseLOS = udTable.GetBool("kamikazeUseLOS", false);

bankingAllowed = udTable.GetBool("bankingAllowed", true);

verticalSpeed = udTable.GetFloat("verticalSpeed", 3.0f); // speed of takeoff and landing, at least for gunships

turnInPlaceDistance = udTable.GetFloat("turnInPlaceDistance", 350.f);
turnInPlaceSpeedLimit = ((turnRate / SPRING_CIRCLE_DIVS) * ((PI + PI) * SQUARE_SIZE)) * (speed / GAME_SPEED);
turnInPlaceSpeedLimit = udTable.GetFloat("turnInPlaceSpeedLimit", std::min(speed, turnInPlaceSpeedLimit));

fallSpeed         = udTable.GetFloat("fallSpeed",    0.2);
unitFallSpeed     = udTable.GetFloat("unitFallSpeed",  0);

transportMass     = udTable.GetFloat("transportMass",    100000.0f);
minTransportMass  = udTable.GetFloat("minTransportMass", 0.0f);
^so there is a way to delimit min size!

flareSalvoSize  = udTable.GetInt("flareSalvoSize",  4);
flareSalvoDelay = udTable.GetInt("flareSalvoDelay", 0) * GAME_SPEED;
^salvos? wtf?

usePieceCollisionVolumes = udTable.GetBool("usePieceCollisionVolumes", false);
^piece collistion?
User avatar
Pxtl
Posts: 6112
Joined: 23 Oct 2004, 01:43

Re: was reading unitdef.cpp.

Post by Pxtl »

I assume the ^ things are yours.

Does anybody even use Spring flares?
User avatar
smoth
Posts: 22309
Joined: 13 Jan 2005, 00:46

Re: was reading unitdef.cpp.

Post by smoth »

don't know man. don't remember seeing them.
User avatar
SinbadEV
Posts: 6475
Joined: 02 May 2005, 03:56

Re: was reading unitdef.cpp.

Post by SinbadEV »

doesn't the XTA raven use salvos... maybe check it and see if it uses salvo flares too?
User avatar
bobthedinosaur
Blood & Steel Developer
Posts: 2702
Joined: 25 Aug 2004, 13:31

Re: was reading unitdef.cpp.

Post by bobthedinosaur »

how does a salvo work compared to a Projectiles or burst?
User avatar
smoth
Posts: 22309
Joined: 13 Jan 2005, 00:46

Re: was reading unitdef.cpp.

Post by smoth »

don't know as far as I know it is related to flares but I don't see a salvo count.

I could have looked that up but I am trying to understand the aircraft code.
User avatar
knorke
Posts: 7971
Joined: 22 Feb 2006, 01:02

Re: was reading unitdef.cpp.

Post by knorke »

random thread is random...
can you post what you want to explain/want explained?
most of those are in wiki already..
ie piece collisions do work, Spring.GetUnitLastAttackedPiece to get last hit piece.
SinbadEV wrote:doesn't the XTA raven use salvos... maybe check it and see if it uses salvo flares too?
err i think flares are those chaff flares airplanes can throw to fool missiles. it has nothing to do with weapons.
User avatar
FLOZi
MC: Legacy & Spring 1944 Developer
Posts: 6242
Joined: 29 Apr 2005, 01:14

Re: was reading unitdef.cpp.

Post by FLOZi »

For Salvo read Burst.

wrt piece cols:

http://spring1944.svn.sourceforge.net/v ... threv=3333
User avatar
Neddie
Community Lead
Posts: 9406
Joined: 10 Apr 2006, 05:05

Re: was reading unitdef.cpp.

Post by Neddie »

I haven't seen a flare in use for a long time, though I liked them in AA or XTA. Can't remember which. Five years ago?
User avatar
Pxtl
Posts: 6112
Joined: 23 Oct 2004, 01:43

Re: was reading unitdef.cpp.

Post by Pxtl »

Neddie wrote:I haven't seen a flare in use for a long time, though I liked them in AA or XTA. Can't remember which. Five years ago?
Iirc only the versions of AA that introduced flares actually had them visible - after that some bug or other made them invisible, but still functional. Iirc, the scout, the radar plane, and the stealth fighters all had flares, although the stealth fighter's flares were so weak as to be practically useless.
User avatar
Karl
Panzerstahl Developer
Posts: 746
Joined: 01 Apr 2010, 21:05

Re: was reading unitdef.cpp.

Post by Karl »

War To Oblivion uses flare too on the B-52 bombers
i dont know how it looks on other mod
Post Reply

Return to “Game Development”