Manzana
Last updated at 12:37 am UTC on 17 January 2006

Author: Diego Gomez Deck

Really simple physics simulations with Morphs. Every Morph contained in ManzanaUniversePasteUpMorph or in ManzanaPlanetPasteUpMorph with mass will be part in a simple simulation.

Manzana is the spanish word for apple, you can guess why I used this name :-)

The idea comes from Planetas, a job made by smalltalk students in a Smalltalk course at Facultad de Agronomía - UBA (in spanish).

### Try it

• Evaluate:
• `<b>ManzanaUniversePasteUpMorph example1.</b> <font color="green">"from example1 to example9"</font>`
• `<b>ManzanaPlanetPasteUpMorph example1.</b> <font color="green">"from example1 to example3"</font>`
• Try draging and dropping the objects in diferents places
• Try resizing the container morph

### Small description

• Every Morph can be included in a simulation. Only mass is necessary (see #mass and #mass: messages).
• ManzanaUniversePasteUpMorph simulate an universe.
• ManzanaPlanetPasteUpMorph simulate a planet with gravity.
• ManzanaForceMorph apply a force proportional to its size to every morph that touch it.

### TODO list

• etoy vocabulary
• when the bounce is detected, a small correction is needed to avoid inyecting more speed than the one on the edge
• made bouncing and wrapping optional
• collition between morph with masses
• edge detection for bitmap based morphs

### Screenshots

ManzanaUniversePasteUpMorph with 3 celestial bodies

ManzanaPlanetPasteUpMorph with some bouncing bodies

ManzanaPlanetPasteUpMorph with assorted morphs.
The arrows are Force morphs. Each time an morph touch these forces, the force is applied producing a change in the speed

ManzanaPlanetPasteUpMorph with some assorted morphs