Open unreal4me opened 5 months ago
Allowing to add custom data and updating them dynamically sounds like a good idea. I think using a separate file instead of entities.json
would be preferable, so the generator doesn't have to handle the additional entries.
Before adding more features to the viewer, I intend to convert the code to Typescript to make it easier to maintain, but I'm not sure when I'll get around to do that.
Most of this is just to fill time, I guess, as minecraft servers tend to use paper which have other map plugins that take that data straight from the server. Coincidentally some of those written in Rust also :)
Before adding more features to the viewer, I intend to convert the code to Typescript to make it easier to maintain, but I'm not sure when I'll get around to do that.
I think switching to TypeScript might create a higher barrier to contributions, but importantly add a heavy dependency. Right now I could (and do) patch the JavaScript code to add a couple of things I need, but a TS viewer would be more complex to work with.
I don't want to derail this thread, but happy to help improving the existing JavaScript code, if there are specific pain points in your mind, @neocturne
A nice feature request to use this on a minecraft server would be to add, for example, players and display them dynamically on the map. One could take the data with RCON or any other means and append it to entities.json say: "players" : [ {"x":656,"y":97,"z":473,"name":"PlayerOne","icon":"some_head_icon", "public": "should_display_or_not?"} ] And in MinedMap.js you could go for something as simple as a setTimeout or a worker that fetches and postMessages back the playerinfo.