Jump to content
Panda Pilot

XM8 overwrite for buttons

Recommended Posts

Ive had some code that has allowed me to overwrite the old server info button with a new XM8 apps button. works great! then i found buried deep within old posts in discord that lead to the old exile mod forums that you can use the same code and add additional lines to overwrite the rest of the buttons. i added the necessary pieces to my knowledge and have been trying it out. the code does work and i have been moving the new XM8 apps button around overwriting the family button, the vg button, and the server info button. but i cannot seem to get all of the 3 of the button replacements to work at the same time. the 3 buttons im using are the exad vg replacing the old vg button, scarcode info menu is replacing the server info, and the xm8 apps is replacing families (which this one currently works the way it is in the code) any help or guidance would be greatly appreciated. thanks, panda. ExileClient_gui_xm8_slide_apps_onOpen - https://pastebin.com/ZxXy7Dd3

Share this post


Link to post
Share on other sites
///Server Rules Button replacement
_SIMLogo = "custom\XM8\Icons\Info.paa";
_serverInfo = _display displayCtrl 1107;
_serverInfo ctrlSetText "";
_serverInfo ctrlSetFade 1;
_serverInfo ctrlCommit 0;

_SIMIcon = _display ctrlCreate ["RscPicture", 9897, _display displayCtrl 4040];
_SIMIcon ctrlSetPosition [(24.25 - 3) * (0.025), (15.5 - 2) * (0.04), 2.75 * (0.04), 2.75 * (0.04)];
_SIMIcon ctrlCommit 0.01;
_SIMIcon ctrlSetText _SIMLogo;

_SIMControl = _display ctrlCreate ["RscExileXM8AppButton1x1", 9898, _display displayCtrl 4040];
_SIMControl ctrlSetPosition [(23.5 - 3) * (0.025), (15 - 2) * (0.04)];
_SIMControl ctrlCommit 0.01;
_SIMControl ctrlSetEventHandler ["ButtonClick", "ExileClientXM8CurrentSlide = 'apps';closeDialog 0;[] ExecVM 'scarCODE\ServerInfoMenu\sqf\initLocal.sqf';"];
_SIMControl ctrlSetStructuredText (parseText (format ["Server Rules/Infos"]));

//XM8 Mobile Button replacement
_VdLogo = "\exile_assets\texture\ui\xm8_menu_ca";
_VdInfo = _display displayCtrl 1104;
_VdInfo ctrlSetText "";
_VdInfo ctrlSetFade 1;
_VdInfo ctrlCommit 0;

_VdIcon = _display ctrlCreate ["RscPicture", 9899, _display displayCtrl 4040];
_VdIcon ctrlSetPosition [(11.1 - 3) * (0.025), (15.5 - 2) * (0.04), 2.75 * (0.04), 2.75 * (0.04)];
_VdIcon ctrlCommit 0.01;
_VdIcon ctrlSetText _VdLogo;

_VdControl = _display ctrlCreate ["RscExileXM8AppButton1x1", 9900, _display displayCtrl 4040];
_VdControl ctrlSetPosition [(10.4 - 3) * (0.025), (15 - 2) * (0.04)];
_VdControl ctrlCommit 0.01;
_VdControl ctrlSetEventHandler ["ButtonClick", "ExileClientXM8CurrentSlide = 'apps';closeDialog 0;[] call CHVD_fnc_openDialog;"];
_VdControl ctrlSetStructuredText (parseText (format ["Viewdistance"]));

Should be enough to get a clue how to do it 😛

2361a5be5db16f5cc89281b8fb717f98.png

Share this post


Link to post
Share on other sites

×