Jump to content

Leaderboard


Popular Content

Showing content with the highest reputation since 07/22/2019 in all areas

  1. 2 points
    I've been working on a Metro-style design/overhaul for Altis Life's Y Menu. This video shows off the color customization available to players. Please remember this is a work in progress, so nothing is final (this is a bare-bones version). If you have any suggestions as to what would be good to put on the phone, feel free to let me know! Comp 1.mp4
  2. 2 points
    The best anti-hack is Spyglass + tight BE filters + Active staff + daily log checks. If you are using Infistar it is likely you disabled some of Spyglass's checks. The truth of it is there will always be that % of people who can get past your anti-hack but that's why you teach your staff how to handle those situations and why either you or your team check all of your logs daily. If you don't want to read 1000+ lines of logs I recommend writing a script that will scan your logs for key words (such as high deposit/withdraw amounts) and output those into a separate file for you to read only the important stuff.
  3. 2 points
    Check your masterHandler.hpp Change these two to 1 to allow cops & civs to revive - revive_civ - revive_cops code from actionKeyHandler //Check if it's a dead body. if (_curObject isKindOf "CAManBase" && {!alive _curObject}) exitWith { //Hotfix code by ins0 if ((playerSide isEqualTo west && {(LIFE_SETTINGS(getNumber,"revive_cops") isEqualTo 1)}) || {(playerSide isEqualTo civilian && {(LIFE_SETTINGS(getNumber,"revive_civ") isEqualTo 1)})} || {(playerSide isEqualTo east && {(LIFE_SETTINGS(getNumber,"revive_east") isEqualTo 1)})} || {playerSide isEqualTo independent}) then { if (life_inv_defibrillator > 0) then { [_curObject] call life_fnc_revivePlayer; }; }; };
  4. 2 points
    Wow, it really takes you a while to get home.
  5. 1 point
    Authers: Kureo & Zalac Edited by: FadedHazard Difficulty: Easy Version: Working on 5.0 (Not tested on 4.4) How to Instal the new Player_HUD: Step 1: Download the new Player_Hud Download here Step 2: Go to core/functions and drag and drop (fn_hudUpdate.sqf) and (fn_hudSetup.sqf) into the folder: Step 3: Go to dialog folder and drag and drop new_HUD.hpp into folder: Step 4: Go into description.ext and put under Class RscTitles, this: change hud_stats.hpp Step 5: Go into dialog folder, open MasterHandler.hpp and add change hud_stats.hpp Step 6: Put the Icon into the Icon folder (drag and drop) Step 7: Go to init.sqf, under paste this under it
  6. 1 point
    Hey everyone, decided I'm going to start releasing assets I've made and or contributed to from Orion, here's the HUD: I won't go into too much detail on how to set it all up, just give the assets. Looks like this, + seatbelt icon in vehicle: hud_stats.hpp //--------------------------------- //By Repentz //--------------------------------- #define INFINITE 1e+1000 #define IDC_LIFE_BAR_FOOD 2200 #define IDC_LIFE_BAR_FOOD_RING 3200 #define IDC_LIFE_BAR_WATER 2201 #define IDC_LIFE_BAR_WATER_RING 3201 #define IDC_LIFE_BAR_HEALTH 2202 #define IDC_LIFE_BAR_HEALTH_RING 3202 //#define IDC_LIFE_BAR_POOP 4202 #define IDC_LIFE_BAR_Speaker 3007 #define IDC_LIFE_BAR_SeatBelt 4203 class playerHUD { idd = -1; duration = INFINITE; movingEnable = 0; fadein = 0; fadeout = 0; name = "playerHUD"; onLoad = "uiNamespace setVariable ['playerHUD',_this select 0]"; objects[] = {}; controls[] = { LIFE_BAR_FOOD_RING, LIFE_BAR_WATER_RING, LIFE_BAR_HEALTH_RING, LIFE_BAR_Speaker, LIFE_BAR_SeatBelt }; class LIFE_BAR_SeatBelt: Life_RscPicture { idc = IDC_LIFE_BAR_SeatBelt; text = ""; x = 0.952292 * safezoneW + safezoneX; y = 0.574333 * safezoneH + safezoneY; w = 0.0331042 * safezoneW; h = 0.0589743 * safezoneH; }; class LIFE_BAR_Speaker: Life_RscPicture { idc = IDC_LIFE_BAR_Speaker; text = ""; x = 0.952292 * safezoneW + safezoneX; y = 0.640333 * safezoneH + safezoneY; w = 0.0331042 * safezoneW; h = 0.0589743 * safezoneH; }; class LIFE_BAR_HEALTH_RING: Life_RscPicture { idc = IDC_LIFE_BAR_HEALTH_RING; text = ""; x = 0.952292 * safezoneW + safezoneX; y = 0.706333 * safezoneH + safezoneY; w = 0.0331042 * safezoneW; h = 0.0589743 * safezoneH; }; class LIFE_BAR_FOOD_RING: Life_RscPicture { idc = IDC_LIFE_BAR_FOOD_RING; text = ""; x = 0.952292 * safezoneW + safezoneX; y = 0.772333 * safezoneH + safezoneY; w = 0.0331042 * safezoneW; h = 0.0589743 * safezoneH; }; class LIFE_BAR_WATER_RING: Life_RscPicture { idc = IDC_LIFE_BAR_WATER_RING; text = ""; x = 0.952292 * safezoneW + safezoneX; y = 0.838333 * safezoneH + safezoneY; w = 0.0331042 * safezoneW; h = 0.0589743 * safezoneH; }; }; HudUpdate: #include "..\..\script_macros.hpp" //--------------------------------- //By Repentz //--------------------------------- #define INFINITE 1e+1000 #define IDC_LIFE_BAR_FOOD 2200 #define IDC_LIFE_BAR_FOOD_RING 3200 #define IDC_LIFE_BAR_WATER 2201 #define IDC_LIFE_BAR_WATER_RING 3201 #define IDC_LIFE_BAR_HEALTH 2202 #define IDC_LIFE_BAR_HEALTH_RING 3202 #define IDC_LIFE_BAR_Speaker 3007 #define IDC_LIFE_BAR_SeatBelt 4203 disableSerialization; if(isNull LIFEdisplay) then {[] call life_fnc_hudSetup;}; //[LIFE_ID_PlayerTags,"onEachFrame"] call BIS_fnc_removeStackedEventHandler; LIFE_ID_PlayerTags = ["LIFE_PlayerTags","onEachFrame","life_fnc_playerTags"] call BIS_fnc_addStackedEventHandler; if(!isNil "life_seatbelt") then { if ( vehicle player != player ) then { if(life_seatbelt) then { LIFEctrl(IDC_LIFE_BAR_SeatBelt) ctrlSetText "VindicateAssets\images\textures\HUD\seatbeltOn.paa"; } else { LIFEctrl(IDC_LIFE_BAR_SeatBelt) ctrlSetText "VindicateAssets\images\textures\HUD\seatbeltOff.paa"; }; } else { LIFEctrl(IDC_LIFE_BAR_SeatBelt) ctrlSetText ""; }; }; if(!isNil "life_fadeSound") then { if(life_fadeSound) then { LIFEctrl(IDC_LIFE_BAR_Speaker) ctrlSetText "VindicateAssets\images\textures\HUD\earplugsY.paa"; } else { LIFEctrl(IDC_LIFE_BAR_Speaker) ctrlSetText "VindicateAssets\images\textures\HUD\earplugsN.paa"; }; }; if(!isNil "life_thirst") then { if (life_thirst <= 100) then { LIFEctrl(IDC_LIFE_BAR_WATER_RING) ctrlSetText "VindicateAssets\images\textures\HUD\water0.paa"; }; if (life_thirst <= 90) then { LIFEctrl(IDC_LIFE_BAR_WATER_RING) ctrlSetText "VindicateAssets\images\textures\HUD\water1.paa"; }; if (life_thirst <= 80) then { LIFEctrl(IDC_LIFE_BAR_WATER_RING) ctrlSetText "VindicateAssets\images\textures\HUD\water2.paa"; }; if (life_thirst <= 70) then { LIFEctrl(IDC_LIFE_BAR_WATER_RING) ctrlSetText "VindicateAssets\images\textures\HUD\water3.paa"; }; if (life_thirst <= 60) then { LIFEctrl(IDC_LIFE_BAR_WATER_RING) ctrlSetText "VindicateAssets\images\textures\HUD\water4.paa"; }; if (life_thirst <= 50) then { LIFEctrl(IDC_LIFE_BAR_WATER_RING) ctrlSetText "VindicateAssets\images\textures\HUD\water5.paa"; }; if (life_thirst <= 40) then { LIFEctrl(IDC_LIFE_BAR_WATER_RING) ctrlSetText "VindicateAssets\images\textures\HUD\water6.paa"; }; if (life_thirst <= 30) then { LIFEctrl(IDC_LIFE_BAR_WATER_RING) ctrlSetText "VindicateAssets\images\textures\HUD\water7.paa"; }; if (life_thirst <= 20) then { LIFEctrl(IDC_LIFE_BAR_WATER_RING) ctrlSetText "VindicateAssets\images\textures\HUD\water8.paa"; }; if (life_thirst <= 10) then { LIFEctrl(IDC_LIFE_BAR_WATER_RING) ctrlSetText "VindicateAssets\images\textures\HUD\water9.paa"; }; if (life_thirst <= 0) then { LIFEctrl(IDC_LIFE_BAR_WATER_RING) ctrlSetText "VindicateAssets\images\textures\HUD\water10.paa"; }; }; if (damage player >= 0) then { LIFEctrl(IDC_LIFE_BAR_HEALTH_RING) ctrlSetText "VindicateAssets\images\textures\HUD\health0.paa"; }; if (damage player >= 0.01) then { LIFEctrl(IDC_LIFE_BAR_HEALTH_RING) ctrlSetText "VindicateAssets\images\textures\HUD\health1.paa"; }; if (damage player >= 0.02) then { LIFEctrl(IDC_LIFE_BAR_HEALTH_RING) ctrlSetText "VindicateAssets\images\textures\HUD\health2.paa"; }; if (damage player >= 0.03) then { LIFEctrl(IDC_LIFE_BAR_HEALTH_RING) ctrlSetText "VindicateAssets\images\textures\HUD\health3.paa"; }; if (damage player >= 0.07) then { LIFEctrl(IDC_LIFE_BAR_HEALTH_RING) ctrlSetText "VindicateAssets\images\textures\HUD\health4.paa"; }; if (damage player >= 0.13) then { LIFEctrl(IDC_LIFE_BAR_HEALTH_RING) ctrlSetText "VindicateAssets\images\textures\HUD\health5.paa"; }; if (damage player >= 0.2) then { LIFEctrl(IDC_LIFE_BAR_HEALTH_RING) ctrlSetText "VindicateAssets\images\textures\HUD\health6.paa"; }; if (damage player >= 0.3) then { LIFEctrl(IDC_LIFE_BAR_HEALTH_RING) ctrlSetText "VindicateAssets\images\textures\HUD\health7.paa"; }; if (damage player >= 0.4) then { LIFEctrl(IDC_LIFE_BAR_HEALTH_RING) ctrlSetText "VindicateAssets\images\textures\HUD\health8.paa"; }; if (damage player >= 0.7) then { LIFEctrl(IDC_LIFE_BAR_HEALTH_RING) ctrlSetText "VindicateAssets\images\textures\HUD\health9.paa"; }; if (damage player >= 1) then { LIFEctrl(IDC_LIFE_BAR_HEALTH_RING) ctrlSetText "VindicateAssets\images\textures\HUD\health10.paa"; }; if(!isNil "life_hunger") then { if (life_hunger <= 100) then { LIFEctrl(IDC_LIFE_BAR_FOOD_RING) ctrlSetText "VindicateAssets\images\textures\HUD\food0.paa"; }; if (life_hunger <= 90) then { LIFEctrl(IDC_LIFE_BAR_FOOD_RING) ctrlSetText "VindicateAssets\images\textures\HUD\food1.paa"; }; if (life_hunger <= 80) then { LIFEctrl(IDC_LIFE_BAR_FOOD_RING) ctrlSetText "VindicateAssets\images\textures\HUD\food2.paa"; }; if (life_hunger <= 70) then { LIFEctrl(IDC_LIFE_BAR_FOOD_RING) ctrlSetText "VindicateAssets\images\textures\HUD\food3.paa"; }; if (life_hunger <= 60) then { LIFEctrl(IDC_LIFE_BAR_FOOD_RING) ctrlSetText "VindicateAssets\images\textures\HUD\food4.paa"; }; if (life_hunger <= 50) then { LIFEctrl(IDC_LIFE_BAR_FOOD_RING) ctrlSetText "VindicateAssets\images\textures\HUD\food5.paa"; }; if (life_hunger <= 40) then { LIFEctrl(IDC_LIFE_BAR_FOOD_RING) ctrlSetText "VindicateAssets\images\textures\HUD\food6.paa"; }; if (life_hunger <= 30) then { LIFEctrl(IDC_LIFE_BAR_FOOD_RING) ctrlSetText "VindicateAssets\images\textures\HUD\food7.paa"; }; if (life_hunger <= 20) then { LIFEctrl(IDC_LIFE_BAR_FOOD_RING) ctrlSetText "VindicateAssets\images\textures\HUD\food8.paa"; }; if (life_hunger <= 10) then { LIFEctrl(IDC_LIFE_BAR_FOOD_RING) ctrlSetText "VindicateAssets\images\textures\HUD\food9.paa"; }; if (life_hunger <= 0) then { LIFEctrl(IDC_LIFE_BAR_FOOD_RING) ctrlSetText "VindicateAssets\images\textures\HUD\food1.paa"; }; }; hudSetup: #include "..\..\script_macros.hpp" disableSerialization; 2 cutRsc ["playerHUD","PLAIN"]; [] call life_fnc_hudUpdate; [] spawn { private["_dam"]; while {true} do { _dam = damage player; waitUntil {(damage player) != _dam}; [] call life_fnc_hudUpdate; }; }; setupActions for all life_actions pushBack (player addAction["<t color = '#009900'>Put on Seatbelt</t>",life_fnc_seatbelt,"",6,false,false,"",' !life_seatbelt && vehicle player != player ']); life_actions pushBack (player addAction["<t color = '#ff3300'>Remove Seatbelt</t>",life_fnc_seatbelt,"",6,false,false,"",' life_seatbelt && vehicle player != player ']); Assets included named HUD.rar HUD.rar
  7. 1 point
    Hello Guys, today Im going to show you the new Spawnscreen I made (exclusive only for ALRPG). As usal, you can use this script, but your are not allowed to post this Tutorial in any other Forum. Create a new file in the dialog folder called spawnSelection.hpp class life_spawn_selection { idd = 38500; name = "life_spawn_selection"; movingenable = 0; enablesimulation = 1; class controlsBackground { class BGha : Life_RscPicture { idc = 38531; colorbackground[] = {1,1,1,0}; text = "textures\spawnscreen.paa"; x = 0 * safezoneW + safezoneX; y = 0 * safezoneH + safezoneY; w = 1 * safezoneW; h = 1 * safezoneH; }; class MapView : Life_RscMapControl { idc = 38502; colorbackground[] = {1,1,1,0}; x = 0.622916666666667 * safezoneW + safezoneX; y = 0.113077679449361 * safezoneH + safezoneY; w = 0.192708333333333 * safezoneW; h = 0.438544739429695 * safezoneH; maxsatellitealpha = 0.75; alphafadestartscale = 1.15; alphafadeendscale = 1.29; coloroutside[] = {0,1,1,1}; colorsea[] = {0.392156862745098,0.584313725490196,0.929411764705882,1}; }; }; class controls { class SpawnPointList : Life_RscListNBox { idc = 38510; text = ""; sizeex = 0.041; coloumns[] = {0,0,0.9}; drawsidearrows = 0; idcleft = -1; idcright = -1; rowheight = 0.050; x = 0.477083333333333 * safezoneW + safezoneX; y = 0.114060963618486 * safezoneH + safezoneY; w = 0.145833333333333 * safezoneW; h = 0.363815142576205 * safezoneH; onlbselchanged = "_this call life_fnc_spawnPointSelected;"; }; class spawnButton : Life_RscButtonMenu { type = 1; style = "0x02"; colorbackground[] = {1,1,1,0}; text = "Neues Leben"; onbuttonclick = "[] call life_fnc_spawnConfirm"; x = 0.477083333333333 * safezoneW + safezoneX; y = 0.47984267453294 * safezoneH + safezoneY; w = 0.145833333333333 * safezoneW; h = 0.0707964601769911 * safezoneH; colorbackgroundactive[] = {1,1,1,0}; colorbackgrounddisabled[] = {0.95,0.95,0.95,0}; offsetx = 0.003; offsety = 0.003; offsetpressedx = 0.002; offsetpressedy = 0.002; colorshadow[] = {1,1,1,0}; colorborder[] = {0,0,0,0}; bordersize = 0.008; idc = 1000; colorbackgroundfocused[] = {1,1,1,0}; colorbackground2[] = {1,1,1,0}; color[] = {1,1,1,0}; colorfocused[] = {1,1,1,0}; color2[] = {1,1,1,0}; colortext[] = {1,1,1,0}; }; }; }; Now you just need to add the .paa to your textures folder. Thats all. Pic of the whole stuff: spawnscreen.paa
  8. 1 point
    It’s just where he’s placed his textures folder/HUD folder so Just replace that line with where your hud folder is located. unzip the HUD file and place the HUD folder in your textures file in your root (don’t extract them into here just place the unzipped folder with all the icons in) So if your HUD folder is located in your textures folder in your servers root then just remove the first parts to make it look like this : “textures\HUD” this is is how the code should look, provided it’s located there
  9. 1 point
  10. 1 point
    You have many hidden characters in the file. You can run it through my tool: http://arma.imthatguyhere.com/bom/ Instructions: If that doesn't resolve it, SQFBin the file and link it here so we can take a look.
  11. 1 point
    Pastebin all the files you edited
  12. 1 point
    ¿puede proporcionar más información sobre su servidor para que otros sepan qué lo distingue?
  13. 1 point
    [INBETA MODPACK] Hey i am a ArmA3 Scripter and Designer that do Textures and Fun scripts and working frameworks for mostly arma 3 RP Servers and love doing it so i have startet a texture modpack Project that i will be constantly updating hope you are gonna use it there is gonna be uniforms/vest for Police/Military/EMS/NATO/REBEL/CIVILIANS/FIREDEPARTMENT And much more you can req uniforms or vest and we will make it for you guys hope youre gonna like it when its FULLY Done Modpack: https://steamcommunity.com/sharedfiles/filedetails/?id=1666200478 Note: Please do critic the design for our improvement and remember its beta right now so there will not be alot of Textures in there yet!
  14. 1 point
  15. 1 point
    Alright, I've seen posts like this from you and I have said before, look through the files and try to understand the code and figure out how you can use it in your own code. Keep practising and learn how to do the things you want. To start you off look at fn_safeInventory.sqf and all the other safe related scripts found in mission file >> dialog >> functions. Regards, Wallace
  16. 1 point
    Very cool, looks like it's coming along nicely.
  17. 1 point
    Wir, das ZuchtBude.de Team, suchen Spieler welche gerne Altis Life auf einem Qualitativ Hochwertigem Server Spielen möchten mit gutem RP Wir bieten diverse Farming Routen (Standard Routen und neue Routen) Ein einzigartiges Webinterface für User, zur Verwaltung diverser Dinge, sowie : Shopsystem für Fahrzeuge (Fahrzeug Rabatt) und Basen (Basen kommen bald) Polizei und Medic Berichte Fahndungsliste mit Variablem Kopfgeld (Einstellbar von Polizei) Überblick über deine Garage Überblick über deine Gang Möglichkeit eine Gang auf öffentlich zu stellen so dass man joinen kann Spielzeit Level System (Man wird fürs spielen belohnt) Von den Skripten her, gibts eine Menge an Skripten um das RP Erlebnis zu steigern : Personalausweis Objekte Platzieren für Medics und Cops zum rp gebrauch usw... Wir sind ebenfalls auf der Suche nach Polizisten (Nach möglichkeit mit Polizei Erfahrung) Zu finden sind wir unter ts : ts.zuchtbude.de Webseite : www.zuchtbude.de Arma Server : vserver1.zuchtbude.de Port 2302 Bei fragen, könnt ihr uns auf unserem TS besuchen oder eine email an [email protected] senden Wir freuen uns über jedes Fünkchen Interesse was wir in euch entfachen können MFG~ Das Zuchtbude.de Team
  18. 1 point
    Works like a charm on 5.0 ❤️ thanks
  19. 1 point
    DynamicWeatherEffects Version 1.01 Description: Script that generates dynamic (random) weather. Works in single player, multiplayer (hosted and dedicated), and is JIP compatible. Instructions: 1. Go to init.sqf in the directory of your misson folder and place "[] execVM "scripts\DynWeather.sqf";" below similar code. 2. Copy the code below and create a new file called "DynWeather.sqf" and place that in a folder called scripts of your mission folder directory, if you don't have a folder called scripts then create one. Arguments: * [_initialFog]: Optional. Fog when mission starts. Must be between 0 and 1 where 0 = no fog, 1 = maximum fog. -1 = random fog. * [_initialOvercast]: Optional. Overcast when mission starts. Must be between 0 and 1 where 0 = no overcast, 1 = maximum overcast. -1 = random overcast. * [_initialRain]: Optional. Rain when mission starts. Must be between 0 and 1 where 0 = no rain, 1 = maximum rain. -1 = random rain. (Overcast must be greater than or equal to 0.75). * [_initialWind]: Optional. Wind when mission starts. Must be an array of form [x, z], where x is one wind strength vector and z is the other. x and z must be greater than or equal to 0. [-1, -1] = random wind. * [_debug]: Optional. true if debug text is to be shown, otherwise false. private ["_initialFog", "_initialOvercast", "_initialRain", "_initialWind", "_debug"]; private ["_minWeatherChangeTimeMin", "_maxWeatherChangeTimeMin", "_minTimeBetweenWeatherChangesMin", "_maxTimeBetweenWeatherChangesMin", "_rainIntervalRainProbability", "_windChangeProbability"]; private ["_minimumFog", "_maximumFog", "_minimumOvercast", "_maximumOvercast", "_minimumRain", "_maximumRain", "_minimumWind", "_maximumWind", "_minRainIntervalTimeMin", "_maxRainIntervalTimeMin", "_forceRainToStopAfterOneRainInterval", "_maxWind"]; if (isNil "_this") then { _this = []; }; if (count _this > 0) then { _initialFog = _this select 0; } else { _initialFog = -1; }; if (count _this > 1) then { _initialOvercast = _this select 1; } else { _initialOvercast = -1; }; if (count _this > 2) then { _initialRain = _this select 2; } else { _initialRain = -1; }; if (count _this > 3) then { _initialWind = _this select 3; } else { _initialWind = [-1, -1]; }; if (count _this > 4) then { _debug = _this select 4; } else { _debug = false; }; /////////////////////////////////////////////////////////////////////////////////////////////////////////////// // The following variables can be changed to tweak weather behaviour // Minimum time in minutes for the weather (fog and overcast) to change. Must be greater than or equal to 1 and less than or equal to // _maxWeatherChangeTimeMin. When weather changes, it is fog OR overcast that changes, not both at the same time. (Suggested value: 10). _minWeatherChangeTimeMin = 10; // Maximum time in minutes for the weather (fog and overcast) to change. Must be greater than or equal to _minWeatherChangeTimeMin. // (Suggested value: 20). _maxWeatherChangeTimeMin = 20; // Minimum time in minutes that weather (fog and overcast) stays constant between weather changes. Must be less than or equal to 0 and // greater than or equal to _minWeatherChangeTimeMin. (Suggested value: 5). _minTimeBetweenWeatherChangesMin = 5; // Maximum time in minutes that weather (fog and overcast) stays unchanged between weather changes. Must be greater than or equal to // _minWeatherChangeTimeMin. (Suggested value: 10). _maxTimeBetweenWeatherChangesMin = 10; // Fog intensity never falls below this value. Must be between 0 and 1 and less than or equal to _maximumFog // (0 = no fog, 1 = pea soup). (Suggested value: 0). _minimumFog = 0; // Fog intensity never exceeds this value. Must be between 0 and 1 and greater than or equal to _minimumFog // (0 = no fog, 1 = pea soup). (Suggested value: 0.8). _maximumFog = 0.2; // Overcast intensity never falls below this value. Must be between 0 and 1 and less than or equal to _maximumOvercast // (0 = no overcast, 1 = maximum overcast). (Suggested value: 0). _minimumOvercast = 0; // Overcast intensity never exceeds this value. Must be between 0 and 1 and greater than or equal to _minimumOvercast // (0 = no overcast, 1 = maximum overcast). (Suggested value: 1). _maximumOvercast = 0.8; // When raining, rain intensity never falls below this value. Must be between 0 and 1 and less than or equal to _maximumRain // (0 = no rain, 1 = maximum rain intensity). (Suggested value: 0); _minimumRain = 0; // When raining, rain intensity never exceeds this value. Must be between 0 and 1 and greater than or equal to _minimumRain // (0 = no rain, 1 = maximum rain intensity). (Suggested value: 0.8); _maximumRain = 0.5; // Wind vector strength never falls below this value. Must be greater or equal to 0 and less than or equal to _maximumWind. // (Suggested value: 0); _minimumWind = 0; // Wind vector strength never exceeds this value. Must be greater or equal to 0 and greater than or equal to _minimumWind. // (Suggested value: 8). _maximumWind = 8; // Probability in percent for wind to change when weather changes. If set to 0 then wind will never change. If set to 100 then rain will // change every time the weather (fog or overcast) start to change. (Suggested value: 25); _windChangeProbability = 25; // A "rain interval" is defined as "a time interval during which it may rain in any intensity (or it may not rain at all)". When overcast // goes above 0.75, a chain of rain intervals (defined below) is started. It cycles on until overcast falls below 0.75. At overcast // below 0.75 rain intervals never execute (thus it cannot rain). // Probability in percent (0-100) for rain to start at every rain interval. Set this to 0 if you don't want rain at all. Set this to 100 // if you want it to rain constantly when overcast is greater than 0.75. In short: if you think that it generally rains to often then // lower this value and vice versa. (Suggested value: 50). _rainIntervalRainProbability = 50; // Minimum time in minutes for rain intervals. Must be greater or equal to 0 and less than or equal to _maxRainIntervalTimeMin. // (Suggested value: 0). _minRainIntervalTimeMin = 0; // Maximum time in minutes for rain intervals. Must be greater than or equal to _minRainIntervalTimeMin. (Suggested value: // (_maxWeatherChangeTimeMin + _maxTimeBetweenWeatherChangesMin) / 2). _maxRainIntervalTimeMin = (_maxWeatherChangeTimeMin + _maxTimeBetweenWeatherChangesMin) / 2; // If set to true, then the rain is forced to stop after one rain interval during which it has rained (use this for example if you only want // small occational cloudbursts ). If set to false, then the rain may stop, but it may also just change intensity for an // immedeate new rain interval. (Suggested value: false). _forceRainToStopAfterOneRainInterval = false; /////////////////////////////////////////////////////////////////////////////////////////////////////////////// // Don't touch anything beneath this line drn_DynamicWeather_DebugTextEventArgs = []; // Empty "drn_DynamicWeather_DebugTextEventArgs" addPublicVariableEventHandler { drn_DynamicWeather_DebugTextEventArgs call drn_fnc_DynamicWeather_ShowDebugTextLocal; }; /* * Summary: Shows debug text on local client. * Arguments: * _text: Debug text. */ drn_fnc_DynamicWeather_ShowDebugTextLocal = { private ["_minutes", "_seconds"]; if (!isNull player) then { player sideChat (_this select 0); }; _minutes = floor (time / 60); _seconds = floor (time - (_minutes * 60)); diag_log ((str _minutes + ":" + str _seconds) + " Debug: " + (_this select 0)); }; /* * Summary: Shows debug text on all clients. * Arguments: * _text: Debug text. */ drn_fnc_DynamicWeather_ShowDebugTextAllClients = { drn_DynamicWeather_DebugTextEventArgs = _this; publicVariable "drn_DynamicWeather_DebugTextEventArgs"; drn_DynamicWeather_DebugTextEventArgs call drn_fnc_DynamicWeather_ShowDebugTextLocal; }; if (_debug) then { ["Starting script WeatherEffects.sqf..."] call drn_fnc_DynamicWeather_ShowDebugTextLocal; }; drn_DynamicWeatherEventArgs = []; // [current overcast, current fog, current rain, current weather change ("OVERCAST", "FOG" or ""), target weather value, time until weather completion (in seconds), current wind x, current wind z] drn_AskServerDynamicWeatherEventArgs = []; // [] drn_fnc_DynamicWeather_SetWeatherLocal = { private ["_currentOvercast", "_currentFog", "_currentRain", "_currentWeatherChange", "_targetWeatherValue", "_timeUntilCompletion", "_currentWindX", "_currentWindZ"]; _currentOvercast = _this select 0; _currentFog = _this select 1; _currentRain = _this select 2; _currentWeatherChange = _this select 3; _targetWeatherValue = _this select 4; _timeUntilCompletion = _this select 5; _currentWindX = _this select 6; _currentWindZ = _this select 7; // Set current weather values 0 setOvercast _currentOvercast; 0 setFog _currentFog; drn_var_DynamicWeather_Rain = _currentRain; setWind [_currentWindX, _currentWindZ, true]; // Set forecast if (_currentWeatherChange == "OVERCAST") then { _timeUntilCompletion setOvercast _targetWeatherValue; }; if (_currentWeatherChange == "FOG") then { _timeUntilCompletion setFog _targetWeatherValue; }; }; if (!isServer) then { "drn_DynamicWeatherEventArgs" addPublicVariableEventHandler { drn_DynamicWeatherEventArgs call drn_fnc_DynamicWeather_SetWeatherLocal; }; waitUntil {!isNil "drn_var_DynamicWeather_ServerInitialized"}; drn_AskServerDynamicWeatherEventArgs = [true]; publicVariable "drn_AskServerDynamicWeatherEventArgs"; }; if (isServer) then { drn_fnc_DynamicWeather_SetWeatherAllClients = { private ["_timeUntilCompletion", "_currentWeatherChange"]; _timeUntilCompletion = drn_DynamicWeather_WeatherChangeCompletedTime - drn_DynamicWeather_WeatherChangeStartedTime; if (_timeUntilCompletion > 0) then { _currentWeatherChange = drn_DynamicWeather_CurrentWeatherChange; } else { _currentWeatherChange = ""; }; drn_DynamicWeatherEventArgs = [overcast, fog, drn_var_DynamicWeather_Rain, _currentWeatherChange, drn_DynamicWeather_WeatherTargetValue, _timeUntilCompletion, drn_DynamicWeather_WindX, drn_DynamicWeather_WindZ]; publicVariable "drn_DynamicWeatherEventArgs"; drn_DynamicWeatherEventArgs call drn_fnc_DynamicWeather_SetWeatherLocal; }; "drn_AskServerDynamicWeatherEventArgs" addPublicVariableEventHandler { call drn_fnc_DynamicWeather_SetWeatherAllClients; }; drn_DynamicWeather_CurrentWeatherChange = ""; drn_DynamicWeather_WeatherTargetValue = 0; drn_DynamicWeather_WeatherChangeStartedTime = time; drn_DynamicWeather_WeatherChangeCompletedTime = time; drn_DynamicWeather_WindX = _initialWind select 0; drn_DynamicWeather_WindZ = _initialWind select 1; if (_initialFog == -1) then { _initialFog = (_minimumFog + random (_maximumFog - _minimumFog)); } else { if (_initialFog < _minimumFog) then { _initialFog = _minimumFog; }; if (_initialFog > _maximumFog) then { _initialFog = _maximumFog; }; }; 0 setFog _initialFog; if (_initialOvercast == -1) then { _initialOvercast = (_minimumOvercast + random (_maximumOvercast - _minimumOvercast)); } else { if (_initialOvercast < _minimumOvercast) then { _initialOvercast = _minimumOvercast; }; if (_initialOvercast > _maximumOvercast) then { _initialOvercast = _maximumOvercast; }; }; 0 setOvercast _initialOvercast; if (_initialOvercast >= 0.75) then { if (_initialRain == -1) then { _initialRain = (_minimumRain + random (_minimumRain - _minimumRain)); } else { if (_initialRain < _minimumRain) then { _initialRain = _minimumRain; }; if (_initialRain > _maximumRain) then { _initialRain = _maximumRain; }; }; } else { _initialRain = 0; }; drn_var_DynamicWeather_Rain = _initialRain; 0 setRain drn_var_DynamicWeather_Rain; _maxWind = _minimumWind + random (_maximumWind - _minimumWind); if (drn_DynamicWeather_WindX == -1) then { if (random 100 < 50) then { drn_DynamicWeather_WindX = -_minimumWind - random (_maxWind - _minimumWind); } else { drn_DynamicWeather_WindX = _minimumWind + random (_maxWind - _minimumWind); }; }; if (drn_DynamicWeather_WindZ == -1) then { if (random 100 < 50) then { drn_DynamicWeather_WindZ = -_minimumWind - random (_maxWind - _minimumWind); } else { drn_DynamicWeather_WindZ = _minimumWind + random (_maxWind - _minimumWind); }; }; setWind [drn_DynamicWeather_WindX, drn_DynamicWeather_WindZ, true]; sleep 0.05; publicVariable "drn_var_DynamicWeather_Rain"; drn_var_DynamicWeather_ServerInitialized = true; publicVariable "drn_var_DynamicWeather_ServerInitialized"; // Start weather thread [_minWeatherChangeTimeMin, _maxWeatherChangeTimeMin, _minTimeBetweenWeatherChangesMin, _maxTimeBetweenWeatherChangesMin, _minimumFog, _maximumFog, _minimumOvercast, _maximumOvercast, _minimumWind, _maximumWind, _windChangeProbability, _debug] spawn { private ["_minWeatherChangeTimeMin", "_maxWeatherChangeTimeMin", "_minTimeBetweenWeatherChangesMin", "_maxTimeBetweenWeatherChangesMin", "_minimumFog", "_maximumFog", "_minimumOvercast", "_maximumOvercast", "_minimumWind", "_maximumWind", "_windChangeProbability", "_debug"]; private ["_weatherType", "_fogLevel", "_overcastLevel", "_oldFogLevel", "_oldOvercastLevel", "_weatherChangeTimeSek"]; _minWeatherChangeTimeMin = _this select 0; _maxWeatherChangeTimeMin = _this select 1; _minTimeBetweenWeatherChangesMin = _this select 2; _maxTimeBetweenWeatherChangesMin = _this select 3; _minimumFog = _this select 4; _maximumFog = _this select 5; _minimumOvercast = _this select 6; _maximumOvercast = _this select 7; _minimumWind = _this select 8; _maximumWind = _this select 9; _windChangeProbability = _this select 10; _debug = _this select 11; // Set initial fog level _fogLevel = 2; _overcastLevel = 2; while {true} do { // Sleep a while until next weather change sleep floor (_minTimeBetweenWeatherChangesMin * 60 + random ((_maxTimeBetweenWeatherChangesMin - _minTimeBetweenWeatherChangesMin) * 60)); if (_minimumFog == _maximumFog && _minimumOvercast != _maximumOvercast) then { _weatherType = "OVERCAST"; }; if (_minimumFog != _maximumFog && _minimumOvercast == _maximumOvercast) then { _weatherType = "FOG"; }; if (_minimumFog != _maximumFog && _minimumOvercast != _maximumOvercast) then { // Select type of weather to change if ((random 100) < 50) then { _weatherType = "OVERCAST"; } else { _weatherType = "FOG"; }; }; // DEBUG //_weatherType = "OVERCAST"; if (_weatherType == "FOG") then { drn_DynamicWeather_CurrentWeatherChange = "FOG"; // Select a new fog level _oldFogLevel = _fogLevel; _fogLevel = floor ((random 100) / 25); while {_fogLevel == _oldFogLevel} do { _fogLevel = floor ((random 100) / 25); }; if (_fogLevel == 0) then { drn_DynamicWeather_WeatherTargetValue = _minimumFog + (_maximumFog - _minimumFog) * random 0.05; }; if (_fogLevel == 1) then { drn_DynamicWeather_WeatherTargetValue = _minimumFog + (_maximumFog - _minimumFog) * (0.05 + random 0.2); }; if (_fogLevel == 2) then { drn_DynamicWeather_WeatherTargetValue = _minimumFog + (_maximumFog - _minimumFog) * (0.25 + random 0.3); }; if (_fogLevel == 3) then { drn_DynamicWeather_WeatherTargetValue = _minimumFog + (_maximumFog - _minimumFog) * (0.55 + random 0.45); }; drn_DynamicWeather_WeatherChangeStartedTime = time; _weatherChangeTimeSek = _minWeatherChangeTimeMin * 60 + random ((_maxWeatherChangeTimeMin - _minWeatherChangeTimeMin) * 60); drn_DynamicWeather_WeatherChangeCompletedTime = time + _weatherChangeTimeSek; if (_debug) then { ["Weather forecast: Fog " + str drn_DynamicWeather_WeatherTargetValue + " in " + str round (_weatherChangeTimeSek / 60) + " minutes."] call drn_fnc_DynamicWeather_ShowDebugTextAllClients; }; }; if (_weatherType == "OVERCAST") then { drn_DynamicWeather_CurrentWeatherChange = "OVERCAST"; // Select a new overcast level _oldOvercastLevel = _overcastLevel; //_overcastLevel = floor ((random 100) / 25); _overcastLevel = 3; while {_overcastLevel == _oldOvercastLevel} do { _overcastLevel = floor ((random 100) / 25); }; if (_overcastLevel == 0) then { drn_DynamicWeather_WeatherTargetValue = _minimumOvercast + (_maximumOvercast - _minimumOvercast) * random 0.05; }; if (_overcastLevel == 1) then { drn_DynamicWeather_WeatherTargetValue = _minimumOvercast + (_maximumOvercast - _minimumOvercast) * (0.05 + random 0.3); }; if (_overcastLevel == 2) then { drn_DynamicWeather_WeatherTargetValue = _minimumOvercast + (_maximumOvercast - _minimumOvercast) * (0.35 + random 0.35); }; if (_overcastLevel == 3) then { drn_DynamicWeather_WeatherTargetValue = _minimumOvercast + (_maximumOvercast - _minimumOvercast) * (0.7 + random 0.3); }; // DEBUG /* if (overcast > 0.8) then { drn_DynamicWeather_WeatherTargetValue = 0.5; } else { drn_DynamicWeather_WeatherTargetValue = 0.85; }; */ drn_DynamicWeather_WeatherChangeStartedTime = time; _weatherChangeTimeSek = _minWeatherChangeTimeMin * 60 + random ((_maxWeatherChangeTimeMin - _minWeatherChangeTimeMin) * 60); drn_DynamicWeather_WeatherChangeCompletedTime = time + _weatherChangeTimeSek; if (_debug) then { ["Weather forecast: Overcast " + str drn_DynamicWeather_WeatherTargetValue + " in " + str round (_weatherChangeTimeSek / 60) + " minutes."] call drn_fnc_DynamicWeather_ShowDebugTextAllClients; }; }; // On average every one fourth of weather changes, change wind too if (random 100 < _windChangeProbability) then { private ["_maxWind"]; _maxWind = _minimumWind + random (_maximumWind - _minimumWind); if (random 100 < 50) then { drn_DynamicWeather_WindX = -_minimumWind - random (_maxWind - _minimumWind); } else { drn_DynamicWeather_WindX = _minimumWind + random (_maxWind - _minimumWind); }; if (random 100 < 50) then { drn_DynamicWeather_WindZ = -_minimumWind - random (_maxWind - _minimumWind); } else { drn_DynamicWeather_WindZ = _minimumWind + random (_maxWind - _minimumWind); }; if (_debug) then { ["Wind changes: [" + str drn_DynamicWeather_WindX + ", " + str drn_DynamicWeather_WindZ + "]."] call drn_fnc_DynamicWeather_ShowDebugTextAllClients; }; }; call drn_fnc_DynamicWeather_SetWeatherAllClients; sleep _weatherChangeTimeSek; }; }; // Start rain thread if (_rainIntervalRainProbability > 0) then { [_minimumRain, _maximumRain, _forceRainToStopAfterOneRainInterval, _minRainIntervalTimeMin, _maxRainIntervalTimeMin, _rainIntervalRainProbability, _debug] spawn { private ["_minimumRain", "_maximumRain", "_forceRainToStopAfterOneRainInterval", "_minRainIntervalTimeMin", "_maxRainIntervalTimeMin", "_rainIntervalRainProbability", "_debug"]; private ["_nextRainEventTime", "_forceStop"]; _minimumRain = _this select 0; _maximumRain = _this select 1; _forceRainToStopAfterOneRainInterval = _this select 2; _minRainIntervalTimeMin = _this select 3; _maxRainIntervalTimeMin = _this select 4; _rainIntervalRainProbability = _this select 5; _debug = _this select 6; if (rain > 0) then { drn_var_DynamicWeather_Rain = rain; publicVariable "drn_var_DynamicWeather_Rain"; }; _nextRainEventTime = time; _forceStop = false; while {true} do { if (overcast > 0.75) then { if (time >= _nextRainEventTime) then { private ["_rainTimeSec"]; // At every rain event time, start or stop rain with 50% probability if (random 100 < _rainIntervalRainProbability && !_forceStop) then { drn_var_DynamicWeather_rain = _minimumRain + random (_maximumRain - _minimumRain); publicVariable "drn_var_DynamicWeather_rain"; _forceStop = _forceRainToStopAfterOneRainInterval; } else { drn_var_DynamicWeather_rain = 0; publicVariable "drn_var_DynamicWeather_rain"; _forceStop = false; }; // Pick a time for next rain change _rainTimeSec = _minRainIntervalTimeMin * 60 + random ((_maxRainIntervalTimeMin - _minRainIntervalTimeMin) * 60); _nextRainEventTime = time + _rainTimeSec; if (_debug) then { ["Rain set to " + str drn_var_DynamicWeather_rain + " for " + str (_rainTimeSec / 60) + " minutes"] call drn_fnc_DynamicWeather_ShowDebugTextAllClients; }; }; } else { if (drn_var_DynamicWeather_rain != 0) then { drn_var_DynamicWeather_rain = 0; publicVariable "drn_var_DynamicWeather_rain"; if (_debug) then { ["Rain stops due to low overcast."] call drn_fnc_DynamicWeather_ShowDebugTextAllClients; }; }; _nextRainEventTime = time; _forceStop = false; }; if (_debug) then { sleep 1; } else { sleep 10; }; }; }; }; }; [_rainIntervalRainProbability, _debug] spawn { private ["_rainIntervalRainProbability", "_debug"]; private ["_rain", "_rainPerSecond"]; _rainIntervalRainProbability = _this select 0; _debug = _this select 1; if (_debug) then { _rainPerSecond = 0.2; } else { _rainPerSecond = 0.03; }; if (_rainIntervalRainProbability > 0) then { _rain = drn_var_DynamicWeather_Rain; } else { _rain = 0; }; 0 setRain _rain; sleep 0.1; while {true} do { if (_rainIntervalRainProbability > 0) then { if (_rain < drn_var_DynamicWeather_Rain) then { _rain = _rain + _rainPerSecond; if (_rain > 1) then { _rain = 1; }; }; if (_rain > drn_var_DynamicWeather_Rain) then { _rain = _rain - _rainPerSecond; if (_rain < 0) then { _rain = 0; }; }; } else { _rain = 0; }; 3 setRain _rain; sleep 3; }; };
  20. 1 point
    Small update - Been tinkering with a few things like working time display, a loading screen & an actual texture for the phone. Again, none of this is final. Comp_1_1.mp4
  21. 1 point
    If it works then it's clearly possible? You cheated and you were banned 😭
  22. 1 point
    thanks man, looks great in game. Well done on making this
  23. 1 point
    Warning Message: Script \life_server\init.sqf not found Your life_server is not found and its path isn't listed, have you pboed your @life_server>addons>life_sever folder?
  24. 1 point
    Can use this script as it seems to do the same as what your trying to accomplish; "If the player is attempting to buy something from a shop, and they have enough money on-hand, the shop will take their cash. If they don't have that money on their person, but they have it in their bank account, that money is taken instead and they will also be charged extra in Tax (if it is enabled on the server)."
  25. 1 point
    I can't think of anything related to Altis Life that would affect this. This script seems to be mission agnostic, it seems to be an exact rip from a DayZ mission from my memory (same variable names and the logic looks familiar).
  26. 1 point
    Original Post - N/A Original Author - Shakir Darwish Open your "dialog" folder and then open "impound.hpp" Add this to classSellCar: class InsureCar : life_RscButtonMenu { idc = 97480; text = "ensure" ; onButtonClick = "[] call life_fnc_insureCar;"; x = 0.43 + (6.25 / 40) + (1 / 250 / (safezoneW / safezoneH)); and = 0 . 9 - ( 1 / 25 ); w = (6.25 / 40); h = (1 / 25); }; Go to dialog>functions and add a new file named "fn_insureCar.sqf" Paste this in the new document: #include "..\..\script_macros.hpp" /* File: fn_insureCar.sqf Author: Guit0x "Lintox" Description: Insure a vehicle from the garage. */ private["_vehicle","_vehicleLife","_vid","_pid","_unit","_multiplier","_price","_purchasePrice","_insurancePrice"]; disableSerialization; if ((lbCurSel 2802) isEqualTo -1) exitWith {hint localize "STR_Global_NoSelection"}; _vehicle = lbData[2802,(lbCurSel 2802)]; _vehicle = (call compile format["%1",_vehicle]) select 0; _vehicleLife = _vehicle; _vid = lbValue [ 2802 , (lbCurSel 2802 )]; _pid = getPlayerUID player; _unit = player; if(isNil "_vehicle") exitWith {hint localize "STR_Garage_Selection_Error"}; if ((time - life_action_delay) < 1.5) exitWith {hint localize "STR_NOTF_ActionDelay";}; if (!isClass (missionConfigFile >> "LifeCfgVehicles" >> _vehicleLife)) then { _vehicleLife = "Default"; //Use Default class if it doesn't exist diag_log format["%1: LifeCfgVehicles class doesn't exist",_vehicle]; }; _price = M_CONFIG(getNumber,"LifeCfgVehicles",_vehicleLife,"price"); switch (playerSide) do { case civilian: { _multiplier = LIFE_SETTINGS(getNumber,"vehicle_insurance_multiplier_CIVILIAN"); _purchasePrice = _price * LIFE_SETTINGS(getNumber,"vehicle_purchase_multiplier_CIVILIAN"); }; case west: { _multiplier = LIFE_SETTINGS(getNumber,"vehicle_insurance_multiplier_COP"); _purchasePrice = _price * LIFE_SETTINGS(getNumber,"vehicle_purchase_multiplier_COP"); }; case independent: { _multiplier = LIFE_SETTINGS(getNumber,"vehicle_insurance_multiplier_MEDIC"); _purchasePrice = _price * LIFE_SETTINGS(getNumber,"vehicle_purchase_multiplier_MEDIC"); }; case east: { _multiplier = LIFE_SETTINGS(getNumber,"vehicle_insurance_multiplier_OPFOR"); _purchasePrice = _price * LIFE_SETTINGS(getNumber,"vehicle_purchase_multiplier_OPFOR"); }; }; _insurancePrice = _purchasePrice * _multiplier; if(!(_insurancePrice isEqualType 0) || _insurancePrice < 1) then {_insurancePrice = 500}; if(BANK < _insurancePrice) exitWith {hint format[(localize "STR_GNOTF_NotEnoughMoney"),[_insurancePrice] call life_fnc_numberText];}; if (life_HC_isActive) then { [_vid,_pid,_insurancePrice,player,life_garage_type] remoteExecCall ["HC_fnc_insureCar",HC_Life]; } else { [_vid,_pid,_insurancePrice,player,life_garage_type] remoteExecCall ["TON_fnc_insureCar",RSERV]; }; hint localize "STR_InsuranceApply"; BANK = BANK - _insurancePrice; life_action_delay = time; closeDialog 0; Open "function.hpp" in your "dialog" folder and add: class Dialog_Controls { file = "dialog\function"; [...] class insureCar {}; [...] }; Then open your "functions" folder in your "dialog" folder and open "fn_garageLBChange.sqf" Replace this: private["_control","_index","_className","_classNameLife","_dataArr","_vehicleColor","_vehicleInfo","_trunkSpace","_sellPrice","_retrievePrice","_sellMultiplier","_price","_storageFee","_purchasePrice"]; With this: private["_control","_index","_className","_classNameLife","_dataArr","_vehicleColor","_vehicleInfo","_trunkSpace","_sellPrice","_retrievePrice","_sellMultiplier","_insurance","_insuranceMultiplier","_price","_storageFee","_purchasePrice","_insurancePrice"]; After this: _classNameLife = _className; Add this: _insurance = (_dataArr select 2 ); Replace this: switch (playerSide) do { case civilian: { _purchasePrice = _price * LIFE_SETTINGS(getNumber,"vehicle_purchase_multiplier_CIVILIAN"); _sellMultiplier = LIFE_SETTINGS(getNumber,"vehicle_sell_multiplier_CIVILIAN"); }; case west: { _purchasePrice = _price * LIFE_SETTINGS(getNumber,"vehicle_purchase_multiplier_COP"); _sellMultiplier = LIFE_SETTINGS(getNumber,"vehicle_sell_multiplier_COP"); }; case independent: { _purchasePrice = _price * LIFE_SETTINGS(getNumber,"vehicle_purchase_multiplier_MEDIC"); _sellMultiplier = LIFE_SETTINGS(getNumber,"vehicle_sell_multiplier_MEDIC"); }; case east: { _purchasePrice = _price * LIFE_SETTINGS(getNumber,"vehicle_purchase_multiplier_OPFOR"); _sellMultiplier = LIFE_SETTINGS(getNumber,"vehicle_sell_multiplier_OPFOR"); }; }; With this: switch (playerSide) do { case civilian: { _purchasePrice = _price * LIFE_SETTINGS(getNumber,"vehicle_purchase_multiplier_CIVILIAN"); _sellMultiplier = LIFE_SETTINGS(getNumber,"vehicle_sell_multiplier_CIVILIAN"); _insuranceMultiplier = LIFE_SETTINGS(getNumber,"vehicle_insurance_multiplier_CIVILIAN"); }; case west: { _purchasePrice = _price * LIFE_SETTINGS(getNumber,"vehicle_purchase_multiplier_COP"); _sellMultiplier = LIFE_SETTINGS(getNumber,"vehicle_sell_multiplier_COP"); _insuranceMultiplier = LIFE_SETTINGS(getNumber,"vehicle_insurance_multiplier_COP"); }; case independent: { _purchasePrice = _price * LIFE_SETTINGS(getNumber,"vehicle_purchase_multiplier_MEDIC"); _sellMultiplier = LIFE_SETTINGS(getNumber,"vehicle_sell_multiplier_MEDIC"); _insuranceMultiplier = LIFE_SETTINGS(getNumber,"vehicle_insurance_multiplier_MEDIC"); }; case east: { _purchasePrice = _price * LIFE_SETTINGS(getNumber,"vehicle_purchase_multiplier_OPFOR"); _sellMultiplier = LIFE_SETTINGS(getNumber,"vehicle_sell_multiplier_OPFOR"); _insuranceMultiplier = LIFE_SETTINGS(getNumber,"vehicle_insurance_multiplier_OPFOR"); }; }; After this: _sellPrice = _purchasePrice * _sellMultiplier; Add this: _insurancePrice = _purchasePrice * _insuranceMultiplier; After this: if (!(_retrievePrice isEqualType 0) || _retrievePrice < 1) then {_retrievePrice = 500;}; Add this: if (!(_insurancePrice isEqualType 0) || _insurancePrice < 1) then {_insurancePrice = 500;}; Replace this: (CONTROL(2800,2803)) ctrlSetStructuredText parseText format[ (localize "STR_Shop_Veh_UI_RetrievalP")+ " <t color='#8cff9b'>$%1</t><br/> " +(localize "STR_Shop_Veh_UI_SellP")+ " <t color='#8cff9b'>$%2</t><br/> " +(localize "STR_Shop_Veh_UI_Color")+ " %8<br/> " +(localize "STR_Shop_Veh_UI_MaxSpeed")+ " %3 km/h<br/> " +(localize "STR_Shop_Veh_UI_HPower")+ " %4<br/> " +(localize "STR_Shop_Veh_UI_PSeats")+ " %5<br/> " +(localize "STR_Shop_Veh_UI_Trunk")+ " %6<br/> " +(localize "STR_Shop_Veh_UI_Fuel")+ " %7 ", With this: (CONTROL(2800,2803)) ctrlSetStructuredText parseText format[ (localize "STR_Shop_Veh_UI_RetrievalP")+ " <t color='#8cff9b'>$%1</t><br/> " +(localize "STR_Shop_Veh_UI_SellP")+ " <t color='#8cff9b'>$%2</t><br/> Prix de l'assurance: <t color='#8cff9b'>$%9</t><br/> State Insurance: %10 <br/> " +(localize "STR_Shop_Veh_UI_Color")+ " <t color='#8cff9b'>%8</t><br/> " +(localize "STR_Shop_Veh_UI_MaxSpeed")+ " <t color='#8cff9b'>%3 km/h</t><br/> " +(localize "STR_Shop_Veh_UI_HPower")+ " <t color='#8cff9b'>%4</t><br/> " +(localize "STR_Shop_Veh_UI_PSeats")+ " <t color='#8cff9b'>%5</t><br/> " +(localize "STR_Shop_Veh_UI_Trunk")+ " <t color='#8cff9b'>%6</t><br/> " +(localize "STR_Shop_Veh_UI_Fuel")+ " <t color='#8cff9b'>%7</t> ", Replace this: (_vehicleInfo select 12), _vehicleColor ]; With this: (_vehicleInfo select 12), _vehicleColor, [_insurancePrice] call life_fnc_numberText, if(_insurance == 1) then {"<t color='#8cff9b'>Assuré</t>"} else {"<t color='#FF0000'>Pas d'assurance</t>"}, (_vehicleInfo select 9) ]; if(_insurance == 1) then { ctrlShow [97480,False]; }else{ ctrlShow [97480,True]; }; Open dialog>function>fn_impoundMenu.sqf Replace this: _tmp = [(_x select 2),(_x select 8)]; With this: _tmp = [(_x select 2),(_x select 8),(_x select 9)]; Open CfgRemoteExec.hpp and add this in server only functions: F(TON_fnc_insureCar,SERVER) In Headless Client functions: F(HC_fnc_insureCar,HC) Open your stringtable.xml and add this: <Key ID="STR_InsuranceApply"> <Original>You just insure your vehicle you are now protected against explosions!</Original> < Czech > Now you insure your vehicle is now protected against explosions ! < / Czech > < Spanish > You just make sure your vehicle is now protected against explosions ! < / Spanish > < Italian > Just ensure your vehicle you are now protected against explosions ! < / Italian > < Polish > Just insure your vehicle you are now protected from explosion ! < / Polish > < Russian > You just insure your car, you are now protected against explosions ! < / Russian > < French > You just make your vehicle you are now protected against explosions ! < / French > < Portuguese > You just hold your vehicle you are now protected against explosions ! < / Portuguese > < German > They only insure your vehicle, you are now protected against explosions ! < / German > </Key> Under "<Key ID="STR_pInAct_SellGarage" Then open your Config_Master.hpp and add: /* Vehicle Insurance Prices */ vehicle_insurance_multiplier_CIVILIAN = .25; //Civilian Vehicle Insurance Price = Vehicle Buy Price * multiplier vehicle_insurance_multiplier_COP = .1; //Cop Vehicle Insurance Price = Vehicle Buy Price * multiplier vehicle_insurance_multiplier_MEDIC = .1; //Medic Vehicle Insurance Price = Vehicle Buy Price * multiplier vehicle_insurance_multiplier_OPFOR = -1; // -- NOT IN USE -- Simply left in for east support. In life_server: Open "config.cpp" and under class Ton_System (both life and hc) add: class insureCar {}; In functions>systems>fn_spawnVehicle.sqf: Replace this: _query = format["SELECT id, side, classname, type, pid, alive, active, plate, color, inventory, gear, fuel, damage, blacklist FROM vehicles WHERE id='%1' AND pid='%2'",_vid,_pid]; With this: _query = format["SELECT id, side, classname, type, pid, alive, active, plate, color, inventory, gear, fuel, damage, blacklist, insure FROM vehicles WHERE id='%1' AND pid='%2'",_vid,_pid]; Replace this: _vehicle setVariable ["dbInfo",[(_vInfo select 4),(_vInfo select 7)],true]; With this: _vehicle setVariable ["dbInfo",[(_vInfo select 4),(_vInfo select 7),(_vInfo select 14)],true]; Replace this: [1,_spawntext] remoteExecCall ["life_fnc_broadcast",_unit]; serv_sv_use deleteAt _servIndex; With this: if ((_vInfo select 14) isEqualTo 1) then { [ 1 , "Your vehicle is available and it is assured!" ] RemoteExecCall [ "life_fnc_broadcast" , _unit]; }else{ [ 1 , "Your vehicle is available but is not insured!" ] RemoteExecCall [ "life_fnc_broadcast" , _unit]; }; serv_sv_use deleteAt _servIndex; In functions>systems create a new file named "fn_insureCar.sqf" and paste this: /* File: fn_insureCar.sqf Author: Guit0x "Lintox" Description: Insure a vehicle from the garage. */ private["_vid","_pid","_query","_sql","_unit","_insurancePrice","_thread"]; _vid = [_this,0,-1,[0]] call BIS_fnc_param; _pid = [_this,1,"",[""]] call BIS_fnc_param; _unit = [_this,2,ObjNull,[ObjNull]] call BIS_fnc_param; _insurancePrice = [_this,3,0,[0]] call BIS_fnc_param; _query = format["UPDATE vehicles SET insure='1' WHERE pid='%1' AND id='%2'",_pid,_vid]; waitUntil { ! DB_Async_Active}; _thread = [_query,1] call DB_fnc_asyncCall; For life_hc paste this instead: /* File: fn_insureCar.sqf Author: Guit0x "Lintox" Description: Insure a vehicle from the garage. */ private["_vid","_pid","_query","_sql","_unit","_insurancePrice","_thread"]; _vid = [_this,0,-1,[0]] call BIS_fnc_param; _pid = [_this,1,"",[""]] call BIS_fnc_param; _unit = [_this,2,ObjNull,[ObjNull]] call BIS_fnc_param; _insurancePrice = [_this,3,0,[0]] call BIS_fnc_param; _query = format["UPDATE vehicles SET insure=‘1' WHERE pid='%1' AND id='%2'",_pid,_vid]; waitUntil { ! DB_Async_Active}; _thread = [_query,1] call HC_fnc_asyncCall; In FSM>cleanup.fsm replace the entire document with: /*%FSM<COMPILE "C:\Program Files (x86)\Bohemia Interactive\Tools\FSM Editor Personal Edition\scriptedFSM.cfg, Server-Side Cleanup">*/ /*%FSM<HEAD>*/ /* item0[] = {"init",0,250,-62.908096,-391.651611,27.091887,-341.651672,0.000000,"init"}; item1[] = {"true",8,218,-62.976639,-315.185364,27.023363,-265.185364,0.000000,"true"}; item2[] = {"Share__Work_load",2,250,-64.183350,-224.681931,25.816656,-174.681931,0.000000,"Share " \n "Work-load"}; item3[] = {"Continue__",4,218,-220.591476,74.216980,-130.591476,124.216980,0.000000,"" \n "" \n "Continue" \n "" \n ""}; item4[] = {"Time_Check",4,218,-219.425827,-133.310532,-129.425964,-83.310455,0.000000,"Time Check"}; item5[] = {"Delete_Dead_Cars",2,4346,-220.186951,-29.248400,-130.187195,20.751413,0.000000,"Delete" \n "Dead" \n "Cars"}; item6[] = {"",7,210,-312.538239,95.295059,-304.538239,103.295059,0.000000,""}; item7[] = {"",7,210,-312.798218,-204.081940,-304.798218,-196.081940,0.000000,""}; item8[] = {"End_Cleanup_",1,250,-64.828239,87.581070,25.171984,137.581238,0.000000,"" \n "End Cleanup" \n ""}; item9[] = {"Check_for_HC_",4,218,-65.059021,-30.047342,24.941008,19.952658,0.000000,"" \n "Check for HC" \n ""}; link0[] = {0,1}; link1[] = {1,2}; link2[] = {2,4}; link3[] = {3,6}; link4[] = {4,5}; link5[] = {5,3}; link6[] = {5,9}; link7[] = {6,7}; link8[] = {7,2}; link9[] = {9,8}; globals[] = {0.000000,0,0,0,0,640,480,1,53,6316128,1,-481.887177,425.726196,554.522583,-436.926575,170,901,1}; window[] = {0,-1,-1,-32000,-32000,1065,104,1468,104,1,188}; *//*%FSM</HEAD>*/ class FSM { fsmName = "Server-Side Cleanup"; class States { /*%FSM<STATE "init">*/ class init { name = "init"; init = /*%FSM<STATEINIT""">*/"private [""_impound"",""_cars"",""_objs"",""_totCars"",""_thread""];" \n "_impound = time;" \n "_cars = time;" \n "_objs = time;" \n "cleanupFSM setFSMVariable [""stopfsm"",false];"/*%FSM</STATEINIT""">*/; precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/; class Links { /*%FSM<LINK "true">*/ class true { priority = 0.000000; to="Share__Work_load"; precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/; condition=/*%FSM<CONDITION""">*/"true"/*%FSM</CONDITION""">*/; action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/; }; /*%FSM</LINK>*/ }; }; /*%FSM</STATE>*/ /*%FSM<STATE "Share__Work_load">*/ class Share__Work_load { name = "Share__Work_load"; init = /*%FSM<STATEINIT""">*/""/*%FSM</STATEINIT""">*/; precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/; class Links { /*%FSM<LINK "Time_Check">*/ class Time_Check { priority = 0.000000; to="Delete_Dead_Cars"; precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/; condition=/*%FSM<CONDITION""">*/"((time - _cars) > (3 * 60))"/*%FSM</CONDITION""">*/; action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/; }; /*%FSM</LINK>*/ }; }; /*%FSM</STATE>*/ /*%FSM<STATE "Delete_Dead_Cars">*/ class Delete_Dead_Cars { name = "Delete_Dead_Cars"; init = /*%FSM<STATEINIT""">*/"{" \n " if (!alive _x) then {" \n " _dbInfo = _x getVariable [""dbInfo"",[]];" \n " if (count _dbInfo > 0) then {" \n " _uid = _dbInfo select 0;" \n " _plate = _dbInfo select 1;" \n " _insureSystem = _dbInfo select 2;" \n " diag_log "" destroy vehicle !"";" \n " diag_log format[""insureSystem = %1 "", _insureSystem];" \n " if(_insureSystem == 1) then " \n " { diag_log "" Insured !"";" \n " diag_log format[""insureSystem = %1 "", _insureSystem];" \n "" \n " _query_0 = format [""UPDATE vehicles SET alive='1', insure='0', active='0' WHERE pid='%1' AND plate='%2'"",_uid,_plate];" \n " _query_0 spawn {" \n " " \n " _thread = [_this,1] call DB_fnc_asyncCall;" \n " };" \n " } else {" \n " diag_log "" Not insured !"";" \n " diag_log format[""insureSystem = %1 "", _insureSystem];" \n " _query = format[""UPDATE vehicles SET alive='0' WHERE pid='%1' AND plate='%2'"",_uid,_plate]; " \n " _query spawn {" \n " _thread = [_this,1] call DB_fnc_asyncCall;" \n " };" \n " };" \n " if (!isNil ""_x"" && {!isNull _x}) then {" \n " deleteVehicle _x;" \n " };" \n " };" \n "};" \n "} forEach allMissionObjects ""LandVehicle"";" \n "" \n "{" \n " if (!alive _x) then {" \n " _dbInfo = _x getVariable [""dbInfo"",[]];" \n " if (count _dbInfo > 0) then {" \n " _uid = _dbInfo select 0;" \n " _plate = _dbInfo select 1;" \n " _insureSystem = _dbInfo select 2;" \n " diag_log "" destroy vehicle !"";" \n " diag_log format[""insureSystem = %1 "", _insureSystem];" \n " if(_insureSystem == 1) then" \n " { diag_log "" Insured !"";" \n " diag_log format[""insureSystem = %1 "", _insureSystem];" \n " _query_0 = format [""UPDATE vehicles SET alive='1', insure='0', active='0' WHERE pid='%1' AND plate='%2'"",_uid,_plate];" \n " _query_0 spawn {" \n " " \n " _thread = [_this,1] call DB_fnc_asyncCall;" \n " };} else { " \n " diag_log "" Not Insured !"";" \n " diag_log format[""insureSystem = %1 "", _insureSystem];" \n " _query = format[""UPDATE vehicles SET alive='0' WHERE pid='%1' AND plate='%2'"",_uid,_plate]; " \n " _query spawn {" \n " _thread = [_this,1] call DB_fnc_asyncCall;" \n " };" \n " };" \n " };" \n " if (!isNil ""_x"" && {!isNull _x}) then {" \n " deleteVehicle _x;" \n " };" \n " };" \n "} forEach allMissionObjects ""Air"";" \n "_cars = time;" \n "" \n "//Group cleanup." \n "{" \n " if (units _x isEqualTo [] && local _x) then {" \n " deleteGroup _x;" \n " };" \n "} forEach allGroups;"/*%FSM</STATEINIT""">*/; precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/; class Links { /*%FSM<LINK "Check_for_HC_">*/ class Check_for_HC_ { priority = 0.000000; to="End_Cleanup_"; precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/; condition=/*%FSM<CONDITION""">*/"cleanupFSM getFSMVariable ""stopfsm"""/*%FSM</CONDITION""">*/; action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/; }; /*%FSM</LINK>*/ /*%FSM<LINK "Continue__">*/ class Continue__ { priority = 0.000000; to="Share__Work_load"; precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/; condition=/*%FSM<CONDITION""">*/"!(cleanupFSM getFSMVariable ""stopfsm"")"/*%FSM</CONDITION""">*/; action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/; }; /*%FSM</LINK>*/ }; }; /*%FSM</STATE>*/ /*%FSM<STATE "End_Cleanup_">*/ class End_Cleanup_ { name = "End_Cleanup_"; init = /*%FSM<STATEINIT""">*/""/*%FSM</STATEINIT""">*/; precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/; class Links { }; }; /*%FSM</STATE>*/ }; initState="init"; finalStates[] = { "End_Cleanup_", }; }; /*%FSM</COMPILE>*/ For life_hc paste this instead: /*%FSM<COMPILE "D:\Bohemia Interactive\Tools\FSM Editor Personal Edition\scriptedFSM.cfg, Server-Side Cleanup">*/ /*%FSM<HEAD>*/ /* item0[] = {"init",0,250,-65.004578,-391.651611,24.995417,-341.651672,0.000000,"init"}; item1[] = {"true",8,218,-62.976639,-315.185364,27.023363,-265.185364,0.000000,"true"}; item2[] = {"Share__Work_load",2,250,-64.183350,-224.681931,25.816656,-174.681931,0.000000,"Share " \n "Work-load"}; item3[] = {"true",8,218,-54.709698,75.189262,35.290302,125.189262,0.000000,"true"}; item4[] = {"Time_Check",4,218,-219.425827,-133.310532,-129.425964,-83.310455,0.000000,"Time Check"}; item5[] = {"Delete_Dead_Cars",2,4346,-220.186951,-29.248400,-130.187195,20.751413,0.000000,"Delete" \n "Dead" \n "Cars"}; item6[] = {"",7,210,-312.538239,95.295059,-304.538239,103.295059,0.000000,""}; item7[] = {"",7,210,-311.750000,-203.033707,-303.750000,-195.033707,0.000000,""}; link0[] = {0,1}; link1[] = {1,2}; link2[] = {2,4}; link3[] = {3,6}; link4[] = {4,5}; link5[] = {5,3}; link6[] = {6,7}; link7[] = {7,2}; globals[] = {0.000000,0,0,0,0,640,480,1,46,6316128,1,-629.444153,611.207214,293.309357,-434.050568,1243,885,1}; window[] = {2,-1,-1,-1,-1,985,225,1868,225,3,1261}; *//*%FSM</HEAD>*/ class FSM { fsmName = "Server-Side Cleanup"; class States { /*%FSM<STATE "init">*/ class init { name = "init"; init = /*%FSM<STATEINIT""">*/"private[""_impound"",""_cars"",""_objs"",""_totCars"",""_thread""];" \n "_impound = time;" \n "_cars = time;" \n "_objs = time;"/*%FSM</STATEINIT""">*/; precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/; class Links { /*%FSM<LINK "true">*/ class true { priority = 0.000000; to="Share__Work_load"; precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/; condition=/*%FSM<CONDITION""">*/"true"/*%FSM</CONDITION""">*/; action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/; }; /*%FSM</LINK>*/ }; }; /*%FSM</STATE>*/ /*%FSM<STATE "Share__Work_load">*/ class Share__Work_load { name = "Share__Work_load"; init = /*%FSM<STATEINIT""">*/""/*%FSM</STATEINIT""">*/; precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/; class Links { /*%FSM<LINK "Time_Check">*/ class Time_Check { priority = 0.000000; to="Delete_Dead_Cars"; precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/; condition=/*%FSM<CONDITION""">*/"((time - _cars) > (3 * 60))"/*%FSM</CONDITION""">*/; action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/; }; /*%FSM</LINK>*/ }; }; /*%FSM</STATE>*/ /*%FSM<STATE "Delete_Dead_Cars">*/ class Delete_Dead_Cars { name = "Delete_Dead_Cars"; init = /*%FSM<STATEINIT""">*/"{" \n " if(!alive _x) then {" \n "_dbInfo = _x getVariable[""dbInfo"",[]];" \n "if(count _dbInfo > 0) then {" \n "_uid = _dbInfo select 0;" \n "_plate = _dbInfo select 1;" \n "_insureSystem = _dbInfo select 2;" \n " diag_log "" destroy vehicule !"";" \n "diag_log format[""insureSystem = %1 "", _insureSystem];" \n "if(_insureSystem == 1) then " \n "{" \ N " diag_log "" Insured !"";" \n " diag_log format[""insureSystem = %1 "", _insureSystem];" \n " _query_0 = format[""UPDATE vehicles SET alive='1', insure='0', active='0' WHERE pid='%1' AND plate='%2'"",_uid,_plate]; " \n " _query_0 spawn " \n "{" \ N " _thread_0 = [_this,1] call HC_fnc_asyncCall;" \n "};" \ N "}" \ N " else " \n "{" \ N " diag_log "" Not Insured !"";" \n " diag_log format[""insureSystem = %1 "", _insureSystem];" \n " _query = format[""UPDATE vehicles SET alive='0' WHERE pid='%1' AND plate='%2'"",_uid,_plate]; " \n " _query spawn " \n "{" \ N " _thread = [_this,1] call HC_fnc_asyncCall;" \n "};" \ N "};" \ N "};" \ N "if(!isNil ""_x"" && {!isNull _x}) then {" \n "deleteVehicle _x;" \n "};" \ N "};" \ N "} foreach allMissionObjects ""LandVehicle"";" \n "" \ N "{" \ N " if(!alive _x) then {" \n "_dbInfo = _x getVariable[""dbInfo"",[]];" \n "if(count _dbInfo > 0) then {" \n "_uid = _dbInfo select 0;" \n "_plate = _dbInfo select 1;" \n "_insureSystem = _dbInfo select 2;" \n " diag_log "" destroy vehicule !"";" \n "diag_log format[""insureSystem = %1 "", _insureSystem];" \n "if(_insureSystem == 1) then " \n "{" \ N " diag_log "" Insured !"";" \n " diag_log format[""insureSystem = %1 "", _insureSystem];" \n " _query_0 = format[""UPDATE vehicles SET alive='1', insure='0', active='0' WHERE pid='%1' AND plate='%2'"",_uid,_plate]; " \n " _query_0 spawn " \n "{" \ N " _thread_0 = [_this,1] call HC_fnc_asyncCall;" \n "};" \ N "}" \ N " else " \n "{" \ N " diag_log "" Not Insured !"";" \n " diag_log format[""insureSystem = %1 "", _insureSystem];" \n " _query = format[""UPDATE vehicles SET alive='0' WHERE pid='%1' AND plate='%2'"",_uid,_plate]; " \n " _query spawn " \n "{" \ N " _thread = [_this,1] call HC_fnc_asyncCall;" \n "};" \ N "};" \ N "};" \ N "if(!isNil ""_x"" && {!isNull _x}) then {" \n "deleteVehicle _x;" \n "};" \ N "};" \ N "} foreach allMissionObjects ""Air"";" \n "" \ N "_cars = time;" \n "" \ N "//Group cleanup." \n "{" \ N " if(count units _x == 0 && local _x) then {" \n "deleteGroup _x;" \n "};" \ N "} foreach allGroups;"/*%FSM</STATEINIT""">*/; precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/; class Links { /*%FSM<LINK "true">*/ class true { priority = 0.000000; to="Share__Work_load"; precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/; condition=/*%FSM<CONDITION""">*/"true"/*%FSM</CONDITION""">*/; action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/; }; /*%FSM</LINK>*/ }; }; /*%FSM</STATE>*/ }; initState="init"; finalStates[] = { }; }; /*%FSM</COMPILE>*/ In functions>systems>fn_getVehicles.sqf: Replace this: _query = format["SELECT id, side, classname, type, pid, alive, active, plate, color, inventory, gear, fuel, damage, blacklist FROM vehicles WHERE id='%1' AND pid='%2'",_vid,_pid]; With this: _query = format["SELECT id, side, classname, type, pid, alive, active, plate, color, insure FROM vehicles WHERE pid='%1' AND alive='1' AND active='0' AND side='%2' AND type='%3'",_pid,_side,_type]; Run this query in your SQL Database: ALTER TABLE vehicles ADD insure INT(1) NOT NULL DEFAULT '0'; Done!
  27. 1 point
    It's not something shared around here that I know of.
  28. 1 point
  29. 1 point
    i dont read whole post but see this and this is not for 4
  30. 1 point
    Life_server init.sqf: /* Set the amount of gold in the federal reserve at mission start */ fed_bank setVariable ["safe",count playableUnits,true]; [] spawn TON_fnc_federalUpdate; fn_federalUpdate.sqf _funds = fed_bank getVariable ["safe",0]; fed_bank setVariable ["safe",round(_funds+((count playableUnits)/2)),true];
  31. 1 point
    From what your comment is I'm guessing your trying to open the map in the editor? In that case you would need to open the mission.sqm (Found in the AltisLife.Altis). The arma 3 editor will only help you with the map (mission.sqm) and GUI (When you get to that point). If your trying to code in then you'd need to use a editor such as notepad ++ or Visual studio code. I suggest making a new save of a empty Altis map then copying the mission.sqm into that folder then edit at your hearts content. Regards, Wallace
  32. 1 point
    That looks like a BOM character run your file through Imthatguyhere's BOM finder. http://arma.imthatguyhere.com/bom/
  33. 1 point
    Working Scripts Archive easy access to all available scripts _____________________________________________________________________________________________________________________________________________ UI and Informational Professional looking HUD Intro Music Intro Music 2 Intro Text Intro Cam Intro Video Outro Script StatusBar Removing Default Statusbar Spawn Menu Redone Updated HUD IPAD Y Menu IPAD Y Menu 2 AI Based Scripts Dynamic Airdrop Improvements & Basic Features Brighter Nights Simply Morphine and Bandages Dynamic market 5.0 Custom Spawn Loadouts for Civilians Seat Belts Patdown Player + Seize Objects Realistic Towing Ear Plugs Rubber Bullets Realistic CPR Kit Actions Menu Tag System Speed Bomb Zip Ties Police Backup Jaws of Life Realistic Tazer Hand Gestures Buyable Loadouts Backpack Custom Capacity Marijuana Effects Gag Action Fastrope Auto Save Adding Smoke Effect to Processing Placeable Objects for Police Invisible Backpacks for police/med Anti VDM Block Changing Names Cops can enter locked vehicles Warner's Barriers Configurable Jail Time Adding police radar GPS System Car Alarm Boat Rental Civilian Passports Police Gate Opening Hotkey Adding Smoke Trails to Cesna Suicide Vest Automatic Messages Animal Tracking (for Hunting) Wedding rings Systems and Complex Features Questing System Zipties Revised [Fully Working, With Gag and Blindfolds] Vehicle Insurance RYANTTS DYNAMIC MARKET SYSTEM OPFOR 4.4 Advanced Banking System, With Pins MrKraken's Gas Station Robbery Script Bounty Hunting Framework [Dialog, DB, Player Interaction] Altis Central Bank - Second Fed Purge [Server Event] Crafting System Slot Machines Bus Transportation Physical Cellphone Gang Capturable Areas Tutorials Basic Coding Tutorial Moving the Federal Reserve Task force Radio Black screen when not in channel ETC Separate Police/Civ Cash & Bank Account Gang Name Spawns Custom Medic & Cop Skins Adding Licenses 4.4 Tobacco-field Civilian Whitelisting Installing Task Force Radio (Addon/Mod) Mining with Shift+C Custom Paychecks Official Paid Scripts Maverick Applications Let me know if i missed anything
  34. 1 point
    Problem Identified. He's a TADST User. Kappa
  35. 1 point
    Hey today im releasing my Mechanic Toolbox script that i made for a framework im working on. ENJOY! feel free to change the icon of the mechanic toolbox i havent changed it because im a sloth PLEASE READ This is for a mechanic jobs you can make out of it and its made so when the normal toolkit is used it repairs 40% and you need a mechanic toolbox to get it to a 100% but if you want it to work as a job you can easy make it whitelisted for a licensens or add the item in the script of a loadout script if you have that, idc but just a reminder so you know its purpose DOWNLOAD INFOMATION [difficulty should be easy] Step 1: go inside youre core\actions and paste this in there fn_Mechanictool.sqf Step 2: now go into youre config_vItem.hpp and paste this code in the class VirtualItems class MechanicTool { variable = "MechanicTool"; displayName = "STR_Item_FMCD"; weight = 4; buyPrice = 350; sellPrice = 100; illegal = false; edible = -1; icon = "\a3\weapons_f\items\data\UI\gear_toolkit_ca.paa"; }; Step 3: replace these lines in the fn_vInteractionMenu.sqf : #define Btn1 37450 #define Btn2 37451 #define Btn3 37452 #define Btn4 37453 #define Btn5 37454 #define Btn6 37455 #define Title 37401 private["_display","_curTarget","_Btn1","_Btn2","_Btn3","_Btn4","_Btn5","_Btn6,"_dlcVehicles"]; if (!dialog) then { createDialog "vInteraction_Menu"; }; disableSerialization; whit this: #define Btn1 37450 #define Btn2 37451 #define Btn3 37452 #define Btn4 37453 #define Btn5 37454 #define Btn6 37455 #define Btn7 37155 #define Title 37401 private["_display","_curTarget","_Btn1","_Btn2","_Btn3","_Btn4","_Btn5","_Btn6","_Btn7","_dlcVehicles"]; if (!dialog) then { createDialog "vInteraction_Menu"; }; disableSerialization; step 4: in the same folder replace these lines: _display = findDisplay 37400; _Btn1 = _display displayCtrl Btn1; _Btn2 = _display displayCtrl Btn2; _Btn3 = _display displayCtrl Btn3; _Btn4 = _display displayCtrl Btn4; _Btn5 = _display displayCtrl Btn5; _Btn6 = _display displayCtrl Btn6; life_vInact_curTarget = _curTarget; _dlcVehicles = ["C_Kart_01_Blu_F","C_Kart_01_Red_F","C_Kart_01_Fuel_F","C_Kart_01_Vrana_F","B_Heli_Transport_03_F","B_Heli_Transport_03_unarmed_F","O_Heli_Transport_04_F","O_Heli_Transport_04_ammo_F","O_Heli_Transport_04_bench_F","O_Heli_Transport_04_box_F","O_Heli_Transport_04_covered_F","O_Heli_Transport_04_fuel_F","O_Heli_Transport_04_medevac_F","O_Heli_Transport_04_repair_F"]; whit these: _display = findDisplay 37400; _Btn1 = _display displayCtrl Btn1; _Btn2 = _display displayCtrl Btn2; _Btn3 = _display displayCtrl Btn3; _Btn4 = _display displayCtrl Btn4; _Btn5 = _display displayCtrl Btn5; _Btn6 = _display displayCtrl Btn6; _Btn7 = _display displayCtrl Btn7; life_vInact_curTarget = _curTarget; _dlcVehicles = ["C_Kart_01_Blu_F","C_Kart_01_Red_F","C_Kart_01_Fuel_F","C_Kart_01_Vrana_F","B_Heli_Transport_03_F","B_Heli_Transport_03_unarmed_F","O_Heli_Transport_04_F","O_Heli_Transport_04_ammo_F","O_Heli_Transport_04_bench_F","O_Heli_Transport_04_box_F","O_Heli_Transport_04_covered_F","O_Heli_Transport_04_fuel_F","O_Heli_Transport_04_medevac_F","O_Heli_Transport_04_repair_F"]; Step 5: now add this in the same file under the repair action should look something like this https://gyazo.com/d9701e0928f12f2dd553ff0d7497584b: // mechanic repair action by fanzer _Btn7 ctrlSetText localize "STR_fzact_Repair"; _Btn7 buttonSetAction "[life_vInact_curTarget] spawn life_fnc_Mechanictool; closeDialog 0;"; step 6: then add this in the same file under the life_inv_toolkit should look something like this https://gyazo.com/24240b9883cc0db0337c24a13898be25: if ((life_inv_MechanicTool >= 1) && {alive life_vInact_curTarget} && {([life_vInact_curTarget] call life_fnc_isDamaged)}) then {_Btn7 ctrlEnable true;} else {_Btn7 ctrlEnable false;}; step 7: now go inside youre functions.hpp and go down to class Actions and add this line: class Mechanictool {}; step 8: now go inside the stringtable.xml and go somewhere at the buttom or where ever you want and add this line: <Key ID="STR_Item_FMCD"> <Original>Mechanic Toolbox</Original> </Key> and you should be done if you have any problems ill will help if i have time!
  36. 1 point
    Difficulty: Easy Author: Dexter Go inside of your script folder (If not there make one) Make a new file called "fn_IntroCam.sqf" /* File: fn_IntroCam.sqf Author: Dexter ( script might already be known, havent seen it yet though ) */ private ["_camera", "_camDistance","_randCamX","_randCamY","_camTime"]; _camDistance = 350; _randCamX = 75 - floor(random 150); _randCamY = 75 - floor(random 150); _camTime = 30; // you can change the time for sure, I adjusted mine to the intro music // the one below basically says that if you already joined the server once the time of the camera movement will be faster, else it might get annoying if(!life_firstSpawn) then { _camTime = 30;}; //intro move showCinemaBorder true; camUseNVG false; _camera = "camera" camCreate [(position player select 0)+_randCamX, (position player select 1)+_randCamY,(position player select 2)+_camDistance]; _camera cameraEffect ["internal","back"]; _camera camSetFOV 2.000; _camera camCommit 0; waitUntil {camCommitted _camera}; _camera camSetTarget vehicle player; _camera camSetRelPos [0,0,2]; _camera camCommit _camTime; waitUntil {camCommitted _camera}; _camera cameraEffect ["terminate","back"]; camDestroy _camera; life_firstSpawn = false; Now go inside Altis_Life.Altis\dialog\function and open file "fn_spawnConfirm.sqf" Go to the bottom and Find "life_firstSpawn" and make it look like this: if (life_firstSpawn) then { [] spawn { cutText ["","BLACK IN"]; [] execVM "script\fn_introcam.sqf"; life_firstSpawn = false; }; };
  37. 1 point
    Well I have used some of the tutorials found here and thought it is only fair for me to put one up for what I made the other day. Apologies if my script is not optimised etc, one of my friends told me I write "wet" code. Difficulty: Easy Framework Version: 4.4r3 10 damage every 5 seconds can be set to whatever you want. If wearing the set clothing no damage but you still get the effects. Right start with the map side, in the mission editor you need to create a trigger point, the size does not matter, you can have it as big or as small as you want. Once created you need to edit its properties so right click the trigger point and click properties. you should get this menu. the Variable name can be anything you want, you need to set the "Trigger: Activation" and "Trigger: Expression" Trigger: Activation Type: None Activation: Anybody Activation Type: Present Repeatable: Yes Server Only: No Trigger: Expression Condition: this && (local player) && (vehicle player in thisList) On Activation: hint parseText format ["<t color='#0eb0ff'>You have entered a radioactive area!</t>"]; player setVariable ["exitRad",false]; player call life_fnc_radArea; On Deactivation: hint parseText format ["<t color='#0eb0ff'>You are leaving the radioactive area!</t>"]; player setVariable ["exitRad",true]; Click ok, save the mission and that is the map side done. Now for the mission file. Create a new file in Altis_Life.Altis\core\functions called fn_radArea.sqf, then copy and paste the below script inside it. If you want to set how often damage is caused just edit the "sleep 5," to however long you want. If you want to edit how much damage is caused edit the "_player setDamage (_damage + 0.1)" remember 0 is 100% of health 1 is dead. To set what clothing is required to be warn edit the "if ((_uniform isEqualTo "U_B_Wetsuit") && (_vest isEqualTo "V_RebreatherB") && (_goggles isEqualTo "G_Diving")) then". #include "..\..\script_macros.hpp" /* fn_radArea.sqf Created by Fuel for RebornRoleplay.com [UK/EU] Reborn Roleplay | RebornRoleplay.co.uk */ _player = [_this,0,objNull,[objNull]] call BIS_fnc_param; _damage = getDammage _player; _uniform = uniform _player; _vest = vest _player; _goggles = goggles _player; _rad1 = ppEffectCreate ["ChromAberration",200]; _rad2 = ppEffectCreate ["DynamicBlur",500]; _rad3 = ppEffectCreate ["FilmGrain",2000]; if (!alive _player || (_damage == 1) || (_player getVariable ["exitRad",true])) exitWith { _player setVariable ["exitRad",true]; _rad1 ppEffectEnable false; _rad1 ppEffectAdjust [0,0,true]; _rad1 ppEffectCommit 1; _rad2 ppEffectEnable false; _rad2 ppEffectAdjust [0]; _rad2 ppEffectCommit 1; _rad3 ppEffectEnable false; _rad3 ppEffectAdjust [0,0,0,0,0,true]; _rad3 ppEffectCommit 1;}; // this is the check to see if they are wearing protective clothing if ((_uniform isEqualTo "U_B_Wetsuit") && (_vest isEqualTo "V_RebreatherB") && (_goggles isEqualTo "G_Diving")) then { //rad sound _player say2d "rad"; // edit this for the length of the effect for "_i" from 0 to 4 do { _rad1 ppEffectEnable true; _rad1 ppEffectAdjust [-0.02,0,true]; _rad1 ppEffectCommit 1; _rad2 ppEffectEnable true; _rad2 ppEffectAdjust [0.03]; _rad2 ppEffectCommit 1; _rad3 ppEffectEnable true; _rad3 ppEffectAdjust [0.12,1.52,3.54,2,2,true]; _rad3 ppEffectCommit 1; }; sleep 5; //loops the script until they exit [_player] remoteExec ["life_fnc_radArea",_player]; } else { //rad sound _player say2d "rad"; // edit this for the length of the effect for "_i" from 0 to 4 do { _rad1 ppEffectEnable true; _rad1 ppEffectAdjust [-0.02,0,true]; _rad1 ppEffectCommit 1; _rad2 ppEffectEnable true; _rad2 ppEffectAdjust [0.03]; _rad2 ppEffectCommit 1; _rad3 ppEffectEnable true; _rad3 ppEffectAdjust [0.12,1.52,3.54,2,2,true]; _rad3 ppEffectCommit 1; }; sleep 5; //set the damage to player _player setDamage (_damage + 0.1); //loops the script until they exit [_player] remoteExec ["life_fnc_radArea",_player]; }; Now open your Functions.hpp, and paste class radArea {}; inside of class Functions { file = "core\functions"; Now open cfgRemoteEcec.hpp, and paste F(life_fnc_radArea,CLIENT) inside of class CfgRemoteExec { class Functions { mode = 1; jip = 0; /* Client only functions */ Now open description.ext, and paste class rad { name = "rad"; sound[] = {"\sounds\rad.ogg", 0.25, 1}; titles[] = {}; }; inside of class CfgSounds { sounds[] = {}; Now copy the attached sound file called rad.ogg and paste it into Altis_life.Altis/sounds/ And you are done, I do not think I have missed anything. here if a quick video of it in action. rad.ogg
  38. 1 point
  39. 1 point
    For noobs. Here are the codes you need to add custom textures for cop uniform skins, medic uniform skins, medic backpack skins, cop backpack skins, medic backpack skins allocated to certain ranks, cop backpack skins allocated to certain ranks etc. File: fn_playerSkins.sqf COP: For adding custom backpack textures: if ((backpack player) == "insertClassnameHere") then { (unitbackpack player) setObjectTextureGlobal [0,"textures\*insertDirectoryHere.jpg"]; }; For adding custom uniform skins assigned to certain ranks: if ((FETCH_CONST(life_coplevel) >= 3) && ((uniform player) == "U_B_CombatUniform_mcam")) then { player setObjectTextureGlobal [0, "textures\clothing\cop\cop_uniform_sarg.jpg"]; }; *NOTE* the "3" in >= 3 refers to the cop level. and the >= basically means "greater than or equal too". You can change it accordingly to what you want. <= will mean less than or equal too. So "if life_coplevel is less than or equal to 3, than all cop levels below level 3 including level 3 will equip THAT specified skin when they buy the clothing, which in this case is U_B_CombatUniform_mcam. MEDIC: For medics it is literally the same, just changing life_coplevel to life_mediclevel. It should look something like this. if ((FETCH_CONST(life_mediclevel) >= 3) && ((uniform player) == "U_B_CombatUniform_mcam")) then { player setObjectTextureGlobal [0, "textures\clothing\med\par.jpg"]; }; Hopefully you get the idea. For reference, below I will include an example of what your file should look like. case west: { if(uniform player == "U_Rangemaster") then { player setObjectTextureGlobal [0, "textures\cop_uniform.jpg"]; }; if ((FETCH_CONST(life_coplevel) >= 3) && ((uniform player) == "U_B_CombatUniform_mcam")) then { player setObjectTextureGlobal [0, "textures\clothing\cop\cop_uniform_sarg.jpg"]; }; if ((FETCH_CONST(life_coplevel) >= 7) && ((uniform player) == "U_O_OfficerUniform_ocamo")) then { player setObjectTextureGlobal [0, "textures\clothing\cop\coastguard.jpg"]; }; if ((backpack player) == "B_Bergen_blk") then { (unitbackpack player) setObjectTextureGlobal [0,"textures\clothing\cop\cop_bergen.jpg"]; }; }; case independent: { if(uniform player == "U_Rangemaster") then { player setObjectTextureGlobal [0, "textures\clothing\med\medic_uniform.jpg"]; }; if ((FETCH_CONST(life_mediclevel) >= 1) && ((uniform player) == "U_B_CombatUniform_mcam")) then { player setObjectTextureGlobal [0, "textures\clothing\med\emt.jpg"]; }; if ((FETCH_CONST(life_mediclevel) >= 2) && ((uniform player) == "U_B_CombatUniform_mcam")) then { player setObjectTextureGlobal [0, "textures\clothing\med\aemt.jpg"]; }; if ((FETCH_CONST(life_mediclevel) >= 3) && ((uniform player) == "U_B_CombatUniform_mcam")) then { player setObjectTextureGlobal [0, "textures\clothing\med\par.jpg"]; }; if ((FETCH_CONST(life_mediclevel) >= 4) && ((uniform player) == "U_Rangemaster")) then { player setObjectTextureGlobal [0, "textures\clothing\med\lieutenant.jpg"]; }; if ((FETCH_CONST(life_mediclevel) >= 5) && ((uniform player) == "U_Rangemaster")) then { player setObjectTextureGlobal [0, "textures\clothing\med\captain.jpg"]; }; if ((backpack player) == "B_Kitbag_mcamo") then { (unitbackpack player) setObjectTextureGlobal [0,"textures\clothing\med\medic_backpack.jpg"]; }; }; *WARNING* Make sure you order your skin ranks as shown above ! They must be in ascending order otherwise the game will just load the one after the next, which may not be the skin you want for that rank.
  40. 1 point
    Hello, Thanks for that, it's working well on 5.0 Can you tell me what to do to set some damage even if there is protection ( -50% for exemple ) At the moment it's no damage with clothing Thanks EDIT: // this is the check to see if they are wearing protective clothing if ((_uniform isEqualTo "U_C_Scientist")) then { _player setDamage (_damage + 0.05);
  41. 1 point
    I have collected some Script Releases from the old Forum wich I can't find here. I only printed the Website in Reading View and basicView with FreePFD. I want to share this, maybe someone is bored and want to get this old stuff working. I am interested on the wantetbased speedradar and I will have a look on it in the next few days. [HOW TO] Molotov Cocktails [HOW TO] Watermark your server [How To]Alcohol with multiple item processing,Drunk Effects, Passouts, and Police Breathalyzing [HowTo] Have Sex with a hooker [HOWTO] midgetgrimm's alcohol system in Altis Life 4.0.0 [HOWTO] Persistent Vehicle Inventory [Script] ShipWreck's by Ryan [Script] Temporary Marriage [Tutorial] Fitness center which energizes [Tutorial] Stable Paintball Script [TUTORIAL] Wasted Death Screen Radar Script Robbing the ATM's In Altis Life Simple Organ Theft with Black Market Sales Speed radar cam (yes another, but different) Speedcontrolscript Give Credit to the author! ALRPG_ressource.rar
×
×
  • Create New...