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

[TF2] No Shotguns in BBall


Post New Thread Reply   
 
Thread Tools Display Modes
Author
trainRiderJ
New Member
Join Date: Jan 2009
Plugin ID:
726
Plugin Version:
1.0
Plugin Category:
Gameplay
Plugin Game:
Team Fortress 2
Plugin Dependencies:
    Servers with this Plugin:
     
    Plugin Description:
    Option to disable shotguns in any map with "bball" in the name
    Old 01-17-2009 , 22:10   [TF2] No Shotguns in BBall
    Reply With Quote #1

    This is a plugin that gives you the option to disable shotguns on any maps with "bball" in the name. Most of the credit for this plugin should go to the authors of these two plugins (I kept their names in my plugin):

    Only-melee
    https://forums.alliedmods.net/showthread.php?t=72077
    Authors: Aviram Hassan/Sp0on/Aviram1994

    Jump mode
    http://forums.alliedmods.net/showthread.php?p=671355
    Author: TheJCS

    Most popular BBall map for reference
    http://www.fpsbanana.com/maps/45633

    I modified the weapon restriction code from the "only-melee" plugin to only remove slot 2 (the shotgun slot), and I took the keyword recognition for map names from the "jump mode" plugin. Tweaked that a bit and then I was done. Not bad for only taking a semester of freshman comp-sci a few years ago

    Convars
    sm_noshotgun 0/1 - Defaults to 1 and allows you to turn off the mod if you wish (by setting it to 0)
    sm_bballmap 0/1 - Is set by the plugin whenever a new map is loaded. If the name of the map contains "bball", it is set to 1, otherwise 0

    Both convars have to be "1" in order to disable shotguns. Note that the plugin really disables all slot2 weapons, but bball is only played with soldiers and I'm only writing the plugin for people who intend to play the map that way. Also, if you enable/disable shotguns during a game, it won't take effect for each individual person until the next time they respawn.

    I've tested this plugin on my local machine and on a friend's server and believe it to be working fine. This is my first time doing anything like this, but I believe I covered all my bases. Please let me know if I'm missing anything!

    EDIT: Almost forgot, a big thanks to Mooga for helping me out with sourcemod and all the noobish stuff I needed to know, and Revalk for use of his server!
    Attached Files
    File Type: sp Get Plugin or Get Source (NoShotgunBBall.sp - 1551 views - 2.6 KB)
    File Type: smx NoShotgunBBall.smx (3.5 KB, 504 views)

    Last edited by trainRiderJ; 01-17-2009 at 22:12.
    trainRiderJ is offline
    MikeJS
    Senior Member
    Join Date: Nov 2008
    Old 01-18-2009 , 07:15   Re: [TF2] No Shotguns in BBall
    Reply With Quote #2

    If a player switches to soldier again in spawn they get their shotguns back again, but that doesn't really matter since there's no spawn rooms on bball
    MikeJS is offline
    bradsmokes
    New Member
    Join Date: May 2010
    Old 05-05-2010 , 01:38   Re: [TF2] No Shotguns in BBall
    Reply With Quote #3

    sounds good to me
    __________________
    smith
    bradsmokes 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 13:02.


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