PDA

View Full Version : sgSafetyZone



Crsk
12-17-2012, 03:06 PM
when you are in the SafetyZone radius, you are protected, the Zone are Safety only for the players and this build
don't block shots (almost) so, SafetyZone is useless as Forcefield or for protect your core.


if your health or armor get 150, if you leave the radius or you are more than 15 seconds inside the safety radius,
you are not protected anymore (for avoid protection abuse).


Media progress:
Done - Textures (!r, !b, !g, !y)
Done - 3D Mesh model

Code progress:
here is where i need help, currently i have two files "sgSafetyZone.uc" and "sgImmune.uc"
when you touch the safety radius you are calling to "sgImmune.uc" so you are protected, the problem is that you
are protected all the match unless you die.

i was trying to use states but i fail, someone enlighten my way!! ):
im not coder, i need help with the "supposedly" part.

here some ss

http://www.mediafire.com/conv/3e37854c01c9d361d28bcf55170a4c9fe8ddb7c2299240f50d 3e353bba7abcae6g.jpg

http://www.mediafire.com/conv/06ad679af9faa098e1cfe777a32a6d5c496e28996f87635a87 71677bcaff53506g.jpg

suggestions are welcome and any help will be too appreciated :)

Higor
12-17-2012, 04:19 PM
While the purpose isn't something I dig.
It has huge potential for other gametypes, and other things with it.

And you just gave me an idea on how to actually make a credible forcefield.


Mechanics and speed.
You must take into consideration speed practises and in order to do that, to make use of as many game defined events.
Usage of chained lists is precisely a good thing in here, it's main purpose is to reduce the amount of iterations.
Damage hook, hook directly into the damage altering functions to provide the functionality, this can be done in 2 ways (Siege only, global).

I personally want to discuss this further.-

How's the current mechanics of this? (code wise)

Crsk
12-17-2012, 04:58 PM
How's the current mechanics of this?

almost no code, i just get the idea, make a model in milkshape, the texture in photoshop and post here xD anyway i'm stucked

my idea is create this build like an infiltrate supplier, i don't know if it is a good way



class sgSafetyZone extends sgEquipmentSupplier;

#exec MESH IMPORT MESH=SafetyZone ANIVFILE=MODELS\SafetyZone_a.3d DATAFILE=MODELS\SafetyZone_d.3d X=0 Y=0 Z=0
#exec MESH ORIGIN MESH=SafetyZone X=0 Y=0 Z=0

#exec MESH SEQUENCE MESH=SafetyZone SEQ=All STARTFRAME=0 NUMFRAMES=30

#exec MESHMAP NEW MESHMAP=SafetyZone MESH=SafetyZone
#exec MESHMAP SCALE MESHMAP=SafetyZone X=0.1 Y=0.1 Z=0.2

function Supply(Pawn target)
{
local Inventory inv;
inv = target.FindInventoryType(class'sgImmunity');

if ( inv == None )
inv = Spawn(class'sgImmunity');

if ( inv != None )
inv.GiveTo(target);
}

defaultproperties
{
DSofMFX=5.000000
BuildingName="SafetyZone"
BuildCost=400
BuildTime=0.500000
bNoUpgrade=True
MaxEnergy=90000.000000
Model=LodMesh'SiegeURC1000.SafetyZone'
SkinRedTeam=Texture'SiegeURC1000_.U.sz_Team0'
SkinBlueTeam=Texture'SiegeURC1000_.U.sz_Team1'
SkinGreenTeam=Texture'SiegeURC1000_.U.sz_Team2'
SkinYellowTeam=Texture'SiegeURC1000_.U.sz_Team3'
MFXrotX=(Pitch=0,Yaw=0,Roll=0)
bCollideWhenPlacing=False
CollisionRadius=150.000000
CollisionHeight=2.000000
}


see CollisionHeight=2, so this build is like a visual effect with a trigger settled in the floor for activate the owner immunity

so using states in sgImmunity.uc could work?

HIGH[+]AdRiaN
12-17-2012, 05:15 PM
i player in safety zone, can kill enemy players?
or, if the player on zone shoot (not with constructror), he loss the protection?

Crsk
12-17-2012, 05:31 PM
i player in safety zone, can kill enemy players?

when you are inside the safety zone you can kill players or they can kill you (immunity expired) because the invisible collision hull is 2 px height.



or, if the player on zone shoot (not with constructror), he loss the protection?

not at the moment, because code in progress, anyway i dont like that way for lost the protection.

~~D4RR3N~~
12-17-2012, 05:42 PM
Looks nice!
Crsk Is on fire coding things for siege xDDDDD
Higor has to respond xDDD

Crsk
12-17-2012, 05:49 PM
Looks nice!
Crsk Is on fire coding things for siege xDDDDD
Higor has to respond xDDD

hahaha i really suck creating things because some monts ago i did not know how to compile, Higor taught me how

SAM
12-17-2012, 06:12 PM
Here's what happen's

Nuke siren goes off....
Everyone runs to supplier.

GG

HIGH[+]AdRiaN
12-17-2012, 06:21 PM
not at the moment, because code in progress, anyway i dont like that way for lost the protection.

but if the protection dont expire when who is inside of zone do a shot, many players will abuse of this, keeping inside of zone sniping enemies incomings

