[SCRIPT] RedStar TradeNet V1.07 (Best buy/sell upgrade) BUGFIX! 16/3/06

The place to discuss scripting and game modifications for X³: Reunion.

Moderators: Moderators for English X Forum, Scripting / Modding Moderators

User avatar
RJV
Posts: 2099
Joined: Mon, 29. Mar 04, 09:45
x3tc

[SCRIPT] RedStar TradeNet V1.07 (Best buy/sell upgrade) BUGFIX! 16/3/06

Post by RJV » Tue, 7. Mar 06, 14:31

Hello all,

RELEASE VERSION - V1.07, updated 16th March 2006
Fixed...
- Error preventing correct installation

Previous Version - V1.06, updated 10th March 2006
Added...
- Removed spurious message to player log

Previous version - V1.05, updated 10th March 2006
Added...
- Sector traffic report
- List sorting by price
- Messages use 'Incoming message/question'
- Code optimisations

For all those that like to lay NavSats and go manual trading, here's a little something to lessen the frustration.

Some goods are better for trading than others, we all know that, so assuming you know what you want to trade in, this could be of use to you.

RedStar Enterprises presents the RedStar Dynamic TradeNet.

Check your ships Orders/Trade commands, and you will see 2 options (buy and sell). Each option will prompt you to specify a jump radius, a good you wish to trade in, and a start point for your radius. The software will then scan all the sectors in the radius IN WHICH YOU HAVE AN ASSET (ship, station, sat), then provide you with a list (up to 5 stations), sorted by best price of where that commodity is being bought (sold) at a 'favourable' price. It will also tell you the closest jumpgate and how many km from the gate to the station.

You then have the option to look at a sector traffic report which will give you a count of the number of ships currently inbound (already in sector) to each of the stations in the list, in case you don't fancy racing someone.

It's up to you then if you want to take advantage of the deals.

Prerequisites - Best Buy locator for the buy option, BSL for the sell.

There's no cheating here, no exploits and the script doesn't play the game for you. Just a little something to make life easier.


Zip version here

Cycrow .spk version here

[EDIT - uses t file 7170, pageID 7170, Trade Command Slots 43 and 44]

Cheers,

Rob.
Last edited by RJV on Thu, 16. Mar 06, 19:40, edited 10 times in total.

napalm_nabd
Posts: 25
Joined: Thu, 24. Nov 05, 04:25
x3tc

Post by napalm_nabd » Tue, 7. Mar 06, 14:36

Very interesting, will give it a go tonight when I get home. (If I'm not to busy watching the football 'Come on Barcelona!!!' :twisted:

Napalm

User avatar
Red Spot
Posts: 3461
Joined: Fri, 4. Feb 05, 13:44
x3

Post by Red Spot » Tue, 7. Mar 06, 15:37

you do realize that a star from a distance is actually just a 'spot' ..... :roll:


anyway .. nice idea .. :thumb_up:



G

User avatar
RJV
Posts: 2099
Joined: Mon, 29. Mar 04, 09:45
x3tc

Post by RJV » Tue, 7. Mar 06, 15:43

Red Spot wrote:you do realize that a star from a distance is actually just a 'spot' ..... :roll:


anyway .. nice idea .. :thumb_up:



G
Thanks. I hope people find it useful.

Hehe. I took my corporation name that I used in X2 as I like the sound of it. I actually considered a change in deference to your good self.... Then I thought, nah :D

Cheers,

Rob.

zergfest90
Posts: 339
Joined: Sun, 1. Jan 06, 06:29
x3tc

Post by zergfest90 » Tue, 7. Mar 06, 15:53

I really like the sound of the feature that checks the distance from the gate. For me, the varying distances from gate to factory enhances the realism of the game. But it also makes manual trading doggone annoying in those sectors where the gate is mucho far away.

I wouldn't mind code that generated a new map of the galaxy showing distances from the Trading Station to all jump gates...

alphalvr
Posts: 1540
Joined: Sun, 13. Nov 05, 18:19
x3ap

Post by alphalvr » Tue, 7. Mar 06, 16:42

well the existing map tells you the distance between gates so its not hard to estimate the distance to trading station, as long as you can see it on the map that is. :D

thats how i di it anyway, unless i got wrong end of the stick :oops:

User avatar
RJV
Posts: 2099
Joined: Mon, 29. Mar 04, 09:45
x3tc

Post by RJV » Fri, 10. Mar 06, 11:16

First post amended for new version (V1.05)

Now features Local Sector Traffic Reports.

Cheers,

Rob.

Puruco
Posts: 527
Joined: Tue, 6. Dec 05, 00:09
x3

Post by Puruco » Fri, 10. Mar 06, 19:23

Hi RJV: Can I make the search from my ship and the wares are in other?

argharg
Posts: 286
Joined: Thu, 11. Dec 03, 07:40
x3

Post by argharg » Sat, 11. Mar 06, 00:44

hi, looks cool, mind packing it up into cycrow script loader format, would make my life easier :)

User avatar
RJV
Posts: 2099
Joined: Mon, 29. Mar 04, 09:45
x3tc

Post by RJV » Sat, 11. Mar 06, 01:14

Puruco wrote:Hi RJV: Can I make the search from my ship and the wares are in other?
The search is completely independent of what you have on board any of your ships. It is a free choice, you can select any ware in the X-universe.

Cheers,

Rob.

User avatar
RJV
Posts: 2099
Joined: Mon, 29. Mar 04, 09:45
x3tc

Post by RJV » Sat, 11. Mar 06, 01:16

argharg wrote:hi, looks cool, mind packing it up into cycrow script loader format, would make my life easier :)
There will be a .spk version sometime over the weekend with any luck. I have one or two internal changes to make, and once I have those finished I'll make it available as either .spk or or .zip.

[EDIT] - Now available in both .zip and .spk flavours :D

Cheers,

Rob.

zergfest90
Posts: 339
Joined: Sun, 1. Jan 06, 06:29
x3tc

How to make this work?

Post by zergfest90 » Mon, 13. Mar 06, 08:18

I checked the trade menu on a ship equipped with the Best Buy and Best Sell upgrades, and I didn't see these additional commands.

I thought maybe one of my other scripts was interfering with this one. But I tried this script in a 'Vanilla' game with no other scripts installed and still didn't have any luck.

Any help would be appreciated!

User avatar
RJV
Posts: 2099
Joined: Mon, 29. Mar 04, 09:45
x3tc

Post by RJV » Mon, 13. Mar 06, 09:53

Hmm... the commands should be there in any game where you have activated the script editor.

I will investigate.

In the meantime, anyone else having this problem?

EDIT - OK, I know what it is. I think I've seen this mentioned before actually. If you save the game once, then reload it, all should be fine.

I tested it doing the following -
New game
Activated Script Editor
Installed best buy and best sell
Checked Trade menu - nothing
Saved
Reloaded
Checked Trade menu - options were present.

Hope that works for you.

Cheers,

Rob.

User avatar
RJV
Posts: 2099
Joined: Mon, 29. Mar 04, 09:45
x3tc

Post by RJV » Thu, 16. Mar 06, 19:35

New version.

Should be no problems getting the thing to install now. Any issues, let me know.

Cheers,

Rob.

drsartan
Posts: 1
Joined: Sun, 23. Jan 05, 18:51
x3

Post by drsartan » Mon, 3. Apr 06, 01:52

I just installed the script and think it's a great idea. I have a question (possible bug?) however. Here's the example:

I'm in Empire's Edge with a ship full of Soja Beans. I go through the Best Sell part of the script with a jump radius of 5 and it tells me I can sell them in Preacher's Void for 38. It also says that I can sell them for 36 (or some lower price) in Empire's Edge as well. But the Best Sell Locator finds a Soyery right in Empire's Edge that is williing to pay 41 for them. I checked the Soyery directly, and sure enough, it will pay 41 each. Why doesn't the script catch this station? I'm both present in the sector (Empire's Edge) and have a navigation satellite there (station in range). I also tried starting the search in Duke's Domain with a radius of 5, but got the same results. Likewise if I'm not present in Empire's Edge.

I've also noticed this on the buying end as well, where it the script returns a best buying price that is higher than I can find with the Best Buys Locator (well within the search radius or even within the sector I'm in).

Any thoughts?

perraultpa
Posts: 26
Joined: Sat, 25. Dec 04, 05:10
x3

