Tags
There are many properties on Mobile and Item that are used only in a minority of instances and on most cases have a zero or null value. Wouldn't it be better to use a tag system where you can dynamically add/remove properties when needed? it would make it much easier (and reduce the amount of default script editing for custom stuff) to add properties that are only used in a few cases. It would also save memory from the properties that are not used. It could be implemented as a hashtable (pointed by a property named Tags or something) that would store extra properties needed. When you need a new one you just add it to the hashtable (this should be rare so propably would not slow the server down much) and from what I understand reading a key in a hashtable is O(1) so no problem to access the properties. Is there any detail I'm missing that would create problems? If not, it would be nice to have this in a default release.
|