ActMap

The ActMap.txt-component describes possible actions (i.e., activities like walking and scaling for clonks; or opening/closing doors of buildings), of an object. The animation phases of each activity are placed as adjacent images in the Graphics.png (and/or Overlay.png/Graphics.bmp). These animations are being referenced using image coordinates in the ActMap.txt. Animations may be started by script (see SetAction) or directly by the engine. Some activities - especially those of clonks and animals - use an engine-intrenal procedure, which controls the movement of an object while such an activity is set.
Any number of sections [Action]
Value Data type Description
Name String (max. 30 chars) Name of the activity. See SetAction().
Procedure String (max. 30 chars) Internal standard procedure. See Procedures.
Directions Integer Number of animation directions. Animation directions are arranged vertically in Graphics.png.
FlipDir Integer If nonzero, this value specifies the first animation phase that is produced by mirroring one of the previous animation directions. If this value is 1, graphics of direction 1 (DIR_Right) will be drawn as a horizontally mirrored graphics of direction 0 (DIR_Left) (see clonks). If it is 7, any directions n >= 7 will be drawn using the mirrored graphics of directions 6 - n, i.e. higher direction values will be drawn using the mirrored graphics in reverse orders (cf. banner in the knights pack).
Length Integer Number of animation phases for this activity (arranged horizontally in Graphics.png)
Reverse Integer 0 or 1. If 1, the animation phases will be shown in reverse order.
Delay Integer Time difference in frames (ticks) between two animation phases.
Step Integer Step count in graphics per action step. Example: A value of 2 will skip one frame for each step, 3 will skip 2, etc. Default 1.
Attach Integer Attachment to surfaces: CNAT Value, e.g. value 8 if the object should attach to the floor like a walking clonk does; or 4 for attachment to the ceiling like a hangling clonk. Only evaluated if the procedure is NONE.
Facet 6 integers Animation graphics: Target rectangle from Graphics.png relative to upper left corner of unrotated object shape.
FacetBase Integer 0 or 1. If 1, the default facet (i.e., the facet shown if the object has no action) will be drawn behind the action facet.
FacetTopFace Integer 0 or 1. If 1, the TopFace (see DefCore.txt) will be drawn using the animated facet.
FacetTargetStretch Boolean 0 or 1. If 1, the graphics will be stretched down towards the upper border of the ActionTarget. Used e.g. for the elevator line.
NextAction String (max. 30 chars) Next action being set after the current one has reached its end.
TurnAction String (max. 30 chars) Action set when changing direction.
NoOtherAction Integer 0 or 1. If 1, no other action can be set after this one (used e.g. for death or destruction).
StartCall String (max. 30 chars) Object script function which is called when the activity is started.
EndCall String (max. 30 chars) Called when an activity reaches the end of its animation.
PhaseCall String (max. 30 chars) Called whenever the animation phase changes.
AbortCall String (max. 30 chars) Called if an activity is being replaced by another before its regular end; i.e. not by a transition through NextAction.
InLiquidAction String (max. 30 chars) Action to be set if the object plunges into water.
Sound String (max. 30 chars) Permanent sound being played during this action.
ObjectDisabled Integer 0 or 1. Restricted control of the object during this action.
DigFree Integer Area that is dug free during this action. If 1, the area covered by the object shape is freed (like the elevator case); otherwise, the value is taken as the radius of a circular area (like a digging Clonk).
EnergyUsage Integer Energy required for this action. Normal machines should use about 500.
Sven2, April 2002
matthes, Juni 2004