Skip to content

Commit

Permalink
1.7.10
Browse files Browse the repository at this point in the history
  • Loading branch information
mysticdrew committed Mar 8, 2024
1 parent 1b1a938 commit 78b590c
Show file tree
Hide file tree
Showing 7 changed files with 7 additions and 36 deletions.
1 change: 1 addition & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ on:
push:
branches-ignore:
- 'master'
- 'journeymap_legacy_webmap_client'

pull_request:

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/master.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: Master
on:
push:
branches:
- 'legacy_version'
- 'journeymap_legacy_webmap_client'

jobs:
build:
Expand Down
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
@@ -1 +1 @@
release=0.9-SNAPSHOT
release=0.8-SNAPSHOT
1 change: 1 addition & 0 deletions src/main/js/api.js
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,7 @@ export async function getPolygons() {
}

export function getResourceUrl(resource) {
console.log(resource)
return URLS.RESOURCES.format({ resource: encodeURIComponent(resource) })
}

Expand Down
4 changes: 0 additions & 4 deletions src/main/js/datastore.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ import dayIconActive from "../images/day-active.png"
import followIconOff from "../images/follow-off.png"
import jmIcon from "../images/journeymap.png"
import nightIcon from "../images/night.png"
import topoIcon from "../images/topo.png"
import undergroundIcon from "../images/underground.png"

const browser = Bowser.getParser(window.navigator.userAgent)
Expand All @@ -26,7 +25,6 @@ export default {
dayIcon: dayIconActive,
followIcon: followIconOff,
nightIcon: nightIcon,
topoIcon: topoIcon,
undergroundIcon: undergroundIcon,

markers: [],
Expand All @@ -35,8 +33,6 @@ export default {
waypoints: [],

caveMappingAllowed: true,
surfaceMappingAllowed: true,
topoMappingAllowed: true,

playerBiome: "N/A",
playerWorld: "N/A",
Expand Down
24 changes: 3 additions & 21 deletions src/main/js/journeymap.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,6 @@ import markerPlayer from "../images/player/self.png"
import nightIcon from "../images/night.png"
import nightIconActive from "../images/night-active.png"
import nightIconDisabled from "../images/night-disabled.png"
import topoIcon from "../images/topo.png"
import topoIconActive from "../images/topo-active.png"
import topoIconDisabled from "../images/topo-disabled.png"
import { translateCoords } from "./utils"
import undergroundIcon from "../images/underground.png"
import undergroundIconActive from "../images/underground-active.png"
Expand Down Expand Up @@ -135,8 +132,6 @@ class Journeymap {
return
}

datastore.state.surfaceMappingAllowed = status.allowedMapTypes.surface
datastore.state.topoMappingAllowed = status.allowedMapTypes.topo
datastore.state.caveMappingAllowed = status.allowedMapTypes.cave

const now = Date.now()
Expand Down Expand Up @@ -181,14 +176,6 @@ class Journeymap {

let mapType = this.currentMapType

if ((! datastore.state.surfaceMappingAllowed) && (mapType === "day" || mapType === "night")) {
mapType = "topo"
}

if ((! datastore.state.topoMappingAllowed) && mapType === "topo") {
mapType = "underground"
}

if ((! datastore.state.caveMappingAllowed) && mapType === "underground") {
mapType = "day"
}
Expand Down Expand Up @@ -246,7 +233,7 @@ class Journeymap {
markers.push({
className: "round-icon",
latLng: translateCoords(animal.posX, animal.posZ),
url: getResourceUrl(animal.iconLocation),
url: getResourceUrl(animal.filename),
size: 15,
zIndex: 2,

Expand Down Expand Up @@ -274,7 +261,7 @@ class Journeymap {
markers.push({
className: "round-icon",
latLng: translateCoords(mob.posX, mob.posZ),
url: getResourceUrl(mob.iconLocation),
url: getResourceUrl(mob.filename),
size: 15,
zIndex: 2,

Expand Down Expand Up @@ -302,7 +289,7 @@ class Journeymap {
markers.push({
className: "round-icon",
latLng: translateCoords(villager.posX, villager.posZ),
url: getResourceUrl(villager.iconLocation),
url: getResourceUrl(villager.filename),
size: 15,
zIndex: 2,

Expand Down Expand Up @@ -452,13 +439,11 @@ class Journeymap {
setMapMode(mapMode) {
datastore.state.dayIcon = dayIcon
datastore.state.nightIcon = nightIcon
datastore.state.topoIcon = topoIcon
datastore.state.undergroundIcon = undergroundIcon

if (this.currentDim === - 1) { // Nether has only cave mode
datastore.state.dayIcon = dayIconDisabled
datastore.state.nightIcon = nightIconDisabled
datastore.state.topoIcon = topoIconDisabled
datastore.state.undergroundIcon = undergroundIconActive

this.currentMapType = "underground"
Expand All @@ -480,9 +465,6 @@ class Journeymap {
case "night":
datastore.state.nightIcon = nightIconActive
break
case "topo":
datastore.state.topoIcon = topoIconActive
break
case "underground":
datastore.state.undergroundIcon = undergroundIconActive
break
Expand Down
9 changes: 0 additions & 9 deletions src/main/resources/assets/journeymap/web/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -98,15 +98,6 @@

<l-control :position="'topleft'"
class="leaflet-bar leaflet-control">
<a @click="setMapMode('day')" id="mapTypeDay" v-if="surfaceMappingAllowed">
<img :src="dayIcon"/>
</a>
<a @click="setMapMode('night')" id="mapTypeNight" v-if="surfaceMappingAllowed">
<img :src="nightIcon"/>
</a>
<a @click="setMapMode('topo')" id="mapTypeTopo" v-if="topoMappingAllowed">
<img :src="topoIcon"/>
</a>
<a @click="setMapMode('underground')" id="mapTypeUnderground" v-if="caveMappingAllowed">
<img :src="undergroundIcon"/>
</a>
Expand Down

0 comments on commit 78b590c

Please sign in to comment.