Raised This Month: $115 Target: $400
 28% 

KnifeSyphon


Post New Thread Reply   
 
Thread Tools Display Modes
Author
bl4nk
SourceMod Developer
Join Date: Jul 2007
Plugin ID:
135
Plugin Version:
1.8
Plugin Category:
Fun Stuff
Plugin Game:
Any
Plugin Dependencies:
    Servers with this Plugin:
    63 
    Plugin Description:
    Rewards players with a health boost for killing with a melee weapon.
    Old 08-13-2007 , 22:44   KnifeSyphon
    Reply With Quote #1

    KnifeSyphon

    Gives players a health boost when they make a knife kill.

    CVars:
    • sm_knifesyphon_enable - Enables\Disables the KnifeSyphon plugin.
      • 0 = off
      • 1 = on (default)
    • sm_knifesyphon_announce - Enables\Disables announcing of the plugin at the beginning of the round.
      • 0 = off
      • 1 = on (default)
    • sm_knifesyphon_life - Amount of life to give to the killer.
      • Ranges from 0 to 100. (default = 25)
    Notes:
    • This mod currently supports the following mods:
      • Counter-Strike: Source
      • Day of Defeat: Source
      • Half-Life 2: Deathmatch
      • Any mod that uses knife as it's melee weapon.
    • If sm_knifesyphon_announce is set to 1 and sm_knifesyphon_enable is set to 0, the plugin will not announce.
    Thanks to:
    • 1695 for requesting the plugin.
    • pRED* | NZ for help with fixing my translation problems.
    • FlyingMongoose for writing the KnifeMug plugin.
    • blue zebra for de/hu translations
    • noPASARAN for ru translations
    Changelog:
    • 1.0
      • Initial Release
    • 1.1
      • Added support for other mods that use 'knife' as a weapon.
      • Shortened the length of the announcement.
    • 1.2
      • Added weapon support for DOD:S and HL2:MP.
      • Added announcement support for DOD:S.
    • 1.3
      • Removed unnecessary code.
      • Changed announcement from each round to the first time the player spawns.
    • 1.4
      • Cvar changes are hooked regardless of default setting (see this post for details).
    • 1.5
      • Plugin will no longer announce if sm_knifesyphon_announce is set to 1 and sm_knifesyphon_enable is set to 0.
    • 1.6
      • Fixed announcement problems.
      • Colorized messages.
    • 1.7
      • Fixed bug where killing with any weapon netted extra HP.
      • Fixed bug where shooting somebody gave HP.
      • Made announcements work properly (without errors!)
      • Shortened the translations a bit (need new ones please) to fit one one line
      • Added TF2 support
    • 1.8
      • Added support for new TF2 weapons:
        • The Sandman
        • The Axtinguisher
        • KGB
        • Ubersaw
    Attached Files
    File Type: txt knifesyphon.phrases.txt (660 Bytes, 1481 views)
    File Type: sp Get Plugin or Get Source (knifesyphon.sp - 4097 views - 5.0 KB)

    Last edited by bl4nk; 04-13-2011 at 13:59.
    bl4nk is offline
    FlyingMongoose
    Veteran Member
    Join Date: Mar 2004
    Old 08-14-2007 , 00:52   Re: KnifeSyphon
    Reply With Quote #2

    To make this plugin more universal throw this into it instead of CCSPlayer::m_iHealth:

    Code:
    stock SetClientHealth(client, amount) {     new HPOffs = FindDataMapOffs(client,"m_iHealth");     SetEntData(client,HPOffs,amount,true); }

    Most mods use the word "knife" for their knife identification and usually identifying the weapon only requires part of the name, so "knife" will suffice throughout most mods including dods, and css
    __________________
    Please do NOT PM for support.

    Only ask for support in plugin threads.

    TunedChaos.com - Precision Tuned Game Servers
    FlyingMongoose is offline
    bl4nk
    SourceMod Developer
    Join Date: Jul 2007
    Old 08-14-2007 , 01:44   Re: KnifeSyphon
    Reply With Quote #3

    Good idea, FlyingMongoose.

    Updated to version 1.1
    bl4nk is offline
    dalto
    Veteran Member
    Join Date: Jul 2007
    Old 08-14-2007 , 01:57   Re: KnifeSyphon
    Reply With Quote #4

    If it's helpful, here is what quakesounds defines as a "knife"

    CS:S
    knife

    DOD:S
    spade
    amerknife
    punch

    HL2M
    stunstick
    crowbar
    dalto is offline
    bl4nk
    SourceMod Developer
    Join Date: Jul 2007
    Old 08-14-2007 , 03:50   Re: KnifeSyphon
    Reply With Quote #5

    Thanks for that, dalto. It seems that it wouldn't have worked very well with "knife" as the only weapon afterall (at least for those two mods).

    Updated to version 1.2
    bl4nk is offline
    1695
    Senior Member
    Join Date: Jan 2006
    Old 08-14-2007 , 04:16   Re: KnifeSyphon
    Reply With Quote #6

    Woah, quick lol !

    thx a lot !
    1695 is offline
    bolinux
    Member
    Join Date: Jul 2007
    Old 08-14-2007 , 05:33   Re: KnifeSyphon
    Reply With Quote #7

    sm_knifesyphon_announce is set to 0 but still shown in chat!

    Quote:
    cvarlist sm_knifesyphon_announce
    cvar list
    --------------
    sm_knifesyphon_announce : 0 : : Enables/Disables the KnifeSyphon announcement at the beginning of the round.
    btw nice plugin
    bolinux is offline
    bolinux
    Member
    Join Date: Jul 2007
    Old 08-14-2007 , 11:00   Re: KnifeSyphon
    Reply With Quote #8

    same at sm_knifesyphon_enable 0 announce is still shown in chat!

    --------------
    sm_knifesyphon_enable : 0 : : Enables/Disables the KnifeSyphon plugin.
    --------------
    bolinux is offline
    ^BuGs^
    Senior Member
    Join Date: May 2007
    Old 08-14-2007 , 15:56   Re: KnifeSyphon
    Reply With Quote #9

    Update StrEqual with strcmp. StrEqual is old school checking.
    __________________
    Sourcemod Plugin Author and Plugin Approver
    "The correct way is MAXPLAYERS + 1"
    I will not take bugs/new idea reports over the forums. Please use the issue list.
    ^BuGs^ is offline
    Kaschenko
    SourceMod Donor
    Join Date: Apr 2006
    Location: Country: Russia; City: M
    Old 08-14-2007 , 16:18   Re: KnifeSyphon
    Reply With Quote #10

    correct please
    "dod_round"?
    Attached Thumbnails
    Click image for larger version

Name:	error.jpg
Views:	695
Size:	82.4 KB
ID:	19099  
    __________________

    Last edited by Kaschenko; 08-14-2007 at 16:20.
    Kaschenko is offline
    Send a message via ICQ to Kaschenko Send a message via MSN to Kaschenko Send a message via Skype™ to Kaschenko
    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 17:44.


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