X2 Stats [NEWS UPDATE - 04 MAR 2005]

The place to discuss scripting and game modifications for X²: The Threat.

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

User avatar
Logaan
Posts: 2146
Joined: Sat, 8. May 04, 22:52
x4

X2 Stats [NEWS UPDATE - 04 MAR 2005]

Post by Logaan » Sat, 13. Nov 04, 17:26

X2 Stats is here!

The new site now has facilities to handle tech support and has all the tutorials you need
Last edited by Logaan on Fri, 4. Mar 05, 19:48, edited 23 times in total.

User avatar
XU Vagabond
Posts: 800
Joined: Fri, 6. Feb 04, 21:22
x3tc

Post by XU Vagabond » Sat, 13. Nov 04, 17:33

looks good logaan it will be alot easier used than update you're sig all the time.

User avatar
bladeuk
Posts: 2063
Joined: Sat, 8. May 04, 18:26
x3tc

Post by bladeuk » Sun, 14. Nov 04, 05:07

Ive already said how good a job hes done, but id like everyone else to know what i think of this, its excellent, its worked out profits for all my stations, how much my companies worth ( 4,296,956,849 ) and everything i need to know about my company.

Brillaint job, keep it up!

User avatar
Logaan
Posts: 2146
Joined: Sat, 8. May 04, 22:52
x4

Post by Logaan » Thu, 18. Nov 04, 22:54

Some players found some issues which I hope the latest changes would sort out.

Im currently working on a Ranks Sig Image at the moment, using the real rank images from the game ( http://logaans-site.co.uk/x2/gamestats/ranks/ranks.html )


So keep those bug reports and suggestions coming :)

User avatar
XU Vagabond
Posts: 800
Joined: Fri, 6. Feb 04, 21:22
x3tc

Post by XU Vagabond » Thu, 18. Nov 04, 23:11

logaan i have noticed that the script dose not see ships sitting in stations e.g. you buy a TS then leave it in the station. Then save you're stats that ship dose not show up in the log. untill it's out in space

User avatar
Logaan
Posts: 2146
Joined: Sat, 8. May 04, 22:52
x4

Post by Logaan » Fri, 19. Nov 04, 01:38

It should do,

Code: Select all

079   * Get List of Ships From Station
080       $ShipList = $CurrentSt -> get ship array from sector/ship/station
That should get all the stations from that Object, which is Current Station.

I did have problems earlier where it would miss ships because they would be in the station when my script checked the sector, then go outside on a job, just as my script would check inside.

Which is why the first line sets the Priority high so it gets priority during its run and shouldnt be interupted. I know its not the most effcient method but its all i can do at the moment

Since this is my first script I dont know what else i can do

User avatar
LV
Sith Lord
Posts: 8255
Joined: Wed, 6. Nov 02, 20:31
x3tc

Post by LV » Fri, 19. Nov 04, 09:36

Code: Select all

$landedcheck = $station -> find ship: class or type=Boron Dolphin race=Pirates flags=$anull refobj=$anull maxnum=$anull  with homebase=$station
use the bottom find ship command and choose the station it will search on instead of the one near the top of the general commands list
LV's TC Scripts
Readme's For All My Scripts


I felt a great disturbance in the forum, Like millions of voices cried out in terror, then were silenced

si tacuisses, philosophus mansisses

User avatar
Logaan
Posts: 2146
Joined: Sat, 8. May 04, 22:52
x4

Post by Logaan » Fri, 19. Nov 04, 12:46

But id have to do that for each dockable class, and then again when it comes to searching the ships docked in other ships

Flector
Posts: 544
Joined: Sat, 6. Dec 03, 14:43
x4

Post by Flector » Tue, 23. Nov 04, 22:33

Logaan, I have some good news and some bad news.

The bad news is that your script doesn't return all ships! I tested it and it returned 429 ships, though it should have returned 578 ships.

The good news is that I have been working on a statistics script myself :o, and I am willing to help you.
My script is by no means finished but it does correctly return all ships :D.

What I basically do is loop through all sectors. For every sector I will search for all flying player owned ships. For every sector I will also search for every station. Then I loop through all stations and find all player owned docked ships. For all the ships I have found at that point I will also check if they carry any ships themselves.
X2: Advanced Magnate, Ace of Aces 1st grade ~ X3R: Master Economist, Crusader
X3TC: Magnate, X-TREME ~ X4F: Salesman, Harmless

User avatar
Logaan
Posts: 2146
Joined: Sat, 8. May 04, 22:52
x4

Post by Logaan » Wed, 24. Nov 04, 00:00

Brilliant :D

That was the same logic to my script but it doesnt work properly, TBH I havnt had time to look at it and sort it out recently.

Would it be in a similar output format to the script I wrote?

EDIT: Just realised i didnt put an example of the script in:
The Script
The Text File

