Files
bo3-js/js/instances/BaseService.js

13 lines
358 B
JavaScript
Raw Normal View History

2025-10-23 20:58:19 +02:00
import { Instance } from "./Instance.js";
export class BaseService extends Instance {
constructor(name) {
super(name);
}
SetParent(parent) {
if (this.Parent === null) {
super.SetParent(parent);
return;
} // Only accept it once
throw new Error("Cannot reparent a service instance.");
}
}