Sign In

Sign In

    1. Created 15 September 2025

    CSHOT

    Siec tworzona z pasja, prężnie rozwijajacą się. Posiadamy serwery CS 1.6. Każdy znajdzie u nas coś dla siebie. Profesjonalne podejście administracji jak i adminów tworzy wspaniałą atmosferę na sieci. Jeśli masz

    1. Created 15 September 2025

    CSHOT

    Siec tworzona z pasja, prężnie rozwijajacą się. Posiadamy serwery CS GO. Każdy znajdzie u nas coś dla siebie. Profesjonalne podejście administracji jak i adminów tworzy wspaniałą atmosferę na sieci. Jeśli masz c

Partners

Awatar autora

Ostatnio dostępny?

Created Today  in PLUGINY  by Poster
[TITLE] Ostatnio dostępny?
[URL] https://amxx.pl/topic/6733-ostatnio-dostępny/


**Opis:**

Plugin poprzez wpisanie komendy wyświetla kiedy ostatnio jakiś gracz grał na
serwerze.
Czas jest pokazywany w formacie: lata, miesiące, dni, godziny, minuty, sekundy

**Instalacja:**

**Plik players_seen. amxx** wrzucamy do cstrike/addons/amxmodx/plugins
**Edytujemy plugins.ini** i dopisujemy na końcu: players_seen.amxx
**Plik players_seen.sma** wrzucamy do cstrike/addons/amxmodx/scripting
**Plik fdata.inc** wrzucamy do cstrike/addons/amxmodx/scripting/include
Restartujemy serwer lub zmienamy mapę.


**Komendy:**




say /seen x
say_team /seen x

gdzie w miejsce x wpisujemy nick gracza.

**Screen:**
[Image: 16438747og1.png]

**Plik fdata.inc :**




/*File Data Store System */
/*Type : Include*/
/* */
/* This file is provided as is (no warranties). */
/* */

stock fdata_exists(File[], Key[], Data[])
{
new Buffer[256], Currkey[128], Currvalue[64];
new Line = 0, Len, Currline = -1;

if(file_exists(File))
{
while((Line = read_file(File, Line++, Buffer, sizeof Buffer - 1, Len)))
{
if((Buffer[0] != '/' && Buffer[1] != '/') && Buffer[0] != ';')
{
strtok(Buffer, Currkey, sizeof Currkey - 1, Currvalue, sizeof Currvalue - 1, ';', 0);

if(equali(Currkey, Key))
{
copy(Data, 128, Currvalue);
Currline = Line - 1;

break;
}
else if(equal(Currkey,"") || !Currkey[0])
Currline = Line - 1;
}
}
}
else
{
static Num;
Num += 1;

server_print("Warning: Error #%d - File %s was not founded!", Num, File);
}
return Currline;
}

stock fdata_set(File[], Key[], Data[])
{
new Buffer[256], Blank[128];
new Line = fdata_exists(File, Key, Blank);

formatex(Buffer, sizeof Buffer - 1,"%s;%s", Key, Data);

write_file(File, Buffer, Line);

return Line;
}

stock fdata_get(File[], Key[], Data[])
{
new Line = fdata_exists(File, Key, Data);

return Line;
}

stock fdata_remove(File[], Key[])
{
new Data[128];
new Line = fdata_exists(File, Key, Data);

write_file(File,"", Line);

return Line;
}
Załączone pliki

* [url=https://amxx.pl/index.php?app=core&module=attach&section=attach&attach_id=1424 "Pobierz załącznik"][Image: unknown.gif][/url] [url=https://amxx.pl/index.php?app=core&module=attach&section=attach&attach_id=1424 "Pobierz załącznik"]**players_seen.amxx**[/url] **6,78 KB** 111 Ilość pobrań

* [url=https://amxx.pl/index.php?app=core&module=attach&section=attach&attach_id=1425 "Pobierz załącznik"][Image: sma.gif][/url] [url=https://amxx.pl/index.php?app=core&module=attach&section=attach&attach_id=1425 "Pobierz załącznik"]**players_seen.sma**[/url] **4,13 KB** 297 Ilość pobrań
[[Image: amxx.gif]**players_seen.amxx**](/kompilator/plugin/1425
"Pobierz plik AMXX")







Załączniki:
players_seen.sma