this (infos.BaseInformation.Level - infos.CalculateUplevel())
what does it have to return exactly and why is it 2 values not only one ?
in your calculation void all you need to do is to check for the next levelreq for that item that is being upgraded and return a bool or a value . so
IE.
Quote:
public static bool CanUpgrade(uint ItemID, uint ClientLevel)
{
uint Nextlevel = look up your baseItems dictionary for the next level using the ItemID(you need to figure out how to code this one);
do all your checks .
if (the new level was found and its not the highest level for the item)
return true;
else return false;
}
|
the npc should check for something like .
Quote:
if (!CanUpgrade(ItemID, client.Entity.Level))
{
do the thing /
}
|
and to make it easier you can mix the (find the new level for the item and the can upgrade void together and thats gonna be less time/work)