Help me with something please!


Hello everyone,

I am currently working on a new game, but I have a question: Imagine a trail and an emoji which you can control by a joystick. If I “lead” my emoji to the trail I want it to stop so it doesn’t cross the line. Same thing with another emoji for example, I want it to be “stuck to the ground” so my emoji that I control won’t go through it. Help me please!

Thanks in advance


Please help me with something...


Welcome to the forum!

So you want there to be a line of trail art, and the emoji can’t go past it? Maybe try making an object the width/length of the trail, make it 99% invisible, and when the emoji bumps it, it can’t go past… idk how to keep it from going past tho.


Ugh such a problem. I’ll be willing to think through ideas later, but consider posting a video of the problem for me to help you better.


Hi everyone,

I am currently working on a game, but there’s something I need to know to move on: Imagine a trail and an emoji which you can control by a joystick. If I “lead” my emoji to the trail I want it to stop so it doesn’t cross the line. Or imagine another emoji, which is also “stuck to the ground” so the emoji that I control can’t go through it. Maybe there’s another person who already asked this, but please tell me then where I can find it.

Thanks in advance



So, if the line is straight horizontally or vertically, you can make the emoji only move as a result of the joystick when it’s y (if your line is horizontal) or x (if your line is vertical) is less than that of the line. I don’t know what kind of joystick code you are using, but inside the code for the emoji, take all the code inside the blocks that make it move of the joystick is moved and put them all inside (Check Once If self y position < text y position). That code is assuming your line is a straight horizontal y, a text object drew the line, and the line is relatively thick. If your line is thinner, you would have to do text y position - 10. The number may have to be greater than 10 depending on the size of the emoji. 10 was a random guess. Basically, here’s what the code would look like:

When (joystick blah blah blah)
-check once if self y position < text y position-10
• move forward 5

It would look like this:

:grinning: |

With the second emoji, I’m not as sure of my code on that one, but I would think that either you would have to use some check once if with a whine bunch of and’s. I would have to actually code it for it to make sense or you may want to wait for someone else to tell you an easier method.


Welcome to the forum! @tankt2016


Thank you so much! I’m going to try it out now!


Welcome to the Forum!
Tag me for anything (@GweTV)


Welcome to the forum! ask tankt for info on how to use it and check #faq for info too


Tell us if it works! Also, welcome to the forum! We are here to help you with whatever you are wondering.


Welcome @Universtar!

If you make an object and set the width and height to the area the emoji doesn’t need to go, then make it 99% invisible, you almost cannot see it, then make it so the emoji cannot cross the line. You can do this by changing the X by the opposite direction from where the emoji is from the line.


Everyone is so kind to me :relieved: thank you all for helping me with this. I’ve been working on this game for a few weeks now, almost finished. It’s actually my first « serious » game, cuz my other games are silly. If you want to check them out, one of them is called « Story of a lifetime » Worked a few minutes on it… :innocent:


Well done! I will go and check out your games later today when I get home :slight_smile:


Me too @Universtar. I am up for it. :grinning:


I liked them. Good job!


Thanks! I actually have 2 accounts, idk why, but on Un1v3rstar I have also 3 « games » (they’re actually not games, cuz they are that silly) but hey if you want to check them out, feel free to do so :stuck_out_tongue::upside_down_face:


My Acoount in Hopscotch is ChickenProductions7.


Checking it out now!