EjectCasing

From Eternity Wiki
Jump to navigationJump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

Description

Spawns bullet casing objects from map object's position.

Usage

EjectCasing(frontdist, sidedist, zheight, thingtype)

Parameters

  • frontdist: distance in front in 16ths of a unit
  • sidedist: distance from middle in 16ths of a unit (negative = left)
  • zheight: z height relative to player's viewpoint in 16ths of a unit
  • thingtype: thingtype to toss

Examples

No examples given.

Notes

This codepointer can be called both from player weapon sprites and regular map objects. If the caller is a player, the z height will be offset with the viewheight and adjusted according to the view pitch. If it's called from any other thing type, the z height will be relative to the origin (ground level).

The thing type is not restricted to bullet casing nonsolid objects, but at spawn time it will not be checked whether it's blocked, possibly remaining stuck in walls.

The spawned object will have no velocity set up, but can be given momentum using the CasingThrust codepointer.

See also