JeZxLee Posted January 23, 2015 Share Posted January 23, 2015 "LettersFall 5" - Beta1 - 100% Cross-Platform! Hi,We have finally finished Beta1 of our 100% cross-platform HTML5 word game "LettersFall 5"...Please help us test Beta1 before official release by playing game at following URL:http://LettersFall.comIf you have any suggestions or find any problems then reply to this forum post.(when posting please include your Operating System and Internet browser you are using)Thank you for your help!JeZxLee Quote Link to comment Share on other sites More sharing options...
JeZxLee Posted January 25, 2015 Author Share Posted January 25, 2015 Hi,Game is officially done and we released the source code!Just visit: http://lettersfall.comand click on the floppy disk on title screen to download the source code.Thank you to all that helped!JeZxLee Quote Link to comment Share on other sites More sharing options...
mbyo_games Posted January 27, 2015 Share Posted January 27, 2015 I'm using Firefox on Windows 8.1. I like your title screen. It reminds me of old-time computer gaming (DOS-era maybe?). I recommend removing the pause that happens whenever you submit a word. It would make the game play a lot faster. Quote Link to comment Share on other sites More sharing options...
JeZxLee Posted January 27, 2015 Author Share Posted January 27, 2015 I'm using Firefox on Windows 8.1. I like your title screen. It reminds me of old-time computer gaming (DOS-era maybe?). I recommend removing the pause that happens whenever you submit a word. It would make the game play a lot faster.Hi, Thank you for playing our HTML5 video game!It would be impossible to remove the check word delaybecause the dictionary is 400,000+ words and needs time to scan through it.(it is somewhat optimized with separate files for each of the 26 English language letters) Thanks! JeZxLee Quote Link to comment Share on other sites More sharing options...
chg Posted January 28, 2015 Share Posted January 28, 2015 Hi, Thank you for playing our HTML5 video game!It would be impossible to remove the check word delaybecause the dictionary is 400,000+ words and needs time to scan through it.(it is somewhat optimized with separate files for each of the 26 English language letters) Thanks! JeZxLee Oh my you don't mean you are basically doing a linear search function CheckSelectedLettersForWord(){var playerWordToCheck = "";var currentDictionaryWord = ""; for (var index = 0; index < 11; index++) { if (SelectedLetterPlayfieldX[index] != -1 && SelectedLetterPlayfieldY[index] != -1) playerWordToCheck += String.fromCharCode( 96 + Playfield[ SelectedLetterPlayfieldX[index] ][ SelectedLetterPlayfieldY[index] ] ); else break; } var index = 0; while (currentDictionaryWord != "1") { if (Playfield[ SelectedLetterPlayfieldX[0] ][ SelectedLetterPlayfieldY[0] ] == 1) currentDictionaryWord = Awords[index]; else if (Playfield[ SelectedLetterPlayfieldX[0] ][ SelectedLetterPlayfieldY[0] ] == 2) currentDictionaryWord = Bwords[index]; else if (Playfield[ SelectedLetterPlayfieldX[0] ][ SelectedLetterPlayfieldY[0] ] == 3) currentDictionaryWord = Cwords[index]; else if (Playfield[ SelectedLetterPlayfieldX[0] ][ SelectedLetterPlayfieldY[0] ] == 4) currentDictionaryWord = Dwords[index]; else if (Playfield[ SelectedLetterPlayfieldX[0] ][ SelectedLetterPlayfieldY[0] ] == 5) currentDictionaryWord = Ewords[index]; else if (Playfield[ SelectedLetterPlayfieldX[0] ][ SelectedLetterPlayfieldY[0] ] == 6) currentDictionaryWord = Fwords[index]; else if (Playfield[ SelectedLetterPlayfieldX[0] ][ SelectedLetterPlayfieldY[0] ] == 7) currentDictionaryWord = Gwords[index]; else if (Playfield[ SelectedLetterPlayfieldX[0] ][ SelectedLetterPlayfieldY[0] ] == 8) currentDictionaryWord = Hwords[index]; else if (Playfield[ SelectedLetterPlayfieldX[0] ][ SelectedLetterPlayfieldY[0] ] == 9) currentDictionaryWord = Iwords[index]; else if (Playfield[ SelectedLetterPlayfieldX[0] ][ SelectedLetterPlayfieldY[0] ] == 10) currentDictionaryWord = Jwords[index]; else if (Playfield[ SelectedLetterPlayfieldX[0] ][ SelectedLetterPlayfieldY[0] ] == 11) currentDictionaryWord = Kwords[index]; else if (Playfield[ SelectedLetterPlayfieldX[0] ][ SelectedLetterPlayfieldY[0] ] == 12) currentDictionaryWord = Lwords[index]; else if (Playfield[ SelectedLetterPlayfieldX[0] ][ SelectedLetterPlayfieldY[0] ] == 13) currentDictionaryWord = Mwords[index]; else if (Playfield[ SelectedLetterPlayfieldX[0] ][ SelectedLetterPlayfieldY[0] ] == 14) currentDictionaryWord = Nwords[index]; else if (Playfield[ SelectedLetterPlayfieldX[0] ][ SelectedLetterPlayfieldY[0] ] == 15) currentDictionaryWord = Owords[index]; else if (Playfield[ SelectedLetterPlayfieldX[0] ][ SelectedLetterPlayfieldY[0] ] == 16) currentDictionaryWord = Pwords[index]; else if (Playfield[ SelectedLetterPlayfieldX[0] ][ SelectedLetterPlayfieldY[0] ] == 17) currentDictionaryWord = Qwords[index]; else if (Playfield[ SelectedLetterPlayfieldX[0] ][ SelectedLetterPlayfieldY[0] ] == 18) currentDictionaryWord = Rwords[index]; else if (Playfield[ SelectedLetterPlayfieldX[0] ][ SelectedLetterPlayfieldY[0] ] == 19) currentDictionaryWord = Swords[index]; else if (Playfield[ SelectedLetterPlayfieldX[0] ][ SelectedLetterPlayfieldY[0] ] == 20) currentDictionaryWord = Twords[index]; else if (Playfield[ SelectedLetterPlayfieldX[0] ][ SelectedLetterPlayfieldY[0] ] == 21) currentDictionaryWord = Uwords[index]; else if (Playfield[ SelectedLetterPlayfieldX[0] ][ SelectedLetterPlayfieldY[0] ] == 22) currentDictionaryWord = Vwords[index]; else if (Playfield[ SelectedLetterPlayfieldX[0] ][ SelectedLetterPlayfieldY[0] ] == 23) currentDictionaryWord = Wwords[index]; else if (Playfield[ SelectedLetterPlayfieldX[0] ][ SelectedLetterPlayfieldY[0] ] == 24) currentDictionaryWord = Xwords[index]; else if (Playfield[ SelectedLetterPlayfieldX[0] ][ SelectedLetterPlayfieldY[0] ] == 25) currentDictionaryWord = Ywords[index]; else if (Playfield[ SelectedLetterPlayfieldX[0] ][ SelectedLetterPlayfieldY[0] ] == 26) currentDictionaryWord = Zwords[index]; if (currentDictionaryWord == playerWordToCheck) return(true); index++; } return(false);}Oh, that's nasty, at the very least move the if-chain outside the inner loop...EDIT: this seems 10 - 100 times slower when I test compared to adding all the words as keys to an associative array and doing a single lookup to see if the word is present at call time Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.