Szerző Téma: Inventory  (Megtekintve 3295 alkalommal)

Nem elérhető Sanyko

  • 324
    • Profil megtekintése
Inventory
« Dátum: 2016. Június 16. - 08:27:59 »
0 Show voters
Sziasztok! Van egy modom és kell neki az inventory.inc Letöltöttem és ha valamit veszek akkor azt írja ki hogy betelt a tárhelyed üríts belőle! Képek:
<a href=\"http://www.kephost.com/image/cPCF\"><img src=\"http://www.kephost.com/images/2016/06/16/sa-mp-016.md.png\" alt=\"sa-mp-016.md.png\" border=\"0\"></a>
<a href=\"http://www.kephost.com/image/cPCS\"><img src=\"http://www.kephost.com/images/2016/06/16/sa-mp-013.md.png\" alt=\"sa-mp-013.md.png\" border=\"0\"></a>
<a href=\"http://www.kephost.com/image/cPCc\"><img src=\"http://www.kephost.com/images/2016/06/16/sa-mp-014.md.png\" alt=\"sa-mp-014.md.png\" border=\"0\"></a>
<a href=\"http://www.kephost.com/image/cPCv\"><img src=\"http://www.kephost.com/images/2016/06/16/sa-mp-015.md.png\" alt=\"sa-mp-015.md.png\" border=\"0\"></a>

Nem elérhető 1Mark6

  • 437
    • Profil megtekintése
