Can anyone tell me what I am doing wrong?


#1

Here is the code for a game I am making where you select a level and the heart start moving and then you catch the heart. But! It won't start moving. Everything else works but the fact that the heart won't move. Any help would be greatly appreciated.


#2

Welcome to the forum! I think we need a link here.


#4

Whoops!

You're telling your full name, please take it out of that post.

It is personal info and cannot be told on the Internet. Don't worry, we have had this before!

And we have to have the link to test it and really see through all the code, it helps.


#5

Can you send us the link to the game? Just quickly post get the link and then unpost


#6

Can you please take your personal information out of your post? You're new, but for future reference please don't include your full name in posts. It isn't allowed :wink:


#7

I'm sorry, it was my automatic signature, it's kind of annoying. Anyway do you know what's wrong? The photos weren't in the correct order, sorry.


#8

That's ok. Just don't do it again :wink:


#9

I don't see any move forwards/change _ by/ set position in the heart's code. I only see set speed, which only changes the speed of the object's movement, not make it move. Hope this helped!
Edit: You didn't show what was inside "When game starts", which might have the movement code. Sorry!


#10

No there is nothing inside that


#11

Also here is the link: https://c.gethopscotch.com/p/y3tlej575


#12

Then you just add "Move Forward (random (something negative to make it go left) to (something positive to make it go right))"! The speed correlates with that, too, if the speed was for difficulty!


#13

But there's a set location block in there too, doesn't that do it?


#14

The Set Location doesn't correlate with speed, only Change X by, Change Y by, and Move Forward do!


#15

Oooooooooh that makes a lot of sense. I will try and tell you if it works


#16

For some reason it still does not work. Try here: https://c.gethopscotch.com/p/y3xd3trft


#17

You put the code in the one of circle's rules instead of the heart's, so the heart isn't affected. :D

Wait, why is that post flagged?


#18

Thank you all sososo much for helping me out, I really appreciate it. Later on when I publish the finished game I will credit you. My hopscotch username is blackie810. Thanks again


#19

Also I don't know why that was flagged?


#20

The finished project is up! I have followed you so you can see it there. Give a like if you want :slight_smile: