Added Component Configuration Section

FedUpWith-Tech 2021-05-14 19:03:46 -04:00
parent 06d63b5624
commit 71afbe5949

@ -53,170 +53,123 @@ storage:
#flags: "?allowReconnect=true"
```
***
### Components
This section allows you to configure any and all of Dynmap's functionality. Not all components can be enabled at once and a few are critical to Dynmap's functionality. This section will contain only a summary of each component; for detailed component configuration please go the the [[Component Configuration]] Page.
```
components:
```
#### [Client Configuration Component](https://github.com/webbukkit/dynmap/wiki/Component-Configuration#client-configuration-component)
This is a required component for Dynmap to run, there are no settings.
**Default is Enabled.**
```
- class: org.dynmap.ClientConfigurationComponent
```
#### [Internal Client Update Component](https://github.com/webbukkit/dynmap/wiki/Component-Configuration#internal-client-update-component)
This component controls Dynmap updating web clients that are connected to the internal web server. It should be enabled if you are using the internal webserver and DISABLED if you are using an external webserver.
**Default is Enabled.**
```
- class: org.dynmap.InternalClientUpdateComponent
sendhealth: true
sendposition: true
allowwebchat: true
webchat-interval: 5
hidewebchatip: false
trustclientname: false
includehiddenplayers: false
# (optional) if true, color codes in player display names are used
use-name-colors: false
# (optional) if true, player login IDs will be used for web chat when their IPs match
use-player-login-ip: true
# (optional) if use-player-login-ip is true, setting this to true will cause chat messages not matching a known player IP to be ignored
require-player-login-ip: false
# (optional) block player login IDs that are banned from chatting
block-banned-player-chat: true
# Require login for web-to-server chat (requires login-enabled: true)
webchat-requires-login: false
# If set to true, users must have dynmap.webchat permission in order to chat
webchat-permissions: false
# Limit length of single chat messages
chatlengthlimit: 256
# # Optional - make players hidden when they are inside/underground/in shadows (#=light level: 0=full shadow,15=sky)
# hideifshadow: 4
# # Optional - make player hidden when they are under cover (#=sky light level,0=underground,15=open to sky)
# hideifundercover: 14
# # (Optional) if true, players that are crouching/sneaking will be hidden
hideifsneaking: false
# If true, player positions/status is protected (login with ID with dynmap.playermarkers.seeall permission required for info other than self)
protected-player-info: false
# If true, hide players with invisibility potion effects active
hide-if-invisiblity-potion: true
# If true, player names are not shown on map, chat, list
hidenames: false
```
#### [JsonFileClientUpdateComponent](https://github.com/webbukkit/dynmap/wiki/Component-Configuration#json-file-client-update-component)
This component controls Dynmap updating web clients that are connected to an external web server. It should NOT be enabled if you are using the internal web server and ENABLED if you are using an external webserver.
**Default is Disabled.**
```
#- class: org.dynmap.JsonFileClientUpdateComponent
# writeinterval: 1
# sendhealth: true
# sendposition: true
# allowwebchat: true
# webchat-interval: 5
# hidewebchatip: false
# includehiddenplayers: false
# use-name-colors: false
# use-player-login-ip: false
# require-player-login-ip: false
# block-banned-player-chat: true
# hideifshadow: 0
# hideifundercover: 0
# hideifsneaking: false
# # Require login for web-to-server chat (requires login-enabled: true)
# webchat-requires-login: false
# # If set to true, users must have dynmap.webchat permission in order to chat
# webchat-permissions: false
# # Limit length of single chat messages
# chatlengthlimit: 256
# hide-if-invisiblity-potion: true
# hidenames: false
```
#### [SimpleWebChatComponent](https://github.com/webbukkit/dynmap/wiki/Component-Configuration#simple-chat-component)
This component controls the Server -> Web part of the chat bridge. Disabling this component will stop the server sending chat messages to the Web but it will NOT stop the web from sending chat to the server.
**Default is Enabled.**
```
- class: org.dynmap.SimpleWebChatComponent
allowchat: true
# If true, web UI users can supply name for chat using 'playername' URL parameter. 'trustclientname' must also be set true.
allowurlname: false
# Note: this component is needed for the dmarker commands, and for the Marker API to be available to other plugins
```
#### [Markers Component](https://github.com/webbukkit/dynmap/wiki/Component-Configuration#markers-component)
This component controls the built in map-marker functionality. It controls markers set via `/dmarker`, marker signs, and the API.
**Default is Enabled.**
```
- class: org.dynmap.MarkersComponent
type: markers
showlabel: false
enablesigns: false
# Default marker set for sign markers
default-sign-set: markers
# (optional) add spawn point markers to standard marker layer
showspawn: true
spawnicon: world
spawnlabel: "Spawn"
# (optional) layer for showing offline player's positions (for 'maxofflinetime' minutes after logoff)
showofflineplayers: false
offlinelabel: "Offline"
offlineicon: offlineuser
offlinehidebydefault: true
offlineminzoom: 0
maxofflinetime: 30
# (optional) layer for showing player's spawn beds
showspawnbeds: false
spawnbedlabel: "Spawn Beds"
spawnbedicon: bed
spawnbedhidebydefault: true
spawnbedminzoom: 0
spawnbedformat: "%name%'s bed"
# (optional) show world border (vanilla 1.8+)
showworldborder: true
worldborderlabel: "Border"
```
#### [Client Components](https://github.com/webbukkit/dynmap/wiki/Component-Configuration#client-side-chat-components)
These components control the user-experience of Dynmap. They adjust things like what elements are visible to the web client or custom logos visible to web users. For simplicities sake, the options for each of these components has been removed and can be found on the [Component Configuration Page.](https://github.com/webbukkit/dynmap/wiki/Component-Configuration#client-side-chat-components)
#### [Chat](https://github.com/webbukkit/dynmap/wiki/Component-Configuration#chat-client-component)
This component controls the Web -> Server part of the chat bridge. Disabling this component will disable web users from sending chat messages but not disable them from receiving chat messages. If you disable this component we highly recommend disabling the chat box component to completely remove that interface from the web.
**Default is Enabled.**
```
- class: org.dynmap.ClientComponent
type: chat
allowurlname: false
type: chat
```
#### [Chat Balloon](https://github.com/webbukkit/dynmap/wiki/Component-Configuration#chat-balloon-client-component)
This component allows pop-up chat balloons above player markers. Disabling it will stop chat messages from appearing above player's heads on the map. This component requires the player markers component to be enabled.
**Default is Enabled.**
```
- class: org.dynmap.ClientComponent
type: chatballoon
focuschatballoons: false
type: chatballoon
```
#### [Chatbox](https://github.com/webbukkit/dynmap/wiki/Component-Configuration#chat-box-client-component)
This component controls the web-chat interface. It controls how many lines of chat are viewable, the delay for messages, and if player faces are visible in the chat window. Disabling this will not disable web users from chatting, just hides the window. If you disable this component make sure to also disable the Chat component and vice versa.
**Default is Enabled.**
```
- class: org.dynmap.ClientComponent
type: chatbox
showplayerfaces: true
messagettl: 5
# Optional: set number of lines in scrollable message history: if set, messagettl is not used to age out messages
#scrollback: 100
# Optional: set maximum number of lines visible for chatbox
#visiblelines: 10
# Optional: send push button
sendbutton: false
type: chatbox
```
#### [Player Markers](https://github.com/webbukkit/dynmap/wiki/Component-Configuration#player-markers-component)
This component controls if player positions and names are shown on the map. This component must be enabled for the Chat Balloon component to function. Disabling this component will completely remove the player markers from the map.
**Default is Enabled.**
```
- class: org.dynmap.ClientComponent
type: playermarkers
showplayerfaces: true
showplayerhealth: true
# If true, show player body too (only valid if showplayerfaces=true
showplayerbody: false
# Option to make player faces small - don't use with showplayerhealth
smallplayerfaces: false
# Optional - make player faces layer hidden by default
hidebydefault: false
# Optional - ordering priority in layer menu (low goes before high - default is 0)
layerprio: 0
# Optional - label for player marker layer (default is 'Players')
label: "Players"
type: playermarkers
```
#### [Digital Clock](https://github.com/webbukkit/dynmap/wiki/Component-Configuration#digital-clock-component)
Note: Only one clock can be enabled at a time.
This Component shows a simple digital clock corresponding to the in-game time of the world currently being viewed. This clock is fairly accurate on Vanilla Minecraft but can often be inaccurate on Modded Minecraft or if you have any plugins that allow per-user time of day.
**Default is Disabled.**
```
#- class: org.dynmap.ClientComponent
# type: digitalclock
# type: digitalclock
```
#### [Time of Day Clock](https://github.com/webbukkit/dynmap/wiki/Component-Configuration#time-of-day-clock-component)
Note: Only one clock can be enabled at a time.
This Component shows a complex time-of-day clock corresponding to the in-game time of the world currently being viewed. Sun and Moon icons appear to traverse the clock This clock is fairly accurate on Vanilla Minecraft but can often be inaccurate on Modded Minecraft or if you have any plugins that allow per-user time of day.
**Default is Enabled.**
```
- class: org.dynmap.ClientComponent
type: link
type: timeofdayclock
```
#### [Link Button](https://github.com/webbukkit/dynmap/wiki/Component-Configuration#link-component)
This component adds a link button in the bottom right corner of the web interface that contains a link to the current map view. This button can be right-clicked and the link copied so that you can bookmark a location or share that view with someone else. Disabling this component will remove the link button from the web interface, manually copying the link from the URL will still allow you to save the current perspective.
**Default is Enabled.**
```
- class: org.dynmap.ClientComponent
type: timeofdayclock
showdigitalclock: true
showweather: true
# Mouse pointer world coordinate display
type: link
```
#### [Coordinate Panel](https://github.com/webbukkit/dynmap/wiki/Component-Configuration#coord-component)
Note: This is only accurate on the 2D view. The 3D view cannot accurately show perfectly correct coordinates.
This component controls the Coordinate Panel in the top left portion of the web interface. It displays the in-game coordinates of where the mouse pointer currently is. Disabling this will remove the Coordinate Panel from the web interface.
**Default is Enabled.**
```
- class: org.dynmap.ClientComponent
type: coord
label: "Location"
hidey: false
show-mcr: false
show-chunk: false
# Note: more than one logo component can be defined
type: coord
```
#### [Logo](https://github.com/webbukkit/dynmap/wiki/Component-Configuration#logo-component)
This component allows you to place a custom image in one of the corners of the map. Traditionally, this is a server logo or other branding and should be a PNG for transparency. A semi-transparent white background will be the background of the image. This does not scale images at all, the size of images uploaded will be the size on the screen (a 512x512 logo will be 512x512 on the web map).
**Default is Disabled.**
```
#- class: org.dynmap.ClientComponent
# type: logo
# text: "Dynmap"
# #logourl: "images/block_surface.png"
# linkurl: "http://forums.bukkit.org/threads/dynmap.489/"
# # Valid positions: top-left, top-right, bottom-left, bottom-right
# position: bottom-right
# type: logo
```
#### [Inactive Timeout]()
This component controls the inactive timer of the internal webserver. If you are using the internal webserver and would like users to be timed out from viewing the map after a set period of time, enable this. A custom timeout length and timeout page can be set.
**Default is Disabled.**
```
#- class: org.dynmap.ClientComponent
# type: inactive
```
#- class: org.dynmap.ClientComponent
# type: inactive
# timeout: 1800 # in seconds (1800 seconds = 30 minutes)
# redirecturl: inactive.html
# #showmessage: 'You were inactive for too long.'
#- class: org.dynmap.TestComponent
# stuff: "This is some configuration-value"
***
```
# Treat hiddenplayers.txt as a whitelist for players to be shown on the map? (Default false)
display-whitelist: false