Hi Emac,

I tried to ad the takedamage to the spawn protection but it gives errors when i compile.
error, unrecogniced member 'TakeDamage' in controler.
It looks like i run in to problems i also encounter when trying to make a headshot bonus.
I did some coding for UT 99 but a lot of things have changed.
My e-mail adres is  maupzilla@chello.nl maybe it is easyer to comunicate this way.

InstigatedBy.TakeDamage(ActualDamage * (InstigatorDamageScale / 100), InstigatedBy, HitLocation, Momentum, DamageType);
ActualDamage *= VictimDamageScale / 100;

This code i used for a ut 99 spawn protection ( it was teh eavy spawn protection if i remember it well.

This is how i made the code

//==============================================================================
// Coded by Emac
//=============================================================================

class donzilla_SPB_GameRules extends GameRules config(DZSnipMutRange);

replication
{
	if(Role == ROLE_Authority)
		setSpawnShooterMsg, setShootSpawnerMsg;
}

var config string setSpawnShooterMsgR;
var config string setShootSpawnerMsgR;

var string setSpawnShooterMsg;
var string setShootSpawnerMsg;

simulated function PostBeginPlay()
{
	if(Role == ROLE_Authority)
	{
		setSpawnShooterMsg = setSpawnShooterMsgR;
		setShootSpawnerMsg = setShootSpawnerMsgR;
	}

	Super.PostBeginPlay();
}

function bool cantHurt(Pawn Victim, Controller InstigatedBy)
{
	local bool bCantHurt;

	bCantHurt = false;

	if(Victim != None)
	{
		if(Victim.FindInventoryType(class'DZSnipMutRange.donzilla_SPB_Item') != None)
		{
			if(setShootSpawnerMsg != &quot;&quot; &amp;&amp; InstigatedBy != None &amp;&amp; PlayerController(InstigatedBy) != None)
			{
			    InstigatedBy.TakeDamage(20, InstigatedBy, InstigatedBy.Location, 0, DAMAGE CLASS);
				PlayerController(InstigatedBy).ClientPlaySound(SoundCue'A_Gameplay.ONS.A_Gameplay_ONS_CoreImpactShieldedCue');
				PlayerController(InstigatedBy).ClientMessage(setShootSpawnerMsg);
			}

			bCantHurt = True;
		}
	}

	if(InstigatedBy != None &amp;&amp; InstigatedBy.Pawn != None &amp;&amp; !bCantHurt)
	{
		if(UTBot(InstigatedBy) != None &amp;&amp; UTBot(InstigatedBy).Pawn.FindInventoryType(class'DZSnipMutRange.donzilla_SPB_Item') != None)
		{
			bCantHurt = True;
		}
		else if(PlayerController(InstigatedBy) != None &amp;&amp; PlayerController(InstigatedBy).Pawn.FindInventoryType(class'DZSnipMutRange.donzilla_SPB_Item') != None)
		{
			if(setSpawnShooterMsg != &quot;&quot;)
			{
			    InstigatedBy.TakeDamage(20, InstigatedBy, InstigatedBy.Location, 0, DAMAGE CLASS);
				PlayerController(InstigatedBy).ClientPlaySound(SoundCue'A_Gameplay.ONS.A_Gameplay_ONS_CoreImpactShieldedCue');
				PlayerController(InstigatedBy).ClientMessage(setSpawnShooterMsg);
			}

			bCantHurt = True;
		}
	}

	return bCantHurt;
}

function NetDamage(int OriginalDamage, out int Damage, pawn Victim, Controller InstigatedBy, vector HitLocation, out vector Momentum, class&lt;DamageType&gt; DamageType)
{
	if(Victim != None &amp;&amp; InstigatedBy != None &amp;&amp; Victim.Controller != None &amp;&amp; Victim.Controller != InstigatedBy){
		if(cantHurt(Victim, InstigatedBy))
		{
			Damage = 0;
			Momentum.X = 0;
			Momentum.Y = 0;
			Momentum.Z = 0;
		}

	}

	if(NextGameRules != None)
	{
		NextGameRules.NetDamage(OriginalDamage, Damage, Victim, InstigatedBy, HitLocation, Momentum, DamageType);
	}
}

function bool PreventDeath(Pawn Killed, Controller Killer, class&lt;DamageType&gt; damageType, vector HitLocation)
{
	if(Killed != None &amp;&amp; Killer != None &amp;&amp; Killed.Controller != None &amp;&amp; Killed.Controller != Killer){
		if(cantHurt(Killed, Killer))
		{
			return true;
		}
	}

	if(NextGameRules != None)
	{
		return NextGameRules.PreventDeath(Killed, Killer, damageType, HitLocation);
	}

	return false;
}

defaultproperties
{
   setSpawnShooterMsg=&quot;You cannot frag while under Spawn Protection!!!&quot;
   setShootSpawnerMsg=&quot;This player is under Spawn Protection!!!&quot;

}

Hope you can help me out,

Greetz,

Maurice :-x