Raised This Month: $32 Target: $400
 8% 

[TF2] Team Fortress: Global Offensive (v1.4.6, 2021-01-18)


Post New Thread Reply   
 
Thread Tools Display Modes
Author
Mikusch
AlliedModders Donor
Join Date: Oct 2019
Location: Germany
Plugin ID:
7266
Plugin Version:
1.4.6
Plugin Category:
Gameplay
Plugin Game:
Team Fortress 2
Plugin Dependencies:
    Servers with this Plugin:
     
    Plugin Description:
    Team Fortress: Global Offensive
    Old 08-20-2020 , 10:51   [TF2] Team Fortress: Global Offensive (v1.4.6, 2021-01-18)
    Reply With Quote #1

    Team Fortress: Global Offensive
    Because Gun Mettle wasn't enough.
    Click image for larger version

Name:	tfgo.png
Views:	240
Size:	2.4 KB
ID:	183283

    What exactly is this?
    TF:GO brings the bomb defusal mode from Counter-Strike: Global Offensive to Team Fortress 2 Arena.
    All players begin the game with basic weapons and can buy new equipment at the start of each round with money earned from neutralizing enemy players or planting the bomb.

    This was my first attempt to create a SourceMod plugin, with no prior knowledge of SourcePawn.
    You can find the source code and download links over on the GitHub repository.

    Features
    • Similar gameplay to Counter-Strike: Global Offensive's bomb defusal mode
    • Easy-to-use buy menu
    • Support for a wide range of arena maps
    • Critical headshots on weapons like pistols, SMGs and revolvers
    • Highly configurable using the plugin configuration and cvars
    • Support for custom music kits
    • Support for custom map voting plugins

    Configuration
    TF:GO uses a single configuration file (sourcemod/configs/weapons.cfg) to define properties for each weapon. It allows you to change their cost in the buy menu, the amount of cash you get per kill, and even if they are capable of dealing critical hits on headshots. The default values should work for most use cases but if you feel like something needs to be changed, it's as easy as editing a single value.

    Weapon configuration example:
    PHP Code:
    "209"    // Pistol (Scout/Engineer)
    {
        
    "kill_award"        "300"
        "armor_penetration"    "0.475"
        "is_default"        "1"
        "can_headshot"        "1"
        "reskins"        "160;294;15013;15018;15035;15041;15046;15056;15060;15061;15100;15101;15102;15126;15148;30666"

    Everything not related to weapons is available as a cvar for you to configure. The available cvars should cover pretty much everything you might want to configure but feel free to tell me if something is missing.

    Cvar List:
    Code:
    tfgo_free_armor
    tfgo_max_armor
    tfgo_buytime
    tfgo_consecutive_loss_max
    tfgo_bombtimer
    tfgo_halftime
    tfgo_startmoney
    tfgo_maxmoney
    tfgo_cash_player_bomb_planted
    tfgo_cash_player_bomb_defused
    tfgo_cash_player_killed_enemy_default
    tfgo_cash_player_killed_enemy_factor
    tfgo_cash_team_elimination
    tfgo_cash_team_loser_bonus
    tfgo_cash_team_win_by_time_running_out_bomb
    tfgo_cash_team_loser_bonus_consecutive_rounds
    tfgo_cash_team_terrorist_win_bomb
    tfgo_cash_team_win_by_defusing_bomb
    tfgo_cash_team_planted_bomb_but_defused
    If this is too much for you to configure, you can check out the included configuration files in the cfg folder, namely tfgo_competitive.cfg and tfgo_casual.cfg. They also contain some other TF2 cvars that you may want to change. Both configurations play quite differently, so go try them out.

    Music Kits
    What would CS:GO be without music kits?
    TF:GO allows you to add custom music kits using the power of soundscripts. You can find two natives in tfgo.inc that allow you to register and use custom music kits.
    PHP Code:
    /**
     * Registers a new music kit with the specified name and soundscript.
     *
     * @param name        Name of the music kit.
     * @param path        Path to the soundscript text file.
     * @param isDefault    Whether this music kit can be randomly assigned to players as a default kit.
     * @param precache    Whether to precache the sounds in this music kit. All music kit sounds are automatically precached on map start.
     */
    native void TFGO_RegisterMusicKit(const char[] name, const char[] pathbool isDefault falsebool precache false);

    /**
     * Sets the active music kit for a client.
     * The music kit passed must be registered prior using TFGO_RegisterMusicKit.
     *
     * @param client    Client index.
     * @param name        Name of the music kit.
     */
    native void TFGO_SetClientMusicKit(int client, const char[] name); 
    PHP Code:
    #undef REQUIRE_PLUGIN
    #include <tfgo>

    public void OnLibraryAdded(const char[] name)
    {
        if (!
    StrEqual(name"tfgo"))
            return;
        
        
    //Registers a new music kit called "darude_01" using the provided soundscript
        
    TFGO_RegisterMusicKit("darude_01""sound/tfgo/music/darude_01/game_sounds_music.txt"falsetrue);

    Custom Map Vote Support
    If you are a server operator and use a non-standard map voting plugin, you can integrate it directly into TF:GO with minimal code.
    I don't want to go too in-depth with this as the code will look different for every map voting plugin but you should know that these natives exist.
    PHP Code:
    /**
     * Called when the game has entered half-time.
     * Intended to be used with map voting plugins to allow a vote to start.
     *
     * @note This forward does not get called if tfgo_halftime is set to 0.
     */
    forward void TFGO_OnHalfTimeStarted();

    /**
     * Called repeatedly when the game is about to leave half-time.
     * Intended to be used with map voting plugins, this forward should return false if a vote is still in progress.
     *
     * @note This forward does not get called until the initial half-time duration (tfgo_halftime_duration) has elapsed.
     * @note This forward does not get called if tfgo_halftime is set to 0.
     *
     * @return    true if the half-time should end, false if it shouldn't end and call this forward again.
     */
    forward bool TFGO_HasHalfTimeEnded();

    /**
     * Called when the game is about to switch or scramble the teams after half-time.
     * 
     * @note This forward gets called regardless of the current value of the tfgo_halftime_scramble convar.
     *
     * @return    true if the teams should be switched or scrambled, false if not.
     */
    forward bool TFGO_ShouldSwitchTeams(); 
    Installation
    1. Grab the latest release from the download link at the bottom of the page.
    2. Extract the contents of the archive into the tf folder of your server.
    3. Install all the required dependencies listed below.
    4. Restart your server or run sm plugins load tfgo and sm_reload_translations.
    5. Load any arena map.

    Dependencies

    Did I forget to mention something?
    Tell me, and I'll add it onto the thread.

    Download from GitHub

    Last edited by Mikusch; 01-18-2021 at 07:39.
    Mikusch is offline
    UltimatusVirsus
    Junior Member
    Join Date: Nov 2018
    Location: Right behind you
    Old 10-09-2020 , 09:42   Re: [TF2] Team Fortress: Global Offensive (v1.3.1, 2020-08-20)
    Reply With Quote #2

    Hello, I have a problem when loading the plugin and that is that it asks me for an extension that I cannot find anywhere.

    UltimatusVirsus is offline
    Mikusch
    AlliedModders Donor
    Join Date: Oct 2019
    Location: Germany
    Old 01-18-2021 , 07:40   Re: [TF2] Team Fortress: Global Offensive (v1.3.1, 2020-08-20)
    Reply With Quote #3

    Quote:
    Originally Posted by UltimatusVirsus View Post
    Hello, I have a problem when loading the plugin and that is that it asks me for an extension that I cannot find anywhere.

    I know I'm terribly late to respond, apologies. The extension is linked at the bottom of the page.

    Last edited by Mikusch; 01-18-2021 at 07:53.
    Mikusch is offline
    vadia111
    Senior Member
    Join Date: Dec 2013
    Old 07-02-2021 , 20:54   Re: [TF2] Team Fortress: Global Offensive (v1.4.6, 2021-01-18)
    Reply With Quote #4

    i downloaded the gamemode and tested it recently ..... the gamemode works ...only once in a while the server crashes due to an unknown error ...

    When the round starts there is no mistake... the mistakes start when you plant the bomb...

    the round is already over and there's no time to defuse.... And in the middle of the game once in a while, the server crashes with an unknown error

    and no error appears in the log...

    I would really like to fix this game mode I'm a big fan of it....thanks for the anticipation!

    =)
    vadia111 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 20:51.


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