Jump to content

AWARDCHECK REFUEL

From CMM Wiki
Return to CMM Command Reference
Environment: Mission Scripting
Function: AWARDCHECK_REFUEL
Function Description: Checks if a player earned a refueling bonus during a sortie by measuring the time between the start of refueling and its end, awarding the bonus if it exceeds 30 seconds and the player hasn't already received it.
File Location: cmm.XpFunctions.lua
Syntax: CMM.AWARDCHECK_REFUEL( table EventData )
Return Value:
Parameters: Name Description
EventDataEvent table from a refueling stopped event containing initiator, time, and position; used to determine the duration of refueling and trigger award logic.
Example: CMM.AWARDCHECK_REFUEL({initiator = 12345, time = 1640995200})
Example Description: Processes a refueling stop event to verify if the refueling duration exceeds 30 seconds and awards a bonus if valid, otherwise notifies the player that the bonus was already earned.
Related Functions:
Notes: --TODO Code review required