home *** CD-ROM | disk | FTP | other *** search
/ Game Level Design / GLDesign.bin / Software / UnrealEngine2Runtime / UE2Runtime-22262001_Demo.exe / Gameplay / Classes / ACTION_IfRandomPct.uc < prev    next >
Text File  |  2003-12-11  |  301b  |  19 lines

  1. class ACTION_IfRandomPct extends ScriptedAction;
  2.  
  3. var(Action) float Probability;
  4.  
  5. function ProceedToNextAction(ScriptedController C)
  6. {
  7.     C.ActionNum += 1;
  8.     if ( FRand() > Probability )
  9.         ProceedToSectionEnd(C);
  10. }
  11.  
  12. function bool StartsSection()
  13. {
  14.     return true;
  15. }
  16.  
  17. defaultproperties
  18. {
  19. }