Jump to content

Server shutdown event


Recommended Posts

Hey guys

first of all i'm not sure if this is the right area so pls dont be mean ;)

I am about to make an Roleplay script and got a little problem. I have to say that i am a bit new to nodejs i am new in ragemp and just got experience with C# (GTMP) and Pawn(Samp).

When i create my Vehicle handling (load save and stuff) i does it in that way 

- Loading all Vehicles from Database on Server start

- Save a vehicle on special tasks like create, take dmg, player exit

- save all Vehicles on server stop (to avoid any save troubles)


i didnt find any serverStop event in ragemp wiki. normaly it didnt need to save any vehicle on server stop because i save it everytime a player leave the Vehicle. BUT i want to add smth like an Mechanicle team and the PD should have a option to tow a wrong parked vehicle when it is looked 


can you say me an way to call functions on serverstop 



an other way is to create a timer every 10 sek. and check if the vehicle moved and when save it. but i think if there are maybe 50 players and everyone driving they are 50 querys every 10 second sounds like performance troubles

Edited by notorious_nils
some stupid grammar stuff
Link to comment
Share on other sites

  • 2 weeks later...

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
  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Create New...