Flector
Posts: 544
Joined: Sat, 6. Dec 03, 14:43
x4

Post by Flector » Wed, 24. Nov 04, 14:12

At first glance both the source and outputs of our scripts appear to be quite different.

Here's what I propose: since I really like your idea of using a script to automatically generate signatures and generate all different kind of stats and rankings on your webpage, I will offer to take a look at the source of your script and try to correct it. Off course, only if you allow me to :wink: ....
X2: Advanced Magnate, Ace of Aces 1st grade ~ X3R: Master Economist, Crusader
X3TC: Magnate, X-TREME ~ X4F: Salesman, Harmless

User avatar
Logaan
Posts: 2146
Joined: Sat, 8. May 04, 22:52
x4

Post by Logaan » Wed, 24. Nov 04, 14:17

Sure, go ahead, anything that will improve the service, and you are welcome to an account on the stats site (if you dont already have one)

cynric
Posts: 354
Joined: Mon, 15. Dec 03, 02:24
x2

Post by cynric » Wed, 24. Nov 04, 14:42

It looks like only khaak ships are missing, the script found only one khaak scout, but I have a few fighters + more than one scout at the moment.

Looks great otherwise :)

GaddyG
Posts: 718
Joined: Thu, 19. Feb 04, 18:06
x3tc

Post by GaddyG » Wed, 24. Nov 04, 16:25

nice little script...
seems to be picking up everything i have except the ships in stations...
which has been mentioned...
It's The End Of The World As We Know It, And I Feel Fiiiiiiiine...

User avatar
Logaan
Posts: 2146
Joined: Sat, 8. May 04, 22:52
x4

Post by Logaan » Wed, 24. Nov 04, 17:45

There are odd bits and bobs that are still a bit buggy, but they can only be found through testing so thanks to all who are participating :)
cynric wrote:It looks like only khaak ships are missing, the script found only one khaak scout, but I have a few fighters + more than one scout at the moment.

Looks great otherwise :)

Slight problem that i know about is that if you dont have a the Khaak Ship specs then they will show as Unknowns or Other

User avatar
Logaan
Posts: 2146
Joined: Sat, 8. May 04, 22:52
x4

Post by Logaan » Wed, 24. Nov 04, 18:26

Doh! :shock: Dont worry all i found the bug in the script, it was so obvious, I found it by getting the script to change the name of the ships it found to - so those left were those in non player stations

I was only looking for player ships in Player Owned Stations, so ships that were bought and still in the Shipyards, or ships that were trading in other stations werent picked up

Ill fix it soon and get post back

EDIT: Ok the new version of the script is uploaded. Basically it now loops through the whole universe and all the stations. I dont think it adds that much time to the execution of the script.
Last edited by Logaan on Wed, 24. Nov 04, 18:54, edited 1 time in total.

Flector
Posts: 544
Joined: Sat, 6. Dec 03, 14:43
x4

Post by Flector » Wed, 24. Nov 04, 18:53

Exactly!

I just found the problem as well, and wanted to report it. I guess you just beat me to it.

Good luck fixing the bug!
X2: Advanced Magnate, Ace of Aces 1st grade ~ X3R: Master Economist, Crusader
X3TC: Magnate, X-TREME ~ X4F: Salesman, Harmless

User avatar
Logaan
Posts: 2146
Joined: Sat, 8. May 04, 22:52
x4

Post by Logaan » Wed, 24. Nov 04, 18:55

I just edited my last post :P, but yeah, i just fixed it :)
I wrote:Ok the new version of the script is uploaded. Basically it now loops through the whole universe and all the stations. I dont think it adds that much time to the execution of the script.
EDIT: And I spelt Caiman wrong in the Ship Table so none of your Caimans would show up , errm oops :oops:

Flector
Posts: 544
Joined: Sat, 6. Dec 03, 14:43
x4

Post by Flector » Wed, 24. Nov 04, 22:12

The fix seems to be a succes!

I have just tested your new version. I compared the totals per shiptype generated by the new version of your script and my own script, and they exactly matched :D. The fact that our scripts were independently developed and generate the exact same results must be a good sign!

I'd like to stress that the statistics scripts I am developing myself are not intended to compete with yours in any way. The scripts I develop are intended to be a help for controlling my empire.

When I get to factory statistics scripts (I don't have any yet), I might be able to check those parts of your script as well.
X2: Advanced Magnate, Ace of Aces 1st grade ~ X3R: Master Economist, Crusader
X3TC: Magnate, X-TREME ~ X4F: Salesman, Harmless

cynric
Posts: 354
Joined: Mon, 15. Dec 03, 02:24
x2

Post by cynric » Wed, 24. Nov 04, 22:58

Great, thx for the quick fix

You may want to update the zip file on your homepage too.

Post Reply

Return to “X²: The Threat - Scripts and Modding”