Closed hellyet closed 1 year ago
Problem seems to be on Native itself 🤔
Problem seems to be on Native itself 🤔
FXServer version is 6440 I will try to fix it, if it turns out - I will send a pull-request
problem seems to be on SetFloatingHelpTextWorldPosition native.. Sure 😄 thanks for the contribution!
Yeah, it is. But i don't have any idea about problem reason 😔.
no problem 😄 we'll take a look at it as soon we'll be able to.
Okey. I think that is cfx api problem.
I found a way to fix it!
Citizen.CreateThread(function()
while true do
Citizen.Wait(5)
Notifications:ShowFloatingHelpNotification('Test Notification', GetEntityCoords(PlayerPedId()), -1)
end
end)
This function need to be called every frame.
Yup, duration is not present in the C# counterpart. Thanks for the finding!! I'm expecting your PR!
I'm confused... I want to split it into two functions: ShowFloatingHelpNotification, that need to be called every frame, and ShowFloatingHelpNotificationOverTime, that accept a duration param and don't need to be called every frame. What do you think?
But there is one thing: these two functions cannot be called at the same time.
i would not add the one with duration as you have seen it seems to be erroring out.. i would default it to use -1 and remove the duration parameter.
I fixed it! (gif is not loading but i works correctly)
RegisterCommand("test_notif", function()
Notifications:ShowFloatingHelpNotification('This text will disappear in 3 seconds ', GetEntityCoords(PlayerPedId()), 3000)
end, false)
In future I will be able to separate it into two functions, as i wrote upper.
in this case.. use 1 function like now and use the check for the duration that
if duration == nil then duration = -1 end
Check my PR, how i did it.
Closed via #133
Coords is correct, I don't know why it rising an error.