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

Gammon Software Solutions 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]  Problem adding new command
Home  |  Users  |  Search  |  FAQ
Username:
Register forum user name
Password:
Forgotten password?
(New message)
Subject: Problem adding new command
Name:
Your forum user name.
Register forum user name
Password:
Your forum password.
Forgotten password?
Message:
Message to be posted (in English, please)
Maximum of 6000 characters. Text only please, no HTML.
Forum codes:
Check this if your message uses 'forum codes' or templates (auto-detected for new posts).
Forum codes Templates

Save this message ...


Subject review (reverse sequence)

Pages: 1 2  

Posted by Nargsbrood   (54 posts)  [Biography] bio
Date Mon 04 Jul 2011 06:01 AM (UTC)  quote  ]
Message
Thanks Zeno -

Here is the link to the Fuss forum in case a resolution is found there:

http://www.smaugmuds.org/index.php?a=topic&t=4558&p=21840#p21840
[Go to top] top

Posted by Zeno   USA  (2,871 posts)  [Biography] bio   Moderator
Date Mon 04 Jul 2011 03:36 AM (UTC)  quote  ]
Message
I'm not familiar with the dynamic mapping, might want to ask on the FUSS forums.

Zeno McDohl,
Owner of Bleached InuYasha Galaxy
http://www.biyg.org
[Go to top] top

Posted by Nargsbrood   (54 posts)  [Biography] bio
Date Mon 04 Jul 2011 02:07 AM (UTC)  quote  ]
Message
I hate bringing up such an old thread but I am having the same problem when trying to add a command to the game.

Its an old mapper function i came across.

this function found in act_move.c:
void do_map ( CHAR_DATA * ch, char *argument ) {

i have this in mud.h
DECLARE_DO_FUN( do_map );



commands.dat shows
#COMMAND
Name map~
Code do_map
Position 100
Level 64
Log 0
End




I get this error message when i tried cedit create:
Log: [*****] BUG: Error locating do_map in symbol table. Resource temporarily unavailable
Command added.
Code do_map not found. Set to no code.

I get this error message when booting up the mud:
Sun Jul 3 18:43:52 2011 :: [*****] BUG: Error locating do_map in symbol table. No error
Sun Jul 3 18:43:52 2011 :: [*****] BUG: fread_command: Function do_map not found for map



since making changes I did 'make clean' and 'make' all compiles no problem. What am I missing?

Thanks,
Nargs


[Go to top] top

Posted by Dbaker84   (26 posts)  [Biography] bio
Date Fri 08 Aug 2008 04:12 AM (UTC)  quote  ]
Message
I'm pulling my hair out over here.

Somehow, I got that sayto function/command to work. I tried to add another new function.......same story as before. I figured, maybe it's the coding again, so I tried yet another function..same. I have absolutely no idea what in the heck is going on. If someone could be so very kind as to look this code over for me and maybe try to compile/run it on their setup, I would be very very appreciative. Here's a link to a zip of the source.

http://www.quickfilepost.com/download.do?get=e71589804edeb6a033bde198b3cba193

The function I'm trying to get to work are do_suicide in act_comm.c and do_invade in act_wiz.c.

I can haz Smaug?
[Go to top] top

Posted by Dbaker84   (26 posts)  [Biography] bio
Date Wed 06 Aug 2008 11:16 PM (UTC)  quote  ]
Message
yeah, I changed mud.h to stc as well.

I'm downloading andlinux as we speak; I'm also beginning to think it has something to do with cygwin due to that error message I posted earlier.

I can haz Smaug?
[Go to top] top

Posted by Zeno   USA  (2,871 posts)  [Biography] bio   Moderator
Date Wed 06 Aug 2008 11:12 PM (UTC)  quote  ]
Message
The function name has to match the line in mud.h, so if mud.h is say_to_char and the fn is stc it won't work.

My only other thought is something funky going on with Cygwin and dynamic linking.

Zeno McDohl,
Owner of Bleached InuYasha Galaxy
http://www.biyg.org
[Go to top] top

Posted by Dbaker84   (26 posts)  [Biography] bio
Date Wed 06 Aug 2008 11:10 PM (UTC)  quote  ]
Message
gah, sorry. I've changed the name from say_to_char to stc, but it's still not working. I assume this is enough.


