This wiki is archived and useful information is being migrated to the main bzflag.org website

Difference between revisions of "Bz removeEvent"

From BZFlagWiki
Jump to: navigation, search
m (added deprecated info)
(Added return value.)
 
Line 1: Line 1:
 
{{apicall
 
{{apicall
 
| name            = bz_removeEvent
 
| name            = bz_removeEvent
 +
| returns        = Whether or not the event was removed successfully.
 +
| returntype      = bool
 
| description    = Removes the specified event listener. The event listener must previously have been added by a call to [[bz_registerEvent]].  
 
| description    = Removes the specified event listener. The event listener must previously have been added by a call to [[bz_registerEvent]].  
 
| param1          = eventType
 
| param1          = eventType

Latest revision as of 05:53, 19 October 2011

bool bz_removeEvent (bz_eEventType eventType, bz_EventHandler* listener)


Removes the specified event listener. The event listener must previously have been added by a call to bz_registerEvent.

Parameters:
eventType  -  The type of event that this listener was previously registered to handle. This is so that if this listener is registered for multiple event types, only one of those will be removed.
listener  -  The listener to remove.
Returns:
Whether or not the event was removed successfully.


Deprecation[edit]

All calls to bz_removeEvent in the bz_Unload have been deprecated as of 2.4 and will be replaced with:

# Flush();

More information on this function can be found on the BZFS_API_2.4_Upgrade page.