Register forum user name Search FAQ

Gammon Forum

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 ➜ SMAUG coding ➜ Mob Prog (death_prog) question

Mob Prog (death_prog) question

It is now over 60 days since the last post. This thread is closed.     Refresh page


Posted by Kain   USA  (43 posts)  Bio
Date Sun 20 Apr 2003 03:47 PM (UTC)
Message
I can't seem to figure something out in a mob prog and it is frustrating me. I know it is something dumb...

I have a mob with a death_prog set to 100.

So in the prog I have

mpoload 12000 2

which works fine, except that whenever a char kills the mob, I see this:

A raccoon is DEAD!!
You receive 0 experience points.
A raccoon screams furiously as it falls to the ground in a heap!
I see nothing like that in the corpse.
The corpse of a raccoon holds:
(PROTO) a newly created raccoon skin


I've tracked down the line "I see nothing like that in the corpse" to either the do_get function in act_obj.c or OBJ_DATA *find_obj in handler.c but I can't figure out why I am getting that message. The mobprog is doing what it should, but why is that message showing?

Thanks
Top

Posted by Kain   USA  (43 posts)  Bio
Date Reply #1 on Sun 20 Apr 2003 04:05 PM (UTC)
Message
I noticed that perhaps I should have been using mpmload 12000 2 and tried that but it still does the same thing. Any suggestions?

Thanks
Top

Posted by Boborak   USA  (228 posts)  Bio
Date Reply #2 on Sun 20 Apr 2003 05:03 PM (UTC)
Message
Sounds like a problem with your AUTOLOOT code. The fact that the message says 'nothing like that' leads me to think the section of code that does the AUTOLOOT isn't doing 'get all corpse' like it should. Secondly, in stock Smaug, you only automatically look in a corpse when AUTOOLOOT is OFF. Here's the chunk of code in fight.c:


            if ( IS_SET(ch->act, PLR_AUTOLOOT) )
                do_get( ch, "all corpse" );
            else
                do_look( ch, "in corpse" );


If your server was really executing do_get( ch, "all corpse" ); you wouldn't get the 'nothing like that' message. As well as, your server is doing both the loot and the look when this code says it should only be doing either or. Hope this helps.
Top

Posted by Kain   USA  (43 posts)  Bio
Date Reply #3 on Sun 20 Apr 2003 10:48 PM (UTC)
Message
Thanks for giving me a start on where to look. But I'm still confused.

If I kill the dragonsnake (from the training academy) I get this:

The dragonsnake is DEAD!!
You receive 0 experience points.
The dragonsnake screams furiously as it falls to the ground in a heap!
You get 1000 gold coins from the corpse of the dragonsnake
The corpse of the dragonsnake holds:
a visor of completion
lightweight tin sleeves
--------------------------------------------
The dragonsnake uses the mpoload program as well. I originally had my mob set up to give 0 gold. So I thought I may have changed the code somehow to mess this up. So I changed my mob to now give 1 gold upon death. And here is what I see now:

A raccoon is DEAD!!
You receive 0 experience points.
A raccoon catches its guts in its hands as they pour through its fatal wound!
I see nothing like that in the corpse.
The corpse of a raccoon holds:
a gold coin
(PROTO) a raccoon pelt
______________________________________

What I can't figure out is why the two mobs are acting differently. I don't have AutoLoot on. I then tried to remove the prototype flag, still does the same thing but doesn't load the raccoon pelt (not sure why, but I'm not worrying about that now) but still has the gold in the corpse like before. So I don't think that is the issue either. I'm just really scratching my head over this one.
Top

Posted by Kain   USA  (43 posts)  Bio
Date Reply #4 on Sun 20 Apr 2003 11:19 PM (UTC)
Message
Well I finally figured out how to get around that message. If I set the mob's gold amount to any value greater than 1, I did not get the message. I scoured through the code in the do_look functions, but couldn't find what I would need to change. But I think I'll just leave it as is and work around it.

Thanks Boborak for pointing me in a good direction.
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.


16,484 views.

It is now over 60 days since the last post. This thread is closed.     Refresh page

Go to topic:           Search the forum


[Go to top] top

Information and images on this site are licensed under the Creative Commons Attribution 3.0 Australia License unless stated otherwise.