Difference between revisions of "Script/LogicCallbacks"

From SF3
Jump to: navigation, search
Line 9: Line 9:
 
| style='color: blue; width: 10%; text-align:right;line-height: 0.8;' | [[../BasicDataTypes|bool]]  
 
| style='color: blue; width: 10%; text-align:right;line-height: 0.8;' | [[../BasicDataTypes|bool]]  
 
| style='color: black; width: 90%; line-height: 0.8;' | '''TOnInventoryEvent''' (const [[../BasicDataTypes|string]]&in ''_sItemName'', const [[../BasicDataTypes|uint]] ''_uAmount'')
 
| style='color: black; width: 90%; line-height: 0.8;' | '''TOnInventoryEvent''' (const [[../BasicDataTypes|string]]&in ''_sItemName'', const [[../BasicDataTypes|uint]] ''_uAmount'')
 +
|-
 +
| style='color: blue; width: 10%; text-align:right;line-height: 0.8;' | [[../BasicDataTypes|bool]]
 +
| style='color: black; width: 90%; line-height: 1.0;' | '''TOnCreatureInventoryEvent''' ([[../Creature|Creature]]&in ''_Creature'', const [[../BasicDataTypes|string]]&in ''_sItemName'', const [[../BasicDataTypes|uint]] ''_uAmount'')
 
|-
 
|-
 
| style='color: blue; width: 10%; text-align:right;line-height: 0.8;' | [[../BasicDataTypes|bool]]  
 
| style='color: blue; width: 10%; text-align:right;line-height: 0.8;' | [[../BasicDataTypes|bool]]  

Revision as of 14:31, 29 March 2017

Callback Function Signatures

Below is a list of function signatures used to register event callbacks. All callback functions must return true if they want to be unregistered and false if they wish to be called again the next time the respective event occurs.

bool TOnHeroPartyEvent (Creature&in _Creature)
bool TOnInventoryEvent (const string&in _sItemName, const uint _uAmount)
bool TOnCreatureInventoryEvent (Creature&in _Creature, const string&in _sItemName, const uint _uAmount)
bool TOnCreatureEvent (Creature&in _Creature)
bool TOnBuildingEvent (Building&in _Building)
bool TOnBuildingCreatureEvent (Building&in _Building, Creature[]&in _Creatures)
bool TOnSectorEvent (Sector@ _Sector, const uint8 _uPreviousOwnerFaction, const uint8 _uNewOwnerFaction)
bool TOnUIEvent ()
bool TOnUIEntityEvent (Entity&in _Entity)
bool TOnTimerEvent ()

Callback Function Signatures

Below is a list of function signatures used to register event callbacks. All callback functions must return true if they want to be unregistered and false if they wish to be called again the next time the respective event occurs.

bool TOnHeroPartyEvent (Creature&in _Creature)
bool TOnInventoryEvent (const string&in _sItemName, const uint _uAmount)
bool TOnCreatureEvent (Creature&in _Creature)
bool TOnBuildingEvent (Building&in _Building)
bool TOnBuildingCreatureEvent (Building&in _Building, Creature[]&in _Creatures)
bool TOnSectorEvent (Sector@ _Sector, const uint8 _uPreviousOwnerFaction, const uint8 _uNewOwnerFaction)
bool TOnUIEvent ()
bool TOnUIEntityEvent (Entity&in _Entity)
bool TOnTimerEvent ()