AOD_Assassin Posted April 23, 2014 Report Share Posted April 23, 2014 I have looked all over google and I cannot find a deployable bike script that works anywhere. If anyone has found one could you please share it? Link to comment Share on other sites More sharing options...
0 bsmaff Posted April 23, 2014 Report Share Posted April 23, 2014 Add this to fnselfactions: //deploy bike if (("PartGeneric" in _mags) && ("PartWheel" in _mags) && ("ItemToolbox" in _itemsPlayer)) then { hasBikeItem = true; } else { hasBikeItem = false;}; if((speed player <= 1) && hasBikeItem && _canDo) then { if (s_player_deploybike < 0) then { s_player_deploybike = player addaction[("<t color="#FFFF00"">" + ("Construct Bike") +"</t>"),"custom\make_bike.sqf","",5,false,true,"", "]; }; } else { player removeAction s_player_deploybike; s_player_deploybike = -1; }; Deploy bike script: if (dayz_combat == 1) then { cutText [format["You are in combat and cannot build a bike."], "PLAIN DOWN"]; } else { private ["_object"]; player removeAction s_player_deploybike; player playActionNow "Medic"; r_interrupt = false; player removeMagazine "PartGeneric"; player removeMagazine "PartWheel"; _dis=10; _sfx = "repair"; [player,_sfx,0,false,_dis] call dayz_zombieSpeak; [player,_dis,true,(getPosATL player)] spawn player_alertZombies; sleep 6; _object = createVehicle ["Old_bike_TK_INS_EP1", position player,[],0,"CAN_COLLIDE"]; _object setVariable ["ObjectID", "1", true]; _object setVariable ["ObjectUID", "1", true]; player reveal _object cutText [format["You've bodged together a bike!"], "PLAIN DOWN"]; r_interrupt = false; player switchMove ""; player playActionNow "stop"; sleep 10; cutText [format["Warning: Spawned Bikes do not save after server restart!"], "PLAIN DOWN"]; }; AOD_Assassin 1 Link to comment Share on other sites More sharing options...
0 AOD_Assassin Posted April 23, 2014 Author Report Share Posted April 23, 2014 Also should the fn_selfactions.sqf be in the custom folder with the player_selfblood.sqf? Link to comment Share on other sites More sharing options...
0 WAE Posted April 23, 2014 Report Share Posted April 23, 2014 Or you could use the script made by maca and have it so you can right click on your toolbox to prevent players from accidentally clicking on the option to construct a bike. It'd also look a lot neater and prevents your action menu from being constantly full of things to execute scripts. That's just if you're an OCD fucker like me :P Link to comment Share on other sites More sharing options...
0 DangerRuss Posted May 5, 2014 Report Share Posted May 5, 2014 Only problem with that WAE is people not knowing it's there lol. I have a nice script for the scroll wheel that also lets you move to cancel the build if anyone is interested Link to comment Share on other sites More sharing options...
0 clemontine36 Posted June 10, 2014 Report Share Posted June 10, 2014 D Add this to fnselfactions: //deploy bike if (("PartGeneric" in _mags) && ("PartWheel" in _mags) && ("ItemToolbox" in _itemsPlayer)) then { hasBikeItem = true; } else { hasBikeItem = false;}; if((speed player <= 1) && hasBikeItem && _canDo) then { if (s_player_deploybike < 0) then { s_player_deploybike = player addaction[("<t color="#FFFF00"">" + ("Construct Bike") +"</t>"),"custom\make_bike.sqf","",5,false,true,"", "]; }; } else { player removeAction s_player_deploybike; s_player_deploybike = -1; }; Deploy bike script: if (dayz_combat == 1) then { cutText [format["You are in combat and cannot build a bike."], "PLAIN DOWN"]; } else { private ["_object"]; player removeAction s_player_deploybike; player playActionNow "Medic"; r_interrupt = false; player removeMagazine "PartGeneric"; player removeMagazine "PartWheel"; _dis=10; _sfx = "repair"; [player,_sfx,0,false,_dis] call dayz_zombieSpeak; [player,_dis,true,(getPosATL player)] spawn player_alertZombies; sleep 6; _object = createVehicle ["Old_bike_TK_INS_EP1", position player,[],0,"CAN_COLLIDE"]; _object setVariable ["ObjectID", "1", true]; _object setVariable ["ObjectUID", "1", true]; player reveal _object cutText [format["You've bodged together a bike!"], "PLAIN DOWN"]; r_interrupt = false; player switchMove ""; player playActionNow "stop"; sleep 10; cutText [format["Warning: Spawned Bikes do not save after server restart!"], "PLAIN DOWN"]; }; Do these bikes cleanup on restart? thanks Link to comment Share on other sites More sharing options...
Question
AOD_Assassin
I have looked all over google and I cannot find a deployable bike script that works anywhere. If anyone has found one could you please share it?
Link to comment
Share on other sites
5 answers to this question
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now