Jump to content
ALPHIVE

I want make radiation trigger effect but that doesnt hurt with item on you

Recommended Posts

Hi everybody, and thank to all the community to help people ! :D

 

I have something i want to make but i really dont know how to do this :/

 

 

I want make radiation zone with a trigger or a marker (so this area kill you), and beside this i want that people that come to radiation zone :

-dont die if they have AAF_pilot_headhelmet

-die if they dont have the AAF_pilot_headhelmet

 

 

Im not extremely good at scripts im beginner so do not hesitate to explain or write any steps and file's name needed, or where i must place things :)

 

 

Thank you guys !

Share this post


Link to post
Share on other sites

Write this in a triggers activation field that triggers for all units present and multiple activation allowed:

{if(headgear _x != "AAF_pilot_headhelmet") then {_x setdamage 1;};} foreach thislist;

Untested but should work as you described.

Share this post


Link to post
Share on other sites

I will try this when i come back home bro ;) thank you for your help ;)

Share this post


Link to post
Share on other sites

I understand the concept of this all, but you do realize the little tube connecting to the helmet isn't a filtration esc system? It's to connect to the oxygen. 

I believe the crew helmets would look better in my opinion. 

Share this post


Link to post
Share on other sites

yeeah midnight i know this ;) but you are right if you think the other one seems to see better i will take a loot at this ;) because i search to place kind of gazmask you know

Share this post


Link to post
Share on other sites

yes, I understand. There are gas masks of course available as modifications. But it all depends on what you want your users downloading :shrug:

Share this post


Link to post
Share on other sites

Don't forget to "rearm" the trigger or add a loop for killing thisList. And let them a chance to grab a mask (or helmet)....

 

Gas mask needs addon like CUP

 

I wrote a little script more spicy:

place a trigger (none none) just for area . That works also with a marker, with little modification.

condition: true

on activation:

 

{
  [_x,thisTrigger] spawn {
    _unit =_this select 0;
    _trg = _this select 1;
    private "_timer";  
    while {alive _unit && local _unit} do {
      waitUntil {sleep 0.5; _unit inArea _trg && {vest _unit != "V_RebreatherB" or headgear _unit != "H_PilotHelmetFighter_B"}};
      if (isPlayer _unit) then {
        hint parseText format["<t size='1.10' font='PuristaMedium' color='#F0133C'>Radiation hazard! Check your equipment</t>"];
        _unit setVariable ["radiat", ppEffectCreate ["DynamicBlur",450]];
        (_unit getVariable "radiat") ppEffectEnable true;
        (_unit getVariable "radiat") ppEffectAdjust [4];
        (_unit getVariable "radiat") ppEffectCommit 10;
      };
      _timer = diag_tickTime;
      waitUntil {sleep 0.5; !(_unit inArea _trg) or diag_tickTime > _timer + 30 or {vest _unit == "V_RebreatherB" && headgear _unit == "H_PilotHelmetFighter_B"}};
      if ( diag_tickTime > _timer + 30) exitWith {_unit setDamage 1};
      if (isPlayer _unit) then {
        hint parseText format["<t size='1.10' font='PuristaMedium' color='#13F03C'>You are out of contamination</t>"];
        _unit setVariable ["noradiat", ppEffectCreate ["DynamicBlur",450]];
        (_unit getVariable "noradiat") ppEffectEnable true;
        (_unit getVariable "noradiat") ppEffectAdjust [0];
        (_unit getVariable "noradiat") ppEffectCommit 10;
      };
   }
  }
} forEach allunits;

 

Now, your units have 30 seconds to leave the area or grab a rebreather (nato) and a pilot helmet (nato). But your vision is altered!

NB: You need to open inventory if gears are on ground.

Have fun!

  • Like 1

Share this post


Link to post
Share on other sites

Guys you are fucking awesome !!! and thank you so much pierremm your system works well ;)

 

But its weird when i place bluefor pilot helmet i can die anyways :/ do you have solution about this ? :)

Share this post


Link to post
Share on other sites

To add some flavor you could increase a units fatigue to induce coughing.

 

