Discuss Scratch

FROOGYCOOLCODEEER
Scratcher
41 posts

Can scratch improve the "touching" block

Can we have the “touching” block work offscreen?

Last edited by FROOGYCOOLCODEEER (May 26, 2025 12:50:49)

Olimon7661
Scratcher
1000+ posts

Can scratch improve the "touching" block

How? Scratch has something called sprite fencing, where sprites can't go off the screen. Basically, an imaginary fence going around the border of the project.
The_Blue_J
Scratcher
1000+ posts

Can scratch improve the "touching" block

Olimon7661 wrote:

How? Scratch has something called sprite fencing, where sprites can't go off the screen. Basically, an imaginary fence going around the border of the project.
Many way exist for sprites to get around that fence. In which case, the OP suggests to make touching work off-screen…
Love and fave detectors and report button detectors become impossible to circumvent with this method though, unless you perform the action before clicking the green flag.
OrangeFlyingCat
Scratcher
100+ posts

Can scratch improve the "touching" block

The_Blue_J wrote:

Love and fave detectors and report button detectors become impossible to circumvent with this method though, unless you perform the action before clicking the green flag.
Well, mouse clicks outside of the stage aren't (or at least shall not be) detected while mouse is not over the stage, touching mouse-pointer shall not work offscreen, and finally the mouse position is clamped. So I think this is not a problem.
FROOGYCOOLCODEEER
Scratcher
41 posts

Can scratch improve the "touching" block

FROOGYCOOLCODEEER wrote:

Can we have the “touching” block work offscreen?
What I mean is that the “touching” block work offscreen for scrolling projects.

Last edited by FROOGYCOOLCODEEER (May 26, 2025 21:03:27)

FROOGYCOOLCODEEER
Scratcher
41 posts

Can scratch improve the "touching" block

Olimon7661 wrote:

How? Scratch has something called sprite fencing, where sprites can't go off the screen. Basically, an imaginary fence going around the border of the project.
If you use the size or “Big” costume trick than the sprite can go offscreen
OrangeFlyingCat
Scratcher
100+ posts

Can scratch improve the "touching" block

FROOGYCOOLCODEEER wrote:

Olimon7661 wrote:

How? Scratch has something called sprite fencing, where sprites can't go off the screen. Basically, an imaginary fence going around the border of the project.
If you use the size or “Big” costume trick than the sprite can go offscreen
Yes, however, this will not provide unlimited movement. It will still be limited by the big costume's size. So I think it's better to just forget about the “touching” block in these cases and just make the hitbox mechanics.
FROOGYCOOLCODEEER
Scratcher
41 posts

Can scratch improve the "touching" block

what about when sprite that uses “touching” collision goes offscreen

OrangeFlyingCat wrote:

FROOGYCOOLCODEEER wrote:

Olimon7661 wrote:

How? Scratch has something called sprite fencing, where sprites can't go off the screen. Basically, an imaginary fence going around the border of the project.
If you use the size or “Big” costume trick than the sprite can go offscreen
Yes, however, this will not provide unlimited movement. It will still be limited by the big costume's size. So I think it's better to just forget about the “touching” block in these cases and just make the hitbox mechanics.
what about when sprite that uses “touching” collision goes offscreen ;/
OrangeFlyingCat
Scratcher
100+ posts

Can scratch improve the "touching" block

FROOGYCOOLCODEEER wrote:

what about when sprite that uses “touching” collision goes offscreen

OrangeFlyingCat wrote:

FROOGYCOOLCODEEER wrote:

Olimon7661 wrote:

How? Scratch has something called sprite fencing, where sprites can't go off the screen. Basically, an imaginary fence going around the border of the project.
If you use the size or “Big” costume trick than the sprite can go offscreen
Yes, however, this will not provide unlimited movement. It will still be limited by the big costume's size. So I think it's better to just forget about the “touching” block in these cases and just make the hitbox mechanics.
what about when sprite that uses “touching” collision goes offscreen ;/
Nothing. No collisions. Though I can't see how this is related to my suggestion. By the way, this “Big” costume trick is not intended - after all, the bordering was made to prevent the sprites from going offscreen. So I don't think your suggestion will be added.
FROOGYCOOLCODEEER
Scratcher
41 posts

Can scratch improve the "touching" block

I am closing the discussion

Powered by DjangoBB