Break through on factory pricing/econ - MUST SEE!
Moderators: Scripting / Modding Moderators, Moderators for English X Forum
Break through on factory pricing/econ - MUST SEE!
here is the scoop (Burianek is mostly correct):
The "price" column in all of those tfiles, is not a price at all. It is deceptive, in that any change made to it, does directly affect the price.
Here is what it really does:
That column is the number of seconds required to produce a single "production unit" (PU), which is not the same as the number of products.
Example:
Tlasers - working with repair weapon - created a factory for it in tfactories - set it up
set price to 1 - price in factory is 28 ????
energy cells is only resource - cycle time 1:00 - number of products 60
added silicon wafers as a primary:
price = 28
cycle time = 1:36
number of products = 96
made other changes as well - similar results - so how is all this determined by the game?
simple - each product is going to have a price (based on mean) per minute (PERIOD)
seconds per PU determines price per product.
in the above example, there is an approximate (the game does do some rounding) price / minute of 1684.
The computer will use common denominators from all products and resources, to calculate a number of products and cycle time.
There is no guarantee of profit, even using default values. the cost of resources has absolutely no bearing or effect on these figures.
add 4 expensive resources, you will lose money. add 1 cheap resource, you will make money.
each product is going to have a different price per minute factor. I didn't take the time to figure out if it is based on which tfile or location within tfile. I'll let somebody else figure that out.
Energy has one additional factor - the above calulations apply - which brings the PU = 4.6 products (assuming ideal is cycletime 1 min) - but the cycle time is then modified to reflect the efficiency of the sun/SPP in the system.
I expect you'll find that ores work in a similar fashion, except maybe energy useage won't slow down, just because a particular asteroid has a lower prod rate.
With this now understood, it should be easier for people to make econ mods. I hope this is helpful.
The "price" column in all of those tfiles, is not a price at all. It is deceptive, in that any change made to it, does directly affect the price.
Here is what it really does:
That column is the number of seconds required to produce a single "production unit" (PU), which is not the same as the number of products.
Example:
Tlasers - working with repair weapon - created a factory for it in tfactories - set it up
set price to 1 - price in factory is 28 ????
energy cells is only resource - cycle time 1:00 - number of products 60
added silicon wafers as a primary:
price = 28
cycle time = 1:36
number of products = 96
made other changes as well - similar results - so how is all this determined by the game?
simple - each product is going to have a price (based on mean) per minute (PERIOD)
seconds per PU determines price per product.
in the above example, there is an approximate (the game does do some rounding) price / minute of 1684.
The computer will use common denominators from all products and resources, to calculate a number of products and cycle time.
There is no guarantee of profit, even using default values. the cost of resources has absolutely no bearing or effect on these figures.
add 4 expensive resources, you will lose money. add 1 cheap resource, you will make money.
each product is going to have a different price per minute factor. I didn't take the time to figure out if it is based on which tfile or location within tfile. I'll let somebody else figure that out.
Energy has one additional factor - the above calulations apply - which brings the PU = 4.6 products (assuming ideal is cycletime 1 min) - but the cycle time is then modified to reflect the efficiency of the sun/SPP in the system.
I expect you'll find that ores work in a similar fashion, except maybe energy useage won't slow down, just because a particular asteroid has a lower prod rate.
With this now understood, it should be easier for people to make econ mods. I hope this is helpful.
You ask me who I am when I'm alone.
I am never alone, for Death is always with me.......
I am never alone, for Death is always with me.......
PS: I have an endless loop script that updates new factories every 15 sec to add prod and res.
This is how i can now add new factories to shipyards and still deploy them without needing to run a script manually.
All this, just to get a functional repair ship - wheeew!
This is how i can now add new factories to shipyards and still deploy them without needing to run a script manually.
All this, just to get a functional repair ship - wheeew!
You ask me who I am when I'm alone.
I am never alone, for Death is always with me.......
I am never alone, for Death is always with me.......
I'm sorry, I read that three times and I still don't understand what you're trying to say.
If you don't mind walking through a detailed example, I'd appreciate it.
(maybe I'm just tired)
Looks like you spent a lot of time working on this. That's great. Thanks.
If you don't mind walking through a detailed example, I'd appreciate it.
(maybe I'm just tired)
Looks like you spent a lot of time working on this. That's great. Thanks.
"Nature's first green is gold" . . . stay golden.
-
- Posts: 246
- Joined: Fri, 5. Dec 03, 16:08
You are describing the problem.
The result that Burianek and I were reaching for is variation in profit, not variation in price. Originally I was hoping to create an economy fix that Egosoft would patch in, so I adjusted the prices as the least intrusive variable. This works great for existing factories, but the game readjusts the cylcles to compensate on new ones.
(Burianek's v3 mod is essentially a rebalanced version of my original mod. This is why you need to uninstall it before building a new factory.)
Because the tfile number controls product yield and cycle time as variables, it uses margin as a constant. (Or near enough to a constant as makes no difference.)
The important numbers (like the TFile multiplier) all appear to be hard coded. So there is really no way to implement a capitalist economy. (You could remove resource requirements from high end fabs, but that becomes just as unrealistic as the enforced profit rate.)
The result that Burianek and I were reaching for is variation in profit, not variation in price. Originally I was hoping to create an economy fix that Egosoft would patch in, so I adjusted the prices as the least intrusive variable. This works great for existing factories, but the game readjusts the cylcles to compensate on new ones.
(Burianek's v3 mod is essentially a rebalanced version of my original mod. This is why you need to uninstall it before building a new factory.)
Because the tfile number controls product yield and cycle time as variables, it uses margin as a constant. (Or near enough to a constant as makes no difference.)
The important numbers (like the TFile multiplier) all appear to be hard coded. So there is really no way to implement a capitalist economy. (You could remove resource requirements from high end fabs, but that becomes just as unrealistic as the enforced profit rate.)
My purpose wasn't so much trying to enforce profitability, as that is not even possible in real life. But rather, to try and fill my factories with logical figures. Meaning, they should make sense.
I have seen factories that produce 3 products per cycle, but can only store 2. No business/factory will produce more than they can store.
By understanding how the system works, I/we can now have the factories produce number of <= the amount that can be stored.
The ability to adjust profitability is only a side bonus, but not sure I want to do that anyway.
The economy is carefully calibrated by EGOSOFT, and I didn't intend to mess with it. I only wanted my new factory to make sense.
Here is the breakdown:
27;299;0.10000;0.10000;0;23;9813;500;960;23;8000;0.01000;25;100008;25;10;1;SS_LASER_REPAIR;
the bold part is the number of seconds required to produce 1
as it is now, the price of a single unit is over 2.8 million.
The price is determined as follows:
The per minute (60seconds) price of the product is in the neighborhood of 1684 (give or take a few credits. Very few.)
When resources are also added - the system determines a common denominator for all - the resources used here is ore and energy.
if I set up up the time factor to 1 second per unit, I get a common denominator of 72. that is - 1:12 for cycle time - 72 products at a price of 28 each.
If I keep the time required for a single unit as a multiple of 72, My factory will make only 1 unit per production cycle (for large ticket items)
That was what I was trying to achieve. Everything Burianek did and explained was correct, but this single point got missed.
With this information, it is now possible to adjust how many products per cycle. Remembering, of course, to do so, you are also adjusting price and time per cycle. But, it shouldn't be that hard to get a multiple of the common denom and stay close to the original price(at least on high ticket items)
The next 2 numbers 25;10 are used to determine allowable price variation from the calculated value. The 25 in this case, allows the player to adjust the price in his/her factory by as much as 25% of the calculated price.
I'm not really sure about the second value of 10 - wasn't really concerned about those 2 values.
I suspect that the 10 has something to do with either AI factories' price adjustment(behavior not limit) or discount/markup when purchased with ship??? - don't really know yet.
If some one does know, post it here, please.
I hope this explains what I was trying to say, a little better
I have seen factories that produce 3 products per cycle, but can only store 2. No business/factory will produce more than they can store.
By understanding how the system works, I/we can now have the factories produce number of <= the amount that can be stored.
The ability to adjust profitability is only a side bonus, but not sure I want to do that anyway.
The economy is carefully calibrated by EGOSOFT, and I didn't intend to mess with it. I only wanted my new factory to make sense.
Here is the breakdown:
27;299;0.10000;0.10000;0;23;9813;500;960;23;8000;0.01000;25;100008;25;10;1;SS_LASER_REPAIR;
the bold part is the number of seconds required to produce 1
as it is now, the price of a single unit is over 2.8 million.
The price is determined as follows:
The per minute (60seconds) price of the product is in the neighborhood of 1684 (give or take a few credits. Very few.)
When resources are also added - the system determines a common denominator for all - the resources used here is ore and energy.
if I set up up the time factor to 1 second per unit, I get a common denominator of 72. that is - 1:12 for cycle time - 72 products at a price of 28 each.
If I keep the time required for a single unit as a multiple of 72, My factory will make only 1 unit per production cycle (for large ticket items)
That was what I was trying to achieve. Everything Burianek did and explained was correct, but this single point got missed.
With this information, it is now possible to adjust how many products per cycle. Remembering, of course, to do so, you are also adjusting price and time per cycle. But, it shouldn't be that hard to get a multiple of the common denom and stay close to the original price(at least on high ticket items)
The next 2 numbers 25;10 are used to determine allowable price variation from the calculated value. The 25 in this case, allows the player to adjust the price in his/her factory by as much as 25% of the calculated price.
I'm not really sure about the second value of 10 - wasn't really concerned about those 2 values.
I suspect that the 10 has something to do with either AI factories' price adjustment(behavior not limit) or discount/markup when purchased with ship??? - don't really know yet.
If some one does know, post it here, please.
I hope this explains what I was trying to say, a little better
You ask me who I am when I'm alone.
I am never alone, for Death is always with me.......
I am never alone, for Death is always with me.......
I should also point out:
Adding items in certain Tfiles will not work. Notably Tships (the most talked about) and Tlasers. Probably others as well. These files have some hard code pointing to locations and/or tags within the file. Subtypes are, after all, simply the index (location) with the file.
I added a new set of lasers, factories could produce and sell them, players could buy them. But no ship could mount them.
Tcockpits contains a number for each turret, that defines which lasers could go there. (yes I understand how the number works, even have post somewhere here that describes the process of adding laser possibilities to a turrent or main gun.) I extended and added the appropriate amount, all to no avail. The code only looks at the numbers originally defined.
However, products that are resources, should be able to be added with impunity. Just remeber to adjust existing factories and stations, so somebody will want them.
Adding items in certain Tfiles will not work. Notably Tships (the most talked about) and Tlasers. Probably others as well. These files have some hard code pointing to locations and/or tags within the file. Subtypes are, after all, simply the index (location) with the file.
I added a new set of lasers, factories could produce and sell them, players could buy them. But no ship could mount them.
Tcockpits contains a number for each turret, that defines which lasers could go there. (yes I understand how the number works, even have post somewhere here that describes the process of adding laser possibilities to a turrent or main gun.) I extended and added the appropriate amount, all to no avail. The code only looks at the numbers originally defined.
However, products that are resources, should be able to be added with impunity. Just remeber to adjust existing factories and stations, so somebody will want them.
You ask me who I am when I'm alone.
I am never alone, for Death is always with me.......
I am never alone, for Death is always with me.......
ok, so what you're really saying is this is a careful way to pick a price for a ware to insure that the least common multiple of products / resources usually ends up with a useable number, and not one that is likely to break production. I understand.Bezredahl wrote:By understanding how the system works, I/we can now have the factories produce number of <= the amount that can be stored.
You're right, you have to be careful of those least common multiple calculations when you're setting up a factory.
Kind of. It's still not possible to independently alter number of products and cycle time. Rate of production is fixed. What you can alter, as you say, by picking reasonable price values, is both the size of the batch produced and at the same time, the cycle time to produce it. (but not independently)With this information, it is now possible to adjust how many products per cycle. Remembering, of course, to do so, you are also adjusting price and time per cycle. But, it shouldn't be that hard to get a multiple of the common denom and stay close to the original price(at least on high ticket items)
That's price variation when the ware is used as a 2ndry resource. I think it's labeled in SF's mod kit. If you don't have that yet, get it from the site in my signature. It's very helpful.The next 2 numbers 25;10 are used to determine allowable price variation from the calculated value. The 25 in this case, allows the player to adjust the price in his/her factory by as much as 25% of the calculated price.
I'm not really sure about the second value of 10 - wasn't really concerned about those 2 values.
Cheers.
"Nature's first green is gold" . . . stay golden.
Been there, done thatYou seem to understand exactly what I am saying and why!
Although that was an excellent bit of sleuthing that each ware is priced at 28 credits per second per production of 1 unit. I used to think of price in terms of a multiplier applied to the price column. I think I like your way better. It's just a different way of arriving at the same place, but it's a bit cleaner.
Just be careful because each tfile can have a different 'multiplier' I'm not certain your 28 rule works for everything.
Welcome to the ostracized nuthead economy club!
added a link to this discussion from the stickied thread.Could somebody sticky this one?
Last edited by Burianek on Wed, 7. Jul 04, 17:07, edited 1 time in total.
"Nature's first green is gold" . . . stay golden.
you can, indirectly by changing ware price, but if you're asking can you keep the number of products and price constant, but make the station make them more quickly, then no, you can't
read this.
read this.
"Nature's first green is gold" . . . stay golden.
-
- Posts: 246
- Joined: Fri, 5. Dec 03, 16:08
We aren't trying to enforce profitability either... All of us economy nuts would be happy with ENABLING profitability.Bezredahl wrote:My purpose wasn't so much trying to enforce profitability, as that is not even possible in real life.
Well.... Only if you consider wholesale enforced equality to be "carefully calibrated". The economy was balanced by making it static.Bezredahl wrote:The economy is carefully calibrated by EGOSOFT...
Unfortunately, this also means that max profit/minute remains constant, and can't be altered. Thats why I gave up working on an economy fix. Though it will work fine for what you are doing. (Creating new products/factories and such.)Bezredahl wrote:With this information, it is now possible to adjust how many products per cycle. Remembering, of course, to do so, you are also adjusting price and time per cycle.
Burianek wrote:you can, indirectly by changing ware price, but if you're asking can you keep the number of products and price constant, but make the station make them more quickly, then no, you can't
read this.
many thak yous
Lets make my rastar refinery more profitable
Correct.
You can also alter profitability by using scripting to layer an 'extra production cycle' on top of the default one. Kind of like what I do in this script.
This has many far reaching uses, but due to the relative lack of economy scripting commands can be a real pain in the you know what to deal with.
You can also alter profitability by using scripting to layer an 'extra production cycle' on top of the default one. Kind of like what I do in this script.
This has many far reaching uses, but due to the relative lack of economy scripting commands can be a real pain in the you know what to deal with.
"Nature's first green is gold" . . . stay golden.