Anyone know why this Scale() isn't working? in Developer Help
|
|
obj/planeticon
proc/Beautify() var/icon/modifiedIcon = icon(icon,icon_state)
switch (myPlanetSize)
if (1) modifiedIcon = modifiedIcon.Scale(96,96) if (2) if (3) modifiedIcon = modifiedIcon.Scale(224,224) if (4) modifiedIcon = modifiedIcon.Scale(288,288) if (5) modifiedIcon = modifiedIcon.Scale(352,352) else DebugMsg("myPlanetSize out of expected range.") modifiedIcon = icon(icon,icon_state)
icon = modifiedIcon
|
Size 2 (no change to scale) works fine.
In the rest of the cases (assuming not "else") the icon simply vanishes.
This is on a proc in a standard obj.
|
modifiedIcon = modifiedIcon.Scale(96,96) // 3 distance acrossTry doing:
Do the same for all the other cases.