Szukam pluginu informacje o serwerze!
NeveR123
30.12.2016
Witam, poszukuje pluginu, który wyświetli będzie pokazywał informacje na serwerze od razu każdemu graczowi po wejściu na serwer.
Informacje takie jak:
Mod: JailBreak
Forum: twojeforum.pl
Ip: itd
Daje plusiki
Vakos
30.12.2016
Edytowałem pod twoją wersję
#include
#include
#include
#define PLUGIN "HUD"
#define AUTHOR "Wszechwiedzący"
#define VERSION "1.0"
public plugin_init()
{
register_plugin(PLUGIN, VERSION, AUTHOR)
}
public pokaz_hud(id)
{
if(is_user_connected(id))
{
new Time[9]
get_time("%H:%M:%S",Time,8)
set_hudmessage(0, 255, 0, 0.02, 0.23, 0, 0.0, 0.3, 0.0, 0.0)
show_hudmessage(id, "[Serwer: JailBreak]^n[Forum: twojeforum.pl]^n[IP:]^n[H@: ]^n[Kontakt: ]^n[VIP : %s]^n[Godzina : %s]^n",Time,get_user_flags(id) & ADMIN_LEVEL_G ? "Tak" : "Nie")
}
else
{
remove_task(id)
}
return PLUGIN_HANDLED
}
public client_putinserver(id)
{
set_task(1.0, "pokaz_hud", id,_,_,"b");
}
NeveR123
30.12.2016
Edytowałem pod twoją wersję
#include
#include
#include
#define PLUGIN "HUD"
#define AUTHOR "Wszechwiedzący"
#define VERSION "1.0"
public plugin_init()
{
register_plugin(PLUGIN, VERSION, AUTHOR)
}
public pokaz_hud(id)
{
if(is_user_connected(id))
{
new Time[9]
get_time("%H:%M:%S",Time,8)
set_hudmessage(0, 255, 0, 0.02, 0.23, 0, 0.0, 0.3, 0.0, 0.0)
show_hudmessage(id, "[Serwer: JailBreak]^n[Forum: twojeforum.pl]^n[IP:]^n[H@: ]^n[Kontakt: ]^n[VIP : %s]^n[Godzina : %s]^n",Time,get_user_flags(id) & ADMIN_LEVEL_G ? "Tak" : "Nie")
}
else
{
remove_task(id)
}
return PLUGIN_HANDLED
}
public client_putinserver(id)
{
set_task(1.0, "pokaz_hud", id,_,_,"b");
}
Mógłbyś includy dodać do tego? Bo ja nie wiem jakie, a mi sie skompilowac nie chce ;/
I jeszcze by to nie w HUD sie wyswietlalo tylko na say
Edited by NeveR123, 30.12.2016 16:20.
Vakos
30.12.2016
Wyżej napisałeś, że ci działa
Poprawione:
#include <amxmodx>
#include <amxmisc>
#include <csx>
#define PLUGIN "HUD"
#define AUTHOR "Wszechwiedzący"
#define VERSION "1.0"
public plugin_init()
{
register_plugin(PLUGIN, VERSION, AUTHOR)
}
public pokaz_hud(id)
{
if(is_user_connected(id))
{
new Time[9]
get_time("%H:%M:%S",Time,8)
set_hudmessage(0, 255, 0, 0.02, 0.23, 0, 0.0, 0.3, 0.0, 0.0)
show_hudmessage(id, "[Serwer: JailBreak]^n[Forum: twojeforum.pl]^n[IP:]^n[H@: ]^n[Kontakt: ]^n[VIP : %s]^n[Godzina : %s]^n",Time,get_user_flags(id) & ADMIN_LEVEL_G ? "Tak" : "Nie")
}
else
{
remove_task(id)
}
return PLUGIN_HANDLED
}
public client_putinserver(id)
{
set_task(1.0, "pokaz_hud", id,_,_,"b");
}
Jeżeli chcesz na say to możesz skorzystać z tego pluginu:
#include
#include
#include
/*
* TimeProjector displays the remaining time and the next map on the top right corner of the client
* display as a hudmessage.
*
* History:
*
* v0.1: - first release
*/
new gcvarForum;
public plugin_init()
{
register_plugin("plg :P","0.1","emblaze")
set_task(180.0, "showTimer",0,"",0,"b")
gcvarForum=register_cvar("amx_forum", "adres forum")
return PLUGIN_CONTINUE
}
public showTimer(id){
new nazwa[32]
get_cvar_string("hostname",nazwa,31)
ColorChat(id,GREEN, "**^x01 Witamy na: ^x03%s",nazwa);
new forum[32]
get_pcvar_string(gcvarForum,forum, 31)
ColorChat(id,GREEN, "**^x01 Forum serwera: ^x03%s",forum)
new nextmap[32]
get_cvar_string("amx_nextmap",nextmap,31)
ColorChat(id,GREEN, "**^x01 Nastepna mapa: ^x03%s", nextmap)
if (get_cvar_float("mp_timelimit"))
{
new a = get_timeleft()
if (get_cvar_num("amx_time_voice"))
{
}
ColorChat(id,GREEN, "**^x01 Czas do konca mapy: ^x03%d^x04:^x03%02d", (a / 60), (a % 60))
}
//Delay for order
set_task(0.1, "showRank", 1);
}
public showRank(id){
new izStats[8], izBody[8]
new iRankPos, iRankMax
new Players[32], playerCount;
get_players(Players, playerCount);
new id2;
for (new i=0; i id2 = Players[i];
iRankPos = get_user_stats(id2, izStats, izBody)
iRankMax = get_statsnum()
ColorChat(id2, GREEN, "**^x01 Twoj rank wynosi:^x04 %d^x01/^x04%d", iRankPos, iRankMax)
}
}
Edited by Vakos, 30.12.2016 16:33.
NeveR123
30.12.2016
Wyżej napisałeś, że ci działa
Poprawione:
#include <amxmodx>
#include <amxmisc>
#include <csx>
#define PLUGIN "HUD"
#define AUTHOR "Wszechwiedzący"
#define VERSION "1.0"
public plugin_init()
{
register_plugin(PLUGIN, VERSION, AUTHOR)
}
public pokaz_hud(id)
{
if(is_user_connected(id))
{
new Time[9]
get_time("%H:%M:%S",Time,8)
set_hudmessage(0, 255, 0, 0.02, 0.23, 0, 0.0, 0.3, 0.0, 0.0)
ColorChat(id, GREEN, "[Serwer: JailBreak]^n[Forum: twojeforum.pl]^n[IP:]^n[H@: ]^n[Kontakt: ]^n[VIP : %s]^n[Godzina : %s]^n",Time,get_user_flags(id) & ADMIN_LEVEL_G ? "Tak" : "Nie")
}
else
{
remove_task(id)
}
return PLUGIN_HANDLED
}
public client_putinserver(id)
{
set_task(1.0, "pokaz_hud", id,_,_,"b");
}
@@
Sprawdź czy jest na say
Nie mogę skompilować, błąd mam. tutaj ss:
Vakos
30.12.2016
Możesz spróbować tej wersji:
#include
#include
#include
/*
* TimeProjector displays the remaining time and the next map on the top right corner of the client
* display as a hudmessage.
*
* History:
*
* v0.1: - first release
*/
new gcvarForum;
public plugin_init()
{
register_plugin("plg :P","0.1","emblaze")
set_task(180.0, "showTimer",0,"",0,"b")
gcvarForum=register_cvar("amx_forum", "adres forum")
return PLUGIN_CONTINUE
}
public showTimer(id){
new nazwa[32]
get_cvar_string("hostname",nazwa,31)
ColorChat(id,GREEN, "**^x01 Witamy na: ^x03%s",nazwa);
new forum[32]
get_pcvar_string(gcvarForum,forum, 31)
ColorChat(id,GREEN, "**^x01 Forum serwera: ^x03%s",forum)
new nextmap[32]
get_cvar_string("amx_nextmap",nextmap,31)
ColorChat(id,GREEN, "**^x01 Nastepna mapa: ^x03%s", nextmap)
if (get_cvar_float("mp_timelimit"))
{
new a = get_timeleft()
if (get_cvar_num("amx_time_voice"))
{
}
ColorChat(id,GREEN, "**^x01 Czas do konca mapy: ^x03%d^x04:^x03%02d", (a / 60), (a % 60))
}
//Delay for order
set_task(0.1, "showRank", 1);
}
public showRank(id){
new izStats[8], izBody[8]
new iRankPos, iRankMax
new Players[32], playerCount;
get_players(Players, playerCount);
new id2;
for (new i=0; i id2 = Players[i];
iRankPos = get_user_stats(id2, izStats, izBody)
iRankMax = get_statsnum()
ColorChat(id2, GREEN, "**^x01 Twoj rank wynosi:^x04 %d^x01/^x04%d", iRankPos, iRankMax)
}
}
DarkGL
30.12.2016
Jeśli chcesz skompilować lokalnie plugin najpierw musisz ściągnąć pliki colorchat
NeveR123
30.12.2016
Jeśli chcesz skompilować lokalnie plugin najpierw musisz ściągnąć pliki colorchat
Mógłbyś mi edytować, aby ten plugin pokazywał się tylko i wyłącznie każdemu kto wejdzie od razu na serwer?? I tylko raz na jedna mape. czyli np wchodze na serwer i plugin sie pokazuje..
KOD