Raised This Month: $130 Target: $400
 32% 

Multimod Plugin


Post New Thread Reply   
 
Thread Tools Display Modes
Plugin Info:     Modification:   Counter-Strike        Category:   General Purpose        Approver:   Hawk552 (427)
joropito
AlliedModders Donor
Join Date: Mar 2009
Location: pfnAddToFullPack
Old 06-24-2009 , 22:44   Multimod Plugin
Reply With Quote #1

This plugin was inspired in
- My idea to run in the same server different sets of plugins
- I found some plugins and the very best aproach was this
Advanced end map vote


UPDATED TO v2.2
- Remember to download language file for correct update.
- Now map voting it's in a separate plugin. You can download from here.
- There was a mistake with the uploaded file mapchooser_multimod.sma. It's fixed now (12/23/2009)
- Fixed all errors found until thread #321 (12/23/2009)
- Files to download: multimod.amxx + multimod.txt (lang) + mapchooser_multimod.amxx (replacement of mapchooser.amxx)

- v0.8 Still available to download. Install instruccions for v0.8 are in multimod-v08.txt file.
- Files to download for v0.8: multimod-v08.amxx + multimod-v08.txt (instructions)



NOTICE
* This plugin is compatible with mapchooser_multimod (you can download it here)
* This plugin may be compatible with galileo. Give it a try!


Code:
Changes
v2.2
* Fixed votemod DoS
* Fixed galileo plugin lookup problem
* Fixed mapchooser_multimod plugin lookup problem
* Fixed nextmod client command problem
* Added currentmod client command
* Added cvar to disallow votemod client command

v2.1
* Recoded from the scratch
* Added mapchooser_multimod (original mapchooser with a few modifications to make it compatibile with multimod)
* Added compatibility with galileo (not fully tested)
Description

Once this plugin is loaded for the first time, it restarts the server to correctly setup and choosing the first mod available in config file.

When it's time to vote map, all players must vote for the nextmap plugin-set (I prefer to call as Mod).
After that, you can vote for custom maps using mapchooser_multimod or Galileo

So, with this you have:

- Plugin-sets/Mods to play
- Per-Mod mapcycle file
- Per-Mod cvars file

Cvars
amx_mintime: Minimum time to play before players can make MOD voting
amx_multimod_mode: Compatibility mode 0 [auto] ; 1 [mapchooser_multimod] ; 2 [Galileo]

Commands
amx_votemod: Admin only command to launch MOD & MAP voting
say /votemod: Player command to launch MOD & MAP voting
say_team /votemod: Player command to launch MOD & MAP voting
say nextmod: Check which MOD will be running in next map

Installation

check this out: https://forums.alliedmods.net/showpo...&postcount=289
  • Compile and put it in your plugins folder
  • Create the folder multimod in your game base directory (ej: cstrike/multimod czero/multimod)
  • Create file multimod.ini in multimod folder (see file format in examples)
  • Create those files for each mod in multimod folder (TAG is the one used in multimod.ini file)
  • TAG-plugins.ini: plugin list to be loaded for the mod (you must include multimod.amxx, admin plugins, mod specific plugins, etc)
  • TAG-maps.ini: maps list for the mod (same format as mapcycle.txt)
  • cfgfilename.cfg: custom cvars and values for the mod
  • Add multimod.amxx into addons/amxmodx/configs/plugins.ini
  • Remember to disable mapchooser.amxx

  • If using mapchooser_multimod, be sure to delete addons/amxmodx/configs/maps.ini if it's there

How it works?
* This plugin doesn't move, rename nor create files on the fly
* This plugin doesn't have a map voting code at this time
* This plugin will restart the server at first run to setup correctly
* After first restart, default plugins.ini will not be loaded anymore
* When there's 3 minutes left for the current map, this plugin will bring a menu for MOD voting
* Then, mapchooser/galileo will have time to work on map voting


////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
EXAMPLE

* multimod.ini format example
Quote:
;mode name:mod tag:custom cvars cfg file
[Gun Game]:[gungame]:[gungame-config.cfg]
[Paint Ball]:[paintball]:[paintball-config.cfg]
* With this example you will need to create:

