Deploy & Re-Pack Bike
DESCRIPTION:
FILES:
INSTALLATION:
DESCRIPTION:
- This Script was made by [AUR]Ace (original by maca)
- This allows you to add a right click option to a toolbox to deploy a pushbike
- In addition, you are able to pack the back and get your toolbox back by using a scroll option
- This script was made specially to avoid an annoying scroll option to deploy which may be accidentally clicked
FILES:
You will need to edit:- compiles.sqf
- init.sqf
- description.ext
- ui_selectSlot.sqf
- extra_rc.hpp
- deploy.sqf
- pack.sqf
- compiles.sqf
INSTALLATION:
- Unpack your dayz_mission.pbo or any mission file you have. (May not be in PBO format)
- Only follow this step if you DON'T have a custom compiles.sqf or fn_selfAction.sqf already
- Go to your "@DayZ\addons" folder and open dayz_code.pbo.
Then copy compiles.sqf (in the init folder) and fn_selfAction.sqf (in the compile) folder, to your root mission folder (where init.sqf is located)
- In your root mission folder, open init.sqf and change:
Code:call compile preprocessFileLineNumbers "\z\addons\dayz_code\init\compiles.sqf";
Code:call compile preprocessFileLineNumbers "compiles.sqf";
- Also in compiles.sqf, change:
Code:fnc_usec_selfActions = compile preprocessFileLineNumbers "\z\addons\dayz_code\compile\fn_selfActions.sqf";
Code:fnc_usec_selfActions = compile preprocessFileLineNumbers "fn_selfActions.sqf";
- Go to your "@DayZ\addons" folder and open dayz_code.pbo.
- Now open fn_selfActions.sqf from your root mission folder place this code at the bottom of it:
Code://----------PACK BIKE START---------- _weapons = [currentWeapon player] + (weapons player) + (magazines player); _isBike = typeOf cursorTarget in ["Old_bike_TK_INS_EP1","Old_bike_TK_CIV_EP1"]; if((_isBike) and _canDo) then { if (s_player_deploybike2 < 0) then { s_player_deploybike2 = player addaction[("<t color=""#007ab7"">" + ("Pack Bike") +"</t>"),"pack.sqf","",5,false,true,"", ""]; }; } else { player removeAction s_player_deploybike2; s_player_deploybike2 = -1; }; //----------PACK BIKE END----------
- Now open compiles.sqf from your root mission folder and change:
Code:player_selectSlot = compile preprocessFileLineNumbers "\z\addons\dayz_code\compile\ui_selectSlot.sqf";
Code:player_selectSlot = compile preprocessFileLineNumbers "ui_selectSlot.sqf";
- Now open description.ext and place the following code at the bottom of it:
Code:#include "extra_rc.hpp"
- Download the attached .zip file, and place the 4 files, loose inside the root mission folder (where init.sqf is located)
http://www.aussierebels.org/phpBB3/ Go to Script Tutorials -> DayZMod (General) -> Deploy Bike Script
NOTE: If you get killed when you get on the bike or deploy it:- Open server_functions.sqf from dayz_server.pbo and change:
Code:server_checkHackers = { if (DZE_DYN_AntiStuck2nd > 3) then { DZE_DYN_HackerCheck = nil; DZE_DYN_AntiStuck2nd = 0; }; if(!isNil "DZE_DYN_HackerCheck") exitWith { DZE_DYN_AntiStuck2nd = DZE_DYN_AntiStuck2nd + 1;}; DZE_DYN_HackerCheck = true; { if(vehicle _x != _x && !(vehicle _x in PVDZE_serverObjectMonitor) && (isPlayer _x) && !((typeOf vehicle _x) in DZE_safeVehicle)) then { //diag_log ("CLEANUP: KILLING A HACKER " + (name _x) + " " + str(_x) + " IN " + (typeOf vehicle _x)); (vehicle _x) setDamage 1; _x setDamage 1; sleep 0.25; }; sleep 0.001; } forEach allUnits; DZE_DYN_HackerCheck = nil; };
Code:/* server_checkHackers = { if (DZE_DYN_AntiStuck2nd > 3) then { DZE_DYN_HackerCheck = nil; DZE_DYN_AntiStuck2nd = 0; }; if(!isNil "DZE_DYN_HackerCheck") exitWith { DZE_DYN_AntiStuck2nd = DZE_DYN_AntiStuck2nd + 1;}; DZE_DYN_HackerCheck = true; { if(vehicle _x != _x && !(vehicle _x in PVDZE_serverObjectMonitor) && (isPlayer _x) && !((typeOf vehicle _x) in DZE_safeVehicle)) then { //diag_log ("CLEANUP: KILLING A HACKER " + (name _x) + " " + str(_x) + " IN " + (typeOf vehicle _x)); (vehicle _x) setDamage 1; _x setDamage 1; sleep 0.25; }; sleep 0.001; } forEach allUnits; DZE_DYN_HackerCheck = nil; }; */
- Open server_functions.sqf from dayz_server.pbo and change:
- Pack your mission file (if it was a PBO) and you are ready to go!
Last edited: