SCOL Record – Static Collection

SCOL record type.

Classes:

SCOL(flags, id[, revision, version, ...])

Static Collection.

class SCOL(flags, id, revision=0, version=15, unknown=b'\x00\x00', data=[])[source]

Bases: Record

Static Collection.

Parameters
  • flags (int)

  • id (bytes)

  • revision (int) – Default 0.

  • version (int) – Default 15.

  • unknown (bytes) – Default b'\x00\x00'.

  • data (List[RecordType]) – Default [].

Classes:

DATA([iterable])

Placements.

DataItem(xp, yp, zp, xr, yr, zr, scale)

Placements.

ONAM([cstring])

Static.

Attributes:

data

Subrecords of this record.

flags

Record flags

id

4-byte form ID

revision

Used for revision control by the Creation Kit, if enabled.

unknown

version

Form version

Methods:

parse_subrecords(raw_bytes)

Parse this record's subrecords.

class DATA(iterable=(), /)[source]

Bases: List[DataItem], RecordType

Placements.

Methods:

parse(raw_bytes)

Parse this subrecord.

unparse()

Turn this subrecord back into raw bytes for an ESP file.

classmethod parse(raw_bytes)[source]

Parse this subrecord.

Parameters

raw_bytes (BytesIO) – Raw bytes for this record

Return type

Self

unparse()[source]

Turn this subrecord back into raw bytes for an ESP file.

Return type

bytes

namedtuple DataItem(xp, yp, zp, xr, yr, zr, scale)[source]

Bases: NamedTuple

Placements.

Fields
  1.  xp (float) – Alias for field number 0

  2.  yp (float) – Alias for field number 1

  3.  zp (float) – Alias for field number 2

  4.  xr (float) – Alias for field number 3

  5.  yr (float) – Alias for field number 4

  6.  zr (float) – Alias for field number 5

  7.  scale (float) – Alias for field number 6

pack()[source]

Pack the DataItem to bytes.

Return type

bytes

classmethod unpack(raw_bytes)[source]

Unpack bytes for the DataItem.

Parameters

raw_bytes (BytesIO)

Return type

Self

class ONAM(cstring: Union[str, bytes] = b'')[source]

Bases: FormIDRecord

Static.

data

Type:    List[RecordType]

flags

Type:    int

id

Type:    bytes

classmethod parse_subrecords(raw_bytes)[source]

Parse this record’s subrecords.

Parameters

raw_bytes (BytesIO) – Raw bytes for this record’s subrecords

Return type

Iterator[RecordType]

revision

Type:    int

unknown

Type:    bytes

version

Type:    int