I'am looking for the map change then the script will be change! someone help me :x
Forum
![>](img/i_next.png)
![>](img/icons/cs2d.png)
![>](img/i_next.png)
![>](img/i_next.png)
Change Map then Change Script
5 replies![To the start](img/i_first.png)
![Previous](img/i_prev.png)
![Next](img/i_next.png)
![To the start](img/i_last.png)
I'am looking for the map change then the script will be change! someone help me :x
MOBSTAZ has written
Hello! everyone
I'am looking for the map change then the script will be change! someone help me :x
I'am looking for the map change then the script will be change! someone help me :x
So,you mean if you change a map the script should also change right? :x
Well,i think this too needs a script xD!
1
2
2
de_dust.map de_dust.lua
Method B :
1
2
3
4
5
6
7
2
3
4
5
6
7
AnyNameYouLikeOrWhatever.lua ----- if map("name")=="de_dust" then 	msg("You're playing on de_dust") elseif map("name")=="cs_office" then 	msg("You're playing on cs_office") end
![user](img/i_friend.png)
Here's a small example
1
2
3
4
5
2
3
4
5
if ((string.len(map("name") > 2) and (string.substr(map("name"), 2) == "gg")) then 	dofile("Gungame.lua"); --whenver the map prefix is gg a gungame script will be executed. else 	dofile("Default.lua"); end
![](img/smiles/bigsmile.gif)
![To the start](img/i_first.png)
![Previous](img/i_prev.png)
![Next](img/i_next.png)
![To the start](img/i_last.png)