Problem z "złamaną nogą" - przekrę...
Acer 21.11.2011
Mam problem, mianowicie niektórzy gracze raz na kiedyś mają błąd:
Monitor przekręcony o 90 stopni "złamana noga na jedną stronę "
Przy tym niema żadnych błędów w konsoli.
Daje sma w załączniku
Monitor przekręcony o 90 stopni "złamana noga na jedną stronę "
Przy tym niema żadnych błędów w konsoli.
Daje sma w załączniku
Załączone pliki
Acer 21.11.2011
Mam go wgrany cały czas na serwerze Dark, a poza tym sam napisałeś:
Więc jakieś inne pomysły?0 HP Bug
Naprawia bugi które ukazują się gdy gracz ma więcej hp niż 255 (zmiana sterowania itp.)
uwaga ! plugin działa ale nie na cod modzie
sebul
21.11.2011
Z tego co z grubsza spojrzałem w kod, to chyba wystarczy wywalić z kodu funkcję "MessageHealth" oraz jej rejestrację w plugin_init i wtedy wgrać plugin podany przez darka.
M3nt0s 22.11.2011
Usun w silniku:
Oraz:
A następnie wgraj na serwer taki plugin:
Lub bez wiadomosci w hud
I wszystko będzie pięknie
register_message(get_user_msgid("Health"),"MessageHealth");
Oraz:
public MessageHealth(msg_id, msg_dest, msg_entity)
{
static health;
health = get_msg_arg_int(1);
if (health < 256) return;
if (!(health % 256))
set_pev(msg_entity, pev_health, pev(msg_entity, pev_health)-1);
set_msg_arg_int(1, get_msg_argtype(1), 255);
}
A następnie wgraj na serwer taki plugin:
#include <amxmodx>
#include <amxmisc>
#include <fakemeta>
#define PLUGIN "HP BUG"
#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, 255, 0, 0.02, 0.23, 0, 0.0, 0.3, 0.0, 0.0);
show_hudmessage(id, "HP: %d", pev(id, pev_health));
iCounter[id]=0;
}
return FMRES_IGNORED;
}
Lub bez wiadomosci w hud
#include <amxmodx>
#include <amxmisc>
#include <fakemeta>
#define PLUGIN "HP BUG"
#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");
}
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;
}
I wszystko będzie pięknie
Użytkownik M3nt0s edytował ten post 22.11.2011 19:51