Persian MO 82 Posted October 2, 2015 I'm looking for a way to disable save/load option in arsenal.Searched forum but nothing yet.Any solution? 1 Share this post Link to post Share on other sites
Razor[42JTF] 10 Posted November 23, 2015 Does anyone have a solution for this. I'm also trying to figure it out Share this post Link to post Share on other sites
Larrow 2820 Posted November 23, 2015 [ missionNamespace, "arsenalOpened", { disableSerialization; _display = _this select 0; { ( _display displayCtrl _x ) ctrlSetText "Disabled"; ( _display displayCtrl _x ) ctrlSetTextColor [ 1, 0, 0, 0.5 ]; ( _display displayCtrl _x ) ctrlRemoveAllEventHandlers "buttonclick"; }forEach [ 44146, 44147 ]; } ] call BIS_fnc_addScriptedEventHandler; 7 1 Share this post Link to post Share on other sites
Tajin 349 Posted November 11, 2016 Well that is a neat way of doing it. You don't happen to know if there is a list of all the pre-defined scripted EHs, do you? That could be quite useful. Share this post Link to post Share on other sites
Larrow 2820 Posted November 11, 2016 Heres the results from a grep for BIS_fnc_callScriptedEventHandler of the A3 files( not including Apex which is still EBO ). Not a well defined list but should give you a good idea of what is available and what files to find them in for more details. Updated version of all BI's scripted events can be found Here on the wiki (v1.80) 3 Share this post Link to post Share on other sites
BLACKOUT6IX 250 Posted November 12, 2016 [ missionNamespace, "arsenalOpened", { disableSerialization; _display = _this select 0; { ( _display displayCtrl _x ) ctrlSetText "Disabled"; ( _display displayCtrl _x ) ctrlSetTextColor [ 1, 0, 0, 0.5 ]; ( _display displayCtrl _x ) ctrlRemoveAllEventHandlers "buttonclick"; }forEach [ 44146, 44147 ]; } ] call BIS_fnc_addScriptedEventHandler; I'm having a issue as to where people can load premade loadouts from the past through my whitelisted arsenal. I don't want to disable the save/load function completely, but just make it so someone can go to the VA, make a loadout, then come load it on my server. Any solutions? Share this post Link to post Share on other sites
randy andy tw1 12 Posted November 22, 2016 Hi, where would you execute this? I am using a script which defines what equipment will be available in the arsenal that runs when the client uses the ammo box. Would this be where this gets executed or does this only need to be executed once? Thanks Share this post Link to post Share on other sites
Larrow 2820 Posted November 25, 2016 Quote Hi, where would you execute this? Just in the initPlayerLocal.sqf. It does not need to have any reference to your VA or anything to do with when you assign items to the VA. The VA will automatically call the script when the VA is opened as long as it has been defined some where on the client. Quote I'm having a issue as to where people can load premade loadouts from the past through my whitelisted arsenal. I don't want to disable the save/load function completely, but just make it so someone can go to the VA, make a loadout, then come load it on my server. Any solutions? So you want only VA white listed items to be loaded when a player loads an existing loadout? How about something like this Share this post Link to post Share on other sites
randy andy tw1 12 Posted January 3, 2017 On 11/25/2016 at 4:43 PM, Larrow said: Just in the initPlayerLocal.sqf. It does not need to have any reference to your VA or anything to do with when you assign items to the VA. The VA will automatically call the script when the VA is opened as long as it has been defined some where on the client. So you want only VA white listed items to be loaded when a player loads an existing loadout? How about something like this these both worked great! one problem.... and i didnt know this, VA has a hot keybind of CTRL+R to randomize loadouts. even with save/load/random disabled, players can still find a way of getting something they shouldnt have ... any ideas? by the way your override_VA_templates worked great! EDIT found this... :D Share this post Link to post Share on other sites
Yoyodef 12 Posted March 21, 2017 On 25/11/2016 at 5:43 PM, Larrow said: Just in the initPlayerLocal.sqf. It does not need to have any reference to your VA or anything to do with when you assign items to the VA. The VA will automatically call the script when the VA is opened as long as it has been defined some where on the client. So you want only VA white listed items to be loaded when a player loads an existing loadout? How about something like this Link is not working anymore, can it be reupload, please? Edit : Nevermind I found it on Larrow dropbox -> " override_VA_templates" Share this post Link to post Share on other sites
Midnighters 152 Posted March 21, 2017 Couldn't you remove all weapons globally and then add them back? Or am I thinking incorrectly here Share this post Link to post Share on other sites
Larrow 2820 Posted March 21, 2017 5 minutes ago, Yoyodef said: Link is not working anymore, can it be reupload, please? Fixed, Due to Dropbox changing users Public folder to private after all these years I have had to move stuff around and reapply shared links, thought I had caught most of them. Most of my forum examples can always be found in the link in my signature. 1 Share this post Link to post Share on other sites
shukari 28 Posted September 15, 2017 Here is the best code, hide all controls that are useless on limited arsenals and disable all shortcuts to them like STRG+S for save: [missionNamespace, "arsenalOpened", { disableSerialization; params ["_display"]; _display displayAddEventHandler ["keydown", "_this select 3"]; {(_display displayCtrl _x) ctrlShow false} forEach [44151, 44150, 44146, 44147, 44148, 44149, 44346]; }] call BIS_fnc_addScriptedEventHandler; 5 2 Share this post Link to post Share on other sites
pierremgi 4857 Posted September 27, 2017 Just a remark; Struggling for the id number of a display or a control , you can write some code or use pbo manager on folders ... steamapps\common\arma3\addons\ui_f.pbo Then edit (but do not modify): defineResIncl.inc (general display/control mission, inventory...) defineResInclDesign.inc (arsenal, player respawn, sector capture...) Then, search for word like arsenal (104 matches), 2 two clicks you reach the list of IDC_RSCDISPLAYARSENAL then, some lines like: #define IDC_RSCDISPLAYARSENAL_CONTROLSBAR_BUTTONSAVE 44146 explicit, I think. 2 Share this post Link to post Share on other sites
7erra 629 Posted September 27, 2017 Another option would be to go through the ingame config viewer. Most of the displays start with "Rsc" and so does "RscDisplayArsenal". After searching a bit through the entries you will find the buttons you are searching for here: configfile >> "RscDisplayArsenal" >> "Controls" >> "ControlBar" >> "controls". Whatever is easier for you. 1 Share this post Link to post Share on other sites
7erra 629 Posted September 28, 2017 Actually here is a function: TER_fnc_findIDC = { /* Author: Terra Description: Execute the script and wait for the message "IDC finder initialized on displays: [display array]". Then you can hover above any button and see the IDC of the control. The tooltip might not be accurate everytime because of control groups. Systemchat output is more reliable. Parameters: 0 - Delay between execution of the function and activation (NUMBER) Default: 5 1 - exclude displays. (ARRAY OF IDDs) Default: Standard displays 0, 46 (Game display), 12 (Map), 49 (Escape menu) Example: [] spawn TER_fnc_findIDC; */ disableSerialization; params [ ["_delay",0,[123]], ["_exclude",[0,12,46,49],[[]]] ]; _exclude = _exclude apply {findDisplay _x}; uisleep _delay; _displays = allDisplays -_exclude; { { _x ctrlAddEventHandler ["MouseEnter",{systemChat format ["IDC: %1",ctrlIDC (_this select 0)]}]; _x ctrlSetTooltip format ["IDC: %1",ctrlIDC _x]; } forEach allControls _x; } forEach _displays; systemChat format ["IDC finder initialized on displays: %1",_displays]; }; 4 Share this post Link to post Share on other sites
beeper 10 Posted April 3, 2018 On 25.11.2016 at 7:43 PM, Larrow said: Just in the initPlayerLocal.sqf. It does not need to have any reference to your VA or anything to do with when you assign items to the VA. The VA will automatically call the script when the VA is opened as long as it has been defined some where on the client. So you want only VA white listed items to be loaded when a player loads an existing loadout? How about something like this Please clarify - where are whitelist file and place to add items to it? Share this post Link to post Share on other sites
Reschiiv 0 Posted February 20, 2019 On 3/21/2017 at 3:40 PM, Yoyodef said: Link is not working anymore, can it be reupload, please? Edit : Nevermind I found it on Larrow dropbox -> " override_VA_templates" Thanks, dude. This really helped me out. Share this post Link to post Share on other sites
mrakos2005 4 Posted May 10, 2020 On 4/3/2018 at 10:44 AM, beeper said: Please clarify - where are whitelist file and place to add items to it? I know this thread is OLD but I had the same issue in understanding how to get Larrow's brilliant "overRide_VA_templates" script to work. After some noob head scratching I realized (eventually) that you don't have to create a whitelist file, it just works off what's already inside the box ie. what contents you, as the mission designer have put inside the ammo box (I used 3den editor's Inventory Manager for that part). Just make sure the folder "LARs" is placed in your mission root folder. The next hurdle (for me) was getting the class CfgFunctions part right. I did it like this in description.ext: respawn=3; respawnButton = 1; enableTeamSwitch = 1; respawndelay=5; respawnDialog = 1; respawnOnStart = -1; disabledAI = 1; aiKills = 0; briefing = 1; debriefing = 1; showHUD = 1; showGPS = 0; showCompass = 1; showMap = 1; showNotePad = 0; showWatch = 1; showUAVFeed = 0; showSquadRadar = 0; joinUnassigned = 1; skipLobby = 0; Saving = 0; // Functions #include "LARs\override_VA_templates\settings.hpp" class CfgFunctions { #include "LARs\override_VA_templates\functions\functions.hpp" the rest of your classes here.... Share this post Link to post Share on other sites