Commit Graph

135 Commits

Author SHA1 Message Date
Grim
72bc3fc355
Arsenal - Fix search case-sensitivy for non-ANSI characters (#9565)
* fix regex for non-ANSI

* Update addons/arsenal/functions/fnc_handleSearchbar.sqf

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

* Update addons/arsenal/functions/fnc_handleSearchbar.sqf

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

---------

Co-authored-by: PabstMirror <pabstmirror@gmail.com>
2023-10-23 16:07:02 -04:00
Grim
339cfa8024
Arsenal - Add support for modifying Virtual Items while opened (#9542)
* add support for mod. virt. items while opened

* updateUniqueItems

* execNextFrame

* add notification and TRACE

* remove debug

* Update addons/arsenal/functions/fnc_addVirtualItems.sqf

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

* Update addons/arsenal/functions/fnc_refresh.sqf

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

* move to removeBox

* update english to plural, others are fine

* missing include

* directCall in refresh

---------

Co-authored-by: johnb432 <58661205+johnb432@users.noreply.github.com>
2023-10-23 13:31:21 -04:00
PabstMirror
dd0838b2d7
Arsenal - Add stat for capabilities of pointer attachments (#9499)
* Arsenal - Add stat for illuminator//pointer attachments

* Update fnc_statTextStatement_illuminators.sqf

* Update fnc_statTextStatement_illuminators.sqf
2023-10-21 13:19:41 -04:00
Grim
80703ce760
Arsenal - Fix editor attribute search (#9544)
fix 3den attribute search
2023-10-20 01:23:40 +00:00
Grim
209edf0433
Arsenal - Add FUNC(getVirtualItems) (#9512)
add API
2023-10-18 14:51:00 -04:00
Grim
b2b49cc993
Arsenal - Fix saving loadouts on new profiles (#9523)
* fix

* Fix unrelated TRACE macro in arsenal

* Update addons/arsenal/functions/fnc_onArsenalOpen.sqf

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

---------

Co-authored-by: PabstMirror <pabstmirror@gmail.com>
2023-10-18 14:17:22 -04:00
Grim
f088d9bfa1
General - uiNamespace cleanup (#9425)
* fix clear trauma on stitch

* add compileFinal and move to hashmap

* add missin param

* fix captives

* explosives/medtreat

---------

Co-authored-by: PabstMirror <pabstmirror@gmail.com>
2023-10-04 14:09:05 -04:00
Grim
ac29287542
Arsenal/Compat RHS - Improve support for RHS attachments (#9386)
Co-authored-by: PabstMirror <pabstmirror@gmail.com>
2023-09-25 18:36:46 +02:00
jonpas
742626ff1a
General - Relative script_component.hpp includes (#9378)
Co-authored-by: PabstMirror <pabstmirror@gmail.com>
2023-09-12 20:58:10 +02:00
johnb432
c11e7690bf
Arsenal - Remove redundant fix for hand guns and binoculars with secondary muzzles (#9305)
Update fnc_onSelChangedRight.sqf
2023-09-05 10:37:02 -03:00
Grim
8f24884f73
Arsenal - Use regex matching for searchbars (multi-word searching) (#9348)
* use regex

* remove extra brackets

* add regex pattern, change refill condition

* add missing quote

* change pattern again

* bleh, we'll just go with this

* use pattern quote (thanks veteran)

* remove comment

* use escapeRegex function

* add regex to 3DEN attribute
2023-08-30 19:41:35 -04:00
Grim
d33a158e2e
Arsenal - Favorites System (#9307)
* improve page handling

* drop MAX_STATS_PER_PAGE for now

* hide stats box when empty

* improve hiding

* improve _fnc_hideUnused

* condition

* prevent page overflow

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

* favorites var

* function prep

* favorites only

* improve favorites adding, add include

* fix stupid

* fix color setting (todo: lnb color)

* add button, finalize

* setting tooltip

* stringtable again

* fix setting overwrite, improve tooltip

* fix losing weapon items

* fix macro

* fix setting to intended overwrite

* remove unnecessary private

* docs

* more docs

* is

* improve button text

* docs

* fix tooltip not showing unless menuBar was clicked

* improve weapon accessory lookup

* empty line

* update refresh calls

* fix left panel

* cleanup currentCargo

* use BI string for favorites

* BI strings again

* no favorites for face/voice/insignia

* stringtable again

* add missing setColorRight

* Add comment for favorites setup

---------

Co-authored-by: PabstMirror <pabstmirror@gmail.com>
2023-08-19 23:56:59 -04:00
Grim
2f8d92701f
Arsenal - Fix magazine misc items categorization (#9336)
fix stupid
2023-08-20 00:43:22 -03:00
Grim
8f3a1c5694
Arsenal - Fix changing stats via script (#9312)
* fix addStat

* fix removeStat

* improve priority sorting

* change append to pushBack
2023-08-19 22:45:07 -04:00
Grim
007995612d
Arsenal - Fix virtual non-weapon magazines in inventory being treated as unique (#9309)
* sigh

* add comment in scanConfig

* fix misc magazines

* improve magazine misc items check

* check player loadout first for uniqueItems
2023-08-19 22:38:06 -04:00
johnb432
a168330550
Arsenal - Add arsenal actions addition and removal via functions (#9318)
* Add and remove arsenal actions via functions

* Fixed header

* Update addons/arsenal/functions/fnc_addAction.sqf

Co-authored-by: Grim <69561145+LinkIsGrim@users.noreply.github.com>

* Update fnc_addSort.sqf

* Update addons/arsenal/functions/fnc_removeAction.sqf

Co-authored-by: Grim <69561145+LinkIsGrim@users.noreply.github.com>

* Update addons/arsenal/functions/fnc_removeAction.sqf

Co-authored-by: Grim <69561145+LinkIsGrim@users.noreply.github.com>

---------

Co-authored-by: Grim <69561145+LinkIsGrim@users.noreply.github.com>
2023-08-18 12:33:56 -04:00
PabstMirror
8c5ab18350
Various - Misc Cleanup (#9317)
* Various - Misc Cleanup

* Update addons/common/functions/fnc_canDig.sqf

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

---------

Co-authored-by: johnb432 <58661205+johnb432@users.noreply.github.com>
2023-08-13 14:13:02 -05:00
PabstMirror
eb53e7a2fe
Tools - document_functions.py: handle header sub indexs for arguments (#9303)
* tools - handle header sub indexs for arguements

* convert remaining

* Update coding-guidelines.md
2023-08-08 22:51:20 -05:00
johnb432
f941e0217b
Arsenal - Improve sorting (#9314)
Tweaked arsenal sorting
2023-08-09 06:25:18 +03:00
johnb432
8d7cc09586
Arsenal - Fix unique explosives showing up in the "all magazines" tab (#9308)
Check all magazines last
2023-08-05 22:07:19 +03:00
johnb432
7ef9d19bc5
Update fnc_replaceUniqueItemsLoadout.sqf (#9297) 2023-07-29 01:01:42 +03:00
Grim
2f0ed27d93
Arsenal - Improve stats display (#9290)
* improve page handling

* drop MAX_STATS_PER_PAGE for now

* hide stats box when empty

* improve hiding

* improve _fnc_hideUnused

* condition

* prevent page overflow

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

---------

Co-authored-by: PabstMirror <pabstmirror@gmail.com>
2023-07-29 01:00:05 +03:00
Grim
93520bdc9d
Arsenal - Add and Improve stats (#9291)
* add nv and magnification stats

* improve ballistics conditions

* add ammo count stat

* Update addons/arsenal/ACE_Arsenal_Stats.hpp

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

* Update addons/nightvision/ACE_Arsenal_Stats.hpp

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

* cleanup

---------

Co-authored-by: PabstMirror <pabstmirror@gmail.com>
2023-07-28 10:05:12 +03:00
Grim
5e6476aa5a
Arsenal - Make Zeuses able to save, delete, and edit Default Loadouts (#9278)
* allow zeus to edit default loadouts

* typo
2023-07-28 07:55:10 +03:00
Grim
12905a0702
Arsenal - Fix #9040 bugs/regressions (#9293)
* fix saving loadout with weapon in container

* readd magazine refill
2023-07-28 07:53:53 +03:00
johnb432
174841751c
Arsenal - Improve support for unique equipment (#9287)
* work on arsenal actions

* cycle through pages

* docs

* cleanup

* Update addons/gunbag/functions/fnc_weaponName.sqf

Co-authored-by: Jouni Järvinen <rautamiekka@users.noreply.github.com>

* missing fil

* Update addons/arsenal/functions/fnc_itemInfo.sqf

* Update addons/arsenal/functions/fnc_refresh.sqf

Co-authored-by: Jouni Järvinen <rautamiekka@users.noreply.github.com>

* remove CBA_loadoutSet gunbag cache

* update fnc_refresh

* Added unique item support for left panel items

* Cleanup

* fix 3den

* add scopeEditor

---------

Co-authored-by: Brett <brett@mayson.io>
Co-authored-by: Jouni Järvinen <rautamiekka@users.noreply.github.com>
Co-authored-by: Salluci <salluci.lovi@gmail.com>
Co-authored-by: Grim <69561145+LinkIsGrim@users.noreply.github.com>
2023-07-25 09:41:15 +03:00
BrettMayson
3edeff217a
Arsenal - Action Buttons (#9069)
* work on arsenal actions

* cycle through pages

* docs

* cleanup

* Update addons/gunbag/functions/fnc_weaponName.sqf

Co-authored-by: Jouni Järvinen <rautamiekka@users.noreply.github.com>

* missing fil

* Update addons/arsenal/functions/fnc_itemInfo.sqf

* Update addons/arsenal/functions/fnc_refresh.sqf

Co-authored-by: Jouni Järvinen <rautamiekka@users.noreply.github.com>

* remove CBA_loadoutSet gunbag cache

* update fnc_refresh

* fix 3den

---------

Co-authored-by: Jouni Järvinen <rautamiekka@users.noreply.github.com>
Co-authored-by: Salluci <salluci.lovi@gmail.com>
Co-authored-by: Grim <69561145+LinkIsGrim@users.noreply.github.com>
2023-07-25 09:30:49 +03:00
Grim
31e1ad0cff
Arsenal - Add Tools category and moveOnOverwrite parameter to FUNC(addCustomRightPanelButton) (#9247)
* add tools tab and setting

* move to preinit

* fix icon, add restart warning

* derp

Co-authored-by: Dystopian <sddex@ya.ru>

* Update addons/arsenal/stringtable.xml

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

* remove setting

* add keepIfOverriden parameter

* docs again

* documentation whitespace

* docs grammar, change parameter name

* fix docs

* more docs fixes

* magazine support

* deprecate spare barrel item

* more docs, improve condition

---------

Co-authored-by: Dystopian <sddex@ya.ru>
Co-authored-by: PabstMirror <pabstmirror@gmail.com>
2023-07-21 22:39:48 +03:00
johnb432
c8404f496e
Arsenal - Add/Fix/Improve/Change numerous aspects (#9040)
* Arsenal update

* Fixes

* Update fnc_onSelChangedLeft.sqf

* Update fnc_updateUniqueItemsList.sqf

* Header fixes

* Fix for defines.hpp

Co-authored-by: Dystopian <sddex@ya.ru>

* Moved fnc_baseWeapon, filtered invalid items

* Update addons/arsenal/functions/fnc_scanConfig.sqf

Co-authored-by: Grim <69561145+LinkIsGrim@users.noreply.github.com>

* Fixes and tweaks

- Sorting is guaranteed to give a fixed order
- Dog tags no longer throw errors when reloading the ACE arsenal mission when you had some saved in your loadout before quitting the last time you played.

* Cleanup, bug fixes and additions

- Added the ability to add items from "CfgMagazines" into the "Misc. items" or custom tabs.
- Added "baseWeapon" class support for weapon attachments. If a weapon attachment has the config property "baseWeapon" defined, it will take that item and show that in the arsenal.
- Added stronger filtering on item scopes (scope > 0 at least for every item)
- Added "descending" (default, as it is now) and "ascending" sort order as a drop down menu,
- Unique backpacks in containers can now be removed with either the "-" or "clear all items" button.
- When sorting by a number, 2 decimal points have been added, so that when you sort by weight it returns the correct order.

* More fixes and tweaks

- Converted the arsenal to partially work with hashmaps instead of arrays (for configItems and virtualItems, currentItems is still an array).
- Because of the above, performance of FUNC(addVirtualItems) and FUNC(removeVirtualItems) has improved immensely.
- Sorting now caches results, reducing repeated sorting times drastically.
- CBA disposable launchers are handled differently now: Within the arsenal, you can change weapon attachments on disposable launchers, but you can't change their magazines (primary or secondary). Item info on the right and the stats show correct information.
- FUNC(addSort) now checks if the new sorting method already exists and doesn't add it if it does.
- FUNC(removeSort) now exists. You can't remove the default sort type (alphabetically) to avoid problems with the arsenal.
- Both FUNC(addStat) and FUNC(compileStats) actually taken priority into account now. Because of that priority on several stats needed to be tweaked.
- FUNC(removeStat) ensures that there are no gaps within the stat array (so if there is an empty spot in the stats page, it's because there is a stat, but the condition for it being shown hasn't been met).

* Update fnc_replaceUniqueItemsLoadout.sqf

* Update fnc_onSelChangedLeft.sqf

* Update fnc_scanConfig.sqf

* Update docs/wiki/framework/arsenal-framework.md

Co-authored-by: Grim <69561145+LinkIsGrim@users.noreply.github.com>

* Minor cleanup

* Baseweapon filtering

* Improvements + better unique items support

* Update fnc_fillRightPanel.sqf

* Update fnc_onSelChangedLeft.sqf

Fixed: Switching between weapons with incompatible primary magazines while a compatible secondary magazine is loaded doesn't equip the new weapon's primary magazine.

* Update addons/common/functions/fnc_uniqueUnitItems.sqf

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

* undefined variable

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

* fix undefined loadout var

* Update fnc_fillLoadoutsList.sqf

---------

Co-authored-by: Dystopian <sddex@ya.ru>
Co-authored-by: Grim <69561145+LinkIsGrim@users.noreply.github.com>
Co-authored-by: PabstMirror <pabstmirror@gmail.com>
2023-07-21 21:25:25 +03:00
Grim
aead9a8eb4
fix nvg stat detection (#9254) 2023-07-16 12:45:33 -05:00
Mike-MF
888ac6c9bc
Arsenal - Fix null comparison (#9213) 2023-06-10 18:59:13 +02:00
jonpas
48a4e9682c Forbit use of (optional) in function headers, always require a value 2023-05-01 17:33:07 +02:00
jonpas
76e1aafb33
Use function documentation script (#6897)
Co-authored-by: Björn Dahlgren <bjorn@dahlgren.io>
2023-04-30 23:03:35 +02:00
TACHarsis
e21ffc4c32
Arsenal - Fix non-local loop variable use in fnc_fillRightPanel.sqf (#9115)
* Fixed use of loop variable from outside of function and using local variable instead

* Update addons/arsenal/functions/fnc_fillRightPanel.sqf

Co-authored-by: Jouni Järvinen <rautamiekka@users.noreply.github.com>

Co-authored-by: Jouni Järvinen <rautamiekka@users.noreply.github.com>
2023-01-05 20:45:13 -06:00
TACHarsis
95a5fb040a
Arsenal - Add init/remove local events to Arsenal creation/destruction (#9064)
* Added two local events to arsenal

* onInitArsenal fired when Arsenal got initiated
* onRemoveArsenal fired when Arsenal got removed

* added them to the arsenal event listing in the docs

* Update addons/arsenal/functions/fnc_removeBox.sqf

Co-authored-by: BrettMayson <brett@mayson.io>

* Update addons/arsenal/functions/fnc_removeBox.sqf

Co-authored-by: BrettMayson <brett@mayson.io>

* Renamed events in accordance with event naming patterns sans "on"

* Apply suggestions from code review

Co-authored-by: BrettMayson <brett@mayson.io>

* Improved Docs

Co-authored-by: BrettMayson <brett@mayson.io>
2022-10-21 19:28:10 -05:00
zharf
5587d9dc69
Arsenal - Fixed fetching loadout from extended loadout (#9045) 2022-09-22 13:06:00 -05:00
BrettMayson
438a90b63d
Common - Add CBA extended loadout (#8923)
* extended loadouts - earplugs, gunbag, and arsenal identity

* arsenal - maintain default loadout size check

* restore comment

Co-authored-by: jonpas <jonpas33@gmail.com>

* fix forgotten example

Co-authored-by: jonpas <jonpas33@gmail.com>
2022-08-25 11:56:54 -05:00
PabstMirror
ad5c275532
arsenal - fix hash getvar default type (#8892) 2022-04-25 19:35:52 -05:00
johnb432
90ebe08012
Arsenal tweak (#8786)
Previously:
- When a new weapon was selected, only magazines defined in the "magazines" attribute of the old weapon's class were deleted.
- When a new weapon was selected, it would consume a magazine from the loadout.

Now:
- When a new weapon is selected, it will only remove the magazines from the previous weapon that are not compatible with the current weapon.
- When a new weapon is selected, it does not consume a magazine from the loadout.
2022-03-07 12:26:56 -06:00
GhostIsSpooky
615afee022
Arsenal - Improve addWeaponItem usage (#8813)
* reload magazine instantly on arsenal

* remove comment in reloadlaunchers

* use addWeaponItem in selChangedRight
2022-02-17 11:14:01 -06:00
shukari
ec2028cc8a
Documentation - Add Arsenal custom sub-item categories (#8678)
* New Info: Adding custom sub item categories

* typo fix

* Custom sub item categories

* Update arsenal.md
2021-11-15 12:18:54 +01:00
PabstMirror
7bc6fdfa66
Cleanup - Trim all trailing whitespace (#8651) 2021-10-30 16:42:03 -05:00
mharis001
ff3e0a48df
Arsenal - Fix stats not updating for custom buttons (#8586) 2021-10-26 18:05:49 -05:00
GhostIsSpooky
005b2aef14
Arsenal - Stop deleting unique belt items (#8483)
* prevent belt items from being deleted

* fix wrong index

* fix gps not being selected

* & fix UAV terminals not being selected

* add comments, delete extra line

* use getUnitLoadout for assignedItems
2021-10-12 17:10:18 -05:00
GhostIsSpooky
97deef5617
General - Use engine hashmaps (#8468)
Co-authored-by: Dedmen Miller <dedmen@users.noreply.github.com>
2021-10-10 18:55:14 +02:00
GhostIsSpooky
a95e71fec8
Arsenal - Handle Weapon Items not in Box Virtual Items as Unique (#8375)
* Handle unique items that are also weapon attachments

* only flatten once
2021-10-07 12:39:55 -05:00
mharis001
d6559f22e0
Arsenal - Fix sort running twice (#8479) 2021-10-06 22:16:42 -05:00
mharis001
09d1284ad9
Arsenal - Fix sortPanel clearing custom item names (#8478) 2021-10-05 15:37:27 -04:00
mharis001
66ce0ba5ff
Arsenal - Restore curator camera state when exiting (#8464) 2021-10-02 06:52:50 -04:00
mharis001
310da98c5e
Arsenal - Fix updateUniqueItemsList incorrectly identifying backpacks (#8463) 2021-10-02 06:52:33 -04:00