Image Maps

Image Map Signage

The camera spell can be used from the command-line to decorate your world with images. There are a few key parameters:

  • name: A player's name, to create a portrait. Can also be used to set a custom name for an id or url map.
  • url: A full url to a PNG image to show on the map.
  • x: The x offset, in pixels, to start rendering from. Default is 0.
  • y: The y offset, in pixels, to start rendering from. Default is 0.
  • width: How many x pixels of the image to use. Default is 128.
  • height: How many y pixels of the image to use. Default is 128.

Or, you can use the following to get an existing map:

  • id: A map id : Useful for creating a copy of an existing map (this can be done with /give, too)

You can use "/magic list maps <keyword>" in-game or via the console to search for maps. The list will include the id's, so you can then use "/cast camera id <id>" to get a copy of a previously loaded map.

Maps are loaded on demand (both from the web and into memory), and cached on the server for performance. If you wish to clear this cache, use "/magic clearcache".

Using /castp from the console can help you get around the command-line length limitations for using longer urls.

Map URLs are saved in data/imagesmaps.yml. This file can be manually edited, though Magic saves to it frequently so editing while the server is offline is best. If you do edit the file, you may create new entries by specifying a non-integer string (e.g. "new1") as the key. Magic will generate a new map and id for your entry on next start. Make sure to create a backup, YML is a fickle mistress.

Other Examples

Instructional Signage

You can also set up command blocks that use "castp @p camera id <foo>" to give out artwork or portraits. "castp @p camera target self" can be used for a photo booth.

Art!


Comments

Posts Quoted:
Reply
Clear All Quotes