{"hash":"0x06D26A96CA1BCA75","ns":"PED","name":"_SET_PED_MOTIVATION","slug":"_SET_PED_MOTIVATION","official":false,"named":true,"luaName":"SetPedMotivation","game":"rdr3","apiset":"client","returnType":"void","params":[{"name":"ped","type":"Ped"},{"name":"motivationState","type":"int"},{"name":"threshold","type":"float"},{"name":"targetPed","type":"Ped"}],"summary":"TOILET_STATE, FEAR_STATE, ANGRY_STATE, AGITATION_STATE, HUNGRY_STATE, TIRED_STATE, SAD_STATE, BRAVE_STATE, OFFER_ITEM_STATE, SUSPICION, DRUNK_STATE If targetPed is set to 0 the ped motivationState affects everyone","descriptions":[{"source":"alloc8or","format":"text","body":"enum eMotivationState\n{\n\tTOILET_STATE,\n\tFEAR_STATE,\n\tANGRY_STATE,\n\tAGITATION_STATE,\n\tHUNGRY_STATE,\n\tTIRED_STATE,\n\tSAD_STATE,\n\tBRAVE_STATE,\n\tOFFER_ITEM_STATE,\n\tSUSPICION,\n\tDRUNK_STATE\n};\n\nIf targetPed is set to 0 the ped motivationState affects everyone"}],"examples":[],"aliases":[],"enums":["PedMotivationState"],"related":["0x42688E94E96FD9B4"],"build":"1207","sources":["alloc8or"],"doc":2,"url":"https://natives.borderlinerp.com/natives/PED/_SET_PED_MOTIVATION","markdownUrl":"https://natives.borderlinerp.com/natives/PED/_SET_PED_MOTIVATION.md","snippets":{"lua":"SetPedMotivation(ped, motivationState, threshold, targetPed)","luaInvoke":"Citizen.InvokeNative(0x06D26A96CA1BCA75, ped, motivationState, threshold, targetPed)","js":"SetPedMotivation(ped, motivationState, threshold, targetPed);","jsInvoke":"Citizen.invokeNative('0x06D26A96CA1BCA75', ped, motivationState, threshold + 0.0000001, targetPed);","csharp":"Function.Call((Hash)0x06D26A96CA1BCA75, ped, motivationState, threshold, targetPed);","notes":["Float parameters: Lua integers (`10`, or whole numbers decoded from NUI/JSON) are sent as ints and read as garbage. Write `10.0` or `value + 0.0`. The generated JS wrappers add `0.0000001` to non-zero floats for the same reason.","The name is a community guess and may change. If the named call is missing in your client build, use `InvokeNative` with the hash — it always works."]}}