uml - How would you design a database for storing mazes and games played on the same mazes? -
i have assignment design database storing mazes , games played on these mazes.
a maze grid, containing prizes , traps. assignment isn't more specific: asks find kind of general rules express events occur in game , rules these events.
i've put down simple conceptual schema of it:
do think that, based on description of assignment, solution? how can improve it?
so maze grid, each node containing data. each node contains several things: 1) list of links other nodes 2) list of items available @ node
everything else can expressed those.
that suggests table maze, containing basic data maze id, name, description, etc. there's table node, containing data node. id, name, coordinates, , maze_id 3rd item, id, item_name, node_id, item_type, , maybe other things.
to speed lookup operations, might want link table maze_node containing maze_id , node_id foreign keys both tables, , node_item table node_id , item_id fields.
other columns , tables may needed hold information not specific data hierarchy (like information stats of items, environment conditions @ nodes, etc.).
and that's basic data structure maze. lore story, you'd @ least need tables texts, chapters, conditions under each chapter launched, etc. etc. pretty independent of maze, though conditions might include player being in specific location in maze, or telling him go specific location.
Comments
Post a Comment