SC2Mapster.com Wiki

SC2 API / Functions / PlayerStartLocation

PlayerStartLocation

point PlayerStartLocation(int player);

Start location point of the player with the id parameter.

Parameters

int player

ID of the player.

Return value

point - Location where the player starts out at.

Examples

Example: Usage
// This will add a town to the player with the start location.
AIDeclareTown(player, c_townOne, PlayerStartLocation(player));

// Get a region around the unit
region r = RegionCircle(PlayerStartLocation(player), 10);

// Get a unit group around the unit
unitgroup = AIFindUnits(player, null,
                        PlayerStartLocation(player), 10, c_noMaxCount);

// Use the position as an order target
OrderSetTargetPoint(ord, PlayerStartLocation(player));

You must login to post a comment. Don't have an account? Register to get one!

Facts

Date created
Mar 13, 2010
Last updated
Mar 13, 2010