Raised This Month: $12 Target: $400
 3% 

Captains Plugin


Post New Thread Reply   
 
Thread Tools Display Modes
Plugin Info:     Modification:   ALL        Category:   Admin Commands       
EFFx
Veteran Member
Join Date: Feb 2016
Location: São Paulo, Brasil
Old 06-05-2017 , 19:31   Captains Plugin
Reply With Quote #1

CAPTAIN PLUGIN v1.5


Plugin release: 06/05/2017
Last update: 06/19/2017

- Description
I saw very newbies here asking for something like this. And one of them asked me in private to make another new system with Captain system. That system, has:

Code:
1. /start command for start the selection, the admin who used that command, can select two players, one will be
 the T captain and the  second the CT captain, thence, everything's normal.
2. When the admin selects those players, they  will spawn close one to one, the spawn can be changed manually 
( requires a LOT of knowledge about all MAP's location, guess nobody  knows it ) or with a menu. /spawnmenu 
for open it. The first coordinate, will be terrorist's coordinate. That coordinate, contains ORIGIN[0], ORIGIN[1], 
ORIGIN[2] + Angles and VAngles. When you select one, the menu will re-open for you  select the CT's origin.
3. Who win, can start to select his team first. Thence, normal.
4. The captains, have 15 seconds to select someone. If him didn't select, the oppost captain will select. 
5. The captains, can get a model, for be difference than others players. Thence, normal.
6. After the admin select two players, they must say .ready for start the duel.
7. Every spawn, on KnifeRound, the captains will get 100 helmet + kevlar, 0 money, no c4 plant, no weapons only the knife, obviously.
8. Noboby can change their team except the admin who has the required access.
9. It supports when the captain has disconneted. When it happens, another random player will be  selected. 
If ain't there any spectator for be selected, 15 seconds countdown will be showed. If it arrives 0, the  selection will end.
10. It supports admin disconnect too. If ain't there any admin, the match will finish if the selection is running, the same if both captains have disconnected.
- Amxmodx version required
I'm using AMX Mod X Compiler 1.8.3-dev+4739, guess it works on all 1.8.3+ and 1.8.2 too, didn't test on 1.8.2

- Cvars
From dir/addons/amxmodx/configs/CaptainsPlugin/cp_cvars.cfg:

Code:
; Captains Plugin cvars settings
; The plugin will use those values

; Turn on/off the plugin
; If you want to turn the plugin activated, set it 1, if not, 0
duel_enabled "1"

; Spawn both captains close when it's knife round
; If you want to turn it activate, set it 1, if not, 0
duel_close_kniferound_spawn "1"

; Min players to start the duel
; If the players num is less than this, the duel can not start, otherwise,  it can
duel_minplayers "10"

; The weapon that'll be used on knife round
; Currently types: deagle or knife, otherwise, it'll automatically be knife
duel_weapon_mode "knife"

; Players need to say .ready to start the duel
; If you want to turn it activated, set it 1, if not, 0
duel_ready "1"

; Captains needs to say !say or !switch to choose in which team they want to start first.
; If you want to turn it activated, set it 1, if not, 0
duel_choose_side "1"


echo Cvars loaded!
- Change log
Spoiler
Attached Files
File Type: zip Captains Plugin.zip (10.4 KB, 408 views)
__________________
• Ranking System • AutoMix 5vs5 System
• Web Ban System • Plugins for free

____________________________________________
For private works:
• Discord: EFFEXo#8850 • Steam: EFFEXo

Last edited by EFFx; 06-21-2017 at 18:27.
EFFx is offline
EFFx
Veteran Member
Join Date: Feb 2016
Location: São Paulo, Brasil
Old 06-05-2017 , 20:11   Re: Captain Mode
Reply With Quote #2

Released the version 1.1:

ºCode edited:
. Added duel_ready 1/0 - If you want not the .ready feature, turn this 0.
. Added duel_weapon_mode deagle/knife - If you want the duel with desert deagles, set it as 'deagle', if you wwant the duel with
knives, set it as 'knife'.
. Removed the spawnVictim() unecessary function.
. Bit optimizations at players_list2_handler handler.
. Added set_task() at for re-open the menu when the captain accidentally or purposely has closed the menu.
. Removed TASK_DUEL_TYPE, TASK_PLAYER_RESPAWN, unecessary constants.
. And bit optimizations in some functions.
__________________
• Ranking System • AutoMix 5vs5 System
• Web Ban System • Plugins for free

____________________________________________
For private works:
• Discord: EFFEXo#8850 • Steam: EFFEXo
EFFx is offline
Houssam Benmouna
Senior Member
Join Date: Apr 2016
Old 06-06-2017 , 13:32   Re: Captain Mode
Reply With Quote #3

Good job :d nice mod
Houssam Benmouna is offline
EFFx
Veteran Member
Join Date: Feb 2016
Location: São Paulo, Brasil
Old 06-08-2017 , 20:39   Re: Captains Plugin
Reply With Quote #4

Released the version 1.2:

ºCode edited:
. Added a start-duel hud showing T captain's name and CT captain's name.
. Added the deagle's ammo when the cvar 'duel_weapon_mode' is 'deagle'.
. Added a code to reset the tPlayersNum's task when a random player is selected after some captain left.
. Adjusted the szWeapoName size to 17.
. Added a check at Round_Restart() logevent.
. Removed the eLive unecessary enumerate.
. Added auto-respawn after dying when it's eSelection.
__________________
• Ranking System • AutoMix 5vs5 System
• Web Ban System • Plugins for free

____________________________________________
For private works:
• Discord: EFFEXo#8850 • Steam: EFFEXo

Last edited by EFFx; 06-08-2017 at 20:39.
EFFx is offline
EFFx
Veteran Member
Join Date: Feb 2016
Location: São Paulo, Brasil
Old 06-11-2017 , 14:09   Re: Captains Plugin
Reply With Quote #5

Released the version 1.3:

ºCode edited:
. Added g_bFileExists boolean to check if the map's .ini file exists and spawn both captains correctly.
. Bit optimizations
. Added g_szChatPrefix into the ChatColor stock.
. Added log_amx() instead of write_file() at loadSpawns() stock.
. Fixed the get_players() format on checkTeamsNumber() stock and set it as boolean.
. Fixed the players selection feature.
. Added all spawn feature with Ham_Spawn instead of spawnPlayers().
. Added g_bDidntSelected for check if both captains missed the selection. If they do that, the choice will end.
__________________
• Ranking System • AutoMix 5vs5 System
• Web Ban System • Plugins for free

____________________________________________
For private works:
• Discord: EFFEXo#8850 • Steam: EFFEXo

Last edited by EFFx; 06-11-2017 at 14:10.
EFFx is offline
Old 06-12-2017, 04:31
Craxor
This message has been deleted by Craxor. Reason: misunderstood...
EFFx
Veteran Member
Join Date: Feb 2016
Location: São Paulo, Brasil
Old 06-14-2017 , 14:47   Re: Captains Plugin
Reply With Quote #6

Released the version 1.4:

ºCode edited:
. Added !stay and !switch command for the captain that won the knife round for start on which team he want.
. Added IsNotSpec() macro.
. Added 4 seconds delay for show captains' name at Round_Restart() instead of instant-show.
. More about !stay and !switch:
If the captain that won the knife round don't say !stay or !switch, there's a countdown that starts from 15 to 0. If it arrives 0,
the player will say a random command.
. The g_bIsSelected is only reseted when the bIsForResetCaptainID is true.
. Added checkPlayersTasks() stock for check if when the player has left and he has tasks running, the stock'll kill that.
. Fixed a log error when any captain type .ready in the chat.
. Added 'duel_close_kniferound_spawn' to spawn all two captains close when it's 1.
. Bit optimizations
__________________
• Ranking System • AutoMix 5vs5 System
• Web Ban System • Plugins for free

____________________________________________
For private works:
• Discord: EFFEXo#8850 • Steam: EFFEXo
EFFx is offline
shehzad1234
BANNED
Join Date: Jan 2016
Location: https://t.me/pump_upp
Old 06-14-2017 , 16:31   Re: Captains Plugin
Reply With Quote #7

Gj. <3
shehzad1234 is offline
Send a message via ICQ to shehzad1234 Send a message via AIM to shehzad1234 Send a message via Yahoo to shehzad1234
Craxor
Veteran Member
Join Date: Jan 2016
Location: Romania
Old 06-17-2017 , 01:31   Re: Captains Plugin
Reply With Quote #8

This is your X-Miliard-Plugin Posted .
__________________
Project: Among Us
Craxor is offline
Send a message via ICQ to Craxor
EFFx
Veteran Member
Join Date: Feb 2016
Location: São Paulo, Brasil
Old 06-17-2017 , 13:52   Re: Captains Plugin
Reply With Quote #9

People never stop asking plugins, so everytime I see someone asking something that's cool and unique, I post it.
__________________
• Ranking System • AutoMix 5vs5 System
• Web Ban System • Plugins for free

____________________________________________
For private works:
• Discord: EFFEXo#8850 • Steam: EFFEXo
EFFx is offline
Natsheh
Veteran Member
Join Date: Sep 2012
Old 06-17-2017 , 17:14   Re: Captains Plugin
Reply With Quote #10

Glad you give your work for free.
__________________
@Jailbreak Main Mod v2.7.0 100%
@User Tag Prefix 100% done !
@Mystery Box 100% done !
@VIP System 100% done !

Natsheh is offline
Send a message via MSN to Natsheh Send a message via Skype™ to Natsheh
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:35.


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