Search found 7 matches
- Sun Feb 28, 2016 4:12 am
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: Guessing Game
- Replies: 16
- Views: 13407
Re: Guessing Game
Thank you so much Craig!!! You saved the day for me! I changed the code slightly, simply to customize it for my needs, but it works beautifully, and in just the way I wanted it to.
- Sat Feb 27, 2016 3:36 am
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: Guessing Game
- Replies: 16
- Views: 13407
Re: Guessing Game
Jacque, thank you for the information. I am more familiar with Java and C#, so I am used to using ampersands. Hi Craig. That code works well, but I am hoping to find a way to continue the input from the field, rather than the ask window. I tried to edit the code to work with the field, but I have no...
- Thu Feb 25, 2016 3:08 am
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: Guessing Game
- Replies: 16
- Views: 13407
Re: Guessing Game
Hi Craig. Thanks for the advice. I think that is exactly what is happening, since it works without the if statement around the random code, but I'm not entirely sure how to resolve that. I want the random number to stay the same until it is correctly guessed, but the if statement around the random c...
- Wed Feb 24, 2016 7:39 pm
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: Guessing Game
- Replies: 16
- Views: 13407
Re: Guessing Game
This is my current code. All of the errors seem to be referencing my "if" and "else if" statements, but I'm still unsure what the issue is. on mouseUp put the text of fld "fld_guess" into theGuess set the randomSeed to the long seconds if theAnswer is empty then put random(100) into theAnswer end if...
- Wed Feb 24, 2016 6:41 pm
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: Guessing Game
- Replies: 16
- Views: 13407
Re: Guessing Game
I did. I tried it with and without the repeat loop, and neither seems to be working. I get a different error message each way. I get the message "button "Submit Guess": execution error at line 17 (Operators -: error in left operand), char 5" without the repeat loop and "button "Submit Guess": execut...
- Wed Feb 24, 2016 2:44 pm
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: Guessing Game
- Replies: 16
- Views: 13407
Re: Guessing Game
Hi Simon! Thanks for pointing me to that thread. I tried the suggestions listed, and I am still having trouble, but I'm not really sure why. The code worked before, except for the infinite answer loop, but now, I'm getting an error whenever I run it. I added to my previous code: if theAnswer is empt...
- Wed Feb 24, 2016 6:13 am
- Forum: Getting Started with LiveCode - Complete Beginners
- Topic: Guessing Game
- Replies: 16
- Views: 13407
Guessing Game
Hi everyone! I am learning LiveCode for a class, and we are making a guessing game. I have the game working pretty well, but I'm trying to keep the same random number until it is correctly guessed, but how I have it set up currently, I set off an endless answer loop and have to force quit to stop it...