# APM Of Difficulty Level

Grammar — Actions Per Minute for difficulty level difficulty
FlagsNative | Function

Returns the actions per minute for the difficulty level specified.

# Arguments

  • int<difficulty> — Difficulty

Returns — int

native int DifficultyAPM(int inDifficulty);

Category: Player / Difficulty Levels

# Examples

mods/core.sc2modbase.sc2data/TriggerLibs/BaseAI.galaxy:107

    int attackersLimit;

	AIStart(player, false, DifficultyAPM(diff));

    if (diff == c_skirChInsane) {

mods/core.sc2modbase.sc2data/TriggerLibs/BaseAI.galaxy:244

    int diff = AIPlayerDifficulty(player);
    
    AIStart(player, true, DifficultyAPM(diff));
    AIDeclareTown(player, c_townOne, PlayerStartLocation(player));
    AISetMainTown(player, c_townOne);

mods/starcoop/starcoop.sc2modbase.sc2data/TriggerLibs/BaseAI.galaxy:143

    int attackersLimit;

	AIStart(player, false, DifficultyAPM(diff));

    if (diff == c_skirChInsane) {

mods/starcoop/starcoop.sc2modbase.sc2data/TriggerLibs/BaseAI.galaxy:287

    int attackersLimit;
    
    AIStart(player, true, DifficultyAPM(diff));
	AIDeclareTown(player, c_townOne, PlayerStartLocation(player));
    AISetMainTown(player, c_townOne);