Split the module up into multiple files

This commit is contained in:
2020-12-10 00:30:00 +01:00
parent 01df3b9dba
commit 38204c7651
11 changed files with 504 additions and 476 deletions

View File

@@ -0,0 +1,12 @@
import {settingsKey} from "../settings.js"
// Toggles between normal and secret doors
export function onDoorLeftClick(event) {
if (event.data.originalEvent.ctrlKey && game.user.isGM && game.settings.get(settingsKey, "toggleSecretDoors")) {
const types = CONST.WALL_DOOR_TYPES
const newtype = this.wall.data.door === types.DOOR ? types.SECRET : types.DOOR
this.wall.update({door: newtype})
return true
}
return false
}