Resume Server at last map

his script should be installed: ctrike/addons/eventscripts/crashreset/es_crashreset.txt

block load
{
  es_keygroupdelete servercrash 
  es_keygroupload servercrash |crashreset
  es_xsetinfo sc_exists 0
  es_exists sc_exists key servercrash server
  if (server_var(sc_exists) equalto 0) do
  {
    es_keycreate servercrash server
  }
  es_xsetinfo sc_load 1
}

block unload
{
  es_keygroupdelete servercrash
}

event es_map_start
{
  if (server_var(sc_load) equalto 1) do
  {
    es_xsetinfo sc_load 0
    es_xsetinfo crash_map 0
    es_keygetvalue crash_map servercrash server currentmap
    if (server_var(crash_map) notequalto server_var(eventscripts_currentmap)) do
    {
     es_delayed 10 changelevel server_var(crash_map)
    }
  }
  else do
  {
    es_delayed 10 es_keysetvalue servercrash server currentmap server_var(eventscripts_currentmap)
    es_delayed 10 es_keygroupsave servercrash |crashreset
  }
}

Oh noes! You're not a Member!

Want access to cool stuff? As a member you can:

  • Post. Give the submitter your thoughts on this Script.
  • Say Thanks. Show your appreciation by sending the submitter points.
  • Stamp Posts. Let other posters know what you think of their posts.
  • Rate. Give this Script a rating out of 10.
  • Flag. Alert moderators and warn members of a problem with this Script.
  • Vote. Vote the submitter for the Monthly Awards.
  • Subscribe. Get notified when this submitter submits again.

Interested? Register or Login

Comments

None found

Credits

Submitter
Woomaps's Levels
  • P2: Drudge
    Points: 1,330
  • C1: Member
  • A6: Elder
    Account Age: 6 years
Woomaps (Redistributor)
Key Authors
woomaps
Unknown

Rating

?/10
Not yet rated.

Stats

Post Count
0
ViewCount
888
Date Added
6 years ago
Date Modified
6 years ago

Share

Embed Code
Code to use:

More embeddable images

Bookmark and Share