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
Search and move corpses

 
Post new topic   Reply to topic    PenUltima Online Forum Index -> Scripting Help
Display posts from previous:   

Author Message
westrupp



Joined: 01 Aug 2007
Posts: 26
Location: Brazil

PostPosted: Fri Mar 28, 2008 9:17 am    Post subject: Search and move corpses Reply with quote

This script search and print name of corpse but dont move corpse, i already tryied others sintaxes but dont work, any have ideia?

Code:

        foreach corpse in ListItemsNearLocationOfType( coords.x, coords.y, coords.z, 5, UOBJ_CORPSE )
            PrintTextAbovePrivate( corpse, corpse.desc, character );
            MoveItemToLocation(corpse, obj.x, obj.y, obj.z , MOVEITEM_FORCELOCATION);
        endforeach


Thanks,


Last edited by westrupp on Fri Mar 28, 2008 9:43 am; edited 1 time in total

Author Message
ncrsn



Joined: 10 Feb 2006
Posts: 168

PostPosted: Fri Mar 28, 2008 9:21 am    Post subject: Reply with quote

That does not make sense.

I don't know what the obj is, but try this snippet instead:

Code:

foreach corpse in ListItemsNearLocationOfType( coords.x, coords.y, coords.z, 5, UOBJ_CORPSE )
            PrintTextAbovePrivate( corpse, corpse.desc, character );
            MoveItemToLocation(corpse, obj.x, obj.y, obj.z , MOVEITEM_FORCELOCATION);
        endforeach

Author Message
westrupp



Joined: 01 Aug 2007
Posts: 26
Location: Brazil

PostPosted: Fri Mar 28, 2008 9:42 am    Post subject: Reply with quote

ncrsn wrote:
That does not make sense.

I don't know what the obj is, but try this snippet instead:



I not in my home now and make this new script i forget change name of variable but already tryed this and dont work, he still dont move corpses...

Sad

Author Message
ncrsn



Joined: 10 Feb 2006
Posts: 168

PostPosted: Fri Mar 28, 2008 10:01 am    Post subject: Reply with quote

Corpses are unmovable by default; thus.

Code:

foreach corpse in ListItemsNearLocationOfType( coords.x, coords.y, coords.z, 5, UOBJ_CORPSE )
            PrintTextAbovePrivate( corpse, corpse.desc, character );
            corpse.movable := 1;
            MoveItemToLocation(corpse, obj.x, obj.y, obj.z , MOVEITEM_FORCELOCATION);
            corpse.movable := 0;
        endforeach


That should do.

Author Message
westrupp



Joined: 01 Aug 2007
Posts: 26
Location: Brazil

PostPosted: Fri Mar 28, 2008 10:37 am    Post subject: Reply with quote

thanks for the hinkt, i try this...

Author Message
westrupp



Joined: 01 Aug 2007
Posts: 26
Location: Brazil

PostPosted: Sat Mar 29, 2008 3:52 am    Post subject: Reply with quote

ncrsn wrote:
Corpses are unmovable by default; thus.

Code:

foreach corpse in ListItemsNearLocationOfType( coords.x, coords.y, coords.z, 5, UOBJ_CORPSE )
            PrintTextAbovePrivate( corpse, corpse.desc, character );
            corpse.movable := 1;
            MoveItemToLocation(corpse, obj.x, obj.y, obj.z , MOVEITEM_FORCELOCATION);
            corpse.movable := 0;
        endforeach


That should do.


this work perfect, thanks...

any idea how equip items from corpse?

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

 




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