Raised This Month: $ Target: $400
 0% 

Adding text to certain maps.


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Fiercetree
Member
Join Date: Dec 2020
Location: I want large bread
Old 08-15-2021 , 12:20   Adding text to certain maps.
Reply With Quote #1

I have a bot server of CS CZ and I have some maps that do not have bots. I'm having difficulty adding text to my map names, so that during the vote, certain maps in the list will have the text next to the map name: (no bots). Besides this change I wanted the map vote to work exactly like amxmodx.

Fysiks provided me with a mapchooser.amxx fille and map_extra_text.ini file. This would allow me to place my maps with added text in the map_extra_text.ini file.

Quote:
Originally Posted by fysiks View Post
This will add text in parentheses after the map name in the vote. The text is arbitrary so you can add what ever you want. This extra text is loaded from an INI file in the AMX Mod X configs directory. Place "map_extra_text.ini" in the AMX Mod X configs directory. I tested it on Day of Defeat so you'll remove all of my maps and replace them with your own. Any maps that you don't want to have any extra text, simply don't add them to the file.

If something doesn't work like you want or you want to modify this at all, please create a thread in Suggestions/Requests and we'll work in that thread.
However, now the map vote won't come up at all. It usually pops up 2 mins before the end of the map. My maps.ini file is in the amxmodx config directory and my mapcycle.txt is in the czero folder of my server.

Last edited by Fiercetree; 08-15-2021 at 18:50. Reason: Clarity
Fiercetree is offline
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 08-15-2021 , 16:59   Re: Adding text to certain maps.
Reply With Quote #2

FYI, you are not allowed to post .amxx files here, please remove them.

The only reason that a vote would not occur is if it didn't load any maps. You should also check your error logs (files that begin with "error_" in the AMX Mod X logs directory.

I have attached a new version that adds debugging. Please run this on a couple maps with mp_timelimit set to something like 5 minutes. Then, please provide me with the mapchooser_debug.txt in the root mod directory. This should tell me what is causing it not to do the vote.
Attached Files
File Type: sma Get Plugin or Get Source (mapchooser.sma - 77 views - 8.3 KB)
File Type: sma Get Plugin or Get Source (mapchooser_1.10.sma - 70 views - 7.5 KB)
__________________

Last edited by fysiks; 08-16-2021 at 22:11.
fysiks is offline
Fiercetree
Member
Join Date: Dec 2020
Location: I want large bread
Old 08-16-2021 , 20:53   Re: Adding text to certain maps.
Reply With Quote #3

Quote:
Originally Posted by fysiks View Post
FYI, you are not allowed to post .amxx files here, please remove them.

The only reason that a vote would not occur is if it didn't load any maps. You should also check your error logs (files that begin with "error_" in the AMX Mod X logs directory.

I have attached a new version that adds debugging. Please run this on a couple maps with mp_timelimit set to something like 5 minutes. Then, please provide me with the mapchooser_debug.txt in the root mod directory. This should tell me what is causing it not to do the vote.
I ran the new version with debugging for a few maps. But I'm unable to locate a mapchooser_debug.txt in the mod directory or anywhere else on my server.

I got these errors in the error logs, but no other errors:
L 08/16/2021 - 206:19: [AMXX] Plugin file open error (plugin "antiflood.amxx")
L 08/16/2021 - 206:19: [AMXX] Invalid Plugin (plugin "mapchooser.amxx")
Fiercetree is offline
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 08-16-2021 , 22:07   Re: Adding text to certain maps.
Reply With Quote #4

That error says that the plugin is not even running because it's not valid. So, you're probably using the "Get Plugin" link which will give you an invalid plugin because the compiler it uses is for AMX Mod X 1.8.2 (I just remembered).

I've created a version that should compile for 1.8.2 using the "Get Plugin" link. I've also attached a version based on AMX Mod X 1.10 but this one you'll need to compile locally and rename if that is the one you want. Both should work just fine.

I've removed debugging because I'm confident that the issue will be fixed when you download a non-corrupt version.
__________________

Last edited by fysiks; 08-16-2021 at 22:10.
fysiks is offline
Fiercetree
Member
Join Date: Dec 2020
Location: I want large bread
Old 08-17-2021 , 10:29   Re: Adding text to certain maps.
Reply With Quote #5

Quote:
Originally Posted by fysiks View Post
That error says that the plugin is not even running because it's not valid. So, you're probably using the "Get Plugin" link which will give you an invalid plugin because the compiler it uses is for AMX Mod X 1.8.2 (I just remembered).

I've created a version that should compile for 1.8.2 using the "Get Plugin" link. I've also attached a version based on AMX Mod X 1.10 but this one you'll need to compile locally and rename if that is the one you want. Both should work just fine.

I've removed debugging because I'm confident that the issue will be fixed when you download a non-corrupt version.
Works like a charm! Thank you so much! I used the 1.8.2 version. I also put the map name with the extra text in maps.ini. It didn't pull it from the map_extra_text_ini file but it did from the maps.ini. I left that extra one on the server, just in case.
This issue is solved, thanks to you!
You absolutely rock!
Fiercetree is offline
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 08-17-2021 , 19:35   Re: Adding text to certain maps.
Reply With Quote #6

Quote:
Originally Posted by Fiercetree View Post
It didn't pull it from the map_extra_text_ini file but it did from the maps.ini.
That is not possible unless you changed the code. You still need the map names in maps.ini but then you also need the map names in map_extra_text.ini with the extra text for maps that you want to have extra text.

Regardless, I'm glad it is working for you now.
__________________
fysiks is offline
Fiercetree
Member
Join Date: Dec 2020
Location: I want large bread
Old 08-17-2021 , 22:14   Re: Adding text to certain maps.
Reply With Quote #7

Quote:
Originally Posted by fysiks View Post
That is not possible unless you changed the code. You still need the map names in maps.ini but then you also need the map names in map_extra_text.ini with the extra text for maps that you want to have extra text.

Regardless, I'm glad it is working for you now.
My mistake, you're correct. When I first tested it, I put the maps with extra text in the JUST the map_extra_text.ini, in which case, it didn't work. I then also added those maps to the maps.ini file.
Any maps with extra text added in the future, I will add to both of those files.

Thank you so much though! Very glad it works.

Last edited by Fiercetree; 08-17-2021 at 22:16.
Fiercetree 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 15:28.


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