Login
User Name:

Password:



Register
Forgot your password?
Vote for Us!
auth_update crash
Dec 23, 2017, 10:15 pm
By Remcon
check_tumble
Dec 18, 2017, 7:21 pm
By Remcon
parse description bug
Dec 15, 2017, 10:08 pm
By Remcon
Couple bugs
Dec 12, 2017, 5:42 pm
By Remcon
Bug in disarm( )
Nov 12, 2017, 6:54 pm
By GatewaySysop
LoP 1.46
Author: Remcon
Submitted by: Remcon
LOP 1.45
Author: Remcon
Submitted by: Remcon
LOP Heroes Edition
Author: Vladaar
Submitted by: Vladaar
Heroes sound extras
Author: Vladaar
Submitted by: Vladaar
6Dragons 4.3
Author: Vladaar
Submitted by: Vladaar
Users Online
CommonCrawl, Google, Yandex

Members: 0
Guests: 8
Stats
Files
Topics
Posts
Members
Newest Member
478
3,708
19,242
612
Jacki72H
Today's Birthdays
There are no member birthdays today.
Related Links
» SmaugMuds.org » General » Coding » Land Snippet (Auric MUD) *tin...
Forum Rules | Mark all | Recent Posts

Land Snippet (Auric MUD) *tiny* BUG
< Newer Topic :: Older Topic > Simple Bug Fix / Correction

Pages:<< prev 1 next >>
Post is unread #1 Jul 4, 2003, 9:25 pm
Go to the top of the page
Go to the bottom of the page

GatewaySysop
Conjurer
GroupMembers
Posts367
JoinedMar 7, 2005

I'm not sure how many people actually use this snippet, but I happen to really like it for what it does and I figured that this might be useful to anyone who's just thrown it in (like me) and not noticed this tiny flaw.

What happens is when you're flying/floating and you enter 'land' the function, as written, responds with;

"You land."
"Ok."

Of course when you're already on the ground, it just tells you, "Ok."

I thought it was annoying that it would say "Ok." after you landed, and that you didn't get a more appropriate message when trying to land while already on the ground. :blink:

I implemented this fix, so far so good:

In do_land (wherever you put it, I used act_move.c) go to the end and find this section,

if (found)
    {
     act( AT_PLAIN, "You land.", ch, NULL, NULL, TO_CHAR );
     act( AT_PLAIN, "$n lands.", ch, NULL, NULL, TO_ROOM );
    }

    send_to_char( "Ok.\n\r", ch );
    return;
}



I changed it to this,

if (found)
    {
     act( AT_PLAIN, "You land.", ch, NULL, NULL, TO_CHAR );
     act( AT_PLAIN, "$n lands.", ch, NULL, NULL, TO_ROOM );
     return;
    }

    send_to_char( "You're already on the ground.\n\r", ch );
    return;
}



I tested this and it appears to work fine.
       
Pages:<< prev 1 next >>