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

[CSS] Jihad Suicide Bomb (.985) [Updated: 3/14/12]


Post New Thread Reply   
 
Thread Tools Display Modes
Author
TheVirus
Member
Join Date: Aug 2011
Plugin ID:
2578
Plugin Version:
.985
Plugin Category:
Fun Stuff
Plugin Game:
Counter-Strike: Source
Plugin Dependencies:
    Servers with this Plugin:
    2 
    Plugin Description:
    Allows players to wear suicide bombs. Mainly for Jail Break/Prison Break maps.
    Old 09-20-2011 , 14:06   [CSS] Jihad Suicide Bomb (.985) [Updated: 3/14/12]
    Reply With Quote #1

    About:
    Updated/Maintained version of MomentumMori's plugin: here.
    It's a remake of the old eventscript plugin (es_bombermod) in sourcemod. It gives players (CT or T) bombs which over time activates and then can be detonated.

    Features:
    • Unlimited bomb types available for purchase via {sm_jihad_buybomb}. Each of them having incremental AoE set by {sm_jihad_sizemultiplier}.
    • To define the amount of types (levels) available, see {sm_jihad_bomblevels}.
    • Prices are set by {sm_jihad_pricebase} and {sm_jihad_priceupgrade}.
    • After a bomb is bought, it activates after a given number of seconds set by {sm_jihad_predelay}. Deactivated bombs can not be used.
    • Players wearing an armed bomb will change color to RED. To activate or disable this feature, see {sm_jihad_coloronarmed}.
    • After a bomb is activated, it has a chance to fail upon detonation, set by {sm_jihad_failrate}, in which case it will automaticly rearm.
    • Before causing an actual explosion, a sound defined by {sm_jihad_postsoundpath} will be played and a delay before the explosion, to let the sound play, can be set by {sm_jihad_postdelay}. Setting the path to an empty string will not play any sound and setting the post delay to 0.0 will cancel any timing effect and the explosion will be instantaneous.
    • The explosion will not affect team members if {mp_friendlyfire} is set to 0.
    • Damage is standard for all bomb types. See {sm_jihad_explosiondamage}. Note that the wearer will not die if the damage is inferior to his health.
    • A limit can be set to restrain the amount of bombs present in each team at once. See {sm_jihad_bomblimitt} and {sm_jihad_bomblimitct}.
    • Another limit can be set to restrain the amount of times a player can buy a bomb during a single round. Useful for deathmatch servers. See {sm_jihad_bomblimitround}.

    New in this release:
    • Time limit to purchase a bomb (prevents buying a bomb during the middle of a round).
    • Lose bomb upon death.
    • Lose bomb upon map change.
    • Buy menu!
    • Random chance the bomb will explode if unused (prevents players from keeping and not using a bomb for a while). Default is 10% per round. Example, if they wear it for 1 round it's 10%, 2 rounds it's 20%, etc.
    • Enable/Disable buy menu through cvar.
    • Fixed radius! Thanks to namie for bringing this to my attention. - Please read the Changelog as this fix changes the way the bomb functions.
    • Added VIP discount. Supply a flag "s" and a discount amount "5000" and it will subtract it from the price.

    Commands:
    • sm_jihad_buybomb <0|N> - Buy a bomb or upgrade an existing one.
    • bomb <0|N> - Buy bomb
      • 0 - Upgrade
      • N - Level of the bomb to buy.

      It's recommended to bind a key to detonate:
      bind v "sm_jihad_detonate"
      This makes it easy to explode without having to worry about typing something in.
    • sm_jihad_detonate - Detonate your bomb, if any.
    • boom - Detonate your bomb, if any.

    Configuration:

    Sound:
    Drop the jihad.wav into cstrike/sound/jihad (create the jihad directory).

    Code:
    // This file was auto-generated by SourceMod (v1.3.5)
    // ConVars for plugin "jihadmod.smx"
    
    
    // Sets how many bomb types exists.
    // -
    // Default: "1"
    sm_jihad_bomblevels "1"
    
    // Sets how many CTs may carry a bomb at once.
    // -
    // Default: "0"
    sm_jihad_bomblimitct "0"
    
    // Sets how many time a player may buy a bomb per round.
    // -
    // Default: "1"
    sm_jihad_bomblimitround "1"
    
    // Sets how many Ts may carry a bomb at once.
    // -
    // Default: "1"
    sm_jihad_bomblimitt "1"
    
    // Sets whether the wearer of an armed bomb changes color.
    // -
    // Default: "0"
    sm_jihad_coloronarmed "0"
    
    // Sets whether the plugin is enabled or not.
    // -
    // Default: "1"
    sm_jihad_enable "1"
    
    // Sets the damage of the explosions.
    // -
    // Default: "400"
    sm_jihad_explosiondamage "400"
    
    // Sets the chance (in percent) that the bomb will fail to detonate.
    // -
    // Default: "0.25"
    sm_jihad_failrate "0.25"
    
    // Sets the delay (in seconds) before detonating the bomb.
    // -
    // Default: "1.0"
    sm_jihad_postdelay "1.0"
    
    // Sets the path of the sound to play after detonating the bomb. (Relative to the sound folder)
    // -
    // Default: "jihad/jihad.wav"
    sm_jihad_postsoundpath "jihad/jihad.wav"
    
    // Sets the delay (in seconds) before arming the bomb.
    // -
    // Default: "15.0"
    sm_jihad_predelay "15.0"
    
    // Sets the base price to buy a bomb.
    // -
    // Default: "15000"
    sm_jihad_pricebase "15000"
    
    // Sets the price to upgrade a bomb.
    // -
    // Default: "2500"
    sm_jihad_priceupgrade "2500"
    
    // Sets the radius of the explosions.
    // -
    // Default: "600"
    sm_jihad_sizemultiplier "600"
    
    // Version of the plugin.
    // -
    // Default: "0.981"
    sm_jihad_version "0.981"
    
    // Bomb Buy Time
    // -
    // Default: "10"
    sm_jihad_bombbuytime "10"
    
    //Random Explosion chance
    // -
    // Default: "10"
    sm_jihad_randomexplosion "10"
    
    //Enable (1) or Disable (0) the buy menu.
    // -
    // Default: "1"
    sm_jihad_enablemenu "1"
    
    //Set to 1 to have it ignore radius. This brings it back to the way the bomb worked before.
    // -
    // Default: "0"
    sm_jihad_ignoreradius "0"
    
    //Flag for VIPs. This will offer a discounted price.
    // -
    // Default: "s"
    sm_jihad_vipflag "s"
    
    //The amount to REMOVE from the base price for VIPs.
    // -
    // Default: "0"
    sm_jihad_vipdiscount "0"
    
    //Version of the plugin.
    // -
    //sm_jihad_version ".983"
    Planned:
    • Defuse/Armor kit for the CTs to use as passive protection against the bomb.

    Changelog:
    0.985 (3/14/12)
    • Added bomb/boom console command (works along side sm_jihad_buybomb/sm_jihad_detonate)

    0.984 (12/12/2011)
    • Forced T suicide when they use the bomb. Prevents the explosion from not killing them.

    0.983 (12/12/2011)
    • Added a VIP discount based on a custom flag.

    0.982 (12/8/2011)
    • Fixed a bug where Ts could spam the bomb.

    0.981 (12/7/2011)
    • Fixed the radius.
    • Fixed some KillTimer() errors.

    The fixed radius changes the bomb quite a bit. Since it was broken before, it determined the radius off of the magnitude (base damage). Now that it works, the radius requires a higher value to work like it used to. It's a tad weaker at 600 than it used to be, but I feel it's much more 'realistic' as you take less damage if they aren't right up to you. Feel free to play with the variables to find the right value for your server.

    0.96 (10/3/2011)
    • Fixed the bomb not re-arming after a new round on existing bombs.

    0.95 (09/23/2011)
    • Added option (sm_jihad_enablemenu) to enable/disable buy menu.
    • Fixed? the sm_jihad_version cvar.

    0.94 (09/20/2011)
    • First public release.

    Known Issues:
    • None, yet.

    All credit to MomentumMori and his effort in porting this over. I am simply keeping it updated/fixed for the people that play on our server. This is my first endeavor into Source Mod scripting, so please forgive me if I make obvious mistakes.

    Let me know if something is broken or you have any requests. Our server only uses 1 bomb for the T team, so I haven't tested it that much for the CTs, but everything should be the same.
    Attached Files
    File Type: zip jihad.zip (49.0 KB, 1403 views)
    File Type: sp Get Plugin or Get Source (sm_jihad-fix.sp - 2619 views - 23.9 KB)

    Last edited by TheVirus; 03-14-2012 at 11:01.
    TheVirus is offline
    kaskull
    Member
    Join Date: Nov 2010
    Old 09-20-2011 , 15:46   Re: [CSS] Jihad Suicide Bomb (.94)
    Reply With Quote #2

    Where top put this sound?
    __________________
    kaskull is offline
    Send a message via Skype™ to kaskull
    TheVirus
    Member
    Join Date: Aug 2011
    Old 09-21-2011 , 10:11   Re: [CSS] Jihad Suicide Bomb (.94)
    Reply With Quote #3

    Quote:
    Originally Posted by kaskull View Post
    Where top put this sound?
    Drop it in cstrike/sound/jihad (create the jihad directory).
    TheVirus is offline
    kaskull
    Member
    Join Date: Nov 2010
    Old 09-21-2011 , 10:57   Re: [CSS] Jihad Suicide Bomb (.94)
    Reply With Quote #4

    Is this for play normal game, or is a kind of mod to play specifical maps?
    __________________
    kaskull is offline
    Send a message via Skype™ to kaskull
    TheVirus
    Member
    Join Date: Aug 2011
    Old 09-21-2011 , 13:14   Re: [CSS] Jihad Suicide Bomb (.94)
    Reply With Quote #5

    Quote:
    Originally Posted by kaskull View Post
    Is this for play normal game, or is a kind of mod to play specifical maps?
    It can be used for a normal game, but it's meant for Prison Break maps where the prisoners need to kill the guards (T vs CT). It adds a little spice to the game.
    TheVirus is offline
    nightrider
    SourceMod Donor
    Join Date: Dec 2008
    Old 09-22-2011 , 02:27   Re: [CSS] Jihad Suicide Bomb (.94)
    Reply With Quote #6

    Thank you for the update.
    Can you make the purchase menu optional?
    as most players complain about the menu preventing the buy out at spawn.
    __________________
    [SIGPIC][/SIGPIC] the pantless
    I am the Night Rider!, I'm a fuel-injected suicide machine.
    I am a rocker! I am a roller!, I am an out-of-controller!


    nightrider is offline
    nightrider
    SourceMod Donor
    Join Date: Dec 2008
    Old 09-22-2011 , 04:37   Re: [CSS] Jihad Suicide Bomb (.94)
    Reply With Quote #7

    I found a quick way of defeating it.
    if T's are only allowed to purchase the jihad bomb in the sm_jihadmod.cfg file.

    // Sets how many CTs may carry a bomb at once.
    // -
    // Default: "0"
    sm_jihad_bomblimitct "0"



    Find this in the sm_jihad-fix.sp file
    replace canBuyBombT with canBuyBombCT
    It basically only checks for CT's


    Code:
                {
                    //Only care about T's and CT's
                    new Team:team = Team:GetClientTeam(i);
                    switch (team)
                    {
                        case 3: //CT
                        {
                            if (canBuyBombCT == 1)
                            {
                                ShowBuyMenu(i);
                            }
                        }
                        case 2: //T
                        {
                            if (canBuyBombT == 1)
                            {
                                ShowBuyMenu(i);
                            }
                        }
                    }
                }
    Replace with
    Code:
                {
                    //Only care about T's and CT's
                    new Team:team = Team:GetClientTeam(i);
                    switch (team)
                    {
                        case 3: //CT
                        {
                            if (canBuyBombCT == 1)
                            {
                                ShowBuyMenu(i);
                            }
                        }
                        case 2: //T
                        {
                            if (canBuyBombCT == 1)
                            {
                                ShowBuyMenu(i);
                            }
                        }
                    }
                }
    __________________
    [SIGPIC][/SIGPIC] the pantless
    I am the Night Rider!, I'm a fuel-injected suicide machine.
    I am a rocker! I am a roller!, I am an out-of-controller!



    Last edited by nightrider; 09-22-2011 at 04:39.
    nightrider is offline
    TheVirus
    Member
    Join Date: Aug 2011
    Old 09-22-2011 , 08:51   Re: [CSS] Jihad Suicide Bomb (.94)
    Reply With Quote #8

    I can add an option to make the buy menu optional.
    TheVirus is offline
    nightrider
    SourceMod Donor
    Join Date: Dec 2008
    Old 09-22-2011 , 12:52   Re: [CSS] Jihad Suicide Bomb (.94)
    Reply With Quote #9

    That would be great.
    Thank you for picking up support on this.
    __________________
    [SIGPIC][/SIGPIC] the pantless
    I am the Night Rider!, I'm a fuel-injected suicide machine.
    I am a rocker! I am a roller!, I am an out-of-controller!


    nightrider is offline
    Antithasys
    Moderator
    Join Date: Apr 2008
    Old 09-22-2011 , 18:12   Re: [CSS] Jihad Suicide Bomb (.94)
    Reply With Quote #10

    The public cvar (sm_jihad_version) you placed in the OP description does not exist in the plugin. Please include it in your plugin with the correct flags.

    Thanks,
    __________________
    [my plugins]

    When you think about asking a question... consider what have you tried?
    Antithasys 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 16:02.


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