phrases = {
"hey give me some money",
-- Make as much phrases for this action you want.
},
actionType = "event",
eventType = "client",
eventName = "17mov_SpeechRecognition:TestPhrase",
arguments = {
arg1 = "17movement.net",
},
Here action type has 3 types
1. Event
2. Command
3. Custom Function
actionType = "event",
eventType = "client", -- or "server"
eventName = "17mov_SpeechRecognition:TestPhrase",
arguments = {
arg1 = "17movement.net", -- optional
},
actionType = "executeCommand",
commandString = "e flip",
actionType = "custom",
actionFunction = function()
-- Add here ur custom code
end,
actionType = "custom",
actionFunction = function()
if IsPlayerFreeAiming(PlayerId()) then
local found, targetPed = GetEntityPlayerIsFreeAimingAt(PlayerId())
print(targetPed)
if found then
local dict, anim = "missminuteman_1ig_2", "handsup_base"
while not HasAnimDictLoaded(dict) do
RequestAnimDict(dict)
Citizen.Wait(10)
end
print("PLAYING")
TaskPlayAnim(targetPed, dict, anim, 8.0, -8.0, -1, 1, 0, false, false, false)
Citizen.Wait(5000)
ClearPedTasks(targetPed)
end
end
end,