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

[TF2] Broken Bottle Bleed


Post New Thread Reply   
 
Thread Tools Display Modes
Author
DarthNinja
SourceMod Plugin Approver
Join Date: Mar 2009
Location: PreThinkHook()
Plugin ID:
2482
Plugin Version:
1.0.3
Plugin Category:
Gameplay
Plugin Game:
Team Fortress 2
Plugin Dependencies:
    Servers with this Plugin:
     
    Plugin Description:
    Broken Demo Bottles have a chance to inflict bleed.
    Old 08-07-2011 , 09:49   [TF2] Broken Bottle Bleed
    Reply With Quote #1

    [TF2] Broken Bottle Bleed
    Version 1.0.3



    Description:
    Broken demo bottles have a chance to inflict bleed on the victim.

    Commands:
    • sm_break
      • Breaks your bottle. Mostly intended for debugging.
      • Requires "Slay" admin flag.

    Cvars:
    • sm_bbb_version
      • Plugin Version
    • sm_bbb_chance
      • Chance to inflict bleed. 1.00 = 100% chance, 0.50 = 50% chance, etc.
      • Default: 1.00
    • sm_bbb_time
      • Time to inflict bleed for.
      • Default: 5 seconds.

    Install Instructions:

    1. Place BrokenBottleBleed.smx into your addons/sourcemod/plugins/ folder.

    Notes:


    Version History:
    • V1.0.2
      • Initial Release
    • V1.0.3
      • Adds checks to make sure attacker and victim are valid clients (prevents an error).

    Total downloads as prior to last edit: 6

    Plugin will not compile on the forums due to custom includes! Download the .smx or compile it yourself locally!

    Attached Files
    File Type: smx BrokenBottleBleed.smx (3.9 KB, 1130 views)
    File Type: sp Get Plugin or Get Source (BrokenBottleBleed.sp - 776 views - 2.9 KB)
    __________________

    Last edited by DarthNinja; 08-07-2011 at 12:19.
    DarthNinja is offline
    JoBarfCreepy
    Member
    Join Date: Feb 2011
    Location: Next to Sweden and Norwa
    Old 08-07-2011 , 10:47   Re: [TF2] Broken Bottle Bleed
    Reply With Quote #2

    Should have been like this by default
    Edits:
    It works great, too.
    The Break command causes the bottle to be whole until you change weapons. Not a big issue, though.

    Last edited by JoBarfCreepy; 08-07-2011 at 11:02. Reason: Tested the plugin now.
    JoBarfCreepy is offline
    DarthNinja
    SourceMod Plugin Approver
    Join Date: Mar 2009
    Location: PreThinkHook()
    Old 08-07-2011 , 12:11   Re: [TF2] Broken Bottle Bleed
    Reply With Quote #3

    Quote:
    Originally Posted by JoBarfCreepy View Post
    The Break command causes the bottle to be whole until you change weapons
    Not a plugin problem.
    It's TF2 not "refreshing" the model since it doesn't know anything changed.

    Going to have an update in a second to fix a minor bug that causes an error.
    -Edit: Done
    __________________

    Last edited by DarthNinja; 08-07-2011 at 12:20.
    DarthNinja is offline
    JoBarfCreepy
    Member
    Join Date: Feb 2011
    Location: Next to Sweden and Norwa
    Old 08-07-2011 , 12:43   Re: [TF2] Broken Bottle Bleed
    Reply With Quote #4

    Quote:
    Originally Posted by DarthNinja View Post
    Not a plugin problem.
    Going to have an update in a second to fix a minor bug that causes an error.
    -Edit: Done
    I didn't see any errors but the one with the model. Also it works great on bots... if you hit them.

    Also this encourages use of bottles. It's especially useful for those who haven't got any demo melee weapons.

    Last edited by JoBarfCreepy; 08-14-2011 at 08:37.
    JoBarfCreepy is offline
    KyleS
    SourceMod Plugin Approver
    Join Date: Jul 2009
    Location: Segmentation Fault.
    Old 08-21-2011 , 17:50   Re: [TF2] Broken Bottle Bleed
    Reply With Quote #5

    In your OnTakeDamage hook, L47 attacker < 0 should be attacker <= 0. Your victim == attacker check could be a lot sooner, along with your IsClientInGame check on the victim at the very end. L66 is kind of useless and just invalidates a valid client index (victim < MaxClients should be victim <= MaxClients).

    PM me when this is addressed.
    KyleS is offline
    farruski
    Junior Member
    Join Date: Oct 2012
    Old 10-29-2012 , 06:28   Re: [TF2] Broken Bottle Bleed
    Reply With Quote #6

    Great Plugin Ninja

    Last edited by farruski; 10-29-2012 at 06:29.
    farruski is offline
    TheXeon
    Member
    Join Date: May 2016
    Old 10-23-2017 , 01:25   Re: [TF2] Broken Bottle Bleed
    Reply With Quote #7

    This is finally relevant again.
    TheXeon 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 21:19.


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