change setViewport action to set for CameraAPI

This commit is contained in:
Hanusiak Piotr 2022-01-14 11:41:37 +01:00
parent 17e9c3c586
commit 7ee41bad30
7 changed files with 24 additions and 20 deletions

View file

@ -17,7 +17,7 @@ export class WorkAdventureCameraCommands extends IframeApiContribution<WorkAdven
}),
];
public setViewport(
public set(
x: number,
y: number,
width?: number,
@ -26,7 +26,7 @@ export class WorkAdventureCameraCommands extends IframeApiContribution<WorkAdven
smooth: boolean = false
): void {
sendToWorkadventure({
type: "cameraSetViewport",
type: "cameraSet",
data: { x, y, width, height, lock, smooth },
});
}