-
OK, I'm trying to do things to just people who do not have a gasmask on. ***In fire.sqs I have it so it should run effect.sqs for each person in the trigger. ***I'm pretty sure that works. ***The problem seems to be with effects.sqs. ***No one in my squad has a gas mask, and it doesn't injure or allowfleeing 1 or set the skill level lower for anyone in my squad. ***I believe the weapon name is correct too, since I only cough when I don't have a gasmask. ***There are no errors that show up ingame.
part of fire.sqs
<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">#close
;Units Immediately Effected
~random 2
? (player distance spot2<=50 AND not(player hasweapon "edc_gasmask")):cutText ["", "black faded",random 0.3] AND player say "chokekio";
;"_x setdammage(damage _x+random 0.2)" foreach List small;
;"_x allowfleeing 1" foreach List small;
;"_x setskill (skill _x)/10" foreach List small;
effects="effects.sqs";
"[_x] exec effects" foreach List small;
;"?(not(_x hasweapon 'edc_gasmask')):_x allowfleeing 1" foreach List small;
;"?(not(_x hasweapon 'edc_gasmask')):_x setskill (skill _x/10)" foreach List small;
;? _end >= 30:goto "medi";
_end=_end+1;
goto "close"
[/QUOTE]
all of effects.sqs
<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">
_unit=_this select 0
if(not(_unit hasweapon "edc_gasmask"))then{_unit setdammage(damage _x+random 0.2);hint
"SetDammage"};
if(not(_unit hasweapon "edc_gasmask"))then{_unit allowfleeing 1;hint "Allow Fleeing"};
if(not(_unit hasweapon "edc_gasmask"))then{_unit setskill ((skill_unit)/10);hint "SetSkill"};
[/QUOTE]
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules