HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Quick question : get unit cost

02-13-2007, 02:34 PM#1
zen87
uhhh... how do we detect a unit's building cost ? eg a scout tower cost 30, i want something like

Collapse JASS:
GetUnitCost('hwtw') returns 30

02-13-2007, 03:39 PM#2
CommanderZ
There is GetItemCostById system somewhere on forums. I'm sure it will be easili modificable to get cost of unit instead of item.
02-13-2007, 03:56 PM#3
zen87
well i know there is an getitemcost, but what i want now is getting a unit/building's cost ><

ah i'll see what i can extract from the getitemcost ability O_o
02-13-2007, 04:04 PM#4
The)TideHunter(
Just make a function that gives a player like 50000 gold, order it to buy a unit, check how much gold is missing, take the gold back, remove the unit, hey presto theyres your amount.