diff --git a/OBJECT/DeleteObject.md b/OBJECT/DeleteObject.md index efd0c2b05..48a6091c0 100644 --- a/OBJECT/DeleteObject.md +++ b/OBJECT/DeleteObject.md @@ -62,7 +62,7 @@ uint objectHash = GetHashKey("v_ret_gc_chair03"); int prop = GetClosestObjectOfType(playerCoords.X, playerCoords.Y, playerCoords.Z, 10.0f, objectHash, true, false, false); // If the object is a mission entity, we have to set it to false. Otherwise, it won't be possible to delete the object. -if (IsEntityAMissionEntity(object)) +if (IsEntityAMissionEntity(prop)) { SetEntityAsMissionEntity(prop, false, true); }