View Single Post
xXDeathreusXx
Veteran Member
Join Date: Mar 2013
Location: pPlayer->GetOrigin();
Old 05-13-2015 , 23:29   [Subplugin] Timed New Weapon
Reply With Quote

Update: IT WORKS! I changed it from using OnGameFrame() to SDKHooks_PreThink which handles clients much better and now the duration till removal works

The ability:
Code:
"abilityX"    // Replace the x with a number numbnuts
{
    "name" "rage_timed_new_weapon"
    "arg1"    ""    // Weapon classname
    "arg2"    ""    // Weapon index
    "arg3"    ""    // Weapon attributes(You should know how to do this, but e.g. "2 ; 3.0"(Damage bonus)
    "arg4"    ""    // Weapon slot (0: Primary, 1: Secondary, 2: Melee)
    "arg5"    ""    // Weapon off hand ammo (Or clipless weapons ammo)
    "arg6"    ""    // Weapon clip ammo
    "arg7"    "1"   // Don't change this
    "arg8"    ""    // Duration to keep the weapon, set to 0 to keep the weapon
    "plugin_name"        "ff2_timed_new_weapon"
}
It functions exactly the same as the default rage ability, only with the added benefit of limiting how long you keep the weapon

I should mention, that it probably has some redundancies in it, I'm notorious for doing that

ff2_timed_new_weapon.ff2
Attached Files
File Type: sp Get Plugin or Get Source (ff2_timed_new_weapon.sp - 353 views - 9.0 KB)
__________________
Plugins|Profile
Requests closed

I'm a smartass by nature, get used to it

Last edited by xXDeathreusXx; 05-27-2015 at 14:39. Reason: Updated
xXDeathreusXx is offline