Skip to main content
Client Runs in your resource.

Zone

Common options: onEnter(zone), onExit(zone), inside(zone) (every frame while inside), debug (draws the outline), data.
  • A box is centered on coords: size.x is the width, size.y the length, size.z the height, heading in degrees. minZ and maxZ replace the height.
  • A poly takes 3 to 256 points and has no height limit unless minZ or maxZ is set.
  • A zone has id, shape, data, isInside, enabled, and zone:Remove(), zone:Contains(coords), zone:SetEnabled(enabled). Removing or disabling a zone the player is in calls onExit.
Zones are checked every settings.zoneInterval ms (default 250), and every frame only while an inside or debug zone needs it.

Point

A point is a sphere that knows how far the player is: point.currentDistance. nearby(point) runs every frame while inside, closest point first.

Example

client.lua