Fix misnamed method names; fix looping over inventories.
git-svn-id: svn://svn.code.sf.net/p/crossfire/code/trunk/maps@3999 282e977c-c81d-0410-88c4-b93c2d0d6712master
parent
8d0d431d9d
commit
b69e3f48d4
|
@ -150,7 +150,7 @@ elif text[0] == 'send':
|
||||||
inv = activator.CheckInventory(sackName)
|
inv = activator.CheckInventory(sackName)
|
||||||
map = 0
|
map = 0
|
||||||
if inv != 0:
|
if inv != 0:
|
||||||
while inv != 0:
|
while inv:
|
||||||
next = inv.Below
|
next = inv.Below
|
||||||
text2=string.split(inv.Name)
|
text2=string.split(inv.Name)
|
||||||
if text2[0]==sackName and text2[1]=='T:' and text2[3]=='F:' and text2[2] == text[1]:
|
if text2[0]==sackName and text2[1]=='T:' and text2[3]=='F:' and text2[2] == text[1]:
|
||||||
|
@ -168,10 +168,10 @@ elif text[0] == 'send':
|
||||||
elif text[0] == 'receive':
|
elif text[0] == 'receive':
|
||||||
map = Crossfire.ReadyMap(storage_map)
|
map = Crossfire.ReadyMap(storage_map)
|
||||||
if ( map != 0 ):
|
if ( map != 0 ):
|
||||||
item = map.GetObjectAt(storage_x, storage_y)
|
item = map.ObjectAt(storage_x, storage_y)
|
||||||
count = 0
|
count = 0
|
||||||
while item != 0:
|
while item:
|
||||||
previous = item.above
|
previous = item.Above
|
||||||
text2 = string.split(item.Name)
|
text2 = string.split(item.Name)
|
||||||
if ( len(text2) == 5 ) and ( text2[0] == sackName ) and ( text2[2] == activatorname ):
|
if ( len(text2) == 5 ) and ( text2[0] == sackName ) and ( text2[2] == activatorname ):
|
||||||
activator.InsertObjectInside(item)
|
activator.InsertObjectInside(item)
|
||||||
|
|
Loading…
Reference in New Issue