Class Block
Namespace: ValveResourceFormat
Assembly: ValveResourceFormat.dll
Represents a block within the resource file.
public abstract class BlockInheritance
Derived
BinaryKV1, BinaryKV3, ChoreoSceneFileData, KeyValuesOrNTRO, Map, NTRO, Panorama, ParticleSnapshot, Plaintext, RawBinary, ResourceExtRefList, ResourceManifest, ResponseRules, SboxShader, Sound, SoundStackScript, Texture, UnknownDataBlock, VBIB, VoxelVisibility
Extension Methods
ResourceDataExtensions.AsKeyValueCollection(Block)
Properties
Offset
Gets or sets the offset to the data.
public uint Offset { get; set; }Property Value
Resource
Gets the resource this block belongs to.
public required Resource Resource { get; set; }Property Value
Remarks
Can technically be null if constructed outside of a .
Size
Gets or sets the data size.
public uint Size { get; set; }Property Value
Type
Gets the block type.
public abstract BlockType Type { get; }Property Value
Methods
Read(BinaryReader)
Reads the block data from a binary reader.
public abstract void Read(BinaryReader reader)Parameters
reader BinaryReader
The binary reader to read from.
Serialize(Stream)
Writes the binary representation of the object to Stream.
public abstract void Serialize(Stream stream)Parameters
stream Stream
Stream.
ToString()
Returns a string that represents the current object.
public override string ToString()Returns
A string that represents the current object.
WriteText(IndentedTextWriter)
Writes the correct text dump of the object to IndentedTextWriter.
public abstract void WriteText(IndentedTextWriter writer)Parameters
writer IndentedTextWriter
IndentedTextWriter.

