-
Notifications
You must be signed in to change notification settings - Fork 74
Configuration
Devin Spikowski edited this page Jan 25, 2018
·
14 revisions
discord-config.json
Changes to this file do not require running build
again
{
"token": "aT4SfVx09_44i9obsw34gJ.45zxjg_JEDOR_n-mgROER-IEri9obsw3",
"servers": [
{
"id": "1234567891234567",
"default": true,
"ignoreChannels": ["members-Only","testing"]
}
]
}
-
token
string, required - Your bot's token, found here -
servers
array, required - An array of server objects to make accessible to D-Zone. Your bot must already be in these servers.
-
id
string, required - The snowflake ID of the server. This can be found in Discord under Server Settings > Widget -
default
boolean, required once - This property must exist and equaltrue
for exactly one server in yourservers
array. It determines which server comes up by default for a new visitor. -
password
string, optional - Adding this property will prompt the user for a password when connecting -
ignoreChannels
array, optional - Ignore messages in these channels. You can use channel IDs or names. Can not be used together withlistenChannels
-
listenChannels
array, optional - Listen to messages only in these channels. You can use channel IDs or names. Can not be used together withignoreChannels
-
ignoreUsers
array, optional - Ignore messages from these users. User IDs must be used. -
alias
string, optional - Change the name of your server as it appears in D-Zone
socket-config.json
Changes to this file require running build
again and re-uploading bundle.js
{
"address": "192.168.0.1",
"port": "3000"
}
-
address
string, required - The IP of the server or computer that is runningnpm start
. This must be an external IP if your D-Zone is to be viewed by the rest of the internet, or any computer outside of the server's local network -
port
string, required - The port number for the websocket to run on. This port must not be in use by any other application, and must be accessible from outside traffic (check port-forwarding on your router). It is recommended that you use a number above 3000 to avoid reserved ports.
misc-config.json
Changes to this file require running build
again and re-uploading bundle.js
The existence of this file and all properties within is optional
{
"textbox": {
"maxWidth": 96,
"linesPerPage": 4,
"scrollSpeeds": [
[0, 3],
[75, 2],
[150, 1]
],
"pageDelay": 5,
"finalDelay": 30,
"openTime": 10,
"closeTime": 8,
"bgColor": "rgba(0, 0, 0, 0.7)"
}
}
-
textbox
object - Parameters related to chat message text boxes-
maxWidth
integer - Maximum width (in pixels) of text boxes. Do not set this below16
-
linesPerPage
integer - Maximum number of lines on each page of text before the box is cleared and the next page continues -
scrollSpeeds
array - Contains integer 2-tuples ([0,3]
) indicating scroll speed for a minimum message length. The speed is measured in number of ticks per character (1 tick is 1/60th of a second), so a higher number means slower speed. Do not use decimals or0
. For example,[0,3]
means for any message greater or equal to length0
(which is every message), use tick speed3
. Adding[50,2]
to the list means that if the message is50
or more characters, tick speed2
will be used instead. -
pageDelay
integer - Multiplier for scroll speed when the end of a page is reached. For example, if a message is scrolling at speed2
and thepageDelay
is5
, there will be a10
tick pause at the end of each page, except for the last page. -
finalDelay
integer - Multiplier for scroll speed when the end of the message is reached. This works the same aspageDelay
except only occurs after the last of the message has appeared. -
openTime
integer - Duration of the text box opening animation in ticks (1 tick is 1/60th of a second) -
closeTime
integer - Duration of the text box closing animation in ticks -
bgColor
rgba string - Background color of the text box. This must be anrgba
string in the format ofrgba(255, 255, 255, 1)
, which represents Red, Green, Blue, and Opacity. Opacity can be decimal value from 0-1.
-