AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Plugins (https://forums.alliedmods.net/forumdisplay.php?f=108)
-   -   [L4D & L4D2] Tank Pass v2.5 [02 Sep 2020] (https://forums.alliedmods.net/showthread.php?t=326374)

disawar1 07-28-2020 20:19

[L4D & L4D2] Tank Pass v2.5 [02 Sep 2020]
 
1 Attachment(s)
About:
Allows the Tank to pass control to another player.

Features:
  • Pass the Tank (player to player).
  • Confirmation menu for new Tank owner.
  • Flexible configs.
  • Admin menu: Pass the Tank (without confirmation)
  • Admin menu: Takeover the Tank (AI to player)
  • Supports both left 4 dead games.
  • Don't break game behavior.
  • Supports multi-languages.

Credits:
Сonsole Variables:

PHP Code:

// "Tank Pass plugin version."
l4d_tank_pass_version
// "Execute command according convar value on old_tank and new_tank to close 3d party HUD."
l4d_tank_pass_command "sm_tankhud"
// "0=Kill the alive player before the Tank pass, 1=Replace the alive player with an infected bot before the Tank pass."
l4d_tank_pass_replace "1"
// "0=Allow to pass the Tank when taking any damage, 1=Prevent to pass the Tank when taking any damage."
l4d_tank_pass_damage "0"
// "0=Allow to pass the Tank when on fire, 1=Prevent to pass the Tank when on fire."
l4d_tank_pass_fire "1"
// "If l4d_tank_pass_fire convar set to 0: 0=Ignite the new Tank when passed, 1=Extinguish the new Tank when passed."
l4d_tank_pass_extinguish "0"
// "Sets the Tank passed count according convar value when taking control of the Tank AI. If >1 the tank will be replaced with a bot when the his frustration reaches 0."
l4d_tank_pass_takeover "1"
// "0=Off, 1=Display pass command info to the Tank through chat messages."
l4d_tank_pass_notify "1"
// 0="X gets Tank" window, 1=Quick pass except finales
l4d_tank_pass_logic "1"
// 0=Off, 1=Display the menu when the Tank is spawned
l4d_tank_pass_menu "1"
// 0=Off, >0=The number of times the Tank can be passed by plugin (Frustration counts as pass).
l4d_tank_pass_count "1"
// 0=Off, 1=Ask the player if he wants to get the Tank.
l4d_tank_pass_confirm "1" 

Сonsole Commands:
HTML Code:

// Player Commands:
sm_pass/sm_tankpass/sm_passtank // Pass the Tank control to another player.

// Admin Commands (ADMFLAG_KICK):
sm_forcepass <#userid|name> // Force to pass the Tank to target player.
sm_taketank <#userid|name> // Take control of the Tank AI.

Plugin Forwards:
PHP Code:

/**
 * Called whenever plugin replaces a players tank control with another player
 *
 * @param old_tank    the player who was a tank
 * @param new_tank    a player who will become a new tank
 * @noreturn
 */
forward void TP_OnTankPass(int old_tankint new_tank); 

Plugin Requirements:
Left 4 DHooks Direct


Source Code:
l4d_tank_pass
l4d_lib.inc
Grab latest l4d_tank_pass.phrases.txt
click Save as...

Changelog:
v 2.5 (02 Sep 2020)
- Added l4d_tank_pass_confirm convar.
- Fixed a bug when it was impossible to pass the Tank to the dead infected if he playing as Tank before dying.

v 2.4.1 (01 Sep 2020)
- SM 1.9 compatibility.
- Tidy up code.

v 2.4 (30 Aug 2020)
- Added third-party plugin support that's spawn tanks.
- Added nyxtools extension compatibility.
- Fixed a bug when passed count not transferred if the Tank left team.
- Renamed some vars

v 2.3 (27 Aug 2020)
- Fixed a bug on finale!
- Added more convars.
- Remove unnecessary code.

06 Aug 2020
- Updated translation.

v 2.2 (01 Aug 2020) ~19 views
- Blocked sm_pass command on final stages.
- Updated translations.

31 July 2020 ~20 views
- Added hungary translation.

29 July 2020 ~52 views
- Released on alliedmods.net.

v 2.1 (24 July 2020)
- Added the tank pass/takeover cmds to admin menu.
- Added more convars.
- Bug fixes.
- Phrases grammar fixes.

v 2.0 (23 July 2020)
- Updated SourcePawn syntax.
- left4dhooks migration.
- Added l4d2 support.
- Added confirm menu.
- Added sm_tankpass, sm_tankfpass commands.
- Removes tank_pass_button convar.

v 1.1 (14 Feb 2014)
- Added TP_OnTankPass forward.
- Added tank_pass_button convar.

v 1.0 (somewhere in 2013)
- Released privately for some l4d1 servers.

KasperH 07-29-2020 12:49

Re: [L4D & L4D2] Tank Pass
 
1 Attachment(s)
- Added Hungarian. :bee:
- Fix'd a misspell in phrase6. "did't" :)

disawar1 07-30-2020 05:11

Re: [L4D & L4D2] Tank Pass
 
Quote:

Originally Posted by KasperH (Post 2712180)
- Added Hungarian. :bee:
- Fix'd a misspell in phrase6. "did't" :)

Can you create a pull request?

KasperH 07-30-2020 14:35

Re: [L4D & L4D2] Tank Pass
 
Quote:

Originally Posted by disawar1 (Post 2712326)
Can you create a pull request?

I tried, hopefully I did it right. :)

disawar1 07-30-2020 20:00

Re: [L4D & L4D2] Tank Pass
 
Quote:

Originally Posted by KasperH (Post 2712397)
I tried, hopefully I did it right. :)

