Raised This Month: $ Target: $400
 0% 

MultiMod Manager CS [v2.2.1]


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Plugin Info:     Modification:   Counter-Strike        Category:   Server Management       
Federicomb
Junior Member
Join Date: Mar 2014
Location: Rosario, Argentina.
Old 07-11-2023 , 03:07   MultiMod Manager CS [v2.2.1]
Reply With Quote #1

MultiMod Manager CS [v2.2.1]


Introduction
Hi , this is my first post here. I want to share with you this project that I have published for 2 years now on my personal GitHub. A project that arose from the fact of improving old multimod plugins that had few features and limitations. Now I feel more confident to share it with you, since it is in a stable version. The project is open to new ideas and suggestions to continue improving it even more. I want to thank the collaborators who have participated and those who are still participating, both in the development of ideas, in testing and debugging. Special thanks to metita who has been the one who has helped me the most in testing and debugging.

Post in spanish: https://amxmodx-es.com/Thread-MultiMod-Manager--25264

Contributors
  • metita
  • Mía
  • Totopizza
  • Roccoxx
  • r0ma
  • Maxi605

RequirementsReSemiclip Compatibility >= 2.3.9 (Optional)

Features
  • Configurations through JSON file
  • Votemod
  • Votemap
  • Nominations (Mods and Maps)
  • RTV (Rock The Vote)
  • Recently played mods and maps
  • Say commands (All say commands can be found here)
  • Admin commands (custom votes, manage, force votemod)
  • API natives and forwards (All detailed information is here)

