Raised This Month: $51 Target: $400
 12% 

Maplister


Post New Thread Reply   
 
Thread Tools Display Modes
asaguda
Junior Member
Join Date: May 2007
Old 07-05-2012 , 19:39   Re: Maplister
Reply With Quote #51

Using TF2, this plugin puts all of the .txt files in the maps folder in the maplist file as well. It didn't when I last used this, about a year ago. Is there a quick fix for this?
asaguda is offline
theY4Kman
Join Date: Jun 2007
Location: Yak
Old 07-05-2012 , 21:52   Re: Maplister
Reply With Quote #52

Quote:
Originally Posted by asaguda View Post
Using TF2, this plugin puts all of the .txt files in the maps folder in the maplist file as well. It didn't when I last used this, about a year ago. Is there a quick fix for this?
Let me know if this works, and I'll update the thread. If it does work, the last release had a big bad error in it
Attached Files
File Type: sp Get Plugin or Get Source (maplister.sp - 295 views - 7.2 KB)
__________________
http://y4kstudios.com
Is that loud enough? Oh, while I have you, check out Viper.

Last edited by theY4Kman; 07-05-2012 at 21:53. Reason: Forgot .sp
theY4Kman is offline
Send a message via ICQ to theY4Kman Send a message via AIM to theY4Kman Send a message via MSN to theY4Kman Send a message via Yahoo to theY4Kman Send a message via Skype™ to theY4Kman
Powerlord
AlliedModders Donor
Join Date: Jun 2008
Location: Seduce Me!
Old 07-05-2012 , 22:32   Re: Maplister
Reply With Quote #53

Quote:
Originally Posted by asaguda View Post
Using TF2, this plugin puts all of the .txt files in the maps folder in the maplist file as well. It didn't when I last used this, about a year ago. Is there a quick fix for this?
I've never run into this... TF2 has a lot of txt files in its maps directory but none of them appeared in my maplist.
__________________
Not currently working on SourceMod plugin development.
Powerlord is offline
asaguda
Junior Member
Join Date: May 2007
Old 07-10-2012 , 20:05   Re: Maplister
Reply With Quote #54

Quote:
Originally Posted by Powerlord View Post
I've never run into this... TF2 has a lot of txt files in its maps directory but none of them appeared in my maplist.
When I say 'text files,' I mean it put the localization text files located in the maps folder along in with the rest of the map files. It would also put some of the maps in more than once.

Code:
pl_thundermountain_tchinese
pl_upward
pl_upward
pl_upward_danish
pl_upward_dutch
pl_upward_english
pl_upward_finnish
pl_upward_french
pl_upward_german
pl_upward_italian
pl_upward_japanese
pl_upward_korean
pl_upward_norwegian
pl_upward_polish
pl_upward_portuguese
pl_upward_russian
pl_upward_schinese
pl_upward_spanish
pl_upward_swedish
pl_upward_tchinese
plr_hightower
Like so.

Also, yes, the updated version works fine. No doubles or any localization text files. Thank you!
asaguda is offline
theY4Kman
Join Date: Jun 2007
Location: Yak
Old 07-10-2012 , 20:26   Re: Maplister
Reply With Quote #55

Quote:
Originally Posted by asaguda View Post
...
Also, yes, the updated version works fine. No doubles or any localization text files. Thank you!
Wonderful! I'll update the thread. I'm embarrassed at this screw-up But that's what happens when you release a hotfix without testing (hey, I'm doing it again!)
__________________
http://y4kstudios.com
Is that loud enough? Oh, while I have you, check out Viper.
theY4Kman is offline
Send a message via ICQ to theY4Kman Send a message via AIM to theY4Kman Send a message via MSN to theY4Kman Send a message via Yahoo to theY4Kman Send a message via Skype™ to theY4Kman
Malachi
Senior Member
Join Date: Jun 2010
Location: USA
Old 07-17-2013 , 16:57   Re: Maplister
Reply With Quote #56

After the SteamPipe update, this plugin was causing us some problems. So instead of complaining, I fixed it.

Not everyone will want to use this, but I'm putting it up here as an alternative for those that might appreciate it.

Changes:
Writes to file mapall.txt instead of maplist.txt. I guess ppl set things up differently depending on their needs, but this was to avoid a collision with an already-in-use file name. I guess using the sourcemod cfg settings might be an improvement for some, but I didn't bother with that (yet).

Also looks in download/maps/ for map file names, then adds them to the list. This is the big change you want.

Puts stock maps at the top of the list, then all custom maps sorted below them. This makes it nicer for our admins, who most of the time are looking for a stock map.



