Skip to content

Irritants (Smoke) - New Component#11220

Draft
BrettMayson wants to merge 32 commits intoacemod:masterfrom
BrettMayson:smoke
Draft

Irritants (Smoke) - New Component#11220
BrettMayson wants to merge 32 commits intoacemod:masterfrom
BrettMayson:smoke

Conversation

@BrettMayson
Copy link
Copy Markdown
Member

@BrettMayson BrettMayson commented Jan 7, 2026

When merged this pull request will:

  • Smoke effects when standing in particles that have blockAIVisibility
  • Blur and over expose vision
  • Affect spo2 breathing effectiveness
  • Adds eye and breathing protection to vanilla facewear, ace arsenal stat bars
  • Unrelated hemtt launch for ADT

Considerations:

  • Should this affect AI? Could be a setting, my concern would just be performance from a lot of AI. One possible optimization would be to first check if there is a smoke grenade in X meters, but that would cause other sources of smoke to stop working and I don't like that as a "solution"
  • Coughing sound effects? Would need to source audio

IMPORTANT

  • If the contribution affects the documentation, please include your changes in this pull request so the documentation will appear on the website.
  • Development Guidelines are read, understood and applied.
  • Title of this PR uses our standard template Component - Add|Fix|Improve|Change|Make|Remove {changes}.

Comment thread addons/smoke/functions/fnc_pfh.sqf Outdated
Comment thread addons/smoke/functions/fnc_pfh.sqf Outdated
Comment thread addons/smoke/functions/fnc_pfh.sqf Outdated
BrettMayson and others added 4 commits January 7, 2026 00:26
Co-authored-by: PabstMirror <pabstmirror@gmail.com>
Co-authored-by: PabstMirror <pabstmirror@gmail.com>
@BaerMitUmlaut
Copy link
Copy Markdown
Member

IMO a bit confusing to have a "smoke" addon that does not change the particles, though I can't think of a better name right now.

@Drofseh
Copy link
Copy Markdown
Contributor

Drofseh commented Jan 7, 2026

IMO a bit confusing to have a "smoke" addon that does not change the particles, though I can't think of a better name right now.

Should it go in the goggles addon where eyewear is already providing protection from other things?

Copy link
Copy Markdown
Contributor

@rautamiekka rautamiekka left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • Missing macros.
  • Inconsistent *_protection spellings.

Comment thread addons/smoke/functions/fnc_pfh.sqf Outdated
Comment thread addons/irritants/functions/fnc_smoke_pfh.sqf
Comment thread addons/smoke/functions/fnc_pfh.sqf Outdated
Comment thread addons/irritants/functions/fnc_smoke_pfh.sqf
Comment thread addons/smoke/initSettings.inc.sqf Outdated
Comment thread addons/smoke/initSettings.inc.sqf Outdated
@BrettMayson
Copy link
Copy Markdown
Member Author

Should it go in the goggles addon where eyewear is already providing protection from other things?

I agree that smoke is maybe not the best, but I also couldn't think of anything else that'd be better

I don't think this should go in goggles, just because while they are related to face wear, that's about it. There is no overlap in config, settings, or functionality.

Comment thread addons/irritants/functions/fnc_isInSmoke.sqf
@BrettMayson
Copy link
Copy Markdown
Member Author

BrettMayson commented Jan 12, 2026

After play testing this weekend, I found a problem with vehicles so I've just disabled it when inside one.

I also had someone get the smoke effect standing in a particular spot, so I'll debug that further this week. Otherwise everything seemed to work well

Solved

Comment thread addons/smoke/functions/fnc_pfh.sqf Outdated
Comment thread addons/smoke/functions/fnc_pfh.sqf Outdated
Comment thread addons/smoke/initSettings.inc.sqf Outdated
Comment thread addons/smoke/XEH_postInit.sqf Outdated
Comment thread addons/irritants/XEH_postInit.sqf
@PabstMirror
Copy link
Copy Markdown
Contributor

isInSmoke cost varies based on nearby objects
but in some cases was up to 0.3ms

I think it would be better to run this at a reduced interval instead of everyframe
5 per second should still be a smooth enough transition for the effects?

