Move grayHiddenPlayers to playerMarkers component
This commit is contained in:
parent
7bff12b729
commit
b3f186a197
@ -44,7 +44,7 @@ export default defineComponent({
|
||||
setup(props) {
|
||||
const store = useStore(),
|
||||
otherWorld = computed(() => {
|
||||
return store.state.configuration.grayHiddenPlayers
|
||||
return store.state.components.playerMarkers?.grayHiddenPlayers
|
||||
&& !props.player.hidden
|
||||
&& (!store.state.currentWorld || store.state.currentWorld.name !== props.player.location.world);
|
||||
}),
|
||||
|
1
src/index.d.ts
vendored
1
src/index.d.ts
vendored
@ -280,6 +280,7 @@ interface LiveAtlasPartialComponentConfig {
|
||||
}
|
||||
|
||||
interface LiveAtlasPlayerMarkerConfig {
|
||||
grayHiddenPlayers: boolean;
|
||||
hideByDefault: boolean;
|
||||
layerName: string;
|
||||
layerPriority: number;
|
||||
|
@ -56,7 +56,6 @@ export default class DynmapMapProvider extends MapProvider {
|
||||
|
||||
private static buildServerConfig(response: any): LiveAtlasServerConfig {
|
||||
return {
|
||||
grayHiddenPlayers: response.grayplayerswhenhidden || false,
|
||||
defaultMap: response.defaultmap || undefined,
|
||||
defaultWorld: response.defaultworld || undefined,
|
||||
defaultZoom: response.defaultzoom || 0,
|
||||
@ -172,6 +171,7 @@ export default class DynmapMapProvider extends MapProvider {
|
||||
|
||||
case "playermarkers":
|
||||
components.playerMarkers = {
|
||||
grayHiddenPlayers: response.grayplayerswhenhidden || false,
|
||||
hideByDefault: component.hidebydefault || false,
|
||||
layerName: component.label || "Players",
|
||||
layerPriority: component.layerprio || 0,
|
||||
|
Loading…
Reference in New Issue
Block a user