KS-Target
Installation
- Unzip the delivered archive into your
resources/folder, under the nameks-target. - Import the provided
install.sqlfile into your database. - Add
ensure ks-targetto yourserver.cfg, afteroxmysqlandqb-core. - Restart your server.
Configuration
Config.MaxDistance = 2.5 -- portée de détection, en mètres
Config.CursorFrequency = 5 -- fréquence de rafraîchissement du raycast (Hz)
Config.CompatMode = true -- active la couche de compatibilité qb-target / ox_target
Lower CursorFrequency on a busy server to save resources — the effect on aiming precision stays negligible below 10 Hz.
Registering a new interaction
A targetable zone is declared with the same syntax as ox_target, for an immediate migration:
exports['ks-target']:AddBoxZone('atm_1', vector3(-1040.9, -2745.6, 20.2), 1.0, 1.0, {
options = {
{ label = "Retirer de l'argent", icon = "fa-solid fa-money-bill", action = function() end },
},
})
Existing zones declared through qb-target or ox_target are picked up automatically when Config.CompatMode is on — no migration needed for scripts already in place.
Common issues
My old qb-target scripts no longer show any options. Check that Config.CompatMode is set to true and that ks-target starts after your old target script in server.cfg — the compatibility layer intercepts its exports at startup.
Mouse-aim targeting doesn’t trigger. The free cursor needs SetMouseCursorActiveThisFrame active — check that no other script is permanently capturing NUI focus (an always-open menu, for instance).

