Jump to content
Sign in to follow this  

Vehicle driver seat restriction according to humanity.

Recommended Posts


This is a restriction to vehicle seat according to humanity.

It may be handy to PVE servers out there.

Special thanks to Juandayz with his fantastic skills and salival. Both sometimes working unseen for the benefit of this community.

Step 1.

Make a new file, Name it veh_hum.sqf with the below contents and put into dayz_epoch/addons folder. If you dont have addons just create one.

In this example we have a hero superhero and agenthero traders with 20k/40k/60k humanity respectively. Adjust according to your needs.


private ["_vehicle","_inVehicle","_driver","_humanity","_txt"];

while {true} do {

_vehicle = vehicle player;
_inVehicle = (_vehicle != player);

if (_inVehicle) then {
	_driver = driver (vehicle player);

	if (({(isPlayer _driver) && (alive _driver)} count (crew _vehicle) > 0)) then {

		_humanity = _driver getVariable["humanity",0];

		if (typeOf _vehicle in DZE_heroHumanity && _humanity <= 20000 || (typeOf _vehicle in DZE_superHeroHumanity && _humanity <= 40000) || (typeOf _vehicle in DZE_agentHumanity && _humanity <= 60000)) then {
			player action ["getOut", (vehicle player)];
			titleText ["","WHITE IN"];
			_txt = "<img image='addons\vehicon.paa' /><br/><t size='0.7' color='#ea2828' align='center'>prohibited vehicle</t>";
            [_txt, [safezoneX, safezoneW], [0.20 * safezoneH + safezoneY, 0.3 * safezoneH], 2, 0.5] spawn BIS_fnc_dynamicText;
sleep 3;

 Step 2: Download this file http://www.mediafire.com/file/bdpt5d96o5cttk3/vehicon.rar

Unzip and put paa file into addons folder.

Step 3: Edit your custom variables file    dayz_code/init/variables.sqf

Put the vehicles you want to restrict below call dayz_resetselfactions; ike this:

	// Custom below
	s_givemoney_dialog = -1;
	s_bank_dialog = -1;
	s_player_checkWallet = -1;
	s_bank_dialog1 = -1;
	s_bank_dialog2 = -1;
	s_player_copyToKey = -1;
	s_player_claimVehicle = -1;
	s_collect_heli = -1;

call dayz_resetSelfActions;

	DZE_heroHumanity = ["Mi17_rockets_RU","Mi24_D","UH1Y_DZE"];
	DZE_superHeroHumanity = ["Mi24_V","Mi24_P","Ka52"];		
	DZE_agentHumanity = ["AV8B2","AV8B","A10","F35B"];
	DZE_safeVehicle = DZE_heroHumanity + DZE_superHeroHumanity + DZE_agentHumanity +["ParachuteWest","ParachuteC"];

Step 4: Edit your init file to exec the script. Above the   (false,12)execVm.... like below

    [] execVM "addons\veh_hum.sqf";
    //[false,12] execVM "\z\addons\dayz_code\compile\local_lights_init.sqf";

Thats it. Enjoy!

  Hide contents

Share this post

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

  • Similar Content

    • By vbawol
      Open world survival mod set just two years after the mass extinction of billions of people. Those that remain are left with remnants of a once technological society. Try to survive, build, or explore your way through the harsh dynamic environment.
      Powerful persistence framework for Arma 3 with native Windows and Linux dedicated server support. Fully configurable script based security checks. Base Building re-envisioned for Arma 3 PhysX. Persistent secure and insecure storage devices. Upgradeable locking doors. Barter based economy and trading systems backed a single currency ¤ called "Krypto". Hostile Environment with several different types of antagonists, Air and Water temperature extremes, and Earthquakes. Hunting, Fishing, Tame Dogs, Explore & Loot: Wrecked ships, Abandoned vehicles and buildings, Perform task based missions and more! Open source APL-SA Epoch Survival MP gamemode. Open source APL-SA Modders resource configs and Class List. Assets can be used as a mod dependency on Steam workshop.
    • By MSDZ
      Hey guys! I decided that relaunching my Namalsk Overpoch server would be fun!
      Discord: https://discord.gg/QbuGTju
      The server is semi militarized
         - Certain vehicles are in game, but with limited weaponry,
         - All high end trade items are at the traveling trader or at a secret trader location
      Running a fully fresh DB, 350 build limit. Feel free to hop on!
    • By spitfirez404
      Veteran Gamers United
                                                                         Server Features: 
                                                                        *Coins, Gold & Gems
                                                                        *Claim Vehicles
                                                                        *Color Filter
                                                                        *Toggle Grass On Or Off
                                                                        *Deployable Bike & Mozzie
                                                                        *New Custom Building Menu
                                                                        *Suicide On Knife
                                                                        *Change View Distance
                                                                        *Group Management
                                                                        *High Loot
                                                                        *Base Raiding
                                                                        *Base Take Over
                                                                    **And Many More** 
      This server is a new one from our last and features alot more scripts. We are adding more in all the time! Server restarts every six hours, and Admins are always available to help if needed. You need both Epoch & Overwatch mods to play. Come give it a go and see what you think :)
    • By PapaSmurf
      Server Name: [PSG]DayZ Overpoch Chernarus|Start 10/18|Coins|FPS+|WAI|Missions|Grp|SSD|Dedicated|Spawn Select|Active Staff|
      Server IP:
      Mods: @DayzOverwatch;@DayZ_Epoch;
      Server Start: 10/18/2018
      Join our Discord!
      PSG is now online! Lots of neat features and a non-militarized vibe!
      Server features and rules are listed below. I'll be regularly adding more content so I hope to see you guys on!
      Feel free to hop on our discord if you have any further questions!
      Server Features:
      Custom Areas (Trainyard, Compound, Oil Rig, Camps, Abandoned Trader, ...)
      Increased Zombie Damage
      Base raiding
      Base takeover areas (Special areas of map)
      Coins can be stored in Safes or Lockboxes
      Coins you are carrying will be lost on death
      Spawn selection and humanity loadout
      Wicked AI and Missions
      Deploy Bike/Mozzies
      Pistol Suicide
      Take clothes from dead AI/players
      Repair at service points/gas stations for coins
      Locate/Vehicle controls with keys
      Set view distance with map 
      Locked vehicles within plot area are immune to damage
      Safes cannot be hotwired
      General Rules:
      Be respectful to other players and staff
      No destroying plot poles
      Base takeovers allowed only in certain areas (Notified upon entering)
      Hackers and anyone benefitting from hackers will be banned
      Only Air to Air kamikaze is allowed
      No advertising other services or servers
      No Spamming
      Safe Zones Rules:
      No stealing Items/Vehicles
      No trolling in safe zones
      No ramming in safe zones
      Safe zone camping is allowed (Leaving safe zone grants temporary god mode)
      Base Rules:
      No Building within 800m of Military Buildings or Traders. (Construction will fail if you try)
      No glitching/finding exploits into bases
      No blocking roads with buildings or vehicles in your plot area
    • By C4-timah
      I am enjoying Grahame's EpochZ immensely.  However, if you are infected by the z's, after 30min you will die (animation for the 30min infection period is excellent btw). Upon death you will be shown the option to re-spawn. At that time you are promptly kicked by BattlEye for setvariable restriction #0:
      04.10.2018 00:14:33: C4-timah ( 57f9a830eeb99412623ce1c3d14b7d50 - #0 "ryanzombiesinfected" = 0 2:2877 Epoch_Male_F  
      If you are killed by the z's (beaten to death), upon your death you will also be shown a re-spawn option and then promptly kicked again for a BattlEye setvariable restriction #0:
      05.10.2018 21:53:02: C4-timah ( 57f9a830eeb99412623ce1c3d14b7d50 - #0 "ryanzombiesimmunity" = false 2:17479 Epoch_Male_F Adding
      !"ryanzombiesinfected" = 0 or
      !"ryanzombiesimmunity" = false does not appear to stop the BE kick. All the other filters in the setvariable.txt all start with  !=  which would indicates the filter must match exactly which would lead me to believe the key word that I need is something entirely different. I am using BattlEye Filter Manager to add the exceptions to the setvariable.txt. As you'll see, all the exceptions have !=" instead of !" unlike the last two that I have placed.
      //new2 5 "" !=(traderName|Offer|Accept|BUILD_SLOT|TRADE_ACTIVE|last_targeter|epoch_(antagobj|antagBomb)) !="bis_fnc_objectvar_var" !="bis_fnc_selectrespawntemplate_respawned" !="#(rev_enabled|var)" !="cup_tow_towedveh" !"ryanzombiesimmunity\" = false" !"ryanzombiesinfected\" = 0"  
      My rpt file shows the following error when killed by an EpochZ Zombie:
      17:44:02 BE protection activated for player id=726964973, name='whitehorse', msgType=285 setvariable.log:
      11.10.2018 17:44:02: whitehorse ( c2568b411cbd25fa774021698eade7c5 - #0 "ryanzombiesinfected" = 0 2:15917 Epoch_Male_F Ideas? Getting kicked every time you get killed by a Z has to be annoying to theses guys and I'd rather not lose the few that are consistently playing on our server. Any help is greatly appreciated.
  • Advertisement
  • Supporters
  • Discord

  • Create New...