Page 1 of 1

131p6 - .cel scripts "mark" command

Posted: 20.07.2003, 16:55
by don
OS: WinXP Pro SP1
Ver: 1.3.1 pre6
RE: .cel scripts

Command: mark

Can someone explain how the "mark" command is supposed to function?

The "object" value works.

The "size" value does not work (#.#)?
I have tried small decimal to large integer "size" values with no change in the display size of the marker.

The "color" value does not work ( [#.# #.# #.#] )?
I have tried small decimal to large integer "size" values, with no change in the display color of the marker. All I get is red.

The "symbol" value does not work (diamond square triangle plus X)?
All I get is an "X".

Here is an example of the code I'm trying to use ...

Code: Select all

 renderflags { set "markers" }

 mark { object "Earth"
        size 10  # (valid value range?)
        color [1.0 0.0 0.0] # (what values where for what colors?)
        symbol "plus" } # (diamond square triangle plus X)


Thank you.

Posted: 20.07.2003, 19:20
by chris
The symbol, color, and size parameters to the mark command should all be working. I just verified it on my version of Celestia . . . Perhaps you need to specify "Sol/Earth" instead of "Earth"? There are some sample mark commands (commented out) in the start.cel script . . . try cutting and pasting them into a script and running it. You should see markers on the four inner planets with different sizes, colors, and symbols.

Actually, just cut and paste this:

Code: Select all

mark { object "Sol/Mercury" color [ 1 1 0 ] symbol "triangle" }
mark { object "Sol/Venus" color [ 1 1 0.7 ] symbol "square" }
mark { object "Sol/Earth" color [ 0 0.3 1 ] symbol "x" }
mark { object "Sol/Mars" color [ 1 0.3 0.3 ] symbol "plus" }


--Chris

Posted: 20.07.2003, 21:19
by don
Hi Chris,

I think I found the snag ...

If an object has a mark already set for it, issuing another mark command for that object does nothing -- the existing mark remains in place. Here's an example of both ...

(Do a keyboard 3 g first <smile>.)

Code: Select all

{
#----< marking test >-----------------------------------
# This works...

renderflags { set "markers" }
unmark { object "Sol/Earth" }

mark { object "Sol/Earth" color [ 0 0.3 1 ] symbol "x" }
print  { text " Small blue 'X' on Earth." row  -3 duration 3 }
wait   { duration 3 }

unmark { object "Sol/Earth" }
mark { object "Sol/Earth" size 40 color [0.0 1.0 0.0] symbol "diamond" }
print  { text " Large green diamond on Earth." row  -3 duration 3 }
wait   { duration 3 }


# This does NOT work...

renderflags { set "markers" }

mark  { object "Sol/Earth" color [ 0 0.3 1 ] symbol "x" }
print { text " Small blue 'X' on Earth." row  -3 duration 3 }
wait  { duration 3 }

mark  { object "Sol/Earth" size 40 color [0.0 1.0 0.0] symbol "plus" }
print { text " Large green plus on Earth." row  -3 duration 3 }
wait  { duration 3 }
#-------------------------------------------------------
}


Is this the intended behavior?

Also, when I am *in* the solar system, "Earth" works just like "Sol/Earth". BUT, it's probably a GOOD idea to get in the habit of using the "Sol/" prefix to address any solar system objects ... just in case (smile).

-Don