Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AI - Add automatic NVG equip/unequip #9313

Merged
merged 15 commits into from
Sep 5, 2023
Merged

AI - Add automatic NVG equip/unequip #9313

merged 15 commits into from
Sep 5, 2023

Conversation

jonpas
Copy link
Member

@jonpas jonpas commented Aug 8, 2023

When merged this pull request will:

  • Adds functionality (disabled by default) where AI will get NVG automatically assigned during night time and unassigned during day time.

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}.

Better naming ideas welcome.

@jonpas jonpas added the kind/feature Release Notes: **ADDED:** label Aug 8, 2023
addons/ai/functions/fnc_assignNVG.sqf Outdated Show resolved Hide resolved
addons/ai/initSettings.sqf Outdated Show resolved Hide resolved
addons/ai/initSettings.sqf Outdated Show resolved Hide resolved
addons/ai/functions/fnc_assignNVG.sqf Outdated Show resolved Hide resolved
addons/ai/functions/fnc_assignNVG.sqf Outdated Show resolved Hide resolved
addons/ai/functions/fnc_assignNVG.sqf Show resolved Hide resolved
addons/ai/functions/fnc_assignNVGpfh.sqf Outdated Show resolved Hide resolved
Co-authored-by: Dystopian <sddex@ya.ru>
addons/ai/XEH_postInit.sqf Outdated Show resolved Hide resolved
addons/ai/XEH_postInit.sqf Outdated Show resolved Hide resolved
addons/ai/initSettings.sqf Outdated Show resolved Hide resolved
@jonpas jonpas marked this pull request as ready for review August 10, 2023 01:48
Copy link
Member

@Mike-MF Mike-MF left a comment

Choose a reason for hiding this comment

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

Tested with preplaced and Zeus spawned AI, works perfectly.

@acknowledge14
Copy link

How about a option to only add low tech(generation 1) NVG?

@Drofseh
Copy link
Contributor

Drofseh commented Aug 10, 2023

Could make the setting be a number
0 - no assignment
1 - assign Gen 1
2 - assign Gen 2
3 etc.
4 etc.

Maybe do -1 for thermal goggles or something? idk

@jonpas
Copy link
Member Author

jonpas commented Aug 10, 2023

How about a option to only add low tech(generation 1) NVG?

Could make the setting be a number 0 - no assignment 1 - assign Gen 1 2 - assign Gen 2 3 etc. 4 etc.

Maybe do -1 for thermal goggles or something? idk

This feature does not add any NVGs at all. It merely puts them into the inventory during the day and puts them back on the head during the night. It is a visual feature. If the unit has a Gen 1 in loadout it'll use that, if it has a Gen 2 it'll use that...

addons/ai/XEH_preInit.sqf Outdated Show resolved Hide resolved
Co-authored-by: Mike-MF <TyroneMF@hotmail.com>
@jonpas jonpas changed the title AI - Add Assign NVG AI - Add automatic AI NVG assignment Aug 11, 2023
@jonpas jonpas changed the title AI - Add automatic AI NVG assignment AI - Add automatic NVG assignment Aug 12, 2023
@jonpas jonpas added this to the 3.16.0 milestone Aug 12, 2023
@jonpas jonpas requested a review from veteran29 August 16, 2023 18:36
@PabstMirror
Copy link
Contributor

swapped pfeh to CBA_fnc_waitAndExecute which should be a tiny bit faster
(no time code checked each frame, just the first element in the ordered array)

@LinkIsGrim
Copy link
Contributor

Better naming ideas welcome.

AI - Add setting to automatically unequip NVGs during daytime?

@johnb432
Copy link
Contributor

AI - Add setting to automatically unequip NVGs during daytime?

AI - Add setting to automatically equip/unequip NVGs depending on time of day?

It's a bit lengthy though...

@jonpas
Copy link
Member Author

jonpas commented Sep 3, 2023

I meant more the naming of settings and description (strings in-game).

addons/ai/stringtable.xml Outdated Show resolved Hide resolved
@jonpas jonpas changed the title AI - Add automatic NVG assignment AI - Add automatic NVG equip/unequip Sep 5, 2023
@jonpas
Copy link
Member Author

jonpas commented Sep 5, 2023

👍 I am happy with this naming now, thanks @LinkIsGrim.

@jonpas jonpas merged commit 938f421 into master Sep 5, 2023
5 checks passed
@jonpas jonpas deleted the feature/ai-assign-nvg branch September 5, 2023 14:20
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.

10 participants