[Free] Ox Target

Does someone have an example how to remove a Zone?

I’ve added a zone with

exports.ox_target:addSphereZone({
			coords	= vector3(exampleCoords.x, exampleCoords.y, exampleCoords.z+1),
			radius	= 1,
			debug	= true,
			options	= {
				{
					name    	= "example:location",

etc…

but when I use

exports.ox_target:removeZone("example:location")

it doesnt remove the sprite and zone. Am I doing something wrong?

1 Like

When you use exports.ox_target:addSphereZone it will return an ID.

It’s that ID you need to use on the exports.ox_target:removeZone

Example:

local varTest = exports.ox_target:addSphereZone({ .....
exports.ox_target:removeZone(varTest )
1 Like

Thanks!

Im about to update my core and inventory from an older version. I am thinking about updating to
Ox target but wonder what challenges Ill come across while converting from qbtarget.

Can anyone offer some insight on converting over?

1 Like

Can you cook too? See vrp

Let me know how it goes, I am considering this as well.

i did it and almost everything is done for you since ox is mostly backwards compatible with qb-target. theres was only like 3 targets i had to change

1 Like

i havent changed over yet , i gotta make sure all my important encrypted scripts can config to it

Theres backwards compatability to a certain extent, try it out we did and do not regret it

Hey, i have an error with the car detection. When i get out and any other goes in and i open a door, it close instantly. I think its not supposed to do it. Same with a stretcher and a person on it. You cant open it anymore. It closes instantly. Any chance to get a fix for it?

Does anyone know of a standalone police interaction menu (cuff, grab/drag, put in car, etc…) menu that works with Ox-Target? I’ve been searching the forums but they are painfully difficult to find anything in.

Just started testing OX_target on our server, but for some reason the Time % crawl up, is that normal? we had it up on 20-30% with out useing the target, and over 50% when holding the target button down?

  1. Check for zones using debug. (drawing zones affects overall time)
  2. Check for canInteract functions running performance-heavy code. (only affects time when active)
  3. Check for targets being registered repeatedly in events and loops. (increases time when active; zones affect overall time)
1 Like

Thx for replying,
Going to take an extra look, since we love the ox_target, just got surprised it crawled up like that, when my character just standing still.

How can i enable the interaction locations when i have my third eye open?

how the deactivate the Perfect Timing minigame?

Great script but 2 questions.

How do i make so that its only accessible outside a Vehicle?
Refueling wise, i have the option to “Refuel”, when i start it disappears and only appears “Cancel”, and when “Cancel” is pressed the “Refuel” appears again and the “Cancel” disappears. Is it possible ?

Edit
No need, managed to find it out.

Script is awesome btw !!!

1 Like

Good morning everyone, I’m facing a major problem with different versions tested, the ATMs on the wall are not recognized and therefore pointable except for the actually physical ones like the one in the shop near the vanilla one, do any of you know how to solve this problem?

Not Working


Working

Blame NVE.

Thanks for the reply, is there a way to solve it? Even modifying the NVE?