I've attached the source here for v1.6.6 (theY4Kman pls take note), as well as a compiled version. You're welcome to look at the source changes on GitHub as well: Github: Maplister



NOTE: The plugin expects your maps to be in the proper locations - stock maps in maps/ and custom maps in download/maps/. If you don't do this, it will still work. However, stock maps won't be sorted seperately.

I also haven't tested this on L4D. I haven't changed the code directly handling L4D, so I'm thinking it will still work.

I had some weird issues with the exceptions file. I haven't had time to look at it, but it seemed like any entries starting with cp_dustbowl (eg cp_dustbowl_english) would also kill cp_dustbowl.
Attached Files
File Type: sp Get Plugin or Get Source (maplister.sp - 153 views - 7.6 KB)
File Type: smx maplister.smx (6.6 KB, 52 views)
Malachi is offline
theY4Kman
Join Date: Jun 2007
Location: Yak
Old 07-17-2013 , 17:14   Re: Maplister
Reply With Quote #57

Quote:
Originally Posted by Malachi View Post
After the SteamPipe update, this plugin was causing us some problems. So instead of complaining, I fixed it.
You're my new favourite person. Do you think your version should be the one offered on the first post? (It's been a long time since I've known why this plug-in was useful, so I don't want to update the first post myself if it turns out I made a bad assumption.) Regardless, I've put a notice up about your update, right above the current download link.

I really appreciate you writing the post and letting others know of your fix.
__________________
http://y4kstudios.com
Is that loud enough? Oh, while I have you, check out Viper.
theY4Kman is offline
Send a message via ICQ to theY4Kman Send a message via AIM to theY4Kman Send a message via MSN to theY4Kman Send a message via Yahoo to theY4Kman Send a message via Skype™ to theY4Kman
Malachi
Senior Member
Join Date: Jun 2010
Location: USA
Old 07-18-2013 , 16:20   Re: Maplister
Reply With Quote #58

Quote:
Originally Posted by theY4Kman View Post
You're my new favourite person. Do you think your version should be the one offered on the first post? (It's been a long time since I've known why this plug-in was useful, so I don't want to update the first post myself if it turns out I made a bad assumption.) Regardless, I've put a notice up about your update, right above the current download link.

I really appreciate you writing the post and letting others know of your fix.

Thanks, I love appreciation!

*

My only hesitation is that my update changes which file the maps are dumped to. If ppl want a drop-in replacement, maybe the output file should be changed back. Or maybe I should just put in a cvar to handle that and be done with it.

Yeah, let me put in the cvar. Should only take me a day or two. Then you can post it up front.

Sound good?
Malachi is offline
theY4Kman
Join Date: Jun 2007
Location: Yak
Old 07-18-2013 , 21:35   Re: Maplister
Reply With Quote #59

Quote:
Originally Posted by Malachi View Post
Thanks, I love appreciation!

*

My only hesitation is that my update changes which file the maps are dumped to. If ppl want a drop-in replacement, maybe the output file should be changed back. Or maybe I should just put in a cvar to handle that and be done with it.

Yeah, let me put in the cvar. Should only take me a day or two. Then you can post it up front.

Sound good?
Sounds great
__________________
http://y4kstudios.com
Is that loud enough? Oh, while I have you, check out Viper.
theY4Kman is offline
Send a message via ICQ to theY4Kman Send a message via AIM to theY4Kman Send a message via MSN to theY4Kman Send a message via Yahoo to theY4Kman Send a message via Skype™ to theY4Kman
Malachi
Senior Member
Join Date: Jun 2010
Location: USA
Old 07-20-2013 , 20:02   Re: Maplister
Reply With Quote #60

Ok, here it is.

I haven't extensively tested it, though I haven't made any extreme changes. That said if there's a problem let me know and I should be able to quickly fix it.

The one issue I know of is that since the default file is maplist.txt, there may be special cases where that file gets overwritten before sm_maplist_file has a chance to update. There are a couple of possible solutions to this: 1. use a dedicated cfg file; 2. set no default to force ppl to set the cvar. While I'm a fan of the latter, if I do that it won't be a drop in replacement.


Changes (v1.6.7):
Added CVar sm_maplist_file which defaults to maplist.txt. This sets the default file that will get written to on map change (if enabled) OR on sm_writemaplist where no file arguments are passed.


I also did a small bit of cleanup here and there. I didn't attach a smx file because you're going to post it on the front page.
Attached Files
File Type: sp Get Plugin or Get Source (maplister.sp - 155 views - 8.6 KB)

Last edited by Malachi; 07-20-2013 at 20:03.
Malachi 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 01:52.


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