From 3c0739710d55bd7d572496bb49f356cea842f782 Mon Sep 17 00:00:00 2001 From: Bjanski Date: Thu, 28 Apr 2016 13:31:00 +0200 Subject: [PATCH] Introduced Virtual Garage --- @ExileServer/addons/exad_vg/$PREFIX$ | 1 + .../addons/exad_vg/Functions/fn_VGLoad.sqf | 52 ++++++ .../addons/exad_vg/Functions/fn_VGStore.sqf | 62 +++++++ .../Functions/fn_requestVGDetailInfo.sqf | 40 ++++ @ExileServer/addons/exad_vg/PboPrefix.txt | 1 + @ExileServer/addons/exad_vg/config.cpp | 51 +++++ @ExileServer/extDB/sql_custom_v2/exile.ini | 29 +++ BattlEye/remoteexec.txt | 2 + docs/VirtualGarage/examples.md | 1 + docs/VirtualGarage/installation.md | 48 +++++ docs/core/installation.md | 11 +- .../Exile.Altis/ExAdClient/CfgHints.cpp | 8 +- .../ExAdClient/VirtualGarage/CfgFunctions.cpp | 28 +++ .../ExAdClient/VirtualGarage/CfgHints.cpp | 38 ++++ ...eServer_system_territory_database_load.sqf | 55 ++++++ .../Functions/fn_allowVGStore.sqf | 28 +++ .../VirtualGarage/Functions/fn_fillVGList.sqf | 36 ++++ .../Functions/fn_loadVGDetailView.sqf | 27 +++ .../Functions/fn_onBtnClickVG.sqf | 40 ++++ .../ExAdClient/VirtualGarage/customize.sqf | 27 +++ .../ExAdClient/VirtualGarage/postInit.sqf | 20 ++ .../Exile.Altis/XM8_apps/Icons/apps_icon.paa | Bin 0 -> 22016 bytes .../XM8_apps/Icons/generic_app.paa | Bin 0 -> 22016 bytes .../Exile.Altis/XM8_apps/XM8_apps_config.sqf | 13 ++ .../Exile.Altis/XM8_apps/XM8_apps_sliders.hpp | 14 ++ .../XM8_apps/apps/XM8_VG/Icons/apps_icon.paa | Bin 0 -> 38878 bytes .../XM8_apps/apps/XM8_VG/XM8_VG_config.sqf | 20 ++ .../scripts/XM8_VG_checkNearByFlags.sqf | 30 +++ .../apps/XM8_VG/scripts/XM8_VG_init.sqf | 27 +++ .../XM8_VG/scripts/XM8_VG_loadContent.sqf | 43 +++++ .../scripts/XM8_VG_mainVGSlide_onLoad.sqf | 154 +++++++++++++++ .../scripts/ExileClient_gui_xm8_show.sqf | 175 ++++++++++++++++++ .../scripts/ExileClient_gui_xm8_slide.sqf | 87 +++++++++ .../ExileClient_gui_xm8_slide_apps_onOpen.sqf | 47 +++++ .../XM8_apps/scripts/XM8_apps_init.sqf | 28 +++ mpmissions/Exile.Altis/config.cpp | 22 +++ mpmissions/Exile.Altis/stringtable.xml | 7 + 37 files changed, 1267 insertions(+), 5 deletions(-) create mode 100644 @ExileServer/addons/exad_vg/$PREFIX$ create mode 100644 @ExileServer/addons/exad_vg/Functions/fn_VGLoad.sqf create mode 100644 @ExileServer/addons/exad_vg/Functions/fn_VGStore.sqf create mode 100644 @ExileServer/addons/exad_vg/Functions/fn_requestVGDetailInfo.sqf create mode 100644 @ExileServer/addons/exad_vg/PboPrefix.txt create mode 100644 @ExileServer/addons/exad_vg/config.cpp create mode 100644 @ExileServer/extDB/sql_custom_v2/exile.ini create mode 100644 BattlEye/remoteexec.txt create mode 100644 docs/VirtualGarage/examples.md create mode 100644 docs/VirtualGarage/installation.md create mode 100644 mpmissions/Exile.Altis/ExAdClient/VirtualGarage/CfgFunctions.cpp create mode 100644 mpmissions/Exile.Altis/ExAdClient/VirtualGarage/CfgHints.cpp create mode 100644 mpmissions/Exile.Altis/ExAdClient/VirtualGarage/CustomCode/ExileServer_system_territory_database_load.sqf create mode 100644 mpmissions/Exile.Altis/ExAdClient/VirtualGarage/Functions/fn_allowVGStore.sqf create mode 100644 mpmissions/Exile.Altis/ExAdClient/VirtualGarage/Functions/fn_fillVGList.sqf create mode 100644 mpmissions/Exile.Altis/ExAdClient/VirtualGarage/Functions/fn_loadVGDetailView.sqf create mode 100644 mpmissions/Exile.Altis/ExAdClient/VirtualGarage/Functions/fn_onBtnClickVG.sqf create mode 100644 mpmissions/Exile.Altis/ExAdClient/VirtualGarage/customize.sqf create mode 100644 mpmissions/Exile.Altis/ExAdClient/VirtualGarage/postInit.sqf create mode 100644 mpmissions/Exile.Altis/XM8_apps/Icons/apps_icon.paa create mode 100644 mpmissions/Exile.Altis/XM8_apps/Icons/generic_app.paa create mode 100644 mpmissions/Exile.Altis/XM8_apps/XM8_apps_config.sqf create mode 100644 mpmissions/Exile.Altis/XM8_apps/XM8_apps_sliders.hpp create mode 100644 mpmissions/Exile.Altis/XM8_apps/apps/XM8_VG/Icons/apps_icon.paa create mode 100644 mpmissions/Exile.Altis/XM8_apps/apps/XM8_VG/XM8_VG_config.sqf create mode 100644 mpmissions/Exile.Altis/XM8_apps/apps/XM8_VG/scripts/XM8_VG_checkNearByFlags.sqf create mode 100644 mpmissions/Exile.Altis/XM8_apps/apps/XM8_VG/scripts/XM8_VG_init.sqf create mode 100644 mpmissions/Exile.Altis/XM8_apps/apps/XM8_VG/scripts/XM8_VG_loadContent.sqf create mode 100644 mpmissions/Exile.Altis/XM8_apps/apps/XM8_VG/scripts/XM8_VG_mainVGSlide_onLoad.sqf create mode 100644 mpmissions/Exile.Altis/XM8_apps/scripts/ExileClient_gui_xm8_show.sqf create mode 100644 mpmissions/Exile.Altis/XM8_apps/scripts/ExileClient_gui_xm8_slide.sqf create mode 100644 mpmissions/Exile.Altis/XM8_apps/scripts/ExileClient_gui_xm8_slide_apps_onOpen.sqf create mode 100644 mpmissions/Exile.Altis/XM8_apps/scripts/XM8_apps_init.sqf create mode 100644 mpmissions/Exile.Altis/config.cpp diff --git a/@ExileServer/addons/exad_vg/$PREFIX$ b/@ExileServer/addons/exad_vg/$PREFIX$ new file mode 100644 index 0000000..a9c6ae5 --- /dev/null +++ b/@ExileServer/addons/exad_vg/$PREFIX$ @@ -0,0 +1 @@ +exad_vg \ No newline at end of file diff --git a/@ExileServer/addons/exad_vg/Functions/fn_VGLoad.sqf b/@ExileServer/addons/exad_vg/Functions/fn_VGLoad.sqf new file mode 100644 index 0000000..f052709 --- /dev/null +++ b/@ExileServer/addons/exad_vg/Functions/fn_VGLoad.sqf @@ -0,0 +1,52 @@ +/* + Copyright 2016 Jan Babor + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + +*/ + +private ["_objVehNetId","_objVeh","_flagNetId","_flag","_objVehId","_flagId","_data","_extDB2Message","_vehList"]; + +_objId = [_this,0,"",[""]] call BIS_fnc_param; +_flagNetId = [_this,1,"",[""]] call BIS_fnc_param; +_playerNetId = [_this,2,"",[""]] call BIS_fnc_param; +_flag = objectFromNetId _flagNetId; +_requestFrom = owner (objectFromNetId _playerNetId); + +_proceed = false; +_vehList = _flag getVariable ["ExAdVGVeh", []]; + +{ + if((format["%1",_x select 0]) isEqualTo _objId)exitWith{ + _vehList deleteAt _forEachIndex; + _proceed = true; + } +}forEach _vehList; + +if(!_proceed)exitWith{[_requestFrom, "notificationRequest", ["Whoops", ["They vehicle is not available anymore"]]] call ExileServer_system_network_send_to}; + +_flag setVariable ["ExAdVGVeh", _vehList, true]; + +_vehObj = (parseNumber _objId) call ExileServer_object_vehicle_database_load; +_extDB2Message = ["loadVehFromVG", [parseNumber _objId]] call ExileServer_util_extDB2_createMessage; +_extDB2Message call ExileServer_system_database_query_fireAndForget; + +if(ExAd_VG_SHOW_ADVHINT)then{ + [["advancedHint", ["VGLoad",[_vehObj getVariable["ExileAccessCode",""]]]], _requestFrom] call ExAdServer_fnc_clientDispatch; +}; + +_pos = getPosATL _vehObj; +_pos set [2, (_pos select 2) + 0.1]; +_vehObj setPosATL _pos; + +true \ No newline at end of file diff --git a/@ExileServer/addons/exad_vg/Functions/fn_VGStore.sqf b/@ExileServer/addons/exad_vg/Functions/fn_VGStore.sqf new file mode 100644 index 0000000..dec9d19 --- /dev/null +++ b/@ExileServer/addons/exad_vg/Functions/fn_VGStore.sqf @@ -0,0 +1,62 @@ +/* + Copyright 2016 Jan Babor + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + +*/ + +private ["_objVehNetId","_objVeh","_flagNetId","_flag","_owner","_objVehId","_flagId","_data","_extDB2Message","_vehList"]; + +_objVehNetId = [_this,0,"",[""]] call BIS_fnc_param; +_objVeh = objectFromNetId _objVehNetId; +_flagNetId = [_this,1,"",[""]] call BIS_fnc_param; +_flag = objectFromNetId _flagNetId; +_owner = owner _objVeh; +if!(_objVeh getVariable ["ExileIsPersistent", false])exitWith{(localize "STR_VG_STORE_NOTPERSISTENT") remoteExec ["hint", _owner]; false}; + +if!(_objVeh setOwner 2)exitWith{format["Get out of the vehicle before storing it."] remoteExec ["hint", _owner]; false}; + +if!(isNil "ExAd_VG_CLEAN_ON_STORE")then{ + if(ExAd_VG_CLEAN_ON_STORE)then{ + clearBackpackCargoGlobal _objVeh; + clearItemCargoGlobal _objVeh; + clearMagazineCargoGlobal _objVeh; + clearWeaponCargoGlobal _objVeh; + } +}; + +_objVeh call ExileServer_object_vehicle_database_update; + +_objVehId = _objVeh getVariable ["ExileDatabaseID",-1]; +_flagId = _flag getVariable ["ExileDatabaseID", -1]; + +if(_objVehId > -1 && _flagId > -1)then{ + _data = [_flagId, _objVehId]; + + _extDB2Message = ["loadVehToVG", _data] call ExileServer_util_extDB2_createMessage; + _extDB2Message call ExileServer_system_database_query_fireAndForget; + + _objVeh call ExileServer_system_vehicleSaveQueue_removeVehicle; + _objVeh call ExileServer_system_simulationMonitor_removeVehicle; + deleteVehicle _objVeh; + + _vehList = _flag getVariable ["ExAdVGVeh", []]; + _vehList pushBack [_objVehId, typeOf _objVeh]; + _flag setVariable ["ExAdVGVeh", _vehList, true]; + + if(ExAd_VG_SHOW_ADVHINT)then{ + [["advancedHint", ["VGStore",[]]], _owner] call EXOServer_fnc_clientDispatch; + }; +}; + +true \ No newline at end of file diff --git a/@ExileServer/addons/exad_vg/Functions/fn_requestVGDetailInfo.sqf b/@ExileServer/addons/exad_vg/Functions/fn_requestVGDetailInfo.sqf new file mode 100644 index 0000000..9013e33 --- /dev/null +++ b/@ExileServer/addons/exad_vg/Functions/fn_requestVGDetailInfo.sqf @@ -0,0 +1,40 @@ +/* + fn_requestVGDetailInfo.sqf + + Copyright 2016 Jan Babor + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ + +private ["_objVehNetId","_objVeh","_flagNetId","_flag","_objVehId","_flagId","_data","_extDB2Message","_vehList"]; + +_objId = [_this,0,"",[""]] call BIS_fnc_param; +_flagNetId = [_this,1,"",[""]] call BIS_fnc_param; +_streamFriendlyUI = [_this,2,0,[0]] call BIS_fnc_param; +_playerNetId = [_this,3,"",[""]] call BIS_fnc_param; +_ctrl = [_this,4,-1,[0]] call BIS_fnc_param; +_flag = objectFromNetId _flagNetId; +_requestFrom = owner (objectFromNetId _playerNetId); + +/*Check if vehicle is in flag - avoid cheaters fishing for pin codes*/ + +_data = format ["loadVehicle:%1", _objId] call ExileServer_system_database_query_selectSingle; + +_displayName = getText(ConfigFile >> "CfgVehicles" >> (_data select 1) >> "displayName"); +_pinCode = if(_streamFriendlyUI == 0)then{_data select 20}else{"XXXX"}; + +_text = format["%1
Pin code: %2
",_displayName, _pinCode]; + +[_text,_ctrl] remoteExec ["ExAd_fnc_loadVGDetailView", _requestFrom]; + +true \ No newline at end of file diff --git a/@ExileServer/addons/exad_vg/PboPrefix.txt b/@ExileServer/addons/exad_vg/PboPrefix.txt new file mode 100644 index 0000000..a9c6ae5 --- /dev/null +++ b/@ExileServer/addons/exad_vg/PboPrefix.txt @@ -0,0 +1 @@ +exad_vg \ No newline at end of file diff --git a/@ExileServer/addons/exad_vg/config.cpp b/@ExileServer/addons/exad_vg/config.cpp new file mode 100644 index 0000000..664493b --- /dev/null +++ b/@ExileServer/addons/exad_vg/config.cpp @@ -0,0 +1,51 @@ +/* + config.cpp + + Copyright 2016 Jan Babor + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ + +class CfgPatches { + class ExAd_VG { + requiredVersion = 0.1; + requiredAddons[] = {"ExAd_Core"}; + }; +}; + +class CfgFunctions { + class ExAdServer { + class VG { + file = "exad_vg\Functions"; + class requestVGDetailInfo {}; + class VGLoad {}; + class VGStore {}; + }; + }; +}; + +class CfgNetworkMessages +{ + class VGStore + { + parameters[] = {"STRING","STRING","STRING"}; + }; + class VGLoad + { + parameters[] = {"STRING","STRING","STRING"}; + }; + class requestVGDetailInfo + { + parameters[] = {"STRING","STRING","SCALAR","STRING","SCALAR"}; + }; +}; \ No newline at end of file diff --git a/@ExileServer/extDB/sql_custom_v2/exile.ini b/@ExileServer/extDB/sql_custom_v2/exile.ini new file mode 100644 index 0000000..736f74c --- /dev/null +++ b/@ExileServer/extDB/sql_custom_v2/exile.ini @@ -0,0 +1,29 @@ +;1. Find [loadVehicleIdPage] and replace the section with this; + +[loadVehicleIdPage] +;SQL1_1 = SELECT id FROM vehicle LIMIT ?,? +SQL1_1 = SELECT id FROM vehicle WHERE territory_id IS NULL LIMIT ?,? +Number Of Inputs = 2 +SQL1_INPUTS = 1,2 +OUTPUT = 1 + +;2. Add all below in the end of the file. +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +;; Virtual Garage related queries | ADDED BY [ExAd]Jan +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; + +[loadTerritoryVehicles] +SQL1_1 = SELECT id, class FROM vehicle WHERE territory_id = ? +Number Of Inputs = 1 +SQL1_INPUTS = 1 +OUTPUT = 1,2-STRING + +[loadVehFromVG] +SQL1_1 = UPDATE vehicle SET territory_id = NULL WHERE id = ? +Number Of Inputs = 1 +SQL1_INPUTS = 1 + +[loadVehToVG] +SQL1_1 = UPDATE vehicle SET territory_id = ? WHERE id = ? +Number Of Inputs = 2 +SQL1_INPUTS = 1,2 \ No newline at end of file diff --git a/BattlEye/remoteexec.txt b/BattlEye/remoteexec.txt new file mode 100644 index 0000000..6261ef2 --- /dev/null +++ b/BattlEye/remoteexec.txt @@ -0,0 +1,2 @@ +//new +7 "" !="exadserver_fnc_clientrequest.*" \ No newline at end of file diff --git a/docs/VirtualGarage/examples.md b/docs/VirtualGarage/examples.md new file mode 100644 index 0000000..b5f1edf --- /dev/null +++ b/docs/VirtualGarage/examples.md @@ -0,0 +1 @@ +#Examples diff --git a/docs/VirtualGarage/installation.md b/docs/VirtualGarage/installation.md new file mode 100644 index 0000000..1c2f885 --- /dev/null +++ b/docs/VirtualGarage/installation.md @@ -0,0 +1,48 @@ +# Installation + +Remember for this plugin to work you first need to install +* [Core](https://github.com/Bjanski/ExAd/blob/Core/docs/core/installation.md) +* [XM8 Apps Improved](https://github.com/vitalymind/XM8_apps_improved) + +## Client + +* Place the folder "VirtualGarage" into "mpmissions\exile.\ExAdClient\" + +* Goto "mpmissions\exile.\ExAd\CfgFunctions" and uncomment + +_From_ +```cpp + //#include "VirtualGarage\CfgFunctions.cpp" +``` +_To_ +```cpp + #include "VirtualGarage\CfgFunctions.cpp" +``` +* Repeat last step for "CfgHints" + +* In "config.cpp" in the mission root folder, find class CfgExileCustomCode and add the following row +```js + ExileServer_system_territory_database_load = "EXOClient\CustomCode\ExileServer_system_territory_database_load.sqf"; +``` +* In "config.cpp" you can also add the ("CfgInteractionMenus" >> "Flag" >> "VG") class if you want to be able to fast load the app through your flag pole. + +* Now you can go into "mpmissions\exile.\ExAdClient\VirtualGarage\customize.sqf" and change to desirable settings. + +### XM8 App + +* Copy over "XM8_apps\apps\XM8_VG" +* Add the app inside "XM8_apps\XM8_apps_config.sqf" +* Add "mainVGSlide" in "XM8_apps\XM8_apps\XM8_apps_sliders.hpp" + +## Server + +* Copy over and pack "@ExileServer\addons\exad_vg" into a pbo. + +## Database +* Run the following sql command in you database. +```sql + ALTER TABLE `vehicle` ADD `territory_id` INT(11) UNSIGNED NULL DEFAULT NULL; + ALTER TABLE `vehicle` ADD CONSTRAINT `vehicle_ibfk_2` FOREIGN KEY (`territory_id`) REFERENCES `territory`(`id`) ON DELETE CASCADE ON UPDATE RESTRICT; +``` + +* Copy over content from "@ExileServer\extDB\sql_custom_v2\exile.ini" - Follow the instructions in the file. \ No newline at end of file diff --git a/docs/core/installation.md b/docs/core/installation.md index 8bccbcd..8e01d2f 100644 --- a/docs/core/installation.md +++ b/docs/core/installation.md @@ -28,11 +28,18 @@ class CfgFunctions #include "SOMEOTHER_ADDON\CfgFunctions.cpp" }; ``` -* Copy over "Core" from "mpmissions\Exile.Altis\ExAd\Core" - +* Copy over "Core" from "mpmissions\Exile.Altis\ExAdClient\" +* Copy over all files in "mpmissions\Exile.Altis\ExAdClient\" +These files includes the installation requirements for all other ExAd plugins +E.g in "mpmissions\Exile.Altis\ExAdClient\CfgFunctions.cpp" you can see that there are alot of lines commented out some of these need to be uncommented for plugins to work. Each plugin will describe more in detail which ones need to be adjusted. ## Server * Navigate to "@ExileServer\addons\" * Copy "exad_core" * Pack exad_core into a .pbo file. +## BattlEye + +I've put all plugins battleye exceptions in "BattlEye" +Check the files and append appropriate exceptions into your BattlEye files. + diff --git a/mpmissions/Exile.Altis/ExAdClient/CfgHints.cpp b/mpmissions/Exile.Altis/ExAdClient/CfgHints.cpp index e3fe1c7..b932ffb 100644 --- a/mpmissions/Exile.Altis/ExAdClient/CfgHints.cpp +++ b/mpmissions/Exile.Altis/ExAdClient/CfgHints.cpp @@ -15,6 +15,8 @@ See the License for the specific language governing permissions and limitations under the License. */ - - -//#include "VirtualGarage\CfgHints.cpp" \ No newline at end of file +class ExAd +{ + displayName = "ExAd Virtual Garage"; + #include "VirtualGarage\CfgHints.cpp" +}; \ No newline at end of file diff --git a/mpmissions/Exile.Altis/ExAdClient/VirtualGarage/CfgFunctions.cpp b/mpmissions/Exile.Altis/ExAdClient/VirtualGarage/CfgFunctions.cpp new file mode 100644 index 0000000..ee80f44 --- /dev/null +++ b/mpmissions/Exile.Altis/ExAdClient/VirtualGarage/CfgFunctions.cpp @@ -0,0 +1,28 @@ +/* + CfgFunctions.cpp + + Copyright 2016 Jan Babor + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ + + +class VirtualGarage +{ + file = "ExAdClient\VirtualGarage\Functions"; + class allowVGStore {}; + class fillVGList {}; + class loadVGDetailView {}; + class onBtnClickVG {}; + class postInit {file = "ExAdClient\VirtualGarage\postInit.sqf"; postInit = 1;}; +}; \ No newline at end of file diff --git a/mpmissions/Exile.Altis/ExAdClient/VirtualGarage/CfgHints.cpp b/mpmissions/Exile.Altis/ExAdClient/VirtualGarage/CfgHints.cpp new file mode 100644 index 0000000..49dc98f --- /dev/null +++ b/mpmissions/Exile.Altis/ExAdClient/VirtualGarage/CfgHints.cpp @@ -0,0 +1,38 @@ +/* + CfgHints.cpp + + Copyright 2016 Jan Babor + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ + +class VGStore +{ + displayName = "Vehicle stored"; + /*displayNameShort = "Your vehicle has been stored and is available through the Virtual Garage interface";*/ + description = "Your vehicle has been stored and is only available through the territory it has been stored at. "; + image = "ExAdClient\Icons\logo.paa"; + noImage = false; + tip = ""; + arguments[] = {}; +}; +class VGLoad +{ + displayName = "Vehicle loaded to world"; + description = "%1Your vehicle has been loaded to the world, the pin code is %11"; + image = "EXOClient\Icons\logo.paa"; + noImage = false; + tip = ""; + arguments[] = {"VGLoad select 0"}; + parameters[] = {"STRING"}; +}; \ No newline at end of file diff --git a/mpmissions/Exile.Altis/ExAdClient/VirtualGarage/CustomCode/ExileServer_system_territory_database_load.sqf b/mpmissions/Exile.Altis/ExAdClient/VirtualGarage/CustomCode/ExileServer_system_territory_database_load.sqf new file mode 100644 index 0000000..7e9f8ad --- /dev/null +++ b/mpmissions/Exile.Altis/ExAdClient/VirtualGarage/CustomCode/ExileServer_system_territory_database_load.sqf @@ -0,0 +1,55 @@ +/** + * ExileServer_system_territory_database_load + * + * Exile Mod + * www.exilemod.com + * © 2015 Exile Mod Team + * + * This work is licensed under the Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International License. + * To view a copy of this license, visit http://creativecommons.org/licenses/by-nc-nd/4.0/. + */ + +private["_territoryID","_data","_id","_owner","_position","_radius","_level","_flagTexture","_flagStolen","_flagStolenBy","_flagStealMessage","_lastPayed","_buildRights","_moderators","_flagObject"]; +_territoryID = _this; +_data = format ["loadTerritory:%1", _territoryID] call ExileServer_system_database_query_selectSingle; +_id = _data select 0; +_owner = _data select 1; +_name = _data select 2; +_position = +[ + _data select 3, + _data select 4, + _data select 5 +]; +_radius = _data select 6; +_level = _data select 7; +_flagTexture = _data select 8; +_flagStolen = _data select 9; +_flagStolenBy = _data select 10; +_flagStealMessage = _data select 11; +_lastPayed = _data select 12; +_buildRights = _data select 13; +_moderators = _data select 14; +_flagObject = createVehicle ["Exile_Construction_Flag_Static",_position, [], 0, "CAN_COLLIDE"]; +_flagObject setFlagTexture _flagTexture; +ExileLocations pushBack _flagObject; +_flagObject setVariable ["ExileTerritoryName", _name, true]; +_flagObject setVariable ["ExileDatabaseID", _id]; +_flagObject setVariable ["ExileOwnerUID", _owner, true]; +_flagObject setVariable ["ExileTerritorySize", _radius, true]; +_flagObject setVariable ["ExileTerritoryBuildRights", _buildRights, true]; +_flagObject setVariable ["ExileTerritoryModerators", _moderators, true]; +_flagObject setVariable ["ExileTerritoryLevel", _level, true]; +_flagObject setVariable ["ExileTerritoryLastPayed", _lastPayed]; +_flagObject call ExileServer_system_territory_maintenance_recalculateDueDate; +_flagObject setVariable ["ExileTerritoryNumberOfConstructions", _data select 15, true]; + +//////////////////////// +///// ExAd START ///// +//////////////////////// +_vehicles = format ["loadTerritoryVehicles:%1", _territoryID] call ExileServer_system_database_query_selectFull; +_flagObject setVariable ["ExAdVGVeh", _vehicles, true]; +//////////////////////// +///// ExAd END ///// +//////////////////////// +true \ No newline at end of file diff --git a/mpmissions/Exile.Altis/ExAdClient/VirtualGarage/Functions/fn_allowVGStore.sqf b/mpmissions/Exile.Altis/ExAdClient/VirtualGarage/Functions/fn_allowVGStore.sqf new file mode 100644 index 0000000..3a6969b --- /dev/null +++ b/mpmissions/Exile.Altis/ExAdClient/VirtualGarage/Functions/fn_allowVGStore.sqf @@ -0,0 +1,28 @@ +/* + fn_allowVGStore.sqf + + Copyright 2016 Jan Babor + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ +private ["_res","_flag"]; + +if(isNil "ExAdCurFlagNetId")exitWith{diag_log "ExAdClient: allowVGStore - ExAdCurFlagNetId is nil";false}; +_flag = objectFromNetId ExAdCurFlagNetId; + +_allowedVeh = ExAd_VG_MIN_ALLOWED_VEH + ExAd_VG_ALLOWED_VEH_MULTIPLE_FACTOR * (_flag getVariable ["ExileTerritoryLevel", 1]); +_storedVeh = count (_flag getVariable ["ExAdVGVeh", []]); + +_res = if(_allowedVeh > _storedVeh)then{true}else{false}; + +_res \ No newline at end of file diff --git a/mpmissions/Exile.Altis/ExAdClient/VirtualGarage/Functions/fn_fillVGList.sqf b/mpmissions/Exile.Altis/ExAdClient/VirtualGarage/Functions/fn_fillVGList.sqf new file mode 100644 index 0000000..9587505 --- /dev/null +++ b/mpmissions/Exile.Altis/ExAdClient/VirtualGarage/Functions/fn_fillVGList.sqf @@ -0,0 +1,36 @@ +/* + Copyright 2016 Jan Babor + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + +*/ + +private ["_list","_idc","_vehClass","_data","_name","_index","_pic"]; + +_list = _this select 0; +_idc = _this select 1; + +{ + _vehClass = if(typeName _x isEqualTo "ARRAY")then{_x select 1}else{typeOf _x}; + _data = if(typeName _x isEqualTo "ARRAY")then{format["%1",_x select 0]}else{netId _x}; + + _name = getText(configFile >> "CfgVehicles" >> _vehClass >> "displayName"); + _index = lbAdd[_idc,_name]; + _pic = getText(configFile >> "CfgVehicles" >> _vehClass >> "picture"); + lbSetPicture [_idc, _index, _pic]; + lbSetPictureColor [_idc, _index, [1,1,1,1]]; + lbSetData [_idc, _index, _data]; + lbSetTooltip [_idc, _index, _vehClass]; +}forEach _list; + +true \ No newline at end of file diff --git a/mpmissions/Exile.Altis/ExAdClient/VirtualGarage/Functions/fn_loadVGDetailView.sqf b/mpmissions/Exile.Altis/ExAdClient/VirtualGarage/Functions/fn_loadVGDetailView.sqf new file mode 100644 index 0000000..ca75dfa --- /dev/null +++ b/mpmissions/Exile.Altis/ExAdClient/VirtualGarage/Functions/fn_loadVGDetailView.sqf @@ -0,0 +1,27 @@ +/* + fn_loadVGDetailView.sqf + + Copyright 2016 Jan Babor + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ +params ["_text","_idc"]; +disableSerialization; + +_display = uiNameSpace getVariable ["RscExileXM8", displayNull]; + +if(isNull _display)exitWith{false}; + +(_display displayCtrl _idc) ctrlSetStructuredText parseText _text; + +true \ No newline at end of file diff --git a/mpmissions/Exile.Altis/ExAdClient/VirtualGarage/Functions/fn_onBtnClickVG.sqf b/mpmissions/Exile.Altis/ExAdClient/VirtualGarage/Functions/fn_onBtnClickVG.sqf new file mode 100644 index 0000000..4e6ed72 --- /dev/null +++ b/mpmissions/Exile.Altis/ExAdClient/VirtualGarage/Functions/fn_onBtnClickVG.sqf @@ -0,0 +1,40 @@ +/* + fn_onBtnClickVG.sqf + + Copyright 2016 Jan Babor + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ + +private ["_fnc","_idc","_data"]; + +_fnc = [_this,0,nil] call BIS_fnc_param; +_idc = [_this,1,nil] call BIS_fnc_param; + +diag_log str _this; + +if(isNil "ExAdCurFlagNetId" || isNil "_fnc" || isNil "_idc")exitWith{false}; + +_data = lbData [_idc, lbCurSel _idc]; + +diag_log str _data; + +if(count _data == 0)then{ + ['Whoops', ["You have to choose a vehicle in the proper list!!"]] call ExileClient_gui_notification_event_addNotification; +}else{ + [_fnc, [_data, ExAdCurFlagNetId, netId player]] call ExAd_fnc_serverDispatch; + closeDialog 0; +}; +disableUserInput false; + +true \ No newline at end of file diff --git a/mpmissions/Exile.Altis/ExAdClient/VirtualGarage/customize.sqf b/mpmissions/Exile.Altis/ExAdClient/VirtualGarage/customize.sqf new file mode 100644 index 0000000..f1cf87d --- /dev/null +++ b/mpmissions/Exile.Altis/ExAdClient/VirtualGarage/customize.sqf @@ -0,0 +1,27 @@ +/* + customize.sqf + + Copyright 2016 Jan Babor + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ + +ExAd_VG_MIN_ALLOWED_VEH = 5; //SCALAR - Minimun allowed vehicles in the virtual garage. + +ExAd_VG_ALLOWED_VEH_MULTIPLE_FACTOR = 3;//SCALAR - How many extra vehicle slots for each territory level. + +ExAd_VG_ACCESS_LEVEL = 1; //SCALAR - Lowest level that can access the Virtual Garage --> 1|2|3 -> Pleb|Moderator|Owner. + +ExAd_VG_CLEAN_ON_STORE = true; //BOOLEAN - If vehicle inventory should reset when stored. + +ExAd_VG_SHOW_ADVHINT = false //BOOLEAN - If the virtual garage should display an Advanced hint upon store and fetch. \ No newline at end of file diff --git a/mpmissions/Exile.Altis/ExAdClient/VirtualGarage/postInit.sqf b/mpmissions/Exile.Altis/ExAdClient/VirtualGarage/postInit.sqf new file mode 100644 index 0000000..16dd1de --- /dev/null +++ b/mpmissions/Exile.Altis/ExAdClient/VirtualGarage/postInit.sqf @@ -0,0 +1,20 @@ +/* + postInit.sqf + + Copyright 2016 Jan Babor + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + +*/ + +execVM "ExAdClient\VirtualGarage\customize.sqf"; \ No newline at end of file diff --git a/mpmissions/Exile.Altis/XM8_apps/Icons/apps_icon.paa b/mpmissions/Exile.Altis/XM8_apps/Icons/apps_icon.paa new file mode 100644 index 0000000000000000000000000000000000000000..caef81d4e5ffc5a6002bf58d9e74e0e4dd9195b2 GIT binary patch literal 22016 zcmeHP4NO(%8U9YW2StQl3wJT0$W6rBkuE7+db@?idzc$PQ^#$*SDUy^g*4NYpR}oL zx;k*!5SMf~XUS}3u4`SpY>lGZ(P|rED%#j0n^_0mD67zlx(UQHyyyFUzay&o`MKW3`73g5jIkRxZn(JoMD8+@RXCFKbC>3kEZ{@( z^1Qqv3ID6{sl}gPco=)p%h+xoV_o=+-BnW>(%8dWAuR+f1S|wB1S|wB1S|wB1S|wB z1nxcr3aHAqZdGN>=W~dw56Wf!f__X_NQT!zdAH z;N-eReJ#DpU>(n2z^s(=C5IdQpCwN%9<$e0DH-apn{b!3tS9wbT_o5UuF?3e{|r8Y z$FJ*wm(@cqyvNWJpCykEkNRGOXT?W#JRSOP2>(^=9w#n@(x1dhrJqIP|0*l^Stc$j zjTdfmOY{GqdO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c(hh< ze97!`yzO7*zRHTvVL3u*bF=>;7DqT6_^U&vZS8T&%ZK%Et22aX%E zx{vOLwh^>YVfph|A=&<(d$8u%(AV^Ec6BJ55(t*J=J3A2`C83PeN6oyj~&*YI+p2p z!vhVD!?eve0dml6UPAhB>~DpBXl5GNm-l(m@~i054SY6SqJP6phMc1AdfdNX+qScN zyi~rOMte%-)vFU~AINg0DNBTkQ!4~&$0@I;^uperF}Im_ySy91VO{T8(`oCR zw~Bt!Ub|Vdu0XrF*VOEp@5&*O0&E-UYHm3MJ} z^eZ2jtbNV-vz+lwTZ+#m|K~$Jee`-_Bm4H>7ku{-K1}4Z9#`bFF4p{4UM0TD_^=(V zte9PlqmnR~qxzwGwhixW-2VE;{)L7Lx?Xk7>w4^`y#68}GUxyEvys+rISRlp(%vS+ zCvCL59`<&bEX7rvR(J!+BR{nH-~9KM-}Iec-EHKj4o40XW_mG+>s5o@$S*(mVrxYw zvY|9)B^E^N<|dl>H_KVqP#!?S`E>x0LAA3szEqQ0u1~BJ81T|$91lY_+&S@Wl$mba zF4;~?fdZ5H?Bc#Sss?BkG+BFz2X&@q*(H-2;2eV%URw7~-kP@fvNn>1+}zydCfFL| z%C2RLDGzg)FquBe#FXqgDcK}T2*09XMd`^ErF`@TQSc1V>{vf!?{Kgk7k|+Ge7F7* z8o>4CmuFsROKLdF<70Ln&$b0;Q?SwS#hdbf{8CFvkOl;Jfc-c)`XHm9nQSJL7+b{( zpJCrxvVf8WRi5Mu`NEf;tbbaUS?cRAz4B+BO}rGvm-v3-iz}T5+mg?Q78Q6N6%KVC N`pU2I5K=_L{SVUx6Wag) literal 0 HcmV?d00001 diff --git a/mpmissions/Exile.Altis/XM8_apps/Icons/generic_app.paa b/mpmissions/Exile.Altis/XM8_apps/Icons/generic_app.paa new file mode 100644 index 0000000000000000000000000000000000000000..0ce2f5b56bfca305973e9012a1369fa6148d2e5a GIT binary patch literal 22016 zcmeHPeQaA-6+d>I)rPsTw0SAeXfLX}si8w+BBjy_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$o$6SKg<8k3FGs>n-jR)64rN>hjI89>R+UP zGx^W*Uqn8)>OU(z+~nWnf9<^gaY`Q#-@Jmv3;VTe6t6P--<0_8)05l2qrboQ6mIOa zTJgy&z$tv*0sWUhhL31vFlCqn|4g%5iy(1bMgJAsgq1SX5L)@5t&~L;IfLKzt7&IbT*3NZEbk0SdgdUeRf30=Qmg^ z)-vLM`#bp7o`L`NYNr85{XGUeFz}*))t2e)1He<&i-hBAb+&TS|NQ!|5H1`0-@Qda zgVg!ky~Wu7l^&N@|F;<*Q;OpsJ*E`5H9r;XET8_bH)Z6%H)Z6%^tinE=dUdbSNumZky)ngLNY(;pcX&m#A!V z5`N0De2Hp?<7n0);MM$U7-hO`|KzvmG>j~}ab^e5dV_7mWe9E7-x7a-@$a6p$8eH{ z@p0y^Itgz}5<}R#{zJT|JmYB{%CQUcQ1fGqmr#JmZq#P(oIEf>%c9PmRn|M-ia8Sp zU%E<@#wFFKX!+^4!SL@Shz)Ni7UB+f1KcY$WiEs=7pUG(;Okv#?H5stqUFEV3FF>t zTKjubeQogjbB}76pGN81lf#T%?}VDI>p%)kt;37r(c5LqFTby?Um^}Q`46}K{dp1N zBrq)Ei8MyXhL)=QD#sfp8D}OYNoU~DWu{q}LJ zd~9FheO^BHQ+u)UxIvfX>QRVodtT`M^TF=Ki@bbUwu2qlFyK*||C+g!%8X&MQx3<^ z;Obpd_NM8(j$>~aRB(;0yn7_`ZcR63>u@;ayPrqX4sAV0n>4rtmu=XiqCD?E^T;or ToO$k^9h2SP+Zl;OxWwUq%MohH literal 0 HcmV?d00001 diff --git a/mpmissions/Exile.Altis/XM8_apps/XM8_apps_config.sqf b/mpmissions/Exile.Altis/XM8_apps/XM8_apps_config.sqf new file mode 100644 index 0000000..617c5a6 --- /dev/null +++ b/mpmissions/Exile.Altis/XM8_apps/XM8_apps_config.sqf @@ -0,0 +1,13 @@ +/* + Improved XM8 apps by vitaly'mind'chizhikov + Official forum thread: + Original idea by Shix. +*/ + +XM8_apps_app1 = [ + "ExAd Virtual Garage", + "XM8_apps\apps\XM8_VG\Icons\apps_icon.paa", + {call XM8_VG_checkNearByFlags}, + TRUE, + "XM8_apps\apps\XM8_VG\scripts\XM8_VG_init.sqf" +]; \ No newline at end of file diff --git a/mpmissions/Exile.Altis/XM8_apps/XM8_apps_sliders.hpp b/mpmissions/Exile.Altis/XM8_apps/XM8_apps_sliders.hpp new file mode 100644 index 0000000..fdc3448 --- /dev/null +++ b/mpmissions/Exile.Altis/XM8_apps/XM8_apps_sliders.hpp @@ -0,0 +1,14 @@ +class CfgXM8 { + //This slide use IDCs from 104140 to 104156 + class sideApps { + controlID = 104140; + title = "XM8 Apps"; + onLoadScript = ""; + }; + //This slide use IDCs from 352500 to + class mainVGSlide { + controlID = 352500; + title = "Virtual Garage"; + onLoadScript = "XM8_apps\apps\XM8_VG\scripts\XM8_VG_mainVGSlide_onLoad.sqf"; + }; +}; \ No newline at end of file diff --git a/mpmissions/Exile.Altis/XM8_apps/apps/XM8_VG/Icons/apps_icon.paa b/mpmissions/Exile.Altis/XM8_apps/apps/XM8_VG/Icons/apps_icon.paa new file mode 100644 index 0000000000000000000000000000000000000000..cf7874c46898b02785cabf1400c03ce11240e8a0 GIT binary patch literal 38878 zcmeFZd011|{yw_)lmRjU0TC(9u*t+I0wRVG5Ro7th6EypK}3&OK}2!f8I*b~wHz5m zN)Q#TTJ=;!u+}iBRmefKd=80{C{xxJpg=$Ur*^sPpS0p zQvomU=? z6kaxC$j~j)*gho;<#93Ya{TMwJcQ-}>ZKV&{fFLF{{-KklWXVH6(EjU(#b{8-@x*< z0)g8dej=QkgmE5gb(XFkA5HgGJhCm^|D!*Zg&4=(1(}<$W$C-xN4_;9z-|1T_AzfT z54mR=@&5@I8`+PHbmWitGVAvhYIvR#WH)|7M+5DR!T6HhFG(@58n^tc1yAJnPu9Ho z3c%0!$;adR)>OaoTV|%sTSs_nfy1_jLBOkv-iBEc6$n@tdmFCnViY zzU*DZDwH7AFE3*@GVd|4lf+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UTU$hK>eDL>YrqNt{WzkOSffXAc=PvdL^4rl)-N#Fnrv zZC*ahCW?*B=(R#Sjppe+zwgBz91y|3-ud5u-uzF5pyk00s`CNxA1MYMr)6}e)2+f) zl=_uPkqf9A7&g|fQf#(b!JhL2XB-lF7m-22zS8_n*8BD8hKU1BEHfVuU6;0j_bJAfR+%u3Sm*M!FAVcoj%BX115?wflsYo(wzRYeR`Ve` zdxl#uZ8p!GHER$tbEI+o$*=<7SFg5{>dsk)@_qqtb(|KY-{>^NzQ6IuyTpv+1=wJn z{ElztvFSQeepNGO7bIAo3Cov`rNE4M?yX1GX2O!_k|dk}w{S?oTZYhU1@EWyt+6Q)*p`xETON{)(~&GM=*}exF|(7veYU6kJ0OQ{ zr;j*2yr(Q*u}tBZ4Kp17z5SZZaL@euq66K$6Tlk}_}S$h)bsuSX>3cD0$EI{L?`@1 zYQQCdnq3;N>i;nuvhDMLr=I1Y8qq2$6F=G}LVNHq?6kVrhHID<_z0Xd4Taj3rr9{CV&Sc|TW> "CfgVehicles" >> (_data select 1) >> "picture"); + ctrlSetText [_picCtrl, _pic]; + + ["requestVGDetailInfo", [_ref, ExAdCurFlagNetId, (profileNamespace getVariable["ExAd_StreamFriendlyUI",0]), netId player, _strCtrl]] call ExAd_fnc_serverDispatch; +}; \ No newline at end of file diff --git a/mpmissions/Exile.Altis/XM8_apps/apps/XM8_VG/scripts/XM8_VG_checkNearByFlags.sqf b/mpmissions/Exile.Altis/XM8_apps/apps/XM8_VG/scripts/XM8_VG_checkNearByFlags.sqf new file mode 100644 index 0000000..3195f2d --- /dev/null +++ b/mpmissions/Exile.Altis/XM8_apps/apps/XM8_VG/scripts/XM8_VG_checkNearByFlags.sqf @@ -0,0 +1,30 @@ +/* +function: XM8_VG_checkNearByFlags +file: XM8_VG\scripts\XM8_VG_checkNearByFlags.sqf + +XM8 VG By Jan Babor +Part of the ExAd Virtual Garage script +*/ +private ["_flags","_flag"]; +_flags = nearestObjects [player,["Exile_Construction_Flag_Static"],150]; + +if(count _flags == 0)exitWith{ + ["Whoops", ["No connetion to a Virtual Garage"]] call ExileClient_gui_notification_event_addNotification; + ["sideApps", 1] call ExileClient_gui_xm8_slide +}; + +_flag = _flags select 0; +if((player distance _flag) > (_flag getVariable ["ExileTerritorySize", 50]))exitWith{ + ["Whoops", ["No connetion to a Virtual Garage"]] call ExileClient_gui_notification_event_addNotification; + ["sideApps", 1] call ExileClient_gui_xm8_slide +}; + +if((([_flag, getPlayerUID player] call ExileClient_util_territory_getAccessLevel) select 0) >= ExAd_VG_ACCESS_LEVEL)then{ + ExAdCurFlagNetId = netId _flag; + ["mainVGSlide", 0] call ExileClient_gui_xm8_slide; + call XM8_VG_loadContent; +} +else +{ + ["Whoops", ["You aren't eligible to access this virtual garage!"]] call ExileClient_gui_notification_event_addNotification; +} \ No newline at end of file diff --git a/mpmissions/Exile.Altis/XM8_apps/apps/XM8_VG/scripts/XM8_VG_init.sqf b/mpmissions/Exile.Altis/XM8_apps/apps/XM8_VG/scripts/XM8_VG_init.sqf new file mode 100644 index 0000000..e83ac38 --- /dev/null +++ b/mpmissions/Exile.Altis/XM8_apps/apps/XM8_VG/scripts/XM8_VG_init.sqf @@ -0,0 +1,27 @@ +/* + XM8 VG app by Jan Babor + + file: XM8_VG\scripts\XM8_VG_init.sqf + + This script will be executed once, when player login. It is executed straight from initLocalPlayer.sqf. + This is best place to compile functions, define global variables and read gonfiguration files used in app. +*/ + +params ["_pathToAppFolder"]; + +XM8_VG_mainVGSlideIDCmap = []; + +{ + if (isNil _x) then { + private ["_code"]; + _code = compileFinal (preprocessFileLineNumbers (format (["%1scripts\%2.sqf",_pathToAppFolder,_x]))); + if (isNil "_code") then {_code = compileFinal ""}; + missionNamespace setVariable [_x, _code]; + }; +} forEach [ + "XM8_VG_mainVGSlide_onLoad", + "XM8_VG_checkNearByFlags", + "XM8_VG_loadContent" +]; + +call compile preProcessFileLineNumbers format ["%1XM8_VG_config.sqf",_pathToAppFolder]; \ No newline at end of file diff --git a/mpmissions/Exile.Altis/XM8_apps/apps/XM8_VG/scripts/XM8_VG_loadContent.sqf b/mpmissions/Exile.Altis/XM8_apps/apps/XM8_VG/scripts/XM8_VG_loadContent.sqf new file mode 100644 index 0000000..77ad4dd --- /dev/null +++ b/mpmissions/Exile.Altis/XM8_apps/apps/XM8_VG/scripts/XM8_VG_loadContent.sqf @@ -0,0 +1,43 @@ +/* +function: XM8_VG_loadContent +file: XM8_VG\scripts\XM8_VG_loadContent.sqf + +XM8 VG by Jan Babor +Part of the ExAd Virtual Garage script +*/ +private ["_display","_error","_slides","_getControl","_flag","_allowedVeh","_storedVeh","_strTxtVehCntColor","_strTxtVehCnt"]; + +_display = uiNameSpace getVariable ["RscExileXM8", displayNull]; +if (isNull _display) exitWith {_error = "Error loading XM8 VG app, display is null"; systemChat _error; diag_log _error;}; +_slides = _display displayCtrl 4007; +if (isNull _slides) exitWith {_error = "Error loading XM8 VG app, slides control is null"; systemChat _error; diag_log _error;}; + +_getControl = { + params ["_key"]; + private ["_ctrl","_idc","_index","_slideClassName"]; + _ctrl = controlNull; + _slideClassName = "mainVGSlide"; //Classname of your slide + _map = XM8_VG_mainVGSlideIDCmap; //Variable name of IDC map of slide + _index = _map find _key; + if (_index != -1) then { + _idc = ((getNumber (missionConfigFile >> "CfgXM8" >> _slideClassName >> "controlID")) + _index); + _ctrl = _display displayCtrl _idc; + }; + _ctrl; +}; + + +_flag = if(typeName ExAdCurFlagNetId == "STRING")then{objectFromNetId ExAdCurFlagNetId}else{ExAdCurFlagNetId}; + +_allowedVeh = ExAd_VG_MIN_ALLOWED_VEH + ExAd_VG_ALLOWED_VEH_MULTIPLE_FACTOR * (_flag getVariable ["ExileTerritoryLevel", 1]); +_storedVeh = count (_flag getVariable ["ExAdVGVeh", []]); +_strTxtVehCntColor = if(_allowedVeh > _storedVeh)then{"#FFFFFF"}else{"#B22400"}; + +_strTxtVehCnt = "SubTitle1Cnt" call _getControl; +_strTxtVehCnt ctrlSetStructuredText parseText format ["%2/%3",_strTxtVehCntColor,_storedVeh,_allowedVeh]; + +[(objectFromNetId ExAdCurFlagNetId) getVariable ["ExAdVGVeh", []],ctrlIDC ("StoreVehList" call _getControl)] call ExAd_fnc_fillVGList; + +[[_flag, ["Car","Air"],_flag getVariable ["ExileTerritorySize", 50]] call ExAd_fnc_getNearByLocalVeh,ctrlIDC ("NearVehicleList" call _getControl)] call ExAd_fnc_fillVGList; + +("InfoCB" call _getControl) cbSetChecked ((profileNamespace getVariable["ExAd_StreamFriendlyUI",0]) == 1); \ No newline at end of file diff --git a/mpmissions/Exile.Altis/XM8_apps/apps/XM8_VG/scripts/XM8_VG_mainVGSlide_onLoad.sqf b/mpmissions/Exile.Altis/XM8_apps/apps/XM8_VG/scripts/XM8_VG_mainVGSlide_onLoad.sqf new file mode 100644 index 0000000..51b9132 --- /dev/null +++ b/mpmissions/Exile.Altis/XM8_apps/apps/XM8_VG/scripts/XM8_VG_mainVGSlide_onLoad.sqf @@ -0,0 +1,154 @@ +/* + XM8 VG app by Jan Babor + + Virtual Garage app that works with the ExAd Virtual Garage plugin. + + file: XM8_emptyApp\scripts\XM8_VG_mainVGSlide_onLoad.sqf + function: XM8_VG_mainVGSlide_onLoad +*/ +private ["_makeButton","_makeBackground","_makeStructuredText","_makePicture","_makeList","_getNextIDC","_pW","_pH","_display","_slides","_unloadScript","_error","_thisSlide"]; + +_makeButton = { + params ["_parent","_idc","_position","_action","_text","_tooltip"]; + private ["_ctrl"]; + _ctrl = _display ctrlCreate ["RscButtonMenu",_idc,_parent]; + _ctrl ctrlSetPosition _position; + _ctrl ctrlSetText _text; + _ctrl ctrlSetEventHandler ["ButtonClick",_action]; + _ctrl ctrlSetTooltip _tooltip; + _ctrl ctrlCommit 0; + _ctrl; +}; + +_makeBackgroundGUI = { + params ["_parent","_idc","_position"]; + private ["_ctrl"]; + _ctrl = _display ctrlCreate ["RscBackgroundGUI", _idc, _parent]; + _ctrl ctrlSetPosition _position; + _ctrl ctrlCommit 0; + _ctrl ctrlSetBackgroundColor [0,0,0,0.5]; + _ctrl; +}; + +_makeFrame = { + params ["_parent","_idc","_position"]; + private ["_ctrl"]; + _ctrl = _display ctrlCreate ["RscFrame", _idc, _parent]; + _ctrl ctrlSetPosition _position; + _ctrl ctrlEnable false; + _ctrl ctrlCommit 0; + _ctrl; +}; + +_makeStructuredText = { + params ["_parent","_idc","_position","_text","_font","_size","_color","_align","_shadow"]; + private ["_ctrl"]; + _ctrl = _display ctrlCreate ["RscStructuredText", _idc, _parent]; + _ctrl ctrlSetPosition _position; + _ctrl ctrlSetStructuredText (parseText format ["%1", _text,_size,_color, _align,_font,_shadow]); + _ctrl ctrlEnable false; + _ctrl ctrlCommit 0; + _ctrl; +}; + +_makePicture = { + params ["_parent","_idc","_position","_picture","_color","_enable","_keepAspect","_tooltip"]; + private ["_ctrl"]; + _ctrl = _display ctrlCreate [(if (_keepAspect) then {"RscPictureKeepAspect"} else {"RscPicture"}), _idc, _parent]; + _ctrl ctrlSetPosition _position; + _ctrl ctrlSetText _picture; + _ctrl ctrlSetTextColor _color; + _ctrl ctrlEnable _enable; + _ctrl ctrlSetTooltip _tooltip; + _ctrl ctrlCommit 0; + _ctrl; +}; + +_makeList = { + params ["_parent","_idc","_position","_actionOnSelChanged","_tooltip"]; + private ["_ctrl"]; + _ctrl = _display ctrlCreate ["RscListBox",_idc,_parent]; + _ctrl ctrlSetPosition _position; + _ctrl ctrlSetEventHandler ["LBSelChanged",_actionOnSelChanged]; + _ctrl ctrlSetTooltip _tooltip; + _ctrl ctrlCommit 0; + _ctrl; +}; + +_makeCheckBox = { + params ["_parent","_idc","_position","_actionOnSelChanged","_tooltip"]; + private ["_ctrl"]; + _ctrl = _display ctrlCreate ["RscCheckBox",_idc,_parent]; + _ctrl ctrlSetPosition _position; + _ctrl ctrlSetEventHandler ["CheckedChanged",_actionOnSelChanged]; + _ctrl ctrlSetTooltip _tooltip; + _ctrl ctrlCommit 0; + _ctrl; +}; + +_getNextIDC = { + params ["_key"]; + private ["_slideClassName","_baseIDC","_result","_map"]; + _slideClassName = "mainVGSlide"; + _map = XM8_VG_mainVGSlideIDCmap; + _baseIDC = getNumber (missionConfigFile >> "CfgXM8" >> _slideClassName >> "controlID"); + _result = _baseIDC + (_map pushBack _key); + _result; +}; + +_pW = 0.025; +_pH = 0.04; +_leftCol = 1; +_leftColW = 12.8; +_rightCol = _leftCol + _leftColW + 2; +_rightColW = _leftColW + 3; +_margin = 0.2; + +_display = uiNameSpace getVariable ["RscExileXM8", displayNull]; +if (isNull _display) exitWith {_error = "Error loading XM8 VG app, display is null"; systemChat _error; diag_log _error;}; +_slides = _display displayCtrl 4007; +if (isNull _slides) exitWith {_error = "Error loading XM8 VG app, slides control is null"; systemChat _error; diag_log _error;}; + +_unloadScript = ' + ExAd_Cur_Flag_NetId = nil; +'; +_display displayAddEventHandler ["unload",_unloadScript]; + +XM8_VG_mainVGSlideIDCmap = []; + +_thisSlide = _display ctrlCreate ["RscExileXM8Slide",("mainVGSlide" call _getNextIDC),_slides]; + +[_thisSlide,("backButton" call _getNextIDC),[27.6 * _pW, 17.7 * _pH, 6 * _pW, 1 * _pH],'["sideApps", 1] call ExileClient_gui_xm8_slide;',"GO BACK",""] call _makeButton; + +/*Stored Vehicle Details*/ +[_thisSlide,("InfoTitle" call _getNextIDC),[_rightCol * _pW, 2.75 * _pH, _rightColW * _pW, 1 * _pH],"Stored Vehicle Detail","PuristaMedium",1.2,"#ffffff","left",1] call _makeStructuredText; + +[_thisSlide,("InfoBgBox" call _getNextIDC),[_rightCol * _pW, 4 * _pH, _rightColW * _pW, 13.5 * _pH]] call _makeBackgroundGUI; + +_idcInfoPic = "InfoPic" call _getNextIDC; +[_thisSlide,_idcInfoPic,[(_rightCol + 9) * _pW, 4 * _pH, 6.75 * _pW, 5.5 * _pH],"",[1,1,1,1],false,true,""] call _makePicture; + +_idcInfoStr = "InfoVehStr" call _getNextIDC; +[_thisSlide,_idcInfoStr,[(_rightCol + _margin) * _pW, (4 + _margin) * _pH, (_rightColW - 2 * _margin) * _pW, (13.5 - 2 * _margin) * _pH],"","PuristaMedium",0.75,"#ffffff","left",1] call _makeStructuredText; + +[_thisSlide,("InfoCBStr" call _getNextIDC),[(_rightCol + _margin + 0.4) * _pW, (16.5 - _margin + 0.25 ) * _pH, (_rightColW - 2 * _margin) * _pW, (13.5 - 2 * _margin) * _pH],"Stream friendly UI","PuristaMedium",0.65,"#ffffff","left",1] call _makeStructuredText; + +[_thisSlide,("InfoCB" call _getNextIDC),[(_rightCol + _margin) * _pW, (16.5 - _margin + 0.2) * _pH, 0.75 * _pW, 0.75 * _pH],'profileNamespace setVariable["ExAd_StreamFriendlyUI",_this select 1]',"Toogle - Stream friendly UI"] call _makeCheckBox; + +/*Stored Vehicles*/ +[_thisSlide,("SubTitle1" call _getNextIDC),[_leftCol * _pW, 2.75 * _pH, _leftColW * _pW, 1 * _pH],"Stored","PuristaMedium",1.2,"#ffffff","left",1] call _makeStructuredText; + +[_thisSlide,("SubTitle1Cnt" call _getNextIDC),[_leftCol * _pW, 3 * _pH, _leftColW * _pW, 1 * _pH],"","PuristaMedium",1,"#ffffff","right",1] call _makeStructuredText; + +_idcStoredVehList = "StoreVehList" call _getNextIDC; +[_thisSlide,_idcStoredVehList,[_leftCol * _pW, 4 * _pH, _leftColW * _pW, 5 * _pH],format["[_this select 0,%1,%2] call XM8_VG_elChanged",_idcInfoPic,_idcInfoStr],""] call _makeList; + +[_thisSlide,("fetchButton" call _getNextIDC),[_leftCol*_pW, 9*_pH, _leftColW*_pW, 1*_pH],format["disableUserInput true;['VGLoad', %1] call ExAd_fnc_onBtnClickVG",_idcStoredVehList],"Fetch",""] call _makeButton; + +/*Nearby vehicles*/ +[_thisSlide,("SubTitle2" call _getNextIDC),[_leftCol * _pW, 10.25 * _pH, _leftColW * _pW, 1 * _pH],"In Radius","PuristaMedium",1.2,"#ffffff","left",1] call _makeStructuredText; + +_idcNearVehList = "NearVehicleList" call _getNextIDC; +[_thisSlide,_idcNearVehList,[_leftCol * _pW, 11.5 * _pH, _leftColW * _pW, 5 * _pH],"",""] call _makeList; + +[_thisSlide,("storeButton" call _getNextIDC),[_leftCol * _pW, 16.5 * _pH, _leftColW * _pW, 1 * _pH],format["if(call ExAd_fnc_allowVGStore)then{disableUserInput true;['VGStore', %1] call ExAd_fnc_onBtnClickVG}else{['Whoops', ['%2']] call ExileClient_gui_notification_event_addNotification}",_idcNearVehList,localize "STR_ExAd_VIRTUALGARAGE_NOTI_FULL"],"Store",""] call _makeButton; diff --git a/mpmissions/Exile.Altis/XM8_apps/scripts/ExileClient_gui_xm8_show.sqf b/mpmissions/Exile.Altis/XM8_apps/scripts/ExileClient_gui_xm8_show.sqf new file mode 100644 index 0000000..b09f3e2 --- /dev/null +++ b/mpmissions/Exile.Altis/XM8_apps/scripts/ExileClient_gui_xm8_show.sqf @@ -0,0 +1,175 @@ +/** +* ExileClient_gui_xm8_show +* +* Exile Mod +* www.exilemod.com +* © 2015 Exile Mod Team +* +* This work is licensed under the Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International License. +* To view a copy of this license, visit http://creativecommons.org/licenses/by-nc-nd/4.0/. +*/ + +/* + XM8 apps Imporeved by vitaly'mind'chizhikov + Based on idea XM8 apps by Shix. see http://www.exilemod.com/topic/9040-xm8-apps/?page=1 + Original function from Exile 0.9.6 +*/ + +private["_display","_control","_slideControlID","_slideName","_slideTitle","_slideControl","_titleControl","_toSlideOpenFunction","_hideSideApps"]; +disableSerialization; +createDialog "RscExileXM8"; +ExileClientXM8IsVisible = true; +_display = uiNameSpace getVariable ["RscExileXM8", displayNull]; +if (ExileClientXM8IsPowerOn) then { + _control = _display displayCtrl 4002; + _control ctrlSetFade 1; + _control ctrlCommit 0; +} else { + { + _control = _display displayCtrl _x; + _control ctrlSetFade 1; + _control ctrlCommit 0; + } forEach [4002,4003,4004,4005,4007,4001,4010,4030,4020]; +}; +true call ExileClient_gui_postProcessing_toggleDialogBackgroundBlur; +if (ExileClientXM8CurrentSlide isEqualTo "party") then { + if (ExileClientPartyID isEqualTo -1) then { + ExileClientXM8CurrentSlide = "apps"; + }; +}; + +private ["_sliders","_appSlide","_newTerritoryBut","_newTerritoryPic","_sideAppsBut","_sideAppsPic","_newSliderIDC","_newSlider","_buttonBack", +"_makeButtonCtrl","_pW","_pH"]; +_pW = 0.025; +_pH = 0.04; +_sliders = _display displayCtrl 4007; +_appSlide = _sliders controlsGroupCtrl 4040; + +//Lets create XM8_apps slide manually, as we are unable to change RscExileXM8 directly in config. +_newSliderIDC = getNumber (missionConfigFile >> "CfgXM8" >> "sideApps" >> "controlID"); +_newSlider = _display ctrlCreate ["RscExileXM8Slide", _newSliderIDC, _sliders]; + +//Lets fill our slider with contents. First lets make go back button +_buttonBack = _display ctrlCreate ["RscButtonMenu",_newSliderIDC + 1,_newSlider]; +_buttonBack ctrlSetPosition [27.6*_pW,17.7*_pH,6*_pW,1*_pH]; +_buttonBack ctrlSetText "GO BACK"; +_buttonBack ctrlSetEventHandler ["ButtonClick","['apps', 1] call ExileClient_gui_xm8_slide"]; +_buttonBack ctrlCommit 0; + +//We hide sideApps in order to be compatible with legacy apps. +_hideSideApps = ' + disableSerialization; + _display = uiNameSpace getVariable ["RscExileXM8", displayNull]; + _sliders = _display displayCtrl 4007; + _sideAppsIDC = getNumber (missionConfigFile >> "CfgXM8" >> "sideApps" >> "controlID"); + _appSlide = _display displayCtrl _sideAppsIDC; + _appSlide ctrlShow false; + _appSlide ctrlCommit 0; +'; + +//We make app buttons with this function +_makeButtonCtrl = { + params ["_idc","_pos","_text","_script","_parent","_pic","_compatible"]; + private ["_ctrl"]; + _ctrl = _display ctrlCreate ["RscExileXM8AppButton1x1",_idc,_parent]; + _ctrl ctrlSetPosition [_pos select 0,_pos select 1,6 * _pW, 4.8 * _pH]; + _ctrl ctrlSetText _text; + if (!_compatible) then { + _ctrl ctrlSetEventHandler ["ButtonClick",_hideSideApps]; + + } else { + _ctrl ctrlSetEventHandler ["ButtonClick",""]; + }; + _ctrl ctrlAddEventHandler ["ButtonClick",format ["call %1",_script]]; + _ctrl ctrlCommit 0; + + _ctrl = _display ctrlCreate ["RscPictureKeepAspect",-1,_parent]; + _ctrl ctrlSetText _pic; + _ctrl ctrlSetPosition [_pos select 0,(_pos select 1) + 0.01,6 * _pW, 2.8 * _pH]; + _ctrl ctrlEnable false; + _ctrl ctrlCommit 0; +}; +//Lets try to create 15 buttons, if some buttons in XM8_apps_config are commented, they will be scipped + +for "_i" from 1 to 15 do { + private ["_pos", "_data"]; + if (!isNil (format ["XM8_apps_app%1", _i])) then { + _data = call compile format ["XM8_apps_app%1", _i]; + _pos = [0,0]; + if (_i in [1,2,3,4,5]) then { + _pos set [0, (0.4 + ((_i-1) * 6.8)) * _pW]; + _pos set [1, 2 * _pH]; + }; + if (_i in [6,7,8,9,10]) then { + _pos set [0, (0.4 + (((_i-1) - 5) * 6.8)) * _pW]; + _pos set [1, 7.2 * _pH]; + }; + if (_i in [11,12,13,14,15]) then { + _pos set [0, (0.4 + (((_i-1) - 10) * 6.8)) * _pW]; + _pos set [1, 12.4 * _pH]; + }; + [(_newSliderIDC + 1 + _i) ,_pos,(_data select 0),str(_data select 2),_newSlider,(_data select 1),(_data select 3)] call _makeButtonCtrl; + }; +}; + +/* +We need some space to put XM8_apps button, for that lets cut territory button in half. +In fact we cant re-possition button as it will render picture (textureNoShortcut) incorrectly. +So lets make new 'territory' button, smaller then original one. +We will hide old button in ExileClient_gui_xm8_slide_apps_onOpen and ExileClient_gui_xm8_slide +*/ +_newTerritoryBut = _display ctrlCreate ["RscExileXM8AppButton1x1",(_newSliderIDC + 15),_appSlide]; +_newTerritoryBut ctrlSetPosition [(23.5 - 3) * _pW,(9.5 - 2) * _pH,6 * _pW, 5 * _pH]; +_newTerritoryBut ctrlSetText getText (configFile >> "CfgXM8" >> "territory" >> "title"); +_newTerritoryBut ctrlSetEventHandler ["ButtonClick","['territory', 0] call ExileClient_gui_xm8_slide"]; +_newTerritoryBut ctrlCommit 0; +_newTerritoryPic = _display ctrlCreate ["RscPictureKeepAspect",(_newSliderIDC + 17),_appSlide]; +_newTerritoryPic ctrlSetText "\exile_assets\texture\ui\xm8_app_territory_ca.paa"; +_newTerritoryPic ctrlSetPosition [(25 - 3) * _pW,(10 - 2) * _pH,(6 * _pW) * 0.5, (5 * _pH) * 0.5]; +_newTerritoryPic ctrlEnable false; +_newTerritoryPic ctrlCommit 0; + +//Now lets make New button for XM8_apps inside app slider. +_sideAppsBut = _display ctrlCreate ["RscExileXM8AppButton1x1",(_newSliderIDC + 16),_appSlide]; +_sideAppsBut ctrlSetPosition [(30 - 3) * _pW,(9.5 - 2) * _pH,6 * _pW, 5 * _pH]; +_sideAppsBut ctrlSetText getText (missionConfigFile >> "CfgXM8" >> "sideApps" >> "title"); +_sideAppsBut ctrlSetEventHandler ["ButtonClick","['sideApps', 0] call ExileClient_gui_xm8_slide"]; +_sideAppsBut ctrlCommit 0; +_sideAppsPic = _display ctrlCreate ["RscPictureKeepAspect",(_newSliderIDC + 18),_appSlide]; +_sideAppsPic ctrlSetText format ["%1%2",XM8_apps_folderPath, "XM8_apps\icons\apps_icon.paa"]; +_sideAppsPic ctrlSetPosition [(31.5 - 3) * _pW,(10 - 2) * _pH,(6 * _pW) * 0.5, (5 * _pH) * 0.5]; +_sideAppsPic ctrlEnable false; +_sideAppsPic ctrlCommit 0; + +{ + //We dont have configured slides, thus we create it via scripting. We do that by executing slide creating scripts. + _slideOnLoadScript = getText (_x >> "onLoadScript"); + if (!isNil "_slideOnLoadScript") then { + call compile preprocessFileLineNumbers _slideOnLoadScript; + }; + + _slideControlID = getNumber (_x >> "controlID"); + _slideName = configName _x; + _slideTitle = getText (_x >> "title"); + _slideControl = _display displayCtrl _slideControlID; + if (_slideName isEqualTo ExileClientXM8CurrentSlide) then { + _titleControl = _display displayCtrl 4004; + _titleControl ctrlSetStructuredText (parseText (format ["%1", _slideTitle])); + _slideControl ctrlSetPosition [(0 * 0.05), (0 * 0.05)]; + _slideControl ctrlCommit 0; + _slideControl ctrlShow true; + _toSlideOpenFunction = missionNamespace getVariable [format ["ExileClient_gui_xm8_slide_%1_onOpen", _slideName], ""]; + if !(_toSlideOpenFunction isEqualTo "") then + { + call _toSlideOpenFunction; + }; + } else { + _slideControl ctrlShow false; + }; +} forEach (("true" configClasses (configFile >> "CfgXM8")) + ("true" configClasses (missionConfigFile >> "CfgXM8"))); +/* +Lets read missionConfigFile as well, as we may have custom slides added. +forEach ("true" configClasses (configFile >> "CfgXM8")); //Original line +*/ +ExileXM8ThreadHandle = [10, ExileClient_gui_xm8_thread_update, [], true] call ExileClient_system_thread_addtask; +call ExileClient_gui_xm8_thread_update; diff --git a/mpmissions/Exile.Altis/XM8_apps/scripts/ExileClient_gui_xm8_slide.sqf b/mpmissions/Exile.Altis/XM8_apps/scripts/ExileClient_gui_xm8_slide.sqf new file mode 100644 index 0000000..a61765f --- /dev/null +++ b/mpmissions/Exile.Altis/XM8_apps/scripts/ExileClient_gui_xm8_slide.sqf @@ -0,0 +1,87 @@ +/** + * ExileClient_gui_xm8_slide + * + * Exile Mod + * www.exilemod.com + * © 2015 Exile Mod Team + * + * This work is licensed under the Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International License. + * To view a copy of this license, visit http://creativecommons.org/licenses/by-nc-nd/4.0/. + */ + +// XM8 apps Imporeved by vitaly'mind'chizhikov +// Based on idea XM8 apps by Shix. see http://www.exilemod.com/topic/9040-xm8-apps/?page=1 +// Original function from Exile 0.9.6 + +private["_try","_toSlideName","_direction","_display","_toSlideControlID","_toSlideControl","_toSlideTitle","_titleControl","_toSlideOpenFunction","_fromSlideControlID","_fromSlideControl","_fromSlideCloseFunction"]; +disableSerialization; +_toSlideName = _this select 0; +_direction = _this select 1; +_display = displayNull; +if !(ExileClientXM8CurrentSlide isEqualTo _toSlideName) then +{ + _display = uiNameSpace getVariable ["RscExileXM8", displayNull]; + _toSlideControlID = getNumber (configFile >> "CfgXM8" >> _toSlideName >> "controlID"); + + //Lets try read MissionConfig, maybe we have custom slide + _try = (missionConfigFile >> "CfgXM8" >> _toSlideName >> "controlID") call BIS_fnc_getCfgData; + if (!isNil "_try") then {_toSlideControlID = _try}; + + _toSlideControl = _display displayCtrl _toSlideControlID; + _toSlideTitle = getText (configFile >> "CfgXM8" >> _toSlideName >> "title"); + + //Lets try read MissionConfig, maybe we have custom slide + _try = (missionConfigFile >> "CfgXM8" >> _toSlideName >> "title") call BIS_fnc_getCfgData; + if (!isNil "_try") then {_toSlideTitle = _try}; + + _titleControl = _display displayCtrl 4004; + _titleControl ctrlSetStructuredText (parseText (format ["%1", _toSlideTitle])); + _toSlideOpenFunction = missionNamespace getVariable [format ["ExileClient_gui_xm8_slide_%1_onOpen", _toSlideName], ""]; + if !(_toSlideOpenFunction isEqualTo "") then + { + call _toSlideOpenFunction; + }; + _fromSlideControlID = getNumber (configFile >> "CfgXM8" >> ExileClientXM8CurrentSlide >> "controlID"); + + //Lets try read MissionConfig, maybe we have custom slide + _try = (missionConfigFile >> "CfgXM8" >> ExileClientXM8CurrentSlide >> "controlID") call BIS_fnc_getCfgData; + if (!isNil "_try") then {_fromSlideControlID = _try}; + + _fromSlideControl = _display displayCtrl _fromSlideControlID; + _fromSlideCloseFunction = missionNamespace getVariable [format ["ExileClient_gui_xm8_slide_%1_onClose", ExileClientXM8CurrentSlide], ""]; + if !(_fromSlideCloseFunction isEqualTo "") then + { + call _fromSlideCloseFunction; + }; + if (_direction isEqualTo 0) then + { + _toSlideControl ctrlSetPosition [(19 * 0.05), (0 * 0.05)]; + _toSlideControl ctrlShow true; + _toSlideControl ctrlCommit 0; + _toSlideControl ctrlSetPosition [(0 * 0.05), (0 * 0.05)]; + _toSlideControl ctrlCommit 0.25; + _fromSlideControl ctrlSetPosition [(-19 * 0.05), (0 * 0.05)]; + _fromSlideControl ctrlCommit 0.25; + } + else + { + _toSlideControl ctrlSetPosition [(-19 * 0.05), (0 * 0.05)]; + _toSlideControl ctrlShow true; + _toSlideControl ctrlCommit 0; + _toSlideControl ctrlSetPosition [(0 * 0.05), (0 * 0.05)]; + _toSlideControl ctrlCommit 0.25; + _fromSlideControl ctrlSetPosition [(19 * 0.05), (0 * 0.05)]; + _fromSlideControl ctrlCommit 0.25; + }; + ExileClientXM8CurrentSlide = _toSlideName; +}; + +//Lets hide old territory button, as we already made new one early on in ExileClient_gui_xm8_show. +//Why we make new? Because if button is re-possition it will render picture (textureNoShortcut) incorrectly. +private ["_sliders","_appSlide","_oldTerritoryBut"]; +_sliders = _display displayCtrl 4007; +_appSlide = _sliders controlsGroupCtrl 4040; +_oldTerritoryBut = _appSlide controlsGroupCtrl 1113; +_oldTerritoryBut ctrlShow false; +_oldTerritoryBut ctrlSetFade 0; +_oldTerritoryBut ctrlCommit 0; \ No newline at end of file diff --git a/mpmissions/Exile.Altis/XM8_apps/scripts/ExileClient_gui_xm8_slide_apps_onOpen.sqf b/mpmissions/Exile.Altis/XM8_apps/scripts/ExileClient_gui_xm8_slide_apps_onOpen.sqf new file mode 100644 index 0000000..545b4e5 --- /dev/null +++ b/mpmissions/Exile.Altis/XM8_apps/scripts/ExileClient_gui_xm8_slide_apps_onOpen.sqf @@ -0,0 +1,47 @@ +/** + * ExileClient_gui_xm8_slide_apps_onOpen + * + * Exile Mod + * www.exilemod.com + * © 2015 Exile Mod Team + * + * This work is licensed under the Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International License. + * To view a copy of this license, visit http://creativecommons.org/licenses/by-nc-nd/4.0/. + */ + +// XM8 apps Imporeved by vitaly'mind'chizhikov +// Based on idea XM8 apps by Shix. see http://www.exilemod.com/topic/9040-xm8-apps/?page=1 +// Original function from Exile 0.9.6 + +private["_display","_health","_popTabsValue","_popTabs","_respectValue","_respect"]; +disableSerialization; +_display = uiNameSpace getVariable ["RscExileXM8", displayNull]; +_health = _display displayCtrl 4057; +_health ctrlSetStructuredText parseText (format ["


%1%2
HEALTH
", round ((1 - damage player) * 100), "%"]); +_popTabsValue = ExileClientPlayerMoney; +if (_popTabsValue > 999) then +{ + _popTabsValue = format ["%1k", floor (_popTabsValue / 1000)]; +}; +_popTabs = _display displayCtrl 4058; +_popTabs ctrlSetTooltip format["%1", ExileClientPlayerMoney]; +_popTabs ctrlSetStructuredText parseText (format ["


%1
POP TABS
", _popTabsValue]); +_respectValue = ExileClientPlayerScore; +if (_respectValue > 999) then +{ + _respectValue = format ["%1k", floor (_respectValue / 1000)]; +}; +_respect = _display displayCtrl 4059; +_respect ctrlSetTooltip format["%1", ExileClientPlayerScore]; +_respect ctrlSetStructuredText parseText (format ["


%1
RESPECT
", _respectValue]); + +//Lets hide old territory button, as we already made new one early on in ExileClient_gui_xm8_show. +//Why we make new? Because if button is re-possition it will render picture (textureNoShortcut) incorrectly. +private ["_sliders","_appSlide","_oldTerritoryBut"]; +_sliders = _display displayCtrl 4007; +_appSlide = _sliders controlsGroupCtrl 4040; +_oldTerritoryBut = _appSlide controlsGroupCtrl 1113; +_oldTerritoryBut ctrlShow false; +_oldTerritoryBut ctrlSetFade 0; +_oldTerritoryBut ctrlCommit 0; + diff --git a/mpmissions/Exile.Altis/XM8_apps/scripts/XM8_apps_init.sqf b/mpmissions/Exile.Altis/XM8_apps/scripts/XM8_apps_init.sqf new file mode 100644 index 0000000..e89183a --- /dev/null +++ b/mpmissions/Exile.Altis/XM8_apps/scripts/XM8_apps_init.sqf @@ -0,0 +1,28 @@ +/* + Improved XM8 apps by vitaly'mind'chizhikov + Original idea by Shix. +*/ + +params ["_pathToFolder"]; + +//Setting path to app +XM8_apps_folderPath = _pathToFolder; + +//Apply config +call compile preprocessFileLineNumbers format ["%1XM8_apps\XM8_apps_config.sqf",_pathToFolder]; + +//Run init scripts for those apps that made for Improved XM8 apps (not legacy apps) +for "_i" from 1 to 15 do { + private ["_pos", "_data"]; + if (!isNil (format ["XM8_apps_app%1", _i])) then { + _data = call compile format ["XM8_apps_app%1", _i]; + if (_data select 3) then { + _arr = (_data select 4) splitString "\"; + _arr resize ((count _arr) - 2); + ((_arr joinString "\") + "\") call compile preprocessFileLineNumbers (_data select 4); + } else { + + }; + }; +}; + diff --git a/mpmissions/Exile.Altis/config.cpp b/mpmissions/Exile.Altis/config.cpp new file mode 100644 index 0000000..9329a50 --- /dev/null +++ b/mpmissions/Exile.Altis/config.cpp @@ -0,0 +1,22 @@ +class CfgExileCustomCode +{ + ExileServer_system_territory_database_load = "ExAdClient\VirtualGarage\CustomCode\ExileServer_system_territory_database_load.sqf"; +}; + +class CfgInteractionMenus +{ + class Flag + { + targetType = 2; + target = "Exile_Construction_Flag_Static"; + class Actions + { + class VG : ExileAbstractAction + { + title = "Virtual Garage"; + condition = "(([_object, getPlayerUID player] call ExileClient_util_territory_getAccessLevel) select 0) >= ExAd_VG_ACCESS_LEVEL"; + action = "call XM8_VG_checkNearByFlags"; + }; + }; + }; +}; \ No newline at end of file diff --git a/mpmissions/Exile.Altis/stringtable.xml b/mpmissions/Exile.Altis/stringtable.xml index e863de8..2c6ab37 100644 --- a/mpmissions/Exile.Altis/stringtable.xml +++ b/mpmissions/Exile.Altis/stringtable.xml @@ -18,4 +18,11 @@ + + + + You garage is full! + + +