You should go with the ShareObject I think. The shared object stores the
data in a Flash specific location (C:\Documents and
Settings\[USER]\Application Data\Macromedia\Flash Player)
All you do is creating a local SharedObject and then store data in it -
this data can be read again later on in a new session. It works like a
cookie.
Try look in the Flash help on SharedObject :)
Or try this code:
var so:SharedObject = SharedObject.getLocal("userHighScore");
if (so.data.highScore == undefined)
{
trace("no high-score found");
}
else
{
trace("high-score = "+so.data.highScore);
}
// set a new highscore:
so.data.highScore = Math.ceil(Math.random() * 1000);
so.flush();
trace("new high-score = "+so.data.highScore);
- Magnus
[quoted text, click to view] Golbez_AU wrote:
> Right now i intend for it to be installed locally.
>
> With the SharedObject class, where does that save the information? Is it in a
> separate file or what?
>
> How hard would it be to implement a system where you could select which user
> to continue with/create a new user?
>
> Once it's implemented, is it as simple as loading the score associated with
> that username as a variable?
>
> Sorry for the uneducated questions, it's just that i want to know which
> direction i should be heading in so that i can begin planning/experimenting for
> my project.