kolor_text(id, "^x04 [ AnimaLibera ] ^x03Zostales zabity przez ^x04 %s - [ HP: %s AP: %s ]", kname, health, armor)
Co mowilem o formatowaniu tekstu? ;>
Witamy w Nieoficjalnym polskim support'cie AMX Mod X, jak w większości społeczności internetowych musisz się zarejestrować aby móc odpowiadać lub zakładać nowe tematy, ale nie bój się to jest prosty proces w którym wymagamy minimalnych informacji.
|
Napisano 05.05.2009 22:18
kolor_text(id, "^x04 [ AnimaLibera ] ^x03Zostales zabity przez ^x04 %s - [ HP: %s AP: %s ]", kname, health, armor)
Napisano 05.05.2009 22:22
Napisano 06.05.2009 13:37
new SayText;
public plugin_init() {
register_plugin("Kolor", "1.0", "MaKeL")
register_clcmd("say a","Set_a")
SayText = get_user_msgid("SayText");
}
public Set_a(id)
{
kolor_text(id, "^x04 To ^x03 Dziala ^x04 SUPER !!!!")
}
stock kolor_text(index, const wiadomosc[])
{
new text[192];
formatex(text, 191, wiadomosc);
message_begin(MSG_ONE, SayText, _, index);
write_byte(index);
write_string(text);
message_end();
}wiec z tego skorzystalem #include <amxmodx>
#include <amxmisc>
#define PLUGIN "Info_po_smierci"
#define VERSION "1.0"
#define AUTHOR "Sinoku"
new SayText;
public plugin_init() {
register_plugin(PLUGIN, VERSION, AUTHOR)
SayText = get_user_msgid("SayText");
register_event("DeathMsg", "DeathMsg", "a")
}
public DeathMsg(id)
{
new armor
new health
new kid = read_data(1) //zabujca
new hs = read_data(2) // HeadShot (1 == true)
new weapon[64]
read_data(3,weapon,63) //krotka nazwa broni (bez weapon_ / CSW_ )
new kname[32]
get_user_name(kid,kname,31)
armor = get_user_armor(id)
health = get_user_health(id)
print_green(id, "~ [ AnimaLibera ] ~ Zostales zabity przez %s - [ HP: %s AP: %s ]", kname, health, armor)
if(hs)
{
print_green(id, "~ [ AnimaLibera ] ~ Gracz %s jebnol ci HeadShota! z %s",kname,weapon)
}
}
stock print_green(id,const fmt[],{Float,_}:...) { //this is my stock btw <img src='https://amxx.pl/public/style_emoticons/<#EMO_DIR#>/naughty.gif' class='bbc_emoticon' alt='^^' />
if(id && !is_user_connected(id)) return 0
static buffer[192]
buffer[0] = '^x04'
vformat(buffer[1],190, fmt,3)
message_begin(id ? MSG_ONE : MSG_ALL,SayText,{0,0,0},id)
write_byte(id)
write_string(buffer)
message_end()
return 1
}Napisano 07.05.2009 22:54
Napisano 07.05.2009 23:16
koniec rundy na say dla wszystkich wyswietla sie: - Najlepszym graczem rundy jest %s np Miczu! - Zabil %d graczy! np 3 - Jebnol %d HeadShoty!! np 2
0 użytkowników, 0 gości, 0 anonimowych