Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ban maps based on their core name #68

Open
evandrocoan opened this issue May 28, 2017 · 1 comment
Open

Ban maps based on their core name #68

evandrocoan opened this issue May 28, 2017 · 1 comment

Comments

@evandrocoan
Copy link
Owner

evandrocoan commented May 28, 2017

Skyliner: And a second question.
I got for exemple 3 types of the map assault, de_assault, cs_assault and cs_assault_shadow.
It is possible to make something to ban for 6 maps all the assault maps?

https://forums.alliedmods.net/showthread.php?p=2523716#post2523716

The map name core should be guessed using this algorithm/strategy bellow:

  1. Find an underscore from the first character name.
  2. Copy the next characters after the underscore until find the end of the map name or another underscore.
  3. Add the copied word to the recentMapsCore.dat file.

It would not use the same value on the cvar gal_banrecent, to not interfere within the standard behavior.
It would created a new cvar called gal_banrecent_core which would ban maps based on their core name.

// Specifies how many of the most recent maps are disallowed from a map
// vote. For example:
//
// I got for example 3 types of the `assault` maps: de_assault,
// cs_assault and cs_assault_shadow. It is possible to make something to
// ban all the assault maps?
//
// The map name core should be guessed using this algorithm/strategy
// bellow:
//
// 1. Find an underscore from the first character name.
// 2. Copy the next characters after the underscore until find the end
//    of the map name or another underscore.
// 3. Add the copied word to the `recentMapsCore.dat` file.
//
// If you specify a value greater than the number of maps in your server,
// it will automatically ban only the maximum allowed.
//
// A value of 0 will disable this feature.
//
// Default: 0
gal_banrecent_core 0

This also would require a new way to ban limit the maximum allowed map bans. Now when the menu ran out of maps due the ban feature, it would need to invoke this ban feature core and un-ban the necessary number of maps, and keep filling the voting menu.

Also add this technique to the current map ban feature for robustness and create the new cvar gal_banrecent_room for both ban features which will allow un-ban some maps beyond the voting menu map choices, so the random map feature can be random. Otherwise it would follow a sequence after all maps being banned.

// Force un-ban some maps beyond the voting menu map choices, therefore
// the random map feature can be random. Otherwise it would follow a
// sequence after all maps being banned, when the maximum allowed ban
// limit is reached.
//
// Default: 0
gal_banrecent_room 3
@ish12321
Copy link

fy_snow and de_snow both would have same core name ..
This feature is i think not important

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants