[MOD 0.13] Black Market (sell and buy on the market)

Topics and discussion about specific mods
User avatar
binbinhfr
Smart Inserter
Smart Inserter
Posts: 1524
Joined: Sat Feb 27, 2016 7:37 pm
Contact:

Re: [MOD 0.13] Black Market (sell and buy on the market)

Post by binbinhfr »

It would be nice to make a user-friendly interface, so that would be more convenient to buy) all the products from all the mods.
You can test my mod, I think that the interface is quite friendly for the moment, with subgroups and items, like in the classic game.
And by the way there is an idea that I have to buy could be just what is already learned or discovered in technologies for realism and less cheating.
and buying resources could also be.
I'm afraid I do not want this : for me, one purpose of this mod is to avoid some technology developement and to focus on other ones (ex: focus on rocket production, but avoid military technos). Buying only things that you have discovered is NOT realistic : on a market you can buy ANYthing you want, if you have the money. And the limitation to "cheating" will be the money : prices are exponential with technology, so you won't be able to buy high-end techno items while selling lower ones. You won't have enough money.
My mods on the Factorio Mod Portal :geek:

depeter
Inserter
Inserter
Posts: 26
Joined: Sun Jul 03, 2016 4:59 am
Contact:

Re: [MOD 0.13] Black Market (sell and buy on the market)

Post by depeter »

binbinhfr wrote:I had problems with recycling and replicator mods (even if I thought these problems were solved...).

The problem is that these mods are introducing loops in recipes.
My mod trys to find out which is the "original" recipe to craft an item, in order to compute its price from its logical/original ingredients.
Example :
a recycler mod will introduce a recipe that crafts iron-plate from a green circuit. But this is not the good recipe to use for computing price of iron-plate. I need the original iron-ore to iron-plate recipe. And there is no way to identify it in factorio data...
Same thing with replicator than can craft anything from a special ingredient. I must avoid these recipes.
So I implemented a way to detect this looped recipes and to avoid them, but it seems that it does not always work and that I deleted too many recipes...

PS: you sent me a list of your mods when there is no problem, because I see the roboport recipe in the CSV.
You have so many mods...
Could you progressively one by one reinstall these special recycling/replicators mods and tell me when the robots disappears from the prices menu ? And send me the CSV file at this moment ? I probably did not test alls these special mods... (i tested boxing, dark matter and omnibarrels)
Ok, I'll try to find which mod affects the roboports, and post another zip when I've found it.

