change warning message
This commit is contained in:
parent
85531745c9
commit
282694fc99
@ -94,19 +94,7 @@ export class CustomizeScene extends AbstractCharacterScene {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public create(): void {
|
public create(): void {
|
||||||
try {
|
this.tryLoadLastUsedWokaLayers();
|
||||||
const savedWokaLayers = gameManager.getCharacterLayers();
|
|
||||||
if (savedWokaLayers && savedWokaLayers.length !== 0) {
|
|
||||||
this.selectedLayers = [];
|
|
||||||
for (let i = 0; i < savedWokaLayers.length; i += 1) {
|
|
||||||
this.selectedLayers.push(
|
|
||||||
this.layers[i].findIndex((item) => item.id === gameManager.getCharacterLayers()[i])
|
|
||||||
);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} catch (error) {
|
|
||||||
console.warn(error);
|
|
||||||
}
|
|
||||||
waScaleManager.zoomModifier = 1;
|
waScaleManager.zoomModifier = 1;
|
||||||
this.createSlotBackgroundTextures();
|
this.createSlotBackgroundTextures();
|
||||||
this.initializeCustomWokaPreviewer();
|
this.initializeCustomWokaPreviewer();
|
||||||
@ -162,6 +150,22 @@ export class CustomizeScene extends AbstractCharacterScene {
|
|||||||
this.scene.run(SelectCharacterSceneName);
|
this.scene.run(SelectCharacterSceneName);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private tryLoadLastUsedWokaLayers(): void {
|
||||||
|
try {
|
||||||
|
const savedWokaLayers = gameManager.getCharacterLayers();
|
||||||
|
if (savedWokaLayers && savedWokaLayers.length !== 0) {
|
||||||
|
this.selectedLayers = [];
|
||||||
|
for (let i = 0; i < savedWokaLayers.length; i += 1) {
|
||||||
|
this.selectedLayers.push(
|
||||||
|
this.layers[i].findIndex((item) => item.id === gameManager.getCharacterLayers()[i])
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} catch {
|
||||||
|
console.warn("Cannot load previous WOKA");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
private createSlotBackgroundTextures(): void {
|
private createSlotBackgroundTextures(): void {
|
||||||
for (let i = 0; i < 4; i += 1) {
|
for (let i = 0; i < 4; i += 1) {
|
||||||
if (this.textures.getTextureKeys().includes(`floorTexture${i}`)) {
|
if (this.textures.getTextureKeys().includes(`floorTexture${i}`)) {
|
||||||
|
Loading…
Reference in New Issue
Block a user