oto plugin
#include <amxmodx>
#include <amxmisc>
#include <fakemeta>
#define PLUGIN "Real HP"
#define VERSION "1.0"
#define AUTHOR "R3X"
#define CHANNEL 1
#define FRAMES 10
public plugin_init()
{
register_plugin(PLUGIN, VERSION, AUTHOR)
register_message(get_user_msgid("Health"),"message_health");
register_forward(FM_PlayerPreThink, "fwPreThink", 1);
}
public message_health(msg_id,msg_dest,msg_entity)
{
if(pev(msg_entity, pev_health) >= 255)
{
set_msg_arg_int(1, ARG_BYTE, 255);
}
return PLUGIN_CONTINUE;
}
public fwPreThink(id)
{
if(!is_user_alive(id))
return FMRES_IGNORED;
static iCounter[33]={0,...};
if(++iCounter[id] >= FRAMES)
{
set_hudmessage(0, 200, 200, 0.02, 0.91,0,0.0, 0.5,0.0,0.0,CHANNEL );
show_hudmessage(id, "HP: %d", pev(id, pev_health));
iCounter[id]=0;
}
return FMRES_IGNORED;
}Przemienilem to na to
#include <amxmodx>
#include <amxmisc>
#include <fakemeta>
#define PLUGIN "Real HP"
#define VERSION "1.0"
#define AUTHOR "R3X"
#define CHANNEL 1
#define FRAMES 10
public plugin_init()
{
register_plugin(PLUGIN, VERSION, AUTHOR)
register_message(get_user_msgid("Health"),"message_health");
register_message(get_user_msgid("armorr"),"message_armorr");
register_forward(FM_PlayerPreThink, "fwPreThink", 1);
register_forward(FM_PlayerPreThink, "fwPreThink", 2);
}
public message_health(msg_id,msg_dest,msg_entity)
{
if(pev(msg_entity, pev_health) >= 255)
{
set_msg_arg_int(1, ARG_BYTE, 255);
}
return PLUGIN_CONTINUE;
}
public message_armorr(msg_id,msg_dest,msg_entity)
{
if(pev(msg_entity, pev_armorr) >= 150)
{
set_msg_arg_int(1, ARG_BYTE, 255);
}
return PLUGIN_CONTINUE;
}
public fwPreThink(id)
{
if(!is_user_alive(id))
return FMRES_IGNORED;
static iCounter[33]={0,...};
if(++iCounter[id] >= FRAMES)
{
set_hudmessage(0, 200, 200, 0.02, 0.91,0,0.0, 0.5,0.0,0.0,CHANNEL );
show_hudmessage(id, "HP: %d", pev(id, pev_health));
iCounter[id]=0;
}
return FMRES_IGNORED;
}
1.error niemoge znależć pliku wyjsciowego kompilacji
Gdzie jest blad ???


Dodatki SourceMod



Temat jest zamknięty









