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

#1 2012-07-02 23:37:16

DonutCannon
New Scratcher
Registered: 2012-07-02
Posts: 29

Join Block Chains

I was wondering if it's possible to make a chain of Join Blocks based off of the length of a word (for example, the length of ___ block.)

Offline

 

#2 2012-07-02 23:58:41

berberberber
Scratcher
Registered: 2012-03-08
Posts: 1000+

Re: Join Block Chains

Hmm... what do you mean?


http://i47.tinypic.com/2iaa73k.png

Offline

 

#3 2012-07-03 00:04:28

AtomicBawm3
Scratcher
Registered: 2009-06-27
Posts: 1000+

Re: Join Block Chains

Yes, you could.  But you need to do it with a repeat loop.


http://i50.tinypic.com/j0yw0p.jpg

Offline

 

#4 2012-07-06 08:22:41

sonicgames20
Scratcher
Registered: 2012-06-13
Posts: 100+

Re: Join Block Chains

ask [what's your name]?
say<join (join (join (join [Hello] (answer)) [My name is]) {Person's name}) [.]>


if there is no I in TEAM and there  is no U in TEAM then who's on the team?
I am-http://blocks.scratchr.org/API.php?user=sonicgames20&amp;action=onlineStatus&amp;type=square-green=online grey=offline

Offline

 

#5 2012-07-06 08:25:08

jontmy00
Scratcher
Registered: 2011-11-28
Posts: 1000+

Re: Join Block Chains

sonicgames20 wrote:

ask [What's your name?] and wait
say<join (join (join (join [Hello](answer)) [My name is]) (Person's name)) [.]>

Scripts fixed.


FOR ALL THE NEWS ON UPDATES FOR SIMPLISTICRAFT, CLICK HERE.

Offline

 

#6 2012-07-06 13:18:48

fg123
Scratcher
Registered: 2008-11-13
Posts: 1000+

Re: Join Block Chains

DonutCannon wrote:

I was wondering if it's possible to make a chain of Join Blocks based off of the length of a word (for example, the length of ___ block.)

I see what you mean. You can use lists for this:

when gf clicked
ask [What's your name?] and wait //however you get the value
set [length v] to (length of (answer))
delete (all  v) of [temp v]
repeat (length)
add [thing] to [temp v] //whatever you want to say in the join blocks
end
say (temp) //this is the list, but wrong color

Last edited by fg123 (2012-07-06 13:19:41)


Hai.

Offline

 

Board footer