Monthly Target: $400 Donations: $147
 36% 

TF2 Ammopacks


Post New Thread Reply   
 
Thread Tools Display Modes
Author
[NATO]Hunter
Member
Join Date: Jul 2006
Location: Germany, NRW, Oberhausen
Plugin ID:
248
Plugin Version:
1.2.4
Plugin Category:
Fun Stuff
Plugin Game:
Team Fortress 2
Plugin Dependencies:
    Servers with this Plugin:
    52 
    Plugin Description:
    Allows engineers to drop ammopacks on death or with secondary Wrench fire.
    Old 01-06-2008 , 17:46   TF2 Ammopacks
    Reply With Quote #1

    Description

    This plugin allows engineers to drop Ammopacks on death or with secondary Wrench fire. You can choose between 3 modes, the first one will only make Engineers drop an Ammopack on death. The second mode will allow engineers to use their Wrench with the alternative fire to drop Ammopacks and pay for them with Metal. And the last mode brings the first and second mode together.

    The plugin is an appendix to my TF2 Medipacks plugin.

    Admins are also able to change an Engineers current Metal amount/level and set it to a value between 0 and 200.

    Thanks to [gh]ferret who helped me a lot getting this thing done. Another thanks goes to GreyScale who pointed me into the right direction about how to find the current weapon. And the last thanks goes to GODJonez for helping me with the vector stuff and pointing me into the right directions, too. I hope you enjoy this plugin!

    ConVars

    sm_ammopacks 3 - Enable/Disable ammopacks (0 = disabled | 1 = on death | 2 = on command | 3 = on death and command)
    sm_ammopacks_small 50 - Metal required for small Ammopacks
    sm_ammopacks_medium 100 - Metal required for medium Ammopacks
    sm_ammopacks_full 200 - Metal required for full Ammopacks
    sm_ammopacks_team 3 - Team to drop Ammopacks for. (0 = any team | 1 = own team | 2 = opposing team | 3 = own on command, any on death)
    sm_ammopacks_keep 60 - Time to keep Ammopacks on map. (0 = off | >0 = seconds)
    sm_ammopacks_limit 100 - Maximum number of extra Ammopacks on map at a time. (0 = unlimited)

    Commands

    sm_ammopack - Can be used by any Engineer as an alternative to +attack2 (secondary fire)
    sm_metal - Admin Flag: cheats (default 'n') - Usage: sm_metal <name|#userid> [amount]

    Installation

    Put ammopacks.smx in addons\sourcemod\plugins\
    Put ammopacks.phrases.txt in addons\sourcemod\translations\

    Changelog

    Version 1.2.4 - 30.05.2009
    - Fixed: Ammopacks counter not handling map/round starts and player pickups, thanks Uranium235.

    Version 1.2.3 - 29.05.2009
    - Fixed: Ammopacks counter was not decreased, thanks Uranium235.

    Version 1.2.2 - 27.05.2009
    - Added: sm_ammopacks_limit limits maximum number of extra Ammopacks on map at a time. (0 = unlimited), thanks naris.
    - Added: sm_ammopacks_team 3 to drop Ammopacks for own team on command, but any team on death, thanks naris.
    - Added: Native interface to control the plugin, thanks naris.
    - Changed: Ammopack creation times are now stored in a dynamic array.
    - Changed: Non-Ammopack entities are not removed by the plugin anymore, thanks naris.
    - Changed: Player class is not cached anymore, allows other plugins to temporary make someone an Engineer, thanks naris.

    Version 1.2.0 - 29.12.2008
    - Cleanup release.
    - The player messages are now send once, thanks Antithasys.

    Version 1.1.0 - 03.08.2008
    - Config file is now written: cfg/plugin.ammopacks.cfg
    - Fixed: Errors related to GetEntityNetClass

    Version 1.0.6 - 12.06.2008
    - Fixed: Errorlog being spammed.

    Version 1.0.5 - 12.05.2008
    - Fixed: Hopefully fixed random crash errors by using new entity natives.
    - Added: sm_ammopacks_team 0 - Team to drop Ammopacks for. (0 = any team | 1 = own team | 2 = opposing team)

    Version 1.0.4 - 09.02.2008
    - Changed: Setting the required Metal for a Ammopack to 0 does now disable that pack.

    Version 1.0.3 - 25.01.2008
    - Fixed: Server could crash if player_death was fired after the player left the server.
    - Changed: Added a warning about the entity limit and a error message that will be written into the SourceMod logs.
    - Changed: Optimized the parameters passed around the spawn stocks.

    Version 1.0.2 - 07.01.2008
    - Added: sm_ammopacks_keep allows you to specify the amount of seconds a pack stays on the map. (60 = default, 0 = off)
    - Added: If an Ammopack times out (see above) it will disappear with a nice sound.
    - Changed: Set default value of sm_ammopacks_full from 150 to 200.

    Version 1.0.1 - 07.01.2008
    - Fixed: Server crashing if Entity limit was reached. (Now there will be no new Ammopacks in that case.)

    Version 1.0.0 - 06.01.2008
    - Initial release.

    Have Fun!
    Attached Files
    File Type: txt ammopacks.phrases.txt (1.5 KB, 3233 views)
    File Type: sp Get Plugin or Get Source (ammopacks.sp - 4227 views - 16.7 KB)
    __________________


    Last edited by [NATO]Hunter; 05-30-2009 at 07:21. Reason: New version 1.2.4
    [NATO]Hunter is offline
    Greyscale
    SourceMod Plugin Approver
    Join Date: Dec 2007
    Location: strYoMommasHouse[you];
    Old 01-06-2008 , 18:14   Re: TF2 Ammopacks
    Reply With Quote #2

    Awesome idea
    Greyscale is offline
    Originengel
    Junior Member
    Join Date: Nov 2007
    Old 01-06-2008 , 20:13   Re: TF2 Ammopacks
    Reply With Quote #3

    Hello, Me, the persistent issue person. I have your plugin working, near perfect except one issue.. After an X amount of time, the server crashes with the use of both this and medipacks. It seems to be caused after a certain amount of medipacks/ammopacks have been spawned... Even if they are removed from the server. I.E. picked up, or degrade. Thanks.... P.S. Its about 100~ or so and it crashes.
    Originengel is offline
    ThatGuy
    Senior Member
    Join Date: Nov 2007
    Old 01-06-2008 , 20:24   Re: TF2 Ammopacks
    Reply With Quote #4

    Quote:
    Originally Posted by Originengel View Post
    Hello, Me, the persistent issue person. I have your plugin working, near perfect except one issue.. After an X amount of time, the server crashes with the use of both this and medipacks. It seems to be caused after a certain amount of medipacks/ammopacks have been spawned... Even if they are removed from the server. I.E. picked up, or degrade. Thanks.... P.S. Its about 100~ or so and it crashes.
    Only when they're combined?


    This should alltogethor be one plugin.
    ThatGuy is offline
    [NATO]Hunter
    Member
    Join Date: Jul 2006
    Location: Germany, NRW, Oberhausen
    Old 01-07-2008 , 04:27   Re: TF2 Ammopacks
    Reply With Quote #5

    I posted in the other thread about the crash issue.

    ThatGuy, no. I think one of the key features of SourceMod is it's modularity and the fact that you can deactivate everything you don't need. Both of my plugins do something on each GameFrame and add to the servers performance. Even if they are combined, the same 2 checks would run in a GameFrame. You see what I mean?
    __________________

    [NATO]Hunter is offline
    MoggieX
    Veteran Member
    Join Date: Aug 2007
    Location: n00bville
    Old 01-08-2008 , 09:04   Re: TF2 Ammopacks
    Reply With Quote #6

    Again tested with our pair of 32 slot servers and they work a treat with this addon, having the extra ammo sure helps!

    Again, menu integration woudl be a nice thing to add, but thats all :-)

    Matt
    __________________
    MoggieX is offline
    Send a message via Skype™ to MoggieX
    CrimsonGT
    Veteran Member
    Join Date: Oct 2007
    Location: Gainesville, FL
    Old 01-08-2008 , 14:36   Re: TF2 Ammopacks
    Reply With Quote #7

    I am actually working on getting a TFC Remakes Server setup on my Dedicated box (running 2fort, dustbowl, and the good TFC remakes) and I think it would be a lot of cool to use this. Is there any way to set it so anyone can drop an ammo pack, but to prevent people from helping an engi get an SG up very quickly make it so the ammo packs use all of the persons ammo or something? Thought it would be kind of cool to bring that aspect of TFC back on a TFC remakes server :-P
    CrimsonGT is offline
    tcviper
    BANNED
    Join Date: Oct 2005
    Location: Netherlands
    Old 01-08-2008 , 16:53   Re: TF2 Ammopacks
    Reply With Quote #8

    Engineers cant give ammo packs in plenty of they dont have ammo ;)
    tcviper is offline
    Send a message via MSN to tcviper
    CrimsonGT
    Veteran Member
    Join Date: Oct 2007
    Location: Gainesville, FL
    Old 01-19-2008 , 03:26   Re: TF2 Ammopacks
    Reply With Quote #9

    Im just talking about would it be possible to make it so when anyone presses G, it drops an ammo pack, but takes away like half of their ammo unless its an Engi, then it would just take away his metal?
    CrimsonGT is offline
    CrimsonGT
    Veteran Member
    Join Date: Oct 2007
    Location: Gainesville, FL
    Old 01-22-2008 , 08:54   Re: TF2 Ammopacks
    Reply With Quote #10

    NATO, is there anyway you could add that or tell me how to?
    CrimsonGT 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 22:28.


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