[Release] esx_doorlock

well yeah I got that bit lol, it still says I don’t have permission. lol

any possible way that the door only can be locked in the closed possition or if you lock it that it will lock when the door is closed?

Cool idea, I’ll look into it.

any ideas on how to get a key please?

1 Like

any updates on this?

did you make it with the code ?

how can i find out the prop name of a certain door? i want to lock the Vanilla Unicorn doors but can’t find out the objName

You identify the door here: https://wiki.■■■■■■■■■■■/index.php?title=Doors
And find the prop name here: https://github.com/Guad/MapEditor/blob/master/ObjectList.ini

3 Likes

Doesn’t seem to work right anymore with the server and esx newest versions. The text on the doors is blinking aand you need to press E when it is showing otherwise you cant get it to unlock. Been trying to fix it now for a hour but cant seem to get it right:/ Gonna keep trying but just wanted you too know whats up.

Pretty sure it has to do with the “GetDistanceBetweenCoords” function due to it blinking, but im not sure.

it works fine for me. you dont have something installed right

yeah just tought about that, because its just the text that is inside the station not the once outside,

If the text is blinking then it’s probably because your computer has a longer time til next frame than mine has. Change out the sleep time at https://github.com/ESX-PUBLIC/esx_doorlock/blob/master/client/main.lua#L44 to 0 ms

The function ApplyDoorState() eats performance as it has to find the door everytime its looped, I’m thinking of saving all the objects once and using the saved objects. Then I can lower the wait time to 0 without performance being lost.

1 Like

Thank you, Tack. It worked, also thanks for the quick answer! Cheers from Sweden.

How can i add lester buildings door? i want to use lesters building for my rp server but need to lock doors

No work with double prison door. Any idea ?

Vidéo: https://vimeo.com/312237512

{
objName = ‘prop_gate_prison_01’,
objCoords = {x = 1833.79, y = 2692.36, z = 44.611},
textCoords = {x = 1833.79, y = 2692.36, z = 48.00},
authorizedJobs = { ‘police’ },
locked = true,
distance = 12,
size = 2
},

{
objName = ‘prop_gate_prison_01’,
objCoords = {x = 1830.86, y = 2699.43, z = 44.611},
textCoords = {x = 1830.86, y = 2699.43, z = 48.00},
authorizedJobs = { ‘police’ },
locked = true,
distance = 12,
size = 2
},

Either wrong gate name or object coords

		{
		objName = 'prop_com_ls_door_01',
		objCoords  = {x = 29.76, y = 1087.17, z = 25.46},
		textCoords = {x = 29.76, y = 1087.17, z = 25.46},
		authorizedJobs = { 'police' },
		locked = true,
		distance = 12,
		size = 2
	},

Not work :frowning:

How to lock this door?

Anyone know the ID for this door from the After Hours update?

Been through so many doors but can’t find it. All I see is v_ilev_ch_glassdoor which isn’t the same.