Jump to content

[Release] Vehicle Service Point (Refuel, Repair, Rearm) [Script]


Axe Cop

Recommended Posts

I think you could never access the gear from the driver seat? only over the map but that has been removed with one of the later epoch patches..

 

You could always access gear in a vehicle via the map by going to units and then gear, regardless of seat, as you said.  However, now with the map removal, you are able to use the "G" button (or whatever you have gear set to) from any position to access gear (I've tested this on other 1.0.3.1 servers without this mod...).  However, on my private server with this mod enabled, you are unable to access gear with the "G" key while in the driver's seat or weapon seat, both of which are utilized by the mod.  Any idea how to get around this? I believe the default menu is overridden by the mod menu, thus not allowing access to gear...

Link to comment
Share on other sites

You should use a code editor like Notepad++ or something it will highlight at least the matching brackets and stuff so you'll see if you open 5 brackets you also close 5 and see where the matching bracket is! :)

and what text disappears? the code view on the forums isn't the best, might be a bug ^^

 

in case you are wondering when I edit code it looks like this with many colors haha (also different colors for build in ArmA commands and stuff so developers can see errors faster):

 

 

I do use Notepad++ but that doesn't mean I'm going to notice the brackets. I'm not a coder, afterall. I just take what others do and add it to my server. :( 

Link to comment
Share on other sites

You could always access gear in a vehicle via the map by going to units and then gear, regardless of seat, as you said.  However, now with the map removal, you are able to use the "G" button (or whatever you have gear set to) from any position to access gear (I've tested this on other 1.0.3.1 servers without this mod...).  However, on my private server with this mod enabled, you are unable to access gear with the "G" key while in the driver's seat or weapon seat, both of which are utilized by the mod.  Any idea how to get around this? I believe the default menu is overridden by the mod menu, thus not allowing access to gear...

I can test this later but my script is not overriding any keys or menus, it may be some other issue maybe you are using some anti hacks those often use custom key bindings?

 

Edit: just tested and its working great with the G key in the driver seat.. so I am pretty sure it is not the script and that would be very weird anyway :D

Edited by Axe Cop
Link to comment
Share on other sites

  • 2 weeks later...

Great script. when i add this on Tav. the fog  script i put in to remove fog stops working. any clue why?

thanks andI have no clue what my script has to do with your fog :D

maybe some weird script error so default answer: did you check both log files (client and server log, I guess both scripts run on the client and most admins don't even know there is a log file on the client where you play the game) for script errors? if there are no errors I would put some debug messages in the files if your game even starts the fog script maybe

Link to comment
Share on other sites

thanks andI have no clue what my script has to do with your fog :D

maybe some weird script error so default answer: did you check both log files (client and server log, I guess both scripts run on the client and most admins don't even know there is a log file on the client where you play the game) for script errors? if there are no errors I would put some debug messages in the files if your game even starts the fog script maybe

I looked and no errors. everything loads up Great. with no errors. just the stupid fog is back. On Taviana. the Fog is op :).  thanks for the Fast reply. i will look further in to it

Link to comment
Share on other sites

I looked and no errors. everything loads up Great. with no errors. just the stupid fog is back. On Taviana. the Fog is op :).  thanks for the Fast reply. i will look further in to it

Well I can tell you my script doesn't add the fog back in, that is for sure :p

Link to comment
Share on other sites

Nope. i love this Script. i will add it on both server's. i figured it out. funny how  and extra [ makes things work funny. Thanks for  the Script and  helpful!

good and well programming is like math, change one thing and the result may be completely different :p

Link to comment
Share on other sites

Hi Axe cop;

 

I wanting to add your script to replace auto refuel/repair center script but i cannot get it to match.

 

I use epoch 1.0.3, not 1.0.3.1

 

It maybe the problem?

 

Anyway i was able to run it ( but not correctly) without added the ac_function.sqf

Then i receved the error ( ac_function.sqf not found) and everything was free to repair, refuel and rearm.

 

Can you help me to get it working for epoch 1.0.3?

 

This script look like very awesome :p

 

Link to comment
Share on other sites

Ho well, it dont work for me on the server anyway.

 

I tryed from many different maneer and nothing match.

 

sorry missclick:

 

this is my ini.sqf and all files are moved like you said in the service_point folder:

 

/*	
	For DayZ Epoch
	Addons Credits: Jetski Yanahui by Kol9yN, Zakat, Gerasimow9, YuraPetrov, zGuba, A.Karagod, IceBreakr, Sahbazz
*/
startLoadingScreen ["","RscDisplayLoadCustom"];
cutText ["","BLACK OUT"];
enableSaving [false, false];
// CPC Nametags
[] execVM "cpcnametags.sqf";

[] ExecVM "custom_monitor.sqf";

[] execVM "faction.sqf";

//[] ExecVM "Scripts\repairactions.sqf";

[] execVM "debug\addmarkers.sqf";

[] execVM "debug\addmarkers75.sqf";

//REALLY IMPORTANT VALUES
dayZ_instance =	11;					//The instance
dayzHiveRequest = [];
initialized = false;
dayz_previousID = 0;

//disable greeting menu 
player setVariable ["BIS_noCoreConversations", true];
//disable radio messages to be heard and shown in the left lower corner of the screen
enableRadio true;
// May prevent "how are you civillian?" messages from NPC
enableSentences false;

// DayZ Epoch config
spawnShoremode = 1; // Default = 1 (on shore)
spawnArea= 1500; // Default = 1500
MaxHeliCrashes= 25; // Default = 5
MaxVehicleLimit = 700; // Default = 50
MaxDynamicDebris = 800; // Default = 100
dayz_MapArea = 14000; // Default = 10000
dayz_maxLocalZombies = 30; // Default = 30 
DZE_teleport = [99999,99999,99999,99999,99999];
DZE_DeathMsgGlobal = true;
DZE_DeathMsgSide = true;
DZE_DeathMsgTitleText = true;

dayz_paraSpawn = false;

dayz_minpos = 0; 
dayz_maxpos = 16000;

dayz_sellDistance_vehicle = 40;
dayz_sellDistance_boat = 40;
dayz_sellDistance_air = 40;

dayz_maxAnimals = 8; // Default: 8
dayz_tameDogs = true;
DynamicVehicleDamageLow = 0; // Default: 0
DynamicVehicleDamageHigh = 100; // Default: 100

EpochEvents = [["any","any","any","any",30,"crash_spawner"],["any","any","any","any",0,"crash_spawner"],["any","any","any","any",15,"supply_drop"]];
dayz_fullMoonNights = true;

//Load in compiled functions
call compile preprocessFileLineNumbers "\z\addons\dayz_code\init\variables.sqf";				//Initilize the Variables (IMPORTANT: Must happen very early)
progressLoadingScreen 0.1;
call compile preprocessFileLineNumbers "\z\addons\dayz_code\init\publicEH.sqf";				//Initilize the publicVariable event handlers
progressLoadingScreen 0.2;
call compile preprocessFileLineNumbers "\z\addons\dayz_code\medical\setup_functions_med.sqf";	//Functions used by CLIENT for medical
progressLoadingScreen 0.4;
call compile preprocessFileLineNumbers "\z\addons\dayz_code\init\compiles.sqf";				//Compile regular functions
progressLoadingScreen 0.5;
call compile preprocessFileLineNumbers "server_traders.sqf";				//Compile trader configs
call compile preprocessFileLineNumbers "Scripts\compiles.sqf"; //Compile custom compiles
progressLoadingScreen 1.0;

"filmic" setToneMappingParams [0.153, 0.357, 0.231, 0.1573, 0.011, 3.750, 6, 4]; setToneMapping "Filmic";

if (isServer) then {
	call compile preprocessFileLineNumbers "\z\addons\dayz_server\missions\DayZ_Epoch_11.Chernarus\dynamic_vehicle.sqf";
	//Compile vehicle configs
	
	// Add trader citys
	_nil = [] execVM "\z\addons\dayz_server\missions\DayZ_Epoch_11.Chernarus\mission.sqf";
	_serverMonitor = 	[] execVM "\z\addons\dayz_code\system\server_monitor.sqf";
};

if (!isDedicated) then {
[] execVM "compile\Server_WelcomeCredits.sqf";
	//Conduct map operations
	0 fadeSound 0;
	waitUntil {!isNil "dayz_loadScreenMsg"};
	dayz_loadScreenMsg = (localize "STR_AUTHENTICATING");
	
	[] execVM "service_point\service_point.sqf";
	
	//Run the player monitor
	_id = player addEventHandler ["Respawn", {_id = [] spawn player_death;}];
	_playerMonitor = 	[] execVM "\z\addons\dayz_code\system\player_monitor.sqf";
[] execVM "admintools\Activate.sqf";
[] execVM "safezone.sqf";	
	
	// Anti Hack 
	//if (true) then {
	//	[] execVM "\z\addons\dayz_code\system\antihack.sqf";
	//};
	
	//Lights
	if (true) then {
		[0,0,true,true,true,58,280,600,[0.698, 0.556, 0.419],"Generator_DZ",0.1] execVM "\z\addons\dayz_code\compile\local_lights_init.sqf";
	};
};

if(true) then {
	#include "\z\addons\dayz_code\system\REsec.sqf"
};

//Start Dynamic Weather
if(true) then {
	execVM "Weather\DynamicWeatherEffects.sqf";
};

//#include "\z\addons\dayz_code\system\BIS_Effects\init.sqf";

p2_newspawn = compile preprocessFileLineNumbers "newspawn\newspawn_execute.sqf";
waitUntil {!isNil ("PVDZE_plr_LoginRecord")};
if (dayzPlayerLogin2 select 2) then
{
    player spawn p2_newspawn;
};
Link to comment
Share on other sites

Nope i dont get any error in rtp.

 

I tryed many different classname, nothing work. i use actually ( USMC_WarfareBVehicleServicePoint )

 

I m desesperated :(

Ok so you have changed the script!? what is with my default version does that work?

I know many people add something wrong then nothing works and I cant help you without debugging it and thats a lot of work.. you need to show me your changes or search for the error yourself :D

Link to comment
Share on other sites

You should use a code editor like Notepad++ or something it will highlight at least the matching brackets and stuff so you'll see if you open 5 brackets you also close 5 and see where the matching bracket is! :)

and what text disappears? the code view on the forums isn't the best, might be a bug ^^

 

in case you are wondering when I edit code it looks like this with many colors haha (also different colors for build in ArmA commands and stuff so developers can see errors faster):

qCsfBgu.png

 

Can you maybe tell me where i can get these plugins for notepad++?

what you have is way better :p

Link to comment
Share on other sites

Ok so you have changed the script!? what is with my default version does that work?

I know many people add something wrong then nothing works and I cant help you without debugging it and thats a lot of work.. you need to show me your changes or search for the error yourself :D

Well in fact all i changed was the classname of the object and the distance.

I used all your sqf without modifing it except the service_point ( classname and distance )

I will modify it once it will work ( if it work ) to only translate the message displayed as i run a 100 % french speaker server.

But so far i didnt change anything.

I will try some more test in some hours and will tell you what.

PS: the most strange things is the first time i tryed it, i used only 1 file, your service_point.sqf without all the 4 other file and i was able to run it ( but for all cost free . Once i added the other files, nothing was runing correctly.

Link to comment
Share on other sites

Well in fact all i changed was the classname of the object and the distance.

I used all your sqf without modifing it except the service_point ( classname and distance )

I will modify it once it will work ( if it work ) to only translate the message displayed as i run a 100 % french speaker server.

But so far i didnt change anything.

I will try some more test in some hours and will tell you what.

PS: the most strange things is the first time i tryed it, i used only 1 file, your service_point.sqf without all the 4 other file and i was able to run it ( but for all cost free . Once i added the other files, nothing was runing correctly.

Yeah because my ac_function.sqf handles the costs and remove the items from the player inventory.. I will remove that file with Epoch 1.0.4 because I've added those function to the main epoch mod for all other scripts to use. :)

But to be honest I don't know what you did wrong, the script works 100% as many admins managed to get it working. :/

 

 

@sperwer66

I use this plugin: http://killzonekid.com/arma-2-arma-3-hybrid-syntax-highlighter-for-notepad/

with my own colors theme here: https://gist.github.com/vos/7743082

Link to comment
Share on other sites

The problem was coming from the object i used, it seems itsnt compatible with your script (USMC_WarfareBVehicleServicePoint and US_WarfareBVehicleServicePoint dont work with it).

 

Thanks for your help and thx for your script it's really nice

They should work but there is another problem because those have their own refuel and repair option and you can't remove them i think? That might only confuse players or even you :D

Link to comment
Share on other sites

Well, they maybe v got their own refuel/repair option but it's disabled when u use it like that on epoch.

I ran the old repair/refuel script on it to get them actived ( but then without any repair saved after restart)

and it worked correctly.

As i told you, when i use only your service_point.sqf withot the repair/refuel/rearm/ac files it work with them.

Once i use the full files it's broken with those objects...

Anyways thank again

Link to comment
Share on other sites

I might look into that when I got some time, because what you are saying makes no sense actually, sorry :D

the other files besides service_point.sqf are only used when you activate one of the option (refuel, repair or rearm) and never before.. but well I don't know might be a weird bug..

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...