Help with project, making sure objects are tapped the right order?

helpwithcode

#1

I am trying to do a memory game. When you click start, the stars flash in a certain sequence. I am not sure how to make sure they are tapped in the correct order. Any help will be appreciated.


#2

Hi @Glitter_Kitty! I'm not sure how to do this? But I think I have an idea! This concept might be the same as the keyboard projects. You could search them up and check out the code. I never really paid attention to the code.


#3

I don't think that will work because I am pretty sure that the keyboard is Set Position. But, thanks for your idea.


#4

Think of the stars as controlling a car . When first is tapped the car moves x 50. Second is tapped the car moves y 50. 3rd is tapped the car moves x 30. 4th is tapped the car moves y 100. 5th is tapped the car moves x100. At the end of each move a ball is set to the cars x-y position. So there are five different balls onscreen. After the fifth move set the cars x-y position to where the car started from. Create a value Repeat 5 times (set value random 1 to 5. If value EQUALS 1 have a 99% invisible object BUMP star 1 and have it dissapear then reappear.
Type this again with EQUALS 2 and BUMP star 2 type again replacing 2 with 3 and so on till you have done EQUALS 5 and BUMP star 5)
Have the car and balls 99% invisible. When each star is bumped into randomly the cars moves and leaves a ball there. when you tap the stars you have to do it in the same order they appeared and disappeared to make the car move the same as it first did to bump the balls that were left in the first five moves. Have a score that goes up when the car bumps into each ball and have the balls go invisible 100 when car bumps them


#5

What I mean by bump star is have a 99% invisible object move up and bump the star the set its position to below that star.


Problems with 99% invisibility
#6

7 days from now I'll publish this to hopscotch. Search for my name and you can see how it's done.


#7

When star 1 is tapped, increase value stars by 1. When star 2 is tapped, check once if value star equals 1, then increase value stars by 1. (dot the other stars, increase the number in check once if.


#8

@KathrynJ @Stradyvarious @Glitter_Kitty @AwesomeGal1b

This is awesome! Great question and great replies :slightly_smiling: We could even add a few more screenshots in the answers to make them crazy good :stuck_out_tongue:!


#9

I might but there would be 5-6 screen shots and I'd have to explain clearly. I've explained more clearly today on the memory game and how to make it.


#10

I posted a message today explaining more clearly ■■■. Click my badge and find the message I posted


#11

Cool! Can you post the link here, too? Can be hard to find on your profile since you've posted a lot :stuck_out_tongue:


#13

@Stradyvarious here's how to get the links to Hopscotch projects :smiley:


#14

Use values! I can show you how if you want!


#15

https://c.gethopscotch.com/p/xftj0agbn I made a memory test game where you have to tap the balls in the right order after watching them pop shortly after my last reply.