AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Unapproved/Old Plugins (https://forums.alliedmods.net/forumdisplay.php?f=27)
-   -   Ultimate Revive (https://forums.alliedmods.net/showthread.php?t=76482)

anakin_cstrike 08-25-2008 11:55

Ultimate Revive
 
1 Attachment(s)
Ultimate Revive
v1.2

With this plugin on your server, you can revive a player,team or all players with x hp and x armor. Also, a nice green screen fade on revive :)

Changelog:

[1.2]
- changes in code
[1.1]
- Fixed bug at respawn
- You don't have to write the hp and armor arguments if you don't want to...the plugin uses the default values: 100 hp and 0 armor.
- Removed fun module

[1.0]
- First relesead

Credits:
- GHW_Chronic -- fakemeta functions
- VEN -- give_item stock

Modules: Fakemeta

Command:
amx_revive <player/@/@T/@CT> <hp> <armor> - respawn a player,team or all player with x hp and x armor. You don't have to write the hp and armor.
@ - all players
@T - terrorists
@CT - counter-terrorists

Info:
- If you don't type the hp and the armor, the plugin use the default values: 100 hp and 0 armor.
- Every player gets a knife,glock or a usp, depending on his team, and default ammo.
- If you want to change to color of the screnfade, change in sma:
Quote:

Fade(index,0,255,0,30);
- bold means editable - RGB format. 30 - alpha


Examples:
  • Single player - will respawn 'mut2nt' with 150 hp and 100 armor
    Code:

    amx_revive mut2nt 150 100
  • T team - will respawn all T players with 100 hp and 50 armor
    Code:

    amx_revive @T 100 50
  • CT team - will respawn all CT players with 50 hp and 0 armor
    Code:

    amx_revive @CT 50 0
  • All players - respawn all players with 1 hp and 0 armor
    Code:

    amx_revive @ 1 0
  • No armor argument - respawn player 'fps' with 50 hp and 0 armor
    Code:

    amx_revive fps 50
  • No arguments - respawn team T with 100 hp and 0 armor
    Code:

    amx_revive @T
Image: [IMG]http://img174.**************/img174/7922/revivesx2.th.png[/IMG]

Emp` 08-25-2008 12:07

Re: Ultimate Revive
 
No point in having these as globals: new name[32],namet[32],teamname[24],tname[16];

No need for this if(!arg3[0]) armor = 0 (if it is not a valid num str_to_num returns 0)

Instead of copying a tname, it is better to just use get_players within the if statements.

get_players is known to be buggy with the 'e' flag. (would recommend using another method to find players on a team)

I recommend you using @ALL instead of just @ as most other plugins use @ALL.

grimvh2 08-25-2008 12:31

Re: Ultimate Revive
 
just to prevent errors

PHP Code:

if(get_user_team(index) == 1)
{
    
// code
}
if(
get_user_team(index) == 2)
{
    
// this instead of else


ps. I think the online compiler supports fakemeta_util now

anakin_cstrike 08-25-2008 14:56

Re: Ultimate Revive
 
1. Global variables - changed
2. if(!arg3[0]) - changed
3. get_player - added "b" flag
4. @ - not changed

hleV 08-25-2008 15:23

Re: Ultimate Revive
 
FakeMeta & Fun? o_O

Howdy! 08-25-2008 15:24

Re: Ultimate Revive
 
You credited wrong person imo. give_item stock credit should go for VEN?

@
Quote:

Originally Posted by grimvh2 (Post 675490)
ps. I think the online compiler supports fakemeta_util now

Why include both if you can do the same with fakemeta only?

anakin_cstrike 08-25-2008 20:11

Re: Ultimate Revive
 
@ grimvh2 : changed
@ hleV : only fakemeta

anakin_cstrike 08-26-2008 17:50

Re: Ultimate Revive
 
1.0 -> 1.1...check first post!

Alka 09-29-2008 14:45

Re: Ultimate Revive
 
Waiting for a confirmation that works.

Gyuky 09-29-2008 15:39

Re: Ultimate Revive
 
I've tested and it works fine :)


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

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