Rebalanced Fortress 2
is a simple yet powerful plugin that allows any server owner to modify the attributes of (almost) every item (and class) in Team Fortress 2 that's given to the player, including weapons, shields or even hats! If you think an item deserves more of the spotlight, or if you think a weapon is horribly broken, you will be able to change the attributes of such weapon to your heart's content. In addition, it's possible to add information related to those changes to let everyone know about what was changed.
This is the public version of the plugin used by the Custom TF2 Weapons
group for their Official Weapon Changes servers (which is why the release version is v1.43, as it was private before) and gives different sets of attributes to the official weapons of the game. In addition, it's also the successor of Balance Fortress 2
, a plugin I also made myself.
How does it work?
A file, tf2rebalance_attributes.txt contained within the data folder, is the one that contains the changes you wish to add to the classes or weapons, which you can modify to your heart's content in case you wish to modify anything. When a player spawns, their weapon will be automatically replaced by the same one but with the attributes that were specified in the file. If a class was modified, then the attributes, if specified, will be added to such class as well and attributes given to classes will not stack or mesh with other classes' given attributes.
The plugin's GitHub page can be seen here.
The releases page can be seen here. (Latest version: 1.8.2)
Cvars and commands
- Please install TF2Items (and optionally TF2Attributes to add attributes into classes and make "sm_tfrebalance_changetimer" work better) and follow their respective installation instructions.
- Optionally, if you wish to compile your own version of the plugin, you might want to have morecolors.inc as well.
- Get the latest release from the plugin's GitHub by clicking here and then clicking on the .zip file download (or, if you're upgrading, grab the plugin file (.smx) directly).
- Drop the "addons" folder from the .zip file into where your server's tf/ folder is.
- Change the map or load it manually by writing "sm plugins load tf2rebalance_jug" in the server's console.
- If you wish to learn how to change a weapon's attributes and/or add attributes into a class, read the example file here.
- Console variables:
- sm_tfrebalance_enable (Default: "1"): Enables (1) or disables (0) the plugin.
- sm_tfrebalance_logdependencies (Default: "1"): Should the lack of TF2Attributes be logged? 1 enables this, whereas 0 disables it instead.
- sm_tfrebalance_firsttimeinfo (Default: "1"): Should the players, on their first spawn, be notified of the possibility of modified weapons and the commands to see such information? 1 enables this, whereas 0 disables it instead.
- sm_tfrebalance_preserveattribsbydefault (Default: "0"): On file parsing, should the lack of a "keepattribs" key default to preserve (1) or not preserve (0) the attributes of the item?
- sm_tfrebalance_changetimer (Default: "0"): If higher than zero, the weapon changes will apply after the time specified on the ConVar (example: "0.2"). This can be used to increase compatibility between plugins.
- Warning: Due to certain HUDs, setting sm_tfrebalance_changetimer to be higher than zero can crash clients after a weapon is given. You are suggested to use sm_tfrebalance_changetimer alongside sm_tfrebalance_timer_onlybots being set to 1. Enable at your own risk.
- sm_tfrebalance_timer_onlybots (Default: "0"): Indicates if sm_tfrebalance_changetimer should only affect bots.
- sm_tfrebalance_bots_giveweapons (Default: "1"): Indicates if bots should be given changes to their weapons.
- sm_tfrebalance_bots_applyclassattribs (Default: "1"): Should class changes apply to Bots?
- sm_tfrebalance_botsmvm_giveweapons (Default: "0"): Indicates if MvM bots should have their weapons changed.
- sm_tfrebalance_botsmvm_applyclassattribs (Default: "0"): Should class changes apply to MvM Bots?
- sm_tfrebalance_debug_giveweapons (Default: "0"): Verbose debug mode that throws messages on the server console about what function is being used to give weapons, whose weapon is being parsed, if attributes are being kept, the index ID of the weapon, the ID of the attribute and the value of the attribute given.
- sm_tfrebalance_debug_configfile (Default: "0"): Very verbose debug mode that displays on the server console what class or weapon is having attributes stored to for later usage for when a player spawns with such weapon or as such class.
- /tfrebalance_refresh (Root admin only): Parses tf2rebalance_attributes.txt again in case an item is in need of a hotfix, or for testing purposes.
- /refreshweapon (Cheat flag): Can target players. Turns their currently-equipped weapons into the ones defined on the tf2rebalance_attributes.txt file (so if a player holds a Brass Beast without changes somehow, the command will give them the version that the plugin would give them by default).
- /official (or /changes, or /change): Displays a menu that allows the player to see the information about their changed items and their class, if any.
If you like this plugin and wish to see more like them, be sure to donate
through my Ko-Fi page here
. It's not required, but any amount helps and it's really appreciated.
Thanks for reading and enjoy!