mr_shadow 4 Posted May 24, 2014 Hello, i would like to know how can i do the BIS_fnc_MP but the target should not be player? for example if i will look at my legs i will become a target so i would like the other player exec BIS_fnc_MP. _trg = cursorTarget ; _trg2 = (player != _trg) [[_trg2 ], "knock", _trg2 , false] spawn BIS_fnc_MP; Share this post Link to post Share on other sites
TittErS 13 Posted May 24, 2014 You can target you with cursorTarget ? me i can not ... 1 Share this post Link to post Share on other sites
mr_shadow 4 Posted May 24, 2014 _trg2= _trg && (player != _trg) ; This doesn't work as well. Share this post Link to post Share on other sites
f2k sel 164 Posted May 24, 2014 Me either, you could always do a distance check. _trg = cursorTarget ; if (_trg distance >1 ) then { [[_trg ], "knock", _trg , false] spawn BIS_fnc_MP}; Share this post Link to post Share on other sites
mr_shadow 4 Posted May 24, 2014 Well the why i don't like it, but when i tryed to dtect is ther is player nerby it also didn't work. Share this post Link to post Share on other sites
f2k sel 164 Posted May 24, 2014 There is also the isplayer command Share this post Link to post Share on other sites
mr_shadow 4 Posted May 24, 2014 _primarywep = weapons player; _primarywep2 = _primarywep select 0; _trg = cursorTarget ; if !(_primarywep2 == "<null>") then { player switchMove "AwopPercMstpSgthWnonDnon_end"; if (_trg distance >1 ) then { [[_trg ], "knock", _trg , false] spawn BIS_fnc_MP }; }; Is there a spelling mistake? is that possible to do something like this? _near = nearestObjects [player, ["MAN"], 3]; _trg = _near select 0;; Share this post Link to post Share on other sites
Lala14 135 Posted May 24, 2014 knock is not defined, unless I am missing something. Plus why don't you use Tajin's script? Share this post Link to post Share on other sites
mr_shadow 4 Posted May 24, 2014 Thats not the thing i need. knock.sqf disableUserInput true; player playMoveNow "CutSceneAnimationBaseZoZo"; player switchMove "acts_InjuredAngryRifle01"; player globalchat "You have been knocked out!"; sleep 5; disableUserInput false; player switchMove "AinvPknlMstpSnonWnonDnon_medic_1"; player globalchat "Press V then move"; Init.sqf knock = compile preprocessFileLineNumbers "knock.sqf"; Share this post Link to post Share on other sites
mr_shadow 4 Posted May 24, 2014 with a cursortarget i can do it from 1km away, i need to define it like with the player around about 4m, any ideas? ---------- Post added at 21:33 ---------- Previous post was at 20:34 ---------- Solved. _primarywep = weapons player; _primarywep2 = _primarywep select 0; _trg = cursortarget; dist_1=player distance _trg; if !(_primarywep2 == "") then { if (dist_1 < 3) then { [[_trg ], "knock", _trg , false] spawn BIS_fnc_MP; }; }; Share this post Link to post Share on other sites
Nemanjic 71 Posted October 10, 2022 Hello everyone. Is there a way to run a script on the cursor target? Situation: The enemy soldier is captive with the ace system but he is under the cache of the GAIA script (group this) setVariable ["mcc_gaia_cache",true, true]; and still refers to the enemy command when is captured so artillery and other enemy forces knows about every opposite units around captured one, sending forces to conflict area and fire artillery also. My question is if I can set gaia cache to false with some kind of addAction or using debug console in that cases on cursor targets so captured unit stop being cached anymore once he is captured? For now, I use sub system with zeus to get to units "soul" and there I put code (group this) setVariable ["mcc_gaia_cache",false, false]; but that is much plastic way and lot of unrealistic surgery. My hopes are with cursor target set the cache to false bla bla but I can't be smart enough for this. Thanks in advance I hope I am explained well what I need... Share this post Link to post Share on other sites