NewestCoServer npc repair

06/29/2013 21:19 Ciarda#1
Hey does anyone know the formula to calculate how much it costs to repair an item? I found out how to repair items just dont know how to put price for it :D it was in packet system
06/30/2013 16:19 pro4never#2
Code:
 uint cost = torepair.ItemtypeData.Value.Price;
                                                uint duraCost = (torepair.CurrentDura * cost) / torepair.MaximumDura;
                                                cost -= duraCost;

That's what we used in Albetros. Very sure it's correct calculation.
07/01/2013 15:03 Ciarda#3
Thanks but my brother allready got it to work I guess that will work too so +thanks!