BoolPrefs

Author: Eric Haines (Eric5h5)

Description
So you're missing SetBool and GetBool from PlayerPrefs? Worry not, here they are!

Usage
Have this script somewhere in your project. Ideally it should be in Standard Assets/Scripts so it can easily be used by C# and Boo scripts. Call it PlayerPrefsX, and then you can use PlayerPrefsX.GetBool and PlayerPrefsX.SetBool as you would expect. Normally GetBool returns false if the key doesn't exist, but you can override that by optionally specifying a default value. i.e., "var foo = PlayerPrefsX.GetBool("blah", true);" will cause foo to be true if the key "blah" doesn't exist. These functions use PlayerPrefs.SetInt and GetInt behind the scenes (0 = false, 1 = true), so they're basically convenience functions.