Blips that disappear from minimap/radar when too far?

I want to add blips on the map that behave just like in normal GTA or other servers - they should be on both, map (and selectable) and radar and as soon as you move out of radar range, they should disappear… I tried different SetBlipDisplay flags, but I either get no blip on the radar, or it stays there (in the corner) no matter how far I go

RegisterNetEvent("map:addBlip");
AddEventHandler("map:addBlip", function(player, args)
	if #args == 0 then
		local pos = player.getCoords();
		local blip = AddBlipForCoord(pos.x, pos.y, pos.z);
		SetBlipSprite(blip, 480);
		SetBlipDisplay(blip, 2);
		SetBlipScale(blip, 1.0);
		SetBlipColour(blip, 27);
		BeginTextCommandSetBlipName("STRING");
		AddTextComponentString("TITLE");
		EndTextCommandSetBlipName(blip);
	end
end)

SET_BLIP_AS_SHORT_RANGE this is what you are looking for

1 Like

holy fck man, that was fast, appreciate it, thanks!

where would you put that into?

It’s a setter so you just set it once wherever you want to change a blip? Insanely self explanatory