FEATURE: add the ability to zoom in and out using touch screen
This commit is contained in:
parent
71898bff7d
commit
d7a74baa9d
11 changed files with 77 additions and 10 deletions
|
@ -8,6 +8,8 @@ import { EnableCameraSceneName } from "./EnableCameraScene";
|
|||
import { localUserStore } from "../../Connexion/LocalUserStore";
|
||||
import { CompanionResourceDescriptionInterface } from "../Companion/CompanionTextures";
|
||||
import { getAllCompanionResources } from "../Companion/CompanionTexturesLoadingManager";
|
||||
import {touchScreenManager} from "../../Touch/TouchScreenManager";
|
||||
import {PinchManager} from "../UserInput/PinchManager";
|
||||
|
||||
export const SelectCompanionSceneName = "SelectCompanionScene";
|
||||
|
||||
|
@ -54,6 +56,10 @@ export class SelectCompanionScene extends ResizableScene {
|
|||
}
|
||||
|
||||
create() {
|
||||
if (touchScreenManager.supportTouchScreen) {
|
||||
new PinchManager(this);
|
||||
}
|
||||
|
||||
this.textField = new TextField(this, this.game.renderer.width / 2, 50, 'Select your companion');
|
||||
|
||||
const confirmTouchAreaY = 115 + 32 * Math.ceil(this.companionModels.length / this.nbCharactersPerRow);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue