Add easily serializable objects #49

Closed
opened 2020-11-19 11:08:33 +01:00 by kazhnuz · 2 comments
Owner

We should think a way to easily get serialized data (like character, inventory content), while making it easily customizable by the player. We could also try to make it more "database-like" ?

We basically have several important thing to think:

  • Serialization of game content ? We use binser, but it use some kind of complexe way of handling…
  • How to get those data. For instance will we have some kind of "query(contentType, attributeName, attributeContent)" ?
  • How to modify those data. For instance change the HP of an hero, etc.
  • How to add/remove those data. This one might be kinda easier ?
  • Simple variable content (like money)
  • How it relate to game data (item data as the save need them to item data as the game need them).

It could also help us to avoid the

We should think a way to easily get serialized data (like character, inventory content), while making it easily customizable by the player. We could also try to make it more "database-like" ? We basically have several important thing to think: - Serialization of game content ? We use binser, but it use some kind of complexe way of handling… - How to get those data. For instance will we have some kind of "query(contentType, attributeName, attributeContent)" ? - How to modify those data. For instance change the HP of an hero, etc. - How to add/remove those data. This one might be kinda easier ? - Simple variable content (like money) - How it relate to game data (item data as the save need them to item data as the game need them). It could also help us to avoid the
Author
Owner

A possibility I see is some kind of "datamanager" system that would just have a table with all its content, that would use some kind of query system.

Possibly needed functions for queries :

get(datatype, attributeName, attributeContent)
getAll(datatype)
getTriaged(number, datatype, attributeName, attributeContent, triagedAttribute, isAsc)
getAllTriaged(number, datatype, triagedAttribute, isAsc)
getOne(datatype, id)

add(data)
addList({data1, data2})

updateAttribute(datatype, id, attributeName, attributeContent)

remove(datatype, id)
A possibility I see is some kind of "datamanager" system that would just have a table with all its content, that would use some kind of query system. Possibly needed functions for queries : ```lua get(datatype, attributeName, attributeContent) getAll(datatype) getTriaged(number, datatype, attributeName, attributeContent, triagedAttribute, isAsc) getAllTriaged(number, datatype, triagedAttribute, isAsc) getOne(datatype, id) add(data) addList({data1, data2}) updateAttribute(datatype, id, attributeName, attributeContent) remove(datatype, id) ```
Author
Owner

One question would be how would be written the structure of the datas.

One question would be how would be written the structure of the datas.
kazhnuz added the
4. Birb Core
1. Feature
2. Epic
labels 2020-11-24 14:45:56 +01:00
kazhnuz added this to the epervier 0.7.0 milestone 2022-08-09 08:31:48 +02:00
Sign in to join this conversation.
No description provided.