Want more features on Pastebin? Sign Up, it's FREE!
Guest

RokkitPawn

By: a guest on Jul 31st, 2013  |  syntax: UnrealScript  |  size: 0.60 KB  |  views: 3  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. class RokkitPawn extends GamePawn
  2.         config(Game);
  3.  
  4. var vector BoostVector;
  5. var bool bKeepBoosting;
  6.  
  7. simulated function PostBeginPlay() {
  8.         super.PostBeginPlay();
  9.         `log("=================== Pawn Function Loaded ===================");
  10. }
  11.  
  12. simulated function BoostPawn( vector HitNormal ) {
  13.         `log("=================== Boost Pawn Entered ===================");
  14.  
  15.         SetPhysics(PHYS_Falling);
  16.  
  17.         Velocity += BoostVector;
  18. }
  19.  
  20. event Tick( float DeltaTime ) {
  21.        
  22.         if (bKeepBoosting == true) {
  23.                 Velocity += BoostVector/2;
  24.         }
  25.  
  26. }
  27.  
  28. defaultproperties
  29. {
  30.         BoostVector=(X=0,Y=0,Z=1000)
  31.         bKeepBoosting=false
  32. }
clone this paste RAW Paste Data