You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Use a custom resolver for sprites you can extend from your game project, currently IDs are generated into the engine assembly, a better solution is to store in a list you can extend from your code, and store the indexes, there are drawbacks though:
not stable, removing an item from list breaks serialization (what doesn't happen with enum if you serialize the key as string)
no intellisense
no free efficient serialization
no free compile-time safety check
other stuff i don't remember :P
The text was updated successfully, but these errors were encountered:
I think there's no way to do this other than an engine-provided dict using string keys that the user adds entries for their sprites, for autocompletion we could generate an enum of strings, we lose safety checks though, and also efficiency since it's not going to be trivial to convert the collection to list and access items by index as opposed to accessing dict by key for the release version.
Use a custom resolver for sprites you can extend from your game project, currently IDs are generated into the engine assembly, a better solution is to store in a list you can extend from your code, and store the indexes, there are drawbacks though:
The text was updated successfully, but these errors were encountered: