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

#1 2011-11-26 12:07:02

iTweak0r
Scratcher
Registered: 2011-07-30
Posts: 100+

Asking and answering

This is NOT  the ask and wait block.

So I want a block like (ask for [dropdown \/] with [] [] < >)

And two blocks like {When [dropdown \/] asked Params: () () < >}
And [answer []]

{} = hat block
() = reporter block
[] = command block

The Params thing in when asked are reporters that you can drag from the hat, like byob.
The < > thing can add and remove spaces.
Answer [] "throws" back a value so it reports something.

Edit: this is like defs and returns and parameters in python

Last edited by iTweak0r (2011-11-29 11:09:42)


Make it in Scratch! because it's cooler when it's made in scratch
http://i.imgur.com/D4iqPHR.png

Offline

 

#2 2011-11-26 17:45:54

iTweak0r
Scratcher
Registered: 2011-07-30
Posts: 100+

Re: Asking and answering

Bump


Make it in Scratch! because it's cooler when it's made in scratch
http://i.imgur.com/D4iqPHR.png

Offline

 

#3 2011-11-26 17:50:05

christian2000
Scratcher
Registered: 2010-11-01
Posts: 100+

Re: Asking and answering

soo... like [brodcast script with () and/or () brodcasting with 'dropdown' ] ?


blerp......
http://obscureinternet.com/wp-content/uploads/Fail-at-Life-Funny-Cards.png

Offline

 

#4 2011-11-26 19:41:48

iTweak0r
Scratcher
Registered: 2011-07-30
Posts: 100+

Re: Asking and answering

christian2000 wrote:

soo... like [brodcast script with () and/or () brodcasting with 'dropdown' ] ?

No ask [] with [] [] <> is a reporter.

Like reporter broadcasts with parameters


Make it in Scratch! because it's cooler when it's made in scratch
http://i.imgur.com/D4iqPHR.png

Offline

 

#5 2011-11-27 11:50:05

christian2000
Scratcher
Registered: 2010-11-01
Posts: 100+

Re: Asking and answering

ok i get it now!


blerp......
http://obscureinternet.com/wp-content/uploads/Fail-at-Life-Funny-Cards.png

Offline

 

#6 2011-11-27 13:14:39

iTweak0r
Scratcher
Registered: 2011-07-30
Posts: 100+

Re: Asking and answering

oh i just found out that this was in a VERY early version of scratch.

but still i want it in 2.0!  smile


Make it in Scratch! because it's cooler when it's made in scratch
http://i.imgur.com/D4iqPHR.png

Offline

 

#7 2011-11-28 17:28:15

Greenatic
Scratcher
Registered: 2009-05-03
Posts: 1000+

Re: Asking and answering

Do you edit Scratch source code?  This sounds a lot like a CustomMenu...

I think it would be a better idea for the Params area to be a list dropdown, because I doubt the ST will make the little < > buttons that BYOB blocks such as (the list [] [] < > ) have.

Last edited by Greenatic (2011-11-28 17:28:51)

Offline

 

#8 2011-11-30 09:02:36

joefarebrother
Scratcher
Registered: 2011-04-08
Posts: 1000+

Re: Asking and answering

this IS possible, if you have a variable for each paramater in a sprite with scripts for each function, and also a global variable called return for returning stuff, like this:
{when i receive [something v}
if <something>
{
  (do something)
  set [return v] to (something)
  stop script
}
(do something else)
set [return v] to (something else)


My latest project is called http://tinyurl.com/d2m8hne! It has http://tinyurl.com/d395ygk views, http://tinyurl.com/cnasmt7 love-its, and http://tinyurl.com/bwjy8xs comments.
http://tinyurl.com/756anbk   http://tinyurl.com/iplaychess

Offline

 

#9 2011-11-30 10:57:20

iTweak0r
Scratcher
Registered: 2011-07-30
Posts: 100+

Re: Asking and answering

joefarebrother wrote:

this IS possible, if you have a variable for each paramater in a sprite with scripts for each function, and also a global variable called return for returning stuff, like this:
{when i receive [something v}
if <something>
{
  (do something)
  set [return v] to (something)
  stop script
}
(do something else)
set [return v] to (something else)

Ya but this would make that easier.


Make it in Scratch! because it's cooler when it's made in scratch
http://i.imgur.com/D4iqPHR.png

Offline

 

#10 2011-12-01 11:01:28

iTweak0r
Scratcher
Registered: 2011-07-30
Posts: 100+

Re: Asking and answering

bump


Make it in Scratch! because it's cooler when it's made in scratch
http://i.imgur.com/D4iqPHR.png

Offline

 

Board footer