[HELP]Make blip on map to make something happen

It dont seem to be working i put a notifaction there but it didnt work ill show you now

Ignore the 2 other screens but look at the mioddle screen

Alright first why do you have a function inside of a function? Second where are you getting playerName from? Third did you fill out your own XYZ coords and see if it prints out “BUTTON PRESSED or whatever”…???

It dont print button pressed but i know i have a function ina function i put it thewre to show you the code

Player nam,es was a mistake as i copied from my other code forgot to take that out

Well if its there its just gonna error out. It doesn’t exist.

local table = {
	{x=1856.91320800781, y=3689.50073242188, z=34.2670783996582}
}

-- Draw Markers --
Citizen.CreateThread(function()
	while true do
		Citizen.Wait(0)
		for k in pairs(table) do
			-- Draw Marker Here --
			DrawMarker(1, table[k].x, table[k].y, table[k].z, 0, 0, 0, 0, 0, 0, 1.001, 1.0001, 0.5001, 0, 0, 255, 200, 0, 0, 0, 0)
		end
	end
end)

Citizen.CreateThread(function()
	while true do
		Citizen.Wait(0)

		for k in pairs(table) do

			local plyCoords = GetEntityCoords(GetPlayerPed(-1), false)
			local dis = Vdist(plyCoords.x, plyCoords.y, plyCoords.z, table[k].x, table[k].y, table[k].z)

			if dis <= 1.2 then
				if IsControlJustPressed(3,176) then
					Citizen.Trace("BUTTON ENTER PRESSED ON MARKER.")
					notification('IT WORKS YAYAYAYA')

					
					
				end
			end
		end
	end
end)

function notification(msg)
	SetNotificationTextEntry("STRING")
	AddTextComponentString(msg)
	DrawNotification(false, false)
end



That should be right

I mean it looks right looking at it.

Yes but it dont work

The marker shows up but nothing else

Like i have this client side so it should work

You are hitting ENTER right?

No lol my bad I didnt know

Just wondering if you know any good tutorial that teach you how to link a menu to it as I know html css bit of js and i know php

There isn’t any good tutorials for it. The only one I seen is old and is hard to understand for newer NUI learners.

Ok well how do you recomend I learn then?

Wow that looks good I am just learning so I can start deving for my community and I love programing

The problem I am having is where it would be in other peoples code as I am looking in cops five m to see how they do it but dont have a clue where to look lol

Ok thanks I will have a look but which one there is 2