Return to “Dev Logs”

Post

Re: [Josh] Friday, April 20, 2018

#31
Important to market simulation is the concept of imperfect information. You may see the markets smooth out if you add some factor to reduce information availability based on distance or exposure. So for instance, a water trader would very quickly react to changes in market price at a location nearby that needs water, but a miner would more commonly react to changes in the price of ore, and never consider water if the location is distant. Add an element if random chance also, and it would lower chance of switching.

You could also mock some amount of the transition by causing distant actors to be aware of the number of switches by other actors that occurred before reaching them. For instance, each actor, when acting, triggers a check for the best action. It determines what the best action is and locks in its course, which immediately increases the future cost for other actors, making the opportunity cost of switching higher for each other actor evaluating that action. What you wind up with is two measures... market prices of goods, seen by the player, and the non players evaluation of yield, which is influenced by omniscience about what other actors are doing.

Its not a perfect simulation, but it would more accurately simulate a real economy, wherein task switching is heavily influenced by the area individuals concern themselves with, and the information they have available around those areas. Perfect information causes crazy trends, unless you spin it in your favor by effectively updating prices before goods are delivered based on the actions the AI will take. Hopefully that doesn't cause too much recursion... have to test it to see.

Oh also! Don't let actors deviate from their assigned task unless certain major events take place, such as being attack. So actors always see acts to completion unless X list of things occur, like a cost opportunity outside of a large range occurs nearby, or they are attack, or someone else the like is attack nearby, etc.
Last edited by MyNameWuzTaken on Sat Apr 21, 2018 5:25 pm, edited 1 time in total.
Post

Re: [Josh] Friday, April 20, 2018

#32
RedDwarfMining wrote:
Sat Apr 21, 2018 8:42 am
The universe's structure/data would be updated by a simulator...NOT while you are playing the game.
By a what?
The game needing some external tool to be run for days to work properly?

The simulation needs to run synchronously with the game to have any effect.
If planetary prices only change after i've run the "update economy.ltl" routine for a day or so it could as well be fixed and derived from the seed.

The game also has to utilise that data at some point, if its never loading it it could as well not exist.
Post

Re: [Josh] Friday, April 20, 2018

#33
BagOfBread wrote:
Sat Apr 21, 2018 12:16 pm
As mentioned by the other comments, right now it looks like the AI entities might just be reacting to market conditions too fast, and need some kind of momentum.
  • Increasing the size of stockpiles, and therefore reducing the short term effect of entities should work (e.g. if stockpiles drop from 50->40 it's a huge price change, but not so much for 500->490).
  • Smooth out prices by averaging demand/supply for the past n minutes, for "historical" memory
  • In line with the long term/fast term idea, just adding a delay to entities entering, switching, or leaving a market might work well enough (even if they have to operate at a loss for some time).

You could also have speculators that look at the derivative / change of price, and buy/sell if the price of a commodity is going up/down. It should smooth out the cycles by reducing the extremities of the cycles. Unless you have too many speculators of course, which would drive constant turnip/bitcoin crazes and crashes.
All good ideas. And in the most sophisticated markets, some people examine the second derivative and even the third derivative, looking for upcoming opportunities. Selling before a crash is an opportunity. And there are huge sales of various graphing capabilities with tools to fit the best types of curves to the data to make projections.

regards,
Charles
Post

Re: [Josh] Friday, April 20, 2018

#35
JoshParnell wrote:
Fri Apr 20, 2018 12:48 pm
The next step for me is smoothing out the volatility of the economy and AI behavior. It's somewhat interesting that periodic/cyclic patterns always seem to emerge in my basic simulated economies when AI agents don't have access to historical data. That result is pretty obvious I guess, but still, interesting to see "those who don't remember the past are doomed to repeat it" play out so literally on-screen. The cyclic behavior can be seen as far back as Development Update #15 (March 2014!), when I introduced colony dynamics and AI job switching for the first time. I've never done a great job of smoothing over this volatility before, but I'm quite convinced that it's a pretty simple matter of factoring in historical data (EMAs mostly) + having a distribution of various AI behaviors with respect to time scale. Some AI agents should act on fast-moving EMAs, making 'short-sighted' decisions about jobs & markets, while others should act on slow/long-period averages, making 'long-term' decisions -- together, the result is a smoothing of the economy at all time scales.
Thinking some more about this. I'm not sure that Josh should actually try to achieve 'smoothing out the volatility of the economy'. I think that he should just try to slow it down. Ideally, make it occur at different rates in different products and services and even better, at different rates in different systems. Which increases the opportunities for inter-system traders.

Some of the relevant ideas
- Ateerix, bdav, MyNameWuzTaken - access to information based on access/relevance to current role and distance (number of inter-system jumps).
- Kekasi - retooling / transitioning cost, including the cost (which may be 'just' time) of learning new skills, gaining access to new sources of information etc.

And at the end of the day, Josh should choose his own approach that is consistent with his vision and is relatively easy to implement.

regards,
Charles
Post

Re: [Josh] Friday, April 20, 2018

#36
Additionally, not every AI needs to be willing to switch tasks. Assuming AI will have some personality, throw in a comfort modifier. Only Ambitious AI are likely to switch tasks from what they prefer to participate in. One of the things that makes market simulation so difficult is that simulations are typically based around all parties as rational actors. Adding irrationality to the individual AI will smooth out some of the strange behaviour.
Post

Re: [Josh] Friday, April 20, 2018

#37
Cornflakes_91 wrote:
Sat Apr 21, 2018 5:24 pm
RedDwarfMining wrote:
Sat Apr 21, 2018 8:42 am
The universe's structure/data would be updated by a simulator...NOT while you are playing the game.
By a what?
The game needing some external tool to be run for days to work properly?

The simulation needs to run synchronously with the game to have any effect.
If planetary prices only change after i've run the "update economy.ltl" routine for a day or so it could as well be fixed and derived from the seed.

The game also has to utilise that data at some point, if its never loading it it could as well not exist.
Hey, Cornflakes - How about some distributed computing? Some cheap EC2 instances to offload simulating adjacent sectors?
By the time LT comes out , that bitcoin craze may pass and some sweet mining rigs may be cheap to get. ;)
Post

