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

#26 2008-01-05 20:51:52

Heybrian
Scratcher
Registered: 2007-12-05
Posts: 100+

Re: A recieve sensing block

EdnaC wrote:

I think that a receive sensing block would just be confusing, as it is very easy to implement with the basic commands that exist.  Instead of sending a broadcast, you could just change a variable when you want the paused script to continue (or whatever it is that you want). 

"Wait until I receive" could be done like this:

|-Forever
|  If Variable = 0
|  Wait 0.05
|  Stop Script   (this will just make the script keep waiting)
|       
|  Do the stuff you were waiting for....  (This will execute when the variable changes)
|  Varible = 0 (To keep the script from running again)

It seems just as easy to switch the value of a variable as to send a broadcast (to me).

Mr Ed

yes but variables sometimes mess up the script if ur doing an rpg game for example, you know when you have like so many number scripts and too many variables, (the ones you already have) it gets kind of glitchey  or buggy. that why things like the next costume trick wont work when you have that. belive me, if anything, scratch needs to be able to hold more data.


Black Mesa. go here to get a game 10 times better than SN or FW.  http://scratch.mit.edu/galleries/view/10650
Smiley! copy and paste these into your post or signature!  smile   sad    yikes                 big_smile     wink    tongue    hmm    neutral   cool   lol   mad   roll

Offline

 

#27 2008-01-05 20:55:00

Heybrian
Scratcher
Registered: 2007-12-05
Posts: 100+

Re: A recieve sensing block

Heybrian wrote:

YES!

uh but the message after it and whyed you put that?


Black Mesa. go here to get a game 10 times better than SN or FW.  http://scratch.mit.edu/galleries/view/10650
Smiley! copy and paste these into your post or signature!  smile   sad    yikes                 big_smile     wink    tongue    hmm    neutral   cool   lol   mad   roll

Offline

 

#28 2008-01-05 21:20:51

funkymonkey
Scratcher
Registered: 2007-06-03
Posts: 1000+

Re: A recieve sensing block

Heybrian wrote:

funkymonkey wrote:

Heybrian wrote:


