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

#4226 2011-12-05 00:05:53

shadow_7283
Scratcher
Registered: 2007-11-07
Posts: 1000+

Re: BYOB 3 - Discussion Thread

bharvey wrote:

Alternatively we could GPL it and then license exceptions for commercial projects that send Jens some percent of the money.  smile

If it worked, I'd love to!  big_smile

I really don't want to be the greedy, selfish kid, that's hungry for money. On the other hand, a teenager has to pay college tuition (and fund various frivilous technological ventures) somehow.  tongue

By the way, your pamphlet (for want of a better word) looks great!

Last edited by shadow_7283 (2011-12-05 00:11:35)

Offline

 

#4227 2011-12-05 00:06:42

jji7skyline
Scratcher
Registered: 2010-03-08
Posts: 1000+

Re: BYOB 3 - Discussion Thread

So, green flag and stop all has been taken out of byob 4?


I don't know why you say goodbye, I say hello!  big_smile

Offline

 

#4228 2011-12-05 00:12:38

shadow_7283
Scratcher
Registered: 2007-11-07
Posts: 1000+

Re: BYOB 3 - Discussion Thread

jji7skyline wrote:

So, green flag and stop all has been taken out of byob 4?

Nope!  smile  They have yet to be implemented, that's all.

Offline

 

#4229 2011-12-05 00:19:25

jji7skyline
Scratcher
Registered: 2010-03-08
Posts: 1000+

Re: BYOB 3 - Discussion Thread

shadow_7283 wrote:

jji7skyline wrote:

So, green flag and stop all has been taken out of byob 4?

Nope!  smile  They have yet to be implemented, that's all.

kay!  smile


I don't know why you say goodbye, I say hello!  big_smile

Offline

 

#4230 2011-12-05 07:48:58

roijac
Scratcher
Registered: 2010-01-19
Posts: 1000+

Re: BYOB 3 - Discussion Thread

hey, bharvey, why don't you actually replace (() in front of ()) with (merge()and()), and (all but first of()) with (items () to () of ())?
it can do the same, but also much more!
also celebrating the mouse positions  smile
http://i.imgur.com/8zcpd.png
try this
this is cool  smile

Offline

 

#4231 2011-12-05 10:53:08

bharvey
Scratcher
Registered: 2008-08-10
Posts: 1000+

Re: BYOB 3 - Discussion Thread

shadow_7283 wrote:

On the other hand, a teenager has to pay college tuition (and fund various frivilous technological ventures) somehow.

OK, you're a friend, give it a try.  But it looks like you'll have to be the one to do the Box2D integration -- I don't hear anyone else leaping at the prospect.  Maybe it'd be easier to walk dogs.  smile

By the way, your pamphlet (for want of a better word) looks great!

Thanks!


http://cs.berkeley.edu/~bh/sig5.png

Offline

 

#4232 2011-12-05 10:59:37

bharvey
Scratcher
Registered: 2008-08-10
Posts: 1000+

Re: BYOB 3 - Discussion Thread

roijac wrote:

hey, bharvey, why don't you actually replace (() in front of ()) with (merge()and()), and (all but first of()) with (items () to () of ())?
it can do the same, but also much more!

I agree that those are useful tools.  But they're straightforward to build with what you have already, and the reason to make adding or taking away one element from the head of the list is that those operations run in constant time on a linked list.