1 minute ago, ALPHIVE said:

Guys you are fucking awesome !!! and thank you so much pierremm your system works well ;)

 

But its weird when i place bluefor pilot helmet i can die anyways :/ do you have solution about this ? :)


According to @pierremgis code you need a rebreather AND the helmet.

 

Cheers

Share this post


Link to post
Share on other sites
7 minutes ago, Grumpy Old Man said:

To add some flavor you could increase a units fatigue to induce coughing.

 


According to @pierremgis code you need a rebreather AND the helmet.

 

Cheers

Yes BLUFOR ones. But, you can change the classes as you like. Example: Remove vest _unit == "V_RebreatherB" and replace "H_PilotHelmetFighter_B"  for  "AAF_pilot_headhelmet"

Share this post


Link to post
Share on other sites

Oh i get it ! :D pierrem can you remake the script just with "H_PilotHelmetFighter_I" needed ? :D i fear to make an error so i prefers guy like you verify :(

 

Thank you really for your help bro your system is awesome !

Share this post


Link to post
Share on other sites
Spoiler

 

@pierremgi i got problem with the script, on the server when someone goes to radiation area, it affect everybody :/ its not local :/

 

How can i correct this ? :)

 

thank for help :)

Share this post


Link to post
Share on other sites

@NeoArmageddon  is it possible to make for rebreather and pilot helmet ? (as a constant script : like this script repeat every second to forbid people to run there without their mask after enter trigger)

 

{if(headgear _x != "AAF_pilot_headhelmet") then {_x setdamage 1;};} foreach thislist;

Share this post


Link to post
Share on other sites
2 hours ago, ALPHIVE said:
  Reveal hidden contents

 

@pierremgi i got problem with the script, on the server when someone goes to radiation area, it affect everybody :/ its not local :/

 

How can i correct this ? :)

 

thank for help :)

Your trigger runs this code with condition always true, just using the area.

Share this post


Link to post
Share on other sites

@pierremgi you mean i must place this trigger withount any condition and repeat "picked" ? :)

 

because i yeah i tried in local in placeing the trigger with the script, but when i came inside it didnt do anything :/

 

Your script work only on server ? or it work same in local ? :)

 

You script is awesome dude i really want use :(

Share this post


Link to post
Share on other sites

No, I corrected my post. When I said "without condition" it's condition always true in fact. In hosted server/clients, the trigger (edited in eden) works fine if you make it NOT repeatable (run once then loop) and "everywhere" That means server only UNCHECKED.

I don't understand your question at NeoArmageddon, btw.

Share this post


Link to post
Share on other sites

@pierremgi so my tragger should me like this ? 

 

https://www.hostingpics.net/viewer.php?id=927431201705061802171.jpg

 

And the question i ask is about Neo Armageddon is :

 

I want make the following scripts like >> "AAF_pilot_headhelmet" and "Rebreather" are needed or you die

if(headgear _x != "AAF_pilot_headhelmet") then {_x setdamage 1;};} foreach thislist;

and i want make this script repeating everytime ;) 

Share this post


Link to post
Share on other sites

Bro when you say true, you mean in condition i LITTERALLY write "true" ? i tried this it worked

 

i still have to try on the server :)

Share this post


Link to post
Share on other sites

For the trigger: No, don't make it repeatable. It's my fault.

So none,none, not repeatable, server only uncheked, cond: true and...

and modify the line::

while {alive _unit} do {

for:

while {alive _unit && local _unit} do {

Script corrected.

For your other question, if you read what i wrote, I gave you a script with an helmet + a rebreather. (B or I if you like).  And , of course, it's repeatable (loop).  So, after all these posts, I can't understand what you need more.

 

Share this post


Link to post
Share on other sites

how would this work with a marker instead of a triigger?

Share this post


Link to post
Share on other sites

just pass marker (must be an area) instead of thisTrigger:

{ [_x,"marker1"] spawn { _unit =_this select 0; _trg = _this select 1; private "_timer"; ....

then, change _trg for _mkr but everywhere, if you want something clean, but no mandatory (just a local variable)..

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

×