I'm trying to create a password input area where a player can insert several passwords and be correct, each password triggering the typing of that password in a separate area (which is what the numbers one to ten in the script below refer to). However, there is some flaw I can't find in the script and if I try to enter anything in the box, it is changed to "orangemarmalade" (see below) and only enters there (acting as if I typed "orangemarmalade" every time). Any one have any help?



on (release)
{
if (enterpassword = "orangemarmalade")
{
one = "orangemarmalade";
}

else if (enterpassword = "goldenafternoon")
{
two = "goldenafternoon";
}

else if (enterpassword = "andtheking")
{
three = "andtheking";
}

else if (enterpassword = "breadandbutterflies")
{
four = "breadandbutterflies"
}

else if (enterpassword = "rockinghorsefly")
{
five = "rockinghorsefly"
}

else if (enterpassword = "lobsterquadrille")
{
six = "lobsterquadrille"
}

else if (enterpassword = "momeraths")
{
seven = "momeraths"
}

else if (enterpassword = "maryjanes")
{
eight = "maryjanes"
}

else if (enterpassword = "mockturtle")
{
nine = "mockturtle"
}
else if (enterpassword = "marchhare")
{
ten = "marchhare"
}

else
{
enterpassword = "Try Again"
}
}