This is a read-only archive of the old Scratch 1.x Forums.
Try searching the current Scratch discussion forums.

#1 2009-01-01 11:23:47

bosox397
Scratcher
Registered: 2008-02-17
Posts: 1000+

The sensing blocks

I have seen people using this block:  xposition of Sprite1


Now I know how to get all the basic scrolldowns like x position, y position, direction and so on but i don't know how to get others.


For example, in my newest game Kitten Cannon, paddle2see was trying to help me put in angles. he told me all the scripts and i did them except one part. He used trig and in one part he used a block like the sensing block i am talking about except instead of having the basic scrolldowns, it included something else which i could not make. It said Barrelength of Sprite1.  I have also seen others like in Archknghts project Archknight's Adventure to use collision detection he used one of those sensing blocks with a centerhittest of sprite1   All i am asking is how do u get those kind of scroll downs and how can you make them work?


Dear Scratch Users,
I'm done with scratch, or at least making projects. I have made one last big game, thats both fun and teaches a lesson about water. It'd mean a lot if you gave me feedback.                              http://scratch.mit.edu/projects/bosox397/569201

Offline

 

#2 2009-01-01 12:07:32

Dan01
Scratcher
Registered: 2008-06-11
Posts: 100+

Re: The sensing blocks

Those are variables of that sprite. If you create a variable that is only used for that sprite, then it will appear on the () of sprite 1.

For example: If you made the variable "Score" on sprite 1. If you were to go to sprite 2 and take out that block; if you selected sprite 1, you could select the score of sprite 1.


http://img3.imageshack.us/img3/4743/ubd6522wp8.png
http://img3.imageshack.us/img3/4667/ubd3758ox2.png

Offline

 

#3 2009-01-01 13:00:11

JSO
Community Moderator
Registered: 2007-06-23
Posts: 1000+

Re: The sensing blocks

You have to select the sprite from the second dropdown box first, that's quite confusing.


http://oi48.tinypic.com/2v1q0e9.jpg

Offline

 

#4 2009-01-01 13:57:57

Lucario621
Community Moderator
Registered: 2007-10-03
Posts: 1000+

Re: The sensing blocks

Yeah so for example, if Player 1 has 2 variables called xVel and yVel, Player 2 can use that block as xVel of Player 1, or x position of Player 1


http://i.imgur.com/WBkM2QQ.png

Offline

 

#5 2009-01-01 16:29:45

bosox397
Scratcher
Registered: 2008-02-17
Posts: 1000+

Re: The sensing blocks

Oh. i'm stupid. THANK YOU!


Dear Scratch Users,
I'm done with scratch, or at least making projects. I have made one last big game, thats both fun and teaches a lesson about water. It'd mean a lot if you gave me feedback.                              http://scratch.mit.edu/projects/bosox397/569201

Offline

 

#6 2009-01-01 20:07:55

Paddle2See
Scratch Team
Registered: 2007-10-27
Posts: 1000+

Re: The sensing blocks

You're not stupid...it's not a well documented feature and it is a bit complicated to understand.  Sorry I didn't explain it better...I didn't understand what you were asking.


http://i39.tinypic.com/2nav6o7.gif

Offline

 

#7 2009-01-01 20:55:19

bosox397
Scratcher
Registered: 2008-02-17
Posts: 1000+

Re: The sensing blocks

Paddle2See wrote:

You're not stupid...it's not a well documented feature and it is a bit complicated to understand.  Sorry I didn't explain it better...I didn't understand what you were asking.

i actually just used it in a new game im working on.


Dear Scratch Users,
I'm done with scratch, or at least making projects. I have made one last big game, thats both fun and teaches a lesson about water. It'd mean a lot if you gave me feedback.                              http://scratch.mit.edu/projects/bosox397/569201

Offline

 

Board footer