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

Interact Menu - Add inheritance support to removeActionFromClass #8396

Merged
merged 17 commits into from
Aug 5, 2024

Conversation

LinkIsGrim
Copy link
Contributor

When merged this pull request will:

@commy2
Copy link
Contributor

commy2 commented Aug 27, 2021

Should it be excludeClasses or excludedClasses?

Co-authored-by: PabstMirror <pabstmirror@gmail.com>
@LinkIsGrim
Copy link
Contributor Author

Do we still care about this?

@rautamiekka
Copy link
Contributor

Even if ACE doesn't, someone will.

@johnb432
Copy link
Contributor

Do we still care about this?

I do, as I have a mod that could make use of it. Hoping it gets added.

@LinkIsGrim LinkIsGrim added the kind/enhancement Release Notes: **IMPROVED:** label Jul 25, 2023
@Mike-MF
Copy link
Member

Mike-MF commented Sep 19, 2023

@LinkIsGrim status on this?

@LinkIsGrim
Copy link
Contributor Author

It works (or it did last time I touched it, and there's been no updates to this part of the code). Needs reviewing.

@johnb432
Copy link
Contributor

johnb432 commented Nov 14, 2023

Generally speaking, I don't understand why FUNC(addActionToClass) does not add actions for CAManBase to GVAR(inheritedActionsAll), but FUNC(removeActionFromClass) removes actions for CAManBase from GVAR(inheritedActionsAll).

The "InitPost" EH for "All" in XEH_preInit.sqf does not not seem to care if the object is CAManBase or not, so why does FUNC(addActionToClass) handle it in a special manner?

I guess that was to take into account actions added to All and alike.

@johnb432 johnb432 added this to the 3.18.0 milestone Jul 24, 2024
Copy link
Contributor Author

@LinkIsGrim LinkIsGrim left a comment

Choose a reason for hiding this comment

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

@johnb432's changes LGTM.

Note, this PR is a performance degradation whenever an object is created due to the additional checks, but there's no getting around that if we want this feature.

@johnb432 johnb432 merged commit 4226cd3 into acemod:master Aug 5, 2024
5 checks passed
blake8090 pushed a commit to blake8090/ACE3 that referenced this pull request Aug 18, 2024
…mod#8396)

* Add inheritance & exclusion support

* Update documentation in wiki

* additional check for parent class in findIf

* forEach instead of count

Co-authored-by: PabstMirror <pabstmirror@gmail.com>

* condition for children of excluded classes

* touch everything but the params check

* apply configName in same line

* fix param data type for _excludedClasses

Co-authored-by: PabstMirror <pabstmirror@gmail.com>

* Update addons/interact_menu/functions/fnc_removeActionFromClass.sqf

Co-authored-by: johnb432 <58661205+johnb432@users.noreply.github.com>

* Fix & formatting

* Fix missing _x & headers, remove invalid classes

---------

Co-authored-by: Salluci <69561145+Salluci@users.noreply.github.com>
Co-authored-by: PabstMirror <pabstmirror@gmail.com>
Co-authored-by: johnb432 <58661205+johnb432@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/enhancement Release Notes: **IMPROVED:**
Projects
None yet
Development

Successfully merging this pull request may close these issues.

ace_interact_menu_fnc_removeActionFromClass issue
7 participants