Regarding the advanced bob stuff that's not available yet (even in this better zip) : might it be feasible to do try the following things?
*If an item does not have any recipe with a valid cost, instead of omitting it, make it available for 1000 (I think that was the price for alien artifacts, which could be considered a similar case).
*Alternatively, don't allow buying such items directly, but do allow recipes that require a combination of invalid and valid items in some way, for example by pricing the invalid ingredients at the average of the valid ingredients.
These have in common that they might not set an entirely correct price, but the bonus would be that they give the player the option of making the decision himself, instead of just not having them.
Also, just a random thought : you do have prices for various ores etc, which also have no "input", is that because you handled them manually? Or are they marked as a resource somewhere in the game data? In that case, is part of the "problem" that things like the gems I mentioned earlier are not marked as resources in their mods, even though maybe they should be? (Although maybe that's not possible for other reasons)

Regarding multiple recipes : aside from loop avoidance, it might make sense to use the most expensive result for buying and the cheapest (but not entirely free) result for selling? This will generally only have the negative side effect of making certain set-ups not profitable, but would still keep a maximal amount of things buyable and sellable. And generally it wouldn't happen that often, as having multiple (non-free) recipes for the same thing should be pretty uncommon, aside from replicators/recyclers.
And one way of looking at things is that the most important point about replicators/recyclers is just to work (without crashing or omitting valid recipes) but not necessarily getting 100% correct prices, considering that the player can theoretically uninstall their replicators/recyclers and just use this mod to do those things.

Regarding loop avoidance : I don't know how easy this is in the scripting interface that's available, but the problem is essentially about paths in a graph of individual recipes. Currently you seem to solve the loop issue by deleting recipes that seem dodgy (but might in some cases actually be ok), whereas it might be better (if it's doable) to working breadth-first and checking every time if a path has a loop (and then discarding the path if needed, but leaving the nodes intact, albeit possibly marked as having lower priority for future searches to minimize time wasted)?


binbinhfr wrote: for me, one purpose of this mod is to avoid some technology developement and to focus on other ones (ex: focus on rocket production, but avoid military technos). Buying only things that you have discovered is NOT realistic : on a market you can buy ANYthing you want, if you have the money. And the limitation to "cheating" will be the money : prices are exponential with technology, so you won't be able to buy high-end techno items while selling lower ones. You won't have enough money.
That's also one of the reasons I like this mod! Being able to buy things you currently can't build yet (or for which you don't want to set up automation yet) gives you extra flexibility in what you can do, but still at a cost (so it's not outright cheating, more like an alternate way of reaching a certain goal).

User avatar
binbinhfr
Smart Inserter
Smart Inserter
Posts: 1524
Joined: Sat Feb 27, 2016 7:37 pm
Contact:

Re: [MOD 0.13] Black Market (sell and buy on the market)

Post by binbinhfr »

Ok, I'll try to find which mod affects the roboports, and post another zip when I've found it.
thx
Regarding the advanced bob stuff that's not available yet (even in this better zip) : might it be feasible to do try the following things?
Could you give me a link to this bob mods you are talking about, and the item that does not appear in my mod ?
*If an item does not have any recipe with a valid cost, instead of omitting it, make it available for 1000 (I think that was the price for alien artifacts, which could be considered a similar case).
I did that at the begining (I still have a unknown_price in my config.lua), but I deleted it. I will think about putting it back, after trying to understand the "bob problem".
*Alternatively, don't allow buying such items directly, but do allow recipes that require a combination of invalid and valid items in some way, for example by pricing the invalid ingredients at the average of the valid ingredients.
It will need a large change of my mod. For the moement, every item with a price can be bought/sold.
Also, just a random thought : you do have prices for various ores etc, which also have no "input", is that because you handled them manually? Or are they marked as a resource somewhere in the game data?
They are marked as ressources. What is the precise gem item that is missing ? because I installed bob ores and I see gemes ore and ruby, etc....

Note: when you install/unsinstall mod, do not forget to click "rescan" to rebuild the prices list.
Regarding multiple recipes : aside from loop avoidance, it might make sense to use the most expensive result for buying and the cheapest (but not entirely free) result for selling?
No, I want to avoid these special recipes as replicators, reversing, recycling, unboxing, unbarreling, etc... that not real "added value" or "industrial" recipe for me. They are just convenience tools, that used recipes because that's the way factorio works.
Regarding loop avoidance : I don't know how easy this is in the scripting interface that's available, but the problem is essentially about paths in a graph of individual recipes.


That's already what I do in the code : I detect loops when in my recursive scheme I travel twice in the same recipe.(using the recipes_used table)
Currently you seem to solve the loop issue by deleting recipes that seem dodgy (but might in some cases actually be ok)
,

no that's not what I'm doing. That's why I find it strange that your roboport dissapear.
I reinstalled all these strange mods, and verified that my roboport is still here.
It must be something else...

I do not delete any recipe at the end : this prices list is built in two passes. First pass I try to avoid every strange recipes and loops to reach only "logical" recipes. Then a second pass using all recipes to reach every node even strange items like boxes, etc... That's why at the end I can still price boxes, barrels, etc...

The only things that I do not price are no-ingredients "free" items (except resources), but I can set a default unkown price of 1000.
EDIT : I remember now : I remove this default unknown price, in order to have returns from users in case of missing priced items : and that's what happens ! ;-)
otehrwise, with a default price of 1000, you would not have make remark about the missing roboport. So I will wait for the price list building to be stable before introducing a default price.

I am curious to see what makes your roboport dissapear...
My mods on the Factorio Mod Portal :geek:

depeter
Inserter
Inserter
Posts: 26
Joined: Sun Jul 03, 2016 4:59 am
Contact:

Re: [MOD 0.13] Black Market (sell and buy on the market)

Post by depeter »

In the game with all the mods, it's adding the ZRecycling mod that kills the roboports. Looking in the debug log, it blacklists both the recycle recipe and the regular recipe, one behind the other. But unless you really want to get to the bottom of that, I'll leave it there, as I'm uninstalling that mod anyway?

I'll try now to set up a minimal set of mods to replicate the gem issue :) It might indeed be not just Bob, but Bob+Angel, but I'll try to figure out the minimum setup, and post a zip for that (export + logs + mod folder zip).

depeter
Inserter
Inserter
Posts: 26
Joined: Sun Jul 03, 2016 4:59 am
Contact:

Re: [MOD 0.13] Black Market (sell and buy on the market)

Post by depeter »

It is indeed Angel's alternate recipes on top of Bob that cause the problem apparently, as adding Angels loses the gems (and thus the advanced laser turrets and many other items). zip at https://wsi.li/3O1Ljy7WRmyp
I reckon this might be a pretty complicated case though, as Angels messes with a lot of Bob stuff (I think generally in a well-structured and balanced way, but possibly not in such a way that it's easy to process the recipes to set up something like your mod is doing).

EDIT:
binbinhfr wrote:
*If an item does not have any recipe with a valid cost, instead of omitting it, make it available for 1000 (I think that was the price for alien artifacts, which could be considered a similar case).
I did that at the begining (I still have a unknown_price in my config.lua), but I deleted it. I will think about putting it back, after trying to understand the "bob problem".
The basic way I looked at it would be : if a price can't be determined for an item (either naturally, or after blacklisting and loop handling), treat it as an (expensive) resource, and just assign a price to it. But it's probably not as straightforward as that :)

User avatar
binbinhfr
Smart Inserter
Smart Inserter
Posts: 1524
Joined: Sat Feb 27, 2016 7:37 pm
Contact:

Re: [MOD 0.13] Black Market (sell and buy on the market)

Post by binbinhfr »

thx for the help Depeter.
i will test zrecycle.
you did not tell me : what is the exact name of the gem resource that is lacking ? is it gem-ore ? or all ruby, etc... ? because i can still add its avlue manually in the config.lua (you can even do it yourself for testing)
I will have a look at this tonight, but from now on, it's chill time :-)
My mods on the Factorio Mod Portal :geek:

depeter
Inserter
Inserter
Posts: 26
Joined: Sun Jul 03, 2016 4:59 am
Contact:

Re: [MOD 0.13] Black Market (sell and buy on the market)

Post by depeter »

binbinhfr wrote:thx for the help Depeter.
i will test zrecycle.
you did not tell me : what is the exact name of the gem resource that is lacking ? is it gem-ore ? or all ruby, etc... ? because i can still add its avlue manually in the config.lua (you can even do it yourself for testing)
I will have a look at this tonight, but from now on, it's chill time :-)
Ah sorry, it was all the gems (the gem tab is empty in the black market dialogue).

Giving a special price to "gem-ore" (the basic "unsorted gem" that you get as a side-effect from handling ores, and from which you can sort and refine all the other gems) was enough to bring back all the gems and their derived resources (unless they required other things that got blacklisted).

Did some more experimenting, and came up with this relatively short list that seems to cover pretty much everything relevant for my mod list : gem-ore, liquid-air, small-alien-artifact, thermal-water. For now I just assigned all of them resource_price (obviously didn't balance-test thoroughly yet, but did a quick price scan, and didn't see anything that was obviously wrong).

Bonsoir!

Airat9000
Smart Inserter
Smart Inserter
Posts: 1418
Joined: Fri Mar 28, 2014 12:32 am
Contact:

Re: [MOD 0.13] Black Market (sell and buy on the market)

Post by Airat9000 »

binbinhfr wrote:thx for the help Depeter.
i will test zrecycle.
you did not tell me : what is the exact name of the gem resource that is lacking ? is it gem-ore ? or all ruby, etc... ? because i can still add its avlue manually in the config.lua (you can even do it yourself for testing)
I will have a look at this tonight, but from now on, it's chill time :-)
trying to start a new game does not long start .. trying to start an old game, too, will not long start of that garbage? *
throw off a collection of mods.
yes and even the idea I have to make you more comfortable - that was to find the right product and that can not deal among 1700 items manually.

пытаюсь начать новую игру, не стартует.. пытаюсь начать старую игру тоже не грузит что за фигня?*
и да и еще идея у меня к вам удобнее сделать - что бы поиск был товара нужного а то не могу среди 1700 товаров разобраться в ручную.

Airat9000
Smart Inserter
Smart Inserter
Posts: 1418
Joined: Fri Mar 28, 2014 12:32 am
Contact:

Re: [MOD 0.13] Black Market (sell and buy on the market)

Post by Airat9000 »

find bug
faster machines mod

and other items

i am buy assembler machine - bug
link mods
https://yadi.sk/d/k5C_kWDNpaTc2
Attachments
bandicam 2016-08-13 23-38-07-146.jpg
bandicam 2016-08-13 23-38-07-146.jpg (101.96 KiB) Viewed 6439 times

User avatar
binbinhfr
Smart Inserter
Smart Inserter
Posts: 1524
Joined: Sat Feb 27, 2016 7:37 pm
Contact:

Re: [MOD 0.13] Black Market (sell and buy on the market)

Post by binbinhfr »

Giving a special price to "gem-ore" (the basic "unsorted gem" that you get as a side-effect from handling ores, and from which you can sort and refine all the other gems) was enough to bring back all the gems and their derived resources (unless they required other things that got blacklisted).
They were not blacklisted : they were not detected as resource, because something must be missing in bob's prototype. Or in agle ore, because if I just install bob's ore, I see the gems. It's when you install angel ores that something is uncorrect concerning the gems.
But it's the same for vanilla water that is not considered as a resource by the game. I had to enter its value manually. I guess that there will always be a few items to enter manually because modders are not always respecting the strict prototype definition.

Concerning Zrecycle, I made a detection on name recipe, as every other strange mod, but I am working on another more general solution.
All unknown items are now set to 999, I can recognize them easily.
Please update and tell me.
Bonsoir!
Are you french ?
My mods on the Factorio Mod Portal :geek:

User avatar
binbinhfr
Smart Inserter
Smart Inserter
Posts: 1524
Joined: Sat Feb 27, 2016 7:37 pm
Contact:

Re: [MOD 0.13] Black Market (sell and buy on the market)

Post by binbinhfr »

Airat9000 wrote:find bug
faster machines mod

and other items

i am buy assembler machine - bug
link mods
https://yadi.sk/d/k5C_kWDNpaTc2
When you install a mod with new items, you have to click on RESCAN to rebuild the prices of new items. Same thing if you uninstall a mod.

But I corrected the crash. Please update to 1.0.5 and tell me if it works.

Are you talking about this faster machine mod : https://mods.factorio.com/mods/Necro9227/speed_machines ?
My mods on the Factorio Mod Portal :geek:

User avatar
aubergine18
Smart Inserter
Smart Inserter
Posts: 1264
Joined: Fri Jul 22, 2016 8:51 pm
Contact:

Re: [MOD 0.13] Black Market (sell and buy on the market)

Post by aubergine18 »

Taxes on the black market? Surely it should be handler fees or bribes or something like that?

Suggestion: Rather than up/down chevron arrows, why not an arrow pointing at the $ symbol? So ">> $" means "to dollar" (ie. sell) and "$ >>" means "from dollar" (ie. buy)

In the smelter example in OP, the image would then be:

$>> smelter >>$
Better forum search for modders: Enclose your search term in quotes, eg. "font_color" or "custom-input" - it prevents the forum search from splitting on hypens and underscores, resulting in much more accurate results.

Airat9000
Smart Inserter
Smart Inserter
Posts: 1418
Joined: Fri Mar 28, 2014 12:32 am
Contact:

Re: [MOD 0.13] Black Market (sell and buy on the market)

Post by Airat9000 »

binbinhfr wrote:
Airat9000 wrote:find bug
faster machines mod

and other items

i am buy assembler machine - bug
link mods
https://yadi.sk/d/k5C_kWDNpaTc2
When you install a mod with new items, you have to click on RESCAN to rebuild the prices of new items. Same thing if you uninstall a mod.

But I corrected the crash. Please update to 1.0.5 and tell me if it works.

Are you talking about this faster machine mod : https://mods.factorio.com/mods/Necro9227/speed_machines ?
and you can link here? I was not comfortable to climb steadily.

User avatar
binbinhfr
Smart Inserter
Smart Inserter
Posts: 1524
Joined: Sat Feb 27, 2016 7:37 pm
Contact:

Re: [MOD 0.13] Black Market (sell and buy on the market)

Post by binbinhfr »

Taxes on the black market? Surely it should be handler fees or bribes or something like that?
Well, as said in the description, it's the Universal Black Market Company that manages all this. It's almost and official stuff now...

(PS : take also in consideration the fact that I am french, and do not have a full english vocabulary ;-) )
Suggestion: Rather than up/down chevron arrows, why not an arrow pointing at the $ symbol? So ">> $" means "to dollar" (ie. sell) and "$ >>" means "from dollar" (ie. buy)
Yes. I'll do this for next release.
My mods on the Factorio Mod Portal :geek:

Airat9000
Smart Inserter
Smart Inserter
Posts: 1418
Joined: Fri Mar 28, 2014 12:32 am
Contact:

Re: [MOD 0.13] Black Market (sell and buy on the market)

Post by Airat9000 »

binbinhfr wrote:
Taxes on the black market? Surely it should be handler fees or bribes or something like that?
Well, as said in the description, it's the Universal Black Market Company that manages all this. It's almost and official stuff now...

(PS : take also in consideration the fact that I am french, and do not have a full english vocabulary ;-) )
Suggestion: Rather than up/down chevron arrows, why not an arrow pointing at the $ symbol? So ">> $" means "to dollar" (ie. sell) and "$ >>" means "from dollar" (ie. buy)
Yes. I'll do this for next release.
best currency coin put dollars last century :)

