well i found an inventory tutorial on this very website and had to mod it around to fit my game, so i have this function
so that works, but when you start the game, i did this codeCode:function addToslot(item1) { var addItem1 = _root.backpack.attachMovie(item1, item1, 1); addItem1._x = eval("_root.backpack.itemSlot"+currentslotnum)._x; addItem1._y = eval("_root.backpack.itemSlot"+currentslotnum)._y; currentslotnum++; }
and that worked, starterBladeI went to the right slot, but then when i use this code to get another weaponCode:_root.warriorSprite10.addToslot("starterBladeI");
the shortSwordI goes to the second slot, but the starterBladeI disappears. anyone see an obvious error?Code:_root.warriorSprite10.addToslot("shortSwordI");




Reply With Quote