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, Yahoo!, Yandex

Members: 0
Guests: 9
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 » Bugfix Lists » AFKMud Bugfix List » AFKMud Bug Archive » [Bug] Mobs + objects not crea...
Forum Rules | Mark all | Recent Posts

[Bug] Mobs + objects not created with specific areas assigned cause crash
< Newer Topic :: Older Topic > AFKMud 1.63

Pages:<< prev 1 next >>
Post is unread #1 Jun 11, 2004, 8:00 pm   Last edited Nov 13, 2005, 12:15 pm by Samson
Go to the top of the page
Go to the bottom of the page

Samson
Black Hand
GroupAdministrators
Posts3,639
JoinedJan 1, 2002

Bug: Mobs and objects not created with specific areas assigned will crash the mud.
Discovered in: AFKMud 1.63
Danger: High - Crash bug
Found by: RapidRunner
Fixed by: Samson

update.c, around line 693 in mobile_update, locate:

      /* NPCs belonging to prototype areas should be doing nothing */
      if( IS_NPC(ch) && IS_AREA_FLAG( ch->pIndexData->area, AFLAG_PROTOTYPE ) )
         continue;


Directly ABOVE those lines, add these:

      /* Mobs with no assigned area should not be updated - Samson 6-11-04 */
      if( IS_NPC(ch) && ch->pIndexData->area == NULL )
         continue;


Then in db.c, find the following in create_object:

   /* Wow. This hackish looking thing is pretty bad isn't it?
    * I thought so too, but hey. Dwip wanted to bring in a bunch of old stuff that needed to be armorgen'd.
    * This was about the only way I could think to do it.
    * Won't bother you much if you haven't set v3 or v4 on an armor though.
    * All in the name of being able to retain stats if deviating from the armorgen specs.
    * Samson 12-23-02
    */
   if( obj->pIndexData->area->version < 18 )
   {


Replace that with:

   /* Wow. This hackish looking thing is pretty bad isn't it?
    * I thought so too, but hey. Dwip wanted to bring in a bunch of old stuff that needed to be armorgen'd.
    * This was about the only way I could think to do it.
    * Won't bother you much if you haven't set v3 or v4 on an armor though.
    * All in the name of being able to retain stats if deviating from the armorgen specs.
    * Samson 12-23-02
    */
   if( obj->pIndexData->area && obj->pIndexData->area->version < 18 )
   {


When a mobile or object is initially created, they should be getting assigned to the zone a builder is working on. However, higher level immortals don't need zones in order to invoke the mcreate and ocreate commands, and can therefore cause this bug to happen if they forget to use the aassign command to assign a zone prior to creating them.
       
Pages:<< prev 1 next >>