[Home] [Downloads] [Search] [Help/forum]

Gammon Forum

See www.mushclient.com/spam for dealing with forum spam. Please read the MUSHclient FAQ!

[Folder]  Entire forum
-> [Folder]  SMAUG
. -> [Folder]  SMAUG coding
. . -> [Subject]  Explored rooms list
Home  |  Users  |  Search  |  FAQ
Username:
Register forum user name
Password:
Forgotten password?

Explored rooms list

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


Posted by Lerkista   (32 posts)  [Biography] bio
Date Sat 20 Sep 2014 06:39 PM (UTC)
Message
Hi

Any idea how i can implement this?

I want my map only display explored rooms, something like aardwolf

In LPC i can do it easily with "mappings", you can do things like:

mapping explored;

explored = ([]);

explored[21000] = 1;
explored[21001] = 1;
explored[21002] = 1;

and can search values as simple as:

a = 21000;
if( list[a] )
return "room explored."

Anything like that??

Or any idea to do this??

I don't know if using an array to store the vnums and check the entire list with every room everytime i show the map can make the mud slower
[Go to top] top

Posted by Nick Gammon   Australia  (21,321 posts)  [Biography] bio   Forum Administrator
Date Reply #1 on Sat 20 Sep 2014 08:40 PM (UTC)
Message
On the client side or the server side? On the server side you would need to remember, per player.

- Nick Gammon

www.gammon.com.au, www.mushclient.com
[Go to top] top

Posted by Lerkista   (32 posts)  [Biography] bio
Date Reply #2 on Sat 20 Sep 2014 09:11 PM (UTC)
Message
Hi

In the server side, so i need to add a variable to the player to store all the explored vnums, buy i don't know how to make it with less resources
[Go to top] top

Posted by Meerclar   USA  (733 posts)  [Biography] bio
Date Reply #3 on Sun 21 Sep 2014 04:26 AM (UTC)
Message
There's not a less resources option. Every option is at least a linear growth per player per room in memory utilization as your (ideally) database of explored rooms expands with player base growth and exploration of the realm.

Meerclar - Lord of Cats
Coder, Builder, and Tormenter of Mortals
Stormbringer: Rebirth
storm-bringer.org:4500
www.storm-bringer.org
[Go to top] 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.


3,010 views.

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

Go to topic:           Search the forum


[Go to top] top

Quick links: MUSHclient. MUSHclient help. Forum shortcuts. Posting templates. Lua modules. Lua documentation.

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

[Home]


Written by Nick Gammon - 5K   profile for Nick Gammon on Stack Exchange, a network of free, community-driven Q&A sites   Marriage equality

Comments to: Gammon Software support
[RH click to get RSS URL] Forum RSS feed ( https://gammon.com.au/rss/forum.xml )

[Best viewed with any browser - 2K]    [Hosted at FutureQuest]