TypeError: invokeMember (takeItem) on JavaObject[haven.purus.pbot.PBotItem@3c6164ff (haven.purus.pbot.PBotItem)] failed due to: Arity error - expected: 1 actual: 0
at <js> :=>(scripts\Farmer.PBot:111:4607-4625)
at <js> startFarmingBtn(scripts\Farmer.PBot:60-126:2878-5098)
at <js> :program(Unnamed:1:0-16)
at org.graalvm.polyglot.Context.eval(Context.java:371)
at haven.purus.pbot.gui.PBotWindow$1$1.run(PBotWindow.java:37)
at java.lang.Thread.run(Unknown Source)
Problem is in row seeds[0].takeItem(); but i dont really know what takeItem method parameters
I tried
- Code: Select all
seeds[0].takeItem("gfx/invobjs/seed-flax");
- Code: Select all
seeds[0].takeItem(seeds[0]);
- Code: Select all
seeds = javaListToArray(PBotUtils.playerInventory().getInventoryItemsByResnames([seedname]));
Help please with this problem, i dont very strong in js, and are there any documentation for api?