PenUltima Online Forum Index Official Core: 096.7
Official Core: 097 2008-02-26
Donate towards the POL web hosting bill!
 POL Home   FAQ   Search    Memberlist   Usergroups    Register    Profile   Log in to check your private messages   Log in
reserved items

 
Post new topic   Reply to topic    PenUltima Online Forum Index -> General Help (095)
Display posts from previous:   

Author Message
DevGIB



Joined: 06 Feb 2006
Posts: 93

PostPosted: Thu Aug 03, 2006 8:57 am    Post subject: reserved items Reply with quote

umm we have a problem were if an item is in use by a script and the player dies the item will get destroyed...

i know what the problem is im just not sure how to fix it... the item is reserved by one script and deleted by another... if we put releaseitem() in the second script it doesnt release it from the first... is there anyway around this... because using moveitemtocontainer() doesnt move reserved items :S

anyway around this?

Author Message
Tritan



Joined: 04 Feb 2006
Posts: 136
Location: Illinois, USA

PostPosted: Thu Aug 03, 2006 2:01 pm    Post subject: Reply with quote

I ran into this in my scripts at one time. The issue was mainly with bard and my provocation package. I just gave each bard a starting instrument and made it newbie.

If anyone has a better solution for this I would be interested also. Razz

Author Message
Marilla



Joined: 02 Feb 2006
Posts: 329

PostPosted: Thu Aug 03, 2006 5:45 pm    Post subject: Reply with quote

It would really depend on how your scripts work; Sounds to me like both the scripts in question need to be re-written to take various things into account. You would likely also have problems if the player logged off during the script(s) running.

You always need to be sure that scripts that reference a player check when necessary that the player is a) still alive and b) still online. Not only is this important in 'loops' like what seems to be going on here, but also it's important in any script that have a gump; Some people for instance assume that nodispose gumps will -never- return 'false' unless a button specifically has that value... but this can happen if a player logs off/loses connection.


Anyway... without knowing exactly what your script does, we couldn't fix it or tell you how to. Clearly, though, at some point your scripts need to be checking if the player has died or logged off, and take appropriate action. It's simple in principle and practice, but can't really be detailed for you without knowing your script.

Author Message
CWO



Joined: 04 Feb 2006
Posts: 698
Location: Chicago, IL USA

PostPosted: Fri Aug 04, 2006 1:50 am    Post subject: Reply with quote

maybe...

See if you can get props from the item. If you can, set the PID as a prop to the item in the first script (would probably be wise to erase this prop too after the script exits). Then when the second script fails to move it and tries to delete it, try looking up and killing the PID from the second script (ultimately releasing it) and then try moving it.

Author Message
MuadDib
POL Developer


Joined: 13 Feb 2006
Posts: 830
Location: Indiana, USA

PostPosted: Fri Aug 04, 2006 5:00 am    Post subject: Reply with quote

I remember this, with bandages, on IC. If you was healing, you lost the bandages, if was in a "newbied" zone for deaths.

In 095 (or was it 94?), using releaseitem on each item, in the chrdeath, seemed to fix it. Unsure if it still does with all the changes since.

Author Message
DevGIB



Joined: 06 Feb 2006
Posts: 93

PostPosted: Sat Aug 05, 2006 11:53 pm    Post subject: Reply with quote

thats exactly whats happening maud... its kinda a newbie zone sorta thing but alittle different... and the problem is ive released every item but they still dont seem to move :S

Post new topic   Reply to topic    PenUltima Online Forum Index -> General Help (095) All times are GMT - 4 Hours
Page 1 of 1

 




Powered by phpBB © 2001, 2005 phpBB Group :: Theme & Graphics by GHS & Scott E. Royalty