[COLOR=#000000][FONT=Arial]I am trying to make an “achievements” page for my game, where if the user has a high score greater than 100, then the achievement can be unlocked. I tried using a code like this, but it didn’t seem to work![/FONT][/COLOR]
[COLOR=#00008B]function[/COLOR] [COLOR=#2B91AF]Check[/COLOR]();
[COLOR=#00008B]if[/COLOR](endscreen_mc.highscore_txt > [COLOR=#800000]100[/COLOR])
{
medals.roachLock.visible = [COLOR=#00008B]false[/COLOR];
}
[COLOR=#00008B]else[/COLOR] [COLOR=#00008B]if[/COLOR](endscreen_mc.highscore_txt < [COLOR=#800000]100[/COLOR])
{
medals.roachLock.visible = [COLOR=#00008B]true[/COLOR];
}
[COLOR=#00008B]else[/COLOR] [COLOR=#00008B]if[/COLOR](endscreen_mc.visible == [COLOR=#800000]100[/COLOR])
{
medals.roachLock.visible = [COLOR=#00008B]true[/COLOR];
}
[COLOR=#000000][FONT=Arial]The high score value is saved inside a shared object. What’s wrong with my code, and what can I do to fix it?[/FONT][/COLOR]