hello to all, I share with you a simple script that allows the prisoner (and visitor)
who is in the prison area, not to die in prison with the status of invincibility player and Health player
(do not starve or thirst…) by creating a loop.
test in video Healt player and Invincibility player with Goku (dragonballz)
thanks to @Xeon70782 for the soluce of the health of the player with esx and vrp
(if I have understand correctly, should also work for vrp)
1.the idea came to me with these scripts: (no dependence with these scripts)
- [Release-ESX Jail] Prisonwork, Anti Combat Log, Mugshot Photo
- [ESX-Release] esx_doorlock_mhacking
- [Release] PrisonFive | Prison Interior
if you use prisonfive maps, do not forget to disable line 706 in map.lua, otherwise door lock at the police station.
-- {hash = -1992828732, pos = vector3(434.69, -984.81, 29.6895943), cellblockDoor = false, dynamic = false, rot = vector3(1.00178859E-05, 5.00895567E-06, 89.9997253)},
if you do not want to be bothered by the prisoners PNJ.
I recommend this script: All the pnj ignores the players inside and outside the jail…
Everyone IgnoreYou
- 1 the little players clever in my server have understood that by killing himself, he respawn directly to the hospital hence the importance of this script.
- 2.I wanted an open environment of jail hence the importance of this script.
- 3.I wanted to give the prisoner a chance to escape with [ESX-Release] esx_doorlock_mhacking without making a respawn zone or limit zone, hence the importance of this script
the ray and cordinnate was a test , maybe change the coordinates to be well in the middle of the prison and to put the radius smaller so that it goes up to the first double door ,but must cover the entire prison too…for rp and escape, it would be better…
local zones = {
{ ['x'] = 1641.78, ['y'] = 2641.07, ['z'] = 32.65} --here cordinate
} ....
if dist <= 250.0 then -- here the ray
if not jailOut then
SetPlayerInvincible(GetPlayerIndex(),true)
link here:
NoDeadInJailv2
I am a beginner only two weeks ago that i began to make a server and knowledge of scripts. so tell me if you have a problem.
I’m inspired by this script, I do not want any credit,All Credit here.