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

Custom Vote Menus


Post New Thread Reply   
 
Thread Tools Display Modes
Plugin Info:     Modification:   ALL        Category:   Admin Commands        Approver:   Hawk552 (427)
GHW_Chronic
SourceMod Donor
Join Date: Sep 2004
Location: Texas
Old 09-02-2007 , 17:58   Custom Vote Menus
Reply With Quote #1

  • This plugin allows you to create a custom vote with any format you want. Includes the ability to set colors of words / letters and justify options. And then depending on what option won, the plugin will execute whatever you want on the admin/server's console (depending on cvar).

  • Example Syntax:
    • Code:
      [Menu]
      Choose A Mod:
      
      1. Halo Mod
      2. CSDM
      3. CTF
      4. Fun Mod
      5. Normal Gameplay
      
      0. Don't Care
      [/Menu]
      
      
      
      
      [1]
      amx_halomod on
      amx_csdm disable
      amx_ctf 0
      amx_funmod off
      [/1]
      
      [2]
      amx_halomod off
      amx_csdm enable
      amx_ctf 0
      amx_funmod off
      [/2]
      
      [3]
      amx_halomod off
      amx_csdm disable
      amx_ctf 1
      amx_funmod off
      [/3]
      
      [4]amx_halomod off
      amx_csdm disable
      amx_ctf 0
      amx_funmod on
      [/4]
      
      [5]
      amx_halomod off
      amx_csdm disable
      amx_ctf 0
      amx_funmod off
      [/5]
      
      [0]
      say Why doesn't anybody care :'(
      [/0]
    • The above example would print out the menu that is at the top of the config file (inbetween the [Menu] [ /Menu] ) and show it exactly as it looks. (white text). Then pretending option #5 won (the majority of people voted for it) then the stuff listed between the [5] [ /5] would be executed on admin/server console (again, depending on the cvar setting).

  • Color and Justification symbols:
    • \r - will make anything after it red
    • \y - will make anything after it yellow
    • \w - will make anything after it white
    • \R - will justify to the right

  • Example Menu with Color + Justification:
    • Code:
      [Menu]
      Choose A Mod:
      
      \y1. \wHalo Mod
      \y2. \wCSDM
      \y3. \wCTF
      \y4. \wFun Mod
      \y5. \wNormal Gameplay\R\rBoring
      
      \y0. \wDon't Care
      [/Menu]
    • The above will look like this:
    • Choose A Mod:

      1. Halo Mod
      2. CSDM
      3. CTF
      4. Fun Mod
      5. Normal Gameplay________Boring

      0. Don't Care
    • Please note that some mods don't support menu color. (CS/CZ do, TFC doesn't)

  • Commands:
    • amx_cvote <vote name>
    • amx_cvote_list - Lists all custom votes in the votes directory.

  • CVARs:
    • cvote_show - Show what a player voted for (1=show 0=don't show) (Default: 1)
    • cvote_execute - Execute winning console command(s) where? (1=admin's console 2=server's console)

  • Config Files:
    • Name.ini - Name is the name of the vote menu that will be used with the commands.
    • configs/votes - Place all vote menu config files into there (votes directory has to be created).
    • Only 1 vote menu per config file.
    • [Menu] and [#] can be in any order you want.
    • Even if an option doesn't execute anything you must have the [#][ /#] (on seperate lines)
Attached Files
File Type: sma Get Plugin or Get Source (GHW_Custom_Vote_Menus.sma - 3520 views - 5.6 KB)

Last edited by GHW_Chronic; 10-24-2007 at 10:21.
GHW_Chronic is offline
Send a message via AIM to GHW_Chronic
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 09-02-2007 , 18:18   Re: Custom Vote Menus
Reply With Quote #2

Seems very useful.
__________________
Arkshine is offline
hackziner
Senior Member
Join Date: Sep 2006
Location: France
Old 09-02-2007 , 18:29   Re: Custom Vote Menus
Reply With Quote #3

Yep, seems to be great

+k
__________________
hackziner is offline
Send a message via ICQ to hackziner Send a message via AIM to hackziner Send a message via MSN to hackziner Send a message via Yahoo to hackziner Send a message via Skype™ to hackziner
ABC3Q
Junior Member
Join Date: Mar 2007
Old 09-02-2007 , 19:40   Re: Custom Vote Menus
Reply With Quote #4

I demand approval.
__________________
| Account has been abandoned |
ABC3Q is offline
GHW_Chronic
SourceMod Donor
Join Date: Sep 2004
Location: Texas
Old 09-02-2007 , 19:43   Re: Custom Vote Menus
Reply With Quote #5

Quote:
Originally Posted by ABC3Q View Post
I demand approval.
lol I only released this like 2 hours ago
GHW_Chronic is offline
Send a message via AIM to GHW_Chronic
eXtinct
Member
Join Date: Sep 2007
Location: Bay Area, CA
Old 09-02-2007 , 20:00   Re: Custom Vote Menus
Reply With Quote #6

Still...this plugin must be approved!
__________________
eXtinct . it'll all be over very soon .

eXtinct is offline
BlackMilk
Veteran Member
Join Date: Jun 2007
Old 09-03-2007 , 06:16   Re: Custom Vote Menus
Reply With Quote #7

Very nice, this should make for interesting things
__________________
Mod:
User:
BlackMilk is offline
Tartooob
Senior Member
Join Date: May 2006
Old 09-03-2007 , 06:39   Re: Custom Vote Menus
Reply With Quote #8

Nice !
Tartooob is offline
soccdoodcss
Veteran Member
Join Date: Nov 2006
Location: Wisconsin
Old 09-04-2007 , 23:26   Re: Custom Vote Menus
Reply With Quote #9

Wow I'm jealous...
__________________
"Now safe beneath their wisdom and their feet.
Here I will teach you truly how to sleep."
soccdoodcss is offline
Send a message via AIM to soccdoodcss
The-Bitter
New Member
Join Date: Oct 2007
Old 10-02-2007 , 09:54   Re: Custom Vote Menus
Reply With Quote #10

What do you mean with 1 menu per configs file??
should we create more votes files??
The-Bitter is offline
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 11:57.


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