[Release] PD5M - Multiplayer PvE Police Script - Ambient Events

Hello everyone,

a video tutorial was added to the main post. Most questions regarding the controls should be cleared up with this. Have fun playing!

1 Like

This is Excellent!!! Thank you and Good Job.

Hello everyone,
PD5M v0.1.1 the config update has been released. This should be especially good for server owners as you can now edit a big amount of variables easily. Have fun!

v0.1.1

  • Config files were greatly expanded and now feature many variables to tweak the ped-generation of the resource.
  • Probabilities for peds possessing weapons, using drugs, drinking, and fleeing / fighting have been increased.
  • Fixed a bug where imprisoned peds were still stuck to a player for everyone else.
2 Likes

On servers with no cross hair enabled this gives a huge advantage to the police. Does the script still work if you discontinue F3 key?

Yes, the script will work fine without F3-key. Some things to note:

  • F3-key is not bound to rights at all, so anyone would be able to use it
  • If crosshair is disabled, F3 actually doesn’t work at all due to me using the SniperScope-native instead of printing a point
  • Without a crosshair targeting peds is really hard since you need them in the center of the screen to talk to them.
  • Since the newest version you can simple disable the crosshair by using the appropriate variable in the config_cl.lua

This release looks tremendous. I can’t wait to try it.

Thanks for all the hard work!

Thank for you a promt reply, Silverman.
I have suggestion though. Wouldn’t it be a good idea if you added permissions? Right now anyone can use it on the server.

Personally not going to use this script but would just like to thank you for the work and effort you put into this. Great post, video, layout (proper credits!!!) and features. Others should use this as an example!

5 Likes

I think I’m going to pass as well. It seems too much of a job to put permissions on it and in One-Sync the police will suffer lag from it while the rest of the server will race away from them. Good effort though, and on a pure police server it would work as intended, but for RP servers with criminals and so forth, not so much.

Well, it’s actually intended for a pure police server, so that’s fine :smiley:

As I currently can’t edit the main post, I also can only publish the patch notes down here. Actually created optional ESX-support for a first version of permissions. Permissions without ESX-support are planned for a later version.

Release v0.1.1.1 Patch Notes

  • ESX-integration thanks to MobTV.
  • Bugfix: Stealing cars is possible again.
  • Bugfix: Pullover is more reliable on intersections with traffic lights.
2 Likes

Hehe, ESX permissions are the easy part - as they’re integrated in ESX :slight_smile: But thanks for coming back to it with a VRP version, pretty please xD that’s the hard one. :smiley: And again thanks for the script Silverman. Its awesome to see PIS coming to FiveM :slight_smile: It runs a bit heavy though on One-Sync. about 40 ms. for me at least, I think police players would have some lag from it or FPS drops. Is there a way to make it more optimized? I love you use radial menu though and the lockups aren’t as often when you don’t have to click on the icons but just release them :slight_smile:

1 Like

I love this, and love the fact you are still working on this, the new esx intergration is awesome, I tried it a few days ago and love every bit of it, I had to take it off the server, If you made it only work with esx_policejob it would be perfect for me, Heck I would make you a beer or something for all your hard work! Thanks again for all the love you put into this I can see it, it shows fo sho! have a great night. cough cough esx_policejob

3 Likes

Huh? Its easy to implement vrp permissions into resources.

Not this one Tron. It’s pretty heavy, but if you want to fork it - be my guest :slight_smile:

I haven’t looked at the code yet, but it shouldn’t be difficult. I’ll have a look at it soon.

1 Like

Thanks for the feedback. Anything I can do to make this script more lightweight? E.g. any Threads which could be run serverside / can be unified / bigger wait-times / can be changed into events?

I suppose I could get a huge plus by getting every check for the markers (garage, armory, …) into one thread (and simplify it heavily).
Please note that this is my first ever lua- and FiveM-project . If more experienced coders want to give input / feedback / tips that would be much appreciated. Same for the OneSync-issues. I don’t use OneSync so have no idea what could lead to increased performance-issues there.

As for the ESX / vrp-support: I’ll probably never do it myself but you are welcome to do it and send a pull-request (or directly contact me so we can work together on that, might be a lot easier). You’d definitely get mentioned in the credits in the first post.

EDIT: Any easy check I can do to see how fast the script is running? I do not have any resource-warning, so at least that is fine :smiley:

EDIT2: Holy, I just saw that I am running the distance-checks for every single marker on a Wait(0). Expect a fix (together with a completely rewritten config) in the next hours.

1 Like

Mostly - at least on servers with LSCS and VRP garages - the police cars are already in their own garages. So adding them in a warmenu is extra, neat - but extra. And again everyone can find those control points if some sort of permissions aren’t added to it all. Same goes with radial menu. If everyone can open it, everyone can arrest and search and so on. So a config where permissions for everything added would be a step in the right direction. About optimizing. In short, only call for the events when players are close to what they need to do. Having the server constantly make calls to every car - flower or what not on the server kills fps and produces lag, but this will produce lag for the police players only, and on RP servers in high speed that would cause a problem.

you might be the best dev i have ever seen on this forum, keep up the good work. Question: if there is a fork or something that some how gets this to work only for police ei: esx_policejob would you update this post with the news. Im still new to the in’s and out’s of github and im afraid I would miss it. thanks again! we love you!

Awesome. :slight_smile:

Ehm… thank you very much!
Yes, every update will include their own patch-notes so it would be pretty hard to miss if you bookmarked this thread.