Evilhardt
Member-
Content Count
91 -
Joined
-
Last visited
-
Medals
Everything posted by Evilhardt
-
check if has been KILLED (not !alive)
Evilhardt posted a topic in ARMA 3 - MISSION EDITING & SCRIPTING
So I have a group of units all of which have a probability of presence. I want a trigger to fire if one of those units has been killed. I I use "!alive unit_1 OR !alive unit_2 OR... ...!alive unit_n" the trigger wo#'t work if one of those units has not even spawned to begin with because of probability of presence... How can I check if a unit actually has ben KILLED rather than is not alive? -
check if has been KILLED (not !alive)
Evilhardt replied to Evilhardt's topic in ARMA 3 - MISSION EDITING & SCRIPTING
Thanks a lot! -
check if has been KILLED (not !alive)
Evilhardt replied to Evilhardt's topic in ARMA 3 - MISSION EDITING & SCRIPTING
Thanks. @ mariodu62: In my case it is not a group of units. They're all single units, since I have placed them at specific locatiosn and when they are grouped they will immediately leave those positions to regroup with their leader. @ Larrow: I see. I tried to implement your script like this: { !(isNull _x) && { (!alive _x) AND (alive flareGuy) } } count [s1, S2, S3, S4, S5, S6, S7] == 0; So, I have units S1 through S7 and the unit flareGuy. I want the flareGuy to launch a flare if one member of the set {S1, S2, S3, S4, S5, S6, S7} has been killed and he himslef is still alive. So, I ave put that into the condition field of the trigger that also launches the flare. But nothing happens once I replace the old condition with the one above and one member of the set is killed. Only once I also kill flareGuy the trigger fires... ?? But it explicitly say !alive _x AND alive flareGuy. What am I doing wrong? :/ -
How do I stop AI from moving, but still rotate to shoot?
Evilhardt replied to Drumheller's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
No, I made a mistake. It is working indeed. Thank you. -
How do I stop AI from moving, but still rotate to shoot?
Evilhardt replied to Drumheller's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Ah I see! Thx. The forcespeed 0 is a good idea, but the units will move a few steps from their spot anyway, which is already too much for my case. -
How do I stop AI from moving, but still rotate to shoot?
Evilhardt replied to Drumheller's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Old thread, I know. But anyways. I got the same issue and the above code doesn't work for me... When I put it in a game logic object I get a syntax error with no text. So I put it in a SQF and called that through the init.sqf posSniper = getPos sniper; while {true} do {setPos sniper posSniper; sleep 0.25; }; posARM = getPos ARM; while {true} do {setPos ARM posARM; sleep 0.25; }; This looks completely fine and logical to me but it does nothing. -
Thx, I used talk waypoints with LockWP now.
-
So, I got a seek and destroy waypoint for 2 units (unit1, unit2). I got a game logic object in which I put: unit1 lockWP true; unit2 lockWP true; And I got a trigger that fires when some unit of another group is not alive. In that trigger's OnAct I put: unit1 lockWP false; unit2 lockWP false; So what I want is, that the two units start moving only once the trigger fired. But they start moving right away, without the trgger havig fired. Can somebody explain to me why that is? :/
-
Thanks. I thout lockWP would work around this stupid thing with units only stopping from progressing through WPs... oh well. The thing is I have these units spawned in certain postures guarding another location. Is it possible to let them get into that posture also when reaching the initial waypoint through the activation filed of teh waypoint? Or do I need a new trigger and stuff just for that?
-
Hi, I need to find a way to force units without weapons to walk at the speed of units with weapons. The latter walk more slowly than the former which causes the squads cohesion to break apart. Is there a way to fix this? The situation is that I have a patrolling team. One of the bots has all weaposn removed and a camping lantern attached to his hand. He needs to be the leader of the squad, because if he isn't his pathfining will go nuts and he will teleport all over the place because of the lantern. But him being leader causes the other guys to lose cohesion, becuause their walking speed (limited) is slower than the lantern-guy's. I have already experimented with forceSpeed with no success. Any other idea on how to work around this issue? :/ ---------- Post added at 01:35 ---------- Previous post was at 23:47 ---------- So, a rather meh-ish workaround I came up with was to put the bots weapons into their backpacks. But now they won't take them out when attacked... is there a "takeFromBackpack" command?
-
Equalize infantry speeds
Evilhardt replied to Evilhardt's topic in ARMA 3 - MISSION EDITING & SCRIPTING
Thanks. I have tried your speed levels and I think they are good enough. I tried adjusting them to get an even better fit, but those are indded the closest you get it seems. -
Equalize infantry speeds
Evilhardt replied to Evilhardt's topic in ARMA 3 - MISSION EDITING & SCRIPTING
As I said, I have already used forceSpeed. It does not slow him down the way needed. Speed of 0 he does not walk at all. Speed of 0.1 he does not walk at all either, 0.3 he walks just as quick as if there was no modifier. When I set the other guys' speed to 2, they are still as slow as if there was no modifier. When I set it to 3 they will run a few meters then hold and wait. Then run a few meters again and hold and wait... the cohesion is kept up this way but it looks retarded. I want them to move in a chilled manner. @Squeeze: I guess I'll have to try this in lack of more elegant solutions :D -
Define Unit Inits through SQF
Evilhardt replied to Evilhardt's topic in ARMA 3 - MISSION EDITING & SCRIPTING
Thanks, it woks now. Unfortunately in MP it causes the underwear bug. Even though up to now I was merely assigning the exact same uniform I had removed beforehand. -
Hey, I'd like to define the inits of all my enemy units through a script. As a test I set up this bit of code inside the init.sqf: { if (side _x == East) then { _x setVehicleInit "this allowdamage false;"; }; } forEach allUnits; It does not work though and I think this is, because _x is not defined a a unit or an object. How could I solve this issue? Thx
-
Define Unit Inits through SQF
Evilhardt replied to Evilhardt's topic in ARMA 3 - MISSION EDITING & SCRIPTING
Cool, thx. Here is the current state of the script, just to make sure: { helmet = [1, 2, 3] call BIS_fnc_selectRandom; uniform = [1, 2, 3] call BIS_fnc_selectRandom; vest = [1, 2, 3] call BIS_fnc_selectRandom; face = [1, 2, 3] call BIS_fnc_selectRandom; //check side of unit if (side _x == east) then { //remove all items and clothes removeallweapons _x; removevest _x; removeuniform _x; removeheadgear _x; removeallassigneditems _x; _x removeweapon 'NVGoggles_OPFOR'; //check if AR dude if (typeOf _x == "O_Soldier_F") then { //assign helmet switch (helmet) do { case 1: { _x addHeadgear 'H_HelmetSpecO_ocamo'; }; case 2: { _x addHeadgear 'H_MilCap_rucamo'; }; case 3: { }; }; //assign uniform switch (uniform) do { case 1: { _x addUniform 'U_O_CombatUniform_ocamo'; }; // options for more different uniforms case 2: { _x addUniform 'U_O_CombatUniform_ocamo'; }; case 3: { _x addUniform 'U_O_CombatUniform_ocamo'; }; }; //assign vest switch (vest) do { case 1: { _x addVest 'V_PlateCarrier1_blk'; }; case 2: { _x addVest 'V_HarnessO_brn'; }; case 3: { _x addVest 'V_HarnessOGL_brn'; }; }; //assign face switch (face) do { case 1: { _x setFace 'PersianHead_A3_01'; }; case 2: { _x setFace 'PersianHead_A3_02'; }; case 3: { _x setFace 'PersianHead_A3_03'; }; }; //add non-randomized AR dude specific items _x addmagazines["30Rnd_65x39_caseless_green",7]; _x addWeapon 'arifle_Katiba_ACO_pointer_F'; }; //check if LMG dude if (typeOf _x == "O_soldier_M_F") then { //assign helmet switch (helmet) do { case 1: { _x addHeadgear 'H_HelmetSpecO_ocamo'; }; case 2: { _x addHeadgear 'H_MilCap_rucamo'; }; case 3: { }; }; //assign uniform switch (uniform) do { case 1: { _x addUniform 'U_O_CombatUniform_ocamo'; }; case 2: { _x addUniform 'U_O_CombatUniform_ocamo'; }; case 3: { _x addUniform 'U_O_CombatUniform_ocamo'; }; }; //assign vest switch (vest) do { case 1: { _x addVest 'V_PlateCarrier1_blk'; }; case 2: { _x addVest 'V_HarnessO_brn'; }; case 3: { _x addVest 'V_HarnessOGL_brn'; }; }; //assign face switch (face) do { case 1: { _x setFace 'PersianHead_A3_01'; }; case 2: { _x setFace 'PersianHead_A3_02'; }; case 3: { _x setFace 'PersianHead_A3_03'; }; }; //add non-randomized LMG dude specific items _x addmagazines["150Rnd_762x51_Box_Tracer",3]; _x addWeapon 'LMG_Zafir_F'; }; //add non-randomized general items _x addPrimaryWeaponItem 'optic_Arco'; _x addmagazines["16Rnd_9x21_Mag",3]; _x addWeapon 'hgun_Rook40_F'; _x addPrimaryWeaponItem "acc_flashlight"; {_x enableGunLights "forceon"} foreach units group _x; _x addEventHandler ["FiredNear",{[_this,_this select 1] execVM "snd.sqf";}]; }; } forEach allUnits; -
Define Unit Inits through SQF
Evilhardt replied to Evilhardt's topic in ARMA 3 - MISSION EDITING & SCRIPTING
After your last post I already had put the classnames into strings. There is some other issue. But I just don't see it. -
Define Unit Inits through SQF
Evilhardt replied to Evilhardt's topic in ARMA 3 - MISSION EDITING & SCRIPTING
Ah, thx. I still get syntax errors though. It says unexpected ) at line 39. But the only ) are the ones around the variables after the switch commands and the ones around the if heads. -
Define Unit Inits through SQF
Evilhardt replied to Evilhardt's topic in ARMA 3 - MISSION EDITING & SCRIPTING
@ Igneous01: Thanks for the detailed explanation. So, I now tried to refine my script as follows, but it does not work :/ First of all I am getting syntax errors. The first for line 31. Secondly, I don't know if the way I am checking for the classname of the unit is actually correct. { helmet = [1, 2, 3] call BIS_fnc_selectRandom; uniform = [1, 2, 3] call BIS_fnc_selectRandom; vest = [1, 2, 3] call BIS_fnc_selectRandom; face = [1, 2, 3] call BIS_fnc_selectRandom; //check side of unit if (side _x == east) then { //remove all items and clothes removeallweapons _x; removevest _x; removeuniform _x; removeheadgear _x; removeallassigneditems _x; _x removeweapon "NVGoggles_OPFOR"; //check if AR dude if (_x == O_Soldier_F) then { //assign helmet switch (helmet) do { case 1: { _x addHeadgear 'H_HelmetSpecO_ocamo'; }; case 2: { _x addHeadgear 'H_MilCap_rucamo'; }; case 3: { }; }; //assign uniform switch (uniform) do { case 1: { _x addUniform 'U_O_CombatUniform_ocamo'; }; // options for more different uniforms case 2: { _x addUniform 'U_O_CombatUniform_ocamo'; }; case 3: { _x addUniform 'U_O_CombatUniform_ocamo'; }; }; //assign vest switch (vest) do { case 1: { _x addVest 'V_PlateCarrier1_blk'; }; case 2: { _x addVest 'V_HarnessO_brn'; }; case 3: { _x addVest 'V_HarnessOGL_brn'; }; }; //assign face switch (face) do { case 1: { _x setFace 'PersianHead_A3_01'; }; case 2: { _x setFace 'PersianHead_A3_02'; }; case 3: { _x setFace 'PersianHead_A3_03'; }; }; //add non-randomized AR dude specific items _x addmagazines["30Rnd_65x39_caseless_green",7]; _x addWeapon 'arifle_Katiba_ACO_pointer_F'; }; //check if LMG dude if (_x == O_soldier_M_F) then { //assign helmet switch (helmet) do { case 1: { _x addHeadgear 'H_HelmetSpecO_ocamo'; }; case 2: { _x addHeadgear 'H_MilCap_rucamo'; }; case 3: { }; }; //assign uniform switch (uniform) do { case 1: { _x addUniform 'U_O_CombatUniform_ocamo'; }; case 2: { _x addUniform 'U_O_CombatUniform_ocamo'; }; case 3: { _x addUniform 'U_O_CombatUniform_ocamo'; }; }; //assign vest switch (vest) do { case 1: { _x addVest 'V_PlateCarrier1_blk'; }; case 2: { _x addVest 'V_HarnessO_brn'; }; case 3: { _x addVest 'V_HarnessOGL_brn'; }; }; //assign face switch (face) do { case 1: { _x setFace 'PersianHead_A3_01'; }; case 2: { _x setFace 'PersianHead_A3_02'; }; case 3: { _x setFace 'PersianHead_A3_03'; }; }; //add non-randomized LMG dude specific items _x addmagazines["150Rnd_762x51_Box_Tracer",3]; _x addWeapon 'LMG_Zafir_F'; }; //add non-randomized general items _x addPrimaryWeaponItem 'optic_Arco'; _x addmagazines["16Rnd_9x21_Mag",3]; _x addWeapon 'hgun_Rook40_F'; _x addPrimaryWeaponItem "acc_flashlight"; {_x enableGunLights "forceon"} foreach units group _x; _x addEventHandler ["FiredNear",{[_this,_this select 1] execVM "snd.sqf";}]; }; } forEach allUnits; After looking a little further I dound "typeof vehicle" and put it into my script, but it's still not working. { helmet = [1, 2, 3] call BIS_fnc_selectRandom; uniform = [1, 2, 3] call BIS_fnc_selectRandom; vest = [1, 2, 3] call BIS_fnc_selectRandom; face = [1, 2, 3] call BIS_fnc_selectRandom; //check side of unit if (side _x == east) then { _y = str (typeof vehicle (_this select 0)); //remove all items and clothes removeallweapons _x; removevest _x; removeuniform _x; removeheadgear _x; removeallassigneditems _x; _x removeweapon 'NVGoggles_OPFOR'; //check if AR dude if (_y == O_Soldier_F) then { //assign helmet switch (helmet) do { case 1: { _x addHeadgear 'H_HelmetSpecO_ocamo'; }; case 2: { _x addHeadgear 'H_MilCap_rucamo'; }; case 3: { }; }; //assign uniform switch (uniform) do { case 1: { _x addUniform 'U_O_CombatUniform_ocamo'; }; // options for more different uniforms case 2: { _x addUniform 'U_O_CombatUniform_ocamo'; }; case 3: { _x addUniform 'U_O_CombatUniform_ocamo'; }; }; //assign vest switch (vest) do { case 1: { _x addVest 'V_PlateCarrier1_blk'; }; case 2: { _x addVest 'V_HarnessO_brn'; }; case 3: { _x addVest 'V_HarnessOGL_brn'; }; }; //assign face switch (face) do { case 1: { _x setFace 'PersianHead_A3_01'; }; case 2: { _x setFace 'PersianHead_A3_02'; }; case 3: { _x setFace 'PersianHead_A3_03'; }; }; //add non-randomized AR dude specific items _x addmagazines["30Rnd_65x39_caseless_green",7]; _x addWeapon 'arifle_Katiba_ACO_pointer_F'; }; //check if LMG dude if (_y == O_soldier_M_F) then { //assign helmet switch (helmet) do { case 1: { _x addHeadgear 'H_HelmetSpecO_ocamo'; }; case 2: { _x addHeadgear 'H_MilCap_rucamo'; }; case 3: { }; }; //assign uniform switch (uniform) do { case 1: { _x addUniform 'U_O_CombatUniform_ocamo'; }; case 2: { _x addUniform 'U_O_CombatUniform_ocamo'; }; case 3: { _x addUniform 'U_O_CombatUniform_ocamo'; }; }; //assign vest switch (vest) do { case 1: { _x addVest 'V_PlateCarrier1_blk'; }; case 2: { _x addVest 'V_HarnessO_brn'; }; case 3: { _x addVest 'V_HarnessOGL_brn'; }; }; //assign face switch (face) do { case 1: { _x setFace 'PersianHead_A3_01'; }; case 2: { _x setFace 'PersianHead_A3_02'; }; case 3: { _x setFace 'PersianHead_A3_03'; }; }; //add non-randomized LMG dude specific items _x addmagazines["150Rnd_762x51_Box_Tracer",3]; _x addWeapon 'LMG_Zafir_F'; }; //add non-randomized general items _x addPrimaryWeaponItem 'optic_Arco'; _x addmagazines["16Rnd_9x21_Mag",3]; _x addWeapon 'hgun_Rook40_F'; _x addPrimaryWeaponItem "acc_flashlight"; {_x enableGunLights "forceon"} foreach units group _x; _x addEventHandler ["FiredNear",{[_this,_this select 1] execVM "snd.sqf";}]; }; } forEach allUnits; -
Define Unit Inits through SQF
Evilhardt replied to Evilhardt's topic in ARMA 3 - MISSION EDITING & SCRIPTING
Ah, so that is more efficient. ok, cool. Thanks. Btw, does the floor thing make an integer of the floating point? -
Define Unit Inits through SQF
Evilhardt replied to Evilhardt's topic in ARMA 3 - MISSION EDITING & SCRIPTING
Cool :) Though I just solved my issue... I had already switched off the PC and was brushing my teeth...^^ but then it occured tro me. I had the numbers in the wrong order. As 6,99999 is the biggest possible all get overwritten when I start with < 1. -
Define Unit Inits through SQF
Evilhardt replied to Evilhardt's topic in ARMA 3 - MISSION EDITING & SCRIPTING
That's why :/ ok, thx. I now tried to build a script that assigned units one of 7 loadouts in a random fashion. But for some reason only the last if-statement and it's block get executed. { _randLO = random 8; if (_randLO < 1) then { if (side _x == East) then { _x addPrimaryWeaponItem "acc_flashlight"; {_x enableGunLights "forceon"} foreach units group _x; _x addHeadgear 'H_HelmetSpecO_ocamo'; _x addEventHandler ["FiredNear",{[_this,_this select 1] execVM "snd.sqf";}]; _x unassignitem "NVGoggles_OPFOR"; _x removeitem "NVGoggles_OPFOR"; _x addVest 'V_PlateCarrier1_blk'; _x addUniform 'U_O_CombatUniform_ocamo'; _x addmagazines["30Rnd_65x39_caseless_green",7]; _x addWeapon 'arifle_Katiba_ACO_pointer_F'; _x addPrimaryWeaponItem 'optic_Arco'; _x addmagazines["16Rnd_9x21_Mag",3]; _x addWeapon 'hgun_Rook40_F'; _x setFace 'PersianHead_A3_01'; }; }; if (_randLO < 2) then { if (side _x == East) then { _x addPrimaryWeaponItem "acc_flashlight"; {_x enableGunLights "forceon"} foreach units group _x; _x addHeadgear 'H_MilCap_rucamo'; _x addEventHandler ["FiredNear",{[_this,_this select 1] execVM "snd.sqf";}]; _x unassignitem "NVGoggles_OPFOR"; _x removeitem "NVGoggles_OPFOR"; _x addVest 'V_HarnessO_brn'; _x addUniform 'U_O_CombatUniform_ocamo'; _x addmagazines["30Rnd_65x39_caseless_green",7]; _x addWeapon 'arifle_Katiba_ACO_pointer_F'; _x addPrimaryWeaponItem 'optic_Arco'; _x addmagazines["16Rnd_9x21_Mag",3]; _x addWeapon 'hgun_Rook40_F'; _x setFace 'PersianHead_A3_02'; }; }; if (_randLO < 3) then { if (side _x == East) then { _x addPrimaryWeaponItem "acc_flashlight"; {_x enableGunLights "forceon"} foreach units group _x; _x addHeadgear 'H_HelmetSpecO_ocamo'; _x addEventHandler ["FiredNear",{[_this,_this select 1] execVM "snd.sqf";}]; _x unassignitem "NVGoggles_OPFOR"; _x removeitem "NVGoggles_OPFOR"; _x addVest 'V_HarnessOGL_brn'; _x addUniform 'U_O_CombatUniform_ocamo'; _x addmagazines["30Rnd_65x39_caseless_green",7]; _x addWeapon 'arifle_Katiba_ACO_pointer_F'; _x addPrimaryWeaponItem 'optic_Arco'; _x addmagazines["16Rnd_9x21_Mag",3]; _x addWeapon 'hgun_Rook40_F'; _x setFace 'PersianHead_A3_03'; }; }; if (_randLO < 4) then { if (side _x == East) then { _x addPrimaryWeaponItem "acc_flashlight"; {_x enableGunLights "forceon"} foreach units group _x; removeHeadgear _x; _x addEventHandler ["FiredNear",{[_this,_this select 1] execVM "snd.sqf";}]; _x unassignitem "NVGoggles_OPFOR"; _x removeitem "NVGoggles_OPFOR"; _x addVest 'V_HarnessO_brn'; _x addUniform 'U_O_CombatUniform_ocamo'; _x addmagazines["30Rnd_65x39_caseless_green",7]; _x addWeapon 'arifle_Katiba_ACO_pointer_F'; _x addPrimaryWeaponItem 'optic_Arco'; _x addmagazines["16Rnd_9x21_Mag",3]; _x addWeapon 'hgun_Rook40_F'; _x setFace 'PersianHead_A3_01'; }; }; if (_randLO < 5) then { if (side _x == East) then { _x addPrimaryWeaponItem "acc_flashlight"; {_x enableGunLights "forceon"} foreach units group _x; removeHeadgear _x; _x addEventHandler ["FiredNear",{[_this,_this select 1] execVM "snd.sqf";}]; _x unassignitem "NVGoggles_OPFOR"; _x removeitem "NVGoggles_OPFOR"; _x addVest 'V_HarnessOGL_brn'; _x addUniform 'U_O_CombatUniform_ocamo'; _x addmagazines["30Rnd_65x39_caseless_green",7]; _x addWeapon 'arifle_Katiba_ACO_pointer_F'; _x addPrimaryWeaponItem 'optic_Arco'; _x addmagazines["16Rnd_9x21_Mag",3]; _x addWeapon 'hgun_Rook40_F'; _x setFace 'PersianHead_A3_02'; }; }; if (_randLO < 6) then { if (side _x == East) then { _x addPrimaryWeaponItem "acc_flashlight"; {_x enableGunLights "forceon"} foreach units group _x; removeHeadgear _x; _x addEventHandler ["FiredNear",{[_this,_this select 1] execVM "snd.sqf";}]; _x unassignitem "NVGoggles_OPFOR"; _x removeitem "NVGoggles_OPFOR"; _x addVest 'V_PlateCarrier1_blk'; _x addUniform 'U_O_CombatUniform_ocamo'; _x addmagazines["30Rnd_65x39_caseless_green",7]; _x addWeapon 'arifle_Katiba_ACO_pointer_F'; _x addPrimaryWeaponItem 'optic_Arco'; _x addmagazines["16Rnd_9x21_Mag",3]; _x addWeapon 'hgun_Rook40_F'; _x setFace 'PersianHead_A3_03'; }; }; if (_randLO < 7) then { if (side _x == East) then { _x addPrimaryWeaponItem "acc_flashlight"; {_x enableGunLights "forceon"} foreach units group _x; removeHeadgear _x; _x addEventHandler ["FiredNear",{[_this,_this select 1] execVM "snd.sqf";}]; _x unassignitem "NVGoggles_OPFOR"; _x removeitem "NVGoggles_OPFOR"; _x addVest 'V_PlateCarrier1_blk'; _x addUniform 'U_O_CombatUniform_ocamo'; _x addmagazines["30Rnd_65x39_caseless_green",7]; _x addWeapon 'arifle_Katiba_ACO_pointer_F'; _x addPrimaryWeaponItem 'optic_Arco'; _x addmagazines["16Rnd_9x21_Mag",3]; _x addWeapon 'hgun_Rook40_F'; _x setFace 'PersianHead_A3_03'; }; }; } forEach allUnits; Any idea why that is? -
Define Unit Inits through SQF
Evilhardt replied to Evilhardt's topic in ARMA 3 - MISSION EDITING & SCRIPTING
It does, thx. But I don't understand why setVehicleInit caused an error. -
Hi, I'd like to adjust the brightess of chemlights I have spawned via createVehicle and attached to bots. I find them to be too bright and would like to dim them quite a bit. Is this somehow possible?
-
Adjust Cemlight Brigntness
Evilhardt replied to Evilhardt's topic in ARMA 3 - MISSION EDITING & SCRIPTING
Well I think it has very different lighting characteristics compared to chemlights. Chemlights lit area is smaller but brighter and has less a soft edge to it. The lightintensity to radisu curve is very steep for chemlights with a very strong increase towards radius = 0. While the lightpoint has a very flat curve. And there are no parameters to define the steepness of of the curve for teh lightpoint. What I wanted was a very small radius with a very steep curve. I wanted the chemlights to look as they do when they fire up for the whole duration of their life. Look here: Basically I want a light source, that casts no actual light on it's sourrounding but only glows itself. But if the amount of casted light was only small comapred to the glowing itself that would do too. -
removeAction via SQF?
Evilhardt replied to Evilhardt's topic in ARMA 3 - MISSION EDITING & SCRIPTING
EDIT: NEVER MIND, I SOLVED IT. I now tried to do this with lightpoints, which worked well. Then I tried to do more than one color. And I don't get this to work. I got this: init: _me = player; _red = _me addAction["personal light on red","light_on_red.sqf", [], 10, FALSE]; _me setVariable ["red", _red]; _blue = _me addAction["personal light on blue","light_on_blue.sqf", [], 10, FALSE]; _me setVariable ["blue", _blue]; light_on_red: _me = player; light="#lightpoint" createVehicle [0,0,4]; light setLightIntensity 200; light setLightAmbient [1,0,0]; light setLightColor [1,1,0.5]; light lightAttachObject [_me,[0,0,1]]; _off = _me addAction["personal light off","light_off.sqf", [], 10, FALSE]; _me removeAction (_this select 2); _blue = _me getVariable "blue"; _me removeAction _blue; light_on_blue: _me = player; light="#lightpoint" createVehicle [0,0,4]; light setLightIntensity 200; light setLightAmbient [0,0,1]; light setLightColor [1,1,1]; light lightAttachObject [_me,[0,0,1]]; _off = _me addAction["personal light off","light_off.sqf", [], 10, FALSE]; _me removeAction (_this select 2); _red = _me getVariable "red"; _me removeAction _red; light_off: _me = player; deleteVehicle light; _red = _me addAction["personal light on red","light_on_red.sqf", [], 10, FALSE]; _blue = _me addAction["personal light on blue","light_on_blue.sqf", [], 10, FALSE]; _me removeAction (_this select 2); But it only ever works once. So I can say "blue" and the red and the blue option will go away, the off action appear and the blue light go live. Then I say "off" and the other two options appear and the light goes off. So far so good. But when I now say either "blue" or "red" there will be "off" + the corresponding other option. Why does this work only once? EDIT: NEVER MIND, I SOLVED IT.