Skip to content
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

Feature Request: MMP (Map export) support #1678

Open
Griatch opened this issue Oct 7, 2018 · 3 comments
Open

Feature Request: MMP (Map export) support #1678

Griatch opened this issue Oct 7, 2018 · 3 comments
Labels
feature-request A suggestion for new functionality. help wanted We specifically want more help on this one.

Comments

@Griatch
Copy link
Member

Griatch commented Oct 7, 2018

Description of requested feature:

MMP (I think it would mean Mud Map Protocol, maybe?) is a "standard" published by Iron Realms for exporting map data from server to client in the form of an XML document. This format is also supported by the Mudlet client.

Exporting map data would be interesting to us in order to serve as the dual purpose of passing the same to our web client. In this respect, using XML is not very useful - It'd be a lot better for us to use JSON. So an idea here would be to represent maps as Python dicts internally and convert them at the protocol level - to XML over the Telnet+GMCP bridge and JSON for the webclient / other connections.

Reasons for adding feature:

Map representation is a good feature to have and one commonly asked about. Whereas the client can already send a formatted map as-is, this implementation has the advantage of leaving it up to the client how to actually visibly represent the map data depending on its capabilities.

Expected result of feature

The ability of Evennia to prepare protocol-agnostic map data in Python-dict form and pass it to the client as XML/JSON depending on the protocol.

Extra information, such as Evennia revision/repo/branch, operating system and ideas for how to solve / implement:

A problem/limitation with the MMP which IRE acknowledges is that (in their own implementation) they send the entire map of a region all at once. This makes it less interesting to explore the map. They suggest it should be up to the client to cordon of parts of the map and only show parts of it as the user moves around ... but this appears to go against all rules of sane game server/client relationships. The way to do this would seem to be for the server to only pass the visible/discovered parts of the map to the client and show stub exits to locations not yet explored. It would need to be explored how well MMP would work for this kind of gradual presentation.


Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.

@Griatch Griatch added feature-request A suggestion for new functionality. develop-branch help wanted We specifically want more help on this one. labels Oct 7, 2018
@strikaco
Copy link
Contributor

strikaco commented Oct 8, 2018

For what it's worth, the pathfinder contrib already provides a framework for collecting and exporting this data in JSON Graph format. This MMP thing looks like a reinvention of GraphML, so it shouldn't be difficult to export to.

The graph can also be made to return only explored and adjacent unexplored nodes (similar to the lock-checking, but the logic would have to be standardized though) to handle the exploration concern.

My own concern is how to handle mapping to their idea of what constitutes an "area" and "environment" (or if those are even necessary? The spec is quite undeveloped).

@vadi2
Copy link

vadi2 commented Oct 8, 2018

Environment's purpose is to colour rooms, area is a logical area in the game, typically rendered as a set of rooms while excluding rooms outside of the area.

@strikaco
Copy link
Contributor

It's easy enough to create an XML tree based on rooms/exits but to really make the most of this I think we're lacking some other core functionality:

  • A native way of handling coordinates for games that opt into Cartesian layout
  • Some official construct of what constitutes a zone/plane/area
  • A way to keep track of what characters have visited what rooms
  • A way to specify what chars/colors a room should be represented as on a map (like __repr__(), but for visualization).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature-request A suggestion for new functionality. help wanted We specifically want more help on this one.
Projects
None yet
Development

No branches or pull requests

3 participants