RuneI
Class TrialPitMace

source: c:\runehov\RuneI\Classes\TrialPitMace.uc
Core.Object
   |
   +--Engine.Actor
      |
      +--Engine.Inventory
         |
         +--Engine.Weapon
            |
            +--RuneI.Hammer
               |
               +--RuneI.TrialPitMace
Direct Known Subclasses:None

class TrialPitMace
extends RuneI.Hammer

//============================================================================= // TrialPitMace. //=============================================================================
Variables
 float FireRadius


Function Summary
 void PowerupEnded()
     
//=============================================================================
//
// PowerupEnded
//
//=============================================================================
 void PowerupEndingPulseOff()
     
//=============================================================================
//
// PowerupEndingPulseOff
//
//=============================================================================
 void PowerupEndingPulseOn()
     
//=============================================================================
//
// PowerupEndingPulseOn
//
//=============================================================================
 void PowerupInit()
     
//=============================================================================
//
// PowerupInit
//
//=============================================================================
 
simulated
RemovePowerupEffect()
     
//=============================================================================
//
// RemovePowerupEffect
//
//=============================================================================
 
simulated
SpawnPowerupEffect()
     
//=============================================================================
//
// SpawnPowerupEffect
//
//=============================================================================
 void WeaponFire(int SwingCount)
     
//=============================================================================
//
// Powerup: FireRadius
//
//=============================================================================

 void WeaponFire(int SwingCount)
     
//=============================================================================
//
// Powerup: FireRadius
//
//=============================================================================




Source Code