Inventory
« Válasz #1 Dátum: 2016. Június 16. - 08:38:27 »
0 Show voters
Ha az Inventory.inc-ből vagy a módból megadnád azt a pár sort ahol ez az üzenet található, talán tudnánk segiteni, így kép alapján esetleg képről olvasni tudunk. :(

Nem elérhető Sanyko

  • 324
    • Profil megtekintése
Inventory
« Válasz #2 Dátum: 2016. Június 16. - 08:45:12 »
0 Show voters
Idézetet írta: 1Mark6 date=1466059107\" data-ipsquote-contentapp=\"forums\" data-ipsquote-contenttype=\"forums\" data-ipsquote-contentid=\"60879\" data-ipsquote-contentclass=\"forums_Topic
Ha az Inventory.inc-ből vagy a módból megadnád azt a pár sort ahol ez az üzenet található, talán tudnánk segiteni, így kép alapján esetleg képről olvasni tudunk. :(
 

stock AddItem(playerid,item[],amount)
{
if(amount <= 0) return 0;
new bool: count[2] = false;
for(new i; i<MAX_ITEMS; i++)
{
    if(CompareEx(ItemName[playerid],item))
    {
   count[0] = true;
        ItemAmount[playerid] += amount;
        return 1;
}
}
if(count[0] == false)
{
    for(new i; i<MAX_ITEMS; i++)
{
    if(CompareEx(ItemName[playerid],\"Üres\"))
    {
      count[1] = true;
      format(ItemName[playerid],128,\"%s\",item);
        ItemAmount[playerid] = amount;
        return 1;
   }
}
}
if(count[1] != true) return SendClientMessage(playerid,-1, \"Betelt a tárhelyed, üríts belőle.\");
return 0;
}

 
Erre gondolsz?

Nem elérhető ZyZu.

  • Globális moderátor
  • 8939
  • my turbo diesel forum
  • Discord: ZyZu.
    • Profil megtekintése
Inventory
« Válasz #3 Dátum: 2016. Június 16. - 08:49:55 »
0 Show voters

Nem elérhető Sanyko

  • 324
    • Profil megtekintése
Inventory
« Válasz #4 Dátum: 2016. Június 16. - 08:53:08 »
0 Show voters
Idézetet írta: ƒeheristi97 date=1466059795\" data-ipsquote-contentapp=\"forums\" data-ipsquote-contenttype=\"forums\" data-ipsquote-contentid=\"60879\" data-ipsquote-contentclass=\"forums_Topic
http://www.solidfiles.com/d/a16ca841c4/
 
Ezt használom én is

Nem elérhető 1Mark6

  • 437
    • Profil megtekintése
Inventory
« Válasz #5 Dátum: 2016. Június 16. - 08:56:56 »
0 Show voters
Az a feltételezésem, hogy a többi Item neve nem ez : \"Üres\", mert a kód csak ezeket érzékeli, és akkor lesz a count[1]  = true, de mivel false ezért kapod a hibaüzenetet.

Nem elérhető Sanyko

  • 324
    • Profil megtekintése
Inventory
« Válasz #6 Dátum: 2016. Június 16. - 08:59:21 »
0 Show voters
Idézetet írta: 1Mark6 date=1466060216\" data-ipsquote-contentapp=\"forums\" data-ipsquote-contenttype=\"forums\" data-ipsquote-contentid=\"60879\" data-ipsquote-contentclass=\"forums_Topic
Az a feltételezésem, hogy a többi Item neve nem ez : \"Üres\", mert a kód csak ezeket érzékeli, és akkor lesz a count[1]  = true, de mivel false ezért kapod a hibaüzenetet.
 
Hogy lehet megcsinálni ha pl veszek egy laptopot akkor legyen benne?

Nem elérhető 1Mark6

  • 437
    • Profil megtekintése
Inventory
« Válasz #7 Dátum: 2016. Június 16. - 09:02:10 »
0 Show voters
A slotoknak \"Üres\"-nek kell lennie, ahhoz, hogy a rendszer bármit is hozzátudjon adni, szerintem ez nálad nem / nem így szerepel, ha megkérhetlek, a /Inv mappából bemásolnád a te inventorydat mit mutat?

Nem elérhető Sanyko

  • 324
    • Profil megtekintése
Inventory
« Válasz #8 Dátum: 2016. Június 16. - 09:04:36 »
0 Show voters
Idézetet írta: 1Mark6 date=1466060530\" data-ipsquote-contentapp=\"forums\" data-ipsquote-contenttype=\"forums\" data-ipsquote-contentid=\"60879\" data-ipsquote-contentclass=\"forums_Topic
A slotoknak \"Üres\"-nek kell lennie, ahhoz, hogy a rendszer bármit is hozzátudjon adni, szerintem ez nálad nem / nem így szerepel, ha megkérhetlek, a /Inv mappából bemásolnád a te inventorydat mit mutat?
 

Item0=
Itemamount0=0
Item1=
Itemamount1=0
Item2=
Itemamount2=0
Item3=
Itemamount3=0
Item4=
Itemamount4=0
Item5=
Itemamount5=0
Item6=
Itemamount6=0
Item7=
Itemamount7=0
Item8=
Itemamount8=0
Item9=
Itemamount9=0
Item10=
Itemamount10=0
Item11=
Itemamount11=0
Item12=
Itemamount12=0
Item13=
Itemamount13=0
Item14=
Itemamount14=0
Item15=
Itemamount15=0
Item16=
Itemamount16=0
Item17=
Itemamount17=0
Item18=
Itemamount18=0
Item19=
Itemamount19=0

Nem elérhető 1Mark6

  • 437
    • Profil megtekintése
Inventory
« Válasz #9 Dátum: 2016. Június 16. - 09:10:43 »
+1 Show voters
A sejtésem pontos :D
Ahogyan te is látod az Item0 =, Item1 =, Ott nincs megadva az érték, ezeknek a mezőknek Item0=Üres, Item1=Üres, -nek kéne lenni.
Javaslat :
- Vagy beleirogatod egyesével, hogy \"Üres\".
- Kitörlöd a fájl, és újragenerálod ( Amikor csatlakozol LoadItems automatikusan lefut elvileg )
- Ha az előző nem müködik, akkor irj ide :D

Nem elérhető Sanyko

  • 324
    • Profil megtekintése
Inventory
« Válasz #10 Dátum: 2016. Június 16. - 09:31:40 »
0 Show voters
Idézetet írta: 1Mark6 date=1466061043\" data-ipsquote-contentapp=\"forums\" data-ipsquote-contenttype=\"forums\" data-ipsquote-contentid=\"60879\" data-ipsquote-contentclass=\"forums_Topic
A sejtésem pontos :D
Ahogyan te is látod az Item0 =, Item1 =, Ott nincs megadva az érték, ezeknek a mezőknek Item0=Üres, Item1=Üres, -nek kéne lenni.
Javaslat :
- Vagy beleirogatod egyesével, hogy \"Üres\".
- Kitörlöd a fájl, és újragenerálod ( Amikor csatlakozol LoadItems automatikusan lefut elvileg )
- Ha az előző nem müködik, akkor irj ide :D
 
Kitöröltem és újra rakta és most így néz ki:
 
Item0=Üres
Itemamount0=0
Item1=Üres
Itemamount1=0
Item2=Üres
Itemamount2=0
Item3=Üres
Itemamount3=0
Item4=Üres
Itemamount4=0
Item5=Üres
Itemamount5=0
Item6=Üres
Itemamount6=0
Item7=Üres
Itemamount7=0
Item8=Üres
Itemamount8=0
Item9=Üres
Itemamount9=0
Item10=Üres
Itemamount10=0
Item11=Üres
Itemamount11=0
Item12=Üres
Itemamount12=0
Item13=Üres
Itemamount13=0
Item14=Üres
Itemamount14=0
Item15=Üres
Itemamount15=0

Nem elérhető 1Mark6

  • 437
    • Profil megtekintése
Inventory
« Válasz #11 Dátum: 2016. Június 16. - 09:33:51 »
0 Show voters
Most próbáld meg, elvileg hibátlanul fog müködni, és nem fogja küldeni azt az üzenetet.

Nem elérhető Sanyko

  • 324
    • Profil megtekintése
Inventory
« Válasz #12 Dátum: 2016. Június 16. - 09:38:49 »
0 Show voters
Idézetet írta: 1Mark6 date=1466062431\" data-ipsquote-contentapp=\"forums\" data-ipsquote-contenttype=\"forums\" data-ipsquote-contentid=\"60879\" data-ipsquote-contentclass=\"forums_Topic
Most próbáld meg, elvileg hibátlanul fog müködni, és nem fogja küldeni azt az üzenetet.
 
Igen most nem küldi az üzenetet. De ha veszek lapotopot akkor ugyan úgy üres lesz pl az 1-es

Nem elérhető 1Mark6

  • 437
    • Profil megtekintése
Inventory
« Válasz #13 Dátum: 2016. Június 16. - 09:39:33 »
+1 Show voters
AddItem(playerid,\"Laptop\",1); Amikor megveszi.

Nem elérhető Sanyko

  • 324
    • Profil megtekintése
Inventory
« Válasz #14 Dátum: 2016. Június 16. - 09:59:38 »
0 Show voters
Idézetet írta: 1Mark6 date=1466062773\" data-ipsquote-contentapp=\"forums\" data-ipsquote-contenttype=\"forums\" data-ipsquote-contentid=\"60879\" data-ipsquote-contentclass=\"forums_Topic
AddItem(playerid,\"Laptop\",1); Amikor megveszi.
 
Ohh basszus KÖSZI!!! ment a + Ezer hálám!

Dupla hozzászólás automatikusan összefûzve. ( 2016. Június 16. - 10:15:19 )


 

AddItem(playerid,\"Laptop\",1); Amikor megveszi.
 
[/quote]
Nem sikerült sajnos :( Ugyan úgy nem adja oda
[/quote]
« Utoljára szerkesztve: 2016. Június 16. - 10:15:19 írta Sanyko »

 

SimplePortal 2.3.7 © 2008-2024, SimplePortal