[Q] Wonderland programming tip
Stephan B. Wessels
swessels at one.net
Sat Apr 6 03:58:58 UTC 2002
On 4/5/02 5:21 PM, "Andreas Raab" <Andreas.Raab at gmx.de> wrote:
>> There is a WonderlandCameraMorph class in the image.
>> Can I use that or something like it to get this kind
>> of idea off the ground? Starting to dig through the
>> Wonderland code and I'd rather not discover how to do
>> this unless someone else hasn't tried yet.
>> Tips and pointers are appreciated. I want to get
>> something working this weekend.
> What you may want to do is to set up your character using the Wonderland
> scripting environment. If you haven't read the Rose/Guzdial book check
> out http://coweb.cc.gatech.edu/squeakbook/5 which contains Jeff's draft
> version of the chapter. It'll explain most of what you need to do. Then,
> all you need to do is to hide the scripting area and all that's left is
> the window with the 3D character.
> - Andreas
You know, I'm such a "code bigot". :) I own both the blue and the white
Squeak books. I tend to quickly scan through books to see what's in them
and then use them as reference and pull information from specific chapters
as needed. I'm so use to pouring over the code in the image to figure out
how things work, that it didn't even cross my mind to check and see if
someone had written documentation! Heh.
I just read the chapter. That clarified the camera morph relationship. I
already have the actor loaded from an MDL file and a script to make it do
what I want.
Sounds like your hint is that I should go ahead and build the Wonderland,
add the actor, program a script for the actor and then hide the script
window. I'll probably take that as a lead idea and write some hooks to the
wonderland to make it easy for me to do all of that in a programmed way.
I'll probably see what it takes to layout the camera morph (for rendering
everything) inside some kind of alignment or other morph to make it appear
to be inside another window. I want my actor to dance and cause the user to
look at a list of things to review from another pane.
According to the textbook, it looks like all actions are the result of
script execution and "events" related to time or user clicks. I'll need
some way to tell my actor to perform a script when a specific application
event happens. For example, when a message containing something interesting
arrives over a TCP socket.
Like I said earlier, this is probably a good weekend project.
Time to start digging...
More information about the Squeak-dev