Szerző Téma: GivePlayerScore  (Megtekintve 659 alkalommal)

Nem elérhető Stramm

  • 193
    • Profil megtekintése
GivePlayerScore
« Dátum: 2013. Június 09. - 19:00:03 »
0 Show voters
Üdv azthogy kell hogy egy parancsra   
hozzá adjon a jelenlegi scorejához +1 et   vagyis ne át álítsa hanem hozzá adja

Nem elérhető ZyZu.

  • Globális moderátor
  • 8939
  • my turbo diesel forum
  • Discord: ZyZu.
    • Profil megtekintése
GivePlayerScore
« Válasz #1 Dátum: 2013. Június 09. - 19:04:16 »
0 Show voters
Létrehozol egy változót és sscanf segitségével egybe írod majd így hozzá adod:
Score[ playerid ]++;

Nem elérhető Stramm

  • 193
    • Profil megtekintése
GivePlayerScore
« Válasz #2 Dátum: 2013. Június 09. - 19:21:39 »
0 Show voters
Hát ezt egyáltalán nem értem.. 

Nem elérhető tudvari

  • 1264
  • Fejlesztő
    • Profil megtekintése
GivePlayerScore
« Válasz #3 Dátum: 2013. Június 09. - 19:40:10 »
0 Show voters
Próbáld ezt,nem tudom,hogy alapból definiálva van-e a GetPlayerScore,de szerintem igen.
 
new score = GetPlayerScore(playerid);
SetPlayerScore(playerid,score+1);

GivePlayerScore
« Válasz #4 Dátum: 2013. Június 09. - 20:02:27 »
0 Show voters
Minek egy fölösleges változó? Minek sscanf? Minek túlbonyolítani?
 
SetPlayerScore(playerid,GetPlayerScore(playerid)+1);

 
Ha meg egy GivePlayerScore-t akarsz akkor
 
stock GivePlayerScore(playerid, givescore)
{
     SetPlayerScore(playerid, GetPlayerScore(playerid)+givescore);
}

 
GivePlayerScore(játékosID, amennyipontotadjon);

 

SimplePortal 2.3.7 © 2008-2024, SimplePortal