NullRefernceException runtime error but no build errors [ScriptHookVDotNet]
-
Maybe the Target is null, or the CurrentBlip is not null.
-
@Jitnaught So I added
UI.ShowSubtitle(Target.ToString());
UnderTarget = Game.Player.GetTargetedEntity();
and it said GTA.Vehicle (was a car) so that worked.
-
Okay so I rewrote the whole code and now everything kinda works but the only problem is that the blip disappears once it's out of the player's FoV even though I set
newBlip.IsShortRange
to false.Here's the new code: https://pastebin.com/b1SgBL4B
-
Everything's fine and I fixed the code! Thanks for everyone who helped me with this issue!