22 lines
483 B
JavaScript
22 lines
483 B
JavaScript
export class EmitterSize {
|
|
constructor() {
|
|
this.mode = "percent";
|
|
this.height = 0;
|
|
this.width = 0;
|
|
}
|
|
load(data) {
|
|
if (data === undefined) {
|
|
return;
|
|
}
|
|
if (data.mode !== undefined) {
|
|
this.mode = data.mode;
|
|
}
|
|
if (data.height !== undefined) {
|
|
this.height = data.height;
|
|
}
|
|
if (data.width !== undefined) {
|
|
this.width = data.width;
|
|
}
|
|
}
|
|
}
|