Notice: Any messages purporting to come from this site telling you that your password has expired, or that you need to verify your details, confirm your email, resolve issues, 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.
Due to spam on this forum, all posts now need moderator approval.
Entire forum
➜ SMAUG
➜ Compiling the server
➜ Who
It is now over 60 days since the last post. This thread is closed.
Refresh page
Pages: 1 2
Posted by
| Chris
(37 posts) Bio
|
Date
| Sun 15 Jul 2001 12:19 AM (UTC) |
Message
| Instead of typing "who 1",can you compile it to "who" so when you type "who" you can see everybody whos on the mud? | Top |
|
Posted by
| Nick Gammon
Australia (23,133 posts) Bio
Forum Administrator |
Date
| Reply #1 on Sun 15 Jul 2001 01:25 AM (UTC) |
Message
| Yes, that can be done. I suggest you look in the do_who function. |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | Top |
|
Posted by
| Chris
(37 posts) Bio
|
Date
| Reply #2 on Sun 15 Jul 2001 04:11 PM (UTC) |
Message
| Uh,still kind of new at this.
Wheres the do_who function? | Top |
|
Posted by
| Kris
USA (198 posts) Bio
|
Date
| Reply #3 on Sun 15 Jul 2001 10:19 PM (UTC) |
Message
| Ok, here's what he means by all this "function" talk. What he's saying, basically, is that you'll have to edit the source code (found in the src directory), which is written in the C programming language. Each .c file contains different parts of the source code, which contains functions such as "do_who" and "nanny" etc. You would then need to recompile the source code. I use cygwin, which takes quite a bit of hard disk space and a little getting used to, but it's free. I suggest you read through all the previous compiling the server posts (many of which are made by me), which ask the same questions, then are answered by Nick or whomever else. :) If you don't know C, I'd suggest you find an online tutorial or take a class or whatever, and learn your way through the source code as you go.
For example, I too wanted to eliminate the "who 1" junk. So, in the file act_info.c, I found the do_who function, and near the beginning was the following ifcheck:
if ( ch && argument[0] == '\0' )
{
send_to_pager_color(
"\n\r&GYou must specify at least one argument.\n\rUse 'who 1' to view the entire who list.\n\r", ch);
return;
}
That basically says "If the person doesn't type anything after 'who', then tell the person this, then return (exit) from the function."
I hope that helps =) | Top |
|
Posted by
| Chris
(37 posts) Bio
|
Date
| Reply #4 on Mon 16 Jul 2001 12:14 AM (UTC) |
Message
| In the act_info.c it stands:
* Now find matching chars.
*/
nMatch = 0;
buf[0] = '\0';
if ( ch )
set_pager_color( AT_GREEN, ch );
else
{
if ( fShowHomepage )
whoout = fopen( WEBWHO_FILE, "w" );
else
whoout = fopen( WHO_FILE, "w" );
if ( !whoout )
{
bug( "do_who: cannot open who file!" );
return;
}
}
What do i change here??
| Top |
|
Posted by
| Nick Gammon
Australia (23,133 posts) Bio
Forum Administrator |
Date
| Reply #5 on Mon 16 Jul 2001 01:01 AM (UTC) |
Message
| As it turns out the lines of code Kris mentioned are surrounded by a #define, so you can make that change by simply removing one line from the file mud.h, namely:
#define REQWHOARG
Then you would delete the file act_info.o and do a "make".
|
- Nick Gammon
www.gammon.com.au, www.mushclient.com | Top |
|
Posted by
| Chris
(37 posts) Bio
|
Date
| Reply #6 on Mon 16 Jul 2001 12:34 PM (UTC) |
Message
| |
Posted by
| Chris
(37 posts) Bio
|
Date
| Reply #7 on Mon 16 Jul 2001 06:05 PM (UTC) |
Message
| |
Posted by
| Nick Gammon
Australia (23,133 posts) Bio
Forum Administrator |
Date
| Reply #8 on Mon 16 Jul 2001 08:57 PM (UTC) |
Message
| Hmmm - I am planning to write a web page to explain some of these terms shortly. Best wait for that. |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | Top |
|
Posted by
| Nick Gammon
Australia (23,133 posts) Bio
Forum Administrator |
Date
| Reply #9 on Tue 17 Jul 2001 06:38 AM (UTC) |
Message
| I have now done an extensive web page which describes using 'make', deleting object files, and in particular gives an example of changing SMAUG to make the 'who' command behave differently. See How to make changes, including compiling |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | Top |
|
Posted by
| Zune
(76 posts) Bio
|
Date
| Reply #10 on Thu 01 Sep 2005 04:05 AM (UTC) |
Message
| I've followed instructions on how to get rid of the "who 1" issue, as presented in Gammon's informative website. I downloaded Cygwin and all, edited the mud.h file to remove the REQWHOARG, and then made the file.
At that point, I get a new smaug.exe file in the src directory, which, when run, says there is no cygwin1.dll file and therefore it is unrunnable.
I have two questions:
1. I was unable to find an act_info.o object file which I was supposed to delete, as part of the directions, and skipped this step. Any idea if this wrong, or why there's no act_info.o file?
2. What is this cygwin1.dll file, and where do I find it and place it for the compiled smaug.exe to run? | Top |
|
Posted by
| David Haley
USA (3,881 posts) Bio
|
Date
| Reply #11 on Thu 01 Sep 2005 04:14 AM (UTC) |
Message
| 1. That means you simply hadn't compiled the source yet. It's not a problem.
2. Cygwin.dll should be in c:/cygwin/bin. There are two things you can do: add that directory to your path, or more easily, copy it to the same directory as smaug.exe. A third thing you can do is run smaug.exe from inside Cygwin; that should also work. |
David Haley aka Ksilyan
Head Programmer,
Legends of the Darkstone
http://david.the-haleys.org | Top |
|
Posted by
| Greven
Canada (835 posts) Bio
|
Date
| Reply #12 on Thu 01 Sep 2005 04:14 AM (UTC) |
Message
| Can't remember off hand where it is, but I don't think you need to move it if you try to run the mud from inside of the cygwin command prompt.
As to why you had no act_info.o, you either had not compiled yet or it is in the /o directory. if you check after you have compiled it, you should find the .o file |
Nobody ever expects the spanish inquisition!
darkwarriors.net:4848
http://darkwarriors.net | Top |
|
Posted by
| Zune
(76 posts) Bio
|
Date
| Reply #13 on Thu 01 Sep 2005 04:28 AM (UTC) |
Message
| You were right on the o directory. Silly, I must have just overlooked it. I recompiled and the edited act_info was included.
So now, the smaug.exe and the cygwin issue. I'm going to see if I can fix this via the path route. I'll be back to comment. | Top |
|
Posted by
| Zune
(76 posts) Bio
|
Date
| Reply #14 on Thu 01 Sep 2005 04:40 AM (UTC) Amended on Thu 01 Sep 2005 04:44 AM (UTC) by Zune
|
Message
| Alright, I did two things:
1. copied and pasted the cygwin1.dll file to the directory where the newly recompiled smaug.exe is stored
2. added the c:/cygwin/bin directory to the path
RESULTS
1.Now, when you click the icon in windows, it just flashes on and off.
2. In the cygwin bash, it doesn't recognize any smaug.exe command to run.
3. At the command prompt, it gives me the same message as before:
"This application has failed to start because cygwin1.dll was not found."
I'm stuck.
PS - Keep in mind that I'm running a "protosmaug" copy of smaug in its own directory for testing, while I have my regular MUD safely in its own C:\smaug directory. At this point, the normal one runs just fine, with the exception of from Cygwin, which doesn't run executables for some reason. | 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.
63,456 views.
This is page 1, subject is 2 pages long: 1 2
It is now over 60 days since the last post. This thread is closed.
Refresh page
top