Ore Merchant

by RedRafe

Adds recipes to trade resource and materials for coins and buy back what you need

Content
2 years ago
1.1
1.13K
Cheats

g [Solved] Hand crafting is broken

2 years ago
(updated 2 years ago)

I don't know how to fix it.
Due to the fact that we have two-sided recipes for basic resources (boards / gears), it does not allow you to craft even the simplest fast belt (edited) - you do not have enough coins.

It's strange that I have not seen the same bug in other mods.

However, we can handcraft parts of the normal recipe separately, and then assemble the final one.
Apparently there is some problem with finding the best recipes in the manual crafting for the available resources.

2 years ago
(updated 2 years ago)

-del

2 years ago

ok, it can be fixed with
allow_as_intermediate = false,
for your recipes (ResourceToCoin & CoinToResource functions)

2 years ago
(updated 2 years ago)

hello saaadel can help me where i can put allow_as_intermediate = false in 2 methods in recipe.lua file (i not lua devoloper) and thanks :)

2 years ago

lib/recipe.lua
---CUT--- #1
local function ResourceToCoin(exchange)
return {
type = "recipe",
name = exchange.resource .. "-for-coin",
allow_as_intermediate = false, -- THIS LINE <<<<<<<<<<<<<<<<<<<<<
order = GetItemOrder(exchange),
---CUT---#1

---CUT---#2
local function CoinToResource(exchange)
return {
type = "recipe",
name = "coin-for-" .. exchange.resource,
allow_as_intermediate = false, -- THIS LINE <<<<<<<<<<<<<<<<<<<<<
order = GetItemOrder(exchange),
---CUT---#2

2 years ago

thanks very much for help :)

2 years ago

patch for "git patch" terminal command: https://pastebin.com/DRcE1YyD

2 years ago

but now if you dont have coins will not use it for craft XD

2 years ago
(updated 2 years ago)

No, that's a different idea:
Handcrafting only works for common materials/ores, and in case you want to spend coins, the ingredients have to be made separately — explicit recipes (coins => ingredient/product).

So, if you select a some product for handcrafting, it will use common materials only.
a
EDIT: yep, it's not the best solution. But for me, it's convenient. At least it fixed common way via standard/common materials

2 years ago

ok i understand what you try to do now thanks :)

2 years ago
(updated 2 years ago)

it look like mod bug with item in other mod (i remmember before mod work normal untill open more researches happen)

i will try with
ResourceToCoin
allow_as_intermediate = false,

CoinToResource
allow_as_intermediate = true, (i dont think i need make it false (maybe bug from ResourceToCoin i dont know i only test XD))

2 years ago
(updated 2 years ago)

you know how i can make it like black market 2 have all items you research automatic ? (i know this not one line of code XD i mean is there thing in api get all researched recipes in game ?)

2 years ago

Fixed handcrafting for the new release! Thanks for the help & feedbacks

This thread has been locked.