-
Notifications
You must be signed in to change notification settings - Fork 19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Visual Prospecting/Journeymap Integration #9
Conversation
src/main/java/serverutils/handlers/ServerUtilitiesClientEventHandler.java
Outdated
Show resolved
Hide resolved
Do ask the GTDevelopers for a review when this is ready. |
…t to certain ranks/players. On by default.
No comments on the code, but it loads, runs, and works in the latest nightly. |
Does VP have a hard-dep on GT? If so, it would be nice to not depend on VP here, if possible. |
There's no hard dep on VP here, runs as per usual without it. |
I should've clarified: I meant hard-dep with respect to this feature. |
The way it works is by using VPs “ore handling” so that part would have to be brought over for modpacks without VP |
I agree for sure. But doing it without VP is gonna be quite the pain seeing as Journeymap doesn't have any api in 1.7.10... The ideal solution if the license allows it would be implementing an api in Journeymap so we don't have to rely on mixins. Or alternatively making a whole other mod and move VPs mixins there, so that the whole 1.7.10 community would be able to utilize it without relying on GT. |
Apparently JourneymapLegacy is now LGPL and they are open to patches: https://github.com/TeamJM/journeymap-legacy but we'd probably have to write the API ourselves and upstream it |
Journeymap is FOSS for 1.7.10 https://github.com/TeamJM/journeymap-legacy There is also an API, but it's not FOSS (just visible source), and for 1.8+ https://github.com/TeamJM/journeymap-api
👍 |
If it works, it doesn't have unnecessary hard deps, and it's an improvement, let's ship it and iterate |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just went and checked the license for JourneymapAPI, it’s ARR sadly…
Otherwise I would really like it if this wasn’t dependent on VP.
e1f35be
to
219f23b
Compare
Yeah we’d have to create a new API for journeymap-legacy. Probably worthwhile if we continue to add more features (and I could see eventual expansion of serverUtilities to replace more and more of thermos doing that). I’ve been running this for awhile and it’s working fine. Maybe a tooltip hover over the on/off icon in JM to explain how to use it? Or at least document it in ServerUtilities. |
Just 1 thing, have a friend that tried to use this in GT6 and found out that VP Crashes hard so this don't work with that mod. |
@Ethryan Can you post the crash report? |
@Ethryan I doubt there's much we can do about that until an api becomes available. Am I good to merge for now? |
Yes, I think so |
Finally the ability to see all those lovely claims at once.
Chunks will be brighter when loaded and will be the same color as your team color.
Unloaded/Loaded difference
Hovering over a claim will show the teams name, whether they're an ally and if the chunk is loaded.
If admins only want players to see their own team they can set the "serverutilities.journeymap.other" permission to false.
If they want to disable it entirely for certain ranks/players, the "serverutilities.journeymap.enable" permission can be set to false.
Due to api constraints only limited chunk interaction is available.
Double click toggles loaded/unloaded state and the VP "deplete" key will unclaim the chunk. It's not currently possible to interact with unclaimed chunks so no claiming available.
Chunk info is requested by the client once they're in view of the map if the overlay has been toggled on. In order to not spam the server with packets every time a player moves the map or walks around with the overlay turned on a 10 second timer has been set between requests. This is just a random number that I picked out a hat and certainly not the greatest solution, any suggestions are very welcome.
Due to this all chunks that the client receive are kept in memory whilst connected to the server, when tested with 2800 chunks that only amounted to about 182kb of memory according to VisualVM so it should be fine.
The exception to this is the unclaim/remove packet which is sent by the server to everyone whenever a chunk is unclaimed. I was unable to figure out a better way to remove chunks on client side.
Map screenshot
Overview of 2200 or so claims