Solo usuarios registrados pueden comentar y agradecer, Logueate o Registrate

Autor Topic: Item value main side (main 5.2)  (Visto 455 veces)

0 Miembros and 1 Guest are viewing this topic.

Offline Macêdo Posteado: January 01, 2026, 08:49:50 PM | Modificado: January 01, 2026, 09:05:57 PM by Macêdo

  • 0 puntos por ventas
  • *
  • Rank: Dedicado
  • Posts: 53
  • Gracias recibida: 818
  • br
Antes:
https://ibb.co/Kj9Hpp0R
https://ibb.co/99PYSv3S

Depois:
https://ibb.co/np7zfdV
https://ibb.co/Cpk5MzDZ




em ZzzInventory.cpp buscar
void RenderItemInfo(int sx,int sy,ITEM *ip,bool Sell, int Inventype, bool bItemTextListBoxUse)

botar esse if modificado
Code: [Select]
if (Sell)
{

// PLAYER COMPRANDO DO NPC (BUY)
DWORD dwBuyValue = GetNpcShopZenValue(ip, false);

ConvertGold(dwBuyValue, Text);

char Text2[100];
ConvertTaxGold(dwBuyValue, Text2);

sprintf(TextList[TextNum], GlobalText[1620], Text2, Text);
}
else
{
// PLAYER VENDENDO PARA O NPC (SELL)
DWORD dwSellValue = GetNpcShopZenValue(ip, true);

ConvertGold(dwSellValue, Text);

sprintf(TextList[TextNum], GlobalText[63], Text);
}

em ZzzInformaation.cpp add
Code: [Select]
DWORD GetNpcShopZenValue(ITEM* ip, bool bSell)
{
if (!ip)
return 0;

int index = ip->Type;
int level = (ip->Level >> 3) & 15;

DWORD value = gItemValue.GetValue(index, level, bSell);
if (value != 0)
return value;

return bSell ? ::ItemValue(ip, 1) : ::ItemValue(ip, 0);
}

call: gItemValue.Load("ItemValue.txt");

ItemValue.txt
Code: [Select]
//Index Level Grade Buy    Sell    // comentário opcional
2051    *     *     10     5        // Bolt
end

by Macêdo


Solo usuarios registrados pueden comentar y agradecer, Logueate o Registrate


 

Related Topics

  Subject / Started by Replies Last post
12 Replies
5170 Views
Last post September 25, 2020, 03:45:22 PM
by GabrielDevel
4 Replies
7293 Views
Last post September 28, 2019, 04:58:06 PM
by Ryuno
2 Replies
1556 Views
Last post May 24, 2019, 12:46:45 PM
by punkjaja
1 Replies
2233 Views
Last post November 23, 2023, 01:17:01 AM
by ntcong295810
11 Replies
4722 Views
Last post January 10, 2026, 06:16:41 AM
by Creazsia