SetFloatingHelpTextStyle
DocsSetFloatingHelpTextStyle(hudIndex, style, hudColor, alpha, arrowPosition, boxOffset)Description
### Arrow Positions
0 = Off / No arrow
1 = Top
2 = Left
3 = Bottom
- 4 = Right
Any numeric value greater than 4 will result in a right arrow (Index 4)
### Important
Needs to be called every frame
Parameters
| Name | Type | Description |
|---|---|---|
hudIndex | int | The hud index for the floating help message |
style | int | Value 0 won't show an arrow at all. Values 1, 2 and -2 will display an arrow. |
hudColor | int | https://docs.fivem.net/docs/game-references/hud-colors/ |
alpha | int | Value for the help box opacity, from 0-255. Anything greater will simply ignore the alpha value. Always 191 in R\* scripts. |
arrowPosition | int | Used to set the arrow positon. No value will hide the arrow |
boxOffset | int | Offset for the floating help box. Note: Arrow stays fixed |
Returns
voidThis native does not return a value.
Examples
Official
function DisplayHelpText(string)
BeginTextCommandDisplayHelp("STRING")
AddTextComponentSubstringPlayerName(string)
EndTextCommandDisplayHelp(1, false, false, 0)
end
CreateThread(function()
while true do
Wait(0)
local Ped = PlayerPedId()
DisplayHelpText('Example Text')
SetFloatingHelpTextStyle(0, 2, 2, 0, 3, 0)
SetFloatingHelpTextToEntity(0, Ped, 0, 0)
end
end)