In this video we look into what weapons we could have gotten in TF2 through various unused item attributes! // Here's where we store attribute values, which are received when the attribute is applied. This repository contains attributes I've written. // already in the game when the plugin loaded, if any. CloakWithCharge[weapon] = StringToInt(value); else if (StrEqual(attrib, "can climb wall")). Painfully. // Usually, you'll want to hook damage done to players, using SDK Hooks. Bullets destroy rockets and grenades in-flight. // For example, when "crit damage multiplier" "0.6" is set on a weapon, we want. Leave a fake corpse on taking damage and temporarily gain invisibility, speed, and damage resistance. if (!HasAttribute[weapon]) return Plugin_Continue; // Weapon is valid, but doesn't have one of our attributes. Cannonballs have a fuse time of 1 second; fuses can be primed to explode earlier by holding down the fire key. 17 min ago, C++ | I don't run a Custom Weapon server, so most of the plugins are made through work-for-hire. Despite already having 160 unique weapons, that isn't counting yet reskins and other weapon qualities. Percentage Attributes: Add. 1.0 is the default for this attribute, so let's compare against that. It was given in genuine quality to players who … grenade_damage_reduction_on_world_contact, Generate building rescue energy on damage, Self mark for death when hauling buildings. On direct hits: rocket does maximum damage, stuns target, and blast radius increased +15% per point. DefenseOnHit[weapon] = StringToFloat(value); else if (StrEqual(attrib, "speed on hit")). Attributes file contains all attributes for an achievement weapon, andItems file, represents all TF2 weapons. if (weapon == -1) return Plugin_Continue; // Weapon is invalid, so it won't be custom. TF2_AddCondition(client, TFCond_Buffed, 0.12); TF2_AddCondition(client, TFCond_DefenseBuffed, 0.12); if (patient > -1 && patient <= MaxClients). vEyeAngles[0] += GetRandomFloat(-1.0, 1.0) * fSpin * 0.6; vEyeAngles[1] += GetRandomFloat(-1.0, 1.0) * fSpin * 0.6; TeleportEntity(victim, NULL_VECTOR, vEyeAngles, NULL_VECTOR); // In addition to the above damage hooks, we also have TraceAttack, which is done before either of them. By continuing to use Pastebin, you agree to our use of cookies as described in the. Added Pyrovision! public Action:TF2_CalcIsAttackCritical(client, weapon, String:weaponname[], &bool:result), if (CanClimbWall[weapon]) //Borrowed from Randomizer, if (FiresSpells[weapon]) //Borrowed from a plugin. Hat attributes. // Does this weapon have the "aim punch multiplier" attribute? +15% rocket speed per point. new victim = GetClientOfUserId(GetEventInt(event, "userid")); new attacker = GetClientOfUserId(GetEventInt(event, "attacker")); new assister = GetClientOfUserId(GetEventInt(event, "assister")); new bool:feign = bool:(GetEventInt(event, "death_flags") & TF_DEATHFLAG_DEADRINGER); SetEntProp(victim, Prop_Send, "m_bGlowEnabled", 0); new weapon = LastWeaponHurtWith[attacker]; if (SpeedOnKill[weapon] != 0.0 && victim > 0 && victim <= MaxClients && !feign). 50 min ago, Python | // Some attributes are simply on/off, so we don't need to check the "value" string. if (!HasAttribute[weapon]) HasAttribute[weapon] = bool:action; // Let Custom Weapons know that we're going to make the attribute work (Plugin_Handled). We don't care! Well the firsts are the weapons and the achievement weapons. Primary Fire: Launches a fast-moving projectile that briefly ignites enemies Alt-Fire: Release a blast of air that pushes enemies and projectiles, and extinguishes teammates that are on fire. name = "Custom Weapons: Lykrast Attributes", Weapons applies Jarate on hit for the specified duration, Jarate is applied before the damage is dealt, so the first shot is not a mini crit, Weapons applies Mad Milk on hit for the specified duration, Mad Milk is applied before the damage is dealt, so the first shot does not heal, Weapons applies a defense buff on wearer on hit for the specified duration, Weapons applies a speed buff on wearer on hit for the specified duration, Weapons applies a speed buff on wearer on kill for the specified duration, When the wearer's health is below the specified value, the weapon is crit boosted, Weapons makes the target visible through walls for the specified duration, Hitting a target with this or less health less will be an instant kill, When drawing this weapon, applies Crit-a-Cola on wearer for the specified duration, On a kill, the clip is set to the defined value, When the charge meters exceed this percentage (50 = 50%), the user is cloaked, Hitting a wall will propel the user upward, On hit, apply specified vertical velocity to the target, On hit, apply specified vertical velocity to the user, On kill, the user is teleported to the target, While airborne, damage is multiplied by this amound, 100% critical hits against airborne targets, On hit, the target's eye angle is changed, disorienting it, Multiplies the knockback inflicted by the weapon by this amount, Can't activate cloak before the meter is full, On cloak, removes Afterburn, Bleeding, Jarate and Mad Milk, On decloak, if your cloak is about the value (50 = 50%), it is reduced to the value, -> "medi gun mini crits defense ubercharge", UberCharge grants mini crits and a defense buff, UberCharge grants crits in addition to its normal benefits, On assist, the user gains UberCharge (0.5 = 50%), A percent of damage dealt through bleeding and crits is healed (0.5 = 50%). TF2 Custom Weapon Attributes Collection. Fires a special bolt that can repair friendly buildings, +25% more overheal, +50% longer duration per point. TF2_RemoveCondition(client, TFCond_OnFire); if(TF2_IsPlayerInCondition(client, TFCond_Bleeding)). Grenades have very little bounce and roll, Taking damage while shield charging reduces remaining charging time, Increased Melee damage against Isolated Merc Set, Increased Nostromo Napalmer damage taken from Isolated Merc Set, Increased Nostromo Napalmer damage against Isolationist Pack Set, Increased Melee damage taken from Isolationist Pack Set, Early Supporter of End of the Line Community Update, Weapon spread increases as health decreases, No cloak meter from ammo boxes when invisible, Not Tradable, Marketable, Usable in Crafting, or Gift Wrappable, Secondary fire when charged grants mini-crits for, Extinguishing teammates reduces cooldown by, Attacks pierce damage resistance effects and bonuses, Immune to push force from damage and airblast when spun up, Normal disguises require (and consume) a full cloak meter, Spawning and resupply do not affect the Gas meter, Maximum health is drained while item is active, Minicrits whenever it would normally crit, Push enemies back when you land (force and radius based on velocity), Able to re-launch while already in-flight, Gain a speed boost when you hit an enemy player, Gas meter builds with damage done and/or time, repair_health_to_metal_ratio_DISPLAY_ONLY, additional_halloween_response_criteria_name. While Attributes such as health regen or damage vulnerability CAN be nailed to a weapon, it's better to leave those in CharacterAttributes for the sake of organization. Set TF2 attribute override projectile type to -1 on the weapon if you want to use this. can change the damage's information, and you will know. TR_TraceRayFilter(vecClientEyePos, vecClientEyeAng, MASK_PLAYERSOLID, RayType_Infinite, TraceRayDontHitSelf, client); new TRIndex = TR_GetEntityIndex(INVALID_HANDLE); GetEdictClassname(TRIndex, classname, sizeof(classname)); if (!StrEqual(classname, "worldspawn")) return; TR_GetPlaneNormal(INVALID_HANDLE, fNormal); //PrintToChatAll("Normal: %f", fNormal[0]); if (fNormal[0] >= 30.0 && fNormal[0] <= 330.0) return; new Float:distance = GetVectorDistance(vecClientEyePos, pos); //PrintToChatAll("Distance: %f", distance); GetEntPropVector(client, Prop_Data, "m_vecVelocity", fVelocity); TeleportEntity(client, NULL_VECTOR, NULL_VECTOR, fVelocity); ClientCommand(client, "playgamesound \"%s\"", "player\\taunt_clip_spin.wav"); // Here's another one, OnPlayerRunCmd. The following table describes the possible attributes of weapons and items as contained in the items_game.txt file. This subreddit is dedicated to Team Fortress 2, created by Valve Corporation in 2007. tf2 team fortress2 mann vs machine mvm custom wave generator. // We also check AFTER the damage was applied, which you should honestly try to do if your attribute. if (client <= 0 || client > MaxClients) return; new invis = GetPlayerWeaponSlot(client, 4); if (CloakRequireFull[invis] && GetEntPropFloat(client, Prop_Send, "m_flCloakMeter") < 100.0). TF2 Custom Weapon Maker. Dragon's Fury Machina Sniper Rifle Sydney Sleeper Medi-gun Kritz-krieg Phlogistinator Flame-Thrower Stickybomb Launcher Scottish Resistance Sticky Jumper Huntsman Fist of Steel Frying Pan Bottle Eyelander Market Gardener Sandman Killing gloves of boxing Ubersaw Disciplinary Action Bushwacka Axtinguisher Gloves of Running urgently HHH'S Headtaker Scatter Gun Revolver Shotgun SMG Short-Stop Pistol Widowmaker Panic-Attack Force-O-Nature Ambassador Wrangler Wrench Gunslinger Eureka Effe… Third successful punch in a row always crits. // client prediction still makes it look like 10 times per second. An attribute is where an effect is impacted on that weapon to make it unique of its own kind. you can change class speed, as well as weapon attributes server side, it's just a matter of getting someone to code a "2012 tf2" set of server attributes and then try to push it to be accepted by all leagues. HealOnSheath[weapon] = StringToInt(value); else if (StrEqual(attrib, "disorientate on hit")), else if (StrEqual(attrib, "push force increased")). Killing blows on burning players grant a speed boost. if (!HasAttribute[weapon]) return Plugin_Continue; // Here's another great thing to track; TF2_CalcIsAttackCritical. if (attacker <= 0 || attacker > MaxClients) return Plugin_Continue; new weapon = GetEntPropEnt(attacker, Prop_Send, "m_hActiveWeapon"); // We have to get the weapon manually, sadly; this also means that. this weapon's damage is increased by %s1%, This effect does not work in the respawn room, mini-crits players, sets them on fire, and disables buildings for 4 sec, building destroyed with your sapper attached or backstab kill. TF2 Custom Attribute Starter Pack. if (attacker <= 0 || attacker > MaxClients) return Plugin_Continue; // Attacker isn't valid, so the weapon won't be either. MadMilkOnHit[weapon] = StringToFloat(value); else if (StrEqual(attrib, "defense on hit")). A collection of (mostly) production-ready custom attributes written for the Custom Attribute framework. 1 : 0, 1); SetEntProp(spell, Prop_Send, "m_iTeamNum", team, 1); SetEntProp(spell, Prop_Send, "m_nSkin", (team-2)); TeleportEntity(spell, vPosition, vAngles, NULL_VECTOR); AcceptEntityInput(spell, "TeamNum", -1, -1, 0); AcceptEntityInput(spell, "SetTeam", -1, -1, 0); TeleportEntity(spell, NULL_VECTOR, NULL_VECTOR, vVelocity); GetClientEyePosition(client, vecClientEyePos); // Get the position of the player's eyes, GetClientEyeAngles(client, vecClientEyeAng); // Get the angle the player is looking. // Every time a player takes damage, we'll check if the weapon that the attacker used, public Action:OnTakeDamage(victim, &attacker, &inflictor, &Float:damage, &damagetype, &weapon, Float:damageForce[3], Float:damagePosition[3]). Build energy by healing teammates. MediGunMiniCritsDefenseUber[weapon] = true; TF2Attrib_SetByName(weapon, "medigun charge is crit boost", -1.0); else if (StrEqual(attrib, "medi gun kritz ubercharge")), else if (StrEqual(attrib, "uber on assist")). I've learned a bunch since I've written these originally, though while I am doing a port, I may or may not put in effort in rewriting the dark magic hackjobs that were initially implemented. public Action:OnPlayerRunCmd(client, &buttons, &impulse, Float:vel[3], Float:ang[3], &weapon2). Absolute Attributes… AFAIK though, updates might wipe the file, so make a backup of it in the same folder under a different name. On Hit: If enemy's belt is at or above eye level, Alt-Fire: Extinguish teammates to gain guaranteed critical hits, On Hit: Force enemies to laugh who are also wearing this item, Generate Rage by dealing damage. STEP 7= Open both attributes and items with wordpad. Mini-crits burning players from the front. On Hit: One target at a time is Marked-For-Death, causing all damage taken to be mini-crits, On Scoped Bodyshot: Rifle charge rate increased by, On Scoped Miss: Rifle charge rate decreased by. // There's also HasAttribute[2049], for a super-marginal performance boost. This is a list of the item definition indexes in TF2, these are useful for distinguishing an unlockable weapon from its original (for example: The Backburner from an ordinary Flamethrower.) if (weapon == -1) return Plugin_Continue; // attributes that use this can only be applied to "hitscan" weapons. Entities used in the official BSP map files that are undefined in the official FGD. ÜberCharge increases healing to 300% and grants immunity to movement-impairing effects, Move speed increases as the user becomes injured, On Scoped Headshot: Rifle charge rate increased by, Gains a damage bonus as rage increases, up to, Can deal charge impact damage at any range, On Hit Teammate: Boosts both players' speed for several seconds, Ammo collected from ammo boxes becomes health, Deals 3x falling damage to the player you land on, Deals crits while the wielder is rocket jumping, Consumable: Become Crit Boosted for 5 seconds, Consumable: Become Übercharged for 5 seconds, Teleporters can be used in both directions, Gives one guaranteed critical hit for each. As well, in game_sounds_weapons.txt, the Fire Axe has the heading BRANDING IRON, referring to the Pyro's original melee weapon, the Branding Iron, which has an untextured model in the game files. // In this case, if it's "aim punch multiplier"... // ...then get the number from the "value" string, and remember that. // We changed the damage, so we need to return Plugin_Changed below... GetEntPropVector(attacker, Prop_Data, "m_vecVelocity", fVelocity); GetEntPropVector(victim, Prop_Data, "m_vecVelocity", fVelocity); if (PushForceIncreased[weapon] != 1.0) //Borrowed from AW2. It's called once every frame for every single player. // is not going to change anything about the damage itself. Class & Slot. Costs 65 metal. Uses a shared pressure tank for Primary Fire and Alt-Fire. // like the one seen below, which shows the next time we can play a "click" noise. case 1: strEntname = "tf_projectile_spellfireball"; case 2: strEntname = "tf_projectile_lightningorb"; case 3: strEntname = "tf_projectile_spellmirv"; case 4: strEntname = "tf_projectile_spellpumpkin"; case 5: strEntname = "tf_projectile_spellbats"; case 6: strEntname = "tf_projectile_spellmeteorshower"; case 7: strEntname = "tf_projectile_spelltransposeteleport"; case 8: strEntname = "tf_projectile_spellspawnboss"; case 9: strEntname = "tf_projectile_spellspawnhorde"; case 10: strEntname = "tf_projectile_spellspawnzombie"; new spell = CreateEntityByName(strEntname); GetAngleVectors(vAngles, vBuffer, NULL_VECTOR, NULL_VECTOR); vVelocity[0] = vBuffer[0]*1100.0; //Speed of a tf2 rocket. UberOnAssist[weapon] = StringToFloat(value); else if (StrEqual(attrib, "backnacker heal")). On Backstab: Absorbs the health from your victim. public OnTakeDamagePost(victim, attacker, inflictor, Float:damage, damagetype, weapon, const Float:damageForce[3], const Float:damagePosition[3]). Delineating what is a function of a weapon and what is a funciton of the bot itself can help you keep your ideas straight. 7 seconds. TF2_RemoveCondition(client, TFCond_Jarated); if(TF2_IsPlayerInCondition(client, TFCond_Milked)). // "ReduxHypeBonusDraining[2049]" (custom-attributes.sp) or client variables. Attributes are handled through a Randomizer config file, that can be modified by the server. FiresSpells[weapon] = StringToInt(value); // If the weapon isn't already marked as custom (as far as this plugin is concerned). Invulnerable while 'Mmmph' taunting. CritWhileLow[weapon] = StringToInt(value); else if (StrEqual(attrib, "glow on hit")). Consumable: Instantly upgrade all buildings to max level, Alt-Fire: Launches a festive ornament that shatters causing bleed, Press your reload key to choose to teleport to spawn or your exit teleporter, Stuns enemies who are also wielding this weapon, All players connected via Medigun beams are hit, On Hit by Fire: Fireproof for 1 second and Afterburn immunity for. Undocumented map entities. Like TF2 x10 Last edited by BigBang1112; Dec 14, 2013 @ 5:38am < > Showing 1-10 of 10 comments . ReloadOnKill[weapon] = StringToInt(value); else if (StrEqual(attrib, "cloak with charge")). // or let it print a warning (Plugin_Continue). Mercs Playing Team Fortress 2. Critical hit system is similar to that one from TF2 Ammo is required to fire a weapon in survival mode. Our "action" will be set to Plugin_Changed if we. STEP 7= Open both attributes and items with wordpad. Some old, some new: They come in Bear Trap, Concussion, EMP, Frag, Gas, Healing, MIRV, Nail and Napalm flavors, all with lovely TF2-style models. Done! SetEntProp(client, Prop_Send, "m_bGlowEnabled", 0); SetEntProp(client, Prop_Send, "m_bGlowEnabled", 1); stock AnglesToVelocity(Float:fAngle[3], Float:fVelocity[3], Float:fSpeed = 1.0). There are many attributes in the game that map to attribute class "set_weapon_mode", with many different names: - "fists have radial buff" - "set cloak is feign death" - "mod bat launches balls" STEP 6 = In the folder should appear again Attributes and Items but in .txt format. We'll use it here for "speed boost on hit teammate". Attributes file contains all attributes for an achievement weapon, and Items file, represents all TF2 weapons. // ^ Remember, this is called once for every custom attribute (attempted to be) applied! new weapon = GetEntPropEnt(client, Prop_Send, "m_hActiveWeapon"); if (weapon <= 0 || weapon > 2048) return Plugin_Continue; public TF2_OnConditionAdded(client, TFCond:cond). Increase in push force taken from damage and airblast, Mini-crits targets when fired at their back from close range, Increased attack speed and smaller blast radius while blast jumping, Charge and fire shots independent of zoom. I've made videos using this method before. TF2_AddCondition(patient, TFCond_Buffed, 0.12); TF2_AddCondition(patient, TFCond_DefenseBuffed, 0.12); TF2_AddCondition(patient, TFCond_HalloweenCritCandy, 0.12); SetClientGlow(client, Float:time1, Float:time2=-1.0). TF2_AddCondition(attacker, TFCond_SpeedBuffAlly, SpeedOnKill[weapon]); new ammoType = GetEntProp(weapon, Prop_Send, "m_iPrimaryAmmoType"); new reloaded = ReloadOnKill[weapon] - GetEntProp(weapon, Prop_Data, "m_iClip1"); if (GetEntProp(attacker, Prop_Data, "m_iAmmo", _, ammoType) < reloaded). Damage increases based on remaining duration of afterburn. // Filter out other plugins. public Action:Timer_TenTimesASecond(Handle:timer), for (new client = 1; client <= MaxClients; client++). fVelocity[0] = Cosine(DegToRad(fAngle[1])); fVelocity[1] = Sine(DegToRad(fAngle[1])); fVelocity[2] = Sine(DegToRad(fAngle[0])) * -1.0; new wep = GetPlayerWeaponSlot(client, 1); if (wep == -1 || wep != GetEntPropEnt(client, Prop_Send, "m_hActiveWeapon")) return -1; GetEdictClassname(wep, class, sizeof(class)); if (StrContains(class, "tf_weapon_med", false)) return -1; return GetEntProp(wep, Prop_Send, "m_bHealing") ? Randomizer Respects the 'tf2c_force_stock_weapons' ConVar. This list is divided in to Weapons, Hats and Crafting Items. Bumping in to enemies will make you slightly visible to enemies. // Also, make sure the victim is a player. ... 8 Weapon Attributes; Weapons. This page was last edited on 11 August 2019, at 11:23. +1 duration, -10 price per point (minimum cost: 5). if (!StrEqual(plugin, "lykrast-attributes")) return Plugin_Continue; // "action" here is what we'll return to the base Custom Weapons plugin when we're done. Made by Derek R (AKA Compegen) Weapon Name: Submit. Updated the Randomizer command to allow for toggling random classes, weapons and attributes. Secondary weapon attributes. STEP 9= You want Natascha to make look like this, don’t you? +25% heal rate for patient, +25% faster revive rate, and +25% self heal rate, per point. Killing an enemy with a critical hit will dismember your victim. Unfortunately, though, it doesn't have as much information as OnTakeDamage. 3.3k. SDKHook(client, SDKHook_OnTakeDamage, OnTakeDamage); SDKHook(client, SDKHook_OnTakeDamagePost, OnTakeDamagePost); SDKHook(client, SDKHook_TraceAttack, OnTraceAttack); SDKHook(client, SDKHook_WeaponSwitch, OnWeaponSwitch); // This is called whenever a custom attribute is added, so first... public Action:CustomWeaponsTF_OnAddAttribute(weapon, client, const String:attrib[], const String:plugin[], const String:value[]). This weapon fires Spells, the value deciding which one. The following table describes the possible attributes of weapons and items as contained in the items_game.txt file.
Beading Wire Nz, Ky Division Of Oil And Gas, How To Fix Bitter Gravy, Will God Still Love Me If I Get A Tattoo, Frankie Goes To Russia, How To Protect Chickens From Cats, Black And White Striped Pants High Waisted,