Skip to Content

bz_eShotFiredEvent

This event is called each time a shot is fired

Data Object Type

2.4.0 bz_ShotFiredEventData_V1

Parameters

These are the values accessible in the bz_EventData variable that's made available in the Event method.

Data Type Name Description
int playerID

ID of the player that fired the shot

int shotID

(UNUSED) Value exists, however it is never set.

bool changed

Whether or not the shot has been modified. Shot type will not change unless this is set to 1 (true).

float[3] pos

Where the shot was fired

bz_ApiString type

The shot type. This is the abbreviation, such as "PZ" or "SW"

double eventTime

This value is the local server time of the event.

Plug-in Usage

Here's a list of plug-ins part of the official distribution that makes use of this event:

Plug-in Example

This block of code can be used to get started when implementing the Event() function of your plug-in.

bz_ShotFiredEventData_V1* dataObject = (bz_ShotFiredEventData_V1*)eventData;

// Data
// ---
// (int)          playerID - ID of the player that fired the shot
// (int)          shotID - (UNUSED) Value exists, however it is never set.
// (bool)         changed - Whether or not the shot has been modified. Shot type will not change unless this is set to 1 (true).
// (float[3])     pos - Where the shot was fired
// (bz_ApiString) type - The shot type. This is the abbreviation, such as "PZ" or "SW"
// (double)       eventTime - This value is the local server time of the event.

Other Shots Events

Back to bzfs API Events

This content is maintained on GitHub. We welcome any feedback and improvements!

Give us Feedback Edit this Page