Hermes
dziwki kola gramy w lola
Hello,
I've managed to find this scipt (title). But I tried to make it working, no way. Is something wrong in code? Or should I add a line to movements.xml with actionid?
Here is the scipt.
And how I can optimize this thing? Such a short ingame use, but many lines in code.
Reg~,
Hermes
I've managed to find this scipt (title). But I tried to make it working, no way. Is something wrong in code? Or should I add a line to movements.xml with actionid?
Here is the scipt.
Code:
function onAddItem(moveitem, tileitem, pos)
item1 = 2335
item2 = 2336
item3 = 2337
item4 = 2338
item5 = 2339
item6 = 2340
item7 = 2341
helmetpos = {x=995, y=1104, z=9, stackpos=255}
helmet = getThingfromPos(helmetpos)
helmetpos1 = {x=995, y=1104, z=9, stackpos=8}
helmetpos2 = {x=995, y=1104, z=9, stackpos=7}
helmetpos3 = {x=995, y=1104, z=9, stackpos=6}
helmetpos4 = {x=995, y=1104, z=9, stackpos=5}
helmetpos5 = {x=995, y=1104, z=9, stackpos=4}
helmetpos6 = {x=995, y=1104, z=9, stackpos=3}
helmetpos7 = {x=995, y=1104, z=9, stackpos=2}
helmet1 = getThingfromPos(helmetpos1)
helmet2 = getThingfromPos(helmetpos2)
helmet3 = getThingfromPos(helmetpos3)
helmet4 = getThingfromPos(helmetpos4)
helmet5 = getThingfromPos(helmetpos5)
helmet6 = getThingfromPos(helmetpos6)
helmet7 = getThingfromPos(helmetpos7)
if moveitem.itemid == item7 and helmet1.itemid == item1 and helmet2.itemid == item2 and helmet3.itemid == item3 and helmet4.itemid == item4 and helmet5.itemid == item5 and helmet6.itemid == item6 then
doRemoveItem(helmet1.uid, 1)
doRemoveItem(helmet2.uid, 1)
doRemoveItem(helmet3.uid, 1)
doRemoveItem(helmet4.uid, 1)
doRemoveItem(helmet5.uid, 1)
doRemoveItem(helmet6.uid, 1)
doRemoveItem(helmet7.uid, 1)
doCreateItem(2342,1,helmetpos)
doSendMagicEffect(pos, 6)
else
end
return 1
end
And how I can optimize this thing? Such a short ingame use, but many lines in code.
Reg~,
Hermes