Register forum user name Search FAQ

Gammon Forum

Notice: Any messages purporting to come from this site telling you that your password has expired, or that you need to verify your details, confirm your email, resolve issues, making threats, or asking for money, are spam. We do not email users with any such messages. If you have lost your password you can obtain a new one by using the password reset link.

Due to spam on this forum, all posts now need moderator approval.

 Entire forum ➜ MUSHclient ➜ Plugins ➜ Mapper for Prophecy MUD

Mapper for Prophecy MUD

It is now over 60 days since the last post. This thread is closed.     Refresh page


Posted by Nick Gammon   Australia  (23,173 posts)  Bio   Forum Administrator
Date Wed 05 Feb 2020 12:11 AM (UTC)

Amended on Thu 13 Feb 2020 10:37 PM (UTC) by Nick Gammon

Message

Installation

First go to this page and download the three files mentioned: http://gammon.com.au/forum/?id=14607

Install as directed in that post.


Configuration

Copy/paste below into your command window (you can do the lot in a batch) to set various configuration options:

mapper config when_to_draw                             prompt
mapper config activate_description_after_exits         No
mapper config activate_description_after_room_name     No
mapper config add_newline_to_prompt                    No
mapper config blank_line_terminates_line_type          Yes
mapper config exits_on_room_name                       No
mapper config include_exits_in_hash                    Yes
mapper config exits_is_single_line                     Yes
mapper config prompt_is_single_line                    Yes
mapper config exit_lines_start_with_direction          No
mapper config sort_exits                               Yes
mapper config status_background                        black
mapper config status_border                            #1B1B1B
mapper config status_text                              lightgreen
mapper config uid_size                                 4
mapper config show_info                                No
mapper config show_warnings                            Yes
mapper config show_room_and_exits                      No

Prompt

Set your prompt to show the room name in square brackets, like this:

prompt <%h/%Hhp %m/%Mm %v/%Vmv %Xtnl [%r] >%c%c

You can add colours, but the trigger expects the prompt to look like that. If you want a different prompt, amend the trigger (below). The important things are:

  • That the trigger actually fires (temporarily set it to recolour the line to check that)
  • That the room name is captured as wildcard #1

Triggers

To help the mapper learn the room name the following trigger should be added to your world file.

See http://www.gammon.com.au/pasting for how to copy from below and paste into your world file.


<!-- All lines - suppress lines that are not descriptions -->

<triggers>
  <trigger
   enabled="y"
   keep_evaluating="y"
   match="*"
   name="All_lines"
   send_to="12"
   sequence="1"
  >
  <send>  

  -- after exits we don't have descriptions
  if have_exits then
    CallPlugin ("99c74b2685e425d3b6ed6a7d", "set_not_line_type", "description")
  end -- if

  </send>
  </trigger>

<!-- Exits -->

  <trigger
   enabled="y"
   keep_evaluating="y"
   match="[Exits: *]"
   name="Exits_line"
   send_to="12"
   sequence="100"
  >
  <send>  

  CallPlugin ("99c74b2685e425d3b6ed6a7d", "set_line_type", "exits", "%1")
  CallPlugin ("99c74b2685e425d3b6ed6a7d", "do_not_deduce_line_type", "exits")
  have_exits = true

  </send>
  </trigger>

<!-- Prompt -->

  <trigger
   enabled="y"
   match="^&lt;\d+/\d+hp \d+/\d+m \d+/\d+mv \d+tnl \[(.*)\] &gt;"
   name="Prompt_line"
   regexp="y"
   send_to="12"
   sequence="100"
  >
  <send>  
  CallPlugin ("99c74b2685e425d3b6ed6a7d", "set_line_type", "prompt")
  CallPlugin ("99c74b2685e425d3b6ed6a7d", "do_not_deduce_line_type", "prompt")
  CallPlugin ("99c74b2685e425d3b6ed6a7d", "set_line_type_contents", "room_name", [====[%1]====])
  CallPlugin ("99c74b2685e425d3b6ed6a7d", "do_not_deduce_line_type", "room_name")
  have_exits = false

  </send>
  </trigger>
</triggers>

Training

Don’t bother training exit lines and prompts, as the triggers will override that. Train descriptions, and “do not move” lines.

Note: Because room names look very much like descriptions (they are adjacent and the same colour) then include the room names (the ones just above the descriptions) in the description training.


Save the map, and backups

The mapping database is saved in the plugin’s “state” file which is automatically saved when you save the world file. Thus you must make sure to save the current world file, in order to save the map (and the mapping corpus). Also you might want to save them separately as shown below just in case.

mapper export map
mapper export corpus

Example output


- Nick Gammon

www.gammon.com.au, www.mushclient.com
Top

The dates and times for posts above are shown in Universal Co-ordinated Time (UTC).

To show them in your local time you can join the forum, and then set the 'time correction' field in your profile to the number of hours difference between your location and UTC time.


6,938 views.

It is now over 60 days since the last post. This thread is closed.     Refresh page

Go to topic:           Search the forum


[Go to top] top

Information and images on this site are licensed under the Creative Commons Attribution 3.0 Australia License unless stated otherwise.