View Single Post
Functions and Seldom Used Properties
Posts: n/a
Lightbulb Functions and Seldom Used Properties - 12-02-2008, 07:13 PM

This is just off the top of my head to get you started - and may not be totally correct. It should, however, give you a start to experiment with. It's also probably worth searching the forum and Dick Baldwin's tutorials for more definitive answers.

World Functions
1. mouse distance from left edge/top edge (tried to use but didn't understand how numbers were calculated)

This is just the distance the cursor is from the top left edge of the viewing window in pixels. Note values outside the viewing window are allowed.

2. IEEE Remainder of A/B (probably some math I haven't learned yet)

Nothing I'd worry about. It refers to an IEEE standard for floating point math but probably won't be too significant with modern machines. Basically it handles things like 4/3 = 1 1/3 = 1.3333333.... (very messy when one was working with 8-bit machines and big numbers )

3. right, up forward (no idea at all about this one)

Essentially the same as the more conventional (x,y,z) coordinates. There are a couple of good forum postings on this.

Object Functions

1. Object's quaternion (????)

A complex notation for 3-dimensional movement which is widely used in games. Wikipedia has a good article as a starting point for information. I really don't think you can use them within Alice 2.0 very effectively - suspect they were included for debug.

2. object's part named key (does that have to do with subparts?)
3. object's variable named variablename and of class valueclass

Both of these can be used to pass parameters to methods. They can be a bit tricky to use as all of the names have to be exact! I believe there is an example in the Dunn, et al text.

Also, all of the seldomly used properties for objects would be nice, especially specular highlight exponent.

The first few are pretty self explanatory.

"is First Class" determines whether or not an object can be selected by the mouse - very useful for something like the ground that you don't want to select.

"Emmisive color" is the color of light coming from an object (like a glowing ball).

"Spectral Highlights" refers to light from other sources reflected from the an object. The color is a combination of the selected color and the color of the source while the exponent sets the intensity of the reflection. Experimenting here is the best approach, although there are tutorials on the web.

Both emmisive color and the spectral parameters, as well as flat vs. smooth shading (experiment with these also) are subsets of the general subject of rendering 3D objects - most 3D modeling programs go into these in some detail. Blender has some of the best tutorials - but they can be pretty difficullt to follow.

I have no idea what "eventsStopAscending" does. (Anyone?)

An opacity map should allow you to modify a texture with a second image but I've never figured out how to make it work.

As I said at the beginning, this is just a first pass. Additions and corrections are welcome and encouraged.

Added note: Just after I posted this, a mouse control program that illustrates the first function was posted - see .

Last edited by DrJim; 12-02-2008 at 08:24 PM. Reason: Added reference
Reply With Quote