diff --git a/src/components/Dialogs.vue b/src/components/Dialogs.vue index 8ee248c..eac840a 100644 --- a/src/components/Dialogs.vue +++ b/src/components/Dialogs.vue @@ -1,9 +1,6 @@ diff --git a/src/components/Droptables.vue b/src/components/Droptables.vue index ebd6b46..243de8f 100644 --- a/src/components/Droptables.vue +++ b/src/components/Droptables.vue @@ -14,12 +14,9 @@ v-if="items.length && maps.length && droptables.length === 0" > No Droptables -
+
- Add one + Add one
- + - - + - - + + - + -
+
- +
@@ -175,11 +147,7 @@ placeholder="Search droptables..." @filtered="onFiltered" > @@ -205,11 +173,7 @@ variant="success" Edit - + Remove diff --git a/src/components/Quests.vue b/src/components/Quests.vue index b1d253c..9479fb9 100644 --- a/src/components/Quests.vue +++ b/src/components/Quests.vue @@ -1,16 +1,10 @@ diff --git a/src/components/Recipes.vue b/src/components/Recipes.vue index 1bc84e7..76cd339 100644 --- a/src/components/Recipes.vue +++ b/src/components/Recipes.vue @@ -12,12 +12,9 @@ v-if="items.length && recipes.length === 0" > No Recipes -
+
- Add one + Add one
- + - - + + - - + + - - + - + - +
-
+
- + -
+
@@ -270,15 +231,9 @@ label-cols-md="3"
-
+
- +
@@ -305,20 +260,13 @@ placeholder="Search recipes..." @filtered="onFiltered" > @@ -342,11 +290,7 @@ v-for="(item, index) in data.item.ingredients" Edit - + Remove diff --git a/src/components/Spawners.vue b/src/components/Spawners.vue index b2fb9e1..89c4023 100644 --- a/src/components/Spawners.vue +++ b/src/components/Spawners.vue @@ -12,12 +12,9 @@ v-if="npcs.length && spawners.length === 0" > No Spawners -
+
- Add one + Add one
- + - + - + - + - +
- +
- + Make Lair-like Spawner
- - + - + - + - +
- + Add
@@ -372,10 +329,7 @@ variant="primary"
- + Del
@@ -386,15 +340,9 @@ variant="danger"
-
+
- +
@@ -421,11 +369,7 @@ placeholder="Search spawners..." @filtered="onFiltered" > @@ -439,10 +383,7 @@ variant="success" @@ -466,11 +407,7 @@ v-for="(item, index) in data.item.npcIds" Edit - + Remove diff --git a/src/components/simple/ModTester.vue b/src/components/simple/ModTester.vue index c111541..63f0142 100644 --- a/src/components/simple/ModTester.vue +++ b/src/components/simple/ModTester.vue @@ -20,9 +20,11 @@ Extra Character Settings {{ validOtherProps ? '✅' : '🚫' }} + v-b-tooltip.hover + title="If your JSON is not well-formed, you cannot run the test." + > + {{ validOtherProps ? '✅' : '🚫' }} +
@@ -30,13 +32,9 @@ title="If your JSON is not well-formed, you cannot run the test."
-
- +
- +
- +
- +
- +
- +
- + Open Client? + > + Open Client? +
-
+ class="code-editor" + v-model="settings.otherProps" + :highlight="highlighter" + line-numbers + />
-
+
- Your mod has {{ numErrors }} error(s). Check Menu > Validate Mod for more info. + Your mod has {{ numErrors }} error(s). Check Menu > Validate Mod for + more info.
Test Mod! + block + variant="primary" + @click="testMod()" + :disabled="!validOtherProps || !validTestProps || numErrors > 0" + > + Test Mod! +
- Kill LotR/MongoDB + + Kill LotR/MongoDB +
@@ -172,8 +160,8 @@ export default { x: 0, y: 0, openClient: true, - otherProps: '{\n \n}' - } + otherProps: '{\n \n}', + }, }; }, @@ -183,12 +171,17 @@ export default { computed: { numErrors() { - if(!this.mod) return 0; + if (!this.mod) return 0; return numErrorsForMod(this.mod); }, validTestProps() { - return this.settings.level > 0 && this.settings.map && this.settings.x > 0 && this.settings.y > 0; + return ( + this.settings.level > 0 && + this.settings.map && + this.settings.x > 0 && + this.settings.y > 0 + ); }, validOtherProps() { @@ -198,7 +191,7 @@ export default { } catch { return false; } - } + }, }, methods: { @@ -216,10 +209,15 @@ export default { map: this.settings.map, x: +this.settings.x, y: +this.settings.y, - ...JSON.parse(this.settings.otherProps) + ...JSON.parse(this.settings.otherProps), }); - window.api.send('TEST_MOD', { mod: this.mod, map: this.settings.map, settings, openClient: this.settings.openClient }); + window.api.send('TEST_MOD', { + mod: this.mod, + map: this.settings.map, + settings, + openClient: this.settings.openClient, + }); this.persist(); }, @@ -230,7 +228,7 @@ export default { async loadSettings() { const settings = await localforage.getItem('modtestsettings'); - if(settings) { + if (settings) { try { this.settings = JSON.parse(settings); } catch { @@ -240,7 +238,7 @@ export default { x: 0, y: 0, openClient: true, - otherProps: '{\n \n}' + otherProps: '{\n \n}', }; } } @@ -248,13 +246,13 @@ export default { persist() { localforage.setItem('modtestsettings', JSON.stringify(this.settings)); - } - } + }, + }, };