apibot Posted June 1, 2022 Report Posted June 1, 2022 After successful smelting/crafting, tf2.backpack is not getting updated. let scraps = inventory.filter(item => item.name == "Scrap Metal") let recs = inventory.filter(item => item.name == "Reclaimed Metal") //I have to use inventory from getInventoryContents because tf.backpack is not updated if (scraps.length > 12) { let craft = Math.floor((scraps.length - 12) / 3) for (let i = craft; i > 0; i--) tf.craft(scraps.slice(0, 3)) } also this only craft 1 reclaimed Quote
Dr. McKay Posted June 2, 2022 Report Posted June 2, 2022 You can only perform one craft at a time; sending that many craft requests will get dropped. You should call craft(), then wait for the craftingComplete event before you craft again. Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.