From 93b4cb9efedd6fc90824f2e28c2a59f3c162ef4b Mon Sep 17 00:00:00 2001 From: Kyep Date: Sat, 19 Oct 2019 23:56:29 -0700 Subject: [PATCH] Option to activate forum account when clicking 'forum' button --- interface/interface.dm | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/interface/interface.dm b/interface/interface.dm index 8edded38e93..a733b8fed78 100644 --- a/interface/interface.dm +++ b/interface/interface.dm @@ -47,9 +47,11 @@ set desc = "Visit the forum." set hidden = 1 if(config.forumurl) - if(alert("This will open the forum in your browser. Are you sure?",,"Yes","No")=="No") - return - src << link(config.forumurl) + if(config.forum_link_url && prefs && !prefs.fuid) + if(alert("You need to activate your forum account. Activate now? (takes 2 seconds)",,"Yes","No")=="Yes") + link_forum_account() + if(alert("Open the forum in your browser?",,"Yes","No")=="Yes") + src << link(config.forumurl) else to_chat(src, "The forum URL is not set in the server configuration.") @@ -85,7 +87,7 @@ src << link(config.discordurl) else to_chat(src, "The Discord URL is not set in the server configuration.") - + /client/verb/donate() set name = "Donate" set desc = "Donate to help with hosting costs." @@ -96,7 +98,7 @@ src << link(config.donationsurl) else to_chat(src, "The rules URL is not set in the server configuration.") - + /client/verb/hotkeys_help() set name = "Hotkey Help" set category = "OOC"