The gold Idea to fix trading and logic for AI and player.

This forum is the ideal place for all discussion relating to X4. You will also find additional information from developers here.

Moderator: Moderators for English X Forum

Post Reply
abisha1980
Posts: 563
Joined: Tue, 11. Dec 18, 18:25
x4

The gold Idea to fix trading and logic for AI and player.

Post by abisha1980 » Thu, 21. Mar 24, 18:34

Simple trading goods no longer is possible
but all sales are done via contracts. (like trade contract)

here a few examples,

Station A needs 20.000 energy cells (gives a contract for 20.000 cells at X price) AI or player can pick the contract sell the goods
Station A needs 20.000 energy cells within a set-time (put a contract X amount + X% time on delivery) the less time the more payment

player and AI can add contracts and accept contracts you pay 150% of contract value fail the contract of only have delivery you get only 75% contract value.

Free traders no longer sell goods at station but at general market at the station the more goods at local market less you get for the delivered goods so in theory if there is 20.000 energy cells the whole sale only give 1 or 2 credits per unit.
Retail investor, η+18,9% 2022 (η+7.1% 2023) (η+0,74 2024) 95% in bonds.
Young people don't be freaking stupid invest also (not in BTC but in real stocks)

Feloidea
Posts: 553
Joined: Sat, 25. Apr 09, 11:06
x4

Re: The gold Idea to fix trading and logic for AI and player.

Post by Feloidea » Thu, 21. Mar 24, 20:08

Solution A seems only marginally different from current trade mechanisms because it's an all-or-nothing trade, which would probably not work well to keep stations stocked and if the trade volume per contract is dependent on demand would very quickly diminish to equal the trades the game currently runs on anyway. So that'd really just introduce potential failure points in the supply chain for negligent gains.

Solution B is probably the most propable that could be meaningfully implemented if the trade scripts were to factor in delivery speed estimates and prioritize trades based on that. I have no idea however how difficult that would be to code and how more CPU intensive the extra calculations would be. I would like it if the game gave delivery speed some weighting on which trades are considered profitable (I'd rather have multiple quck trade runs than wait for one big volume order that arrives god knows when because 5 jumps away), but if hasn't been implemented to date then it's probably because there's some limitations on how the script runs on a fundamental level of a design choice by the development team to ensure the game isn't locked behind higher system requirements to run fluidly (the game is already quite CPU intensive).

abisha1980
Posts: 563
Joined: Tue, 11. Dec 18, 18:25
x4

Re: The gold Idea to fix trading and logic for AI and player.

Post by abisha1980 » Thu, 21. Mar 24, 20:30

not really because if contract is taken or send out the goods ether get delivered or not.
difference is that the station reserved the goods say the station needs 50.000 cells it give out 2 contracts both of 20.000 cells it means you can't sell 30.000 cells to that station because you only got 1 contract
or get both contracts but then you can only deliver 40.000 cells.

a station would never send out contracts if there is no storage for goods.

see it like a wholesale contract deal
Retail investor, η+18,9% 2022 (η+7.1% 2023) (η+0,74 2024) 95% in bonds.
Young people don't be freaking stupid invest also (not in BTC but in real stocks)

Zloth2
Posts: 447
Joined: Sat, 7. Jul 18, 17:16
x4

Re: The gold Idea to fix trading and logic for AI and player.

Post by Zloth2 » Fri, 22. Mar 24, 05:23

I don't understand the issue you are trying to solve?
"If you can't take a little bloody nose, maybe you ought to go back home
and crawl under your bed. It's not safe out here! It's wondrous, with
treasures to satiate desires both subtle and gross, but it's not for the
timid." ---- Q

dtpsprt
Posts: 2802
Joined: Wed, 6. Nov 02, 20:31
x4

Re: The gold Idea to fix trading and logic for AI and player.

Post by dtpsprt » Fri, 22. Mar 24, 22:29

That means you want trade to be like in X Rebirth. I'm afraid the train is long gone on that one. Egosoft made their decision and it was not included. What can I say?

User avatar
Duncaroos
Posts: 503
Joined: Wed, 4. Jan 12, 22:23
x4

Re: The gold Idea to fix trading and logic for AI and player.

Post by Duncaroos » Sat, 23. Mar 24, 01:12

abisha1980 wrote:
Thu, 21. Mar 24, 20:30
not really because if contract is taken or send out the goods ether get delivered or not.
difference is that the station reserved the goods say the station needs 50.000 cells it give out 2 contracts both of 20.000 cells it means you can't sell 30.000 cells to that station because you only got 1 contract
or get both contracts but then you can only deliver 40.000 cells.

a station would never send out contracts if there is no storage for goods.

see it like a wholesale contract deal
Isnt that the whole point of dynamic pricing in X4? if you have little stock for sale, you have a high price. Lots of stock for sale - you have a low price. Same with buying (you'll pay more when you're almost out of stock and visa versa).

If sale price <= buy price you have a sale. So if this was the case for my overflowing Solar Power Plant with low sale price, and there's a station that wants say 50,000 units of ECells. So if my trader that can handle say, 25,000 units, can reserve 25,000 units at that price.

I forget if it's the price in which the trade is created, or when you're doing the actual flip); if it's the latter - I think I see where you're coming at. I agreed to send you 25,000 ECell units for 18Cr...the fact you already received 25,000 ECells since then shouldn't affect my agreed price with you.
Playing X4+All_DLC 6.20 Build - on:
CPU: Ryzen 5 5600X; RAM: 4x8GB DDR4 3200MHz; GPU: GTX 1070 8GB, Driver v516.94, DirectX 12.0; OS: Win10 Home 22H2 (19045.3086); Monitor: Single Acer S232HL 1920x1080

