Old MUSH Import

I’ve had a couple folks ask about this, so I figured I’d mention it on the forum.

It is possible to import stuff from an old Penn or Tiny game to an Ares game. It requires two steps:

Export

Write some export code on the old game to emit the data to you and then log it to a file - preferably in JSON or YAML format (something Ares can easily parse).

For example, something trivial could be:

   @pemit me=characters:%R
   @dolist lsearch(all,type,player)={@pemit me=%B%B-%R%B%B%B%Bname: [name(##)]%R%B%B%B%Bdescription: [xget(##,describe)]}

That will emit you all characters with their names and descriptions in YAML format.

Remember that YAML really cares about indendtation.

Import

Once you have the YAML file, upload it to your game server. Then you can read and parse that file in the tinker handler:

In tinker_cmd.rb:

def handle
   file = File.read(path_to_your_yaml_file, :encoding => "UTF-8")
   data = YAML.load(file)
   data['characters'].each do |import|
      char = Character.create(name: import['name'], 
                              description: import['description'])
   end
end

Data Mapping

In the simple example above, all we did was create a placeholder character object with the old PennMUSH name and description.

If you have other character data that you want to import, you’ll have to figure out an Ares equivalent for the data. For example: an old “fullname” attribute might map to char.update_demographic(:fullname, import['fullname']).

While you can kind-of migrate FS3 skills by mapping old to new skill levels, it’s very ugly and the points don’t really balance fairly. I recommend you just let people redo chargen in the new system.

Other Objects

You can do the exact same thing described above for rooms.

Exits are trickier (since they reference rooms), and frankly it’s probably easier to just link the rooms up manually rather than trying to write import code.

“Thing” objects don’t exist in Ares, so you’ll have to figure out how to handle them manually (probably as room or character details).

And, of course, you can’t really import code because the entire code base works differently.

Hope that helps!