Ignores statement: Difference between revisions
From Unreal Wiki, The Unreal Engine Documentation Site
mNo edit summary |
m better formatting |
||
Line 2: | Line 2: | ||
== Concept == | == Concept == | ||
Ignores statement allows you to specify functions and events that will not be executed when the actor is in defined state.<br> | Ignores statement allows you to specify functions and events that will not be executed when the actor is in defined state.<br> | ||
For example, if you create state Firing and put Fire and AltFire in ignores, Fire and AltFire functions wont be executed. | For example, if you create state Firing and put Fire and AltFire in ignores, Fire and AltFire functions wont be executed.<br> | ||
Note that functions declared as 'final' can't be ignored. | Note that functions declared as 'final' can't be ignored. | ||
== Practice == | == Practice == | ||
<uscript>state Firing | <uscript>state Firing |
Revision as of 09:53, 6 September 2008
This article is a stub. You can help Unreal Wiki by expanding it. |
Concept
Ignores statement allows you to specify functions and events that will not be executed when the actor is in defined state.
For example, if you create state Firing and put Fire and AltFire in ignores, Fire and AltFire functions wont be executed.
Note that functions declared as 'final' can't be ignored.
Practice
<uscript>state Firing { ignores Fire, AltFire; //So player cant call Fire and AltFire when firing a weapon, meanie not refire and cheat Begin: DoTheFireStuff(); //Trace or spawn projectile Sleep(1.0); //Some refire rate, purely demonstrational, real weapons use FinishAnim() instead GotoState('Idle'); //In different state we can fire again }</uscript>