Notice: Any messages purporting to come from this site telling you that your password has expired, or that you need to "verify" your details, 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.
Entire forum
➜ MUSHclient
➜ Plugins
➜ MUSHclient generic graphical mapper module
MUSHclient generic graphical mapper module
|
It is now over 60 days since the last post. This thread is closed.
Refresh page
Pages: 1
2
3
4
5
6
7
8
9 10
11
12
13
14
15
16
17
Posted by
| Jakaiya
(4 posts) Bio
|
Date
| Reply #120 on Fri 07 May 2010 11:53 PM (UTC) Amended on Sat 08 May 2010 12:39 AM (UTC) by Jakaiya
|
Message
|
Nick Gammon said:
Try downloading their XML file which lists amongst other things their area codes. A couple of pages back in this thread, I think, is how to do it. There is a plugin you download from the Git site, and you download the Achaea mapper xml file from their site.
When importing the xml file for Midkemiaonline I get the following error
Run-time error
World: Midkemia
Function/Sub: create_map_database called by alias
Reason: processing alias ""
[string "Plugin"]:289: Function 'io.lines' disabled in Lua sandbox - see MUSHclient global preferences
stack traceback:
[C]: in function 'error'
[string "Sandbox"]:39: in function 'lines'
[string "Plugin"]:289: in function <[string "Plugin"]:208>
EDIT: ok so I figured out the issue. If anyone is going to use this make sure you go into your global properties and trust the game id and plugin ID in your LUA tab. | Top |
|
Posted by
| Larkin
(278 posts) Bio
|
Date
| Reply #121 on Mon 10 May 2010 07:49 PM (UTC) |
Message
| Here's a fun feature!
When standing at room 4932, if I do MAPPER GOTO 4932, I walk out of the room and walk back in. Needs a simple check to see if you're already in the room, for anyone who might be trying to walk to people and/or spamming the goto command. :) | Top |
|
Posted by
| Nick Gammon
Australia (23,046 posts) Bio
Forum Administrator |
Date
| Reply #122 on Mon 10 May 2010 09:11 PM (UTC) |
Message
| |
Posted by
| LupusFatalis
(154 posts) Bio
|
Date
| Reply #123 on Fri 14 May 2010 05:50 AM (UTC) |
Message
| Hey, I've been using the serialization thing that you gave an example of to do my database for the mapper. I've got one area that is up to ~4500 rooms. The file is up to about 2500KB. I'm just curious how much this method can really handle--i.e. should I invest some time into figuring out how to database with sql or something, and further how to script some sort of transfer. For reference, I'll probably have another dozen or so areas equally large. | Top |
|
Posted by
| Nick Gammon
Australia (23,046 posts) Bio
Forum Administrator |
Date
| Reply #124 on Fri 14 May 2010 06:00 AM (UTC) |
Message
| Hmm, yes well the serialization was really to keep the example simple. My main mapper plugin uses the SQLite database. Check this out:
http://github.com/nickgammon/plugins/blob/master/ATCP_Mapper.xml
Adding to the database, and querying it, are quite straightforward, and you just need to create the tables initially if they don't exist (all this is in the plugin).
The database will save memory eventually because you only need some rooms in memory at once rather than all of them. In my plugin once a room is accessed I keep it in memory for speed, but I assume that in one session you won't visit every possible room.
The serialization will eventually introduce a lag spike when the plugin is first loaded (as it reads in megabytes of data) and when the world is saved (as it is all written out again). |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | Top |
|
Posted by
| LupusFatalis
(154 posts) Bio
|
Date
| Reply #125 on Fri 14 May 2010 03:37 PM (UTC) |
Message
| Alright, I think I'm going to do that. I'll probably try to get this done over next week.
I think I'll try to incorporate all the maps into one map at the same time. As it is, I manually switch the databases, which isn't a huge problem since the "areas" are so large--just a bit of a pain. Not yet sure how I'll do that yet, but I figure this transitional phase is probably as good a time as any to puzzle that out and make that change as well.
I shall post my results after I finish or hit a wall! Thanks again. | Top |
|
Posted by
| Maxhrk
USA (76 posts) Bio
|
Date
| Reply #126 on Thu 20 May 2010 11:01 PM (UTC) Amended on Thu 20 May 2010 11:04 PM (UTC) by Maxhrk
|
Message
| I dunno if you have forgot to added a function for this variable in init:
I have noticed that it does exist ATCP_Mapper.xml but not in mapper.lua. So, I wonder if you are going to implement it eventually?
inquisitively,
~maxhrk
EDIT:
nevermind, i found a updated version of mapper.lua that now has it. Excuse me. :3 | Top |
|
Posted by
| Maxhrk
USA (76 posts) Bio
|
Date
| Reply #127 on Fri 21 May 2010 12:54 AM (UTC) Amended on Fri 21 May 2010 01:08 AM (UTC) by Maxhrk
|
Message
| I have scanned throughout the recent ATCP_mapper.xml and noticed there is no function to change the areas.. so i go ahead and then voluntarily add the functionality for it.
Append to the local handler table to this:
{ name = "Move the room to a different area", func = change_room_area}
And adds new 'change_room_area' function to the script:
function change_room_area(room, uid)
if next(areas) == nil then
mapper.maperror("There is no available areas to choose from.")
return
end
local chosen_area = utils.listbox ("Choose area to alter the room's area", "Areas ...", areas)
if not chosen_area then
return
end
rooms[uid].area = chosen_area
mapper.draw (current_room)
dbcheck (db:execute (string.format ([[
UPDATE rooms SET area = %s WHERE uid = %s;
]], fixsql (chosen_area), -- area (e.g. "1" for "western ithmia")
fixsql (uid) -- from current room
)))
end
I hope it help people who want to change the area of the room more easier. :p Now i dont know if auto-surveying is relevant to 'atcp_mapper.xml' :p | Top |
|
Posted by
| Nick Gammon
Australia (23,046 posts) Bio
Forum Administrator |
Date
| Reply #128 on Fri 21 May 2010 03:04 AM (UTC) |
Message
| I've added that to the standard distribution, without testing I admit, but it looks OK. |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | Top |
|
Posted by
| Nick Gammon
Australia (23,046 posts) Bio
Forum Administrator |
Date
| Reply #129 on Fri 21 May 2010 06:16 AM (UTC) |
Message
| Tested it now, seems to work OK. I pushed some changes (commit e57b06f) to make the style a bit more consistent, and to fix the grammar of "There is no available areas to choose from". |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | Top |
|
Posted by
| LupusFatalis
(154 posts) Bio
|
Date
| Reply #130 on Fri 21 May 2010 03:57 PM (UTC) |
Message
| Hey, I was just thinking about it. And one feature that might be cool is an "offline" feature where you can use the mapper to simulate exploration. | Top |
|
Posted by
| Indico
(16 posts) Bio
|
Date
| Reply #131 on Sat 22 May 2010 03:10 AM (UTC) |
Message
| Has anyone worked out a way to use the X,Y,Z values? | Top |
|
Posted by
| Larkin
(278 posts) Bio
|
Date
| Reply #132 on Sat 22 May 2010 10:16 AM (UTC) |
Message
| I did figure out a way, though it looks a little screwy in some places because the exits are drawn halfway from each side and don't always meet in the middle, like when a room is southeasterly but it goes over one and down two. I haven't had the time to come up with a way to correct the exit lines yet. | Top |
|
Posted by
| Tripphippy
(3 posts) Bio
|
Date
| Reply #133 on Tue 01 Jun 2010 08:55 PM (UTC) |
Message
| how can i modify the mapper to not draw unexplored rooms but just a stub | Top |
|
Posted by
| Nick Gammon
Australia (23,046 posts) Bio
Forum Administrator |
Date
| Reply #134 on Tue 01 Jun 2010 10:33 PM (UTC) |
Message
| Do you mean instead of the dashed border in this screenshot?
|
- 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.
737,669 views.
This is page 9, subject is 17 pages long:
1
2
3
4
5
6
7
8
9 10
11
12
13
14
15
16
17
It is now over 60 days since the last post. This thread is closed.
Refresh page
top