Author Topic: A Challenge  (Read 4423 times)

Offline mudder

  • Acquaintance
  • *
  • Posts: 2
    • View Profile
A Challenge
« on: May 01, 2009, 07:38:54 AM »
Ok guys, I'm new to this site but old to muds, and I question that involves code (don't worry, it's not dull).  I found this site when I googled "illegal to move or destruct an object" (it took me to http://lpmuds.net/forum/index.php?topic=883.0).

So my challenge/question is this:  I play a certain mud where there's a certainly highly rare object that drops off of a certain monster.  Legend has it that it only drops once in hundreds of times.  But some of us have noticed that if you are in the room, and look around or attack the monster RIGHT as it respawns, you'll see one of these two codes:

*Illegal to move or destruct an object (/domains/Isles/Kobold/Korlis/obj/other/kor_paper3#1232) defining actions from a verb function which returns zero. Trace written to /log/runtime

alternately, I've seen this before:

*Illegal to move or destruct an object (/domains/Atheria/Whitestorm/void)
defining actions from a verb function which returns zero. Trace written to /log/runtime

It SEEMS the code you see depends on whether or not you've picked up the piece of paper that also respawns in the room...I'm not sure.

ANYWAY, my challenge is this: some have claimed that this code comes up because the monster, or rather the game itself, is essentially "destroying" this rare item we're all trying to get, the moment the creature spawns--these ppl claim, thus, that perhaps by attacking the monster the moment it spawns, you'll increase your chances of getting this rare artifact.

MY question: what does this code actually mean/do, and what bearing does it have on the randomness or not-so-randomness of this all-important item we're all trying to get?

Thank you for your thoughts!!!!!   :)

Offline quixadhal

  • BFF
  • ***
  • Posts: 642
    • View Profile
    • WileyMUD
Re: A Challenge
« Reply #1 on: May 01, 2009, 08:46:05 AM »
From reading the thread referenced, it sounds more like an add_action that's supposed to be associated with the paper item is either not working, or perhaps working but still being flagged as incorrect by the driver.

Besides being in the add_action is EVIL camp, they're supposed to return a true/false value so that the parser knows if it should continue trying alternate matches, or if that one actually worked.  That warning seems to imply that whomever coded the object didn't bother to return a value (and thus probably gets the default behavior of false).

Anyone how actually knows how this stuff works wanna guess? :)

Offline cratylus

  • Your favorite and best
  • Administrator
  • ***
  • Posts: 1020
  • Cratylus@Dead Souls <ds> np
    • View Profile
    • About Cratylus
Re: A Challenge
« Reply #2 on: May 01, 2009, 09:02:48 AM »
ANYWAY, my challenge is this: some have claimed that this code comes up because the monster, or rather the game itself, is essentially "destroying" this rare item we're all trying to get, the moment the creature spawns--these ppl claim, thus, that perhaps by attacking the monster the moment it spawns, you'll increase your chances of getting this rare artifact.

Without seeing the code in question, your challenge is an invitation to speculation. I'm
happy to speculate, but you're more likely to get useful help if you share the code
that is giving you trouble. Remember to enclose it in code tags, using the # button
in the toolbar of the post reply.

The thread you quoted has the likely solution to the error. You have a function
that either returns nothing or returns 0. Have that function return 1 instead. You
don't seem to be asking how to fix this, but I presume this is what you meant
to ask, so that's what I'm answering.

I'd like to remind folks (not just mudder) that it helps to provide more technical info (code, logs)
rather than less. While your perspective on what you think is happening is interesting, ultimately
you may simply not be looking at the right thing. Show us what you've got, and we may see things
you did not.

See also: http://www.chiark.greenend.org.uk/~sgtatham/bugs.html
And: http://www.catb.org/~esr/faqs/smart-questions.html

As to the question you did ask regarding the logic of the behavior you're seeing,
there's no way for me to answer that without totally guessing. I'd have to see the
code to tell you what it is doing.

-Crat


Offline Alexi

  • Acquaintance
  • *
  • Posts: 15
    • View Profile
Re: A Challenge
« Reply #3 on: May 01, 2009, 10:07:53 AM »
ANYWAY, my challenge is this: some have claimed that this code comes up because the monster, or rather the game itself, is essentially "destroying" this rare item we're all trying to get, the moment the creature spawns--these ppl claim, thus, that perhaps by attacking the monster the moment it spawns, you'll increase your chances of getting this rare artifact.

