Etoy: lots of 'garbage' costumes?
Scott Wallace
scott.wallace at squeakland.org
Thu Nov 14 03:41:32 UTC 2002
Marcel and Markus,
This is a part of the e-toy landscape that has not been in a very
clean state for several years now. It's a loose end we've been able
to live with only because there have been so few users ;-) And also
because the phenomenon you mention only arises if non-SketchMorphs
are involved when you do "look like". Which they never are in any of
Alan's demos or any uses of this feature in the school experiments
using E-toys.
If any of the contributors of costumes to a "look like" sequence are
themselves not SketchMorphs, the list of "past costumes" can grow
indefinitely because a fresh form is made from the image-form of the
costume contributors in those cases.
(In the case of wearing *sketch* costumes from other SketchMorphs, a
check is made for *identity* of forms so that duplicates will not
accumulate. But in the case of wearing the "picture" of another
morph that is *not* a SketchMorph, the identity check does no good.)
Because of these known problems of proliferation of costume
histories, there's a menu item in the World's debug menu called
"abandon costume history", which clears out all those memories of
"other costumes" in all the world's players; also, for any individual
morph, in the "more" branch of the Viewer menu (the one you get by
clicking on the little menu icon at the top of a Viewer) will be
found the menu item "forget other costumes", which does the same job,
but just for that one object.
The principal reasons for holding on to past costume histories are
not very prominent now (this stuff goes back some years) so perhaps a
draconian solution is in order.
Fixes would be welcome ;-)
Cheers,
-- Scott
At 11:20 PM +0100 11/13/02, Marcel Weiher wrote:
>Hi folks,
>
>in the "Scripting with Squeak" Seminar we're giving, Markus and I
>have encountered a problem with Projects becoming difficult to save
>because of memory issues.
>
>A little snooping revealed that the problem was with
>Morphs/Etoys/Players that were being animated by changing their
>costume using scripting tiles (the "... look like Holder's
>playerAtCursor / increment Holder's cursor" pattern). These seem to
>accumulate all the customes they've ever had in the "costumes"
>instance variable of their "player".
>
>Since our students tend to leave their animations running in the
>background while they work on other stuff, that adds up to a LOT of
>customes.
>
>Is this the intended behavior? Can I turn it off somewhere?
>
>I have a small snippet of code to zap all of these costumes. Is
>this safe or will I destroy something important?
>
>Thanks,
>
>Marcel
>
More information about the Squeak-dev
mailing list
|