bz_eAllowServerShotFiredEvent
This event is called before a world weapon is fired. This event can disallow a world weapon from firing and it can change the shot type, similar to bz_eShotFiredEvent.
Data Object Type
2.4.14 bz_AllowServerShotFiredEventData_V1
Parameters
These are the values accessible in the bz_EventData variable that's made available in the Event method.
| Data Type | Name | Description | 
|---|---|---|
| bool | 
                            allow
                         | 
                        
                             True to allow a server shot to be fired  | 
                    
| bool | 
                            changed
                         | 
                        
                             Set this to true if you'd like to change the   | 
                    
| bz_ApiString | 
                            flagType
                         | 
                        
                             The flag abbreviation of the shot type that was fired  | 
                    
| float | 
                            speed
                         | 
                        
                             The speed of the shot fired  | 
                    
| float[3] | 
                            pos
                         | 
                        
                             The position of where the shot was fired (x, y, z coordinates)  | 
                    
| float[3] | 
                            velocity
                         | 
                        
                             The vector of the shot's direction multiplied by the shot's speed  | 
                    
| bz_eTeamType | 
                            team
                         | 
                        
                             The team this shot belongs to  | 
                    
| double | 
                            eventTime
                         | 
                        
                             This value is the local server time of the event.  | 
                    
Plug-in Usage
There are no plug-ins in the official distribution that make use of this event. Browse the Plug-in Releases forum for plug-ins which may make 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_AllowServerShotFiredEventData_V1* dataObject = (bz_AllowServerShotFiredEventData_V1*)eventData;
// Data
// ---
// (bool)         allow - True to allow a server shot to be fired
// (bool)         changed - Set this to true if you'd like to change the `flagType` of the server shot
// (bz_ApiString) flagType - The flag abbreviation of the shot type that was fired
// (float)        speed - The speed of the shot fired
// (float[3])     pos - The position of where the shot was fired (x, y, z coordinates)
// (float[3])     velocity - The vector of the shot's direction multiplied by the shot's speed
// (bz_eTeamType) team - The team this shot belongs to
// (double)       eventTime - This value is the local server time of the event.    
    Other Shots Events
This content is maintained on GitHub. We welcome any feedback and improvements!