AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Plugins (https://forums.alliedmods.net/forumdisplay.php?f=108)
-   -   [CSS/CSGO] Revival 1.1.6 [2022/10/29] (https://forums.alliedmods.net/showthread.php?t=312838)

Grey83 12-17-2018 12:08

[CSS/CSGO] Revival 1.1.6 [2022/10/29]
 
10 Attachment(s)
Name: Revival

Description: Press and hold Shift, E or Ctrl key above death place to respawn player

Installation: Place compiled plugin (sm_revival.smx) into the plugins folder (../addons/sourcemod/plugins/).

Commands: sm_revival - show client's prefrences menu (key for revive, where show additional info and progressbar)

ConVars:
  • sm_revival_version - plugin version
  • sm_revival_enabled - Enable/disable plugin
  • sm_revival_tip - Enable/disable key tip at the beginning of the round
  • sm_revival_msg - Enable/disable chat messages (except tips)
  • sm_revival_key - Key for reviving (0 - 'duck', 1 - 'use', 2 - 'walk', 3 - no key needed)
  • sm_revival_pos - Spawn player at: 0 - position of reviver, 1 - his death position, 2 - team spawn point
  • sm_revival_clean - Remove body x sec after the death (-1 - don't remove)
  • sm_revival_dissolve - Dissolve effect when removing ragdolls: -1 - disable effect, 0 - Energy, 1 - Heavy electrical, 2 - Light electrical, 3 - Core effect
  • sm_revival_teamchange - Can a player be revived after a team change
  • sm_revival_no_end - Can a players be revived after a round end
  • sm_revival_enemy - Can a player revive the enemy (the revived player will change the team)
  • sm_revival_bar - Enable/disable progressbar
  • sm_revival_percent - Enable/disable save the percentage of reviving
  • sm_revival_effect - Enable/disable effect (circles) around to place of death
  • sm_revival_radius - Radius to respawn death player
  • sm_revival_time - The time after the death of the player, during which the revive is possible (0 - down to the end of the round)
  • sm_revival_countdown - Time for respawn in seconds
  • sm_revival_times - How many times can a player revive other players during the round (0 - unlimited)
  • sm_revival_reset - Reset counter of revived (for cvar 'sm_revival_times') at every: 0 - round, 1 - spawn
  • sm_revival_risings - How many times can a player will revived by other players during the round (0 - unlimited)
  • sm_revival_noblock_time - Noblocking time after respawn (set at 0 if you have any noblock plugin)
  • sm_revival_health_cost - Need's health to respawn (if value is less than 0, then this value will be added to the reviver)
  • sm_revival_maxhealth - The maximum amount of health that a reviver can receive for reviving players (0 - disable limit)
  • sm_revival_death - Can a player revive others if he have less HP than needed for reviving
  • sm_revival_health - How many HP will get revived player
  • sm_revival_frag - Give x frags to the player for revived teammate
  • sm_revival_rip - Disallow the revival of the players killed: 1 - in the head, 2 - with a knife, 3 - in the head or with a knife.
  • sm_revival_balance - The difference in the number of live players of the teams, at which player can revive allies (-1 - disable restriction)
  • sm_revival_soundpath - This sound playing after reviving (empty string = disabled)
  • sm_revival_nodmg_time - No damage recive time after respawn (set at 0.0 if you have any spawn protect plugin)
  • sm_revival_crouch - Crouch a revived player for a split second to avoid getting stuck in a space with a low height
  • sm_revival_color_t - T death mark color. Wrong color code = red
    *Set by HEX (RGB or RRGGBB, values 0 - F or 00 - FF, resp., any register).
  • sm_revival_color_ct - CT death mark color. Wrong color code = blue
  • sm_revival_color_any - Any death team mark color (sm_revival_enemy = 1). Wrong color code = green
  • sm_revival_best - Show TOPx revivers at round end (0 - disable)
  • sm_revival_worst - Show AntiTOPx revivers at round end (0 - disable)
  • sm_revival_mark_t - Path to the vmt-file in folder 'materials' for the T mark. Wrong or empty path = default mark.
  • sm_revival_mark_ct - Path to the vmt-file in folder 'materials' for the CT mark. Wrong or empty path = default mark.
  • sm_revival_mark_any - Path to the vmt-file in folder 'materials' for the Any mark. Wrong or empty path = default mark.
  • sm_revival_hud_x - HUD info position X (0.0 - 1.0 left to right or -1 for center)
  • sm_revival_hud_y - HUD info position Y (0.0 - 1.0 top to bottom or -1 for center)
  • sm_revival_hud_color - HUD info color. Set by HEX (RGB or RRGGBB, values 0 - F or 00 - FF, resp.). Wrong color code = green
  • sm_revival_hud_mode - Show additional info in the: 0 - chat only, 1 - HUD, 2 - KeyHint (not for CS:S v34)
  • sm_revival_together - Can more than 1 alive player try to revive a player at the same time (0 - 1 reviver per 1 dead player)
  • sm_revival_feed - Show revives in the killfeed to the: 1 - allies, 2 - enemies, 4 - spectators (all: 1+2+4 = 7).
  • sm_revival_last_man - Disable revives when only one player is alive on one of the teams
  • sm_revival_duel - Disable revives when both teams have one player alive

Natives & forward:
Code:

enum
{
        RI_Revives,        // How many times during this round the player reviveded others
        RI_Revived,        // How many times during this round the player was reviveded by others
        RI_Target,        // Player's current target for revive
        RI_Percents        // Progress in reviving the target
};

/**
 * Getting current player information by selected type
 *
 * @param сlient        Client index
 * @param type                Information type: RI_*
 * @return                Player information by selected type (-1 for wrong type)
 * @error                Invalid client index, client not connected, fake client or invalid information type.
 */
native int Revival_GetPlayerInfo(int сlient, int type);

/**
 * Setting current player values of selected type
 *
 * @param сlient        Client index
 * @param type                Information type: RI_*
 * @param value                Value of choosed type
 * @error                Invalid client index, client not connected, fake client, invalid information type or invalid value.
 */
native void Revival_SetPlayerInfo(int сlient, int type, int value);

/**
 * Called when a client changed status.
 *
 * @param reviver        Reviver index
 * @param target        Revive target index
 * @param frags                The number of frags that the reviver will receive
 * @param diff_hp        The amount by which the health of the reviver will be changed
 * @param health        The amount of health that the revival target will have (always > 0)
 */
forward void Revival_OnPlayerReviving(int reviver, int target, int &frags, int &diff_hp, int &health);

Starting from v1.0.7, the plugin supports text coloring in chat using tags: {DEFAULT}, {TEAM}, {GREEN}, {WHITE}, {RED},
{LIME}, {LIGHTGREEN}, {LIGHTRED}, {GRAY}, {LIGHTOLIVE}, {OLIVE}, {BLUEGREY}, {LIGHTBLUE}, {BLUE}, {PURPLE}, {LIGHTRED2}.
*Only the first 3 tags will be used in CSSv34, the rest will be removed from the text.

Screenshots: 1st (from v1.0.0), 2nd, 3rd, client's prefrences menu

https://github.com/favicon.ico GitHub

aykocity 12-17-2018 21:22

Re: [CSS/CSGO] Revival 1.0.3 [2018/12/17]
 
Thank you @Grey83
cs go work ?

Grey83 12-18-2018 07:07

Re: [CSS/CSGO] Revival 1.0.3 [2018/12/17]
 
aykocity, IDK: i don't have CSGO server for tests.
Should work without significant problems (not sure about progress bar).

arcticx2 12-18-2018 19:00

Re: [CSS/CSGO] Revival 1.0.3 [2018/12/17]
 
Noice ! will test it on csgo & update the results here

*edit : worked on csgo but as you mentioned no progress bar ! + a few errors :

Quote:

L 12/18/2018 - 16:13:06: [SM] Exception reported: Entity 297 (297) is not a CBaseEntity
L 12/18/2018 - 16:13:06: [SM] Blaming: sm_revival 1.0.3.smx
L 12/18/2018 - 16:13:06: [SM] Call stack trace:
L 12/18/2018 - 16:13:06: [SM] [0] AcceptEntityInput
L 12/18/2018 - 16:13:06: [SM] [1] Line 311, F:\steamcmd\l4d2_ds\left4dead2\addons\sourcem od\scripting_1.8.0\! Revival\sm_revival 1.0.3.sp::Timer_RemoveBody
L 12/18/2018 - 16:13:12: [SM] Exception reported: Entity 295 (295) is not a CBaseEntity
L 12/18/2018 - 16:13:12: [SM] Blaming: sm_revival 1.0.3.smx
L 12/18/2018 - 16:13:12: [SM] Call stack trace:
L 12/18/2018 - 16:13:12: [SM] [0] AcceptEntityInput
L 12/18/2018 - 16:13:12: [SM] [1] Line 311, F:\steamcmd\l4d2_ds\left4dead2\addons\sourcem od\scripting_1.8.0\! Revival\sm_revival 1.0.3.sp::Timer_RemoveBody
L 12/18/2018 - 16:13:14: [SM] Exception reported: Entity 295 (295) is not a CBaseEntity
L 12/18/2018 - 16:13:14: [SM] Blaming: sm_revival 1.0.3.smx
L 12/18/2018 - 16:13:14: [SM] Call stack trace:
L 12/18/2018 - 16:13:14: [SM] [0] AcceptEntityInput
L 12/18/2018 - 16:13:14: [SM] [1] Line 311, F:\steamcmd\l4d2_ds\left4dead2\addons\sourcem od\scripting_1.8.0\! Revival\sm_revival 1.0.3.sp::Timer_RemoveBody
i do not have l4d2 :D

Grey83 12-19-2018 07:32

Re: [CSS/CSGO] Revival 1.0.3 [2018/12/17]
 
Quote:

Originally Posted by arcticx2 (Post 2629859)
i do not have l4d2 :D

but I have 8)

Grey83 12-23-2018 07:06

[CSS/CSGO] Revival 1.0.4 [2018/12/23]
 
1 Attachment(s)
Changes:
  • Fixed error "Exception reported: Entity 295 (295) is not a CBaseEntity"
  • Some optimizations

arybagusoctora 12-25-2018 03:06

Re: [CSS/CSGO] Revival 1.0.4 [2018/12/23]
 
Can you make another setting, so player can spawn on last position when they died? need this great plugin for my deathmatch server with random spawn position.

Grey83 12-25-2018 06:18

Re: [CSS/CSGO] Revival 1.0.4 [2018/12/23]
 
arybagusoctora, players are always revives on the spot of their death.
If this is not the case, then some other plugin (deathmatch plugin) moves them after the revival.

arybagusoctora 12-25-2018 07:51

Re: [CSS/CSGO] Revival 1.0.4 [2018/12/23]
 
Quote:

Originally Posted by Grey83 (Post 2630880)
arybagusoctora, players are always revives on the spot of their death.
If this is not the case, then some other plugin (deathmatch plugin) moves them after the revival.

its ok, plugin work as expected. my bad. thanks for your great plugin, i appreciated your hard work!

Grey83 01-05-2019 08:45

Re: [CSS/CSGO] Revival 1.0.5 [2019/01/05]
 
Changes:
  • Now plugin can run at servers with CS:S v34 (without emo-sprite) and can be compiled using SM 1.9*.
  • The plugin no longer turns off when you turn off effects.
  • Other small fixes
*Zip-archive contains 2 versions of this plugin: compiled using SM 1.9 and compiled using SM 1.8


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

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