enigma-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Enigma-devel] Questions about enigma.GetPos()


From: Markus Laire
Subject: Re: [Enigma-devel] Questions about enigma.GetPos()
Date: Mon, 30 Apr 2007 10:01:33 +0300

On 4/28/07, Ronald Lamprecht <address@hidden> wrote:
Hi,

Markus Laire wrote:
> If I use enigma.GetPos() on an item which is currently in inventory or
> in some bag, it seems to return the position where the item has last
> been on ground.
> If this behaviour likely to remain the same?

No. We are aware of this feature but it will change in future. Thus any
usage of this feature is depreceated.

I'm currently working on a level where I want to know the location
where each dynamite is exploded, to add some custom effects on
explosion.

I'm doing this by giving each dynamite a unique name, and then
checking their position periodically with
enigma.GetPos(enigma.GetNamedObject(unique_name)).

Once the position changes, I know that the dynamite has been dropped
and so I save that location. After that, once
enigma.GetNamedObject(unique_name) returns nil I know that dynamite
has exploded, and so I will add my custom effect at the saved
location.

Do you have any idea how the enigma.GetPos() will change, and how I
should continue to do what I want to do? I can't just check the map
for new "it-hollow":s because then I wouldn't know which dynamite was
exploded at that location.

ps. It would be really nice to be able to set callback-functions for
different events, like dropping an item.

--
Markus Laire




reply via email to

[Prev in Thread] Current Thread [Next in Thread]