Archived copy of warcraft-source.com, the Warcraft: Source (WCS) forum (2007–2011), rebuilt from the Internet Archive by wc3mods.net. This page was captured on 2010-04-12 (original capture). Home · Forum · All archived topics · Downloads

Author Topic: Small Admin.txt Improvemnt  (Read 146 times)

Offline max42

  • Level 1 Trained Beginner
  • *
  • Posts: 20
Small Admin.txt Improvemnt
« on: March 07, 2008, 12:12:07 PM »
hi guys

(sorry seemed the best place to post this)

dont know about you but it annoys me that when i do a wcs reload it always changes the map to de_dust

well with this quick change to the admin.txt file you can set it so the map will change to the curent map you on

find this line
Code: [Select]
if (server_var(wcs_game) = server_var(wcs_game_css)) then es_xdelayed 15 changelevel de_dust2



and replace it all with this line
Code: [Select]
if (server_var(wcs_game) = server_var(wcs_game_css)) then es_delayed 15 changelevel server_var(eventscripts_currentmap)

now when you do a wcs reload the map will change to the current map your on

enjoy :D

Offline Mouth662

  • Level 3 Trained Apprentice
  • ***
  • Posts: 66
  • Your going to feel a little prick!
    • Asg Clan Homepage/Forums
Re: Small Admin.txt Improvemnt
« Reply #1 on: March 07, 2008, 07:17:12 PM »
this is not the right place to post, this is the python version discussion of wcs. also changelevel just changes to the next map in the mapcycle, changelevel2 changes to the specified map.

Offline max42

  • Level 1 Trained Beginner
  • *
  • Posts: 20
Re: Small Admin.txt Improvemnt
« Reply #2 on: March 08, 2008, 02:49:45 AM »
yer as i said i did not know where to post this please feel free to move it to correct section

also read the code before making statements

the admin.txt already has the cmd changelevel and because the map dust 2 is named it will always change it to that map on admin reload

my cmd replaces the de_dust2 with server_var(eventscripts_currentmap) this tells the server to reload the CURRENT map it's on so what ever map is currently loaded it will just reload that

much better than going to dust 2 all the time



i did not make this post thinkning it may work
i added this post to this forum becasue i know it works and also have this on my server and thought it be helpful to others

Offline Mouth662

  • Level 3 Trained Apprentice
  • ***
  • Posts: 66
  • Your going to feel a little prick!
    • Asg Clan Homepage/Forums
Re: Small Admin.txt Improvemnt
« Reply #3 on: March 08, 2008, 05:43:56 AM »
yer as i said i did not know where to post this please feel free to move it to correct section

also read the code before making statements

the admin.txt already has the cmd changelevel and because the map dust 2 is named it will always change it to that map on admin reload

my cmd replaces the de_dust2 with server_var(eventscripts_currentmap) this tells the server to reload the CURRENT map it's on so what ever map is currently loaded it will just reload that

much better than going to dust 2 all the time



i did not make this post thinkning it may work
i added this post to this forum becasue i know it works and also have this on my server and thought it be helpful to others


im not saying what you wrote wouldnt work necessarily im saying that in myexperience with writing scripts for my server using changelevel despite whatever map is behind it doesnt change to the specified map, changelevel2 server_var(es_currentmap) does change to that map.  if yours works then fine but on the two of my servers ive tried changelevel mapname it didnt change tothat map, changelevel2 did. but ill digress since this isnt python discussion

Offline freddukes

  • Level 7 Expert
  • *****
  • Posts: 292
Re: Small Admin.txt Improvemnt
« Reply #4 on: March 08, 2008, 09:25:32 AM »
DONT USE CHANGELEVEL2... Sorry, but it's just a BIG bug with Valve... Chaangelevel2 makes all windows servers crash... It'll only work on linux. Sorry for the caps :P

-freddukes