data: fix indentation in markdown

master
an 2019-06-12 23:28:15 -04:00
parent 661bc9082f
commit 475aa64138
1 changed files with 162 additions and 162 deletions

View File

@ -7,12 +7,12 @@ unavailable, the link below:
<http://creativecommons.org/publicdomain/zero/1.0/>
All of the information in this Document is original research. Marathon and
Forge are owned by Bungie, Inc. QuickDraw, QuickTime and Macintosh are owned by
Apple. Aleph One (also referred to as A1 in this Document) is owned by Bungie,
Inc. et al. Igni Ferroque, Ferro, and Atque are owned by Gregory Smith
(treellama.) Any other copyrights not mentioned here belong to their respective
owners and not me.
All of the information in this Document is original research. Marathon and Forge
are owned by Bungie, Inc. QuickDraw, QuickTime and Macintosh are owned by Apple.
Aleph One (also referred to as A1 in this Document) is owned by Bungie, Inc. et
al. Igni Ferroque, Ferro, and Atque are owned by Gregory Smith (treellama.) Any
other copyrights not mentioned here belong to their respective owners and not
me.
If you need explanation on anything in this document don't hesitate to ask me.
Contact information is available at <http://greyserv.net>.
@ -168,9 +168,9 @@ Text commands include:
It displays a picture to the specified alignment and text to the other side.
It will:
* Wait for input before proceeding.
* Display 45 characters per line, and display up to 22 lines on one page.
* Display text aligned to the left on the right side of the screen.
- Wait for input before proceeding.
- Display 45 characters per line, and display up to 22 lines on one page.
- Display text aligned to the left on the right side of the screen.
If alignment is specified as RIGHT, text is aligned to the right on the left of
the screen. If alignment is specified as CENTER, no text may be displayed, only
@ -195,13 +195,13 @@ hellote this is example text from durnadle prettiest ai in ever thank u for read
`#LOGON` and `#LOGOFF` are generally used first and last in a terminal.
These two display a PICT in the middle of the screen and text below the image
if you supply it. They both do things to the screen borders.
These two display a PICT in the middle of the screen and text below the image if
you supply it. They both do things to the screen borders.
They will:
* Automatically continue, an input will interrupt it.
* Only display one line of text, at most 72 characters.
* Display text aligned to the center in the middle of the screen.
- Automatically continue, an input will interrupt it.
- Only display one line of text, at most 72 characters.
- Display text aligned to the center in the middle of the screen.
Example:
@ -222,9 +222,9 @@ ehhg.431.4122//<PFGR ZNE6 &49c2>
`#INFORMATION` will just display text, and is mostly used in Marathon 1.
It will:
* Wait for input before proceeding.
* Display 72 characters per line, and display up to 22 lines on one page.
* Display text aligned to the left on the left side of the screen.
- Wait for input before proceeding.
- Display 72 characters per line, and display up to 22 lines on one page.
- Display text aligned to the left on the left side of the screen.
Example:
@ -243,17 +243,17 @@ p.s. if you don't win i'm erasing your home planet from existence
`#CHECKPOINT` may only be used in Marathon 1, unless you're using Aleph One
version 1.1 or higher.
This shows a map centered on the specified goal point, with the goal circled,
on the left of the screen.
This shows a map centered on the specified goal point, with the goal circled, on
the left of the screen.
The map will only show polygons connected to the polygon the goal is in, so if
you have a separated area where the goal point is, it will only display that.
It will also not display secret areas and any polygons proceeding them.
you have a separated area where the goal point is, it will only display that. It
will also not display secret areas and any polygons proceeding them.
It will:
* Wait for input before proceeding.
* Display 45 characters per line, and display up to 22 lines on one page.
* Display text aligned to the left on the right side of the screen.
- Wait for input before proceeding.
- Display 45 characters per line, and display up to 22 lines on one page.
- Display text aligned to the left on the right side of the screen.
Example:
@ -338,8 +338,8 @@ Example:
#SOUND sound_number
```
`#SOUND` plays the specified sound from the Sounds file or from the scenario
and then goes to the next level.
`#SOUND` plays the specified sound from the Sounds file or from the scenario and
then goes to the next level.
Example:
@ -394,12 +394,12 @@ Map tags:
Map files can be identified by the `Minf` chunk.
Maps will always have either a `PNTS` or `EPNT` chunk, depending on what the
map (and editor) use. `PNTS` are plain and have no more information than the
actual position, while `EPNT` can be loaded directly into memory by the engine.
`EPNT` also tells the engine that the map is preprocessed and that `iidx` and
`PLAT` chunks also exist. With `DataVersion` as `DataM1`, the format must
always be preprocessed.
Maps will always have either a `PNTS` or `EPNT` chunk, depending on what the map
(and editor) use. `PNTS` are plain and have no more information than the actual
position, while `EPNT` can be loaded directly into memory by the engine. `EPNT`
also tells the engine that the map is preprocessed and that `iidx` and `PLAT`
chunks also exist. With `DataVersion` as `DataM1`, the format must always be
preprocessed.
Physics tags:
@ -411,9 +411,9 @@ Physics tags:
| `PXpx` | Array of Physics Definition |
| `WPpx` | Array of Weapon Definition |
Physics definitions may be embedded into a map in Infinity and Aleph One, so
the only reliable way to check if something is a pure physics file is by
checking that there are no chunks other than `**px` chunks.
Physics definitions may be embedded into a map in Infinity and Aleph One, so the
only reliable way to check if something is a pure physics file is by checking
that there are no chunks other than `**px` chunks.
Image tags:
@ -484,25 +484,25 @@ The type "`fixed`" refers to a 32-bit fixed point number with the format 15.16s
sign.)
The type "`angle`" refers to a 16-bit fixed point number with the format 0.9s.
This is used for all angles. Because they're actually 16-bit, the real format
is 6.9s, but the integral part is ignored. "No angle" is represented by 65510
This is used for all angles. Because they're actually 16-bit, the real format is
6.9s, but the integral part is ignored. "No angle" is represented by 65510
(-1.9) for some reason.
The type "`unit`" refers to a 16-bit fixed point number with the format 5.10s.
This is used for all world coordinates.
A "`u16opt`" is a 16-bit integer which references something by index. If all
bits are set, it is to be interpreted as "none." Traditionally, these are
signed integers, but they can be treated as unsigned with no repercussions.
bits are set, it is to be interpreted as "none." Traditionally, these are signed
integers, but they can be treated as unsigned with no repercussions.
## Wad ##
### Wad File ###
Wad files are structured like:
* Wad Header
* Entries/Chunks
* Directory
- Wad Header
- Entries/Chunks
- Directory
It *must* be in this order because the engine assumes that the data directly
after the 128th byte is entry data.
@ -539,8 +539,8 @@ If `WadVersion` is greater than or equal to `VerDir`:
- `DirOffset` is the offset to the first Directory Entry structure.
- `NumEntries` is the number of entries in this file.
- `AppDataSize` is the number of bytes to skip for each directory entry.
- `ChunkSize` and `EntrySize` may be zero, in which case they will default to
16 and 10 respectively. They exist for forward compatibility with Wad patching,
- `ChunkSize` and `EntrySize` may be zero, in which case they will default to 16
and 10 respectively. They exist for forward compatibility with Wad patching,
but because they were never actually expanded upon, are useless.
If `WadVersion` is greater than or equal to `VerOver`:
@ -553,8 +553,8 @@ If `WadVersion` is greater than or equal to `VerOver`:
### Directory Entry ###
Directory Entry is 8 bytes if `WadVersion` is `VerBase`, or else `EntrySize +
AppData` bytes. Following this structure is `AppData` bytes, supposed to be
Directory Entry is 8 bytes if `WadVersion` is `VerBase`, or else `EntrySize
+ AppData` bytes. Following this structure is `AppData` bytes, supposed to be
| Name | Type | Offset |
| ---- | ---- | ------ |
@ -579,9 +579,9 @@ ignored by the engine.
### Chunk ###
Chunk is 12 bytes if `WadVersion` is `VerBase`, or `ChunkSize` bytes otherwise.
Most Wad entries are made up of tagged data formats, the engine assumes this
for every entry and so every entry has at least one chunk. These are similar to
IFF or PNG chunks.
Most Wad entries are made up of tagged data formats, the engine assumes this for
every entry and so every entry has at least one chunk. These are similar to IFF
or PNG chunks.
| Name | Type | Offset |
| ---- | ---- | ------ |
@ -638,8 +638,8 @@ Point is 4 bytes. A geometric point.
### Endpoint ###
Endpoint is 16 bytes. A point structure which can be loaded directly into
memory instead of being calculated at runtime.
Endpoint is 16 bytes. A point structure which can be loaded directly into memory
instead of being calculated at runtime.
| Name | Type | Offset |
| ---- | ---- | ------ |
@ -650,8 +650,8 @@ memory instead of being calculated at runtime.
| `Support` | `u16` | `14` |
- `Flags` is an Endpoint Flags bit field.
- `HeightHi` and `HeightLo` are the highest adjacent ceiling and lowest
adjacent floor heights, respectively.
- `HeightHi` and `HeightLo` are the highest adjacent ceiling and lowest adjacent
floor heights, respectively.
- `Position` is a Point structure.
- `Support` is the index of the highest adjacent polygon.
@ -674,8 +674,8 @@ Line is 32 bytes. A geometric line segment.
- `PointBeg` and `PointEnd` are the beginning and terminating endpoints.
- `Flags` is a Line Flags bit field.
- `HeightHi` and `HeightLo` are the highest adjacent ceiling and lowest
adjacent floor heights, respectively.
- `HeightHi` and `HeightLo` are the highest adjacent ceiling and lowest adjacent
floor heights, respectively.
- `SideFrnt` and `SideBack` are indices of the Sides in the front and back.
- `PolyFrnt` and `PolyBack` are indices of the connected Polygons.
@ -717,11 +717,11 @@ respective texture.
### Polygon ###
Polygon is 128 bytes. A geometric polygon, essentially Doom's "sector," but
must be convex. More similar to a "subsector" since you have to split it
yourself and the map compiler will not help you with this process. (It is a
planned feature of Maraiah to allow the user to draw polygons of arbitrary
shape and automatically split them.)
Polygon is 128 bytes. A geometric polygon, essentially Doom's "sector," but must
be convex. More similar to a "subsector" since you have to split it yourself and
the map compiler will not help you with this process. (It is a planned feature
of Maraiah to allow the user to draw polygons of arbitrary shape and
automatically split them.)
Note that `u16opt`s not available with `DataM1` must be set to none.
@ -797,11 +797,10 @@ Light is 100 bytes. If `DataVersion` is `DataM1` this is an Old Light.
### Old Light ###
Old Light is 32 bytes. The old lighting system not only sucked, but there was
no Media system, so it was even more useless as it couldn't be used as a
controller for liquids. So, because of these issues, the new lighting system
was put in place, but it was incompatible data-wise because it had too many
extensions.
Old Light is 32 bytes. The old lighting system not only sucked, but there was no
Media system, so it was even more useless as it couldn't be used as a controller
for liquids. So, because of these issues, the new lighting system was put in
place, but it was incompatible data-wise because it had too many extensions.
| Name | Type | Offset |
@ -965,12 +964,13 @@ Static Map Info is 88 bytes.
| `Name` | `u8[66]` | `18` |
| `EntryFlags` | `u32` | `84` |
- `TextureId` is a Texture Collection enumeration. It is a preset number for texture collections and some other things such as media (liquid) presets.
- `TextureId` is a Texture Collection enumeration. It is a preset number for
texture collections and some other things such as media (liquid) presets.
- `PhysicsId` used to be used for specifying three physics models: one for the
Forge editor, one for the game, and one for low-gravity. However, the first one
ended up being useless and the third was made into a map flag instead which
simply modifies the current physics model. This should always be set to `1` by
new editors.
Forge editor, one for the game, and one for low-gravity. However, the first
one ended up being useless and the third was made into a map flag instead
which simply modifies the current physics model. This should always be set to
`1` by new editors.
- `LandscapeId` is a Landscape enumeration. is the landscape number to use for
the sky. This starts at `0`, since it's an offset into the landscape
collections. If `DataVersion` is `DataM1` or the `Music` flag of `EnvFlags` is
@ -987,18 +987,18 @@ this is `0`, this implies the value is `Solo`.
### Terminal ###
Terminal text can be encoded with some weird xor bullshit for some reason.
You can decode it and encode it with the same method:
Terminal text can be encoded with some weird xor bullshit for some reason. You
can decode it and encode it with the same method:
```c
for(i = 0; i < len / 4; i++) {p += 2; *p++ ^= 0xFE; *p++ ^= 0xED;}
for(i = 0; i < len % 4; i++) *p++ ^= 0xFE;
```
* Terminal Header
* Terminal Groups
* Text Faces
* Terminal text (null byte terminated)
- Terminal Header
- Terminal Groups
- Text Faces
- Terminal text (null byte terminated)
### Terminal Header ###
@ -1286,10 +1286,11 @@ Attack Definition is 16 bytes.
Pictures are formed with a header and then a variable number of operations. In
other words, a small state machine is used to form an image through effects and
various fill instructions. QuickDraw is horrifying. This is the native image
format. It's a fucking metafile.
format. It's a fucking metafile. I suppose this could be worse, considering they
later used PDF files for images.
* Picture Header
* Picture Opcodes
- Picture Header
- Picture Opcodes
### Picture Header ###
@ -1421,14 +1422,14 @@ Header Op is 24 bytes.
## Shapes ##
Shapes files start with exactly 32 Collection Headers, followed by everything
else. Use the offsets provided by these structures to find where all of the
data is.
else. Use the offsets provided by these structures to find where all of the data
is.
### Collection Header ###
Collection Header is 32 bytes. Each collection may have two versions, lo-res
and hi-res, which are used according to the user's settings. The main purpose
of these is for compatibility with older Macs which might not have enough video
Collection Header is 32 bytes. Each collection may have two versions, lo-res and
hi-res, which are used according to the user's settings. The main purpose of
these is for compatibility with older Macs which might not have enough video
memory for, for instance, the huge two mebibyte sky boxes that Marathon 2 has.
| Name | Type | Offset |
@ -1440,11 +1441,11 @@ memory for, for instance, the huge two mebibyte sky boxes that Marathon 2 has.
### Collection Definition ###
Collection Definition is 544 bytes (no, I'm not kidding, there are actually
that many unused bytes.) The sequences, frames and bitmaps have their
individual offsets stored in tables, which themselves are at offsets specified
by this structure. Note that all offsets (including those in offset tables) are
relative to the start of this structure.
Collection Definition is 544 bytes (no, I'm not kidding, there are actually that
many unused bytes.) The sequences, frames and bitmaps have their individual
offsets stored in tables, which themselves are at offsets specified by this
structure. Note that all offsets (including those in offset tables) are relative
to the start of this structure.
| Name | Type | Offset |
| ---- | ---- | ------ |
@ -1467,8 +1468,8 @@ relative to the start of this structure.
offset table.
- `FrmNum` and `FrmOfs` are the number of frames and the offset to their offset
table.
- `BmpNum` and `BmpOfs` are the number of bitmaps and the offset to their
offset table.
- `BmpNum` and `BmpOfs` are the number of bitmaps and the offset to their offset
table.
### Frame ###
@ -1494,8 +1495,7 @@ Frame is 36 bytes. TODO: document how world transform works.
Sequence is 88 bytes. A sequence, also known as a "high level shape" in the
engine, is essentially a potentially animated sequence of frames organized into
angular views which may loop or play sounds. Each sequence has a "key frame"
which is used for determining when to run action code or play an attached
sound.
which is used for determining when to run action code or play an attached sound.
| Name | Type | Offset |
| ---- | ---- | ------ |
@ -1526,8 +1526,8 @@ last frame of this sequence.
Bitmap Header is 26 bytes.
Each Bitmap Header is followed by either `Height * 4` or `Width * 4` empty
bytes which must be skipped.
Each Bitmap Header is followed by either `Height * 4` or `Width * 4` empty bytes
which must be skipped.
| Name | Type | Offset |
| ---- | ---- | ------ |
@ -1608,11 +1608,11 @@ Carbon Sound Header is 21 bytes.
The sound format is from Carbon's `SoundHeader` structures. It's used primarily
in System 7 programs as `snd` resources but in OS X it was deprecated in favor
of QuickTime. HFS still has Resource Forks but they aren't used anymore. I
don't imagine this format was ever used for anything else, except for Marathon,
which embeds it in the Sound files directly, instead of using `snd` resources
(which have a larger structure consisting of a resource header and sound
commands rather than just the header and sample data.)
of QuickTime. HFS still has Resource Forks but they aren't used anymore. I don't
imagine this format was ever used for anything else, except for Marathon, which
embeds it in the Sound files directly, instead of using `snd` resources (which
have a larger structure consisting of a resource header and sound commands
rather than just the header and sample data.)
| Name | Type | Offset |
| ---- | ---- | ------ |
@ -1633,8 +1633,8 @@ actually used by Marathon.
Carbon Extended Sound Header is 42 bytes.
The extended sound header contains more useless information and even several
fields that do absolutely nothing. Wow. At least it can store 16 bit samples.
It also has an 80-bit float in it, which horrifies me greatly. There's only one
fields that do absolutely nothing. Wow. At least it can store 16 bit samples. It
also has an 80-bit float in it, which horrifies me greatly. There's only one
actually useful field.
| Name | Type | Offset |
@ -1645,8 +1645,8 @@ actually useful field.
- `Frames` is used instead of `Size` for sounds with this header, since it
represents how many frames there are rather than how many bytes. Even though
this is actually a pointless distinction and `Size` is left at `1` anyway.
- `SampleBits` must be either `16` or `8`. If it is `16` then the sample data
is signed 16-bit *little endian* mono PCM.
- `SampleBits` must be either `16` or `8`. If it is `16` then the sample data is
signed 16-bit *little endian* mono PCM.
# ENUMERATIONS ################################################################
@ -1970,11 +1970,11 @@ Sound behaviours are used to determine falloff and volume bounds of a sound.
| `Normal` | `1` |
| `Loud` | `2` |
- `Quiet` sounds will not be heard at all when obstructed, and only play at
full volume point-blank. They fall off very quickly, with a range of only 5
world units.
- `Normal` sounds will be heard at at most half volume when obstructed, and
fall off at 10 world units unobstructed.
- `Quiet` sounds will not be heard at all when obstructed, and only play at full
volume point-blank. They fall off very quickly, with a range of only 5 world
units.
- `Normal` sounds will be heard at at most half volume when obstructed, and fall
off at 10 world units unobstructed.
- `Loud` sounds will be heard at 3/4 volume when obstructed and can be heard at
full volume for twice the distance as a normal sound, and fall off at 15 units
unobstructed.
@ -2105,8 +2105,8 @@ over for editor preset usage.
| `Transparent` | `2` |
- `Solid` means the point belongs to a solid line.
- `SameHeight` means all polygons with this point have the same height,
relative to the point's lines
- `SameHeight` means all polygons with this point have the same height, relative
to the point's lines
- `Transparent` means the point does not belong to an opaque line.
### Line Flags ###