void do_stc( CHAR_DATA *ch, char *argument )
{
char arg[MAX_INPUT_LENGTH];
char buf[MAX_STRING_LENGTH];
const char *sbuf;
CHAR_DATA *victim;
EXT_BV actflags;
/*int arglen;*/
CHAR_DATA *vch;
#ifndef SCRAMBLE
int speaking = -1, lang;

for( lang = 0; lang_array[lang] != LANG_UNKNOWN; lang++ )
if( ch->speaking & lang_array[lang] )
{
speaking = lang;
break;
}
#endif

argument = one_argument( argument, arg );


I can haz Smaug?
[Go to top] top

Posted by Zeno   USA  (2,871 posts)  [Biography] bio   Moderator
Date Wed 06 Aug 2008 11:07 PM (UTC)  quote  ]
Message
Er, the function header. Not file header.

Zeno McDohl,
Owner of Bleached InuYasha Galaxy
http://www.biyg.org
[Go to top] top

Posted by Dbaker84   (26 posts)  [Biography] bio
Date Wed 06 Aug 2008 10:53 PM (UTC)  quote  ]
Message
It's in act_comm.c

#include <ctype.h>
#include <stdio.h>
#include <string.h>
#include <time.h>
#include "mud.h"

I can haz Smaug?
[Go to top] top

Posted by Zeno   USA  (2,871 posts)  [Biography] bio   Moderator
Date Wed 06 Aug 2008 10:15 PM (UTC)  quote  ]
Message
What file is the function in? What does the function header look like?

Zeno McDohl,
Owner of Bleached InuYasha Galaxy
http://www.biyg.org
[Go to top] top

Posted by Dbaker84   (26 posts)  [Biography] bio
Date Wed 06 Aug 2008 09:49 PM (UTC)  quote  ]
Message
My cygwin is doing this after it makes all the o files


/usr/lib/gcc/i686-pc-cygwin/3.4.4/../../../../1686-pc-cygwin/bin/ld: warning: auto-importing has been activated without --enable-auto-import specified on the command line.
This should work unless it involves constant datat structures referencing symbols from auto-imported DLLs.Info: resolving __timezone by linking to __imp__timezone (auto-import)


I assume that this could cause an issue due to the dynamic linking.

I can haz Smaug?
[Go to top] top

Posted by Dbaker84   (26 posts)  [Biography] bio
Date Wed 06 Aug 2008 09:45 PM (UTC)  quote  ]
Message
Yeah, I am using Cygwin. I'm 110% sure that I'm using a clean compile, so I really have no idea what is going on here. Could it have anything to do with do_say and do_say_to_char sharing the do_say part? Other than that, I can't think of anything that would be causing an issue.

I can haz Smaug?
[Go to top] top

Posted by Zeno   USA  (2,871 posts)  [Biography] bio   Moderator
Date Wed 06 Aug 2008 09:42 PM (UTC)  quote  ]
Message
http://www.gammon.com.au/forum/bbshowpost.php?bbsubject_id=8247&page=1

That's all I found find about it.

Are you using Cygwin?

Zeno McDohl,
Owner of Bleached InuYasha Galaxy
http://www.biyg.org
[Go to top] top

Posted by Dbaker84   (26 posts)  [Biography] bio
Date Wed 06 Aug 2008 09:37 PM (UTC)  quote  ]

Amended on Wed 06 Aug 2008 09:38 PM (UTC) by Dbaker84

Message
mud.h:

DECLARE_DO_FUN( do_say_to_char );


cedit:

cedit sayto create do_say_to_char



This is exactly what I'm getting ingame:

Log: Trevlyn: cedit sayto create do_say_to_char
Log: [*****] BUG: Error locating do_say_to_char in symbol table. Resource temporarily unavailable
Command added.
Code do_say_to_char not found. Set to no code.

I can haz Smaug?
[Go to top] top

Posted by Zeno   USA  (2,871 posts)  [Biography] bio   Moderator
Date Wed 06 Aug 2008 09:34 PM (UTC)  quote  ]
Message
What does the line look like in mud.h?

What are you typing with cedit?

Zeno McDohl,
Owner of Bleached InuYasha Galaxy
http://www.biyg.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.


7,393 views.

This is page 1, subject is 2 pages long: 1 2  [Next page]

It is now over 60 days since the last post. This thread is closed.   [New subject]  Start a new subject   [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.

[Home]

Written by Nick Gammon - 5K

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

[Best viewed with any browser - 2K]    [Web site powered by FutureQuest.Net]