Dependencies
INTERACT
If you want to use the interact you can download it from the following link:
https://github.com/bitc0de/bit-interact
The interact is the icon that appears when you approach areas with an "E" key prompt.
If you do not want to use any interact and simply want to use a drawText, you can modify the drawTxt function in the configuration file.
By default it is configured like this:
function drawTxt(key, text, font, centre, x, y, scale, r, g, b, a)
TriggerEvent("bit-interact:Start", key, text)
-- default drawtxt:
--[[SetTextFont(font)
SetTextProportional(0)
SetTextScale(scale, scale)
SetTextColour(r,g,b,a)
SetTextDropShadow(0,0,0,0,255)
SetTextEdge(1,0,0,0,255)
SetTextDropShadow()
SetTextOutline()
SetTextCentre(centre)
SetTextEntry("STRING")
AddTextComponentString(text)
DrawText(x,y)]]
end
Change to this if you don't want to use BIT-Interact:
function drawTxt(key, text, font, centre, x, y, scale, r, g, b, a)
SetTextFont(font)
SetTextProportional(0)
SetTextScale(scale, scale)
SetTextColour(r,g,b,a)
SetTextDropShadow(0,0,0,0,255)
SetTextEdge(1,0,0,0,255)
SetTextDropShadow()
SetTextOutline()
SetTextCentre(centre)
SetTextEntry("STRING")
AddTextComponentString(text)
DrawText(x,y)
end
TARGET
If instead of using interact you want to use a targeting system, you must have one installed. The script is compatible with:
- qb-target
- ox-target
- bt-target
- Any other targeting system (configurable in shared.lua)
The script is designed to work with any targeting system, offering complete flexibility for your server setup.