Password

hello everyone… im doing a game, so because the game isnt easy and its long, i decided to set passwords… so i did, i did everything like i had to do it… then i put this code in the button, ans when you press the button without writing anything, it goes to the second level… why??? heres the code:

on(release, keyPress “<Enter>”){
if(pass = “asupu”){
gotoAndStop(“2”)
} else if(pass == “tefgh”){
gotoAndStop(“3”)
} else if(pass == “gkavc”){
gotoAndStop(“4”)
} else if(pass == “kowrt”){
gotoAndStop(“5”)
} else if(pass == “jkltr”){
gotoAndStop(“6”)
} else if(pass == “oprtd”){
gotoAndStop(“7”)
} else if(pass == “oftaw”){
gotoAndStop(“8”)
} else if(pass == “oyarf”){
gotoAndStop(“9”)
} else if(pass == “zdyig”){
gotoAndStop(“10”)
} else if(pass == “xgdty”){
gotoAndStop(“11”)
} else if(pass == “gjsog”){
gotoAndStop(“12”)
} else if(pass == “sjpwf”){
gotoAndStop(“13”)
} else if(pass == “qkrpv”){
gotoAndStop(“14”)
} else if(pass == “snfpa”){
gotoAndStop(“15”)
} else {
gotoAndPlay (“wrong_pass”)
}
}

what am i doing wrong??? please help, the game its almost done and i wanna publish it!! thanks…
ohh btw, if you are going to answer me please i prefer emails… instead of coming everyday checking if i got an answer… mrojas2000@gmail.com or mrojas2000@hotmail.com
thank you for reading this!!!
Miguel Rojas

we wanna see to!
:eye:

In the first if statement - you need a “==” versus a single “=”

on(release, keyPress “<Enter>”){
if(pass [COLOR=“DarkOrange”]==[/COLOR] “asupu”){

huh??

oh crap… why does it needs the 2 ==s anyways
thanks dude… that worked!!!

using one “=” is setting your variable to equal that string - the strict equality “==” operator is comparing if your variable matches something. glad it worked out!

thanks for everything – help, fast answer, and information