shader (abstract tag)

🚧 This article is a stub. You can help expand it by submitting content in pull requests or issues in this wiki's source repo.

Shader tags define the visual appearance of models in the game world. The shader tag class itself is abstract and cannot be created directly, but is extended by the various child shader types like shader_model and shader_environment.

Structure and fields #

Field Type Comments
shader flags bitfield(16)
Flag Mask Comments
simple parameterization 0x1

Causes lightmap UVs for this material to be based on existing texture UVs rather than generated completely anew by Tool/Sapien. This can be used to fix squiggly or jagged shadowing artifacts often seen on large complex surfaces using a single material.

ignore normals 0x2
transparent lit 0x4
detail level enum
Option Value Comments
high 0x0
medium 0x1
low 0x2
turd 0x3
power f32
color of emitted light
  • red: f32
  • green: f32
  • blue: f32
tint color
  • red: f32
  • green: f32
  • blue: f32
physics flags bitfield(16)
Flag Mask Comments
unused 0x1
material type enum
Option Value Comments
dirt 0x0
sand 0x1
stone 0x2
snow 0x3
wood 0x4
metal hollow 0x5
metal thin 0x6
metal thick 0x7
rubber 0x8
glass 0x9
force field 0xa
grunt 0xb
hunter armor 0xc
hunter skin 0xd
elite 0xe
jackal 0xf
jackal energy shield 0x10
engineer skin 0x11
engineer force field 0x12
flood combat form 0x13
flood carrier form 0x14
cyborg armor 0x15
cyborg energy shield 0x16
human armor 0x17
human skin 0x18
sentinel 0x19
monitor 0x1a
plastic 0x1b
water 0x1c
leaves 0x1d
elite energy shield 0x1e
ice 0x1f
hunter shield 0x20
shader type enum (little endian?)
  • This field's value may change at build time or have precision errors. It should not be used for exact comparisons between tag data.
Option Value Comments
unkn0 0x0
unkn1 0x1
unkn2 0x2
shader environment 0x3
shader model 0x4
shader transparent generic 0x5
shader transparent chicago 0x6
shader transparent chicago extended 0x7
shader transparent water 0x8
shader transparent glass 0x9
shader transparent meter 0xa
shader transparent plasma 0xb

This information was partially generated using Invader tag definitions.


Thanks to the following individuals for their research or contributions to this topic:

  • Kavawuvi (Invader tag definitions)
  • MosesOfEgypt (Tag structure research)