Re: [Josh] Friday, April 20, 2018

#38
lobosan wrote:
Sun Apr 22, 2018 9:45 pm
Hey, Cornflakes - How about some distributed computing? Some cheap EC2 instances to offload simulating adjacent sectors?
By the time LT comes out , that bitcoin craze may pass and some sweet mining rigs may be cheap to get. ;)
And have a single player game that needs a server rack to work?

Or because network transfer speeds are faster than local drive transfer speeds?

Or to delay LT by another three years to implement the distributable computing?
Post

Re: [Josh] Friday, April 20, 2018

#39
Will be interesting to see how the missions will play out or how the AI feels in terms of transparency for the player. There might be a ton of data that could explain why the AI acts like it did but when the data is hidden from the player
or not presented in a good understandable way the player might just see the behavior of the AI as unexplainable/unreasonable. Just imagine you pick up an anti-pirate mission and because someone else already killed the pirate or the pirate decided to move on to another sector or another profession you might sit at the target location for a long time waiting for your mission objective where in a game with a more scripted AI, it would just generate the pirate.
Post

Re: [Josh] Friday, April 20, 2018

#40
Cornflakes_91 wrote:
Sat Apr 21, 2018 5:24 pm
RedDwarfMining wrote:
Sat Apr 21, 2018 8:42 am
The universe's structure/data would be updated by a simulator...NOT while you are playing the game.
By a what?
The game needing some external tool to be run for days to work properly?

The simulation needs to run synchronously with the game to have any effect.
If planetary prices only change after i've run the "update economy.ltl" routine for a day or so it could as well be fixed and derived from the seed.

The game also has to utilise that data at some point, if its never loading it it could as well not exist.
No Faster Than Light communication. Your prices/data from a system 10 light years away will always be 10 years old. You'll take your chances trying to sell cargo with it.

A colony a hundred light years away might already be dead and no point in trading with them.....their prices are out of date anyway...100 years old.
Last edited by RedDwarfMining on Mon Apr 23, 2018 8:19 am, edited 1 time in total.
Post

Re: [Josh] Friday, April 20, 2018

#42
Dinosawer wrote:
Mon Apr 23, 2018 8:18 am
How is there no FTL communication when there is FTL travel?
My LT universe, there is no FTL.

Knowing the prices of a system, at any distance, is just another room/skybox simulator. Vast distances are meaningless.

Risk reward.....taking your goods to another system should be a gamble...you know their supply of pink underwear is low...but the data is old.
Last edited by RedDwarfMining on Mon Apr 23, 2018 8:31 am, edited 1 time in total.
Post

Re: [Josh] Friday, April 20, 2018

#45
Dinosawer wrote:
Mon Apr 23, 2018 8:27 am
Erm, okay.
Then why simulate a galaxy when you can't travel to another system anyway?

That's why you simulate the universe.......SETA(egosoft)does this....You take your chance that the universe will change on a 100 ly voyage. (simulated in a couple of hours)

And when you return home...200 years have passed! And pirates have destroyed and looted all your stuff.

Online Now

Users browsing this forum: No registered users and 3 guests

cron