User Name:


Forgot your password?
Vote for Us!
auth_update crash
Dec 23, 2017, 10:15 pm
By Remcon
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, Yandex

Members: 0
Guests: 6
Newest Member
Today's Birthdays
There are no member birthdays today.
Related Links
» SmaugMuds.org » Bugfix Lists » AFKMud Bugfix List » AFKMud Bug Archive » [Bug] Object stacking is not ...
Forum Rules | Mark all | Recent Posts

[Bug] Object stacking is not working properly.
< Newer Topic :: Older Topic > AFKMud 1.77

Pages:<< prev 1 next >>
Post is unread #1 Feb 12, 2006, 4:24 pm
Go to the top of the page
Go to the bottom of the page

Black Hand
JoinedJan 1, 2002

Bug: Object stacking is not working properly.
Danger: Medium - Messes up the object grouping code, causing increased memory usage.
Discovered in: AFKMud 1.77
Found by: Cam, Dwip, and Samson.
Fixed by: Samson


handler.c, clone_object

   if( obj->action_desc && obj->action_desc[0] != '\0' )
      clone->action_desc = QUICKLINK( obj->action_desc );

Below that, add:
   if( obj->socket[0] && obj->socket[0] != '\0' )
      clone->socket[0] = QUICKLINK( obj->socket[0] );
   if( obj->socket[1] && obj->socket[1] != '\0' )
      clone->socket[1] = QUICKLINK( obj->socket[1] );
   if( obj->socket[2] && obj->socket[2] != '\0' )
      clone->socket[2] = QUICKLINK( obj->socket[2] );

Been wondering why your items don't stack properly in listings? Getting odd bug messages about comparisons to NULL strings and the word "None"? It's probably because of this bug right here. This one was actually rather elusive and has been plaguing Alsherok for some time now. Mysterious bug spam generated my inventory commands, by seeing items on the ground that should be stacked but aren't, and stack counts being way off but no bug spam at all. And it was all tracked down to a simple ommision in the clone_object function. Once that's in place, stacked items will suddenly start working properly. Including being fixed in pfiles as people log back on.
Pages:<< prev 1 next >>