Freak-ppa's picture
Upload 56 files
6ffd0b5 verified
raw
history blame
689 Bytes
import { app } from "../../scripts/app.js";
/*
Things that can be useful (generally as breakpoints) when debugging
*/
export function add_debug() {
var dirty_canvas = true;
Object.defineProperty(app.canvas, 'dirty_canvas', {
get : () => { return dirty_canvas },
set : (v) => { dirty_canvas = v;} // a breakpoint here catches the calls that mark the canvas as dirty
})
var dirty_bg_canvas = true;
Object.defineProperty(app.canvas, 'dirty_bg_canvas', {
get : () => { return dirty_bg_canvas },
set : (v) => { dirty_bg_canvas = v;} // a breakpoint here catches the calls that mark the background canvas as dirty
})
}