Change Log:
Latest Version:
Added cooldown time in Config.CoolDownTime. Default is set to 30 sec, set to 0 to turn off cooldown.
Added Config.MustUseVoice in config as well. This will make it so the player has to use ingame voice to activate the mugging.
( I want to add a timeout in this so if you do not hit E or Use voice to start the mugging after a certain time the ped will run away but need find the best solution to get this coded in. Hopefully next update will have this added)
Previous Fix:
Added check to see if ped is fleeing - no more stopping NPC from full sprint.
Removed the abality to mug NPC from inside vehicle.
Changed the check for target running away - check for target distance. ( no more mugging and running away from NPC and still getting cash)
Added support for BlackMoney in Config. Just set Config.DirtyMoney = true and will payout only BlackMoney.
Fixed error that was showing up on server script for expected then near =
Removed the function to mug animals (funny but unintentional)
Added check for player so you can not mug other players on the server.
Added Police Requirement in Config
Added progressBar support in Config if set to false you do not have to have progressBar installed.
Moved Giveable items to the Config for easier adjusting for server owners.
Fixed ESX.jobname not noticing new job until restart - thanks to XxFri3ndlyxX
Removed Mugging MissionEntityPeds so servers with doctors or clerks stationed around town dont need to worry about them.
Features:
This script will allow anyone other then police to mug locals on a server. This was based off https://github.com/D3uxx/esx_robnpc with a few improvements.
Download:
ESX_Mugging:
Features
- Can Mug any local you are with-in 5.0m
- Will receive random amount from Config.MinMoney to Config.MaxMoney - default is 5 - 100
- Can set Police Notify Percentage - default is set to 40%
- Can set Always Notify on death - This will always notify Police of Murder if NPC is killed during mugging. Once they start running the script will not notify if you kill them.
- Must have Weapon that is not from melee/explosive catagory to start a mugging.
- If you aim at a vehicle that is moving at all (even being pushed) the NPC will ignore the mugging script and act as the game dictates.
- If you aim at a driver of a stopped vehicle the driver will exit the vehicle and put hands up you can then start the mugging.
- Player can stop same NPC but if that npc is last one mugged will not be able to mug again.
- Police Notification gives Alert as well as Circle that will slowly vanish over time (default is 250 seconds - not in Config.lua with this version)
Known Issues:
- GCPhone support not 100% - has worked on 1 server but another server does not get sms alerts.
Planned Features:
-
I am looking into randomly having the NPC stop and turn to player and take picture. And the Alert would then have mugshot of criminal added instead of the 911 Alert picture.
-
I am looking into having to use voice to get the NPC to react at all. If you point a gun at driver of a car but do not say anything in game they will just drive away after a second or two. If you point at a driver and in game tell them to get out of the vehicle they will step out and raise hands.
Original release had 1 bad line of code that was causing continues cpu usage which has been addressed and is not in this release.
Any questions or comments feel free to send me a msg here and ill respond as soon as i can.
SpikE