Post by perraultpa » Tue, 25. Apr 06, 01:10

I thought this script looked pretty cool since I like to do alot of trading. But I am running into an issue with the report. Here is what I got:
Advanced Nav Sats in Argon Prime, Home of Light, Herron's Nebula and Power circle.

I am currently in Home of Light.

I run the Buy command (It does say RedStar before it) to get a report on Silicon Wafers, Radius 5 and I used HoL, AP, and Power Circle as the start point. All three times I get a message that says none availiable. Or something to that effect. When I tried running it for energy cells same issue except when I was in "The Wall" So it seems to only be checking the system I am in and none of the others.

Thanks and great script except for the above issue.

Well I have been playing around with this one some more and I think my problem may be a lack of understanding with the logic. Will it only find a sutiable station to buy a ware from if the price less then the average price?

Also I had an idea that seems go along with your script very nicely. A price alert monitor. Basicly a script that checks the price of wares in sectors where you have a Adv Nav Sat aginst a list of wares you create for a price you choose and checks for the criteria being met every minute (for example, that may be too often) and when it is met sends you a message automatically and is formatted just like your buy/sell report. Also might want to charge for this service. Like 10-100 credits for every game hour.

User avatar
RJV
Posts: 2099
Joined: Mon, 29. Mar 04, 09:45
x3tc

Post by RJV » Fri, 19. May 06, 10:58

Hi,

Apologies for not replying to this sooner... :oops:

The trade software searches for a 'favourable' price. Off the top of my head I'm not sure what the figure was, but I think it looks for prices in the 20% range, that is buying goods if they are priced at anything up to 20% above minimum, and selling if they are priced at anything down to 20% below max (where the % figure is calculated off the difference between min and max)

The limits I set were fairly arbitrary but should provide a balance between getting some options and making it too easy. (note - this value can be changed in the script if you like, you just need to look for where there is a value divided by 5, you'd change this to 4 if you wanted 25% for example. All changes unsupported and at own risk :D ).

Cheers,

Rob.

User avatar
RJV
Posts: 2099
Joined: Mon, 29. Mar 04, 09:45
x3tc

Post by RJV » Fri, 19. May 06, 11:13

Also on the other question asked above - the script searches for a selection of up to 5 stations where the buying/selling criteria is fulfilled. Not necessarily the best 5...

This was deliberate by the way in an attempt to try and spread the trade around and allow the AI free traders to sell their stuff while still giving the player the chance of making a killing.

Cheers,

Rob.

Barleyman
Posts: 127
Joined: Sun, 16. Apr 06, 00:52
x3

Post by Barleyman » Tue, 6. Jun 06, 13:10

Tried your script yesterday and immediately made tasty profits on Paranid Soya Husks.

I noticed one anomaly. The script will find and even give rough directions to stations you do not know about. In 1.4 GOD engine apparently continuously pulls down factories and creates new ones..

I located 2 new factories in as many trading runs! When you add to the equation that brand-new factories are usually empty and will pay bucketloads for all goods..

Perhaps there should be a fee to using this to compensate for this behavior? maybe 1000cr/sector scanned?

User avatar
RJV
Posts: 2099
Joined: Mon, 29. Mar 04, 09:45
x3tc

Post by RJV » Fri, 16. Jun 06, 22:05

Barleyman wrote:Tried your script yesterday and immediately made tasty profits on Paranid Soya Husks.

I noticed one anomaly. The script will find and even give rough directions to stations you do not know about. In 1.4 GOD engine apparently continuously pulls down factories and creates new ones..

I located 2 new factories in as many trading runs! When you add to the equation that brand-new factories are usually empty and will pay bucketloads for all goods..

Perhaps there should be a fee to using this to compensate for this behavior? maybe 1000cr/sector scanned?
Yes that's right, it does. I was going to build in a 'show only if known by player' function to this, but I balanced it with the argument that it's not really practical for players to continually scan for new stations (or set tons and tons of satellites to ensure full coverage). I didn't want to charge a fee because the sector info comes from (or at least is driven by) player-owned property.

Consider it a little bonus :D

Cheers,

Rob.

Post Reply

Return to “X³: Reunion - Scripts and Modding”