Higor
12-17-2012, 06:27 PM
This is my idea of forcefield:

First, make ForceField a bProjTarget=False actor, so bullets and projectiles go through.
(Write that one down).

We make this ForceField delete projectiles that belong to enemies (more like make them "Hit a wall")

As for hitscan damage and explosion waves...

Create a linked list of ForceField actors in either the SiegeGI class (main Siege) and/or a Siege Mutator (if we were to implement SiegeU as mutator on other gametypes).
The linked List would look like this:

(SiegeGI)
var WildcardsForcefield FFlist;
(WildcardsForcefield)
var WildcardsForcefield nextFF;

This way we can iterate through this list without causing too much overhead.

(SiegeGI.ReduceDamage)
local WildcardsForcefield aFF;
For ( aFF=FFlist ; aFF!=none ; aFF=aFF.nextFF )
{
// Process stuff here
}

Then we check for a series of conditions for reducing damage:
Hitscan bullet:
We check that the forcefield is between the instigator and the hit location, and that is on a different team.
If those conditions apply, reduce damage to zero.

Explosion wave:
Check if the forcefield is between the victim and the explosion center, if it is, reduce damage 50%.

Exception:
Forcefield core will not be affected by these damage scalers.

Crsk
12-17-2012, 07:54 PM
but if the protection dont expire when who is inside of zone do a shot, many players will abuse of this, keeping inside of zone sniping enemies incomings

is abuse when you have 10 seconds immunity? mmm... you right, maybe (add) lost immunity by shot is good, and don't lost the protection by 150 health because get it take like 5 seconds when you have 100 health before use the SHP lvl.5 (armor take like 10 seconds from 0 to 150)



This is my idea of forcefield:

First, make ForceField a bProjTarget=False actor, so bullets and projectiles go through.
(Write that one down).

We make this ForceField delete projectiles that belong to enemies (more like make them "Hit a wall")

As for hitscan damage and explosion waves...

Create a linked list of ForceField actors in either the SiegeGI class (main Siege) and/or a Siege Mutator (if we were to implement SiegeU as mutator on other gametypes).
The linked List would look like this:


(SiegeGI)
var WildcardsForcefield FFlist;
(WildcardsForcefield)
var WildcardsForcefield nextFF;


This way we can iterate through this list without causing too much overhead.


(SiegeGI.ReduceDamage)
local WildcardsForcefield aFF;
For ( aFF=FFlist ; aFF!=none ; aFF=aFF.nextFF )
{
// Process stuff here
}


Then we check for a series of conditions for reducing damage:
Hitscan bullet:
We check that the forcefield is between the instigator and the hit location, and that is on a different team.
If those conditions apply, reduce damage to zero.

Explosion wave:
Check if the forcefield is between the victim and the explosion center, if it is, reduce damage 50%.

Exception:
Forcefield core will not be affected by these damage scalers.

a total different concept of forcefield, yours delete enemy projectiles, mine get immunity to players inside his radius, i think yours is more elegant xD

please implement that, i want to see an advanced forcefield and over all, i want to see noobs failing when try to spam my sup!

~~D4RR3N~~
12-17-2012, 08:02 PM
i want to see noobs failing when try to spam my sup!
ROFL

HIGH[+]AdRiaN
12-17-2012, 11:11 PM
is abuse when you have 10 seconds immunity? mmm... you right, maybe (add) lost immunity by shot is good, and don't lost the protection by 150 health because get it take like 5 seconds when you have 100 health before use the SHP lvl.5 (armor take like 10 seconds from 0 to 150)
makes no sense continue with protection if a player shot... if he shot, he is trying kill someone, but if possible, is better you make the immunity dont expires, if the player shot if the initial weapons (piston, chainsaw, enforcer and constructor)

piston and chaisaw cant kill someone when you are inside of sup
shooting enforcer by 10 seconds is not problem (sniper is a problem)
constructor, kkk i dont need say anything

|uK|chiseller
12-18-2012, 07:07 AM
I think something like that would be much better than the current sup spam solution.

HIGH[+]AdRiaN
12-18-2012, 11:12 AM
I think something like that would be much better than the current sup spam solution.

yes, the current one is shit, tele near ss, nuke ss = loss a lot of ru

|uK|B|aZe//.
12-18-2012, 04:16 PM
why not just have the sup immunity how it was no ru given for nuking a sup? but you get ru if you nuked stuff near a sup obviously like normal building nukings

SAM
12-18-2012, 07:04 PM
why not just have the sup immunity how it was no ru given for nuking a sup? but you get ru if you nuked stuff near a sup obviously like normal building nukings

Because that's easier said than done.....depending on the map there'd need to be a specified 'radius' and because sone maps are small and others large the radius would not really work unless higor can figure out an alternative.

And even if he does, people will still complain just like they did when people egged him on to implementing the 'nuke on back' and once he did there was an almighty crying session with tissues going all round. No win situation on this really as it becomes 'noob friendly'

Crsk
06-07-2013, 07:09 AM
as been so long, i'm good at not finishing things... but i'll keep working on this anti sup spam thing and post the result.

now looks like a Supplier's extension, look

http://i1285.photobucket.com/albums/a596/Crssk/SafetyZone_zpsa4b624bc.png

is not buildable anymore, it's auto placed when a supplier is detected in the level