Jump to content

Resource Restarter


Mr.ArO

Recommended Posts

Posted

Hello

Is there a resource that restarts another resource ?? (ex. there are cars in the map when players play they move them, blow up and etc.. that resource restarts the car map from 30 minutes over and over again)

Posted

server.lua:

function autoRestart() 
restartResource(getResourceFromName("carsmap")) 
end 
setTimer(autoRestart,1800000,0) 

meta.xml:

<meta> 
    <script src="server.lua" type="server"/> 
</meta> 

you have to give the resource admin rights because restartResource requires them to work.

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...