No video

Creating Mobile Controls on Scratch

  Рет қаралды 23,232

How-To-Scratch

How-To-Scratch

Күн бұрын

Пікірлер: 111
@Johnlafun4-hr9xb
@Johnlafun4-hr9xb Күн бұрын
Thank you, I didn’t know that it needed the ‘mouse down’ block. Because if you don’t use that block, the scratch cat just goes in that direction forever. Thank you for the tutorial!
@how-to-scratch
@how-to-scratch Күн бұрын
Yep! Glad it helped. Thank you!
@MossManOG
@MossManOG 3 ай бұрын
It works very well! I had to make my game mobile friendly before a school project, and this was very quick and easy to do.
@how-to-scratch
@how-to-scratch 3 ай бұрын
Awesome! I’m glad it helped!
@floppathejetskider
@floppathejetskider 6 ай бұрын
It works and it’s perfectly smooth, 10/10!
@how-to-scratch
@how-to-scratch 6 ай бұрын
Awesome to hear!
@supremeobbymasters1936
@supremeobbymasters1936 3 ай бұрын
You are a life saver I need it this for my first scratch game
@how-to-scratch
@how-to-scratch 3 ай бұрын
Thank you!! I am glad it helped :D
@luigigamingsm
@luigigamingsm 21 күн бұрын
Maybe you should add a platform so that you can program the sprite to go to the ground after clicking the jump button
@Antarctica_ice
@Antarctica_ice 7 ай бұрын
Just put this code: When this Sprite (Arrow Button On Mobile) Clicked Broadcast [ (Left Or Right Message) ] For the Character: If i received Broadcast [ (The lastest Message) ] And put some Motion blocks that countain moves!
@MateusLord
@MateusLord 5 ай бұрын
E se eu quiser que ele fique em loop, até eu soltar?
@NotAlphaSlayer15
@NotAlphaSlayer15 4 ай бұрын
@@MateusLord*use* *if touching mouse pointer and mouse down?*
@MateusLord
@MateusLord 4 ай бұрын
@@NotAlphaSlayer15 obrigado
@Blue_skiesGacha
@Blue_skiesGacha 7 ай бұрын
This is really smooth! Ty!
@how-to-scratch
@how-to-scratch 7 ай бұрын
You’re welcome!
@NotAlphaSlayer15
@NotAlphaSlayer15 5 ай бұрын
*use for jump* *If then Key up arrow pressed or mouse down?* *change y by (y speed) or (number)*
@OWG335
@OWG335 Жыл бұрын
Love your videos am Wolfgang355 Remember me from scratch
@how-to-scratch
@how-to-scratch Жыл бұрын
Thank you! Yes, of course I remember!
@vitinhogames3207
@vitinhogames3207 2 ай бұрын
How to press jump and walk at the same time, mine doesn't work, can do it at one time.
@how-to-scratch
@how-to-scratch 2 ай бұрын
Make sure the events in the player where the player walks and jumps are not in the same chunk of script.
@farhanzifaan3184
@farhanzifaan3184 2 ай бұрын
Ohhhh so is mean we can't do it cuz of script?
@daviddoss3221
@daviddoss3221 Ай бұрын
You can do it with the move () steps too.
@Exinciti
@Exinciti Жыл бұрын
nice
@how-to-scratch
@how-to-scratch Жыл бұрын
Thank you!
@thirishwehlaing2274
@thirishwehlaing2274 8 ай бұрын
I'm making a platformer so this help me a lot
@how-to-scratch
@how-to-scratch 8 ай бұрын
Glad to hear it helped!
@melonstuff9creative
@melonstuff9creative 4 ай бұрын
oh my freaking god it works thank you!!
@how-to-scratch
@how-to-scratch 4 ай бұрын
I’m glad it helped!
@user-li8jg6fs9y
@user-li8jg6fs9y 4 ай бұрын
Cool
@how-to-scratch
@how-to-scratch 4 ай бұрын
Thank you!
@totallynotfoox
@totallynotfoox Жыл бұрын
Thx
@how-to-scratch
@how-to-scratch Жыл бұрын
No problem!
@SlightlyOffendedKiwi
@SlightlyOffendedKiwi 9 күн бұрын
Hey, this might be kind of a complicated question.. but I’m making a game that is both mobile and PC compatible. It’s easy to code in the whole “if clicking right arrow move right” thing and it’s easy to put in the little arrows + jump for mobile. For context, at the beginning of the game it asks “are you on mobile or PC” to which it sends the signal of whatever the player clicks, BUT there are multiple places on the map you have to travel to, and when it opens a new backdrop, it HAS to send the signal to get mobile controls regardless of what the player selected because I don’t know how to make it consistently check if the player is/selected mobile. Is there a way I can code it in so when the player selects that, it’s possible to check, especially since both “When background switches to” and “when I recieve (signal)” are top blocks, therefore can’t be stacked together. Is this too complicated?? Let me know if you have any other questions. Thanks !!
@how-to-scratch
@how-to-scratch 9 күн бұрын
@@SlightlyOffendedKiwi hi! Let me see if this is correct. When you initially select mobile, what if you set a variable you could call mobile to true, then throughout the project have an if statement that checks if mobile = true and if so shows the controls? If I misunderstood please let me know!
@SlightlyOffendedKiwi
@SlightlyOffendedKiwi 9 күн бұрын
@@how-to-scratch hey that might work! If I understand you right, I should make a variable titled ‘mobile’ and when the player selects said variable, I put a statement saying “if mobile = true then show controls”? Let me run the code for that
@how-to-scratch
@how-to-scratch 7 күн бұрын
@@SlightlyOffendedKiwi essentially yes! Rather, when the player selects the option for mobile (whatever button they select mobile with) then it sets the variable mobile to true
@SlightlyOffendedKiwi
@SlightlyOffendedKiwi 6 күн бұрын
@@how-to-scratch it worked! Thank you so much!!
@Villangaming716
@Villangaming716 4 ай бұрын
Make scratch cat face the direction of the button when pressed like me
@how-to-scratch
@how-to-scratch 4 ай бұрын
Ah! To do that, do this: When Green Flag Pressed: Set Rotation Style Then for each button, when pressed on the left button: Point in direction: -90 For right button: Point in direction : 90
@PhiliponBauvart-on8rl
@PhiliponBauvart-on8rl 7 ай бұрын
Thank you for your video you are the best
@how-to-scratch
@how-to-scratch 7 ай бұрын
No problem, and thank you!!
@Exinciti
@Exinciti Жыл бұрын
Also could you make a how to add gravity tutorial?
@how-to-scratch
@how-to-scratch Жыл бұрын
Hey! You can find information on gravity here! kzbin.info/www/bejne/gXKzmGmvjbudqpY
@Exinciti
@Exinciti Жыл бұрын
@@how-to-scratch thanks
@how-to-scratch
@how-to-scratch Жыл бұрын
@@Exinciti No problem.
@codeacademy6394
@codeacademy6394 Жыл бұрын
when green flag clicked forever change y by (Gravity) change [Gravity] by (-1)
@nutobrewe_banana
@nutobrewe_banana 8 ай бұрын
I managed! but when the sprite left and right buttons are hidden and if I click in the same place where they are, the code will work! what's the matter? how to remove?
@how-to-scratch
@how-to-scratch 8 ай бұрын
Huh, weird! That should not be possible. Make sure that they are hidden with the "hide" block, and if that fails, I would try to temporarily relocate the buttons to the edge of the screen until no longer hidden: if hidden: go to: -999,-999 else: go to: (position for when not hidden) And yo u can check for if hidden however you want to.
@nutobrewe_banana
@nutobrewe_banana 8 ай бұрын
@@how-to-scratch very thanks!
@how-to-scratch
@how-to-scratch 8 ай бұрын
@@nutobrewe_banana Of course!
@Cursenothere
@Cursenothere 8 ай бұрын
broadcast is a easier way for me but this is better
@hoytt8141
@hoytt8141 8 ай бұрын
Thanks bro 😎
@ronjharedrobles2960
@ronjharedrobles2960 7 ай бұрын
hiim from 2024 of january im 2 day old de, i think u should use ,when this sprite is click, if "not-mousedown" then, brodcast message 1(for arrows),when i receive "message 1", repeat 10 change x by 10
@andrejbreininger8889
@andrejbreininger8889 8 ай бұрын
How can do that walk and jump both work when I press them both
@Driftingbears88
@Driftingbears88 4 ай бұрын
It work but in the platformer it goes through the platform i just dont understand
@lizzyr.i.p2203
@lizzyr.i.p2203 4 ай бұрын
Hello how can I make it so that the character can move around a 2d map with the mobile controls (scrolling camera basically). Because I’ve been having trouble to find how to do it. And if there’s anything you don’t understand then let me know :D
@how-to-scratch
@how-to-scratch 4 ай бұрын
If it’s for a scrolling platformer, here is a video that would help with that: Creating Your First Scrolling Platformer on Scratch - LEARN HOW! kzbin.info/www/bejne/ZmOohGqbbK17o6s You could implement the button controls with the video by using broadcasts to tell the level when to move.
@lizzyr.i.p2203
@lizzyr.i.p2203 4 ай бұрын
Thank you, but I’ve been trying to do the code and it still doesn’t work. Can you give me the code so I can make it when I click the mobile button the camera scroll moves aswell? And also sorry if I’m bugging you or anything.
@how-to-scratch
@how-to-scratch 3 ай бұрын
@@lizzyr.i.p2203 I will need to view the actual project and code itself so I can see how you are working with it so far. Would you be able to share it with me?
@user-mv5jp4gq7i
@user-mv5jp4gq7i 3 ай бұрын
It works
@how-to-scratch
@how-to-scratch 3 ай бұрын
That’s great to hear!
@differentsmile6398
@differentsmile6398 7 ай бұрын
And not maze wall detection
@Hitsomni
@Hitsomni Ай бұрын
I can't jump and move right/left at the same time
@how-to-scratch
@how-to-scratch Ай бұрын
Make sure they aren’t in the same chunk of code
@Physicsless8
@Physicsless8 8 ай бұрын
how could i insert the when i receive jump into an if key pressed box
@how-to-scratch
@how-to-scratch 8 ай бұрын
What if you did, When I receive jump > if key pressed?
@farhanzifaan3184
@farhanzifaan3184 2 ай бұрын
Can you tell me when i turn left the chracter also turn left plz tell me
@how-to-scratch
@how-to-scratch 2 ай бұрын
Make sure you have this: When Green Flag Clicked: Set Rotation Style
@farhanzifaan3184
@farhanzifaan3184 2 ай бұрын
@@how-to-scratch thanks for give idea
@Bobby_Unstoppable977
@Bobby_Unstoppable977 7 ай бұрын
Thankyou
@how-to-scratch
@how-to-scratch 7 ай бұрын
You're w elcome!
@GroundFIsher
@GroundFIsher 6 ай бұрын
What if I have animations in a sprite when it walks? It's really glitchy
@how-to-scratch
@how-to-scratch 6 ай бұрын
You are absolutely right! Create a separate loop for the animation. You could do: When flag is clicked: Forever: If Touching and Mouse Down?: Switch Costume to Wait 0.15 Switch Costume to
@Villangaming716
@Villangaming716 4 ай бұрын
But yeah it’s smooth
@maneywintersky
@maneywintersky 5 күн бұрын
Change x by -10 is Not working 😭
@how-to-scratch
@how-to-scratch 4 күн бұрын
Noooo that’s not good
@maneywintersky
@maneywintersky 4 күн бұрын
Change x by -10 does the same thing as moveright can you please fix it
@maneywintersky
@maneywintersky 4 күн бұрын
Okay i found Out this is works is by making move left by (Move -10 steps!)
@asmaabdulhakim
@asmaabdulhakim 7 ай бұрын
does this help when we use touch screen also?
@how-to-scratch
@how-to-scratch 7 ай бұрын
Yes!
@Axochata
@Axochata 2 ай бұрын
When I receive button doesn’t exist
@Axochata
@Axochata 2 ай бұрын
Nvm I found it
@how-to-scratch
@how-to-scratch 2 ай бұрын
@@Axochata yay!
@nathanc6443
@nathanc6443 5 ай бұрын
So how to touch 2 places at once
@how-to-scratch
@how-to-scratch 5 ай бұрын
Could you give an example of what you mean please? :D
@nathanc6443
@nathanc6443 5 ай бұрын
@@how-to-scratch i want to go right but jump at the same time but im not sure if that would work
@nathanc6443
@nathanc6443 5 ай бұрын
@@how-to-scratch like in my platformer i tried adding mobile controls but what happened was it didn’t work as well because you cant jump and go right at the same time
@Ligmaballssussybaka
@Ligmaballssussybaka 5 ай бұрын
Hey thats my idea
@differentsmile6398
@differentsmile6398 7 ай бұрын
I make maze for mobile but i try making like this mobile control but the cat going in maze wall 🧱 so what solution
@how-to-scratch
@how-to-scratch 7 ай бұрын
Try following this maze tutorial here: kzbin.info/www/bejne/ioWopHuelsqdkJo Implement the mobile controls with the collision detection and see if that works!
@how-to-scratch
@how-to-scratch 7 ай бұрын
If you get stuck along the way, feel free to share and send the project here, and I can help with the code if you would want!
@Why_why7352
@Why_why7352 6 ай бұрын
5:09
@sapphireshorts249
@sapphireshorts249 8 ай бұрын
Open Scratch But On Mobile
@user-qr7zr9gb4k
@user-qr7zr9gb4k 9 ай бұрын
O have question for you?
@how-to-scratch
@how-to-scratch 9 ай бұрын
Let me know your question and I’ll do my best to answer!
@MusaAslam-on8ej
@MusaAslam-on8ej 9 ай бұрын
It didnt work
@how-to-scratch
@how-to-scratch 9 ай бұрын
I'd love to take a look at your code and see what the issue might be! Would you be able to send me the link to the project, and then I could possibly help you with it?
@LVXD-og7iw
@LVXD-og7iw 7 ай бұрын
​@@how-to-scratchit didnt work because you only can press ONE button at the same in a phone, because scratch uses "the pointer" to touch a button, and "the pointer" is 1, no 2 or more
@LVXD-og7iw
@LVXD-og7iw 7 ай бұрын
​@@how-to-scratchThis is the reason because is imposible
@America_flag24
@America_flag24 5 ай бұрын
@@LVXD-og7iwYou forgot to send the link of the project.
@Ligmaballssussybaka
@Ligmaballssussybaka 5 ай бұрын
​@@how-to-scratchthats literally my ideas on mobile
@superyousif
@superyousif Жыл бұрын
the quality is so bad
@how-to-scratch
@how-to-scratch Жыл бұрын
On the video?
@superyousif
@superyousif Жыл бұрын
yeah
@how-to-scratch
@how-to-scratch Жыл бұрын
@@superyousif That's odd. It shouldn't be bad because the highest quality it goes to is 1080p60FPS.
@barryiscool
@barryiscool 10 ай бұрын
​@how-to-scratch nahh bro the quality is amazing 👌
@Nash188
@Nash188 10 ай бұрын
@@barryiscool for real broo
ChatGPT Makes a Scratch Game
10:30
PolyMars++
Рет қаралды 1 МЛН
Kids' Guide to Fire Safety: Essential Lessons #shorts
00:34
Fabiosa Animated
Рет қаралды 16 МЛН
Вы чего бл….🤣🤣🙏🏽🙏🏽🙏🏽
00:18
Whoa
01:00
Justin Flom
Рет қаралды 33 МЛН
Pool Bed Prank By My Grandpa 😂 #funny
00:47
SKITS
Рет қаралды 20 МЛН
How to make a Joystick in Scratch | Scratch Tutorial!
8:26
Alex Steve
Рет қаралды 22 М.
I Spent 6 Years Making Games in Scratch
10:03
chipm0nk
Рет қаралды 329 М.
Chat GPT Decides What Scratch Game I Make!
2:51
Huney
Рет қаралды 255
How to Play ANY SCRATCH GAME on MOBILE! (The Correct Way)
1:01
McVincient
Рет қаралды 18 М.
The Variable HACK 🔨 Not many Scratchers know... yet
10:33
griffpatch
Рет қаралды 605 М.
Scratch Movement with a Touch Screen
11:38
D Greenwood
Рет қаралды 19 М.
Scratch Mods NOBODY knows About!
7:42
ProjectLabs
Рет қаралды 48 М.
Top 10 Scratch Games (October 2022)
18:57
ShiftClickLearn
Рет қаралды 2,5 МЛН
Minecraft But On Scratch
7:23
Irrelevant
Рет қаралды 468 М.
I Tried Making a 3D Game in Scratch
8:01
Jackson Academy
Рет қаралды 335 М.
Kids' Guide to Fire Safety: Essential Lessons #shorts
00:34
Fabiosa Animated
Рет қаралды 16 МЛН