Quote:
multimod/gungame-maps.ini
multimod/gungame-plugins.ini
multimod/gungame-config.cfg

multimod/paintball-maps.ini
multimod/paintball-plugins.ini
multimod/paintball-config.cfg

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////



Comments are welcome.
If you need help to setup your own multimod server, you're welcome.
Attached Files
File Type: txt multimod.txt (6.8 KB, 10606 views)
File Type: sma Get Plugin or Get Source (multimod-v08.sma - 12282 views - 14.0 KB)
File Type: txt multimod-v08.txt (3.6 KB, 6672 views)
File Type: sma Get Plugin or Get Source (multimod.sma - 14171 views - 10.1 KB)
File Type: sma Get Plugin or Get Source (mapchooser_multimod.sma - 13286 views - 7.9 KB)

Last edited by joropito; 12-23-2009 at 20:05. Reason: File update
joropito is offline
Send a message via MSN to joropito
Jaden
Member
Join Date: Jun 2009
Old 06-24-2009 , 22:53   Re: MULTIMOD PLUGIN
Reply With Quote #2

So if map goes to deathrun the deathrun mod turns on, and if it goes to a gg_maze or a gg_map then it turns on gungame?
__________________
`Jaden.
Jaden is offline
roflmao456
Junior Member
Join Date: Jun 2009
Location: Canada
Old 06-24-2009 , 22:56   Re: MULTIMOD PLUGIN
Reply With Quote #3

That's pretty neat. Good idea
roflmao456 is offline
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 06-24-2009 , 23:03   Re: MULTIMOD PLUGIN
Reply With Quote #4

Quote:
Originally Posted by Jaden View Post
So if map goes to deathrun the deathrun mod turns on, and if it goes to a gg_maze or a gg_map then it turns on gungame?
No, it brings up a vote for which mod you want to play next then it only gives you maps that are allowed for that specific mod.

Why are you so "anti-whitespace"?
__________________
fysiks is online now
Jaden
Member
Join Date: Jun 2009
Old 06-24-2009 , 23:06   Re: MULTIMOD PLUGIN
Reply With Quote #5

Ohh, then i like it, very good idea
__________________
`Jaden.
Jaden is offline
crazyeffect
Veteran Member
Join Date: Jul 2008
Location: Belgium
Old 06-25-2009 , 04:14   Re: MULTIMOD PLUGIN
Reply With Quote #6

Actually this is cool
__________________
crazyeffect is offline
Send a message via MSN to crazyeffect
joropito
AlliedModders Donor
Join Date: Mar 2009
Location: pfnAddToFullPack
Old 06-26-2009 , 13:29   Re: MULTIMOD PLUGIN
Reply With Quote #7

Updated

Fixed some minor bugs.
Added admin command amx_votemod to force Mod votting

I will add some commands and checks to avoid errors in server log (empty arrays, empty/inexistent files, etc)
joropito is offline
Send a message via MSN to joropito
Old 06-26-2009, 13:33
joropito
This message has been deleted by joropito. Reason: repeated
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 06-27-2009 , 11:41   Re: MULTIMOD PLUGIN
Reply With Quote #8

pause a plugin is not efficient for some mod, example with csdm and ffa mode on, i bet that pause csdm won't turn off ffa.
__________________
- tired and retired -
ConnorMcLeod is offline
fang
Senior Member
Join Date: Nov 2007
Location: New Jersey
Old 06-27-2009 , 12:03   Re: MULTIMOD PLUGIN
Reply With Quote #9

Quote:
Originally Posted by ConnorMcLeod View Post
pause a plugin is not efficient for some mod, example with csdm and ffa mode on, i bet that pause csdm won't turn off ffa.
Couldn't you just not add the FFA into the other sections so it auto-pauses then?

EDIT:
This plugin would be awesome if you could integrate a RTV function to it.
__________________
fang is offline
crazyeffect
Veteran Member
Join Date: Jul 2008
Location: Belgium
Old 06-27-2009 , 13:05   Re: MULTIMOD PLUGIN
Reply With Quote #10

yeah
__________________
crazyeffect is offline
Send a message via MSN to crazyeffect
Reply


Thread Tools
Display Modes

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 22:01.


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