Config file (JSON) (e.g)
addons/amxmodx/configs/multimod_manager/configs.json
Code:
{
	"global_chat_prefix": "!g[MULTIMOD]",
		// !g = ^4 (Green color)
		// !t = ^3 (Team color)
		// !y = ^1 (con_color cvar)

	"adminflags":
	{
		"menu": "u",        // menu access
		"managemods": "a",  // immunity 
		"selectmenu": "f",  // amx_map command
		"forcevotemod": "f",// amx_map command
		"votemenu": "j"     // amx_vote and other vote commands
	},

	"rockthevote":
	{
		"enable": true,     // true / false
		"cooldown": 120,    // min = 0 (disabled)
		"minplayers": 3,    // min = 0 (disabled) | max = 32
		"percentage": 75    // min = 0 (disabled) | max = 100
	},

	"nomination":
	{
		"mods": true,       // true / false
		"maps": true        // true / false
	},

	"admin_max_options_in_menu": 9,   // min = 2 | max = 9
	"mods_in_menu": 9,                // min = 2 | max = 9
	"maps_in_menu": 9,                // min = 2 | max = 9

	"max_recent_mods": 5,   // min = 0
	"max_recent_maps": 5,   // min = 0

	"overwrite_mapcycle": true, // true / false (overwrites the mapcycle.txt with the maps of the selected mod)

	"resemiclip_path": "", 
		// Path where the add-on is located
		// Leave empty to disable this option ("")
		// If the path does not exist, it will be considered as disabled
		// E.g.: "addons/resemiclip"

	"change_game_description": true, // true / false (Changes the game description with the name of the mod)

	"mods":
	[
		// The first mode will always be the default mode, it cannot be blocked
		{
			"modname": "GunGame",
				// Mod name.
				// E.g.: "GunGame"


			"mod_tag": "gg",
				// Mod tag
				// E.g.: "gg"


			"mapsfile": "gungame_maps.ini",
				// Only the file name along with the extension.
				// The file must be located in "addons/amxmodx/configs/multimod_manager/mapsfiles/"
				// E.g.: "gungame_maps.ini"


			"change_map_type": 0,
				// "change_map_type": 0 (The map will change at the end of the map)
				// "change_map_type": 1 (The map will change at the end of the round)
				// "change_map_type": 2 (Allows to play 1 more round and then changes the map)


			"cvars":
			[
				"sv_gravity 900", "sv_alltalk 1"
			],
				// Cvars that are executed when starting the mode, all the ones you want
				// Each cvar in quotes and separated by commas
				// E.g.: "cvars": [ "sv_gravity 900", "sv_alltalk 1", "hostname My CS Server", "mp_roundtime 6" ]
				// Leave "cvars": [ ] // to not load cvars


			"plugins":
			[
				"plugin10.amxx", "plugin20.amxx"
			],
				// Plugins that are needed for this mode, all the ones you want
				// Each plugin in quotes, separated by commas and with its corresponding extension
				// E.g.: "plugins": [ "gungame.amxx", "ultimate_sounds.amxx", "csstats.amxx" ]
				// Leave "plugins": [ ] // to not load cvars

			"resemiclip_config":
			{
				"semiclip": "1",
				"team": "3", // 0 = all | 1 = T | 2 = CT | 3 = Team
				"time": "0",
				"crouch": "0",
				"effects": "0",
				"distance": "250",
				"transparency": "0",
				"penetfire": "0"
			}
		},
		{
			"modname":"DeathMatch",
			"mod_tag": "dm",
			"mapsfile":"deathmatch_maps.ini",
			"change_map_type": 1,
			"cvars":
			[
				"sv_gravity 900", "sv_alltalk 1"
			],
			"plugins":
			[
				"plugin11.amxx", "plugin21.amxx", "plugin33.amxx", "plugin44.amxx", "plugin5.amxx"
			],
			"resemiclip_config":
			{
				"semiclip": "1",
				"team": "3",
				"time": "0",
				"crouch": "0",
				"effects": "0",
				"distance": "250",
				"transparency": "0",
				"penetfire": "0"
			}
		},
		{
			"modname":"Fruta",
			"mod_tag": "fr",
			"mapsfile":"fruta_maps.ini",
			"change_map_type": 1,
			"cvars":
			[
				"sv_gravity 900", "sv_alltalk 1"
			],
			"plugins":
			[
				"plugin12.amxx", "plugin22.amxx", "plugin32.amxx", "plugin42.amxx"
			],
			"resemiclip_config":
			{
				"semiclip": "1",
				"team": "3",
				"time": "0",
				"crouch": "0",
				"effects": "0",
				"distance": "250",
				"transparency": "0",
				"penetfire": "0"
			}
		},
		{
			"modname":"Zombie Plague",
			"mod_tag": "zp",
			"mapsfile":"zp_maps.ini",
			"change_map_type": 1,
			"cvars":
			[
				"sv_gravity 900", "sv_alltalk 1"
			],
			"plugins":
			[
				"plugin13.amxx", "plugin23.amxx", "plugin33.amxx", "plugin43.amxx", "plugin53.amxx", "plugin63.amxx", "plugin73.amxx"
			],
			"resemiclip_config":
			{
				"semiclip": "1",
				"team": "3",
				"time": "0",
				"crouch": "0",
				"effects": "0",
				"distance": "250",
				"transparency": "0",
				"penetfire": "0"
			}
		},
		{
			"modname":"PaintBall",
			"mod_tag": "pb",
			"mapsfile":"paintball_maps.ini",
			"change_map_type": 1,
			"cvars":
			[
				"sv_gravity 900", "sv_alltalk 1"
			],
			"plugins":
			[
				"plugin14.amxx", "plugin24.amxx", "plugin34.amxx", "plugin44.amxx"
			],
			"resemiclip_config":
			{
				"semiclip": "1",
				"team": "3",
				"time": "0",
				"crouch": "0",
				"effects": "0",
				"distance": "250",
				"transparency": "0",
				"penetfire": "0"
			}
		},
		{
			"modname":"HNS",
			"mod_tag": "hns",
			"mapsfile":"hns_maps.ini",
			"change_map_type": 1,
			"cvars":
			[
				"sv_gravity 900", "sv_alltalk 1"
			],
			"plugins":
			[
				"plugin15.amxx", "plugin25.amxx", "plugin35.amxx", "plugin45.amxx"
			],
			"resemiclip_config":
			{
				"semiclip": "1",
				"team": "3",
				"time": "0",
				"crouch": "0",
				"effects": "0",
				"distance": "250",
				"transparency": "0",
				"penetfire": "0"
			}
		},
		{
			"modname":"Surf",
			"mod_tag": "sf",
			"mapsfile":"surf_maps.ini",
			"change_map_type": 1,
			"cvars":
			[
				"sv_gravity 900", "sv_alltalk 1"
			],
			"plugins":
			[
				"plugin15.amxx", "plugin25.amxx", "plugin35.amxx"
			],
			"resemiclip_config":
			{
				"semiclip": "1",
				"team": "3",
				"time": "0",
				"crouch": "0",
				"effects": "0",
				"distance": "250",
				"transparency": "0",
				"penetfire": "0"
			}
		}
	]
}
Console commands
  • mm_force_votemod: Forces a votemod.
  • amx_multimod: Opens an admin command menu.
  • amx_manage_mm: Opens an admin manage menu.

API
PHP Code:
enum ChangeMap_e
{
    
CHANGEMAP_TIMELEFT,
    
CHANGEMAP_END_OF_ROUND,
    
CHANGEMAP_ONE_MORE_ROUND,
};

/* ===========================================================================
*                 [ MULTIMOD MANAGER NATIVES ]
* ============================================================================ */

/**
 * Return the loaded mods count.
 *
 * @return (int)        Number of loaded mods.
 */
native mm_get_mods_count();

/**
 * Return if the mod is enabled or not.
 *
 * @param iModId        Mod index.
 *
 * @return (bool)       true if the mod is enabled, false otherwise.
 */
native bool:mm_is_mod_enabled(const iModId);

