Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > C++ > Game Control Storage

Reply
Thread Tools

Game Control Storage

 
 
Daniel Moree
Guest
Posts: n/a
 
      11-08-2004
What would be the best way to store the controls of a game? Should it be
done in a INI or other type of file or should it be done in the registry.

Explain both please. What's the best way to pull from the file and set my
variables, and what's the best way to add and pull from the registry?

Thanks for your help in advance.


 
Reply With Quote
 
 
 
 
Thomas Matthews
Guest
Posts: n/a
 
      11-08-2004
Daniel Moree wrote:

> What would be the best way to store the controls of a game? Should it be
> done in a INI or other type of file or should it be done in the registry.

Very off-topic. The C++ language doesn't care much about the outside
world, such as registries or files.


> Explain both please. What's the best way to pull from the file and set my
> variables, and what's the best way to add and pull from the registry?

Since this is platform specific, your best answers will come from
posting to a platform specific newsgroup or the generic
news:comp.programming. Your issue is platform specific because
I know of many workstations and embedded platforms that don't have
registries.

>
> Thanks for your help in advance.


The ultimate answer to your question:
Game "controls" or other information should be stored in
non-volatile memory (NVM). NVM is memory that can survive
loss of power. The location should be somewhere that your
program can access and users can't. You don't want users
changing the settings of your game, or do you?

Text files have the advantage of being more platform
independent than a binary file. However, a binary
file is quicker to access because it doesn't require
a translation (but it may need converting when porting
to different platforms).

I can't say what is best because that is a religious
issue.

--
Thomas Matthews

C++ newsgroup welcome message:
http://www.slack.net/~shiva/welcome.txt
C++ Faq: http://www.parashift.com/c++-faq-lite
C Faq: http://www.eskimo.com/~scs/c-faq/top.html
alt.comp.lang.learn.c-c++ faq:
http://www.comeaucomputing.com/learn/faq/
Other sites:
http://www.josuttis.com -- C++ STL Library book

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
DVD and Game Storage Caibinets TvilleWood DVD Video 0 07-23-2008 02:55 PM
Why is enterprise storage so much more expensive than personal storage? John Computer Support 4 03-17-2008 09:50 PM
How to access the external storage unit of storage router =?Utf-8?B?SWduYXRpdXM=?= Wireless Networking 4 11-06-2006 06:40 AM
Difference b/w storage class and storage class specifier sarathy C Programming 2 07-17-2006 05:06 PM
Java Game- Game can't find it's graphics jar file BlackHawke Java 12 01-26-2004 06:14 AM



Advertisments