RSSy MYGO.pl Opublikowano Lipiec 15, 2016 o 16:55 RSSy Udostępnij Opublikowano Lipiec 15, 2016 o 16:55 Wanting new weapons in TF2? Valve not doing it? Take matters into your own hands with Custom Weapons 3! Based on the Custom Weapons 2 plugin by MasterOfTheXP, Custom Weapons 3 has a brand new menu system and the ability for servers to make shields and wearables! Unlike Custom Weapons 2, however, Custom Weapons 3 uses a module-based system."What is that supposed to mean?" Well, what that means is that if you want to contribute to Custom Weapons 3, a lot of the plugin is exposed via forwards in the .inc file. It also means that if a server owner finds a module that causes lag, it can be removed or replaced by a more optimized module."How do I know what to insta..." Shhhh... I was about to get to that. In the attachments of this post, you will see something called "CW3 Starter Kit.zip". If you're setting up a server, the starter kit has everything you need to get it going, just copy the plugins folder into your servers sourcemod/plugins folder.LIST OF WHAT THE OFFICIAL MODULES DO: Spoiler cw2attributes This provides backwards compatibility with Custom Weapons 2 attribute plugins. This will spam errors if an attribute is applied to a wearable or shield. To add an attribute, put a block in your weapon config titled "attributes". Inside there, put blocks with the names of the attributes you want to apply, one attribute per block. Inside those blocks, insert two keys titled "plugin" and "value". The value for "plugin" is the name of the plugin the attribute is from. The value for "value" is the value of the attribute. cw2legacy This plugin basically replicates Custom Weapons 2's functionality. This can be used to guarantee compatibility with an old Custom Weapons 2 server. cw2model-application Allows custom models to be added to a weapon. Due to Valve making a change a few years ago, your weapon will be invisible to other players. There is no way to fix this. If you know a workaround, DO NOT POST IT HERE. For a custom viewmodel, insert a block into your weapon config titled "viewmodel". Inside that block, put a key titled "modelname". The value of "modelname" is the location of the model to display. For a custom worldmodel, insert a block into your weapon config titled "worldmodel". Inside that block, put a key titled "modelname". The value of "modelname" is the location of the model to display. This will be invisible to other players. There is no fix. cw2sounds Allows custom sounds to be played for various weapon events. To use this, make a block titled "sound" and inside that block, put a block titled "player" for every sound you want to replace. Inside each of those blocks, put a "find" and "replace" key. The value for "find" is the sound you want to replace, and the value for "replace" is the sound to play instead. cw3-attributes This allows vanilla and new attributes to be applied to weapons. To use attributes from plugins build on cw3-attributes, put a block titled "cw3_attributes" in your weapon config. You can put "while active" "1" in an attribute block to tell an attribute plugin to make the attribute only work while the weapon is out. Bear in mind that this is not law, an attribute plugin can ignore this if they wish. Other than that, the parameters are the same as cw2attributes. cw3model-application This does essentially the same thing as the cw2model-application module, but saves one entity per worldmodel. If you have server crashes due to a lot of edicts, give this a shot! HOW TO MAKE A WEAPON CONFIG: Spoiler Creating a new custom weapon is plain easy. Simply duplicate a custom weapon's config file, and fill out its info with your own. The weapon's name goes right at the top, in "quotes". "classes" is the array of player classes the weapon should be available for; the number next to each class is the weapon slot (0 = Primary, 1 = Secondary, 2 = Melee) "baseclass" is the classname of the weapon, without "tf_weapon_". For a shield put "wearable_demoshield", and for a wearable (such as boots) put "wearable". "baseindex" is the item index of the base weapon, see above classname link. If unsure, stick within the 0-30s. If it uses ammo (i.e. most non-melee weapons) it should have "mag" and "ammo" keys with the intended starting ammo. "logname" will be displayed in client consoles when a kill is made with the weapon. Not currently implemented. "killicon", also not implemented yet, will be able to change the weapon's icon in the kill feed. "description" is the stat list that players will see when selecting the weapon. \n = Newline. "\n \n" will skip an entire line. "attributes"; Requires cw2attributes module. Each attribute has: An identifier, to set what attribute it is. This will either be a case-sensitive name (Custom Weapons, TF2Attributes) or an attribute index (TF2Items). "plugin": Who will provide the attribute's functionality? For official Valve attributes, you'll usually want to use TF2Attributes, so put "tf2attributes". A select few attributes require "tf2attributes.int" instead. If TF2Attributes doesn't work for said attribute (so far I've only seen "alt-fire is vampire" not work with TF2Att) then try "tf2items" instead, with the identifier being the number beside the attribute's name. (e.g. "move speed penalty" should instead be "54") Or, of course, a custom attribute! In which case, "plugin" should be set to the name of the attributes plugin, minus ".smx". And of course, a value. Most attributes are multipliers; with "damage bonus/penalty", "2.0" is double (+100%), and "0.5" is halved (-50%). With time-based attributes such as "Reload time increased/decreased", "0.5" is half time (good), whereas "2.0" makes it take twice as long (bad). And some attributes are simply "1.0 = on, 0.0 = off". If you're unsure about values, check out a weapon that already has that attribute (Ctrl+F the official weapon's name in tf/scripts/items_game.txt, or just look at the custom weapon's config) "cw3_attributes"; the bread-n-butter. Requires cw3-attributes module. Each attribute has: An identifier, to set what attribute it is. This will either be a case-sensitive name (Custom Weapons, TF2Attributes) or an attribute index (TF2Items). "plugin": Who will provide the attribute's functionality? For official Valve attributes, you'll usually want to use TF2Attributes, so put "tf2attributes". A select few attributes require "tf2attributes.int" instead. If TF2Attributes doesn't work for said attribute (so far I've only seen "alt-fire is vampire" not work with TF2Att) then try "tf2items" instead, with the identifier being the number beside the attribute's name. (e.g. "move speed penalty" should instead be "54") Or, of course, a custom attribute! In which case, "plugin" should be set to the name of the attributes plugin, minus ".smx". The Starter Kit includes "aw2attrib" and "rays-attributes". "while active": If this is 1, cw3-attributes will tell the attribute plugin that this attribute should only work while the weapon is out. Do note, that this is a recommendation, and some attributes may intentionally ignore this. And of course, a value. Most attributes are multipliers; with "damage bonus/penalty", "2.0" is double (+100%), and "0.5" is halved (-50%). With time-based attributes such as "Reload time increased/decreased", "0.5" is half time (good), whereas "2.0" makes it take twice as long (bad). And some attributes are simply "1.0 = on, 0.0 = off". If you're unsure about values, check out a weapon that already has that attribute (Ctrl+F the official weapon's name in tf/scripts/items_game.txt, or just look at the custom weapon's config) Q&A Spoiler I'm an attribute developer, how does this affect me? Well, there are a few changes to how attributes are applied. First off, in CW2, attributes were indexed mostly by weapon entity index. This is no longer the case. Attributes should now be indexed by client id and slot. It's not really as bad as it seems at first, my AW2 attributes plugin took about an hour or two to port.I'm a server owner, how does this affect me? If you've used CW2, it shouldn't affect you at all! Just use the cw2legacy or all the cw2 builds and your server will just have the fancy new menu. INSTALLATION First things first, make sure your server has tf2items installed. For either of the attribute modules, make sure you also have tf2attributes installed. Put cw3.smx into your sourcemod/plugins folder Create a cw3 folder in sourcemod/plugins Inside that folder, create a modules folder Inside THAT folder, place any modules you want to use. Inside the cw3 folder, create a folder titled attributes Inside that folder, place any attribute plugins that run on cw3 Inside your sourcemod/configs folder, create a folder called cutsomweapons Inside that folder, place any weapon configs you have, or create your own! (CW2 attribute users only) Inside your sourcemod/plugins folder, create a folder called customweaponstf Inside that folder, place any attribute plugins that are built on CW2 (FREE) DLC You need weapons and modules to use CW3, so why not grab some of these? Weapons No unofficial weapons posted (yet!) Modules No unofficial modules posted (yet!) Attributes No unofficial attributes posted (yet!) CHANGELOG Spoiler Beta 1 Initial release. Looking for a server? Come check out Custom TF2 Weapons, the officially supported Custom Weapons 3 server! Attached Files CW3 Starter Kit.zip (331.3 KB) Wyświetl pełny artykuł Odnośnik do komentarza Udostępnij na innych stronach Więcej opcji udostępniania...
Rekomendowane odpowiedzi
Jeśli chcesz dodać odpowiedź, zaloguj się lub zarejestruj nowe konto
Jedynie zarejestrowani użytkownicy mogą komentować zawartość tej strony.
Zarejestruj nowe konto
Załóż nowe konto. To bardzo proste!
Zarejestruj sięZaloguj się
Posiadasz już konto? Zaloguj się poniżej.
Zaloguj się