Skip to content

Commit 524632f

Browse files
Reorganized menu options and added links to the Help menu.
1 parent 20b56ba commit 524632f

File tree

4 files changed

+28
-2
lines changed

4 files changed

+28
-2
lines changed

extensions/discord.svg

Lines changed: 1 addition & 0 deletions
Loading

extensions/includes/help.mjs

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
import { openUrl } from "./util.mjs";
2+
3+
const wikiHelpAction = tiled.registerAction('OpenWikiHelp', () =>
4+
openUrl('https://undertale.wiki/d/t/interactive-maps-project/318'));
5+
wikiHelpAction.text = 'Wiki extension help ↗';
6+
wikiHelpAction.icon = 'wiki.svg';
7+
8+
const wikiDiscordAction = tiled.registerAction('OpenWikiDiscord', () =>
9+
openUrl('https://undertale.wiki/w/Project:Discord'));
10+
wikiDiscordAction.text = 'Undertale/Deltarune Wiki Discord ↗';
11+
wikiDiscordAction.icon = 'discord.svg';
12+
13+
tiled.extendMenu('Help', [
14+
{
15+
separator: true
16+
},
17+
{
18+
action: 'OpenWikiHelp'
19+
},
20+
{
21+
action: 'OpenWikiDiscord'
22+
}
23+
]);

extensions/includes/popup.mjs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -164,8 +164,9 @@ const /** @type {Record<MapObjectShape, MarkerPopupHandler|undefined>} */ handle
164164
const enablePopup = tiled.registerAction('WikiMarkerPopup', () => {});
165165
enablePopup.checkable = true;
166166
enablePopup.checked = true;
167+
enablePopup.icon = 'wiki.svg';
167168
enablePopup.iconVisibleInMenu = false;
168-
enablePopup.text = 'Enable marker popup';
169+
enablePopup.text = 'Enable wiki marker popup';
169170
enablePopup.shortcut = 'Ctrl+Shift+M';
170171

171172
/**

extensions/includes/publish.mjs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -178,6 +178,7 @@ publishAction.shortcut = 'Ctrl+Shift+U';
178178

179179
tiled.extendMenu('File', [
180180
{
181-
action: 'PublishToWiki'
181+
action: 'PublishToWiki',
182+
before: 'Close'
182183
}
183184
]);

0 commit comments

Comments
 (0)