Advertisement
mrc333777

Untitled

Oct 22nd, 2019
134
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.72 KB | None | 0 0
  1. function Timer()
  2. {
  3. local Pawn P;
  4. local Inventory Inv;
  5. local UnrealIPlayer UP;
  6. local int AddAmmo, AddHealth;
  7. local vector TestBob;
  8. // Look = vector(Pawn(Owner).ViewRotation);
  9. TestBob = vect(0,0,0);
  10. // local ScriptedPawn SP;
  11.  
  12. // foreach AllActors(class'ScriptedPawn', SP)
  13. // {
  14. // if(SP !=none)
  15. // if(SP.Health > 100000)
  16. // SP.Health = 100000;
  17. // }
  18. //Maprotator
  19. foreach AllActors (Class'UnrealIPlayer',UP)
  20. {
  21. if (UP != None)
  22. {
  23. if (UP.bFire!=0 || UP.bAltFire!=0 || UP.bDuck!=0 || UP.bPressedJump!=False || UP.Acceleration!=TestBob) <<<<<<<----------- Not working with jump with mouse looking to reset the mapclock, but the fire and duck works
  24. MapClock = 0;
  25. }
  26. }
  27. MapClock++;
  28. if (MapClock > 3600)
  29. mapendcode();
  30. //End Maprotator
  31.  
  32. for (P=Level.PawnList; P!=None; P=P.NextPawn)
  33. if (P.IsA('PlayerPawn'))
  34. {
  35. if (P.Health > 1)
  36. {
  37. for(Inv=P.Inventory; Inv!=None; Inv=Inv.Inventory)
  38. if ( Weapon(Inv) != None )
  39. {
  40. Weapon(Inv).bCanThrow = True;
  41.  
  42. if ( Weapon(Inv).AmmoType != None )
  43. {
  44. if (P.IsInState('FeigningDeath'))
  45. AddAmmo = 10;
  46. else
  47. AddAmmo = 1;
  48. Weapon(Inv).AmmoType.AmmoAmount = Min(Weapon(Inv).AmmoType.AmmoAmount+AddAmmo,999);
  49. }
  50. }
  51.  
  52. if (P.Health < 999)
  53. {
  54. if (P.IsInState('FeigningDeath'))
  55. AddHealth = 10;
  56. else
  57. AddHealth = 1;
  58. P.Health = Min(P.Health+AddHealth,999);
  59. }
  60.  
  61. if (P.bBlockPlayers == true)
  62. P.bBlockPlayers = false;
  63.  
  64. }
  65. }
  66. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement