Skip to content

Commit 48c3fda

Browse files
committed
It works!
1 parent 716eaff commit 48c3fda

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

Basic Text Adventure Game/Adventure.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,9 +46,10 @@ def save_userdata(data_type, data):
4646
print("Error, you must create a user")
4747
else:
4848
userfile = open(current_user, "w")
49+
userfile.write("name:")
4950
userfile.close()
5051
current_user_data = enter_room(current_user)
51-
current_user_data.update([data_type][data])
52+
current_user_data.update({data_type: data})
5253
save_data(current_user, current_user_data)
5354

5455

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
name: Joe

0 commit comments

Comments
 (0)