S
t
a
r
t
Diary
Diary
Download egg-O-shOOter
Download
How to create your own egg-O-shOOter ?
Insight
Frequently asked questions
Questions?
egg-O-shOOter Food
Food
Links
Links
I
m
p
r
i
n
t
Klick hier für die deutschsprachige Version.

At this column you can learn to create your own egg-O-shOOter.
<<<     Object rotation 1     >>>

Let's rotate a cup. Take the 'have a break-cup' and observe the specialties of rotations.
The first cup has no rotating speed, you will learn something about initialization process first:

#1#
ObjectNumber=1       #1#'Mach mal Pause' Tasse / Cup 'Have a break'
ObjectFront=1
ObjectStartActive=1
ObjectTexture=10
ObjectF=-1
ObjectD=-1
ObjectSecMin=-1
ObjectSecMax=-1
ObjectConnect=-1
ObjectKoordPre=-1
ObjectHitDirection=0
ObjectXMin=0
ObjectXMax=0
ObjectYMin=0
ObjectYMax=0
ObjectDMin=40
ObjectDMax=40
ObjectAMin=45
ObjectAMax=45
ObjectVXMin=0
ObjectVXMax=0
ObjectVYMin=0
ObjectVYMax=0
ObjectVRotMin=0
ObjectVRotMax=0
ObjectRotAxis=3
ObjectVGrowMin=0
ObjectVGrowMax=0
ObjectGravMin=0
ObjectGravMax=0
ObjectMoveXMin=-800
ObjectMoveXMax=+800
ObjectMoveYMin=-200
ObjectMoveYMax=+200
ObjectMoveAMin=-360
ObjectMoveAMax=+360
ObjectMoveRMin=1
ObjectMoveRMax=1000
ObjectMoveType=3
ObjectType=3
ObjectBenefitMin=*0,*0,*0,*0,*0,*0,*0,*0,*0,*0,*0,*0,*0
ObjectBenefitMax=*0,*0,*0,*0,*0,*0,*0,*0,*0,*0,*0,*0,*0
ObjectMirror=0
ObjectMovePointing=0
ObjectHitSound=objecthit014
ObjectAppearSound=
ObjectHitTextEnglish=
ObjectHitTextGerman=

Save 'themes.txt', start level 1 and press the 'N'-key to rescan the file. The cup is tilted either to the right or to the left whenever you press the 'N'-key. That's alright, because the variable ObjectAMin/Max is 'bidirectional' and we did not type signed values. So the direction is 'diced' whenever the cup is initialized.
The rotation at the example given above is around the Z-axis, which is the axis pointing out of your screen. Further rotation axis are the X-(=horizontal) and Y-(=vertical) axis. The rotation axis is given by the variable ObjectRotAxis.
1=X-Achse
2=Y-Achse
3=Z-Achse (Standard)
Set ObjectRotAxis=1 (=rotation around the X-axis) and rescan the file 'themes.txt' some times by pressing the 'N'-key. It seems that the cup is tilted in just one direction by now - is there no 'bidirectionality' given? The answer is that egg-O-shOOter still handles the angle like being 'bidirectional', you just can't see the difference! Hereat the flatness of the egg-O-shOOter universe is noticeable. There is no real 'front' and 'behind'.
Let's push the cup and let it rotate. That is done by setting the variable ObjectVRotMin/Max=30.
Now a little illusion of rotation around the X-axis will appear at your brain. Observe the cup and imagine it would rotate 'forward' - that should work. Let the rotation continue and imagine there would be a rotation 'backwards' - that should work as well. As seen at the static tilting, there is no difference between the two directions. Only if setting ObjectRotAxis=3 you will realize the difference. That's the disadvantage of a 2-dimensional world. The rotation axis around X- and Y-axis where implemented to realize the wing beat of the birds, which will be described later.
Projektfenster Gimp
Let's play around with the variables ObjectMoveAMin/Max to limit the rotation:

ObjectAMin=0
ObjectAMax=0
...
ObjectVRotMin=+30
ObjectVRotMax=+30
ObjectRotAxis=3
...
ObjectMoveAMin=-45
ObjectMoveAMax=+45

Limited by those values, the cup starts rotating clockwise until the direction is inverted when reaching an angel of 45 degrees. The anticlockwise rotation is inverted when reaching an angel of -45 degrees.

ObjectMoveAMin=+45
ObjectMoveAMax=+315

Makes the cup rotate inside the once 'forbidden' area.

ObjectMoveAMin=-350
ObjectMoveAMax=+350

Makes the cup rotate almost twice around the axis before inverting the direction.

ObjectMoveAMin=-360
ObjectMoveAMax=+360

Causes nothing, because egg-O-shOOter always adds or subtracts 360 degrees to avoid the current angle from being outside -360 to +360 degrees.

<<<Back to connected objects          Continue with object rotation 2>>>