Hello guys,
I would like to develop a system, where user will get the data dynamically(what I mean dynamic is, without reloading pages, using AJAX.. but well, it does not matter much).
My situation is like this. I have this table, I called it "player", in this player table, I will store the player information like, player name, level, experience etc.
Each player can have different clothes, start from tops(shirts), bottoms, shoes, and hairstyle, and each player can have more than 1 tops, bottoms, shoes etc.
What I am hesitated or not very sure about is, how do you normally store the data? My current design is like this:
Player Table
===========================================================================================
id | name | (others player's info) | wearing | tops | bottoms
===========================================================================================
1 | player1 | | top=1;bottom=2;shoes=5;hair=8 | 1,2,3| 7,2,3
Tops Table
=====================
id | name | etc...
=====================
1 | t-shirt | ...
I am not sure if this design is good. If you are the database designer, how would you design the database? Or how you will store them?
Please advise.
Thanks