sm.ai.getClosestVisibleTeamOpponent

Returns the character, with an opposing color, closest to the unit.

Kind: Function

Environments: Game

Game

sm.ai.getClosestVisibleTeamOpponent( unit, color )

Open the full Game reference

Parameters:

Name Type Description
unit Unit The unit.
color Color The color.

Returns:

Type Description
Character The character.