Page 1 of 1

API changes to BZFS

Posted: Thu Jul 18, 2019 7:25 pm
by Zehra
Currently the API provides quite a bunch of notification and modification events.
While normally this is not a cause of concern, it does pose quite an issue when dealing with multiple plug-ins, especially if data is modified.

I'll provide the three most common events in this example:
The death event, the flag transferred event, and the shot fired event.

The death event provides a modification and a notification event upon a player death.
However the lack of a final state made it quite tricky to track the last death and it could easily be incorrect if another plug-in modified the event at a later time.
The introduction of the death finalized event did resolve this issue quite nicely.

For the secondary event, the flag transferred event will be used.
It is both a notification and modification event.
Simply using the thiefControl plug-in and if another plug-in uses the event as a notification upon steal, it can easily cause the plug-in to improperly function.
This causes it to be somewhat difficult to be able to properly track flags.
(Self-written solutions are generally required to work-around said issue or merging plug-ins.)

For the third event, shot fired event.
If a shot is fired, it can be modified and this can cause inaccuracies if actions or notifications based on shots fired is being done and they are modified.
This can easily cause a plug-in to malfunction or confuse a plug-in enough to function improperly.
Merging plug-ins or updating them has been one work-around for this.

Requesting that changes be made for the next major release within the API.

-Zehra