Versions in this module Expand all Collapse all v0 v0.5.1 Jan 15, 2023 Changes in this version + const BlockSize + const ChunkBufferSize + const ChunkSize + var Alpha = chunked.ID("MCAL") + var BlockHeader = chunked.ID("MHDR") + var Chunk = chunked.ID("MCNK") + var CollisionObjects = chunked.ID("MCRF") + var DefaultMap = MapParam + var DoodadDefs = chunked.ID("MDDF") + var Heights = chunked.ID("MCVT") + var Layer = chunked.ID("MCLY") + var Liquids = chunked.ID("MCLQ") + var MainTileIndex = chunked.ID("MAIN") + var MapChunkInfo = chunked.ID("MCIN") + var MapIndexHeader = chunked.ID("MPHD") + var MapModelFilenamesOffsets = chunked.ID("MMID") + var MapModels = chunked.ID("MMDX") + var MapObject = chunked.ID("MWMO") + var MapObjectDefs = chunked.ID("MODF") + var MapObjectFilenameOffsets = chunked.ID("MWID") + var MapTextures = chunked.ID("MTEX") + var MapVersion = chunked.ID("MVER") + var Normals = chunked.ID("MCNR") + var ShadowMap = chunked.ID("MCSH") + var SoundEmitters = chunked.ID("MCSE") + func CalcBlockCornerPos(m *MapParam, bi BlockIndex) (pos tempest.C2Vector, err error) + type BlockIndex tempest.C2iVector + func CalcBlockIndex(m *MapParam, pos tempest.C2Vector) (bi BlockIndex, err error) + type ChunkAlphaMap [64 * 64]byte + type ChunkData struct + AlphaMaps []ChunkAlphaMap + CollisionDoodads []uint32 + CollisionWMOs []uint32 + Heights [ChunkBufferSize]float32 + Layer []ChunkLayer + Liquids ChunkLiquids + Normals [ChunkBufferSize][3]byte + NormalsPad [13]byte + OldSoundEmitters []ChunkOldSoundEmitter + ShadowMap [64]uint64 + type ChunkHeader struct + AreaID uint32 + Flags uint32 + Holes uint16 + IndexX uint32 + IndexY uint32 + NumDoodadRefs uint32 + NumEffectDoodad [8]byte + NumLayers uint32 + NumMapObjRefs uint32 + NumSndEmitters uint32 + OffsetAlpha uint32 + OffsetHeight uint32 + OffsetLayer uint32 + OffsetLiquid uint32 + OffsetMCCV uint32 + OffsetNormal uint32 + OffsetRefs uint32 + OffsetShadow uint32 + OffsetSndEmitters uint32 + Pad0 uint16 + Position tempest.C3Vector + PredTex [8]uint16 + SizeAlpha uint32 + SizeLiquid uint32 + SizeShadow uint32 + Unused1 uint32 + Unused2 uint32 + type ChunkIndex tempest.C2iVector + func CalcChunkIndex(m *MapParam, pos tempest.C2Vector) (ci ChunkIndex, err error) + type ChunkInfo struct + Flags uint32 + Offset uint32 + Pad uint32 + Size uint32 + type ChunkLayer struct + EffectID uint16 + Flags uint32 + OffsetAlpha uint32 + Pad uint16 + TextureID uint32 + type ChunkLiquids struct + FlowValues [2]struct{ ... } + MaxHeight float32 + MinHeight float32 + NumFlowValues uint32 + Tiles [8 * 8]byte + Verts [9 * 9]struct{ ... } + type ChunkOldSoundEmitter struct + CutoffDistance float32 + EndTime uint16 + GroupSilenceMax uint16 + GroupSilenceMin uint16 + InterSoundGapMax uint16 + InterSoundGapMin uint16 + LoopCountMax byte + LoopCountMin byte + MaxDistance float32 + MinDistance float32 + Mode uint16 + PlayInstancesMax uint16 + PlayInstancesMin uint16 + Position tempest.C3Vector + SoundNameID uint32 + SoundPointID uint32 + StartTime uint16 + type Dir struct + Location string + func (d *Dir) Exists(at string) bool + func (d *Dir) ReadFile(at string) (io.ReadCloser, error) + type DoodadDef struct + Flags uint16 + NameID uint32 + Position tempest.C3Vector + Rotation tempest.C3Vector + Scale uint16 + UniqueID uint32 + type HeaderFlags uint32 + const ADTHasBigAlpha + const ADTHasMCCV + const WDTUsesGlobalWMO + type Index struct + HeaderFlags HeaderFlags + Tiles [64 * 64]TileIndex + Version uint32 + type MapBlock struct + ChunkData [16][16]*ChunkData + ChunkInfo [16 * 16]ChunkInfo + DoodadDefs []DoodadDef + Flags uint32 + MapModelFilenameOffsets []uint32 + MapModels []byte + MapObjectDefs []WMODef + MapObjectFilenameOffsets []uint32 + MapObjects []byte + Textures []string + Version uint32 + type MapParam struct + BlockSize tempest.C2iVector + type MapReader struct + Name string + func NewMapReader(src Source, build vsn.Build, name string) (*MapReader, error) + func (mr *MapReader) ReadBlock(x, y int) (*MapBlock, error) + type Source interface + Exists func(at string) bool + ReadFile func(at string) (io.ReadCloser, error) + type TileFlags uint64 + const TileHasTerrain + type TileIndex struct + Flags TileFlags + type WMODef struct + DoodadSet uint16 + Extent tempest.CAaBox + Flags uint16 + NameID uint32 + NameSet uint16 + Position tempest.C3Vector + Rotation tempest.C3Vector + Scale uint16 + UniqueID uint32