BetterDeadThanZed

Unlock or teleport vehicles at traders

3 posts in this topic

I don't have safe zones at the traders on my server. Instead I have no-build zones. I don't want safe zones. I know if you use safe zones, there's a setting that lets you unlock vehicles left within a trader on restart. I am looking for a script to either unlock vehicles within X meters of my traders (maybe via a list of trader coordinates), or a script that will teleport vehicles left at the trader to a central location (A "repo" lot?).

Share this post


Link to post
Share on other sites

It looks like you have already overridden the ExileServer_object_vehicle_database_load.sqf file so the easiest thing might be to make further changes to it.

Try changing:

Spoiler

if (_isLocked) then 
{
	if (_unlockInSafeZonesAfterRestart) then 
	{
		if (_position call ExileClient_util_world_isInTraderZone) then 
		{
			_isLocked = false;
		};
	};
};

 

to this:

Spoiler

if (_isLocked) then 
{
	_unlockPositions = [
		[[12345,12345],100],
		[[23456,23456],200]
	];
	{
		if (((_x select 0) distance2D _position) < (_x select 1)) then
		{
			_isLocked = false;
		};
	} forEach _unlockPositions;
};

 

and change the unlock positions to what you need.

*untested*

Share this post


Link to post
Share on other sites
2 hours ago, deadeye2 said:

It looks like you have already overridden the ExileServer_object_vehicle_database_load.sqf file so the easiest thing might be to make further changes to it.

That worked. Thank you! 

Share this post


Link to post
Share on other sites
Advertisement

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 account

Sign in

Already have an account? Sign in here.


Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.