ID:150076
 
Is there a way to find all of the icon_states contained within an icon?

flick()
Explain, in a bit more detail and a 'may' be able to assist.
Flick wrote:
Is there a way to find all of the icon_states contained within an icon?

Sadly, not yet. However, Dantom are planning to revamp the icon structure a bit in the nearish future to provide better access to the icon, its states, etc.

Lummox JR
In response to Super saiyan3
Well, for example, when adding a 'forest' turf to a map from within the game, I would like to be able to choose which icon state to use, without having to hard code a list of possible icon states for each atom.

Something along the lines of:

turf
verb
change_state()
set src in view()
var/list/states
for(var/icon_state/I in src.icon) // <<--- This obviously doesn't work
states += I
src.icon_state = input("which state") in states


flick()

In response to Lummox JR
Lummox JR wrote:
Dantom are planning to revamp the icon structure a bit in the nearish future.

Delicious.. I hope it happens soon. It'll simplify my random areas a lot more. :D

-- Tarmas.
In response to Tarmas
In the map editor when you click one of your turfs there's this button generate icon states...??? ANyone notice that or it doesn't work...

BTW I hardly go check the forum anymore and never go on BYOND so I know everyone will miss the great one =)