Tejkr 13 Posted March 24, 2018 I want to check, if a vehicle enters area (I will drive it and park it there and when the car is inside trigger, it will be true and switch the objective)... I've tried car in thislist, the car is named car, but it won't fire anyway... I had idea of something like "player in car AND player in thislist" but I think there must be easier way to check for object inside the trigger, isn't there? Share this post Link to post Share on other sites
HazJ 1289 Posted March 24, 2018 vehicle player in thislist !(vehicle player isKindOf "Man") && vehicle player in thislist varName in thislist Any of these? If you have more than one then you can use forEach / count command. Share this post Link to post Share on other sites
Tejkr 13 Posted March 24, 2018 My mistake, it was activated by no one, it detects the vehicle, when I changed the activation by blufor. I thought it isn't needed for a car check. Share this post Link to post Share on other sites
Grumpy Old Man 3547 Posted March 24, 2018 17 minutes ago, Tejkr said: My mistake, it was activated by no one, it detects the vehicle, when I changed the activation by blufor. I thought it isn't needed for a car check. Vehicles always will take the side of its occupants, otherwise enemy wouldn't fire at thrm, since editor placed empty vehicles count as civilian side. Cheers Share this post Link to post Share on other sites
Tankbuster 1747 Posted March 24, 2018 5 hours ago, Grumpy Old Man said: Vehicles always will take the side of its occupants, otherwise enemy wouldn't fire at thrm, since editor placed empty vehicles count as civilian side. Cheers https://community.bistudio.com/wiki/BIS_fnc_objectSide Can return the 'country of manufacture', ignoring the side of it's occupants. Share this post Link to post Share on other sites
Grumpy Old Man 3547 Posted March 24, 2018 43 minutes ago, Tankbuster said: https://community.bistudio.com/wiki/BIS_fnc_objectSide Can return the 'country of manufacture', ignoring the side of it's occupants. Would be neat if AI in arma actually worked that way. I mean seeing an MRAP of the opposing faction in the distance, with my trusty AT launcher on the back, I'd sure as heck not hesitate to blow it up, no matter if it's occupied or empty. Cheers Share this post Link to post Share on other sites
Tankbuster 1747 Posted March 24, 2018 21 minutes ago, Grumpy Old Man said: Would be neat if AI in arma actually worked that way. I mean seeing an MRAP of the opposing faction in the distance, with my trusty AT launcher on the back, I'd sure as heck not hesitate to blow it up, no matter if it's occupied or empty. Cheers Oh yes, it's frustrating them knowing from a distance of 1km+ that you and your NATO hommies have nicked the Ifrit you are currently in. I reported it as an issue back in 2008 - odd that they never picked it up. 2 Share this post Link to post Share on other sites
Grumpy Old Man 3547 Posted March 24, 2018 1 minute ago, Tankbuster said: Oh yes, it's frustrating them knowing from a distance of 1km+ that you and your NATO hommies have nicked the Ifrit you are currently in. I reported it as an issue back in 2008 - odd that they never picked it up. Would be a nice change gameplay wise, just imagine your average coop game, with some NATO folks capturing a Varsuk and heading back to the FOB without communicating an incoming friendly varsuk to the rest of the team. Even something as simple as a quick sitrep to your side (radio menu 5-5) would do the trick to reveal to friendly AI of the captured varsuk. Now it's just odd. Cheers 2 Share this post Link to post Share on other sites
HazJ 1289 Posted March 24, 2018 6 hours ago, Tankbuster said: Oh yes, it's frustrating them knowing from a distance of 1km+ that you and your NATO hommies have nicked the Ifrit you are currently in. I reported it as an issue back in 2008 - odd that they never picked it up. Are you feeling okay @Tankbuster? This is Bohemia Interactive + ArmA. 1 Share this post Link to post Share on other sites
Tejkr 13 Posted March 25, 2018 This is little off this topic, but what if I want to pick from a random radio masseges? I have this: this addEventHandler ["hitPart", {_randomElement = selectRandom [player sideChat "Good",player sideChat "Nice"]}]; It sends both messages at the same time. I'm just trying, can't script obviously, but what's wrong please? Share this post Link to post Share on other sites
Grumpy Old Man 3547 Posted March 25, 2018 1 hour ago, Tejkr said: This is little off this topic, but what if I want to pick from a random radio masseges? I have this: this addEventHandler ["hitPart", {_randomElement = selectRandom [player sideChat "Good",player sideChat "Nice"]}]; It sends both messages at the same time. I'm just trying, can't script obviously, but what's wrong please? You're trying to randomize code, which doesn't work the way you're using it. To randomize code you need something like this using strings and call compile: _randomElement = selectRandom ["player sideChat 'Good'","player sideChat 'Nice'"]; call compile _randomElement; or brackets and call: _randomElement = selectRandom [{player sideChat "Good"},{player sideChat "Nice"}]; call _randomElement; However this is a perfect example to always re-evaluate what you want to do, what to randomize and which elements will stay the same. Player won't change, sideChat won't change, but the text should be randomized. So it boils down to this: _randomComment = selectRandom ["Nice","Good"]; player sideChat _randomComment; Cheers 2 Share this post Link to post Share on other sites
PPPAnimal 5 Posted May 19, 2023 On 3/24/2018 at 9:34 AM, Grumpy Old Man said: Would be neat if AI in arma actually worked that way. I mean seeing an MRAP of the opposing faction in the distance, with my trusty AT launcher on the back, I'd sure as heck not hesitate to blow it up, no matter if it's occupied or empty. Cheers Hmmm, this has me thinking now. I have seen this done before. Not sure how they did it but you could try... getin eventhandler to check if in enemy vehicle and SETCAPTIVE 1 so ai will not shoot him. or enemyDetected eventhandler to trigger check if he is in friendly vehicle or wearing friendly unitform and setcaptive 1 if true then run checks using KnowsAboutChanged and when knowsabout > 2.5 or 4 etc. SETCAPTIVE 0 to make them fire at him. getout eventhandler could setcaptive 0 also. KnowsAboutChanged _group addEventHandler ["KnowsAboutChanged", { params ["_group", "_targetUnit", "_newKnowsAbout", "_oldKnowsAbout"]; }]; EnemyDetected _group addEventHandler ["EnemyDetected", { params ["_group", "_newTarget"]; }]; Share this post Link to post Share on other sites