# Get Next Unused Town Slot

Grammar — Get the index of the next unused town slot for player player
FlagsNative | Function

Returns the index of the next unused town slot for a player.

# Arguments

  • int — Player

Returns — int

native int AIGetNextUnusedTownSlot(int player);

Category: AI Advanced / Towns / Functions

# Examples

mods/core.sc2modbase.sc2data/TriggerLibs/NativeLib.galaxy:1367

    // Automatic Variable Declarations
    // Implementation
    AIDeclareTown(lp_player, AIGetNextUnusedTownSlot(lp_player), lp_center);
}