Advertisement
Guest User

Untitled

a guest
Sep 21st, 2017
127
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. class MagmaBloat extends KFPawn_ZedBloat;
  2.  
  3. var MaterialInstanceConstant VisibleMaterial;
  4.  
  5. simulated function PostBeginPlay()
  6. {
  7.     UpdateGameplayMICParams();
  8. }
  9.  
  10. simulated event ReplicatedEvent(name VarName)
  11. {
  12.     UpdateGameplayMICParams();
  13.     super(KFPawn_Monster).ReplicatedEvent(VarName);
  14. }
  15.  
  16. simulated function UpdateGameplayMICParams()
  17. {
  18.     super(KFPawn_Monster).UpdateGameplayMICParams();
  19.     Mesh.SetMaterial(0, VisibleMaterial);
  20. }
  21.  
  22. simulated event Tick( float DeltaTime )
  23. {
  24.     super.Tick(DeltaTime);
  25.    
  26.     if ( WorldInfo.NetMode != NM_DedicatedServer )
  27.     {
  28.         CharacterMICs.Length = 0;
  29.         CharacterMICs[0] = VisibleMaterial;
  30.         Mesh.SetMaterial(0, VisibleMaterial);
  31.     }  
  32. }
  33.  
  34.  
  35. function Puke()
  36. {
  37.     local Pawn P;
  38.     local Vector PukeLocation, PukeDirection;
  39.     local Rotator PukeRotation;
  40.     local vector HitLocation, HitNormal, EndTrace, Momentum;
  41.     local Actor HitActor;
  42.  
  43.     Mesh.GetSocketWorldLocationAndRotation( 'PukeSocket', PukeLocation, PukeRotation );
  44.  
  45.     PukeDirection  = Vector(Rotation);
  46.     PukeDirection.Z = 0.f;
  47.     foreach WorldInfo.AllPawns(class'Pawn', P, PukeLocation, VomitRange)
  48.     {
  49.         if( CanPukeOnTarget(P, PukeLocation, PukeDirection) )
  50.         {
  51.             DealPukeDamage( P, PukeLocation );
  52.         }
  53.     }
  54.  
  55.     // Extra handling for fracture mesh actors, etc
  56.     EndTrace = PukeLocation + PukeDirection*VomitRange;
  57.     HitActor = Trace( HitLocation, HitNormal, EndTrace, PukeLocation, true, vect(10,10,10) );
  58.     if( HitActor != none && HitActor.bCanBeDamaged && Pawn(HitActor) == none )
  59.     {
  60.         Momentum = EndTrace - PukeLocation;
  61.         Momentum.Z = 0.f;
  62.         Momentum = Normal(Momentum);
  63.         HitActor.TakeDamage( VomitDamage, Controller, HitLocation, Momentum, class'KFDT_FirePuke',, self );
  64.     }
  65. }
  66.  
  67. function DealPukeDamage( Pawn Victim, Vector Origin )
  68. {
  69.     local Vector VectToEnemy;
  70.  
  71.     VectToEnemy = Victim.Location - Origin;
  72.     VectToEnemy.Z = 0.f;
  73.     VectToEnemy = Normal( VectToEnemy );
  74.  
  75.     Victim.TakeDamage( GetRallyBoostDamage(VomitDamage), Controller, Victim.Location, VectToEnemy, class'KFDT_FirePuke',, self );
  76. }
  77.  
  78.  
  79. DefaultProperties
  80. {
  81.     Name='Magma Gray Bloat'
  82.  
  83.     VisibleMaterial=MaterialInstanceConstant'ZedPack.Skins.MagmaBloat_M'
  84.  
  85.     LocalizationKey=KFPawn_ZedBloat
  86.     Begin Object Name=KFPawnSkeletalMeshComponent
  87.         // Enabling kinematic for physics interaction while alive.  (see also MinDistFactorForKinematicUpdate)
  88.         bUpdateKinematicBonesFromAnimation=true
  89.         bPerBoneMotionBlur=false
  90.     End Object
  91.  
  92.     // ---------------------------------------------
  93.     // Stats
  94.     XPValues(0)=17
  95.     XPValues(1)=22
  96.     XPValues(2)=30
  97.     XPValues(3)=3500
  98.  
  99.     //BaseEyeHeight=1.f
  100.     // ---------------------------------------------
  101.     // Content
  102.     MonsterArchPath="ZED_ARCH.ZED_Bloat_Archetype"
  103.     PawnAnimInfo=KFPawnAnimInfo'ZED_Bloat_ANIM.Bloat_AnimGroup'
  104.     DifficultySettings=class'KFDifficulty_Bloat'
  105.  
  106.     // ---------------------------------------------
  107.     // Special Moves
  108.     Begin Object Name=SpecialMoveHandler_0
  109.         SpecialMoveClasses(SM_Evade)=class'KFSM_Evade'
  110.         SpecialMoveClasses(SM_Evade_Fear)=class'KFSM_Evade_Fear'
  111.         SpecialMoveClasses(SM_Block)=class'KFSM_Block'
  112.     End Object
  113.  
  114.     // for reference: Vulnerability=(default, head, legs, arms, special)
  115.     IncapSettings(AF_Stun)=     (Vulnerability=(0.5, 1.0, 0.5, 0.5, 0.5), Cooldown=50.0,  Duration=1.5)
  116.     IncapSettings(AF_Knockdown)=(Vulnerability=(1.0),                     Cooldown=20.0)
  117.     IncapSettings(AF_Stumble)=  (Vulnerability=(0.4),                     Cooldown=10.0)
  118.     IncapSettings(AF_GunHit)=   (Vulnerability=(0.35),                    Cooldown=0.1)
  119.     IncapSettings(AF_MeleeHit)= (Vulnerability=(2.0),                     Cooldown=0.3)
  120.     IncapSettings(AF_Poison)=   (Vulnerability=(0.3),                     Cooldown=50.5, Duration=2.0)
  121.     IncapSettings(AF_Microwave)=(Vulnerability=(3.0),                     Cooldown=3.0,  Duration=4.0)
  122.     IncapSettings(AF_FirePanic)=(Vulnerability=(1),                       Cooldown=1.0,  Duration=1.0) //duration 8
  123.     IncapSettings(AF_EMP)=      (Vulnerability=(1),                     Cooldown=1.0,  Duration=1.5)
  124.     IncapSettings(AF_Freeze)=   (Vulnerability=(2.0),                     Cooldown=10.0,  Duration=2.5)
  125.     IncapSettings(AF_Snare)=    (Vulnerability=(1.0, 1.0, 2.0, 1.0),      Cooldown=5.5,  Duration=3.0)
  126.     IncapSettings(AF_Bleed)=    (Vulnerability=(4.0))
  127.  
  128.     Begin Object Name=Afflictions_0
  129.         FireFullyCharredDuration=3.5
  130.     End Object
  131.  
  132.     ParryResistance=3
  133.  
  134.     // ---------------------------------------------
  135.     // Gameplay
  136.     VomitRange=400.f
  137.     VomitDamage=20
  138.     ExplodeRange=500.f
  139.     Begin Object Name=MeleeHelper_0
  140.         BaseDamage=20.f
  141.         MaxHitRange=290.f
  142.         MomentumTransfer=25000.f
  143.         MyDamageType=class'KFDT_Slashing_ZedWeak'
  144.     End Object
  145.  
  146.     Health=1500
  147.     HeadlessBleedOutTime=1.f
  148.     DrawScale=1.1
  149.  
  150.     // Override Head GoreHealth (aka HeadHealth)
  151.     HitZones[HZI_HEAD]=(ZoneName=head, BoneName=Head, Limb=BP_Head, GoreHealth=300, DmgScale=1.0001, SkinID=1)
  152.     HitZones.Add((ZoneName=rknife, BoneName=RightForearm, Limb=BP_RightArm, GoreHealth=20, DmgScale=0.2, SkinID=2))
  153.     HitZones.Add((ZoneName=lknife, BoneName=LeftForearm, Limb=BP_LeftArm, GoreHealth=20, DmgScale=0.2, SkinID=2))
  154.     DoshValue=1500
  155.     Mass=130.f
  156.  
  157.     // Penetration
  158.     PenetrationResistance=3.0
  159.  
  160.     DamageTypeModifiers.Add((DamageType=class'KFDT_Ballistic_Submachinegun',    DamageScale=(0.35)))  //0.25
  161.     DamageTypeModifiers.Add((DamageType=class'KFDT_Ballistic_AssaultRifle',     DamageScale=(0.35)))  //0.25
  162.     DamageTypeModifiers.Add((DamageType=class'KFDT_Ballistic_Shotgun',          DamageScale=(0.25)))  
  163.     DamageTypeModifiers.Add((DamageType=class'KFDT_Ballistic_Handgun',          DamageScale=(0.35)))  //0.2
  164.     DamageTypeModifiers.Add((DamageType=class'KFDT_Ballistic_Rifle',            DamageScale=(0.30)))
  165.     DamageTypeModifiers.Add((DamageType=class'KFDT_Slashing',                   DamageScale=(0.3)))
  166.     DamageTypeModifiers.Add((DamageType=class'KFDT_Bludgeon',                   DamageScale=(0.3)))
  167.     DamageTypeModifiers.Add((DamageType=class'KFDT_Fire',                       DamageScale=(1.0)))  //1.2 //1.6
  168.     DamageTypeModifiers.Add((DamageType=class'KFDT_Microwave',                  DamageScale=(0.8)))
  169.     DamageTypeModifiers.Add((DamageType=class'KFDT_Explosive',                  DamageScale=(0.5)))
  170.     DamageTypeModifiers.Add((DamageType=class'KFDT_Piercing',                   DamageScale=(0.25)))
  171.     DamageTypeModifiers.Add((DamageType=class'KFDT_Toxic',                      DamageScale=(0.25)))
  172.  
  173.     //Special Case damage resistance
  174.     DamageTypeModifiers.Add((DamageType=class'KFDT_Ballistic_9mm',              DamageScale=(0.65))
  175.     DamageTypeModifiers.Add((DamageType=class'KFDT_Ballistic_AR15',             DamageScale=(0.40))
  176.  
  177.     // ---------------------------------------------
  178.     // Block Settings
  179.     MinBlockFOV=0.1f
  180.  
  181.     // ---------------------------------------------
  182.     // Movement / Physics
  183.     Begin Object Name=CollisionCylinder
  184.         CollisionRadius=+0055.000000 // Mesh is pulled back by 20 UU
  185.     End Object
  186.  
  187.     RotationRate=(Pitch=50000,Yaw=20000,Roll=50000)
  188.     GroundSpeed=150.0f
  189.     SprintSpeed=410.0f   //260
  190.     PhysRagdollImpulseScale=1.5f
  191.     KnockdownImpulseScale=1.5f
  192.  
  193.     // ---------------------------------------------
  194.     // AI / Navigation
  195.     ControllerClass=class'KFAIController_ZedBloat'
  196.     BumpDamageType=class'KFDT_NPCBump_Large'
  197.     DamageRecoveryTimeHeavy=0.85f
  198.     DamageRecoveryTimeMedium=1.0f
  199.  
  200.     // ---------------------------------------------
  201.     // Puke Mines
  202.     PukeMineProjectileClass=class'KFProj_BloatPukeMine'
  203.     DeathPukeMineRotations(0)=(Pitch=7000,Yaw=10480,Roll=0)
  204.     DeathPukeMineRotations(1)=(Pitch=7000,Yaw=32767,Roll=0)
  205.     DeathPukeMineRotations(2)=(Pitch=7000,Yaw=-10480,Roll=0)
  206.  
  207.     // ---------------------------------------------
  208.  
  209. `if(`notdefined(ShippingPC))
  210.     DebugRadarTexture=Texture2D'UI_ZEDRadar_TEX.MapIcon_Bloat';
  211. `endif
  212.  
  213.     // ---------------------------------------------
  214.     // Spawning
  215.     MinSpawnSquadSizeType=EST_Large
  216.  
  217.     bIsBloatClass=true
  218. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement