> ## Documentation Index
> Fetch the complete documentation index at: https://luau.limerence.biz/llms.txt
> Use this file to discover all available pages before exploring further.

# Overview

> api.world: the current map (Bloxstrike, Rivals, Overkill, Phantom Forces, Murderers vs Sheriffs Duels).

**Bloxstrike, Rivals, Overkill, Phantom Forces, and Murderers vs Sheriffs Duels.** The current map. Empty table in games without map rotation, so guard with `if api.world.getMap then`.

## What you can read

| Call        | Returns      | What it tells you                                                    |
| ----------- | ------------ | -------------------------------------------------------------------- |
| `getMap()`  | `string?`    | The map you're currently on, or `nil` while not in a match.          |
| `getMaps()` | `{ string }` | Every map the game has, when the game exposes a list (may be empty). |

## Things that notify you

Call `:Connect(callback)`. Disconnects on unload.

| Signal         | Your callback receives                                               |
| -------------- | -------------------------------------------------------------------- |
| `onMapChanged` | `(map: string?)`: the map changed, or `nil` when you left the match. |

## Example

```luau theme={null}
api.world.onMapChanged:Connect(function(map)
    if map == "Crossroads" then
        api.ui.toast("Crossroads config loaded")
    end
end)
```
