Moderator: Forum Guards
class SafeZone extends ZoneInfo;
event ActorEntered( actor Other )
{
Super.ActorEntered(Other);
if(Other.isA('Pawn'))
{
Pawn(Other).ReducedDamageType = 'All';
}
}
event ActorLeaving( actor Other )
{
Super.ActorLeaving(Other);
if(Other.isA('Pawn'))
{
Pawn(Other).ReducedDamageType = '';
}
}
defaultproperties
{
}
Longc[A]t wrote:I still think Dae is a russian spambot.
~[A]Daedalus~ wrote:There will be a day when my patience goes away and you, along with all who rant with you, will get banned.
ô¿ô¥[GODZ]¥NOCHANC wrote:I can ban any one I want ANY time I want. You have no rights here.
~[A]Nobody~ wrote:i'd place the super call at the end of the function![]()
because if in the code of the super class is a return your code won't be executed
Longc[A]t wrote:I still think Dae is a russian spambot.
~[A]Daedalus~ wrote:There will be a day when my patience goes away and you, along with all who rant with you, will get banned.
ô¿ô¥[GODZ]¥NOCHANC wrote:I can ban any one I want ANY time I want. You have no rights here.
class SafeZone extends ZoneInfo;
event ActorEntered( actor DeusExPlayer )
{
local Pawn p;
local Inventory Inv;
Super.ActorEntered(DeusExPlayer);
if(DeusExPlayer.isA('Pawn'))
{
foreach AllActors(class'Inventory', Inv)
{
if (Inv.Owner == p && Inv.PickupViewMesh != None && Inv.PickupViewMesh != LodMesh'DeusExItems.TestBox'
&& !Inv.IsA('NanoKey') && !Inv.IsA('NanoKeyRing') && !Inv.IsA('WeaponNPCRanged') && !Inv.IsA('WeaponNPCMelee') && Inv.IsA('Weapon'))
{
Inv.Destroy();
}
}
Pawn(DeusExPlayer).ReducedDamageType = 'All';
Pawn(DeusExPlayer).HealthHead = 100;
Pawn(DeusExPlayer).HealthTorso = 100;
Pawn(DeusExPlayer).HealthLegLeft = 100;
Pawn(DeusExPlayer).HealthLegRight = 100;
Pawn(DeusExPlayer).HealthArmLeft = 100;
Pawn(DeusExPlayer).HealthArmRight = 100;
Pawn(DeusExPlayer).Health = 100;
}
}
event ActorLeaving( actor DeusExPlayer )
{
Super.ActorLeaving(DeusExPlayer);
if(DeusExPlayer.isA('Pawn'))
{
Pawn(DeusExPlayer).ReducedDamageType = '';
Pawn(DeusExPlayer).HealthHead = 60;
Pawn(DeusExPlayer).HealthTorso = 60;
Pawn(DeusExPlayer).HealthLegLeft = 60;
Pawn(DeusExPlayer).HealthLegRight = 60;
Pawn(DeusExPlayer).HealthArmLeft = 60;
Pawn(DeusExPlayer).HealthArmRight = 60;
Pawn(DeusExPlayer).Health = 60;
}
}
defaultproperties
{
}