Miz.CheckAirFrame
Appearance
| Environment: | Mission Scripting | |
|---|---|---|
| Function: | Miz.CheckAirFrame | |
| Function Description: | Checks if a player's airframe is compatible with a specified mission type by comparing the airframe's cargo capacity against the mission's required cargo type. Returns true if the airframe has sufficient cargo capacity, otherwise returns false. Logs informational messages for errors or successful matches. | |
| File Location: | cmm.sideMissionFunctions.lua | |
| Syntax: | CMM.Miz.CheckAirFrame( object playerObject , string MissionType ) | |
| Return Value: | boolean | |
| Parameters: | Name | Description |
| playerObject | Player object to retrieve the airframe type from, must have a getTypeName method. | |
| MissionType | The mission type string, case-insensitive, used to determine cargo requirements from sidequest data. | |
| Example: | CMM.Miz.CheckAirFrame(player, "CargoMission") | |
| Example Description: | Verifies that the player's airframe has the required cargo capacity for a cargo mission, returning true if valid and logging the match details. | |
| Related Functions: | ||
| Notes: | ||