This Feature Request made we realize that ASH has some unnecessary functions in its runtime library.
We have the following functions to translate between certain ASH types and KoL's internal ID for objects of that type.
to_int(item) : yes
to_int(familiar) : yes
to_int(skill) : yes
to_int(effect) : yes
Each of the above also has the reverse translation:
to_item(int) : yes
to_familiar(int) : yes
to_skill(int) : yes
to_effect(int) : yes
These are useful functions, since scripts can use the object ID numbers to construct URLs to manipulate the appropriate objects.
Certain ASH types do not have a to_int translation, since there is no KoL ID number corresponding to them:
to_int(location) : no
to_int(monster) : no
to_int(coinmaster) : no
However, there are 4 ASH data types that have a to_int (and recently, a corresponding reverse translation function), even though such a number is arbitrarily assigned by ASH and is useless for actually interacting with KoL:
to_int(element) : yes
to_element(int) : yes
to_int(stat) : yes
to_stat(int) : yes
to_int(class) : yes
to_class(int) : yes
to_int(phylum) : yes
to_phylum(int) : yes
I would like to simplify ASH by removing those eight functions. They do not help scripts interact with KoL, since KoL uses no such numbers. They do not provide anything that a script cannot do itself without help from ASH.
We have the following functions to translate between certain ASH types and KoL's internal ID for objects of that type.
to_int(item) : yes
to_int(familiar) : yes
to_int(skill) : yes
to_int(effect) : yes
Each of the above also has the reverse translation:
to_item(int) : yes
to_familiar(int) : yes
to_skill(int) : yes
to_effect(int) : yes
These are useful functions, since scripts can use the object ID numbers to construct URLs to manipulate the appropriate objects.
Certain ASH types do not have a to_int translation, since there is no KoL ID number corresponding to them:
to_int(location) : no
to_int(monster) : no
to_int(coinmaster) : no
However, there are 4 ASH data types that have a to_int (and recently, a corresponding reverse translation function), even though such a number is arbitrarily assigned by ASH and is useless for actually interacting with KoL:
to_int(element) : yes
to_element(int) : yes
to_int(stat) : yes
to_stat(int) : yes
to_int(class) : yes
to_class(int) : yes
to_int(phylum) : yes
to_phylum(int) : yes
I would like to simplify ASH by removing those eight functions. They do not help scripts interact with KoL, since KoL uses no such numbers. They do not provide anything that a script cannot do itself without help from ASH.