AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Plugins (https://forums.alliedmods.net/forumdisplay.php?f=108)
-   -   [TF2] Player Climb (v1.5, 6-6-2015) (https://forums.alliedmods.net/showthread.php?t=260967)

Nanochip 04-03-2015 21:58

[TF2] Player Climb (v1.5, 6-6-2015)
 
1 Attachment(s)
[TF2] Player Climb



Description:
Climb walls with melee by attacking the heck out of a frisky wall! ;)
I ripped SickleClimbWalls from VSH and added a couple cvars.
Decided to release this to the public since a lot of people want it for their FF2 server (and I use it for my prophunt server).
Edit your climbing preferences in the sm_settings menu or sm_playerclimb command.

Video Demonstration:


CVARS:
Listed in your cfg/sourcemod/PlayerClimb.cfg
Note that the default settings for these cvars remedy the VSH bushwacka climb for sniper only.
  • sm_playerclimb_version - Plugin version, no touchy!
  • sm_playerclimb_enable [0/1] - (Default: 1) Enable the plugin? 1 = Yes, 0 = No.
  • sm_playerclimb_damageamount [#] - (Default: 15.0) How much damage should the player take while climbing?
  • sm_playerclimb_team [0/1/2] - (Default: 0) Restrict climbing to X team only. 0 = No restriction, 1 = BLU, 2 = RED.
  • sm_playerclimb_boss [0/1] - (Default: 0) [VSH/FF2 ONLY] Should the boss be able to climb walls? 1 = Yes, 0 = No.
  • sm_playerclimb_class "scout,sniper,spy,heavy,soldier,demo,medic,py ro,engineer" - (Default: "sniper") Which classes should be allowed to climb walls? Use "all" for all classes, otherwise specify the class name separated by a comma.
  • sm_playerclimb_maxclimbs [#] - (Default: 0) The maximum amount of times the player can melee the wall (climb) while being in the air before they have to touch the ground again. 0 = Disabled, 1 = 1 Climb... 23 = 23 Climbs.
  • sm_playerclimb_cooldown [#.#] - (Default: 0.0) Time in seconds before the player may climb the wall again, this cooldown starts when the player touches the ground after climbing.
  • sm_playerclimb_nextclimb [#.#] - (Default: 1.56) Time in seconds in between melee climbs.

Override:
Put this in your addons/sourcemod/configs/admin_overrides.cfg if you wish to limit player climbing to a specific flag.
  • sm_playerclimb_override - By default, everyone has access to climbing.

Installation:
  1. Click "Get Plugin" attached at the bottom of this post.
  2. Drag and drop the playerclimb.smx to your addons/sourcemod/plugins/ folder.
  3. Restart the server/map.

To-Do List:
I am always welcome to suggestions!
  • None

Changelog:
Spoiler


FF2 Boss Specific Climbing (Ability):
I made this plugin into a subplugin for Freak Fortress 2, check it out here.

Want to support me?
Credits:
Since I ripped some code from VSH, these beautiful people deserve credit:

enstage 04-04-2015 01:10

Re: [TF2] Sniper Climb (v1.0, 4-3-2015)
 
Can I suggest combining the damage and damageamount cvars? Just have damageamount and make it so that when it is set to 0 they don't take damage.

Nanochip 04-04-2015 02:28

Re: [TF2] Sniper Climb (v1.0, 4-3-2015)
 
Not sure why I didn't do that to begin with. Updated.

Chdata 04-04-2015 02:30

Re: [TF2] Sniper Climb (v1.0, 4-3-2015)
 
You should unrestrict the damage ceiling. Some servers have health pools in the Xxxx.

You should add support for X team only, or flat out use the FF2/VSH get boss natives to prevent bosses from wallclimbing.

You could do it like taunt crits does. If the player's max health is greater than X, then obviously the must be a boss player.

check m_iMaxHealth < 600. That should do the trick.

Here is the unreleased change to SickleClimbWalls that'll be part of VSH some day.

PHP Code:

    new TRIndex TR_GetEntityIndex();
    
GetEdictClassname(TRIndexclassnamesizeof(classname));

    if (!((
StrStarts(classname"prop_") && classname[5] != 'p') || StrEqual(classname"worldspawn")))
    {
        return 
false;
    } 

You may as well change the SDKHooks takedamage to not read the stats off of the player's weapon: This causes bleed weapons to hit oneself when you climb walls; such as the tribalman's shiv.

PHP Code:

    SDKHooks_TakeDamage(clientclientclient15.0DMG_CLUB0); // GetPlayerWeaponSlot(client, TFWeaponSlot_Melee)

    
if (client != Hale)
    {
        
ClientCommand(client"playgamesound \"%s\"""player\\taunt_clip_spin.wav");
        
RequestFrame(Timer_NoAttackingEntIndexToEntRef(weapon));
    } 

Lastly, support for non-snipers. If m_hActiveWeapon == GetPlayerWeaponSlot(cilent, TFWeaponSlot_Melee). If iClass == etc

Nanochip 04-04-2015 02:54

Re: [TF2] Sniper Climb (v1.0, 4-3-2015)
 
Thanks for the suggestions, added them to the to-do list. I'll work on them tomorrow, off to bed I go!

Maximilian_ 04-04-2015 04:22

Re: [TF2] Sniper Climb (v1.0, 4-3-2015)
 
Nice work! But... Can you to do support for other melee weapons?

Maximilian_ 04-04-2015 04:58

Re: [TF2] Sniper Climb (v1.0, 4-3-2015)
 
or special cvars?

Chdata 04-04-2015 05:04

Re: [TF2] Sniper Climb (v1.0, 4-3-2015)
 
Also I suggest the maxhealth thing way over team based.

Nanochip 04-04-2015 09:58

Re: [TF2] Sniper Climb (v1.0, 4-3-2015)
 
Quote:

Originally Posted by Chdata (Post 2281701)
Also I suggest the maxhealth thing way over team based.

I'll add support for both, because I use this plugin for Prophunt as well, and i'd like to keep the climbing limited to blu team only.

Nanochip 04-04-2015 12:43

Re: [TF2] Player Climb (v1.1, 4-4-2015)
 
UPDATE: v1.1 (4-4-2015)
  • Added cvars: sm_playerclimb_enable, sm_playerclimb_team, sm_playerclimb_boss, sm_playerclimb_class.
  • Updated SickleClimbWalls
  • Removed damageamount boundaries.
  • Renamed plugin to "Player Climb" since it's not only sniper that can climb now.


All times are GMT -4. The time now is 00:01.

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