Jump to content
  • 0

[REQUEST] Vehicle Locator Removes Key if Vehicle Doesn't Exist!


DangerRuss

Question

I've been using this mod on my server for awhile

I've been trying to add a feature similar to the infistar admin tool, which would remove the key from the players inventory if they vehicle they're searching for no longer exists. However, Im pretty stumped as to how to go about doing this. I've been looking at the infistar code and I can see how he does it, but Im not sure how to implement it into this existing script. Any help would be awesome. 

Link to comment
Share on other sites

2 answers to this question

Recommended Posts

  • 0

Replace this :

	} else { systemChat format ["%1 - Vehicle ID: %2 - (This vehicle no longer exists in the database)",_keyName,_finalID]; };	

with this: 

	} else {
		systemChat format ["%1 - Vehicle ID: %2 - (This vehicle no longer exists in the database)",_keyName,_finalID];
		_key_removed = [player,_key] call BIS_fnc_invRemove;	
	};	

Untested this but it should be all you need.

Link to comment
Share on other sites

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
  • Advertisement
  • Discord

×
×
  • Create New...