Access to Multitouch in code

A feature I’d like to see in Hopscotch is:

Ways to access multitouch in code, in addition to single touch

I’d use it for this type of project:

It could be used for

  • drawing pads (pinch to zoom on a drawing, two-finger tap to undo, rotate with two fingers)
  • video games (zoom in on a map)

Here are some examples of Hopscotch code that could be improved if we had this:

I would like to use it to try and code these functionalities:

  • pinch to zoom
  • twist to rotate

Here is an example design I’ve made:

I think some functionality for collections might be needed, but maybe something like this:

There’s also a design at the bottom of this post by Awesome_E

I’ve seen something similar in another programming languages, it looks like this:

This is in Codea, an iPad coding app that uses Lua

18 Likes

cool idea

5 Likes

T1! I haven’t seen you in a long time though you might not know me

3 Likes

Ooh nice
Pinching in/out will be a thing
I wish I knew lua ahem roblox

2 Likes

Oh, hello t1. I actually know a bit of Lua too.

This would be an excellent idea - I would use it for an abstract effect game.

3 Likes

I would maybe use this for a transition (if you are implying that the computer zooms in and out). But could you turn it off? Or is it something you have to code into your game?

Been wanting something like this for a while now. Multitouch is a thing but it only understands one point of origin with the last touch X and Y

7 Likes

Hmm cool idea

I think in addition there should be a way to test if multiple fingers are touching the screen. Then I would so use this for making a better “Teleportation Glitch Prevention”

Other than that, it’s a great idea. Hopscotch sort of supports multitouch, but there is currently no way to tell.

This is a great idea!

I like this idea, will add it to our list!

Something we are considering is creating a way to optionally add more advanced code blocks to your editor. I’d imagine this feature living in that area. My sense is that it would be overwhelming for beginners.

14 Likes

something like “enable beta editor” but replace “beta editor” with “advanced editor” or smth

3 Likes

Maybe like a button that shows up right above the keyboard that switches to an advanced version

6 Likes

When ipad is tapped increase a variable by 1. When iPad is not pressed, set the variable to 0. The variable will be a pretty good idea of how many fingers are on the screen. If you put 2 or more fingers on the screen at about the same time, it’ll only count 1, though.

2 Likes

That would be really cool. I have seen a basic editor and advanced editor before in my 2-3 years of programming outside hopscotch. Would be interesting to see that in Hopscotch.

Major updates just keep on getting better and better.

1 Like

One GUI design I think would be perfect for a button like that would be “A code stack with a plus sign in the bottom right corner”

2 Likes