00001	//=============================================================================
00002	// TrialPitMace.
00003	//=============================================================================
00004	class TrialPitMace expands Hammer;
00005	
00006	var(Sounds) Sound PoweredUpFireSound;
00007	var float FireRadius;
00008	
00009	//=============================================================================
00010	//
00011	// PowerupInit
00012	//
00013	//=============================================================================
00014	
00015	function PowerupInit()
00016	{
00017	//	local int joint;
00018	//	local actor glow;
00019	
00020		Super.PowerupInit();
00021	
00022		DesiredColorAdjust.X = 128;
00023		DesiredColorAdjust.Y = 70;
00024	
00025	/*
00026		joint = JointNamed('offset');
00027		glow = Spawn(class'trialpitfire', self,, GetJointPos(joint));
00028		if(glow != None)
00029		{
00030			AttachActorToJoint(glow, joint);
00031		}
00032	*/
00033	}	
00034	
00035	//=============================================================================
00036	//
00037	// PowerupEndingPulseOn
00038	//
00039	//=============================================================================
00040	
00041	function PowerupEndingPulseOn()
00042	{
00043		DesiredFatness = 140;
00044		DesiredColorAdjust.X = 0;
00045		DesiredColorAdjust.Y = 0;
00046		PlaySound(PoweredUpEndingSound, SLOT_None);
00047	}
00048	
00049	//=============================================================================
00050	//
00051	// PowerupEndingPulseOff
00052	//
00053	//=============================================================================
00054	
00055	function PowerupEndingPulseOff()
00056	{
00057		DesiredFatness = 128;
00058		DesiredColorAdjust.X = 128;
00059		DesiredColorAdjust.Y = 70;
00060	}
00061	
00062	//=============================================================================
00063	//
00064	// PowerupEnded
00065	//
00066	//=============================================================================
00067	
00068	function PowerupEnded()
00069	{
00070	//	local int joint;
00071	//	local actor glow;
00072	
00073		Super.PowerupEnded();
00074	
00075		DesiredColorAdjust.X = 0;
00076		DesiredColorAdjust.Y = 0;
00077	
00078	/*
00079		joint = JointNamed('offset');
00080		glow = DetachActorFromJoint(joint);
00081		if(glow != None)
00082			glow.Destroy();
00083	*/
00084	}	
00085	
00086	//=============================================================================
00087	//
00088	// SpawnPowerupEffect
00089	//
00090	//=============================================================================
00091	simulated function SpawnPowerupEffect()
00092	{
00093		local EffectSkeleton ES;
00094	
00095		// Spawn an EffectSkeleton that will display all powered up effects
00096		ES = Spawn(class'EffectSkelTrialMace', self);
00097		if (ES != None)
00098		{
00099			AttachActorToJoint(ES, 0);
00100		}
00101	}
00102	
00103	//=============================================================================
00104	//
00105	// RemovePowerupEffect
00106	//
00107	//=============================================================================
00108	simulated function RemovePowerupEffect()
00109	{
00110		local actor A;
00111		// Remove Effect skeleton
00112		A = DetachActorFromJoint(0);
00113		A.Destroy();
00114	}
00115	
00116	//=============================================================================
00117	//
00118	// Powerup: BlastRadius
00119	//
00120	// This function is called when the weapon is initially powered up
00121	//=============================================================================
00122	
00123	function WeaponFire(int SwingCount)
00124	{
00125		local FireRadius B;
00126		local vector loc;
00127	
00128		if (bPoweredUp && SwingCount == 0)
00129		{
00130			loc = Location;
00131			loc.Z -= 10;
00132			B = Spawn(class'FireRadius', Owner,, loc, rotator(vect(0,0,1)));
00133			B.Instigator = Pawn(Owner);
00134			PlaySound(PoweredUpFireSound, SLOT_Interface);
00135		}
00136	}
00137	
00138	/*
00139	//=============================================================================
00140	//
00141	// Powerup: FireRadius
00142	//
00143	//=============================================================================
00144	
00145	function WeaponFire(int SwingCount)
00146	{
00147		local actor A;
00148		local int i;
00149		local bool bCollisionJoints;
00150		local ParticleSystem P;
00151	
00152		if (bPoweredUp)
00153		{
00154			// Spawn fire effects
00155			for (i=0; i<65535; i+=8192)
00156			{
00157				P = spawn(class'BlazeEffect',,,Owner.Location);
00158				P.Velocity = vector(rot(0,1,0)*i)*200;
00159			}
00160	
00161			foreach RadiusActors(class'actor', A, FireRadius, Owner.Location)
00162			{
00163				if (A == self || A==Owner || A.Owner==Owner)
00164					continue;
00165	
00166				if (A.bHidden)
00167					continue;
00168	
00169				if (ScriptPawn(A) != None && ScriptPawn(A).bIsBoss)
00170					continue;
00171	
00172				if (!FastTrace(Location, A.Location))
00173					continue;
00174	
00175				if (A.IsA('Pawn'))
00176				{
00177					// Set on fire
00178					Pawn(A).PowerupBlaze(Pawn(Owner));
00179	
00180					// Do some damage
00181					A.JointDamaged(15, Pawn(Owner), A.Location, Normal(A.Location-Owner.Location)*50, 'blunt', 0);
00182					A.AddVelocity((Normal(A.Location-Owner.Location)+vect(0,0,1))*300);
00183				}
00184				else if (A.IsA('Decoration') || A.IsA('Inventory'))
00185				{
00186					// Set all collision joints on fire
00187					for (i=0; i<A.NumJoints(); i++)
00188					{
00189						if ((A.JointFlags[i] & JOINT_FLAG_COLLISION)!=0)
00190						{
00191							bCollisionJoints = true;
00192							A.SetOnFire(Pawn(Owner), i);
00193						}
00194					}
00195					if (!bCollisionJoints)
00196						A.SetOnFire(Pawn(Owner), 1);
00197				}
00198			}
00199		}
00200	}
00201	*/
00202	
00203	defaultproperties
00204	{
00205	     PoweredUpFireSound=Sound'WeaponsSnd.PowerUps.afire01'
00206	     FireRadius=300.000000
00207	     StowMesh=1
00208	     Damage=30
00209	     BloodTexture=Texture'weapons.TrialMacetrialpit_maceblood'
00210	     rating=2
00211	     ExtendedLength=5.000000
00212	     RunePowerRequired=50
00213	     RunePowerDuration=5.000000
00214	     PowerupMessage="Blaze!"
00215	     ThroughAir(0)=Sound'WeaponsSnd.Swings.swing07'
00216	     ThroughAirBerserk(0)=Sound'WeaponsSnd.Swings.bswing08'
00217	     HitFlesh(0)=Sound'WeaponsSnd.ImpFlesh.impfleshhammer04'
00218	     HitWood(0)=Sound'WeaponsSnd.ImpWood.impactwood03'
00219	     HitStone(0)=Sound'WeaponsSnd.ImpStone.impactstone19'
00220	     HitMetal(0)=Sound'WeaponsSnd.ImpMetal.impactmetal09'
00221	     HitDirt(0)=Sound'WeaponsSnd.ImpEarth.impactearth06'
00222	     HitShield=Sound'WeaponsSnd.Shields.shield08'
00223	     HitWeapon=Sound'WeaponsSnd.Swords.sword08'
00224	     HitBreakableWood=Sound'WeaponsSnd.ImpWood.impactwood12'
00225	     HitBreakableStone=Sound'WeaponsSnd.ImpStone.impactstone11'
00226	     SheathSound=Sound'WeaponsSnd.Stows.xstow01'
00227	     UnsheathSound=Sound'WeaponsSnd.Stows.xunstow01'
00228	     PowerUpSound=Sound'WeaponsSnd.PowerUps.powerstart38'
00229	     PoweredUpSoundLOOP=Sound'WeaponsSnd.PowerUps.power02L'
00230	     PitchDeviation=0.080000
00231	     PowerupIcon=Texture'RuneFX2.tmace'
00232	     PowerupIconAnim=Texture'RuneFX2.tmace1a'
00233	     PoweredUpSwipeClass=Class'RuneI.WeaponSwipeFire'
00234	     A_Idle=H3_idle
00235	     A_AttackA=H3_attackA
00236	     A_AttackAReturn=H3_attackAreturn
00237	     A_AttackB=H3_attackB
00238	     A_AttackBReturn=H3_attackBreturn
00239	     A_AttackC=H3_attackC
00240	     A_AttackCReturn=H3_attackCreturn
00241	     A_AttackStandA=H3_StandingattackA
00242	     A_AttackStandAReturn=H3_StandingattackAReturn
00243	     A_AttackStandB=H3_StandingattackB
00244	     A_AttackStandBReturn=H3_StandingattackBReturn
00245	     A_AttackBackupA=H3_BackupAttackA
00246	     A_AttackBackupAReturn=H3_BackupAttackAReturn
00247	     A_AttackBackupB=H3_BackupAttackB
00248	     A_AttackBackupBReturn=H3_BackupAttackBReturn
00249	     A_AttackStrafeRight=S1_StrafeRightAttack
00250	     A_AttackStrafeLeft=S1_StrafeLeftAttack
00251	     A_Throw=H3_throw
00252	     A_Powerup=s2_powerup
00253	     A_PainFront=H3_painFront
00254	     A_PainRight=S1_painBack
00255	     A_Taunt=H3_taunt
00256	     A_PumpTrigger=H3_PumpTrigger
00257	     A_LeverTrigger=H3_LeverTrigger
00258	     PickupMessage="You now carry the Trial Pit Mace"
00259	     PickupSound=Sound'OtherSnd.Pickups.grab03'
00260	     DropSound=Sound'WeaponsSnd.Drops.hammerdrop03'
00261	     Mass=14.000000
00262	     Skeletal=SkelModel'weapons.TrialMace'
00263	     SkelGroupSkins(0)=Texture'weapons.TrialMacetrialpit_mace'
00264	     SkelGroupSkins(1)=Texture'weapons.TrialMacetrialpit_mace'
00265	}

End Source Code