Skip to content

TE_BLOODSPRITE

wootguy edited this page Nov 29, 2025 · 4 revisions

A downward spray of sprites with an animated sprite in the center.

Parameters

Type Name Description
Vector pos Center point of the effect
const char* sprite1 Animated sprite in the center (alpha transparency)
const char* sprite2 Animated sprites sprayed down from the center point (alpha transparency)
uint8_t RGBA Sprite RGBA (index in [Engine Pallete #1](Temporary-Entities#engine-pallete-1))
uint8_t scale Sprite scale * 0.1

Example Usage

void te_bloodsprite(Vector pos, const char* sprite1="sprites/bloodspray.spr",
    const char* sprite2="sprites/blood.spr", uint8_t RGBA=70, uint8_t scale=3,
    int msgType=MSG_BROADCAST, edict_t* dest=NULL)
{
    MESSAGE_BEGIN(msgType, SVC_TEMPENTITY, dest);
    WRITE_BYTE(TE_BLOODSPRITE);
    WRITE_COORD(pos.x);
    WRITE_COORD(pos.y);
    WRITE_COORD(pos.z);
    WRITE_SHORT(MODEL_INDEX(sprite1));
    WRITE_SHORT(MODEL_INDEX(sprite2));
    WRITE_BYTE(RGBA);
    WRITE_BYTE(scale);
    MESSAGE_END();
}

Clone this wiki locally