AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Plugins (https://forums.alliedmods.net/forumdisplay.php?f=108)
-   -   [L4D1 & L4D2] SM Respawn Improved (https://forums.alliedmods.net/showthread.php?t=323220)

Dragokas 04-14-2020 21:18

[L4D1 & L4D2] SM Respawn Improved
 
1 Attachment(s)
Description:
Adds ability to respawn player:
  • from admin menu
  • from console
  • from 3-rd party plugins using native
without losing statistics.

This is fork, improved version based on v1.9.5 from this topic. See changelog below.
Features:
  • Allow respawning even a spectator (with team selection)
  • Ability to spawn in crouch pose (like inside the transport / duct with limited height of space)
  • Very accurate positioning at crosshair preventing the collision
  • Lot of customization in respawn position (see ConVars and l4d_sm_respawn.inc)
  • Allow to switch the team (e.g. using sm_respawnex command)

Commands:
sm_respawn - Opens menu to select players for respawning.
sm_respawn <target> - Respawn a player at your crosshair.
sm_respawnex - Extended respawn options. Alternative to SM_Respawn() native. See the "Natives" section.
Settings (ConVars):
cfg/sourcemod/l4d_sm_respawn.cfg:
PHP Code:

// Respawn survivor players with this loadout
// For the list of valid names see here: https://github.com/raziEiL/l4d2_weapons/blob/e7d7d75518150aea155acc3c37ff79f15e994b99/scripting/include/l4d2_weapons.inc#L149
l4d_sm_respawn_loadout "smg,pistol,pain_pills"

// Notify in chat and log about the respawn action? (0 - No, 1 - Yes)
l4d_sm_respawn_showaction "1"

// Add 'Respawn player' item in admin menu under 'Player commands' category? (0 - No, 1 - Yes)
l4d_sm_respawn_adminmenu "1"

// Where to respawn? (1 - next to you or alive player, 2 - at your crosshair, 32 - TakeOver bot firstly. You can combine with SPAWN_POSITION values, see .inc file)
l4d_sm_respawn_position "34"

// What teams to display in respawn menu? (2 - Spectators, 4 - Survivors, 8 - Infected, 16 - Dead only, 32 - No surv.bots, 64 - No inf.bots. You can combine)
l4d_sm_respawn_teams "78"

// Respawn infected player as ghost? (1 - Yes, 0 - No, instant respawn)
l4d_sm_respawn_ghost "1"

// Admin flag(s) required to use the respawn command
l4d_sm_respawn_accessflag "d" // (ban) 

Natives:
Spoiler


Installation
- Just unpack /l4d_sm_respawn/ and copy to server.
- If you update from the original 1.x version, perhaps you may want to remove "Respawn Survivor" entry from "configs/adminmenu_custom.txt" file (not required anymore, unless you are using adminmenu_sorting.txt feature).
- If you want to use custom admin. menu items sorting (like, to make "Respawn Player" item to be the first in the list), here are required correct settings:
(optionally) adminmenu_custom.txt

(optionally) adminmenu_sorting.txt
P.S. You don't need l4d_native_usage_sample.sp file. It is an example for developers, how to use natives.
Credits
- AtomicStryker & Ivailosp - original authors
- doku - for original idea and sig
- Crasher - for updates
- SilverShot - for explaining me opcodes, tools, his patch samples and a lot of patience
- MicroLeo - some code and signatures
- Shadowysn - some signatures
ChangeLog:
Spoiler


Donate
Donates are very appreciated and welcomed for further inspiration, make me happy, and make next updates came out more often:
- Patreon (Paypal)
- BitCoin
- Ю.Money
P.S.:
- Project and updates discontinued. Don't ask.

SkiPlix 04-15-2020 10:13

Re: [L4D & L4D2] SM Respawn Improved
 
1 Attachment(s)
Added Spanish translation.

Enzyoo 04-15-2020 10:22

Re: [L4D & L4D2] SM Respawn Improved
 
1 Attachment(s)
Added Swedish translation!

hoanganh81097 04-16-2020 13:25

Re: [L4D & L4D2] SM Respawn Improved
 
sometime, survivors lost body when they die :(
Quote:

L 04/16/2020 - 10:16:39: [SM] Exception reported: Client index 0 is invalid
L 04/16/2020 - 10:16:39: [SM] Blaming: l4d_sm_respawn.smx
L 04/16/2020 - 10:16:39: [SM] Call stack trace:
L 04/16/2020 - 10:16:39: [SM] [0] IsFakeClient
L 04/16/2020 - 10:16:39: [SM] [1] Line 318, C:\Users\Admin\Desktop\scripting 1.10\l4d_sm_respawn.sp::eDeadSurvivorVisible
L 04/16/2020 - 10:16:39: [SM] Exception reported: Client index 0 is invalid
L 04/16/2020 - 10:16:39: [SM] Blaming: l4d_sm_respawn.smx
L 04/16/2020 - 10:16:39: [SM] Call stack trace:
L 04/16/2020 - 10:16:39: [SM] [0] IsFakeClient
L 04/16/2020 - 10:16:39: [SM] [1] Line 318, C:\Users\Admin\Desktop\scripting 1.10\l4d_sm_respawn.sp::eDeadSurvivorVisible
L 04/16/2020 - 10:41:45: [SM] Exception reported: Client 15 is not in game

Dragokas 04-17-2020 00:51

Re: [L4D & L4D2] SM Respawn Improved
 
Thanks.

Updated.

Quote:

2.1 (17-Apr-2020)
- Fixed that strange code for clearing player's dead body after respawn in L4D2.
- Added Hungarian translation (thanks to KasperH).
- Added Spanish translation (thanks to SkiPlix).
- Added Swedish translation (thanks to Enzyoo).

HarryPotter 04-21-2020 08:04

Re: [L4D & L4D2] SM Respawn Improved
 
1 Attachment(s)
Add traditional Chinese and Simplified Chinese

Tonblader 06-08-2020 01:23

Re: [L4D & L4D2] SM Respawn Improved
 
when i use sm_respawn @dead
not all bodies are removed, and something similar happens when there are more than 5+ coop players, they disconnect but their bodies do not disappear.

maclarens 07-31-2020 05:36

Re: [L4D & L4D2] SM Respawn Improved
 
hello!can u add cvar limit revive?!players abuse it a lot revive command..

Dragokas 07-31-2020 05:53

Re: [L4D & L4D2] SM Respawn Improved
 
no, so don't give admin access or whatever to your players.

HarryPotter 07-31-2020 09:11

Re: [L4D & L4D2] SM Respawn Improved
 
Quote:

Originally Posted by Tonblader (Post 2704566)
when i use sm_respawn @dead
not all bodies are removed, and something similar happens when there are more than 5+ coop players, they disconnect but their bodies do not disappear.

This plugin just gives adm the access to respawn the player, it does not remove the dead body
try this
https://forums.alliedmods.net/showthread.php?p=2647018


All times are GMT -4. The time now is 16:52.

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