I'm writing a text based adventure for my final programming project for a class, and I seem to have hit a bit of a snag. I'm not a very savvy programmer, but I do know alot of the basics. We have alot of freedom with the program, and get graded based on how unique, creative, and the features the program has. I wanted to add in an edit mode to the program, so that if the user types in a certain "code" in the beginning, he/she can edit the text file that contains the game information.
My program reads from a text file, rooms.txt. The file contains the total number of rooms, the room index, name, description, the exit locations, treasure name, treasure description, treasure value, monster name, monster description, monster health, and the information on the sign in the room.
I have an idea of how to do the implementation, but i'm not quite sure about it. I wanted to use fstream and have the program prompt the user for which room they want to edit. I'm not sure how to have the program replace the given lines in the text file, or anything. I'll attach my text file at the end, I hope someone can help me figure out how to implement this.