Skip to main content
lation_interact is a drop-in replacement for qb-target. Every export - AddBoxZone, AddTargetModel, AddTargetEntity, the globals, the data accessors, all of it - is answered under the qb-target name, with the behavior your scripts expect: label keying, job/gang/item/citizenid gates, canInteract, event dispatch by type, cleanup when a resource stops. Works with QBCore and Qbox. No consumer script needs editing. The switch:
  1. Remove (or stop) the real qb-target
  2. ensure lation_interact after your framework core, before every script that uses targeting
Scripts that check for qb-target see it as installed, and everything they register shows up in the new interaction UI automatically. Zone centers arrive the way PolyZone takes them - any vector, or a table with named or positional components; a 2D center takes the player’s z at registration.
qb-target also doubles as a ped spawner (SpawnPed, RemoveSpawnedPed, DeletePeds, GetPeds) - plenty of scripts rely on it, so it ships here too and works identically, including spawn-on-load and cleanup on player unload.

What You Might Notice

A few things don’t translate one-to-one from the targeting eye to an attention model. Poly and combo zones print a one-time console note; the rest are silent:
  • Zones reach from a step away - the stack goes live within Config.Stages.reach (2.4m) of the zone’s surface, never farther than the zone’s targetoptions.distance. qb’s eye reached a default-distance zone from 7.0m; the per-option distance gates are still qb’s exact math.
  • Poly and combo zones become spheres - wide enough to reach the zone’s farthest point, so a long thin poly is the worst fit. Box and circle zones are exact.
  • Eye cosmetics are ignored - targeticon, drawColor, drawDistance, and outline settings have no meaning without a crosshair.
  • No targeting eye - nothing has to be held to see an interaction and there’s no crosshair, so the eye-machinery exports (DisableTarget, EnableNUI, …) exist but do nothing. The interact key - Left Alt by default, and rebindable by each player - still reveals passive interactions and frees the cursor for clicks; it just isn’t an eye. AllowTargeting still works: false puts the whole layer to sleep, true wakes it.
  • Targets behind the player are ignored - qb’s eye reached anything the camera was pointed through. Here nothing at the player’s back is focused, and a camera pushed into a wall can’t see past it. From a seat their own vehicle doesn’t block it, so drive-thrus and garages still work.

Reveal Mode

Bridged content renders nothing until you look at it. If you’d rather every bridged zone get a grain (a point of light marking it from a distance), set Config.Reveal.bridged = 'ambient' in config.lua. Bridged entities, models and globals always reveal on focus.

qtarget

qtarget is where qb-target came from, so its exports are answered under the qtarget name too - AddCircleZone, AddBoxZone, AddPolyZone, AddEntityZone, AddTargetBone, AddTargetEntity, AddTargetModel, the Ped / Vehicle / Object / Player shorthands, and every matching Remove*. Scripts that still register through qtarget (a habit from when the one name worked under both targets) need no changes, and required_item gates like item. Registrations share the qb-target registries, so a zone added under one name removes under the other.

Vehicle Doors

Door, hood and trunk toggles are built in - one chip per door, on the door itself - so qb-target’s Config.EnableDefaultOptions isn’t missed. Config.VehicleDoors = 'passive' keeps them hidden until the interact key is held; false turns them off.

Per-Script Behavior

Two things you can set without touching the script itself:
  • Passive - list a resource in Config.PassiveResources and everything it registers stays hidden until the interact key is held, like a classic target. See passive mode.
  • In a vehicle - options a script flags with allowInVehicle = true stay live from a seat; everything else follows Config.InVehicle. See in a vehicle.

Updating

After updating lation_interact, do a full server restart so every script that depends on it registers its targets correctly.