bharvey wrote:
Do you like it? When this design is totally implemented it's going to be so cool! For example you'll be able to have class variables by having the clones say
Code:
RUN [[THE SCRIPT [SET <foo> TO <bar>]] OF [OBJECT <PARENT>]](whereas just SETting it in the clone would make a private copy).
I love it! I've never seen OOP done quite like this before. I'm beginning to really like this style of programming; it seems so much more elegant than what I'm used to!
Offline
@ bharvey and Jens
It would be kinda cool to be able to put a block into the default value field of the argument editor.
Last edited by 14God (2011-02-04 00:55:52)
Offline
Theres a general fault with my 'send' block and that is that it will only use variables from the receivers scope. This can be fixed by making an out variable and a multiple input variable and setting the out to the multiple input value. The multiple input can then be used to passed arguments and the out variable can be put in your script and you can use list blocks to access it.
Offline
14God wrote:
Theres a general fault with my 'send' block and that is that it will only use variables from the receivers scope. This can be fixed by making an out variable and a multiple input variable and setting the out to the multiple input value. The multiple input can then be used to passed arguments and the out variable can be put in your script and you can use list blocks to access it.
You should be able to say, e.g.,
SEND <other-guy> [SET <his-variable> TO [ASK <me> <my-variable>]]
where ASK is the reporter version of SEND, and <me> is specific, like [OBJECT <sprite34>], not [OBJECT <MYSELF>].
Offline
bharvey wrote:
You should be able to say, e.g.,
Code:
SEND <other-guy> [SET <his-variable> TO [ASK <me> <my-variable>]]where ASK is the reporter version of SEND, and <me> is specific, like [OBJECT <sprite34>], not [OBJECT <MYSELF>].
Wow thats way better then what I was doing. I also realized that the send block will use script variables from the senders scope.
Offline
MiniLogo, an almost complete reimplementation of UCBLogo (a wonderful Logo by Brian Harvey, http://www.cs.berkeley.edu/~bh/) based on Jen's BYOB is available at http://byob.sitibs.com/miniLogo-v1.0.ypr.
Please, look at the presentation at http://scratch.mit.edu/projects/s_federici/1576481.
MiniLogo is similar in spirit to miniC++ (http://scratch.mit.edu/forums/viewtopic.php?id=51792).
Detailed documentation of the miniLogo language is avaiable at http://byob.sitibs.com/miniLogo-v1.0.pdf.
A HUGE thanks to Brian Harvey for having designed UCBlogo, such a beautiful Logo!
WARNING: loading miniLogo can take a while (even more that 2 minutes) so... be patient!
Last edited by s_federici (2011-02-04 16:11:36)
Offline
bharvey wrote:
shadow_7283 wrote:
Once my AI has reached its goal, it is supposed to follow the parent of each tile back to the original square to find the shortest path
Does each tile have a unique next-closer-to-start neighbor? If so, this sounds doable. I wouldn't try to make that neighbor the parent of the tile; probably all the tiles should have one parent. But each should have a variable whose value is the next neighbor. Will that do it?
Hmm... I'll have to consider it. Not today however. It really snowed where I live for the first time in four or five years! :D
Offline
14God wrote:
Yes, factoring ATTRIBUTE that way is much cleaner, and is in fact The Plan -- the current ATTRIBUTE OF block is a stopgap. I like your sense of aesthetics!
P.S. Except, we weren't planning to make it a special form; I think it's easier to understand if you actually see the lambdafication of the accessor block. But maybe you're right. We'll have to think about that. One limiration of the special-form approach is that it prevents using an un-lambdafied variable block for a program that wants to get at several different attributes.
Last edited by bharvey (2011-02-04 11:02:28)
Offline
14God wrote:
I also realized that the send block will use script variables from the senders scope.
Yeah I thought of that in bed last night. It's neat that script variables, at first just a convenience, have this truly valuable benefit!
Offline
xly wrote:
You can also save a block (even a list of blocks) into a semi-persistent list variable, get it back and run it. The whole context of a sprite could be handled like that.
Cool! I like the idea of making a list of accessor blocks defining the state of a sprite and then doing MAP [THE [< > OF <sprite>] BLOCK] over that list to get the state of a particular sprite.
Offline
shadow_7283 wrote:
It really snowed where I live for the first time in four or five years!
Offline
bharvey wrote:
shadow_7283 wrote:
It really snowed where I live for the first time in four or five years!
LOL! I don't have to worry about me three feet of snow up her in Wisconsin! [/offtopic]
Looks like it's time for me to update my version of BYOB!
Offline
Hi BHarvey, this isn't exactly linked to BYOB, but I was just wondering if you knew that you and your tutorial on Logo are mention int he help files of it. I was just kinda surprised to see your name pop up during a computing lesson. (Sorry for going offtopic)
Offline
bharvey wrote:
markyparky56 wrote:
you and your tutorial on Logo are mention int he help files of it.
In the help files of what, exactly? Berkeley Logo? (No surprise if so. ) Someone else's Logo? Tnx.
MS Windows Logo. (Is that Berkeley Logo?)
Last edited by markyparky56 (2011-02-04 12:36:30)
Offline
markyparky56 wrote:
MS Windows Logo. (Is that Berkeley Logo?)
Ah. It's a spinoff of Berkeley Logo, with a Windows-specific GUI added.
It's also really old and unmaintained; you should check out FMSLogo, a newer MSWLogo spinoff, instead.
Offline
bharvey wrote:
shadow_7283 wrote:
It really snowed where I live for the first time in four or five years!
Funny. Unfortunately, The snow is almost completely GONE already.
I'm going to live in a colder climate someday.
Offline
Ooh! I just noticed that there's a layer option in the get and set blocks! I don't see how this could be used, but it might lead to something...
There's also a 'mouse-pointer' option in the delete block.
Last edited by rubiks_cube_guy238 (2011-02-04 18:26:50)
Offline