# Set Camera Bounds

Grammar — Set the camera bounds for players to bounds (minimap|Do/Do Not adjust the minimap)
FlagsNative | Action

Sets the camera bounds within a region. This will limit the specified Players from moving their camera beyond the specified Bounds. If the Minimap parameter is set to Do, the minimap will also shrink to fit the camera bounds. This is useful for hiding things off map, or having the playable area expand at some point during your map.

# Arguments

  • playergroup — Players
  • region — Bounds
  • bool [ preset::Do_Do_Not_Option ] — Minimap

Returns — void

native void CameraSetBounds(
	playergroup players,
	region bounds,
	bool includeMinimap,
);

Category: Camera / Camera Tricks

# Examples

# campaigns/liberty.sc2campaign

MapScript.galaxy

// L2495
CameraSetBounds(PlayerGroupAll(), lv_bounds, true)
// L1008
CameraSetBounds(PlayerGroupAll(), RegionRect(128.0, 2.0, 256.0, 195.0), true)
// L12448
CameraSetBounds(PlayerGroupAll(), RegionRect(17.0, 12.0, 128.0, 203.0), true)
// L1139
CameraSetBounds(PlayerGroupAll(), RegionPlayableMap(), true)
// L1996
CameraSetBounds(PlayerGroupAll(), RegionFromId(17), true)
// L2682
CameraSetBounds(PlayerGroupAll(), RegionFromId(25), true)
// L3206
CameraSetBounds(PlayerGroupAll(), RegionFromId(21), true)
// L3427
CameraSetBounds(PlayerGroupAll(), RegionFromId(11), true)
// L3686
CameraSetBounds(PlayerGroupAll(), RegionFromId(58), true)
// L4084
CameraSetBounds(PlayerGroupAll(), RegionFromId(8), true)
// L4533
CameraSetBounds(PlayerGroupAll(), RegionFromId(8), true)
// L5097
CameraSetBounds(PlayerGroupAll(), RegionFromId(8), true)
// L5680
CameraSetBounds(PlayerGroupAll(), RegionFromId(23), true)
// L4519
CameraSetBounds(gv_fORCEGOOD_GUYS, gv_mapAreaNormal, true)
// L6076
CameraSetBounds(gv_fORCEGOOD_GUYS, gv_mapAreaNormal, true)
// L9751
CameraSetBounds(PlayerGroupAll(), RegionFromId(3), true)
// L9761
CameraSetBounds(PlayerGroupAll(), RegionFromId(3), true)
// L557
CameraSetBounds(PlayerGroupAll(), RegionFromId(19), true)
// L826
CameraSetBounds(PlayerGroupAll(), RegionPlayableMap(), true)
// L492
CameraSetBounds(PlayerGroupAll(), RegionPlayableMap(), true)
// L660
CameraSetBounds(PlayerGroupAll(), RegionPlayableMap(), true)
// L1838
CameraSetBounds(PlayerGroupAll(), RegionPlayableMap(), true)
// L2495
CameraSetBounds(PlayerGroupAll(), lv_bounds, true)
// L1008
CameraSetBounds(PlayerGroupAll(), RegionRect(128.0, 2.0, 256.0, 195.0), true)
// L12448
CameraSetBounds(PlayerGroupAll(), RegionRect(17.0, 12.0, 128.0, 203.0), true)
// L1139
CameraSetBounds(PlayerGroupAll(), RegionPlayableMap(), true)
// L1996
CameraSetBounds(PlayerGroupAll(), RegionFromId(17), true)
// L2682
CameraSetBounds(PlayerGroupAll(), RegionFromId(25), true)
// L3206
CameraSetBounds(PlayerGroupAll(), RegionFromId(21), true)
// L3427
CameraSetBounds(PlayerGroupAll(), RegionFromId(11), true)
// L3686
CameraSetBounds(PlayerGroupAll(), RegionFromId(58), true)
// L4084
CameraSetBounds(PlayerGroupAll(), RegionFromId(8), true)
// L4533
CameraSetBounds(PlayerGroupAll(), RegionFromId(8), true)
// L5097
CameraSetBounds(PlayerGroupAll(), RegionFromId(8), true)
// L5680
CameraSetBounds(PlayerGroupAll(), RegionFromId(23), true)
// L4519
CameraSetBounds(gv_fORCEGOOD_GUYS, gv_mapAreaNormal, true)
// L6076
CameraSetBounds(gv_fORCEGOOD_GUYS, gv_mapAreaNormal, true)
// L9751
CameraSetBounds(PlayerGroupAll(), RegionFromId(3), true)
// L9761
CameraSetBounds(PlayerGroupAll(), RegionFromId(3), true)
// L557
CameraSetBounds(PlayerGroupAll(), RegionFromId(19), true)
// L826
CameraSetBounds(PlayerGroupAll(), RegionPlayableMap(), true)
// L492
CameraSetBounds(PlayerGroupAll(), RegionPlayableMap(), true)
// L660
CameraSetBounds(PlayerGroupAll(), RegionPlayableMap(), true)
// L1838
CameraSetBounds(PlayerGroupAll(), RegionPlayableMap(), true)
// L3806
CameraSetBounds(PlayerGroupAll(), RegionEntireMap(), true)
// L4532
CameraSetBounds(PlayerGroupAll(), RegionFromId(2), true)
// L5716
CameraSetBounds(PlayerGroupAll(), RegionEntireMap(), true)
// L5743
CameraSetBounds(PlayerGroupAll(), RegionFromId(7), true)
// L8726
CameraSetBounds(PlayerGroupAll(), RegionFromId(8), true)
// L9756
CameraSetBounds(PlayerGroupAll(), RegionEntireMap(), true)
// L9788
CameraSetBounds(PlayerGroupAll(), RegionFromId(1), true)
// L14385
CameraSetBounds(PlayerGroupAll(), RegionFromId(3), true)
// L15580
CameraSetBounds(PlayerGroupAll(), RegionEntireMap(), true)
// L15611
CameraSetBounds(PlayerGroupAll(), RegionFromId(9), true)
// L3806
CameraSetBounds(PlayerGroupAll(), RegionEntireMap(), true)
// L4532
CameraSetBounds(PlayerGroupAll(), RegionFromId(2), true)
// L5716
CameraSetBounds(PlayerGroupAll(), RegionEntireMap(), true)
// L5743
CameraSetBounds(PlayerGroupAll(), RegionFromId(7), true)
// L8726
CameraSetBounds(PlayerGroupAll(), RegionFromId(8), true)
// L9756
CameraSetBounds(PlayerGroupAll(), RegionEntireMap(), true)
// L9788
CameraSetBounds(PlayerGroupAll(), RegionFromId(1), true)
// L14385
CameraSetBounds(PlayerGroupAll(), RegionFromId(3), true)
// L15580
CameraSetBounds(PlayerGroupAll(), RegionEntireMap(), true)
// L15611
CameraSetBounds(PlayerGroupAll(), RegionFromId(9), true)

# mods/heroesdata.stormmod

GameLib.galaxy

// L1183
CameraSetBounds(libCore_gv_playerGroupFromPlayer[lp_player], libGame_gv_cameraBound_Regions[lp_boundsIndex], true)
// L1201
CameraSetBounds(libCore_gv_playerGroupFromPlayer[lp_player], lp_bound, true)