Skip to main content

Clues

A Types.Sense that turns an agent's sightings into clues on a shared Interest map. Add it after Sight, give every agent of a group the same map, and roam it with [States.Roam]: one enemy spotting a player warms that part of the map for all of them.

:AddSense(VluxyAI.Senses.Sight.new({ Range = 45 }))
:AddSense(VluxyAI.Senses.Clues.new(interest))

Functions​

new​

Clues.new(
interest: Interest,--

The shared map.

options: CluesOptions?
) → Clues

Types

​

interface CluesOptions {
Radius: number?--

Studs around the sighting that are raised. Default 20.

SeenHeat: number?--

Per second while someone is in view, at the centre. Default 4.

HeadingHeat: number?--

Per second at PredictedPosition once they are lost. Default 2.

SightPrefix: string?--

The Prefix of the Sight whose keys are read. Default "".

}

Errors

TypeDescription
"unknown option"

Tick​

Clues.Tick(
self: Clues,
agent: Agent,
deltaTime: number
) → ()

Raises the map around the current sighting, or around where the lost target was heading.

Destroy​

Clues.Destroy(self: Clues) → ()

Nothing to release.

Show raw api
{
    "functions": [
        {
            "name": "new",
            "desc": "",
            "params": [
                {
                    "name": "interest",
                    "desc": "The shared map.",
                    "lua_type": "Interest"
                },
                {
                    "name": "options",
                    "desc": "",
                    "lua_type": "CluesOptions?"
                }
            ],
            "returns": [
                {
                    "desc": "",
                    "lua_type": "Clues"
                }
            ],
            "function_type": "static",
            "errors": [
                {
                    "lua_type": "\"unknown option\"",
                    "desc": ""
                }
            ],
            "source": {
                "line": 82,
                "path": "lib/Senses/Clues.luau"
            }
        },
        {
            "name": "Tick",
            "desc": "Raises the map around the current sighting, or around where the lost target was heading.",
            "params": [
                {
                    "name": "self",
                    "desc": "",
                    "lua_type": "Clues"
                },
                {
                    "name": "agent",
                    "desc": "",
                    "lua_type": "Agent"
                },
                {
                    "name": "deltaTime",
                    "desc": "",
                    "lua_type": "number"
                }
            ],
            "returns": [],
            "function_type": "static",
            "source": {
                "line": 95,
                "path": "lib/Senses/Clues.luau"
            }
        },
        {
            "name": "Destroy",
            "desc": "Nothing to release.",
            "params": [
                {
                    "name": "self",
                    "desc": "",
                    "lua_type": "Clues"
                }
            ],
            "returns": [],
            "function_type": "static",
            "source": {
                "line": 112,
                "path": "lib/Senses/Clues.luau"
            }
        }
    ],
    "properties": [],
    "types": [
        {
            "name": "CluesOptions",
            "desc": "",
            "fields": [
                {
                    "name": "Radius",
                    "lua_type": "number?",
                    "desc": "Studs around the sighting that are raised. Default `20`."
                },
                {
                    "name": "SeenHeat",
                    "lua_type": "number?",
                    "desc": "Per second while someone is in view, at the centre. Default `4`."
                },
                {
                    "name": "HeadingHeat",
                    "lua_type": "number?",
                    "desc": "Per second at `PredictedPosition` once they are lost. Default `2`."
                },
                {
                    "name": "SightPrefix",
                    "lua_type": "string?",
                    "desc": "The `Prefix` of the [Sight] whose keys are read. Default `\"\"`."
                }
            ],
            "source": {
                "line": 34,
                "path": "lib/Senses/Clues.luau"
            }
        }
    ],
    "name": "Clues",
    "desc": "A [Types.Sense] that turns an agent's sightings into clues on a shared [Interest] map. Add it\nafter [Sight], give every agent of a group the same map, and roam it with [States.Roam]: one\nenemy spotting a player warms that part of the map for all of them.\n\n```lua\n:AddSense(VluxyAI.Senses.Sight.new({ Range = 45 }))\n:AddSense(VluxyAI.Senses.Clues.new(interest))\n```",
    "source": {
        "line": 74,
        "path": "lib/Senses/Clues.luau"
    }
}