not if you have like ten scripts and ur doing an rpg game. that is one script. imagine a 1 week long rpg game to make. it will not work .same with     
            <when I receive[ shoot
              <repeat until> <( costume # <=> 4 )>
                  <next costume>

what is that script working for? once you know that, then you can decide if it will work.

huh?

nevermind. my point is, both of the scripts you pointed out will work


http://i243.photobucket.com/albums/ff67/hprules_photos/banner2.jpg
Kuzimu: Dawn of a New Age                                                                                                  Coming May 2010

Offline

 

#29 2008-01-05 21:22:14

funkymonkey
Scratcher
Registered: 2007-06-03
Posts: 1000+

Re: A recieve sensing block

Heybrian wrote:

Heybrian wrote:

YES!

uh but the message after it and whyed you put that?

is that the kind of block you want?


http://i243.photobucket.com/albums/ff67/hprules_photos/banner2.jpg
Kuzimu: Dawn of a New Age                                                                                                  Coming May 2010

Offline

 

#30 2008-01-05 23:22:21

Heybrian
Scratcher
Registered: 2007-12-05
Posts: 100+

Re: A recieve sensing block

funkymonkey wrote:

Heybrian wrote:

funkymonkey wrote:


what is that script working for? once you know that, then you can decide if it will work.

huh?

nevermind. my point is, both of the scripts you pointed out will work

not with big scripts


Black Mesa. go here to get a game 10 times better than SN or FW.  http://scratch.mit.edu/galleries/view/10650
Smiley! copy and paste these into your post or signature!  smile   sad    yikes                 big_smile     wink    tongue    hmm    neutral   cool   lol   mad   roll

Offline

 

#31 2008-01-05 23:23:40

Heybrian
Scratcher
Registered: 2007-12-05
Posts: 100+

Re: A recieve sensing block

funkymonkey wrote:

Heybrian wrote:

Heybrian wrote:


YES!

uh but the message after it and whyed you put that?

is that the kind of block you want?

yes but with a message fafter it.     /i recive "message"\
                                                  \                        /


Black Mesa. go here to get a game 10 times better than SN or FW.  http://scratch.mit.edu/galleries/view/10650
Smiley! copy and paste these into your post or signature!  smile   sad    yikes                 big_smile     wink    tongue    hmm    neutral   cool   lol   mad   roll

Offline

 

#32 2008-01-06 09:27:41

funkymonkey
Scratcher
Registered: 2007-06-03
Posts: 1000+

Re: A recieve sensing block

Heybrian wrote:

funkymonkey wrote:

Heybrian wrote:


huh?

nevermind. my point is, both of the scripts you pointed out will work

not with big scripts

so have it with a lot of small scripts. it will still work the same way, only maybe a little slower.


http://i243.photobucket.com/albums/ff67/hprules_photos/banner2.jpg
Kuzimu: Dawn of a New Age                                                                                                  Coming May 2010

Offline

 

#33 2008-01-06 09:29:59

funkymonkey
Scratcher
Registered: 2007-06-03
Posts: 1000+

Re: A recieve sensing block

Heybrian wrote:

funkymonkey wrote:

Heybrian wrote:

uh but the message after it and whyed you put that?

is that the kind of block you want?

yes but with a message fafter it.     /i recive "message"\
                                                  \                        /

oh ya.... i forgot that. i'll add it


http://i243.photobucket.com/albums/ff67/hprules_photos/banner2.jpg
Kuzimu: Dawn of a New Age                                                                                                  Coming May 2010

Offline

 

#34 2008-01-06 11:35:52

funkymonkey
Scratcher
Registered: 2007-06-03
Posts: 1000+

Re: A recieve sensing block

Heybrian wrote:

yes but with a message fafter it.     /i recive "message"\
                                                  \                        /

like this?
http://i243.photobucket.com/albums/ff67/hprules_photos/irecieve.jpg


http://i243.photobucket.com/albums/ff67/hprules_photos/banner2.jpg
Kuzimu: Dawn of a New Age                                                                                                  Coming May 2010

Offline

 

#35 2008-01-06 13:09:43

Heybrian
Scratcher
Registered: 2007-12-05
Posts: 100+

Re: A recieve sensing block

funkymonkey wrote:

Heybrian wrote:

funkymonkey wrote:


nevermind. my point is, both of the scripts you pointed out will work

not with big scripts

so have it with a lot of small scripts. it will still work the same way, only maybe a little slower.

Okay heres something every scratch RPGer hates. one word. LAG! It makes the game so laggy if you have small scripts. My point is,  with this block a bunch of reasons AND you wont have to start more scripts.


Black Mesa. go here to get a game 10 times better than SN or FW.  http://scratch.mit.edu/galleries/view/10650
Smiley! copy and paste these into your post or signature!  smile   sad    yikes                 big_smile     wink    tongue    hmm    neutral   cool   lol   mad   roll

Offline

 

#36 2008-01-06 13:10:50

Heybrian
Scratcher
Registered: 2007-12-05
Posts: 100+

Re: A recieve sensing block

funkymonkey wrote:

Heybrian wrote:

yes but with a message fafter it.     /i recive "message"\
                                                  \                        /

like this?
http://i243.photobucket.com/albums/ff67 … ecieve.jpg

Yes thats perfect.


Black Mesa. go here to get a game 10 times better than SN or FW.  http://scratch.mit.edu/galleries/view/10650
Smiley! copy and paste these into your post or signature!  smile   sad    yikes                 big_smile     wink    tongue    hmm    neutral   cool   lol   mad   roll

Offline

 

#37 2008-01-06 13:12:09

Heybrian
Scratcher
Registered: 2007-12-05
Posts: 100+

Re: A recieve sensing block

funkymonkey wrote:

Heybrian wrote:

yes but with a message fafter it.     /i recive "message"\
                                                  \                        /

like this?
http://i243.photobucket.com/albums/ff67 … ecieve.jpg

But soon after that peaple are going to be complaining about needing broadcast sensing blocks.


Black Mesa. go here to get a game 10 times better than SN or FW.  http://scratch.mit.edu/galleries/view/10650
Smiley! copy and paste these into your post or signature!  smile   sad    yikes                 big_smile     wink    tongue    hmm    neutral   cool   lol   mad   roll

Offline

 

#38 2008-01-06 13:18:03

Heybrian
Scratcher
Registered: 2007-12-05
Posts: 100+

Re: A recieve sensing block

and also if you need to end a script by broadcasting something you cant recive after the scripts going, so the sensing bloc would really help for that.


Black Mesa. go here to get a game 10 times better than SN or FW.  http://scratch.mit.edu/galleries/view/10650
Smiley! copy and paste these into your post or signature!  smile   sad    yikes                 big_smile     wink    tongue    hmm    neutral   cool   lol   mad   roll

Offline

 

#39 2008-01-06 13:42:23

kevin_karplus
Scratcher
Registered: 2007-04-27
Posts: 1000+

Re: A recieve sensing block

Small scripts or big does not make any difference to the speed of scratch.
The number of scripts running at the same time is what is important. Also, how many slow operations (like graphics effects for the whole stage) are done.

Offline

 

#40 2008-01-06 21:48:42

Heybrian
Scratcher
Registered: 2007-12-05
Posts: 100+

Re: A recieve sensing block

funkymonkey wrote:

Heybrian wrote:

funkymonkey wrote:


nevermind. my point is, both of the scripts you pointed out will work

not with big scripts

so have it with a lot of small scripts. it will still work the same way, only maybe a little slower.

very slower


Black Mesa. go here to get a game 10 times better than SN or FW.  http://scratch.mit.edu/galleries/view/10650
Smiley! copy and paste these into your post or signature!  smile   sad    yikes                 big_smile     wink    tongue    hmm    neutral   cool   lol   mad   roll

Offline

 

#41 2008-01-06 21:50:45

Heybrian
Scratcher
Registered: 2007-12-05
Posts: 100+

Re: A recieve sensing block

kevin_karplus wrote:

Small scripts or big does not make any difference to the speed of scratch.
The number of scripts running at the same time is what is important. Also, how many slow operations (like graphics effects for the whole stage) are done.

Tell me about it! i made a project where the cat turns blue but online he tured green! if you dont belive me go to scratch cat adventure 2 and look at it online then downlaod it and look at that. online the cat is green. on scratch (downloaded) he is blue. he is supposed to be blue.


Black Mesa. go here to get a game 10 times better than SN or FW.  http://scratch.mit.edu/galleries/view/10650
Smiley! copy and paste these into your post or signature!  smile   sad    yikes                 big_smile     wink    tongue    hmm    neutral   cool   lol   mad   roll

Offline

 

#42 2008-01-06 23:28:01

EdnaC
Scratcher
Registered: 2007-08-28
Posts: 100+

Re: A recieve sensing block

Heybrian wrote:

[yes but variables sometimes mess up the script if ur doing an rpg game for example, you know when you have like so many number scripts and too many variables, (the ones you already have) it gets kind of glitchey  or buggy. that why things like the next costume trick wont work when you have that. belive me, if anything, scratch needs to be able to hold more data.

You are probably having "glitches" because you have global variables (variables for all sprites) that are being changed by differents scripts.  If a script is waiting for a variable to change, and several other sprites could be running scripts that modify that variable, you will really have a hard time tracking down the "bug".

You should try to limit variables to be "for this sprite only" whenever possible.  The new ability to "sense" the value of another sprite's variables (but not change that sprite's variables) really helps with this.  Keeping variables "for this sprite only" also helps a lot with managing the big list of variables that a large project needs.

When planning a project, it's a good idea to start on paper with a list of the sprites that you'll need, the variables and broadcasts that will do the control, and put some thought into which sprites need to be able to change variables, as opposed to just being able to "know" what the variable's value is.  Having fewer "global" variables will really help you to avoid problems.

-Mr Ed

Offline

 

#43 2008-01-07 17:49:31

funkymonkey
Scratcher
Registered: 2007-06-03
Posts: 1000+

Re: A recieve sensing block

kevin_karplus wrote:

Small scripts or big does not make any difference to the speed of scratch.
The number of scripts running at the same time is what is important. Also, how many slow operations (like graphics effects for the whole stage) are done.

that is very true, but then why did you tell me that

<forever>
<if>
is slower than
<forever if>?

Last edited by funkymonkey (2008-01-07 17:49:46)


http://i243.photobucket.com/albums/ff67/hprules_photos/banner2.jpg
Kuzimu: Dawn of a New Age                                                                                                  Coming May 2010

Offline

 

#44 2008-01-07 17:52:52

funkymonkey
Scratcher
Registered: 2007-06-03
Posts: 1000+

Re: A recieve sensing block

Heybrian wrote:

funkymonkey wrote:

Heybrian wrote:

yes but with a message fafter it.     /i recive "message"\
                                                  \                        /

like this?
http://i243.photobucket.com/albums/ff67/hprules_photos/irecieve.jpg

But soon after that peaple are going to be complaining about needing broadcast sensing blocks.

that would be good too


http://i243.photobucket.com/albums/ff67/hprules_photos/banner2.jpg
Kuzimu: Dawn of a New Age                                                                                                  Coming May 2010

Offline

 

#45 2008-01-07 17:54:13

funkymonkey
Scratcher
Registered: 2007-06-03
Posts: 1000+

Re: A recieve sensing block

Heybrian wrote:

Okay heres something every scratch RPGer hates. one word. LAG! It makes the game so laggy if you have small scripts. My point is,  with this block a bunch of reasons AND you wont have to start more scripts.

i hate lag too. but, small scripts do not affect the speed of a project. Like Kevin said, its the amount of small scripts. anyways, dont long scripts make it laggy? they have so many commands in them that wouldnt it be harder to read for Scratch?


http://i243.photobucket.com/albums/ff67/hprules_photos/banner2.jpg
Kuzimu: Dawn of a New Age                                                                                                  Coming May 2010

Offline

 

#46 2008-01-07 20:23:33

Heybrian
Scratcher
Registered: 2007-12-05
Posts: 100+

Re: A recieve sensing block

EdnaC wrote:

Heybrian wrote:

[yes but variables sometimes mess up the script if ur doing an rpg game for example, you know when you have like so many number scripts and too many variables, (the ones you already have) it gets kind of glitchey  or buggy. that why things like the next costume trick wont work when you have that. belive me, if anything, scratch needs to be able to hold more data.

You are probably having "glitches" because you have global variables (variables for all sprites) that are being changed by differents scripts.  If a script is waiting for a variable to change, and several other sprites could be running scripts that modify that variable, you will really have a hard time tracking down the "bug".

You should try to limit variables to be "for this sprite only" whenever possible.  The new ability to "sense" the value of another sprite's variables (but not change that sprite's variables) really helps with this.  Keeping variables "for this sprite only" also helps a lot with managing the big list of variables that a large project needs.

When planning a project, it's a good idea to start on paper with a list of the sprites that you'll need, the variables and broadcasts that will do the control, and put some thought into which sprites need to be able to change variables, as opposed to just being able to "know" what the variable's value is.  Having fewer "global" variables will really help you to avoid problems.

-Mr Ed

ohhhhhhhh. i always used global variables just in case id need them for everybody. ok i'll try that


Black Mesa. go here to get a game 10 times better than SN or FW.  http://scratch.mit.edu/galleries/view/10650
Smiley! copy and paste these into your post or signature!  smile   sad    yikes                 big_smile     wink    tongue    hmm    neutral   cool   lol   mad   roll

Offline

 

#47 2008-01-07 20:24:46

Heybrian
Scratcher
Registered: 2007-12-05
Posts: 100+

Re: A recieve sensing block

funkymonkey wrote:

kevin_karplus wrote:

Small scripts or big does not make any difference to the speed of scratch.
The number of scripts running at the same time is what is important. Also, how many slow operations (like graphics effects for the whole stage) are done.

that is very true, but then why did you tell me that

<forever>
<if>
is slower than
<forever if>?

i dont get your post at ALL.  =P


Black Mesa. go here to get a game 10 times better than SN or FW.  http://scratch.mit.edu/galleries/view/10650
Smiley! copy and paste these into your post or signature!  smile   sad    yikes                 big_smile     wink    tongue    hmm    neutral   cool   lol   mad   roll

Offline

 

#48 2008-01-07 20:25:51

Heybrian
Scratcher
Registered: 2007-12-05
Posts: 100+

Re: A recieve sensing block

funkymonkey wrote:

Heybrian wrote:

Okay heres something every scratch RPGer hates. one word. LAG! It makes the game so laggy if you have small scripts. My point is,  with this block a bunch of reasons AND you wont have to start more scripts.

i hate lag too. but, small scripts do not affect the speed of a project. Like Kevin said, its the amount of small scripts. anyways, dont long scripts make it laggy? they have so many commands in them that wouldnt it be harder to read for Scratch?

thats exactly what i said. long scripts are ussaly fine in scratch (downloaded) but only sometimes, and are even worse online


Black Mesa. go here to get a game 10 times better than SN or FW.  http://scratch.mit.edu/galleries/view/10650
Smiley! copy and paste these into your post or signature!  smile   sad    yikes                 big_smile     wink    tongue    hmm    neutral   cool   lol   mad   roll

Offline

 

#49 2008-01-07 20:27:17

Heybrian
Scratcher
Registered: 2007-12-05
Posts: 100+

Re: A recieve sensing block

but still, since your a forum moderator (kevin) do you have any contact with the creators and updaters of scratch? because if you do, tell them to look at this thread

Last edited by Heybrian (2008-01-07 20:27:40)


Black Mesa. go here to get a game 10 times better than SN or FW.  http://scratch.mit.edu/galleries/view/10650
Smiley! copy and paste these into your post or signature!  smile   sad    yikes                 big_smile     wink    tongue    hmm    neutral   cool   lol   mad   roll

Offline

 

#50 2008-01-07 21:34:08

funkymonkey
Scratcher
Registered: 2007-06-03
Posts: 1000+

Re: A recieve sensing block

Heybrian wrote:

ohhhhhhhh. i always used global variables just in case id need them for everybody. ok i'll try that

lol, me too. i never thought it would make a difference


http://i243.photobucket.com/albums/ff67/hprules_photos/banner2.jpg
Kuzimu: Dawn of a New Age                                                                                                  Coming May 2010

Offline

 

Board footer