MUSH managementMUSH management javelin Mon, 2012-02-13 19:55
Questions and answers about running a MUSH.
Can I restrict a command to objects without a flag?Can I restrict a command to objects without a flag? javelin Mon, 2012-02-13 20:03
Can I restrict a command to objects without a flag?
'restrict_command foo !FLAG' removes FLAG from the list of required flags to be able to use that command, and doesn't restrict the command to just objects without that flag. Just add a new flag with @flag and restrict the command to it, and set it on all objects but the ones you don't want using the command.
2003-Jun-16 6:58pm shawnw
How do I change some of the messages generated by the mush?How do I change some of the messages generated by the mush? javelin Mon, 2012-02-13 19:59
How do I change some of the messages generated by the mush?
Two ways. If you don't mind changing the source code, you can find the line that generats the message you want to change, edit it, re-compile, and reboot the mush.
If you'd rather avoid doing that, you can take advantage of the support for translating messages into other languages to just customize a few. The directions below assume you're running the mush on a unix server and are logged into the mush account's shell in the base pennmush directory. If you're using Windows or Macintosh, you'll probably have to resort to the first option.
First, create an index of all the strings marked for translation by running 'make pennmush.pot'. That will create a file named pennmush.pot in the po/ subdirectory. cd to that directory, and 'cp pennmush.pot en.po'.
Then, using your favorite text editor, open the file en.po, and look for a line like 'msgid "The message you want to change"'. The next line will be 'msgstr ""'. Put the customized message in the double quotes. Save the file and exit the editor.
Next, you need to compile the translation file. Do this with 'LANG=mine make localized'. That done, you need to edit the restart script in the pennmush/game directory. A few lines into the file is a commented section titled Internationalization stuff. Below the comments (The lines starting with #'s), add this line: 'export LC_MESSAGES=en'.
Finally, @shutdown the mush (A full @shutdown, not a /reboot), and start it back up again with the restart script. If all goes well, you should see something in game/log/netmush.log about 'Setting messages locale to mine'. and will get the custom messages. If not, you probably have to fiddle more with your environment variables a bit. Try LANG or LC_ALL instead of LC_MESSAGES, for example. See the gettext documentation on the account for more information.
2002-Apr-25 7:37pm shawnw
A slight variation on the above is to create po/en.pox instead of po/en.po. In this approach, en.pox contains only those entries that you're changing from the default (so it may be a very short file).
After you've got en.pox, you can build en.po from it automatically by running "make en.po" in the po/ subdirectory. This will combine en.pox with the pennmush.pot template and produce en.po. Thereafter, follow Raev's instructions.
This is the approach that's used by Javelin to build the translation files that are actually distributed on the ftp site. Advantages of this approach are than when pennmush.pot gets updated, you can quickly rebuild a matching en.po, and you get to easily see which entries you've changed. A disadvantage is that you have to copy and paste the untranslated entries from pennmush.pot into en.pox and edit them, rather than having the whole file copied in one fell swoop.
2002-Dec-02 12:03pm dunemush
How do I get a pennmush.org hostname?How do I get a pennmush.org hostname? javelin Mon, 2012-02-13 20:07
How do I get a pennmush.org hostname?
Follow the instructions given here: http://services.pennmush.org/faq.html#SEC9
2005-Mar-03 12:14pm shawnw
How do I make an actual game using Penn?How do I make an actual game using Penn? javelin Mon, 2012-02-13 20:04
How do I make an actual game using Penn?
Sorry, I am new here, just trying to figure out how to post a question. I downloaded PennMUSH, and I read the Guide for Gods, however, I didn't find information on how to CREATE a game? How do I create rooms, objects and NPC's? How do I make them talk and perform actions? How do I place objects in certain rooms and how do I bind them? I googled, but couldn't find a step-by-step manual, but I'd be pleased if anybody could point me towards some kind of manual that covers creating of a MUSH. Thanks, and sorry if I did something wrong while trying to post my question.
2003-Jun-09 2:32am zeitenflug
Ok, I DID somehow screw up while posting, I admit it, but I found an answer - isn't that amazing? To all people new to MUSHing in general and specifically to PennMUSH: My very short (and probably not all accurate answer) as to HOW DO I CREATE A GAME with PennMUSH:
It IS complicated, a lot more than, let's say, with MORDOR, but on the other hand it gives you a whole lot more opportunities, and if you aren't afraid to learn something new, it's an all powerful...errr... thingy.
MUSH seems to be some kinda "standard" - not really, since you can sometimes find things like "on TinyMush you have to type that-and-that and on PennMUSH this-and-that", but there's some kind of overall logic to all MUSHes and the language used to write games is generally the same.
It is called mushcode, and that's a vital information, since it took me some days to figure that one out (could somebody please put it into the manual?) and once you know it, it's easy to find tutorials and stuff on the internet. You could go to mushcode.com, e.g., or to http://moosh.net/mush/mushcode.shtml. Both are good starting points.
The problem is, with all things that are powerful, PennMUSH isn't something you just can download, use and enjoy as easily as MORDOR. You have to go through lots of tutorials first, learn about security issues and so on. Once you did it, there's a complicated programming language waiting to be explored, and so on. But wait - just go looking for the URLs. I'll open a BLOG at pennmush.org and I'll put down my way towards using PennMUSH. In case you're new to all this stuff, I'd be happy to hear from you and your efforts. Perhaps I can find out useful stuff, that helps getting you the hang of it.
2003-Jun-15 6:58am zeitenflug
How do I set up guest characters?How do I set up guest characters? javelin Mon, 2012-02-13 19:58
How do I set up guest characters?
You can have as many guest characters as you want, with whatever names you wish. They all must have the guest @power, and at least one of them must be named or aliased Guest (Passwords don't matter).
If that character is already logged in when someone tries to connect as a guest, the first disconnected guest-@powered player is used instead. If all guest-@powered players are logged in and more people tr to connect as guests, they will double up on some of the guest players (Two or more people connected using the same character, from different sites). If this happens frequently, you should create some more guest characters.
2001-Jul-05 8:50am shawnw
I accidently deleted some directories including the one where Penn saves databases toI accidently deleted some directories including the one where Penn saves databases to javelin Mon, 2012-02-13 20:02
Oops. This means that saves don't work. Well, the database gets saved, but where it's saved to is no longer accessible outside of the mush process, so you can't get it from a shell.
Here's an (untested) possible approach to fixing it:
If you've lost the netmush binary, grab a new tarball and recompile using all the same options as theo original.
Attach to the running mush process using gdb (gdb netmush PID). At the gdb prompt, try 'p options.output_database = "/full/path/to/someplace/outdb"'. Do the same for options.chat_database and options.mail_database. Quit gdb, do a @dump, and look for the database files. Hopefully they're there.
2003-Apr-29 8:20pm shawnw
I have an error from info_slave in netmush.log!I have an error from info_slave in netmush.log! javelin Mon, 2012-02-13 20:05
Messages like 'info_slave reading remote size: Invalid argument' and similar errors indicate that the mush stopped running without politely telling the info_slave to shut down (Usually due to a crash). It can usually be ignored; errors from the mush itself right above it in the log file are likely to be important, however.
The info_slave process itself is used to look up the hostnames associated with IP addresses. This can be a slow procedure, so it's done by another program instead of having the mush tied up with it and unusable for anything else during that time.
2003-Jun-24 7:47pm shawnw
Listening on alternate portsListening on alternate ports javelin Mon, 2012-02-13 20:01
Some people on the internet are behind a firewall which disallows outgoing connections to non-standard ports. So, for example, they may not be able to connect to your MUSH on port 6969.
A solution is to make the MUSH also listen on a standard port (in this example, I use 443, which is usually used for secure HTTP connections). This assumes you have iptables installed on the system, and are logged on as root. It should probably be put in /etc/rc.d/rc.local so that it will be re-executed upon machine boot.
/sbin/iptables -t nat -A PREROUTING -i eth0 -p tcp -d 184.108.40.206 --dport
443 -j DNAT --to 220.127.116.11:6969
In the above, 18.104.22.168 is my MUSH's IP address. 6969 is the normal port of the MUSH. 443 is the port I've setup especially for people who can't reach port 6969.
This port forwarding does not obfuscate the LASTSITE of players who connect through the alternate port, since it is done at the kernel level.
2002-Dec-01 2:02am pmak
Old DB, much garbageOld DB, much garbage javelin Mon, 2012-02-13 19:56
OK. I have been trying to make an argument against using an old DB on a game. I'd much rather start fresh. The old DB is 3-4 years old, 15,000 objects. Already, 10,000 objects have been destroyed, leaving about 5,000 actual objects.
This just seems wrong to me. I'd much rather start anew. Is there any technical reasons as to why one doesn't want 10,000 garbage holes in a DB? Possible corruption problems in the future?
2001-Apr-16 10:44am krey
No corruption. But although garbage objects don't take much memory, they do take some, and a game with 10,000 garbage and 5,000 real will be measurable larger, memory-wise, than a game with only 5,000 real.
In fact, because of the way PennMUSH allocates room in the array for objects,
you pay an even worse penalty. PennMUSH preallocates large chunks of this array to make things faster (so it doesn't have to grow the array by one object every time the db goes up by one). By default, any time the db array needs to grow, it doubles. So initially, this game will have 15000 db array slots. If you ever actually reuse all that garbage, the next object created will cause the game to have 30,000 array slots. Contrast this with a game with 5000 non-garbage objects. The next object created brings you to 10,000 array slots, which is still less than the 15,000 you'd start with using the old db.
That said, there are also advantages to reusing old dbs that often outweigh the above for small dbs (such as reusing code that depends on dbrefs, etc.) But for a 15,000 object db, you'll have to decide if your memory is sufficient to make it worthwhile.
2001-Apr-16 8:06pm dunemush
Uppercase to Lowercase commandsUppercase to Lowercase commands javelin Mon, 2012-02-13 20:05
Is there any way to alias the uppercase commands like WHO to who and QUIT to quit? I'm moving over from TinyMUX where we're all used to just typing them lowercase and my players are requesting I figure this out.
2004-May-07 3:39pm kelvin
Not without modifying those bits of the source (In bsd.c) to do case-insensitive string comparisions.
2004-Jul-24 10:39am shawnw
UPPERCASE means something by convention in Penn. An uppercase command is one that's associated with the player's socket, rather than the player object. That's why you can QUIT a single connection, and not have all your connections logged out (and why you can't run WHO when you're disconnected).
What can I do to the MUSH from the shell account?What can I do to the MUSH from the shell account? javelin Mon, 2012-02-13 20:01
What can I do to the MUSH from the shell account?
On UNIX systems, there is a command called kill which will send a signal to a specific process, like the mush. Signals are a way of letting a program know that some external event happened that it needs to know about, and Penn gives special meaning to several.
The kill program is usually invoked with 'kill -SIGNAL PID', where PID is the process ID of the mush. It's found at the top of pennmush/game/log/netmush.log,
or in the wizard version of @uptime in the mush itself.
The signals understood by Penn and what they do:
kill -HUP: Re-read all the config files, cached text files like the connect screen, sitelock file, re-build help indexes.
kill -USR1: Same as @shutdown/reboot
kill -USR2: Same as @dump
kill -INT: Same as @shutdown
kill -TERM: Same as @shutdown/panic
2002-Nov-04 3:40pm shawnw
Why do IP addresses on my mush look funny?Why do IP addresses on my mush look funny? javelin Mon, 2012-02-13 19:56
Why do IP addresses on my mush look funny?
If your mush shows IP address in a format like ::ffff:NNN.NNN.NNN.NNN instead of NNN.NNN.NNN.NNN, it's the result of an IPv4 address being mapped into an IPv6 one. This usually happens when the mush is running on a server that supports the newer IPv6 standard, with connecting clients that use IPv4. It's perfectly normal.
2001-Apr-21 2:09am shawnw
It's possible to tell the mush to use only IPv4 networking even when IPv6 networking is available, and this will cause IP addresses to be the 'normal' IPv4 ones without the funny characters. This isn't recommended, as it's good to do everything possible to promote the use of IPv6 over IPv4, but it can be done.
In the mush config file, set the ip_addr directive to "0.0.0.0", so the line looks
Alternatively, you can set it to a specific IP address. The 0.0.0.0 means "All IPv4 addresses being used". It requires a full @shutdown and restart to take effect, as @shutdown/reboot won't open new sockets for listening.
2002-Dec-01 1:13am shawnw