Open main menu

Difference between revisions of "SCI/Specifications/SCI in action/Views and animation in SCI"

m
behaviour -> behavior
m (Fix pseudocode display)
m (behaviour -> behavior)
Line 8: Line 8:
An animation cycle is done entirely in SCI code (with the aid of some kernel calls). It involves two other objects; the mover and the cycler. The mover is responsible for controlling the motion of an actor towards a specific point, while the cycler changes the image of the actor, making him appear to walk, for instance.
An animation cycle is done entirely in SCI code (with the aid of some kernel calls). It involves two other objects; the mover and the cycler. The mover is responsible for controlling the motion of an actor towards a specific point, while the cycler changes the image of the actor, making him appear to walk, for instance.


The behaviour of a view is controlled by its signal property. This property contains a bitfield which describes a lot of animation-related stuff. The bits can be roughly divided into two groups; the script and interpreter bits (I had called them Option and State bits at first, but that is not entirely accurate). The first group allows the script to influence the drawing pro- cess somewhat, the other are used internally by the interpreter. The two groups overlap a bit, though.
The behavior of a view is controlled by its signal property. This property contains a bitfield which describes a lot of animation-related stuff. The bits can be roughly divided into two groups; the script and interpreter bits (I had called them Option and State bits at first, but that is not entirely accurate). The first group allows the script to influence the drawing pro- cess somewhat, the other are used internally by the interpreter. The two groups overlap a bit, though.


<p><strong>Table 6-1. SCI and FreeSCI signal bits</strong></p>
<p><strong>Table 6-1. SCI and FreeSCI signal bits</strong></p>
Line 101: Line 101:
|  align="left" valign="top" | _K_VIEW_SIG_FLAG_IGNORE_ACTOR
|  align="left" valign="top" | _K_VIEW_SIG_FLAG_IGNORE_ACTOR
|  align="left" valign="top" | Actors can walk in the rectangle occupied by the view. The
|  align="left" valign="top" | Actors can walk in the rectangle occupied by the view. The
behaviour of this bit is odd, and best expressed by example. The Guild Master in QfG1 has
behavior of this bit is odd, and best expressed by example. The Guild Master in QfG1 has
his bit 14 set. This means that ego (or someone else) can walk all the way to his chair
his bit 14 set. This means that ego (or someone else) can walk all the way to his chair
(try sneaking in on him from behind). If we clear this bit, we can't sneak in on
(try sneaking in on him from behind). If we clear this bit, we can't sneak in on
2,051

edits