Szerző Téma: /goto megakadályozása  (Megtekintve 745 alkalommal)

Nem elérhető ObiWan

  • 596
    • Profil megtekintése
/goto megakadályozása
« Dátum: 2013. Szeptember 15. - 10:19:49 »
0 Show voters
Üdv mindenkinek!
Szeretnék egy olyan parancsot csinálni, amivel kitudom kapcsolni azt, hogy egy player hozzám teleportáljon, és vissza is lehessen kapcsolni..
Ez nekem nem ment eddig. Esetleg valaki megtudná nekem csinálni?

/goto megakadályozása
« Válasz #1 Dátum: 2013. Szeptember 15. - 11:55:17 »
+1 Show voters

Nem elérhető ObiWan

  • 596
    • Profil megtekintése
/goto megakadályozása
« Válasz #2 Dátum: 2013. Szeptember 15. - 12:18:49 »
0 Show voters
Idézetet írta: $$David$$ date=1379238917\" data-ipsquote-contentapp=\"forums\" data-ipsquote-contenttype=\"forums\" data-ipsquote-contentid=\"42753\" data-ipsquote-contentclass=\"forums_Topic
http://sampforum.hu/index.php?topic=8926.msg102504#msg102504
 
Köszi, ez jó, de nekem szét kellene szedni két külön parancsra a /setgoto parancsot. /gotooff és /gotoon

/goto megakadályozása
« Válasz #3 Dátum: 2013. Szeptember 17. - 23:24:44 »
0 Show voters
akkor csak cseréld ki ezt:
 
CMD:setgoto ( playerid, params [  ] )
{
    if ( GetPVarInt ( playerid, \"pGoto\" ) == 0  ) {
         SetPVarInt ( playerid, \"pGoto\", 1 );
         SendClientMessage ( playerid, 0x000000FF, \"Engedélyezted, hogy hozzád teleportálhassanak!\" );
    } else {
          SetPVarInt ( playerid, \"pGoto\", 0 );
          SendClientMessage ( playerid, 0x000000FF, \"Letiltottad, hogy hozzád teleportálhassanak!\" );
    }
    return 1;
}

 
erre:
 

CMD:setgoto ( playerid, params [  ] )
{
    if ( GetPVarInt ( playerid, \"pGoto\" ) == 0  ) {
         SetPVarInt ( playerid, \"pGoto\", 1 );
         SendClientMessage ( playerid, 0x000000FF, \"Engedélyezted, hogy hozzád teleportálhassanak!\" );
CMD:parancs ( playerid, params [ ] )
      if ( GetPVarInt ( playerid, \"pGoto\" ) == 0  ) {
          SetPVarInt ( playerid, \"pGoto\", 0 );
          SendClientMessage ( playerid, 0x000000FF, \"Letiltottad, hogy hozzád teleportálhassanak!\" );
    }
    return 1;
}

 
remélem segítettem de csak gondolkodni kellene !::D

Nem elérhető Flash

  • 5726
  • (っ◕‿◕)っ
    • Profil megtekintése
/goto megakadályozása
« Válasz #4 Dátum: 2013. Szeptember 18. - 17:03:57 »
0 Show voters
Idézetet írta: rcsbakos2 date=1379453084\" data-ipsquote-contentapp=\"forums\" data-ipsquote-contenttype=\"forums\" data-ipsquote-contentid=\"42753\" data-ipsquote-contentclass=\"forums_Topic
akkor csak cseréld ki ezt:
 
CMD:setgoto ( playerid, params [  ] )
{
    if ( GetPVarInt ( playerid, \"pGoto\" ) == 0  ) {
         SetPVarInt ( playerid, \"pGoto\", 1 );
         SendClientMessage ( playerid, 0x000000FF, \"Engedélyezted, hogy hozzád teleportálhassanak!\" );
    } else {
          SetPVarInt ( playerid, \"pGoto\", 0 );
          SendClientMessage ( playerid, 0x000000FF, \"Letiltottad, hogy hozzád teleportálhassanak!\" );
    }
    return 1;
}

 
erre:
 

CMD:setgoto ( playerid, params [  ] )
{
    if ( GetPVarInt ( playerid, \"pGoto\" ) == 0  ) {
         SetPVarInt ( playerid, \"pGoto\", 1 );
         SendClientMessage ( playerid, 0x000000FF, \"Engedélyezted, hogy hozzád teleportálhassanak!\" );
CMD:parancs ( playerid, params [ ] )
      if ( GetPVarInt ( playerid, \"pGoto\" ) == 0  ) {
          SetPVarInt ( playerid, \"pGoto\", 0 );
          SendClientMessage ( playerid, 0x000000FF, \"Letiltottad, hogy hozzád teleportálhassanak!\" );
    }
    return 1;
}

 
remélem segítettem de csak gondolkodni kellene !::D
 
Te is jó szarul írtad le.
tess:
 
CMD:agoto(playerid) {
if(GetPVarInt(playerid, \"agoto\")) {
SetPVarInt(playerid, \"agoto\", 1);
}else{
SetPVarInt(playerid, \"agoto\", 0);
}
new str[128];
format(str, sizeof(str), \"Sikeresen %s a hozzád való teleportálást.\", GetPVarInt(playerid, \"agoto\")?(\"engedélyezted\"):(\"letíltottad\"));
SendClientMessage(playerid, -1, str);
return 1;
}

 
Tíltás sor meg:
 
if(!GetPVarInt(id, \"agoto\")) return SendClientMessage(playerid, -1, \"Hiba. A játékosnak le van tíltva a hozzá való teleportálás.\");

Nem elérhető ObiWan

  • 596
    • Profil megtekintése
/goto megakadályozása
« Válasz #5 Dátum: 2013. Szeptember 21. - 08:10:12 »
0 Show voters
Kössz mindenkinek!

 

SimplePortal 2.3.7 © 2008-2024, SimplePortal