Merge pull request #9413 from Ty-Omaha/button

Adds a Discord button & stylizes the Karma Shop and Donate buttons
This commit is contained in:
Crazy Lemon
2018-09-29 17:48:48 -07:00
committed by GitHub
4 changed files with 36 additions and 6 deletions
+6 -2
View File
@@ -85,6 +85,7 @@
var/githuburl = "http://example.org"
var/donationsurl = "http://example.org"
var/repositoryurl = "http://example.org"
var/discordurl = "http://example.org"
var/overflow_server_url
var/forbid_singulo_possession = 0
@@ -388,7 +389,10 @@
if("githuburl")
config.githuburl = value
if("discordurl")
config.discordurl = value
if("donationsurl")
config.donationsurl = value
@@ -782,4 +786,4 @@
if(M.can_start())
runnable_modes[M] = probabilities[M.config_tag]
// to_chat(world, "DEBUG: runnable_mode\[[runnable_modes.len]\] = [M.config_tag]")
return runnable_modes
return runnable_modes
+3
View File
@@ -183,6 +183,9 @@ CHECK_RANDOMIZER
## GitHub address
# GITHUBURL http://example.org
## Discord address
# DISCORDURL http://example.org
## Donations address
# DONATIONSURL http://example.org
+12
View File
@@ -78,6 +78,18 @@
to_chat(src, "<span class='danger'>The GitHub URL is not set in the server configuration.</span>")
return
/client/verb/discord()
set name = "Discord"
set desc = "Join our Discord server."
set hidden = 1
if(config.discordurl)
if(alert("This will invite you to our Discord server. Are you sure?",,"Yes","No")=="No")
return
src << link(config.discordurl)
else
to_chat(src, "<span class='danger'>The Discord URL is not set in the server configuration.</span>")
return
/client/verb/donate()
set name = "Donate"
set desc = "Donate to help with hosting costs."
+15 -4
View File
@@ -1697,18 +1697,29 @@ window "rpane"
size = 67x16
text = "Changelog"
command = "Changelog"
elem "karma"
elem "discordb"
type = BUTTON
pos = 487,0
size = 67x16
size = 60x16
background-color = #7289DA
text-color = #FFFFFF
font-style = bold
text = "Discord"
command = "discord"
elem "karma"
type = BUTTON
pos = 552,0
size = 77x16
background-color = #ff8040
font-style = bold
text = "Karma Shop"
command = "karmashop"
elem "donate"
type = BUTTON
pos = 559,0
pos = 634,0
size = 60x16
background-color = #8080ff
background-color = #008000
font-style = bold
text = "Donate"
command = "Donate"
elem "browseb"