It's my first time posting so go easy on me.
I'm trying to create a game/application in Java based on the following rules:
-Player starts with 4 Elements: Water, Air, Fire, Earth.
-Available elements are in a scroll box on the right side of the screen in the "tile bank"
-The player can place and freely move tiles of each element on a free-moving game board and have as many instances of each element as they wish.
-Elements are combined by dragging one tile (e.g. Water) and another tile (e.g. another Water) to create a new tile of the correct element (For this example, I would have the resulting reaction create "Sea" [Water+Water=Sea]
-The player can then use the created elements to make more combinations (e.g. Sea + Sea = Ocean)
-Some elements are final and can't be used to make a new element. These can be excluded from available tiles in the tile bank.
-Object of the game is to discover all possible elements.
I want to incorporate hints into the game upon successful reactions, but for now I've run into the conundrum of how to actually combine the elements.
The suggestions I've had so far are as follows:
-HashMaps (possibly with elements as binary values; Water= 0001 Fire = 0010, etc.
-Using the elements as interfaces
-Creating a table of values with unique ID's
-Classes within classes, creating a hierarchy.
I'm also thinking it may be easiest to simply hard-code all of the reactions into the element objects themselves individually.
Does anyone have experience with a game like this or can give suggestions based on the object of the game?
Thank you in advance.