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

[TF2] Trail Gun (v1.0, 9-1-2018)


Post New Thread Reply   
 
Thread Tools Display Modes
Author
Nanochip
Senior Member
Join Date: Jan 2014
Plugin ID:
6243
Plugin Version:
1.0
Plugin Category:
Fun Stuff
Plugin Game:
Team Fortress 2
Plugin Dependencies:
    Servers with this Plugin:
     
    Plugin Description:
    This is a cosmetic plugin for server donors which allows them to shoot props with trails out of their gun.
    Old 09-01-2018 , 23:45   [TF2] Trail Gun (v1.0, 9-1-2018)
    Reply With Quote #1

    [TF2] Trail Gun



    Description:
    This is a cosmetic plugin for server donors which allows them to shoot props with trails out of their gun.
    Props will be despawned after a short amount of time and only root admins can spam shoot.

    Dependencies:
    Video Demonstration:


    CVARS:
    Listed in your cfg/sourcemod/plugin.trailgun.cfg (which is generated when the plugin is loaded)
    • sm_trailgun_weapon - (Default: tf_weapon_flaregun) What weapon(s) is/are used as the trail gun? Separate classnames with a comma. Put "all" if you want all weapons to be considered as a trailgun.
    • sm_trailgun_weapon_slot - (Default: -1) Which weapon slot should the trailgun be used on? -1 = All weapon slots are allowed, 0 = Primary Slot, 1 = Secondary Slot, 2 = Melee Slot
    • sm_trailgun_button - (Default: 2) Which button shoots the trail gun? 1 = +attack, 2 = +attack2, 3 = +attack3, 4 = +use
    • sm_trailgun_despawn_time - (Default: 6) After a prop & trail is shot out of the gun, how many seconds till it despawns?
    • sm_trailgun_delay - (Default: 4.0) Time in seconds before a prop can be shot again. Use the command override below to set who can bypass this cvar.

    Command:
    • sm_trailgun - (Default Access: ADMFLAG_RESERVATION) Opens the Trail Gun menu.

    Command Override:
    This would go in your addons/sourcemod/configs/admin_overrides.cfg
    • sm_trailgun_override_delay - (Default Access: ADMFLAG_ROOT) This is the override to bypass the sm_trailgun_delay cvar (meaning there's no delay).

    Developer Native:
    PHP Code:
    /**
     * Does the player have the trailgun enabled?
     *
     * @param1        client - player's client index
     * @return        True if the player has it enabled, false otherwise
     */
    native bool TG_Enabled(int client); 
    Installation:
    1. Install Sourcemod.
    2. Install VPhysics extension.
    3. Download the plugin at the bottom of the post.
    4. Extract the zip to your addons/sourcemod/ folder.
    5. Restart the server.

    To-Do List:
    • Add support for custom trails and props
    • Suggest more

    Changelog:
    Spoiler




    ➤Download
    ➤Source
    ➤GitLab



    __________________

    Last edited by Nanochip; 09-21-2018 at 20:42.
    Nanochip is offline
    PC Gamer
    Veteran Member
    Join Date: Mar 2014
    Old 09-02-2018 , 09:47   Re: [TF2] Trail Gun (v1.0, 9-1-2018)
    Reply With Quote #2

    How did you get the vphysics extension to load? It doesn't load on my TF2 server with sourcemod version 1.9.0.6251

    Quote:
    L 09/02/2018 - 086:16: [SM] Unable to load plugin "trailgun.smx": Required extension "VPhysics" file("vphysics.ext") not running
    Update: Now works great! Solution: Must restart server after installing vphysics. A simple map change isn't enough to force it to load.

    Last edited by PC Gamer; 09-02-2018 at 13:28.
    PC Gamer is offline
    Nanochip
    Senior Member
    Join Date: Jan 2014
    Old 09-02-2018 , 10:32   Re: [TF2] Trail Gun (v1.0, 9-1-2018)
    Reply With Quote #3

    Quote:
    Originally Posted by PC Gamer View Post
    How did you get the vphysics extension to load? It doesn't load on my server with sourcemod version 1.9.0.6251
    Hmm not sure, it loads fine for me and I'm on 6251 as well.
    __________________
    Nanochip is offline
    Dagothur
    Member
    Join Date: Dec 2014
    Old 09-02-2018 , 11:20   Re: [TF2] Trail Gun (v1.0, 9-1-2018)
    Reply With Quote #4

    Quote:
    Originally Posted by PC Gamer View Post
    How did you get the vphysics extension to load? It doesn't load on my TF2 server with sourcemod version 1.9.0.6251
    did you check 'sm exts list'? sometimes it shows what the issue is there
    Dagothur is offline
    Dagothur
    Member
    Join Date: Dec 2014
    Old 09-02-2018 , 12:44   Re: [TF2] Trail Gun (v1.0, 9-1-2018)
    Reply With Quote #5

    For those of us who don't read and follow your instructions you might want to change the LogErrors to SetFailStates ("Host_Error: Bad string: ?" crash if the config files aren't present)

    Last edited by Dagothur; 09-02-2018 at 12:44.
    Dagothur is offline
    Reply



    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 06:53.


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