Co-authored-by: PabstMirror <pabstmirror@gmail.com>
Comment thread addons/smoke/functions/fnc_pfh.sqf Outdated
Comment thread addons/smoke/functions/fnc_pfh.sqf Outdated
Comment thread addons/smoke/functions/fnc_pfh.sqf Outdated
Comment thread addons/smoke/functions/fnc_isOpenSeat.sqf Outdated
Comment thread addons/smoke/initSettings.inc.sqf Outdated
Co-authored-by: PabstMirror <pabstmirror@gmail.com>
Copy link
Copy Markdown
Contributor

@PabstMirror PabstMirror left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

opps

Comment thread addons/smoke/functions/fnc_pfh.sqf Outdated
Comment thread addons/smoke/functions/fnc_pfh.sqf Outdated
Comment thread addons/smoke/initSettings.inc.sqf Outdated
Co-authored-by: PabstMirror <pabstmirror@gmail.com>
Comment thread addons/smoke/functions/fnc_isOpenSeat.sqf Outdated
@PabstMirror PabstMirror added the kind/feature Release Notes: **ADDED:** label Feb 20, 2026
@PabstMirror PabstMirror added this to the 3.21.0 milestone Feb 20, 2026
@BrettMayson
Copy link
Copy Markdown
Member Author

BrettMayson commented Feb 20, 2026

This has been working well for us, I think most false positives will be dealt with, but the actual time spent using it is still pretty low, just a few hours.

It is possible there could still be false positives, where the player gets themself into some positioning with terrain, grass, etc. that causes it to think they're in smoke and apply the affect.

@OverlordZorn
Copy link
Copy Markdown
Contributor

OverlordZorn commented Feb 22, 2026

Immersion cigs rewrite has cough sounds from the dayz mod uner apl-sa.

Coughing sound effects:
https://github.com/CVO-Org/immersion-cigs-rewrite/blob/main/addons/core/CfgSounds.hpp#L93-L96
https://github.com/CVO-Org/immersion-cigs-rewrite/tree/main/addons/core/data/sounds

The code for it can be found under core/fnc/adv_fatigue
https://github.com/CVO-Org/immersion-cigs-rewrite/blob/main/addons/core/functions/adv_fatigue/fn_cough.sqf

There's even something in there that alerts enemies of you presense if thats of interest.

@OverlordZorn
Copy link
Copy Markdown
Contributor

Maybe I missed it when scanning over the code, but is there an API way to add "exposure" to a unit?

I would prefer to avoid having to overwrite the actual value each frame but if i could add a baseline that would be great.

Maybe a similar system like the dutyFactor of advanced_fatigue?

@Drofseh
Copy link
Copy Markdown
Contributor

Drofseh commented Mar 7, 2026

I still don't love calling this addon smoke, how do you feel about irritants or something like that?

@BrettMayson BrettMayson changed the title Smoke - New Component Irritants (Smoke) - New Component Mar 20, 2026
Comment thread addons/compat_cup_units/compat_cup_smoke/CfgGlasses.hpp Outdated
@PabstMirror PabstMirror modified the milestones: 3.21.0, 3.21.1 Mar 25, 2026
@BrettMayson BrettMayson marked this pull request as draft March 25, 2026 11:06
@BrettMayson
Copy link
Copy Markdown
Member Author

Has problems with tall grass on CUP maps

@PabstMirror
Copy link
Copy Markdown
Contributor

I had an idea to scan for nearby ammo to determine the type of smoke
(vehicle IR-blocking smoke being much more toxic and having a stronger effect)
scan for nearest smoke ammo, 10m upwind
could use something like that and say if no ammo found then it must be false positive

could also scan at minimum of 3m above ground level, that should clear most foliage

@Drofseh
Copy link
Copy Markdown
Contributor

Drofseh commented Mar 28, 2026

I had an idea to scan for nearby ammo to determine the type of smoke (vehicle IR-blocking smoke being much more toxic and having a stronger effect) scan for nearest smoke ammo, 10m upwind could use something like that and say if no ammo found then it must be false positive

could also scan at minimum of 3m above ground level, that should clear most foliage

Ammo can have config event handlers.
Could use fired to have the ammo put itself in a list after a couple seconds. Then check the distance and direction to the the position of each ammo.
If with X degrees of wind direction and within Y m * wind speed apply effects. Maybe stronger the closer the player is.
That would allow for different ammo to have different effects as well.

https://community.bistudio.com/wiki/Arma_3:_Event_Handlers#Ammo_Config_Events

@PabstMirror PabstMirror modified the milestones: 3.21.1, Ongoing Apr 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

kind/feature Release Notes: **ADDED:**

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants