Step completed
Triggered when a step of a heist is completed
Event
RegisterNetEvent("robberies_creator:heist:stepCompleted", function(playerId, heistId, stageId, stepType)
end)
Parameters
Name
Data Type
Description
playerId
int
player server ID who completed the step
heistId
int
Heist ID
stageId
int
Stage ID
Step types
SAFE
ROBBABLE_OBJECT
HACKABLE_PANEL
THERMAL_CHARGE
LOCKPICKABLE_DOOR
Example
-- This hypothetical example will give xp when a player does a step which has a minigame
RegisterNetEvent("robberies_creator:heist:stepCompleted", function(playerId, heistId, stageId, stepType)
if(stepType ~= "ROBBABLE_OBJECT") then
TriggerEvent("xp_script:addPlayerXp", playerId, 10)
end
end)
Where to insert the code?
You can place it in the file integrations/sv_integrations.lua
of the script, at the bottom of the file on new lines
Last updated
Was this helpful?