[an error occurred while processing this directive]
FSASM support Index DKI file format description

SCASM support in DynKit 

Contents
Introduction

The SCASM support in DynKit is very limited, because SCASM (v2.19 at the time DynKit was released) cannot create BGL section 10 directly and also offers no ways to implement section 10 data structures using macros.

You can use SCASM to put the SDL code into a section 9 Area()-block, and then import it into a dynamic library as raw SDL code using DynKit Hangar. The Area()-block must begin with one of the two SCASM macros supplied with DynKit, followed by the SDL code that draws the object. The SDL code must conclude with a Return instruction.

There is an example dynamic object shape made with SCASM: dynbrick.sca.

Macros

Macro( dkobj.scm ScaleFactor DynExtent )
Macro( dkobjx.scm
ScaleFactorX DynExtent )

Both these macros select the proper RefPoint and the scale factor, call the SDL code that follows in both shadow and regular drawing mode, and set the object extent variable. The difference between them is in the meaning of the scale factor parameter. The macro dkobj.scm expects the scale factor to be in the format used by the SetScale() instruction, while dkobjx.scm expects it to be in the format used by SetScaleX().

One of these macros must be placed at the very beginning of the Area()-block where you put your SDL code.

Special dynamic scenery instructions

SCASM 2.19, included in DOD, has the D_35 dynamic instruction that allows selecting dynamic object shapes using 16-byte ID strings. Earlier versions of SCASM do not support it. If you have to use an earlier version, you should use regular Pattern() instructions in your code and then insert the desired ID strings using DynPatch.

D_35( Label traffic_flags mindense id0 id1 id2 ... id15 )

The parameters Label traffic_flags mindense have the same meaning as in the Pattern() instruction. The parameters id0..id15 specify the ID string.


FSASM support Index DKI file format description

Copyright © 1998 by Konstantin Kukushkin