Thanks!
------
Translations were updated!

KasperH 07-31-2020 12:18

Re: [L4D & L4D2] Tank Pass
 
Quote:

Originally Posted by disawar1 (Post 2712428)
Thanks!
------
Translations were updated!

My thanks! :bacon!::bacon!:

SkiPlix 07-31-2020 15:28

Re: [L4D & L4D2] Tank Pass
 
Rephrased some stuff in the plugin's translation.txt file.
&
Added Spanish translation.

@disawar1
Also maybe this is only on my server, but every time a tank spawns, 2 Tanks are created (Total 2 Tanks at the same time).

Pelee 08-01-2020 08:09

Re: [L4D & L4D2] Tank Pass
 
Plugin bug:

In finale, if you pass the tank to a teammate, this counts as a progress for survivor teams and shortly after another tank spawns. Finale such as dark carnival progresses upon tank pass. Game breaking, please look into it

Request:

Can you add optional feature which allows us to vote who gets the next tank?

Such as if there is a tank spawn on the map, a menu should pop up when survivors leaves the saferoom to vote the tank player.

disawar1 08-01-2020 12:41

Re: [L4D & L4D2] Tank Pass
 
Quote:

Originally Posted by Pelee (Post 2712609)
Plugin bug:

In finale, if you pass the tank to a teammate, this counts as a progress for survivor teams and shortly after another tank spawns. Finale such as dark carnival progresses upon tank pass. Game breaking, please look into it

Request:

Can you add optional feature which allows us to vote who gets the next tank?

Such as if there is a tank spawn on the map, a menu should pop up when survivors leaves the saferoom to vote the tank player.

Bug were fixed in v2.2. Read notes.
I'm going to release the Tank vote plugin next week. I need to update the syntax and do other work.

Quote:

Originally Posted by SkiPlix (Post 2712549)
Rephrased some stuff in the plugin's translation.txt file.
&
Added Spanish translation.

@disawar1
Also maybe this is only on my server, but every time a tank spawns, 2 Tanks are created (Total 2 Tanks at the same time).

I use SDK Calls only when you confirm pass menu. Look for the problem elsewhere.

Pelee 08-01-2020 16:32

Re: [L4D & L4D2] Tank Pass
 
Quote:

Originally Posted by disawar1 (Post 2712631)
Bug were fixed in v2.2. Read notes.

That only blocks the command, doesn't fix the bug. It would be nice to be able to pass the tank in finale as well, without that bug. However, another solution to this could be the vote tank plugin. Some ideas: Make the vote menu show up in finale once survivor leaves the saferoom or once the finale stage begins and another time menu showing up when the first tank dies so the team can vote the 2nd finale tank and so on.


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

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