Duncaroo's Station Storage Estimator

abisha1980
Posts: 563
Joined: Tue, 11. Dec 18, 18:25
x4

Re: The gold Idea to fix trading and logic for AI and player.

Post by abisha1980 » Sat, 23. Mar 24, 10:22

Duncaroos wrote:
Sat, 23. Mar 24, 01:12
abisha1980 wrote:
Thu, 21. Mar 24, 20:30
not really because if contract is taken or send out the goods ether get delivered or not.
difference is that the station reserved the goods say the station needs 50.000 cells it give out 2 contracts both of 20.000 cells it means you can't sell 30.000 cells to that station because you only got 1 contract
or get both contracts but then you can only deliver 40.000 cells.

a station would never send out contracts if there is no storage for goods.

see it like a wholesale contract deal
Isnt that the whole point of dynamic pricing in X4? if you have little stock for sale, you have a high price. Lots of stock for sale - you have a low price. Same with buying (you'll pay more when you're almost out of stock and visa versa).

If sale price <= buy price you have a sale. So if this was the case for my overflowing Solar Power Plant with low sale price, and there's a station that wants say 50,000 units of ECells. So if my trader that can handle say, 25,000 units, can reserve 25,000 units at that price.

I forget if it's the price in which the trade is created, or when you're doing the actual flip); if it's the latter - I think I see where you're coming at. I agreed to send you 25,000 ECell units for 18Cr...the fact you already received 25,000 ECells since then shouldn't affect my agreed price with you.
exactly it also brakes the game logic on the long run. AI keep sending small amounts because the game try to fill the stations which clots the whole system
if ship X get destroy underway with contract the sell still stands until the sell timed out. say you have 2 contracts (25K cells each) one ship delivers the goods and one get destroyed underway (the station reserves again 25K cells again after time out)
and you pay the fine

same deal for AI if, AI can't deliver the contract they pay your credits.
Retail investor, η+18,9% 2022 (η+7.1% 2023) (η+0,74 2024) 95% in bonds.
Young people don't be freaking stupid invest also (not in BTC but in real stocks)

jlehtone
Posts: 21814
Joined: Sat, 23. Apr 05, 21:42
x4

Re: The gold Idea to fix trading and logic for AI and player.

Post by jlehtone » Sat, 23. Mar 24, 14:30

abisha1980 wrote:
Thu, 21. Mar 24, 18:34
Station A needs 20.000 energy cells (gives a contract for 20.000 cells at X price) AI or player can pick the contract sell the goods
This is the current game.
Station needs energy and announces "buy offer". Ship makes a contract to deliver X ECells at price Y. Then it delivers (or fails).
If X was not all that station needs, then there is a new buy offer for the remaining amount.
If ship fails to deliver, then station re-opens the offer.
Goner Pancake Protector X
Insanity included at no extra charge.
There is no Box. I am the sand.

Post Reply

Return to “X4: Foundations”