RuneI
Class StoneGuard

source: c:\runehov\RuneI\Classes\StoneGuard.uc
Core.Object
   |
   +--Engine.Actor
      |
      +--Engine.Pawn
         |
         +--RuneI.ScriptPawn
            |
            +--RuneI.StoneGuard
Direct Known Subclasses:None

class StoneGuard
extends RuneI.ScriptPawn

//============================================================================= // StoneGuard. //=============================================================================

Function Summary
 void AfterSpawningInventory()
     
//================================================
//
// AfterSpawningInventory
//
// Used to spawn additional chained weapon
//================================================
 eAttitude AttitudeToCreature(Pawn Other)
     
//------------------------------------------------
//
// AttitudeToCreature
//
//------------------------------------------------
 bool CanPickup(Inventory item)
     
//================================================
//
// CanPickup
//
// Let's pawn dictate what it can pick up
//================================================
 bool DamageBodyPart(int Damage, Pawn EventInstigator, vector HitLocation, vector Momentum, name DamageType, int bodypart)
     
//============================================================
//
// DamageBodyPart
//
// StoneGuards are immortal
//============================================================
 EMatterType MatterForJoint(int joint)
     
//============================================================
//
// MatterForJoint
//
// Returns what kind of material joint is associated with
//============================================================
 void PlayMoving(optional float)
 void PlayWaiting(optional float)



Source Code


00001	//=============================================================================
00002	// StoneGuard.
00003	//=============================================================================
00004	class StoneGuard expands ScriptPawn;
00005	
00006	//------------------------------------------------
00007	//
00008	// AttitudeToCreature
00009	//
00010	//------------------------------------------------
00011	function eAttitude AttitudeToCreature(Pawn Other)
00012	{
00013		if(Other.IsA('Goblin'))
00014			return ATTITUDE_Hate;
00015		else
00016			return Super.AttitudeToCreature(Other);
00017	}
00018	
00019	//================================================
00020	//
00021	// AfterSpawningInventory
00022	//
00023	// Used to spawn additional chained weapon
00024	//================================================
00025	function AfterSpawningInventory()
00026	{
00027		Weapon = Spawn(class'zombieclaw');
00028		Weapon.SetOwner(self);
00029		AttachActorToJoint(Weapon, JointNamed(WeaponJoint));	// Attach to left hand
00030		Weapon.GotoState('Active');
00031	}
00032	
00033	//================================================
00034	//
00035	// CanPickup
00036	//
00037	// Let's pawn dictate what it can pick up
00038	//================================================
00039	function bool CanPickup(Inventory item)
00040	{
00041		if(item.IsA('Weapon') && Weapon == None)
00042		{
00043			return(item.IsA('ZombieClaw'));
00044		}
00045	}
00046	
00047	function PlayWaiting(optional float tween)
00048	{
00049		PlayAnim('base', 1.0, 0.1);
00050	}
00051	
00052	function PlayMoving(optional float tween)
00053	{
00054		PlayAnim('base', 1.0, 0.1);
00055	}
00056	
00057	//============================================================
00058	//
00059	// MatterForJoint
00060	//
00061	// Returns what kind of material joint is associated with
00062	//============================================================
00063	function EMatterType MatterForJoint(int joint)
00064	{
00065		return(MATTER_STONE);
00066	}
00067	
00068	//============================================================
00069	//
00070	// DamageBodyPart
00071	//
00072	// StoneGuards are immortal
00073	//============================================================
00074	
00075	function bool DamageBodyPart(int Damage, Pawn EventInstigator, vector HitLocation, vector Momentum, name DamageType, int bodypart)
00076	{
00077		return(false);
00078	}
00079	
00080	defaultproperties
00081	{
00082	     FightOrFlight=1.000000
00083	     FightOrDefend=1.000000
00084	     HighOrLow=0.500000
00085	     HighOrLowBlock=0.500000
00086	     BlockChance=1.000000
00087	     LungeRange=100.000000
00088	     PaceRange=100.000000
00089	     TimeBetweenAttacks=0.100000
00090	     MeleeRange=100.000000
00091	     CombatRange=180.000000
00092	     GroundSpeed=0.000000
00093	     AccelRate=0.000000
00094	     JumpZ=0.000000
00095	     MaxStepHeight=0.000000
00096	     AirControl=0.100000
00097	     WalkingSpeed=0.000000
00098	     ClassID=22
00099	     Health=9999
00100	     BodyPartHealth(1)=9999
00101	     BodyPartHealth(3)=9999
00102	     BodyPartHealth(5)=9999
00103	     Intelligence=BRAINS_HUMAN
00104	     WeaponJoint=attach_hand
00105	     ShieldJoint=attach_shielda
00106	     StabJoint=spineb
00107	     bCanLook=True
00108	     bHeadLookUpDouble=True
00109	     LookDegPerSec=10.000000
00110	     CollisionRadius=24.000000
00111	     CollisionHeight=46.000000
00112	     Buoyancy=400.000000
00113	     RotationRate=(Pitch=0,Yaw=0,Roll=0)
00114	     SkelMesh=23
00115	     Skeletal=SkelModel'Players.Ragnar'
00116	}

End Source Code