WraitheDX / realms_shattered

This is a CLI (command line interface) text RPG programmed in C++.
11 stars 6 forks source link

Adding gameplay - Exploring: Rooms #35

Closed WraitheDX closed 4 years ago

WraitheDX commented 4 years ago

Note: Gameplay will go through iterations, and start off very simple.

From GameState::game_state_player_hub(), player should be able to type 'rift' and explore a rift of randomly generated rooms. This should throw the player into a new GameState function: game_state_rift().

A new() instance of a rift struct should be created in GameData upon entering the rift. The struct should have a difficulty that is randomly chosen, probably just 1-3. Difficulty should only affect the number of rooms that the rift contains. The rift should store the number of rooms, which should be randomized. A formula along the lines of: number_of_rooms = random int (3, 6) +/x difficulty should be fine, just not too many as currently rooms will be empty.

After creation and initialization of the rift struct, the first room should be generated. Room struct should have a name (Room ). Print name to player. Player should be able to type 'move' and move on to the next room. When moving from the final room, player should return to game_state_player_hub().

Eventually a room will have any number of possibilities: events, random npcs, harvestables (skinning/harvesting fallen enemies, mining, harvesting plants, fishing, etc), combat, puzzles, examining for hidden elements, etc. For now we just want base functionality to expand on.

WraitheDX commented 4 years ago

Tackling this issue now. This issue has been implemented.