User avatar
binbinhfr
Smart Inserter
Smart Inserter
Posts: 1524
Joined: Sat Feb 27, 2016 7:37 pm
Contact:

Re: [MOD 0.13] Black Market (sell and buy on the market)

Post by binbinhfr »

Airat9000 wrote:best currency coin put dollars last century :)
yes, but graphically, $ is a good shortcut for money :-)
My mods on the Factorio Mod Portal :geek:

User avatar
binbinhfr
Smart Inserter
Smart Inserter
Posts: 1524
Joined: Sat Feb 27, 2016 7:37 pm
Contact:

Re: [MOD 0.13] Black Market (sell and buy on the market)

Post by binbinhfr »

1.0.6 - automatically rescan prices if any mod change. Also clean chests orders of uninstalled items.
- new prices scan routine from bottom to top. Should better handle loop recipes.
- Export now generates a list of unpriced items, ready to be edited and included into config.lua
in case user wants to apply specific prices to these unknown items...
- New icons with horizontal chevron arrows to represent "from $" (buy) and "to $" (sell).
1.0.5 - avoid crash when browsing an unpriced object

@depeter : you can try this new pricing routine, totally different from the previous one. No more recurse, but a multi-pass bottom to top scanning of ingredients. I start with resources, and try to crawl to the top. Inhently, it avoids loops and strange recipes. At the end, some items still have no price ; they are given a 999 "unknown" value and can be listed in a TXT file using EXPORT button, to further include them in config.lua if needed. Tell me if it works better with all your mods...
My mods on the Factorio Mod Portal :geek:

