Szerző Téma: Átnevezve : Alap AFK rendszer  (Megtekintve 709 alkalommal)

Átnevezve : Alap AFK rendszer
« Dátum: 2013. június 21. - 20:48:43 »
+1 Show voters
Üdv
 
Gondoltam feldobom ezt az afk rendszert :) igy hát fel is dobtam
Parancsok:
/AFk
/Back
/afklist
 
#define FILTERSCRIPT         
#include <a_samp>           
#include <zcmd>             
#define blue 0x0FFDD349     
#define red 0xAA3333AA       
    new pName[24];
    new str[128];
    new pName2[24];
    new str2[128]; //^^
        new IsAFK[MAX_PLAYERS];
        public OnFilterScriptInit()
    {
            print(\"\\n-----------------------------------------------------------\");
            print(\" Thosir Simpla AFK Rendszere Betöltve.\");
            print(\"-----------------------------------------------------------\\n\");
                        return 1;
    }
    public OnFilterScriptExit()
    {
            print(\"\\n----------------------------------\");
            print(\" Thosiro AFK Rendszere Terheletlen.\");
            print(\"------------------------------------\\n\");
            return 1;
    }
        public OnPlayerConnect(playerid)
        {
                IsAFK[playerid] = 0;
        }
    command(afk, playerid, params[])
    {
                if(IsAFK[playerid] == 0)
                {
            TogglePlayerControllable(playerid,0);
            GetPlayerName(playerid, pName, 24);
            format(str, 128, \"%s AFK-ba van! (Nincs gépnél)\", pName);
            SendClientMessageToAll(blue, str);
                        IsAFK[playerid] = 1;
                }
        else return SendClientMessage(playerid, blue, \"Te most AFK-zol!\");
                return 1;
    }
    command(back, playerid, params[])
    {
                if(IsAFK[playerid] == 1)
                {
            TogglePlayerControllable(playerid,1);
            GetPlayerName(playerid, pName2, 24);
            format(str2, 128, \"%s visszatért a géphez!\", pName2);
            SendClientMessageToAll(blue, str2);
                        IsAFK[playerid] = 0;
                }
                else return SendClientMessage(playerid, blue, \"Már nem vagy AFK modban!\");
                return 1;
    }
command(afklist, playerid, params)
{
        new pString[MAX_PLAYER_NAME], pName3[MAX_PLAYER_NAME];
        for(new pID = 0; pID < MAX_PLAYERS; pID ++)
        {
        if(IsPlayerConnected(pID))
                {
                        if(IsAFK[pID] == 1)
                        {
                                SendClientMessage(playerid, 0xFFFFFFFF, \"A játékos jelenleg AFK:\");
                                GetPlayerName(playerid, pName3, sizeof(pName3));
                                format(pString, sizeof(pString), \"%s\", pName3);
                                SendClientMessage(playerid, 0xFFFFFFFF, pString);
}
        }
                }
        return 1;
                        }

 
                   //kecskéké a világ
« Utoljára szerkesztve: 2013. június 23. - 16:04:16 írta Thosiro »

Nem elérhető Rupert

  • 2301
    • Profil megtekintése
Átnevezve : Alap AFK rendszer
« Válasz #1 Dátum: 2013. június 21. - 21:32:10 »
0 Show voters
Miért rendszer?
Sorry. Szúrja a szemem.

Nem elérhető huhboy

  • 894
  • huhboy
    • Profil megtekintése
Átnevezve : Alap AFK rendszer
« Válasz #2 Dátum: 2013. június 21. - 21:37:04 »
+2 Show voters
print(\"\\n-----------------------------------------------------------\"); //Prints a message on samp-server.exe saying the script has loaded successfully.
            print(\" Thosir Simpla AFK Rendszere Betöltve.\");
            print(\"-----------------------------------------------------------\\n\");

 
ahhoz képest, hogy eszerint a tiéd, az összes komment angol xd

Nem elérhető Flash

  • 5726
  • (っ◕‿◕)っ
    • Profil megtekintése
Átnevezve : Alap AFK rendszer
« Válasz #3 Dátum: 2013. június 21. - 22:37:45 »
+2 Show voters
Gratulálok bazdmeg te vagy a 100000 személy aki AFK \"scriptet\" töltött fel a fórumra, nyereménye: örök ban csá :DDD

Átnevezve : Alap AFK rendszer
« Válasz #4 Dátum: 2013. június 21. - 22:43:42 »
0 Show voters
Idézetet írta: Flash date=1371847065\" data-ipsquote-contentapp=\"forums\" data-ipsquote-contenttype=\"forums\" data-ipsquote-contentid=\"38740\" data-ipsquote-contentclass=\"forums_Topic
Gratulálok ***dmeg te vagy a 100000 személy aki AFK \"scriptet\" töltött fel a fórumra, nyereménye: örök ban csá :DDD
 
már mért is lenne ban ? Am igaz kurva sok van :/ és nem valami nagy dolog... Törlöm

Nem elérhető huhboy

  • 894
  • huhboy
    • Profil megtekintése
Átnevezve : Alap AFK rendszer
« Válasz #5 Dátum: 2013. június 22. - 11:06:12 »
0 Show voters
egyébként, ha így csinálod, akkor legalább nem ölik meg a playert, amíg afk-ban van....(akinek nem tûnne fel, világot vált xd)
 

command(afk, playerid, params[]) //The AFK Command
    {
                if(IsAFK[playerid] == 0) //Checks if the player is not already AFK.
                {
            TogglePlayerControllable(playerid,0); //Makes the player not controllable on the /afk command.
            GetPlayerName(playerid, pName, 24);
            //__________________Kiegészítés________________
            SetPlayerVirtualWorld(playerid, 1);
            //___________________________________________
            format(str, 128, \"%s AFK-ba van! (Nincs gépnél)\", pName); //The message it will send when a player types /afk.
            SendClientMessageToAll(blue, str); //Sends the message to all players
                        IsAFK[playerid] = 1; //Tells the system the player is AFK.
                }
        else return SendClientMessage(playerid, blue, \"Te most AFK-zol!\");//Sends an error message if the player is already AFK.
                return 1;
    }
    command(back, playerid, params[]) //The Back Command
    {
                if(IsAFK[playerid] == 1) //Checks to see if the player is AFK.
                {
            TogglePlayerControllable(playerid,1); //Makes the player controllable on the /back command.
            GetPlayerName(playerid, pName2, 24);
            //__________________Kiegészítés________________
            SetPlayerVirtualWorld(playerid, 0);
            //___________________________________________
            format(str2, 128, \"%s visszatért a géphez!\", pName2); //The message it will send when the player types /back.
            SendClientMessageToAll(blue, str2); //Sends the message to all players.
                        IsAFK[playerid] = 0; //Tells the system the player is not AFK.
                }
                else return SendClientMessage(playerid, blue, \"Már nem vagy AFK modban!\");
                return 1;
    }
« Utoljára szerkesztve: 2013. június 22. - 11:10:04 írta huhboy »

Átnevezve : Alap AFK rendszer
« Válasz #6 Dátum: 2013. június 22. - 13:00:51 »
0 Show voters
  SetPlayerVirtualWorld(playerid, 1);

 

Idézetet írta: huhboy date=1371891972\" data-ipsquote-contentapp=\"forums\" data-ipsquote-contenttype=\"forums\" data-ipsquote-contentid=\"38740\" data-ipsquote-contentclass=\"forums_Topic

egyébként, ha így csinálod, akkor legalább nem ölik meg a playert, amíg afk-ban van....(akinek nem tûnne fel, világot vált xd)
Igen látom :) köszi ennek majd talán 1 x hasznát veszem
[/quote]

xD1999

  • Vendég
Átnevezve : Alap AFK rendszer
« Válasz #7 Dátum: 2013. június 23. - 08:04:54 »
0 Show voters
Miért angol?
És nekem teccik !ment a \"+\"

Átnevezve : Alap AFK rendszer
« Válasz #8 Dátum: 2013. június 23. - 09:38:41 »
0 Show voters
Idézetet írta: xD1999 date=1371967494\" data-ipsquote-contentapp=\"forums\" data-ipsquote-contenttype=\"forums\" data-ipsquote-contentid=\"38740\" data-ipsquote-contentclass=\"forums_Topic
Miért angol?
 
A lényeget leforditottam az a lényeg :D
és THX

Nem elérhető CANNONN

  • 2139
    • Profil megtekintése
Átnevezve : Alap AFK rendszer
« Válasz #9 Dátum: 2013. június 23. - 09:41:25 »
0 Show voters
Idézetet írta: Thosiro date=1371973121\" data-ipsquote-contentapp=\"forums\" data-ipsquote-contenttype=\"forums\" data-ipsquote-contentid=\"38740\" data-ipsquote-contentclass=\"forums_Topic


Miért angol?
 
A lényeget leforditottam az a lényeg :D
és THX
 
[/quote]
[mod]Tehát te csak lefordítottad?[/mod]

Nem elérhető Flash

  • 5726
  • (っ◕‿◕)っ
    • Profil megtekintése
Átnevezve : Alap AFK rendszer
« Válasz #10 Dátum: 2013. június 23. - 14:53:16 »
0 Show voters
De most ez mi már, hogy mindenki feltölti az általa készített AFK scriptet.. van vagy 1000 féle lassan, közbe csak annyi a lényege, hogy le/ki fagyasszon, és ez scmtoall.. Ezt még lehetne bõvíteni bõven, ízlés/tetszés szerint is persze de legalább adjuk meg a módját, hogy ügyeljünk a script szépségére, hogy legyen minél érthetõbb, a saját nyelvünkön írjuk a scriptet stb-t..

 

SimplePortal 2.3.7 © 2008-2024, SimplePortal