View Single Post
06-16-20, 11:14 PM   #1
nirran
A Murloc Raider
Join Date: Mar 2005
Posts: 8
money format gold etc coins

i want to format the money string to break up large numbers and have the coin icons in the string,this is what i have,it works but need the method to add the icons

Code:
function GetGoldTextureString(value)

    local copper, silver, gold, calc

	copper = (("%d"):format(value % 100))

	silver = (("%d"):format((value / 100) % 100))
	
	gold = (("%d"):format(value / 100 / 100))

	calc = FormatLargeNumber(gold)
	
	return (calc.."g "..silver.."s "..copper.."c")

end
  Reply With Quote