sparks wrote:
That's pretty cool Sci, We haven't actually decided on what competition we're doing or what the guidelines are yet, I also don't think it's fair for any librarians to enter whatever competition we do have either because if one of them is chosen it could look like favouritism
Could you take me off the list for just that day then re add me then? JK LOL XD
Offline
ProgrammingFreak wrote:
sparks wrote:
We're not sure. Some sort of competition to celebrate a year of the library. A project is a nice idea because it might draw in new users whilst a special library header is always fun and we've done it before!
Hmm, maybe like Scratch and Google. A season thing.
But you could also have a block contest. Maybe harder for newer people.
The block idea would be hard... because most blocks anyone could think of are already in the library!!! I keep trying to think of one making it and then i see it is shared already. If the library workers aren't allowed to enter, maybe we could have a contest for them! (just a thought)
Offline
scimonster wrote:
Pecola1 wrote:
scimonster wrote:
TuragaTreeko wrote:
Would %(number), %(shift value), or %(alt value) work for new dropdowns? Like, %ø, %9, or %@?
Hmm, I wonder! I'll try that out later, when I'm back on my own comp.
Yeah, title competition! Do something with 1 year anniversary. I might upload one in a project because I can't upload images to hosting sites.IDK, I know ' would ALMOST work, but the blockspec didn't allow it.
('%1' #- #thing:) showed as http://theblocklibrary.site11.com/inclu … or=control
Numbers don
't work. That's why i tried some characters, I think ` did work and maybe ~ did too... can't remember.
Offline
sparks wrote:
@SSBBM, What's wrong with the Scratch fora? Well by using a seperate page we can vote anonymously and also people won't know who made the image they voted for, meaning that personal feelings towards other Scratchers will not sway your vote!
Could you make it so a user cannot vote for their own?
Offline
Pecola1 wrote:
scimonster wrote:
Pecola1 wrote:
IDK, I know ' would ALMOST work, but the blockspec didn't allow it.
('%1' #- #thing:) showed as http://theblocklibrary.site11.com/inclu … or=control
Numbers don
't work. That's why i tried some characters, I think ` did work and maybe ~ did too... can't remember.
Mhm. Seems like my "brilliant" idea was an EPIC fail. Why do you think it won't allow %(not a letter)s? Maybe it takes some edits in the Translators. Hm. I think I'll go try that.
EDIT: Aaah... it's all REALLY technical. I can't make head or tail of it. I went to Primitives-C Translators, and I also tried Scratch-Translation. I just can't understand any of it.
Last edited by TuragaTreeko (2011-06-28 12:58:13)
Offline
Well now that the images for the competition could be shared anonymously we have removed any favouritism from the voting process, Librarians are welcome to enter. We COULD make it so that users cannot vote on their own project but that means users would have to enter their username and password to vote which may deter people, we could do IP based hosting, I'm not sure.
Offline
jslomba wrote:
hey, is anyone gonna do that update?!
Oh, yeah, after I finish this project I'm almost done with...
Last edited by scimonster (2011-06-29 08:52:02)
Offline
I made another new block! (Note: Did you guys even see the last one? I think I've got a lot more coming...)
Blockspec:
('factorial of %n' #r #Factorial:)
Code:
Factorial: t1 | answer t1store | answer _ 1. t1store _ t1. t1 = 0 ifTrue: [^ 1]. t1 < 0 ifTrue: [^ 0]. t1 isInf ifTrue: [^ 0]. t1 isNaN ifTrue: [^ 0]. [t1store > 1] whileTrue: [answer _ answer * t1store. t1store _ t1store - 1]. ^ answer
Works best if you go to Scratch Blocks > CommandBlockMorph > all > canBecomeWatcher and add #Factorial: to the list of reporters.
Last edited by Greenatic (2011-06-29 11:39:27)
Offline
I have a block. This is a good block to use for an answer/ask game, and they give the wrong answer.
('error!' #r #getError)
getError
^Error!
Offline
TuragaTreeko wrote:
I have a block. This is a good block to use for an answer/ask game, and they give the wrong answer.
('error!' #r #getError)
getError
^Error!
Actually, it should report
^ self error
Offline
I've got a question for the librarians:
I was getting ready to make << () is infinite?>> and << () is NaN?>> blocks, but it occured to me that these would be used for very similar purposes. Would you prefer that I instead make a << () is infinite or NaN?>> block?
Last edited by Greenatic (2011-06-29 14:38:41)
Offline
scimonster wrote:
TuragaTreeko wrote:
I have a block. This is a good block to use for an answer/ask game, and they give the wrong answer.
('error!' #r #getError)
getError
^Error!Actually, it should report
^ self error
um... it seems to work for me. It reports error, so... ?
Offline
Could someone reply to my question? Please?
Anyway, my third new block:
Blockspec:
('%n is an integer?' #b #IsInteger:)
Code (there may have been an easier way, but I did it my way):
IsInteger: t1 | t1pos | t1 isInf ifTrue: [^ false]. t1 isNaN ifTrue: [^ false]. t1pos _ t1 abs. [t1pos > 0] whileTrue: [t1pos _ t1pos - 1]. t1pos = 0 ifTrue: [^ true]. t1pos = 0 ifFalse: [^ false]
Does anyone have anything to say about any of the blocks?
Offline
Greenatic wrote:
Could someone reply to my question? Please?
Anyway, my third new block:
http://polyeztahpuppies.webs.com/isinteger.gif
Blockspec:Code:
('%n is an integer?' #b #IsInteger:)Code (there may have been an easier way, but I did it my way):
Code:
IsInteger: t1 | t1pos | t1 isInf ifTrue: [^ false]. t1 isNaN ifTrue: [^ false]. t1pos _ t1 abs. [t1pos > 0] whileTrue: [t1pos _ t1pos - 1]. t1pos = 0 ifTrue: [^ true]. t1pos = 0 ifFalse: [^ false]Does anyone have anything to say about any of the blocks?
Wouldn't it be easier to just do this?
isInteger: t1
^ t1 = t1 rounded
Offline
scimonster wrote:
Greenatic wrote:
Could someone reply to my question? Please?
Anyway, my third new block:
http://polyeztahpuppies.webs.com/isinteger.gif
Blockspec:Code:
('%n is an integer?' #b #IsInteger:)Code (there may have been an easier way, but I did it my way):
Code:
IsInteger: t1 | t1pos | t1 isInf ifTrue: [^ false]. t1 isNaN ifTrue: [^ false]. t1pos _ t1 abs. [t1pos > 0] whileTrue: [t1pos _ t1pos - 1]. t1pos = 0 ifTrue: [^ true]. t1pos = 0 ifFalse: [^ false]Does anyone have anything to say about any of the blocks?
Wouldn't it be easier to just do this?
isInteger: t1
^ t1 = t1 rounded
I knew there was an easier way
I didn't try something like that because I know Scratch's rounding block sometimes glitches, and I didn't know if it used a script like that. Does it? I used my method because I knew it would work reliably.
Offline
And another one!!!!
Blockspec:
('%n is a Fibonacci number?' #b #IsFibonacci:)
Code: (it's super long, I know)
IsFibonacci: t1 | fib1 fib2 oldfib2 fib3 oldfib3 | t1 isInf ifTrue:[^false]. t1 isNaN ifTrue:[^false]. t1 < 0 ifTrue: [^ false]. t1 = 0 ifTrue: [^ true]. t1 = 1 ifTrue: [^ true]. fib1 _ 0. fib2 _ 1. oldfib2 _ fib2. fib3 _ fib1 + fib2. oldfib3 _ fib3. [t1 > fib3] whileTrue: [fib3 _ fib1 + fib2. fib2 _ oldfib3. fib1 _ oldfib2. oldfib3 _ fib3. oldfib2 _ fib2]. t1 = fib3 ifTrue: [^ true]. t1 = fib3 ifFalse: [^ false]
For best results, go to Scratch Blocks > CommandBlockMorph > private > canBecomeWatcher and add #IsFibonacci: to the list.
EDIT: Added code to prevent infinite or NaN values.
Last edited by Greenatic (2011-06-29 17:14:42)
Offline
spiral projects here we come!
Offline
Another one!!!!
Note: This contains code similar to my block. If that one is changed, this one should be changed as well.
Blockspec:
('%n is prime?' #b #IsPrime:)
Code: (brace yourself! )
IsPrime: t1 | divisor factor t1store | t1 isInf ifTrue: [^ false]. t1 isNaN ifTrue: [^ false]. t1 < 1 ifTrue: [^ false]. t1 = 1 ifTrue: [^ false]. t1store _ t1. [t1store > 0] whileTrue: [t1store _ t1store - 1]. t1store = 0 ifFalse: [^ false]. divisor _ 2. [divisor > (0.5 * t1)] whileFalse: [factor _ t1 / divisor. [factor > 0] whileTrue: [factor _ factor - 1]. factor = 0 ifTrue: [^ false]. divisor _ divisor + 1]. ^ true
Yeah, I've made a lot of blocks today.
Last edited by Greenatic (2011-07-20 14:31:42)
Offline
Greenatic wrote:
I've got a question for the librarians:
I was getting ready to make << () is infinite?>> and << () is NaN?>> blocks, but it occured to me that these would be used for very similar purposes. Would you prefer that I instead make a << () is infinite or NaN?>> block?
Any opinions?
Offline
jslomba wrote:
scimonster wrote:
jslomba wrote:
hey, is anyone gonna do that update?!
Oh, yeah, after I finish this project I'm almost done with...
you done yet?
Yeah, but I didn't have time to do an update. I'll try it soon.
Offline
Scramble 2.0 is out, and it needs a library. Any tips on making a library?
Thanks
Offline
Hardmath123 wrote:
Scramble 2.0 is out, and it needs a library. Any tips on making a library?
Thanks
Well, I see you set up 6 posts, and so I would recommend, because there aren't enough posts by section:
1) Home
2) Stacks
3) Reporters
4) Booleans
5) FAQ
6) About Scramble
Offline