zorket wrote:
kinker wrote:
The hide list block
_____________________________________________________
block spec:Code:
('hide list %L' #- #hideList: 'list')no code
And there u have it!That didn't work for me.
I was gonna give the method but my dad got rid of Zatch UPDATE I now have Zatch back!
Last edited by kinker (2010-10-30 10:04:59)
Offline
I'm 85% an an expert on blocks. There are just a lot of blocks I have, and i'm wondering how to get it. This would be in the operators category.
Probably unfinished blockspec:
('%n percent chance of: else:' #c #chance:else)
And no code. I'll let you know if I find a connection with blocks though!
Offline
zorket wrote:
I'm 85% an an expert on blocks. There are just a lot of blocks I have, and i'm wondering how to get it. This would be in the operators category.
Probably unfinished blockspec:
('%n percent chance of: else:' #c #chance:else)And no code. I'll let you know if I find a connection with blocks though!
that block can be avoided with a few more steps in simple scratch
[blocks]
<if> <( <pick random( 0 )to( 100 <>> 100 - whatever percent here )>
<else>
<end>
[/blocks]
hope it helps!
Offline
LS97 wrote:
zorket wrote:
I'm 85% an an expert on blocks. There are just a lot of blocks I have, and i'm wondering how to get it. This would be in the operators category.
Probably unfinished blockspec:
('%n percent chance of: else:' #c #chance:else)And no code. I'll let you know if I find a connection with blocks though!
that block can be avoided with a few more steps in simple scratch
[blocks]
<if> <( <pick random( 0 )to( 100 <>> 100 - whatever percent here )>
<else>
<end>
[/blocks]
hope it helps!
That script should still help find the code.
Offline
bbbeb wrote:
Actually, there are only 37,564,234,323,234,754,567,467,356 digits of pi before it repeats. Amazing!
you're serious? they got Pi to repeat?!?!?!?
celebration...!...!...!...!...!...!...!...!
/random
Offline
^ Can you give a link backing it up?
Offline
johnnydean1 wrote:
^ Can you give a link backing it up?
yeah wanted to ask that. i'll check on wikipedia right now. it's better than nothing...
edit wikipedia still states that Pi is irrational
Last edited by LS97 (2010-10-25 11:18:02)
Offline
kinker wrote:
zorket wrote:
kinker wrote:
The hide list block
_____________________________________________________
block spec:Code:
('hide list %L' #- #hideList: 'list')no code
And there u have it!That didn't work for me.
I was gonna give the method but my dad got rid of Zatch UPDATE I now have Zatch back!
code:
hideList: t1 | t2 | self showOrHideList: t1 show: false. t2 _ self ownerThatIsA: ScratchStageMorph. t2 ~= self ifTrue: [t2 showOrHideList: t1 show: false]
Offline
LS97 wrote:
Aidan wrote:
I have another problem. How do I 'save' the changes?
that's something i didnt include in my tutorial, thanks for reminding me!
Shift-click the R again, and click 'save image for end-user'. then click yes.
I did this and Scratch froze on me. I could quit it the regular way, so a had to force quit it. After I tried again, the exact same thing happened.
Offline
bdn7 wrote:
LS97 wrote:
Aidan wrote:
I have another problem. How do I 'save' the changes?
that's something i didnt include in my tutorial, thanks for reminding me!
Shift-click the R again, and click 'save image for end-user'. then click yes.I did this and Scratch froze on me. I could quit it the regular way, so a had to force quit it. After I tried again, the exact same thing happened.
why did not use tarsk manager on windows or what ever thig on a mac to close it
Offline
I would like a (random dog command) block. I have it mostly down, but doesn't work.
Blockspec:
'dog command' #r #chooseOfAndReportDogCommand
chooseOfAndReportDogCommand | t1 | t1 _ random 1 - 6. t1 = 1 ifTrue: [^ 'sit.']. t1 = 2 ifTrue: [^ 'lay down.']. t1 = 3 ifTrue: [^ 'roll over.']. t1 = 4 ifTrue: [^ 'shake.']. t1 = 5 ifTrue: [^ 'dance.']. t1 = 6 ifTrue: [^ 'play dead.'].
Problem: How do I fix the random part?
Last edited by zorket (2010-10-30 18:14:42)
Offline
Maybe we can make a revised <if on edge, bounce> block with <touching[ ]> or <touching color[ ]>.
Then the result would be <if touching (color, edge or sprite), bounce>.
Last edited by Marioblender (2010-10-30 19:21:12)
Offline
kinker wrote:
code:
Code:
hideList: t1 | t2 | self showOrHideList: t1 show: false. t2 _ self ownerThatIsA: ScratchStageMorph. t2 ~= self ifTrue: [t2 showOrHideList: t1 show: false]
i dont think that's the appropriate code, you missed one bit. (you obviously took all of the code from nXIII and didnt even look at it... )
Offline
zorket wrote:
I would like a (random dog command) block. I have it mostly down, but doesn't work.
Blockspec:'dog command' #r #chooseOfAndReportDogCommand
Code:
chooseOfAndReportDogCommand | t1 | t1 _ random 1 - 6. t1 = 1 ifTrue: [^ 'sit.']. t1 = 2 ifTrue: [^ 'lay down.']. t1 = 3 ifTrue: [^ 'roll over.']. t1 = 4 ifTrue: [^ 'shake.']. t1 = 5 ifTrue: [^ 'dance.']. t1 = 6 ifTrue: [^ 'play dead.'].Problem: How do I fix the random part?
self randomFrom: 1 to: 6, I think but I haven't got Scratch open so I can't be sure.
Offline
TheSuccessor wrote:
zorket wrote:
I would like a (random dog command) block. I have it mostly down, but doesn't work.
Blockspec:'dog command' #r #chooseOfAndReportDogCommand
Code:
chooseOfAndReportDogCommand | t1 | t1 _ random 1 - 6. t1 = 1 ifTrue: [^ 'sit.']. t1 = 2 ifTrue: [^ 'lay down.']. t1 = 3 ifTrue: [^ 'roll over.']. t1 = 4 ifTrue: [^ 'shake.']. t1 = 5 ifTrue: [^ 'dance.']. t1 = 6 ifTrue: [^ 'play dead.'].Problem: How do I fix the random part?
self randomFrom: 1 to: 6, I think but I haven't got Scratch open so I can't be sure.
We can gain more codes by opening squeak. In the pick random code where I just checked, contains something else.
Offline