Gammon Forum
Entire forum
PennMUSH
Running the server
A couple of questions
It is now over 60 days since the last post. This thread is closed.
  Refresh page
Posted by
| Tanos
(9 posts) bio
|
Date
| Wed 02 May 2001 02:18 AM (UTC) |
Message
| Ok, first question. Is it ok to just run 'pennmush.exe' instead of 'pennmush /run'? Because I setup a DOS execution file that just runs pennmush.exe instead of me manually having to go through each directory and then typing 'pennmush /run'. So, wanted to know if there's anything wrong with that. Second, and final question. Is there any way to add softcode to the Win32 version of Pennmush? I.E. adding +bboards, etc. If so, then where would I place the code inside the /pennmush directory so that it will be recognized? Whew, ok, thanks :)
~tanos | top |
|
Posted by
| Nick Gammon
Australia (23,000 posts) bio
Forum Administrator |
Date
| Reply #1 on Wed 02 May 2001 03:06 AM (UTC) |
Message
| Yes it is OK to just run pennmush.exe. On Windows NT that will be about 15 seconds slower because it tries to run it as a service, which then times out.
I'm not sure what you mean by a "DOS execution file" - however normally such files (eg. batch files) would allow the /run to be part of the command.
As for softcode, once the server is running that is normally installed by a wizard executing the appropriate softcode commands once logged in. For instance, you might use MUSHclient to "send a file" or "paste the clipboard" directly to the MUSH to have it process a batch of commands. |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | top |
|
Posted by
| Tanos
(9 posts) bio
|
Date
| Reply #2 on Wed 02 May 2001 12:19 PM (UTC) |
Message
| Ok, thanks. And by DOS execution file I just mean that I copied a DOS prompt and then changed the cmd line to c:\ yadda yadda yadda pennmush.exe | top |
|
Posted by
| Tanos
(9 posts) bio
|
Date
| Reply #3 on Wed 02 May 2001 06:36 PM (UTC) |
Message
| Ok, I'm a little retarted and need some more uhh...."guidance." Can you give me an example of imping a new function or something? I'm used to MUDs and all I needed to do was type up the code and then save it to 'src' but this is a bit different. So, can you just throw an example out there so I can get a feel for adding new stuff to my MUSH?
~tanos | top |
|
Posted by
| Nick Gammon
Australia (23,000 posts) bio
Forum Administrator |
Date
| Reply #4 on Wed 02 May 2001 10:03 PM (UTC) Amended on Wed 02 May 2001 10:04 PM (UTC) by Nick Gammon
|
Message
| It is hard to know for sure whether you are really asking about softcode or "hard code".
Softcode is adding functionality by adding to the MUSH database from within the MUSH itself, as a wizard. You can read about this at: MUSH 101 Schoolhouse.
Generally functions like +bboard are done in softcode. The "+" signifies this.
Hardcode is adding new commands to the server, in C, which then has to be compiled using a suitable compiler. The PennMUSH site will have more information. Describing in detail how to write such functions goes outside the scope of my experience a bit. At the PennMUSH site, however, you will find some "code snippets" which should give an example of what to do.
This process is described in Javelin's Guide for PennMUSH Gods which is well worth reading.
|
- Nick Gammon
www.gammon.com.au, www.mushclient.com | top |
|
Posted by
| Tanos
(9 posts) bio
|
Date
| Reply #5 on Wed 02 May 2001 10:39 PM (UTC) |
Message
| Ok, thanks :) | top |
|
Posted by
| Nick Gammon
Australia (23,000 posts) bio
Forum Administrator |
Date
| Reply #6 on Wed 02 May 2001 11:13 PM (UTC) Amended on Wed 02 May 2001 11:16 PM (UTC) by Nick Gammon
|
Message
|
Quote:
By the DOS execution file I just mean that I copied a DOS prompt and then changed the cmd line to c:\ yadda yadda yadda pennmush.exe
You can always tack on the /run to the end, like this:
c:\pennmush\pennmush.exe /run
|
- Nick Gammon
www.gammon.com.au, www.mushclient.com | top |
|
Posted by
| Tanos
(9 posts) bio
|
Date
| Reply #7 on Thu 03 May 2001 12:01 PM (UTC) |
Message
| Ok, I've done that but then that brings out my curiosity question. What's the point of the '/run'?
~tanos | top |
|
Posted by
| Nick Gammon
Australia (23,000 posts) bio
Forum Administrator |
Date
| Reply #8 on Thu 03 May 2001 08:53 PM (UTC) |
Message
| I wanted the same executable to be installable as an NT "service" (which runs in the background even if no-one is logged in) and a normal program which you just execute.
If it is a service it has to do some somewhat different things at startup, so the trick is to know, at execution time, whether or not the program is running as a service or a "normal" program.
I couldn't find any easy way, so what it does is attempt to do a "service startup", and then if that fails, revert to normal mode. However this service startup seems to take about 15 seconds before it gives up and returns an error code (under NT). Under 95/98 it returns immediately.
To avoid this 15-second delay, the command-line parameter "/run" tells it that it is not a service, and to go straight into normal execution mode.
|
- Nick Gammon
www.gammon.com.au, www.mushclient.com | top |
|
Posted by
| Tanos
(9 posts) bio
|
Date
| Reply #9 on Thu 03 May 2001 10:35 PM (UTC) |
Message
| Ok. Now I've got another question :P
I was looking through the '+help' system using softcode and discovered a line that went something like this:
@set <dbref whatever>=COMMANDS
Now that's an unknown flag to me. So, two questions. What does it do? And is there any way to find a new '+help' system in softbode, or hardcode in a COMMANDS flag? | top |
|
Posted by
| Nick Gammon
Australia (23,000 posts) bio
Forum Administrator |
Date
| Reply #10 on Thu 03 May 2001 11:15 PM (UTC) |
Message
| I don't know what it does. Someone may have hard-coded in an extra flag, it's not that hard to do. |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | top |
|
Posted by
| Tanos
(9 posts) bio
|
Date
| Reply #11 on Sun 06 May 2001 03:22 AM (UTC) |
Message
| Ok, lemme tack some technical weirdness onto this subject. I was recently just mukking about with some softcode and after a bit of coding I decided to test it with a regular player, 'Testguy.' Now, I didn't notice at first because I was enthralled with the coding but after awhile I noticed that the game was no longer telling when a player logged in. So, my question is...is there any way to fix this and why did it happen?
~tanos | top |
|
Posted by
| Nick Gammon
Australia (23,000 posts) bio
Forum Administrator |
Date
| Reply #12 on Sun 06 May 2001 06:11 AM (UTC) |
Message
| Notification of new logins is a flag too, so somehow your new code has corrupted that behaviour. Hard to say how exactly without looking at your changes, but I would look closely at your changes, and see if (perhaps) you shared the same flag number between the two functions, or maybe when you set the new flag you somehow clear the other one. |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | top |
|
Posted by
| Samantha
(2 posts) bio
|
Date
| Reply #13 on Sat 14 Dec 2002 04:55 PM (UTC) |
Message
| I know this is a rather old topic, but I only just found the site.
Quote: @set <dbref whatever>=COMMANDS
Anyway, the above the 'commands' is basically the same as PennMUSH's 'no_commands' flag. One of the other MUSH codebases where by default items don't have the 'commands' flag set, similar to Penn's mehtod of having them set 'no_commands' | 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.
30,906 views.
It is now over 60 days since the last post. This thread is closed.
  Refresh page
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.