rock-mod
Version:
Rock-Mod is a powerful framework designed for creating and managing mods for Grand Theft Auto (GTA) games.
38 lines (37 loc) • 1.06 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.MockEntity = void 0;
const MockWorldObject_1 = require("../worldObject/MockWorldObject");
const utils_1 = require("../../../../shared/common/utils");
const RockMod_1 = require("../../../RockMod");
class MockEntity extends MockWorldObject_1.MockWorldObject {
_model;
_rotation;
_netData;
get model() {
return this._model;
}
get rotation() {
const { x, y, z } = this._rotation;
return new utils_1.Vector3D(x, y, z);
}
constructor(options) {
super(options);
this._model = options.model;
this._rotation = options.rotation;
this._netData = new Map();
}
setModel(value) {
this._model = RockMod_1.RockMod.instance.utils.hash(value);
}
setRotation(value) {
this._rotation = value;
}
getNetData(name) {
return this._netData.get(name);
}
setNetData(name, value) {
this._netData.set(name, value);
}
}
exports.MockEntity = MockEntity;