Without seeing the code in question, your challenge is an invitation to speculation. I'm
happy to speculate, but you're more likely to get useful help if you share the code
that is giving you trouble.

This chap is a player...I'm not certain s/he has access to code.  The ultimate question is not about fixing the problem but staging play.  I'd venture a guess by the tone of the "debate" among their player community that they don't have much access to their developers or lack responsive bug fix workflow.

If there was enough snap to post LP snippet code, I doubt there would have been the need to resort to googling to find lpmuds.net.  Or for that matter, if fixing the code was the priority, I don't think the focus would be on how to "increase your chances of getting this rare artifact."  They are arguing over how to "play" around a bug... sad actually.

Too bad the name of the mud was not published... seems to me it has exceptionally loyal/determined players and needs a bit of shame therapy.

Offline cratylus

  • Your favorite and best
  • Administrator
  • ***
  • Posts: 1020
  • Cratylus@Dead Souls <ds> np
    • View Profile
    • About Cratylus
Re: A Challenge
« Reply #4 on: May 01, 2009, 10:39:57 AM »
Quote
This chap is a player

If so then mea culpa.

My apologies if I came off grumpy.

I'm unaccustomed to regular players having access to error
messages that contain file data.

-Crat

Offline mudder

  • Acquaintance
  • *
  • Posts: 2
    • View Profile
Re: A Challenge
« Reply #5 on: May 01, 2009, 03:25:56 PM »
How refreshing to get so many responses!

Yes, I'm a player; No, I didn't really want to share which mud; No, I have no code or technical info at my disposal (but Thank you Crat for trying!).

I really just wanted to know what the error meant.  Since then it seems to be apparent that it happens whenever you try to kill a mob directly before it spawns, anywhere in the game world--this is rare and hard to do, and so the game rarely spews this code. 

Loyal? Yes.  Loyal enough to resist any shame therapy (that's probably a bad thing).

Thanks guys!!!


Offline cratylus

  • Your favorite and best
  • Administrator
  • ***
  • Posts: 1020
  • Cratylus@Dead Souls <ds> np
    • View Profile
    • About Cratylus
Re: A Challenge
« Reply #6 on: May 01, 2009, 07:55:30 PM »
Loyal? Yes.  Loyal enough to resist any shame therapy (that's probably a bad thing).

Mmm I think maybe you thought he meant shaming you. I think he meant shaming Petrarch.

-Crat

Offline Alexi

  • Acquaintance
  • *
  • Posts: 15
    • View Profile
Re: A Challenge
« Reply #7 on: May 01, 2009, 08:07:14 PM »
Loyal? Yes.  Loyal enough to resist any shame therapy (that's probably a bad thing).

Mmm I think maybe you thought he meant shaming you. I think he meant shaming Petrarch.

-Crat
Haha... dots are connected. Mmm- indeed -tha

Cheers,
Alexi

Offline Nulvect

  • BFF
  • ***
  • Posts: 127
    • View Profile
Re: A Challenge
« Reply #8 on: May 02, 2009, 12:40:34 PM »
To be fair, Petrarch didn't make the area being talked about, but anyway...

The error message indicates that the current execution thread started from a command defined by an add_action (which is how you add commands into items and rooms, for you non-coders). The code inside the command is trying to move or destroy the object where the command is defined, which isn't allowed. A workaround for this is to use call_out with a time of 0 seconds to call remove(), though it's entirely possible it will take a full heartbeat before it's done so you should take appropriate precautions (use remove_action first, for example).

I find it especially weird that the Void room would have an error like that. The Void is a catch-all room in case something bad happens; if your current room gets destroyed unexpectedly and the mud needs somewhere safe to put you, you go to the Void.

Basically, unless the item you want is that piece of paper, it is -probably- not being affected by the errors. But it could be, it's impossible to say.

Offline petriomelony

  • Acquaintance
  • *
  • Posts: 34
    • View Profile
Re: A Challenge
« Reply #9 on: May 04, 2009, 06:59:10 PM »
heh, running a search on the two area names he mentioned, it looks like it's Merentha, or perhaps if Merentha distributes those areas with their code, a mud that uses the Merentha lib.

Offline Alexi

  • Acquaintance
  • *
  • Posts: 15
    • View Profile
Re: A Challenge
« Reply #10 on: May 04, 2009, 10:18:33 PM »
So much for subtlty.  No need for dots when there are plenty that will pave the way with yellow bricks.  :P