online map view
Opened this issue · 7 comments
Would it be possible to see these maps online, like how dynmap does?
I think it would be, but it would almost certainly have the same color scheme as the map colors support. However, having complicated zooming, rotation and hud overlays requires a lot of additional web programming. I don't think Maplands should try to do better than what dynmap does, because dynmap is very well optimized for displaying maps online. It does so by efficient caching mechanics and a very well-designed online protocol. Rewriting all that for the sake of Maplands seems a bit pointless.
No reason you can't use both :)
+1 to replicating dynmap. Spectifically: trigger render + export of all chunks from server.
As a mod, you are using the engine to render the blocks/textures directly correct? This is a major limitation to external programs that need block texture definitions.
Specific example - FoolCraft2 has ~149 mods, particularly earth/leaves/flowers from BiomesOPlenty and marble from AstralSourcery to name just two. Dynmap struggles to keep up with this. Other don't bother. You might have the unique ability to bypass the biggest issue, and render directly.
Does my understanding of how it handles mods work like that??
I wrote my own engine, so not exactly. If mods use resource packs for the models of the blocks, then yes, but I'm not sure if that is the case. When resource packs are expanded more by Mojang allowing custom blocks and models, then yes, maplands will support all of that almost automatically.
My engine can interpret the model .json format used by Minecraft client and render them in isometric perspective onto a canvas. It has some quad/triangle render primitives to do this. No OpenGL is used though.
Ah - so like in 1.10 with no resource packs (just whats included inside the mod jar) wouldn't work?
Dont think so, no. Unless the mod jar has an assets subdirectory, then its possible to load it the same way it loads the Minecraft client jar's assets.
See also these files in BKCommonLib:
https://github.com/bergerhealer/BKCommonLib/blob/master/src/main/java/com/bergerkiller/bukkit/common/map/MapResourcePack.java
https://github.com/bergerhealer/BKCommonLib/blob/master/src/main/java/com/bergerkiller/bukkit/common/map/archive/MapResourcePackZipArchive.java
I support a whole lot of ways of loading model resources, even automatic downloads with hash checks, stored in a local cache.
I think a major problem might exist in the block to model name resolution though. Minecraft has no sane API server-side to retrieve the paths of the models, its mostly relying on common patterns.
https://github.com/bergerhealer/BKCommonLib/blob/master/src/main/java/com/bergerkiller/bukkit/common/map/util/ModelInfoLookup.java#L105
The mods do have assets subdirectory.
I'll get it the proper acid test tho. I'm now struggling to get Sponge to work with Forge 2488 on 1.10 (no longer in support), so battling with a 1.12 or just with a vanilla/sponge world. Thanks for the tips!
Forge isnt (yet?) supported by BKCommonLib, so for that it doesn't really matter yet. They lack the Bukkit API there to have things work. Porting BKC/TC to Sponge might be doable in the long term, but it'll take a while.