Page 1 of 1

Creepinator gun - force field

Posted: Mon Jan 16, 2017 1:00 pm
by Pileyrei
Boring question

The creepinator gun fires rockets in a spiral.

If you stand still and right click you get a pink shield that covers you for a few seconds. This shield blocks the enforcer bullets - quite funny to see people standing in front of you trying to shoot you. However everything else goes straight through the shield which makes me wonder - what's the point?

Anyone know what I mean and if there is a way to make it a proper shield?

Thanks
Piley

Re: Creepinator gun - force field

Posted: Mon Jan 16, 2017 5:38 pm
by Barbie
There are at least two Creepinators: I found them in packages "DangerW" and "EK_map_pack". They are different in code, but both spawn a "GhandiForceField" from the same package on alt fire. These GhandiForceFields are also not equal in code:
DangerW.GhandiForceField
Show

Code: Select all

//=============================================================================
// GhandiForceField.
//=============================================================================
class GhandiForceField expands ForceFieldProj;

var() int Charge;

	function PostBeginPlay()
	{
		Super.PostBeginPlay();
		PlaySound(SpawnSound);
		SetCollision(True,True,True);
		PlayAnim('Grow',0.2);
		if (Charge<10) Charge = 10;
	}

Auto State Activated
{
	function Touch(Actor Other)
	{
		if ( other.isa('projectile') && !other.isa('CTFFlag') && !other.isa('REDFlag') )
		{
			Spawn(class'UT_SpriteBallExplosion',,, other.location);
			other.destroy();
			PlaySound(ImpactSound);
		}
	}

	function ProcessTouch(Actor Other, Vector HitLocation)
	{
		if ( other.isa('projectile') && !other.isa('CTFFlag') && !other.isa('REDFlag') )
		{
			Spawn(class'UT_SpriteBallExplosion',,, other.location);
			other.destroy();
			PlaySound(ImpactSound);
		}
	}

Begin:
	FinishAnim();
	Sleep(Charge/10);
	TweenAnim('All',0.5);
	FinishAnim();
	Destroy();
}



defaultproperties
{
    Charge=10
    DrawScale=2.00
    CollisionRadius=60.00
    CollisionHeight=100.00
}
EK_map_pack.GhandiForceField
Show

Code: Select all

//=============================================================================
// GhandiForceField.
//=============================================================================
class GhandiForceField expands ForceFieldProj;

var() int Charge;

	function PostBeginPlay()
	{
		Super.PostBeginPlay();
		PlaySound(SpawnSound);
		SetCollision(True,True,True);
		PlayAnim('Grow',0.2);
		if (Charge<10) Charge = 50;
	}

Auto State Activated
{
	function Touch(Actor Other)
	{
		PlaySound(ImpactSound);
	}

Begin:
	FinishAnim();
	Sleep(Charge/10);
	TweenAnim('All',0.5);
	FinishAnim();
	Destroy();
}


defaultproperties
{
    Charge=50
    DrawScale=2.00
    CollisionRadius=60.00
    CollisionHeight=100.00
}
Can you determine in what package the Creepinator you are using is in? I made two test maps with "GhandiForceFields.EK_map_pack" and "DangerW.GhandiForceField" and both seem to block projectiles (I tried with Ripper and ShockRifle).

Re: Creepinator gun - force field

Posted: Mon Jan 16, 2017 6:59 pm
by Pileyrei
Hi Barbie

Thank you so much for doing this!
The map it is in is DM-AnotherFunnel:

DL link: http://medor.no-ip.org/index.php?dir=Maps/DeathMatch/

This is just something I am curious about.
If I spawn the Ghandi shield rockets still kill me.

Re: Creepinator gun - force field

Posted: Mon Jan 16, 2017 8:06 pm
by Barbie
Pileyrei wrote:If I spawn the Ghandi shield rockets still kill me.
That EK_map_pack.GhandiForceField does not destroy projectiles as the one of the DangerW package does. So if a rocket hits the collision cylinder of an EK_map_pack.GhandiForceField, it will explode and make damage in a certain hurt radius. Maybe that is the reason why you get killed.
However, I'll have a look at the map you mentioned.

<EDIT>
The map DM-AnotherFunnel.unr has a Creepinator and GhandiForceField in MyLevel and both look like an exact copy of the stuff in package EK_map_pack.
Pileyrei wrote:if there is a way to make it a proper shield?
It depends on what stage you are:
1) you are the mapper: expand MyLevel.GhandiForceField with the code of DangerW.GhandiForceField.
2) you want to play this map only local: Edit the map as suggested in (1) and save it with a new, unique name.
3) you want to run this map on a server:
3.1) do as suggested in (2) (helps only for this map)
3.2) install a SpawnNotification on server that replaces the GhandiForceField (helps for all maps)
3.3) use Higor's XC_Engine's function replacer to hack in the code taken from DangerW.GhandiForceField (does not help for this map but for all maps using package EK_map_pack - correct me if I'm wrong).
</EDIT>

Re: Creepinator gun - force field

Posted: Tue Jan 17, 2017 9:40 am
by Pileyrei
Thanks very much for the help :)