SpawnBlood
Jump to navigation
Jump to search
native Actor SpawnBlood (Vector3 pos1, double dir, int damage)
Usage
Spawns the calling actor's Blood actor, as if it was damaged. This function respects the BloodType property.
Blood behavior is still largely hardcoded in GZDoom, so the internals of this function are not exposed to ZScript at all. The function performs a series of checks, such as checking the BloodType, the game type, applying BloodColor and such.
Parameters
- Vector3 pos1
- The position of where the attack came from. This is normally assumed to be the position of the projectile or puff actor used by the attack.
- double dir
- The absolute angle direction of where the attack came from. (Verification needed)
- int damage
- The presumed damage of the attack. This does not deal any actual damage; this value is only used to determine which state the animation of the spawned blood actor should begin at:
- 13 damage or above — begins at the 1st state from the top of Spawn
- 9-12 damage — begins at the 2nd state
- 8 or less — begins at the 3rd state
Return value
Returns a pointer to the spawned blood actor. (New from 4.14.2)
Examples
![]() |
Note: This article lists no examples. If you make use of this feature in your own project(s) or know of any basic examples that could be shared, please add them. This will make it easier to understand for future authors seeking assistance. Your contributions are greatly appreciated. |