Skip to content

Commit

Permalink
DT/cameracontrols: minor fixes (#768)
Browse files Browse the repository at this point in the history
- Set cameraBG value
- Disabled interpolation when loading
  • Loading branch information
LilyMakesThings committed Jul 22, 2023
1 parent 3b38982 commit 84053a4
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions extensions/DT/cameracontrols.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@

vm.runtime.runtimeOptions.fencing = false;
vm.renderer.offscreenTouching = true;
vm.setInterpolation(false);

function updateCamera(x = cameraX, y = cameraY, scale = cameraZoom / 100, rot = -cameraDirection + 90) {
rot = rot / 180 * Math.PI;
Expand Down Expand Up @@ -347,6 +348,7 @@
setCol(args, util) {
const rgb = Scratch.Cast.toRgbColorList(args.val);
Scratch.vm.renderer.setBackgroundColor(rgb[0] / 255, rgb[1] / 255, rgb[2] / 255);
cameraBG = args.val;
}
getCol() {
return cameraBG;
Expand Down

0 comments on commit 84053a4

Please sign in to comment.