Returns the difficulty level of the player's AI.

Format: AILevel

Arguments:

Return type: int

Error conditions: none

Details:

If AI is enabled on the player, the value ranges from 1 (easiest) to 8 (most difficult). If AI is not enabled on the player, the return value is 0.

Example:

trigger1 = Random < AILevel * 10
; Triggers with 10% probability at AILevel 1, 20% at AILevel 2, etc.