Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 how do u save and load?
Index -> Programming, Turing -> Turing Help
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
kicknock




PostPosted: Fri Feb 23, 2007 3:43 pm   Post subject: how do u save and load?

im making a rpg game and im not sure how to save the character's stats.
for example, suppose the game file name is "rpg.t" and my character's strength is 10.
how do i save that strength stat of 10 into another file let's say "gamedata.t"?
Sponsor
Sponsor
Sponsor
sponsor
StealthArcher




PostPosted: Fri Feb 23, 2007 3:45 pm   Post subject: RE:how do u save and load?

Save all numerical numbers as them selves, each separated by a "|".

Names save each on a new line.
Clayton




PostPosted: Fri Feb 23, 2007 4:31 pm   Post subject: Re: how do u save and load?

not to discourage you or anything, but if you don't even know File I/O, then I suggest you strongly rethink trying to create an RPG. Start with something smaller, and work your way up.
wtd




PostPosted: Fri Feb 23, 2007 4:35 pm   Post subject: Re: how do u save and load?

Freakman @ Sat Feb 24, 2007 5:31 am wrote:
not to discourage you or anything, but if you don't even know File I/O, then I suggest you strongly rethink trying to create an RPG. Start with something smaller, and work your way up.


++
Cervantes




PostPosted: Fri Feb 23, 2007 5:11 pm   Post subject: RE:how do u save and load?

Freakman and wtd are right: you should know how to do File Input/Output before attempting to make an RPG. (There's actually a lot more that you should know before trying to make an RPG, but that's not the point right now.)

However, it's never too soon to learn. Here's a link to the File I/O tutorial.
Martin




PostPosted: Fri Feb 23, 2007 5:22 pm   Post subject: RE:how do u save and load?

I disagree. Keep at it, having a big project is the best way to learn how stuff works. When you have no idea what to expect, you'll learn things you wouldn't have otherwise.

As people said before, what you're looking for is file IO.
kicknock




PostPosted: Fri Feb 23, 2007 6:44 pm   Post subject: Re: how do u save and load?

oh... i just read the file i/o tutorial. i new all the stuff in the tutorial. i just thought saving turing files were different because i only used file i/o for text files.
BigBear




PostPosted: Sat Mar 29, 2008 4:13 pm   Post subject: Re: how do u save and load?

Saving Graphical RPG's
If you understand saving and load stats by saving the variable of the stat in a text file or in a file with a wierd file extension (.sav) Then loading the stats by assigning those variables in your program to the numbers in the file.

But still wondering how do u save and load where the character is in the world? If the user is only able to save at save spots (church, magic blue circle) then have something like if they saved at checkpoint one then their position is = to the x and y of checkpoint one on the map checkpoint one is. Or you can record what map they are on and where they are on the map like if the user can save and load from the start menu anytime then when you save the starts also store what map they are on and where their coordinates which you will know because you draw them there when they move.
Sponsor
Sponsor
Sponsor
sponsor
Display posts from previous:   
   Index -> Programming, Turing -> Turing Help
View previous topic Tell A FriendPrintable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 1 of 1  [ 8 Posts ]
Jump to:   


Style:  
Search: