This site is a testing version, but all data is shared with the live forum.


Raised This Month: $ Target: $400
 0% 

AdminCustomMenu edit


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Tanis
Junior Member
Join Date: Jun 2011
Old 06-17-2011 , 08:18   AdminCustomMenu edit
Reply With Quote #1

Hi guys,

I'm setting up a dedicated lan-server with custom mutations.

I've created a AdminCustomMenu, where I can manage all my mutations and campaigns/maps, but I have some problems when the server changes map.

I'm using the command
Code:
sm_cvar map #2 #1
Where #2 is map and #1 is mutation. The mapchange and mutation works fine, but all clients are disconnected and have to reconnect manually.

I tried another solution where i used the
Code:
sm_map cvar
, but that doesn't seem to register the mutation
Code:
sm_map #2 #1
and only changes the map fine without any disconnects.

So I was wondering if it would be possible to run two commands after eachother in the the AdminCustomMenu > e.g.
Code:
sm_cvar mp_gamemode #1; sm_map #2;
but so far I havn't been able to do so (this one only changes gamemode)...


Hope anyone can help me here, I'd love not being disconnected running these commands.

Best regards
Tanis
Tanis is offline
Powerlord
AlliedModders Donor
Join Date: Jun 2008
Location: Seduce Me!
Old 06-17-2011 , 10:47   Re: AdminCustomMenu edit
Reply With Quote #2

Don't ever use the map command, as it disconnects all players (as you've found out).

Instead, use the changelevel command.
__________________
Not currently working on SourceMod plugin development.
Powerlord is offline
Tanis
Junior Member
Join Date: Jun 2011
Old 06-17-2011 , 11:02   Re: AdminCustomMenu edit
Reply With Quote #3

Don't think I mentioned it, but it's a Left4Dead2 server.

Can the changelevel command use mutations for L4D2?
Tanis is offline
micazoid
Veteran Member
Join Date: Oct 2010
Location: Munich - Germany
Old 06-17-2011 , 11:36   Re: AdminCustomMenu edit
Reply With Quote #4

why not using sm_map instead? As powerlord daid, map is kicking all clients. I do not really know what mutation is, so I dunno if sm_map is also working. Just check with your console

Nevermind the sm_map thingi. Next I read the post completly..... promise
__________________
micazoid is offline
Powerlord
AlliedModders Donor
Join Date: Jun 2008
Location: Seduce Me!
Old 06-17-2011 , 11:36   Re: AdminCustomMenu edit
Reply With Quote #5

Quote:
Originally Posted by Tanis View Post
Don't think I mentioned it, but it's a Left4Dead2 server.

Can the changelevel command use mutations for L4D2?
I'm not sure, I don't actually run L4D2 servers.
__________________
Not currently working on SourceMod plugin development.
Powerlord is offline
Tanis
Junior Member
Join Date: Jun 2011
Old 06-18-2011 , 04:27   Re: AdminCustomMenu edit
Reply With Quote #6

Would it be possible to run two commands within one menu?
Tanis is offline
Tylerst
Veteran Member
Join Date: Oct 2010
Old 06-18-2011 , 09:40   Re: AdminCustomMenu edit
Reply With Quote #7

Can you post that section of your custom admin menu? It doesn't have to be the whole file, just the section involving the map change.

Would be easier to help if we can see exactly what you have.


And yes, you can have 2 commands(or more) in one section.

Random example:

Code:
"cmd"  "sv_cheats 1; director_stop; z_spawn #1; z_common_limit #2; director_start"
"admin     "sm_kick"
"execute"     "server"
"1"
{
     "type"     "list"
     "title"     "Infected"
     "1"      "hunter"
     "1."     "Hunter"
     "2"      "boomer"
     "2."     "Boomer"
     "3"      "tank"
     "3."     "Tank"
     "3*"    "sm_ban"
     //Etc
}
"2"
{
     "type"     "list"
     "title"     "Common Limit"
     "1"     "30"
     "2"     "50"
     "3"     "250"
     //Etc
}

Last edited by Tylerst; 06-18-2011 at 09:54.
Tylerst is offline
Tanis
Junior Member
Join Date: Jun 2011
Old 06-18-2011 , 09:55   Re: AdminCustomMenu edit
Reply With Quote #8

Here is a small section of the map/mutation selection:
Code:
		"Uncommon CoOp"
		{
			"cmd"	"sm_cvar mp_gamemode #1; sm_map #2"
			"1"
			{
				"type"		"list"
				"title"		"Choose Mutation"
				"1"		"biohazard"
				"1."	"Biohazard"
				"2"		"coulrophobia"
				"2."	"Coulrophobia"
				"3"		"deconstruction"
				"3."	"Deconstruction"
				"4"		"dirtnap"
				"4."	"Dirt Nap"
				"5"		"jimpocalypse"
				"5."	"Jimpocalypse"
				"6"		"riotcontrol"
				"6."	"Riot Control"
				"7"		"uncommonground"
				"7."	"Uncommon Ground"
			}
			"2"
			{
				"type"		"list"
				"title"		"Choose Campaign"
				"1"		"c1m1_hotel"
				"1."	"Dead Center"
				"2"		"c2m1_highway"
				"2."	"Dark Carnival"
				"3"		"c3m1_plankcountry"
				"3."	"Swamp Fever"
				"4"		"c4m1_milltown_a"
				"4."	"Hard Rain"
				"5"		"c5m1_waterfront"
				"5."	"The Parish"
				"6"		"c6m1_riverbank"
				"6."	"The Passing"
				"7"		"c7m1_docks"
				"7."	"The Sacrifice"
				"8"		"c8m1_apartment"
				"8."	"No Mercy"
				"9"		"c13m1_alpinecreek"
				"9."	"Cold Stream"
			}
		}
It's not very smooth, and I guess it could be made in a different way.


Is it possible to have more sub-menus? Or is it only 2 layered.
Tanis is offline
Tylerst
Veteran Member
Join Date: Oct 2010
Old 06-18-2011 , 11:08   Re: AdminCustomMenu edit
Reply With Quote #9

Hmm, I don't run my own L4D2 server so I can't test it, but your formatting is correct and the map names are correct, so I'm guessing it's a problem with mp_gamemode.

I thought that mp_gamemode was just for choosing the overall game mode IE coop/realism/etc, rather than specific mutations.


Could be wrong though, I don't have much experience with the mutations.

You might wanna try changelevel with map/mutation as stated above though if map worked for you

Last edited by Tylerst; 06-18-2011 at 11:11.
Tylerst is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 20:18.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode