AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Suggestions / Requests (https://forums.alliedmods.net/forumdisplay.php?f=12)
-   -   how i make players get auto revived when they joined the server (https://forums.alliedmods.net/showthread.php?t=218724)

UaExFanTasY 06-20-2013 00:19

how i make players get auto revived when they joined the server
 
hello everybody

i want know something

on my deathmatch server i has a proplem

that's a people when they join the server

they dead so i have to revive them 1 by 1 and 1 time by my self

so how i make when anyone join the server get auto revive

because its deathmatch server

:cry:

Haskyutza 06-20-2013 02:02

Re: how i make players get auto revived when they joined the server
 
Take a look
http://forums.alliedmods.net/showpos...53&postcount=4

If you want only to revive when the player connected, delete this line
PHP Code:

RegisterHamHam_Killed"player""RespawnPlayer" ); 


UaExFanTasY 06-20-2013 12:04

Re: how i make players get auto revived when they joined the server
 
Quote:

#include <amxmodx>
#include <cstrike>
#include <hamsandwich>

new const PLUGIN[] = "Auto Respawn"
new const VERSION[] = "1.0"
new const AUTHOR[] = "platzpatrone"

public plugin_init()
{
register_plugin(PLUGIN, VERSION, AUTHOR)
RegisterHam( Ham_Killed, "player", "RespawnPlayer" );

register_event("TextMsg","team_join","a","1=1","2&Game_join_te","2&Game_join_ct")

}

public RespawnPlayer(id)
{
if (get_user_team(id) == 3)
return PLUGIN_HANDLED

if (!is_user_alive(id))
{
ExecuteHamB(Ham_CS_RoundRespawn, id);
}

return PLUGIN_CONTINUE
}

public team_join(id)

here is the plugins can u do it for me
I want it to be auto revive on connect and only 1 time enaugh

Moody92 06-20-2013 13:15

Re: how i make players get auto revived when they joined the server
 
Really ? he gave you the key you only have to put it in the right lock.

PHP Code:

#include <amxmodx>
#include <cstrike>
#include <hamsandwich>
 
new const PLUGIN[]  = "Auto Respawn"
new const VERSION[] = "1.0"
new const AUTHOR[]  = "platzpatrone"

public plugin_init()
{
    
register_plugin(PLUGINVERSIONAUTHOR)
    
    
register_event("TextMsg","team_join","a","1=1","2&Game_join_te","2&Game_join_ct")
    
}

public 
RespawnPlayer(id)
{
    if (
get_user_team(id) == 3)
        return 
PLUGIN_HANDLED
        
    
if (!is_user_alive(id))
    {
        
ExecuteHamB(Ham_CS_RoundRespawnid);
    }

    return 
PLUGIN_CONTINUE
}

public 
team_join(id)
{
      
set_task(12.0"RespawnPlayer"id);



UaExFanTasY 06-21-2013 02:46

Re: how i make players get auto revived when they joined the server
 
not work its crash the server =.=

TheDS1337 06-21-2013 04:34

Re: how i make players get auto revived when they joined the server
 
Untested
Code:
#include < amxmodx > #include < amxmisc > #include < hamsandwich > new g_pluginInformations[ 3 ][ ] = {     "Respawn Player On Connect",     "1.0",     "De{a}gLe" }; public plugin_init( )     register_plugin( g_pluginInformations[ 0 ], g_pluginInformations[ 1 ], g_pluginInformations[ 2 ] );     public client_putinserver( client ) {     if( !is_user_alive( client ) || get_user_team( client != 3 ) )         ExecuteHamB( Ham_CS_RoundRespawn, client ); }

EpicMonkey 06-21-2013 05:06

Re: how i make players get auto revived when they joined the server
 
Quote:

Originally Posted by DeagLe.Studio (Post 1974187)
Untested
Code:
#include < amxmodx > #include < amxmisc > #include < hamsandwich > new g_pluginInformations[ 3 ][ ] = {     "Respawn Player On Connect",     "1.0",     "De{a}gLe" }; public plugin_init( )     register_plugin( g_pluginInformations[ 0 ], g_pluginInformations[ 1 ], g_pluginInformations[ 2 ] );     public client_putinserver( client ) {     if( !is_user_alive( client ) && get_user_team( client != 3 ) )         ExecuteHamB( Ham_CS_RoundRespawn, client ); }

Which team does a player belong to when he joins a server?

TheDS1337 06-21-2013 05:09

Re: how i make players get auto revived when they joined the server
 
Quote:

Originally Posted by EpicMonkey (Post 1974195)
Which team does a player belong to when he joins the server?

Only DEAD T and CT.

oxygen935 06-21-2013 05:44

Re: how i make players get auto revived when they joined the server
 
Quote:

Originally Posted by DeagLe.Studio (Post 1974187)
Untested
Code:
#include < amxmodx > #include < amxmisc > #include < hamsandwich > new g_pluginInformations[ 3 ][ ] = {     "Respawn Player On Connect",     "1.0",     "De{a}gLe" }; public plugin_init( )     register_plugin( g_pluginInformations[ 0 ], g_pluginInformations[ 1 ], g_pluginInformations[ 2 ] );     public client_putinserver( client ) {     if( !is_user_alive( client ) && get_user_team( client != 3 ) )         ExecuteHamB( Ham_CS_RoundRespawn, client ); }

This will cause bugs cause he will respawn the player and also if the player will not have choosen any team...
Use uaxfantasy's plugin istead of this

Kia 06-21-2013 08:30

Re: how i make players get auto revived when they joined the server
 
PHP Code:

new g_pluginInformations][ ] =
{
    
"Respawn Player On Connect",
    
"1.0",
    
"De{a}gLe"
}; 

Can't express how useless this is..


All times are GMT -4. The time now is 05:25.

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