Jump to content
  • Advertisement
Sign in to follow this  
derek7

why use register table,I know many big software don't adopt it.

This topic is 5006 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Advertisement
Several reasons:
  • It allows you to have a nice uninstaller in the control pannel
  • You can store data in a way that doesn't require you having a settings file
  • It helps prevent people "just copying the directory" to pirate the game (I'm not implying you pirated it)

    Share this post


    Link to post
    Share on other sites
    Quote:
    Original post by Ravuya
    I am not entirely sure what you're asking.
    I'm assuming he's asking "What's the point in using the registry?"

    Share this post


    Link to post
    Share on other sites
    I don't mind programs using the registry, but I REALLY hate it when they don't remove their settings on uninstal. MS should make windows track registry changes, and undo all of them a program has caused when you uninstall that program (or have an option of doing so at least).

    As far as I can tell, the only real bonus to the registry is that you can take the liberty of just picking a place to put it and you always know where it is (ie from updater programs that are not run from the game's directory), so you don't have to ask users stuff like 'where is the settings file?' or 'where is the game installed?'

    As a repository for OS settings, the registry makes sense, but it doesn't really work as a general ini replacement and I hate that everybody is treating it as such.

    Share this post


    Link to post
    Share on other sites
    Quote:
    Original post by Extrarius
    I don't mind programs using the registry, but I REALLY hate it when they don't remove their settings on uninstal. MS should make windows track registry changes, and undo all of them a program has caused when you uninstall that program (or have an option of doing so at least).


    Yes yes YES! Personally, I don't think the registry was a bad idea, but I can't say the same about the implementation. I know some shareware companies wouldn't like it, but they can figure out a new copy protection trick. It would really help to remove the crap that tends to build up in the registry.

    It would be pretty simple to implement too, you could do it similarly to a source control system, just storing deltas.

    Share this post


    Link to post
    Share on other sites
    The original point of the registry, as far as I know, was mostly for administrators. It provides a central place that can be backed up and secured. It's format is more consistent then the randomness seen in config files. It also has a clear way to provide per-user configs which historically Windows didn't have.

    It gets abused and misused like everything else.

    Share this post


    Link to post
    Share on other sites
    Quote:
    Original post by Extrarius
    As a repository for OS settings, the registry makes sense, but it doesn't really work as a general ini replacement and I hate that everybody is treating it as such.


    Unfortunately MS seems to be pushing things that way.

    Quote from MSDN WritePrivateProfileString:
    Quote:
    The WritePrivateProfileString function copies a string into the specified section of an initialization file.

    Note This function is provided only for compatibility with 16-bit versions of Windows. Applications should store initialization information in the registry.


    Further, even if you do use an ini file, it might get moved by Windows into the registry:

    Quote:
    The system maps most .ini file references to the registry, using the mapping defined under the following registry key:

    HKEY_LOCAL_MACHINE
    SOFTWARE
    Microsoft
    Windows NT
    CurrentVersion
    IniFileMapping



    To avoid all of that, you have to stop using the MS-supplied functions and write your own. No big deal, but they hooked developers on the ini functions and then messed them up.

    Share this post


    Link to post
    Share on other sites
    The programs still don't store your data in the registry though, so you still have to hunt down that when you format or something, so just having the settings there would be alot easier -- I've never seen a util for exporting all the registry entries pertaining to a given file.

    The C:\Documents and Settings folder would seem like a logical place for settings to me...

    Share this post


    Link to post
    Share on other sites
    Sign in to follow this  

    • Advertisement
    ×

    Important Information

    By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

    GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

    Sign me up!