/**
 * Retrieves mod name.
 *
 * @note If the destination buffer is too small to hold the source string, the 
 *       destination will be truncated.
 *
 * @param iModId        Mod index.
 * @param szOutput      Buffer to copy mod name to.
 * @param iLen          Buffer size.
 *
 * @return (int)        -1 on error.
 *                      >= 0 Number of cells written.
 */
native mm_get_mod_name(const iModIdszOutput[], const iLen);

/**
 * Retrieves mod tag.
 *
 * @note If the destination buffer is too small to hold the source string, the 
 *       destination will be truncated.
 *
 * @param iModId        Mod index.
 * @param szOutput      Buffer to copy mod tag to.
 * @param iLen          Buffer size.
 *
 * @return (int)        -1 on error.
 *                      >= 0 Number of cells written.
 */
native mm_get_mod_tag(const iModIdszOutput[], const iLen);

/**
 * Return the mod changemap type.
 *
 * @note See 'ChangeMap_e' enum for more information.
 *
 * @param iModId        Mod index.
 *
 * @return (int)        0 on change map timeleft.
 *                      1 on change map end of round.
 *                      2 on change map one more round.
 */
native ChangeMap_e:mm_get_mod_changemap_type(const iModId);

/**
 * Return the maps list of the mod.
 *
 * @param iModId        Mod index.
 *
 * @return (Array)      Maps list array handle, which must be freed via ArrayDestroy()
 */
native Array:mm_get_mod_maps(const iModId);

/**
 * Return the cvars list of the mod.
 *
 * @param iModId        Mod index.
 *
 * @return (Array)      Cvars list array handle, which must be freed via ArrayDestroy()
 */
native Array:mm_get_mod_cvars(const iModId);

/**
 * Return the plugin list of the mod.
 *
 * @param iModId        Mod index.
 *
 * @return (Array)      Plugins list array handle, which must be freed via ArrayDestroy()
 */
native Array:mm_get_mod_plugins(const iModId);

/**
 * Return the current mod index based on JSON position.
 *
 * @return (int)        Index of the current mod.
 */
native mm_get_currentmod_id();

/**
 * Return the next mod index based on JSON position if nextmod is already chosen.
 *
 * @return (int)        -1 if nextmod is not chosen yet.
 *                      >= 0 Index of the next mod.
 */
native mm_get_nextmod_id();

/**
 * Force a votemod.
 *
 * @return (bool)       true on success, false otherwise
 */
native bool:mm_force_votemod();

/**
 * Force a map change.
 *
 * @param iModId        Mod index.
 * @param szMap         Map to change to.
 * @param flChangeTime  Time to wait before changing map.
 *                      0.0 to change map immediately.
 *
 * @return (bool)       true on success, false otherwise.
 */
native bool:mm_force_change_map(const iModId, const sMap[], const Float:flChangeTime 0.0);

/* ===========================================================================
*                 [ MULTIMOD MANAGER FORWARDS ]
* ============================================================================ */

/**
 * Called when a votemod gets started
 *
 * @param bSecondVote   True if this is the second votemod for tiebreaker
 */
forward multimod_start_votemod(const bool:bSecondVote);

/**
 * Called when a votemod gets ended
 *
 * @param bSecondVote   True if this is the second votemod for tiebreaker
 */
forward multimod_end_votemod(const bool:bSecondVote);

/**
 * Called when a votemap gets started
 *
 * @param bSecondVote   True if this is the second votemap for tiebreaker
 */
forward multimod_start_votemap(const bool:bSecondVote);

/**
 * Called when a votemap gets ended
 *
 * @param bSecondVote   True if this is the second votemap for tiebreaker
 */
forward multimod_end_votemap(const bool:bSecondVote);

/**
 * Called when a admin forces a votemod
 *
 * @param iAdminId      Admin index
 *
 * @return              PLUGIN_CONTINUE to let the admin force a votemod
 *                      PLUGIN_HANDLED or higher to stop the admin from forcing a votemod
 */
forward multimod_admin_force_votemod(const iAdminId); 

Repository

https://github.com/FEDERICOMB96/amxx-multimod-manager

Latest release: https://github.com/FEDERICOMB96/amxx...eleases/latest
Attached Files
File Type: zip MultiModManagerCS-v1.1.0.zip (91.3 KB, 153 views)
File Type: zip MultiModManagerCS-v2.1.2.zip (98.3 KB, 158 views)
File Type: zip MultiModManagerCS-v2.2.0.zip (98.3 KB, 197 views)
File Type: zip MultiModManagerCS-v2.2.1.zip (100.7 KB, 146 views)
__________________
Believe, be yourself and don't hold on to just one dream ❤

https://github.com/FEDERICOMB96

Last edited by Federicomb; 09-12-2023 at 05:02. Reason: Updated to v2.2.1
Federicomb is offline
 



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 21:11.


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