RonenNess / GeonBit.UI

UI system for MonoGame projects.
MIT License
466 stars 63 forks source link

Suggestion, have a list of AttachedData #87

Closed AleCie closed 6 years ago

AleCie commented 6 years ago

Right now you can go ahead and create custom structs/classes if you want to store multiple things in AttachedData that otherwise don't belong together , but it could be beneficial for it to be a list to which user can add as many things as he wants, and leave it to him to later figure out what and how many elements are there.

Even simple change from 'public object AttachedData' to 'public List<object> AttachedData' would give much more flexibility.

RonenNess commented 6 years ago

Hi @AleCie, thank you for the suggestion. However I think it's ok the way it is. If you want a list of attached data you can always attach a list yourself, like this:

entity.AttachedData = new List<object>();

Because it's so simple I see no value in forcing it to be a list, it will only make it slightly less comfortable for people who don't need a list.

Thanks :)