Parachute sync
Since v15 alt:V has parachute sync.
How to use
Object sync is disabled by default, in order to enable it add two event listeners to your server-side code, in JS there are clientDeleteObject
and clientRequestObject
.
JS example
import * as alt from "alt-server";
alt.on("clientRequestObject", (player, model, position) => {
alt.log("Client:", player.name, "requesting object:", model, position);
// you can cancel it if needed
// return false;
});
alt.on("clientDeleteObject", (player) => {
alt.log("Client:", player.name, "deleting object");
// this one is also cancellable
// return false;
});