Game Development Community

StateAllowImageChange

by Tim Heldna · in Torque Game Engine · 08/18/2006 (10:50 am) · 1 replies

Hi,

stateAllowImageChange
stateWaitForTimeout

RE the weapon state system.

Anyone else noticed that setting the two above values to either true or false has no affect?

If a state has a TimeoutValue specified, shouldn't I be able to use one or a combination of those values listed above to force the image into another state if another state is called?

E.g.
// Play the reload animation, and transition into
   stateName[5]                     = "Reload";
   stateTransitionOnNoAmmo[5]       = "NoAmmo";
   stateTransitionOnTimeout[5]      = "Ready";
   stateTimeoutValue[5]             = 0.8;
   [b]stateAllowImageChange[5]         = true;[/b]
   [b]stateWaitForTimeout[5]           = false;[/b]
   stateSequence[5]                 = "Reload";
   stateEjectShell[5]               = true;

That would cancel playing the reload animation if the fire state was activated (even before the 0.8 TimeoutValue is reached).

Anyone else having the same problem?

- Tim

#1
08/18/2006 (11:49 am)
Another question, perhaps a GG staff member knows the answer to this.

I noticed in shapeImage.cc stateScaleAnimation is set to true and not exposed as an adjustable parameter through script.

Is there a reason for this?

I added it to initPersistFields(), therefore allowing me to alter the value through script and haven't noticed any problems.

- Tim