ctrlfrk
Manual Inserter
Manual Inserter
Posts: 1
Joined: Sun Aug 14, 2016 12:22 am
Contact:

Re: [MOD 0.13] Black Market (sell and buy on the market)

Post by ctrlfrk »

There seems to be a problem with this mod causing the game to never load: https://mods.factorio.com/mods/Bobingab ... greenhouse

I've toggled all mods off except for base, greenhouse and the library mod it depends on.

I tried dropping back to 1.0.3 and that works so it's probably an issue with the new scanning code.

Nexela
Smart Inserter
Smart Inserter
Posts: 1828
Joined: Wed May 25, 2016 11:09 am
Contact:

Re: [MOD 0.13] Black Market (sell and buy on the market)

Post by Nexela »

ctrlfrk wrote:There seems to be a problem with this mod causing the game to never load: https://mods.factorio.com/mods/Bobingab ... greenhouse

I've toggled all mods off except for base, greenhouse and the library mod it depends on.

I tried dropping back to 1.0.3 and that works so it's probably an issue with the new scanning code.
Greenhouse does a few things differently from most mods and these might be what causes the issue.
Wood to seedling gives a random amount of seedling
Greenhouse [grow trees] recipe takes seedlings and returns raw wood and seedlings (both random) I think.
also has [grow trees with fertilizer] recipe

Airat9000
Smart Inserter
Smart Inserter
Posts: 1418
Joined: Fri Mar 28, 2014 12:32 am
Contact:

Re: [MOD 0.13] Black Market (sell and buy on the market)

Post by Airat9000 »

I liked:
1) Statistics bought and sold goods
2) export to csv (just do not understand how it works)

in general, if you remove the bugs and fix it will be very good mod!
Scanning prices would be good to make some sort of calculation - that would be seen at what stage of counting, and the game slows down is not clear because of what can be

question of how long can keep the coins in the game? let's say I have a product that is worth $ 12 billion coins

что мне понравилось:
1) статистика купленных и проданных товаров
2) экспорт в csv (только не понял как оно работает)

в целом если убрать баги и отремонтировать будет очень хороший мод!
со сканированием ценами хорошо бы сделать какой нибудь подсчет - что бы было видно на каком этапе подсчет, а то игра тормозит не понятно из за чего может быть

вопрос сколько можно монет держать в игре? допустим у меня есть товар который стоит 12 миллиардов монет

Post Reply

Return to “Mods”