The BYOB3 toolkit has APPEND (what you called MERGE). I didn't write a general sublist block because I think it's unusual to take sublists other than the butfirst (or the butlast, but that's more costly for linked lists).  But you can easily write one recursively if you need it.

PS: Nice script!  Glad you like mouse position.

PPS: It took me a long time to get the joke in your sig because my browser is set to white-on-black display.  smile

Last edited by bharvey (2011-12-05 11:01:24)


http://cs.berkeley.edu/~bh/sig5.png

Offline

 

#4233 2011-12-05 11:36:28

Jens
Scratcher
Registered: 2007-06-04
Posts: 1000+

Re: BYOB 3 - Discussion Thread

@ roijac

bharvey wrote:

It took me a long time to get the joke in your sig because my browser is set to white-on-black display.  smile

OMG, now I'm seeing it, too. Yes, that's original for sure  smile


Jens Mönig

Offline

 

#4234 2011-12-05 11:41:39

roijac
Scratcher
Registered: 2010-01-19
Posts: 1000+

Re: BYOB 3 - Discussion Thread

bharvey wrote:

I agree that those are useful tools.  But they're straightforward to build with what you have already, and the reason to make adding or taking away one element from the head of the list is that those operations run in constant time on a linked list.

The BYOB3 toolkit has APPEND (what you called MERGE). I didn't write a general sublist block because I think it's unusual to take sublists other than the butfirst (or the butlast, but that's more costly for linked lists).  But you can easily write one recursively if you need it.

actually the reason behind suggesting that is to improve speed: they are so common that it would really reduce speed in longer algorithms, where you sometimes really need them  smile

(example: you want to make a quasi-fibonacci sequence, where you add the n last elements etc.)

Offline

 

#4235 2011-12-05 14:08:51

bharvey
Scratcher
Registered: 2008-08-10
Posts: 1000+

Re: BYOB 3 - Discussion Thread

roijac wrote:

actually the reason behind suggesting that is to improve speed: they are so common that it would really reduce speed in longer algorithms, where you sometimes really need them

You're wrong about the speed issue, but don't feel bad; it took me a long time to convince Jens, too.  smile

You're thinking (we teachers don't actually have eyes in the back of our heads; we're just telepathic  smile ) that making something a primitive block makes it faster than writing it as a script.  And that's true, of course, but it's true only by a constant factor.

In BYOB it's a huge constant factor, which is why having a COPY OF (list) primitive block made sense.  In Snap! it'll be much smaller.  But, let's say it's a factor of 100 speed difference between a Snap! script and raw JS.

For small list lengths, up to 30 or so, that constant factor will be the most visible influence on overall program speed.  But for small lists, your program will be fast enough no matter what.  If the primitive version takes less than a second, then (by hypothesis) the Snap! script will take less than 100 seconds, i.e., less than two minutes.  And a second is a really long time for a computer; in most cases it'll be more like milliseconds vs. deciseconds.

But for larger lists, over 100 or so, the critical factor in program speed is the order of growth of running time as a function of size.  And no matter how you implement it, appending or subsetting lists requires linear time -- if you double the size, you double the running time.  By contrast, for linked lists, the IN FRONT OF (cons) and ALL BUT FIRST OF (cdr) operations are constant time, independent of the length of the list.

Try writing the mergesort example I gave earlier by recopying lists, and you'll see what I mean.

Yes, we could have our cake and eat it too by providing the primitives you want in addition to the ones I want.  But yours can be implemented straightforwardly in terms of mine, and as usual our policy is to put only the bare minimum in the primitive set, writing the other useful things as custom tool blocks.

We definitely also want to work on constant factors.  At some time, maybe not in 4.0, we're going to replace the interpreter with a compiler that compiles into JS, and that will dramatically improve speed, I hope.

Last edited by bharvey (2011-12-05 14:26:42)


http://cs.berkeley.edu/~bh/sig5.png

Offline

 

#4236 2011-12-05 14:22:53

MathWizz
Scratcher
Registered: 2009-08-31
Posts: 1000+

Re: BYOB 3 - Discussion Thread

bharvey wrote:

We're going to replace the interpreter with a compiler that compiles into JS.

big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile   big_smile


http://block.site90.net/scratch.mit/text.php?size=30&text=%20A%20signature!&color=333333

Offline

 

#4237 2011-12-05 14:59:55

xly
Scratcher
Registered: 2010-04-17
Posts: 100+

Re: BYOB 3 - Discussion Thread

No comment !
http://www.xleroy.net/ByobTuto/New/Snap!/xmastree.gif

Offline

 

#4238 2011-12-05 15:09:14

14God
Scratcher
Registered: 2008-11-14
Posts: 100+

Re: BYOB 3 - Discussion Thread

Why does it still say "pre alpha"? Its good enough to be alpha  big_smile


http://cs.berkeley.edu/~bh/sig4.png
Logic and reason have led me to atheism... but I'm stuck with the name  tongue

Offline

 

#4239 2011-12-05 16:49:12

xly
Scratcher
Registered: 2010-04-17
Posts: 100+

Re: BYOB 3 - Discussion Thread

The aim is to entirely convert Byob 3.1 to Snap!
And even basic functions like Save/Load are not yet implemented !
There is still a "long way to Alpha"

Offline

 

#4240 2011-12-05 18:38:48

bharvey
Scratcher
Registered: 2008-08-10
Posts: 1000+

Re: BYOB 3 - Discussion Thread

xly wrote:

The aim is to entirely convert Byob 3.1 to Snap!
And even basic functions like Save/Load are not yet implemented !
There is still a "long way to Alpha"

Yes, exactly.  Plus multiple sprites, costumes,...

Alpha in January, Beta in February, that's my theory.


http://cs.berkeley.edu/~bh/sig5.png

Offline

 

#4241 2011-12-05 19:01:15

bharvey
Scratcher
Registered: 2008-08-10
Posts: 1000+

Re: BYOB 3 - Discussion Thread

14God wrote:

Why does it still say "pre alpha"? Its good enough to be alpha  big_smile

P.S. to the above:  Until recently it said "pre-pre-pre-alpha"!  We've made progress in the naming.  smile


http://cs.berkeley.edu/~bh/sig5.png

Offline

 

#4242 2011-12-06 02:54:37

xly
Scratcher
Registered: 2010-04-17
Posts: 100+

Re: BYOB 3 - Discussion Thread

bharvey wrote:

xly wrote:

The aim is to entirely convert Byob 3.1 to Snap!
And even basic functions like Save/Load are not yet implemented !
There is still a "long way to Alpha"

Yes, exactly.  Plus multiple sprites, costumes,...

Alpha in January, Beta in February, that's my theory.

January, February...That is not so far ahead !!

Offline

 

#4243 2011-12-06 04:32:15

Hardmath123
Scratcher
Registered: 2010-02-19
Posts: 1000+

Re: BYOB 3 - Discussion Thread

Jens wrote:

Hardmath123 wrote:

I've got a question: what does 'morphic' actually mean? I know it relates to morphs which (I think) are like widgets, but is there something deeper? A quick Google gave a Wiki result. The Wikipedia page actually returned a link to your Morphic.js ( big_smile ), but there was nothing useful and explanatory.

Hi Hardmath123,

you're right, the Wikipedia article is just a stub. Here are three papers that explain what Morphic is all about:

http://selflanguage.org/documentation/p … ctness.pdf
http://ftp.squeak.org/docs/Self-4.0-UI-Framework.pdf
http://stephane.ducasse.free.fr/FreeBooks/CollectiveNBlueBook/morphic.final.pdf

Thanks! I finally got a chance to read those.

I'm working on a simplified version of Morphic which makes it easier to implement a GUI. You have to create objects (I'm not saying morphs because I'm not sure whether they have all the features needed to be morphs) in code (var button = new button()), and they are manually undraggable and uneditable during runtime, though you can dynamically edit them in the code. Screenshot:
http://www.imgpaste.com/HSUj.png
Is this Morphic?

Oh, and in BBCode [url] tags, you can omit the "=http://path" bit if you want the linked text to be the path itself: [url]http://www.google.com[/url].  wink


Hardmaths-MacBook-Pro:~ Hardmath$ sudo make $(whoami) a sandwich

Offline

 

#4244 2011-12-06 05:51:19

Jens
Scratcher
Registered: 2007-06-04
Posts: 1000+

Re: BYOB 3 - Discussion Thread

Hi Hardmath123,

I share your feeling that it's important to create "locked up" GUIs. This is not in the spirit of the original Morphic where everything and anything can be taken apart and modified directly by the user anytime in any way imaginable, and I believe that exactly this is "real" Morphic's worst mistake and the reason why mostly everybody who is working with Squeak hates it (and Squeak, too).

Therefore Morphic.js has ways to "lock up" a GUI. You can set the "isDraggable" property of any Morph to false, and you can specify the World to be in "userMode". You can also set the World's contextMenu property to null, and then you have a completely locked up Morphic GUI, that cannot be taken apart or inspected by the user at runtime (no "secret" keys either).

Having conceded this I do think that a directly editable, metacircular GUI system that can be manipulated by way of itself is totally cool and offers brilliant self documenting features. So you really want to have your cake and eat it, too, i.e. you want to have both "modes" in a GUI, the "locked up" one and the "dev" mode which lets you inspect and debug everything.


Jens Mönig

Offline

 

#4245 2011-12-06 06:07:55

Hardmath123
Scratcher
Registered: 2010-02-19
Posts: 1000+

Re: BYOB 3 - Discussion Thread

Jens wrote:

Hi Hardmath123,

I share your feeling that it's important to create "locked up" GUIs. This is not in the spirit of the original Morphic where everything and anything can be taken apart and modified directly by the user anytime in any way imaginable, and I believe that exactly this is "real" Morphic's worst mistake and the reason why mostly everybody who is working with Squeak hates it (and Squeak, too).

Therefore Morphic.js has ways to "lock up" a GUI. You can set the "isDraggable" property of any Morph to false, and you can specify the World to be in "userMode". You can also set the World's contextMenu property to null, and then you have a completely locked up Morphic GUI, that cannot be taken apart or inspected by the user at runtime (no "secret" keys either).

Having conceded this I do think that a directly editable, metacircular GUI system that can be manipulated by way of itself is totally cool and offers brilliant self documenting features. So you really want to have your cake and eat it, too, i.e. you want to have both "modes" in a GUI, the "locked up" one and the "dev" mode which lets you inspect and debug everything.

Which do you prefer — end-user editable mode or "locked up" mode? Which would be easier to develop, and use? I personally see little user-side advantage in a "dev" mode, maybe a little help for developers nitpicky about aesthetics. But I guess I'll implement a "dev" move anyway; it may prove useful.

PS: Congratulations on 1500 posts!  big_smile


Hardmaths-MacBook-Pro:~ Hardmath$ sudo make $(whoami) a sandwich

Offline

 

#4246 2011-12-06 07:42:58

roijac
Scratcher
Registered: 2010-01-19
Posts: 1000+

Re: BYOB 3 - Discussion Thread

bharvey wrote:

...

Well, it's ok, just said because this is what I learnt from BYOB  smile
Also notice the infinite loop when calling a script with no return block  tongue

Offline

 

#4247 2011-12-06 10:06:37

bharvey
Scratcher
Registered: 2008-08-10
Posts: 1000+

Re: BYOB 3 - Discussion Thread

xly wrote:

January, February...That is not so far ahead !!

Note I didn't say the first of the month.  The actual beta deadline is 28 Feb.  That still wouldn't be much time if we had a team of 5000 programmers, but instead we have Jens, so it should be plenty.


http://cs.berkeley.edu/~bh/sig5.png

Offline

 

#4248 2011-12-06 10:13:35

MathWizz
Scratcher
Registered: 2009-08-31
Posts: 1000+

Re: BYOB 3 - Discussion Thread

bharvey wrote:

That still wouldn't be much time if we had a team of 5000 programmers, but instead we have Jens, so it should be plenty.

Nice analogy.  tongue  When's saving planned, because that's the only reason I'm not making complicated projects in Snap!.

Last edited by MathWizz (2011-12-06 10:13:57)


http://block.site90.net/scratch.mit/text.php?size=30&text=%20A%20signature!&color=333333

Offline

 

#4249 2011-12-06 10:41:21

bharvey
Scratcher
Registered: 2008-08-10
Posts: 1000+

Re: BYOB 3 - Discussion Thread

MathWizz wrote:

When's saving planned, because that's the only reason I'm not making complicated projects in Snap!.

Yeah, me too.  nXIII is working on it.  Should be soon.

EDIT: A reader for BYOB projects, too, he plans.

Last edited by bharvey (2011-12-06 10:41:59)


http://cs.berkeley.edu/~bh/sig5.png

Offline

 

#4250 2011-12-06 11:25:54

roijac
Scratcher
Registered: 2010-01-19
Posts: 1000+

Re: BYOB 3 - Discussion Thread

how does he actually implement saving?

Offline

 

Board footer