'From Squeak2.8 of 13 June 2000 [latest update: #2359] on 28 November 2000 at 6:54:46 am'! EllipseMorph subclass: #SwingMorph instanceVariableNames: 'position velocity ' classVariableNames: '' poolDictionaries: '' category: 'Morphic-Demo'! !SwingMorph methodsFor: 'as yet unclassified' stamp: 'ward 11/28/2000 00:00'! initialize super initialize. velocity _ 0@0. position _ 0@0! ! !SwingMorph methodsFor: 'as yet unclassified' stamp: 'ward 11/28/2000 01:07'! step | mags acceleration delta | super step. mags _ owner submorphs select: [:each | each class == EllipseMorph]. acceleration _ mags inject: 0@0 into: [:sum :each | delta _ each position - position. sum + (delta / (delta r squared + 2))]. acceleration _ velocity * -0.0001 + acceleration. velocity _ velocity + (acceleration * 10) . position _ position + velocity. self position: position rounded! ! !SwingMorph methodsFor: 'as yet unclassified' stamp: 'ward 11/28/2000 00:04'! stepTime "As fast as possible." ^ 0 ! !