Home » Stars! Clones, Extensions, Modding » Stars! Extensions » "message pane" scraper
Re: "message pane" scraper |
Wed, 07 August 2013 11:46 |
|
m.a@stars | | Commander | Messages: 2765
Registered: October 2004 Location: Third star to the left | |
|
XyliGUN wrote on Wed, 07 August 2013 12:25Seems like you mean UTF8 header bytes?
Ahh, I should have guessed. Still, Stars! doesn't use them, and my Excel doesn't seem to know what they are for, either.
Quote:It's temporary here just for the debugging purposes and to make it easy to understand what does all these numbers means. But for an automation purposes EventId column should be used.
Makes sense.
Quote:Currently I always make it 0, but in fact there is a two byte "shortcut" used by goto button and it can reference planet, fleet, technology browser, etc. I'm not sure if it have any usage for automation purposes, but in any case I have to sort it out before dumping into the file.
I'd vote to export it with everything else. Does no harm, and could be useful.
m.a@starsWell, yes and no. Format is the same, but in fact several event params actually use two value args, this is why I currently put them in one Arg, separated by "|" symbol. I'm still thinking on how to correctly dump these ones.
Weird. Looks like they should be in the same csv format as the rest, unless there's a better way.
Quote:m.a@starsPerhaps you'll like to test against much bigger (and complex) m-files? I should have a handful fat ones still around.
Absolutely, just need to make sure it works on all of my games collection.
Sweet. Let me know if you need more!
So many Stars, so few Missiles!
In space no one can hear you scheme! Report message to a moderator
|
|
| | | |
Re: "message pane" scraper |
Wed, 07 August 2013 12:26 |
|
XyliGUN | | | Messages: 325
Registered: July 2004 Location: Russia, St.Petersburg |
|
|
XyliGUNXAPBobThe hidden info I'd be concerned about is the MT sales pamphlet.
Wormhole info includes: what are the target wormhole, who seen it, and who been through.
Trader info includes: carrying item, and who already met him.
Thanks to the m files received, it's now verified, there IS a "hidden" info described above.
But imho, the only info really giving an advantage is knowledge on what trader carrying, others are mostly useless.
"Progress isn't made by early risers. It's made by lazy men trying to find easier ways to do something."
Robert A. Heinlein, Time Enough For LoveReport message to a moderator
|
|
|
Re: "message pane" scraper |
Wed, 07 August 2013 12:34 |
|
m.a@stars | | Commander | Messages: 2765
Registered: October 2004 Location: Third star to the left | |
|
XyliGUN wrote on Wed, 07 August 2013 16:05\n - location, can be in form of either planet id, fleet id or space coordinates
planet is stored in form P|PlanetId
fleet is stored in form F|OwnerId|FleetId
space coordinates is stored in form C|x|y
Is that format your way to make things easier for toolmakers, or are there other reasons?
Because I don't think it's really needed, as most messages need to be specifically coded for, anyway.
Quote:\X - strange, but \X is always replaced by empty string in any event message, will be stored as empty Arg in export
Looks like a leftover from earlier versions. Is that param always empty in the m-file?
What about the \s param? Seems many messages use it as fleet/ship Id, or perhaps a fleet name.
[Updated on: Wed, 07 August 2013 12:35]
So many Stars, so few Missiles!
In space no one can hear you scheme! Report message to a moderator
|
|
|
Re: "message pane" scraper |
Wed, 07 August 2013 12:49 |
|
m.a@stars | | Commander | Messages: 2765
Registered: October 2004 Location: Third star to the left | |
|
XyliGUN wrote on Wed, 07 August 2013 18:26XyliGUNWormhole info includes: what are the target wormhole, who seen it, and who been through.
Trader info includes: carrying item, and who already met him.
Thanks to the m files received, it's now verified, there IS a "hidden" info described above.
But imho, the only info really giving an advantage is knowledge on what trader carrying, others are mostly useless.
I wouldn't call it entirely useless. Who met a Trader tells you what to expect from their ships and/or tech, and even about their minerals and freightering capabilities.
Wormhole target coordinates are priceless for all those who haven't explored it yet, or even for those who want to launch a surprise attack thru it. "Who saw it" would tell you about their scouts and scanners (and hence tech, econ, and colonies), perhaps even their readiness against attacks. And almost the same can be gleaned from knowing who has already been thru it.
So many Stars, so few Missiles!
In space no one can hear you scheme! Report message to a moderator
|
|
| | | | |
Re: "message pane" scraper |
Wed, 07 August 2013 17:00 |
|
m.a@stars | | Commander | Messages: 2765
Registered: October 2004 Location: Third star to the left | |
|
XyliGUN wrote on Wed, 07 August 2013 21:16Just wondering what ambiguities do you mean?
The way Stars! converts "clicks" to "grav" hab values isn't sloped enough for low gravities, so for the lowest dozen "grav" values it isn't easy to tell what their origin "click" value is. They are: 0.12, 0.12, 0.13, 0.13, 0.14, 0.14, 0.15, 0.15, 0.16, 0.17, 0.17
So many Stars, so few Missiles!
In space no one can hear you scheme! Report message to a moderator
|
|
| |
Re: "message pane" scraper |
Thu, 08 August 2013 04:15 |
|
XAPBob | | Lt. Commander | Messages: 957
Registered: August 2012 | |
|
The clicks to grav is discussed at length http://starsautohost.org/sahforum2/index.php?t=msg&th=22 99&prevloaded=1&rid=1560&start=0
Leave it as an exercise for secondary tools (it's easy enough to do as either a calculation or a lookup table). However CLICKS are unique - values are not necessarily (low grave has ?10 repeated values) so it's actually MUCH better to get clicks.
- Some of the fleet items seem to imply that the fleet ID isn't unique - I presume it is, and that the "ship type" is actually just "extra" information.
- \v and \V are values, but what are \g and \G?
I'm actually going to go back to one of my earlier questions as well....
The fleet report is a bit weak in terms of telling you exactly what is in each fleet - I presume the information is available to have a count of each ship design ID (and associated name?) and percentage damage to each type, for each fleet ID (e.g. 32 integers per fleet ID)?
That, combined with the "normal" f report would actually provide a good view of what ships are where.
Additionally if the Clicks valuue for planets can be exported then that would allow for accurate tools (without having to guess at values)
These are probably extra tools (certainly other files) - but seem relevant here at the moment.
The below information is looking really useful though. I can certainly see this being useful to generate a complete list of "useful information" from an m file at the start of a turn.
[Updated on: Thu, 08 August 2013 04:22] Report message to a moderator
|
|
|
Re: "message pane" scraper |
Thu, 08 August 2013 05:28 |
|
XyliGUN | | | Messages: 325
Registered: July 2004 Location: Russia, St.Petersburg |
|
|
m.a@starsXyliGUNCan you share m + xy files with this event, so I can verify?
Sorry, it's been too long since I last made one of these mistakes, but it should be easy to testbed.
OK, here is an updated list of the event param formats:
- \e - environment area (note: 0 - gravity, 1 - temperature, 2 - radiation)
- \E - environment area value (seems to be in clicks from the left?)
- \F - ship id (the same as fleet id)
- \g or \G - currently exported as an integer value, but it wasn't found in any of the m files
- \i - signed integer value
- \I - change type (0 = decreased, 1 = increased)
- \j - zero based research area id (0 - energy, 1 - weapons, 2 - propulsion, 3 - construction, 4 - electronics, 5 - biotechnology)
- \k - technology id (4 bytes unsigned integer), stored in format: bits 0-15 is an ItemId, bits 16-31 is a GroupId
- \l, \L or \Z - zero based player id
- \m - cargo type (note: 0 - ironium, 1 - boranium, 2 - germanium, 3 - colonists, 4 - fuel)
- \M - mine field type (0 - standard, 1 = heavy, 2 - speed bump)
- \n - this param consumed 2 args, it specifies location (can be either planet id, fleet id or space coordinates)
- \o or \s - zero based fleet id
- \O - zero based owner id (the same as player id)
- \p - zero based planet id (note: you have to add 1 to match a planet id as it shown in Stars!)
- \P - percent value
- \S - packet origin (the same as player id)
- \v - 4 bytes unsigned integer value (note: some events treat it "as is", some add '00'/'kT'/'mg')
- \V - 4 bytes unsigned integer value, but comparing to \v it always used as is, since it is already multiplied by 100
- \X - strange, but \X is always replaced by empty string in any event message, will be stored as empty Arg in export
- \z - design id (bits 0-4 - design id, bit 5 values: 0 - ship design, 1 - starbase design)
Hope this makes sense.
[Updated on: Thu, 08 August 2013 05:30]
"Progress isn't made by early risers. It's made by lazy men trying to find easier ways to do something."
Robert A. Heinlein, Time Enough For LoveReport message to a moderator
|
|
|
Re: "message pane" scraper |
Thu, 08 August 2013 06:14 |
|
XyliGUN | | | Messages: 325
Registered: July 2004 Location: Russia, St.Petersburg |
|
|
XAPBobThe clicks to grav is discussed at length http://starsautohost.org/sahforum2/index.php?t=msg&th=22 99&prevloaded=1&rid=1560&start=0
Cool! Thanks for pointing me.
XAPBobLeave it as an exercise for secondary tools (it's easy enough to do as either a calculation or a lookup table). However CLICKS are unique - values are not necessarily (low grave has ?10 repeated values) so it's actually MUCH better to get clicks.
Deal!
XAPBob- Some of the fleet items seem to imply that the fleet ID isn't unique - I presume it is, and that the "ship type" is actually just "extra" information.
Yes, exactly, this just a sort of an additional info for the formatting.
XAPBob- \v and \V are values, but what are \g and \G?
There is only one event with the param \g and another one with \G:
\s attempted to execute transfer orders with \g involving either fuel or colonists. The attempt failed.
\s had orders to transfer cargo to or from a \G. A futile pursuit.
If someone can simulate а game with these events and send me an m + xy files, then I can say exactly what is this.
XAPBobI'm actually going to go back to one of my earlier questions as well....
The fleet report is a bit weak in terms of telling you exactly what is in each fleet - I presume the information is available to have a count of each ship design ID (and associated name?) and percentage damage to each type, for each fleet ID (e.g. 32 integers per fleet ID)?
Yes, there is a count and damage per design id in fleet inside fleet block.
XAPBobThat, combined with the "normal" f report would actually provide a good view of what ships are where.
Additionally if the Clicks valuue for planets can be exported then that would allow for accurate tools (without having to guess at values)
Well, I hate to promise ahead..., but this is what on my to do list:
- export players (player id, logo id, singular and plural names)
- export planets (planet id, original/current environment, minerals concentration and available amount, starbase design id and damage, rout to target)
- export designs (including design name, hull, items on board)
- export fleets (several lines per fleet for each design id)
- export events
So far I have all of these info extracted, just need to carefully drop it to CSV.
I thinking of the one command line for all of this, just with the different switches like: /export players, /export planets, /export designs, /export fleets, /export events.
XAPBobThese are probably extra tools (certainly other files) - but seem relevant here at the moment.
The below information is looking really useful though. I can certainly see this being useful to generate a complete list of "useful information" from an m file at the start of a turn.
XAPBob, just wondering, what kind of tool(s) are you going to do first once you have all of this info exported?
"Progress isn't made by early risers. It's made by lazy men trying to find easier ways to do something."
Robert A. Heinlein, Time Enough For LoveReport message to a moderator
|
|
| |
Re: "message pane" scraper |
Thu, 08 August 2013 09:56 |
|
m.a@stars | | Commander | Messages: 2765
Registered: October 2004 Location: Third star to the left | |
|
XyliGUN wrote on Thu, 08 August 2013 12:14There is only one event with the param \g and another one with \G:
\s attempted to execute transfer orders with \g involving either fuel or colonists. The attempt failed.
I don't quite recall this one, but could be an error message for trying to "transfer" colonists to an uninhabited planet. The very next msg (#285) mentions planets and is suspiciously similar.
Quote:\s had orders to transfer cargo to or from a \G. A futile pursuit.
The "futile pursuit" is most definitely related to Wormholes.
Quote:If someone can simulate а game with these events and send me an m + xy files, then I can say exactly what is this.
It's not exactly easy to get a wormhole when and where you need it.
Quote:Yes, there is a count and damage per design id in fleet inside fleet block.
Interesting!
Quote:export players (player id, logo id, singular and plural names)
That'll be needed for the tools that want to render messages with race names in them.
Quote:export planets (planet id, original/current environment, minerals concentration and available amount, starbase design id and damage, rout to target)
... and Packeting Destination, too, pls?
A very interesting additional export (for future releases, perhaps) would be the details of the Production Queues.
Quote:export designs (including design name, hull, items on board)
Oh, yessss!
That, coupled with some future tool to import designs, would enable a bunch of *very* interesting things.
Quote:So far I have all of these info extracted, just need to carefully drop it to CSV.
I'm guessing that will include:
* details about foreign fleets
* battle debris
* packets
* minefields
* MT position / speed
?
I'm sure if you show us what the exported info looks like now, you'd be able to collect many useful suggestions!
Quote:I thinking of the one command line for all of this, just with the different switches like: /export players, /export planets, /export designs, /export fleets, /export events.
Well, since it's already an "exporter" tool, why not keep it simple imitating Stars! own style? i.e: "exporter [filename] -rpdfea" (where "r" stands for "races" and "a" would mean "all")
Quote:just wondering, what kind of tool(s) are you going to do first once you have all of this info exported?
* "routes" checker/tweaker
* "packeting" checker/tweaker
* "fuel" checker/tweaker (better if all waypoints known, not just the next)
* "danger" analyzer
* external shipdesign organizer/tweaker/library
* prod Qs checker/tweaker
* pop & mins "optimizer"?
[Updated on: Thu, 08 August 2013 09:59]
So many Stars, so few Missiles!
In space no one can hear you scheme! Report message to a moderator
|
|
|
Re: "message pane" scraper |
Thu, 08 August 2013 13:55 |
|
XyliGUN | | | Messages: 325
Registered: July 2004 Location: Russia, St.Petersburg |
|
|
m.a@starsXyliGUNSeems like you mean UTF8 header bytes?
Ahh, I should have guessed. Still, Stars! doesn't use them, and my Excel doesn't seem to know what they are for, either.
Hmmm... How do you open it?
Could you try just locate CSV in explorer, then right click on CSV file -> "Open with..." -> Excel.
Or, if you have an association of CSV with Excel, then just double click on CSV.
Both should work well with any text file with UTF8 header. If it works for you?
"Progress isn't made by early risers. It's made by lazy men trying to find easier ways to do something."
Robert A. Heinlein, Time Enough For LoveReport message to a moderator
|
|
| | |
Re: "message pane" scraper |
Thu, 08 August 2013 14:16 |
|
m.a@stars | | Commander | Messages: 2765
Registered: October 2004 Location: Third star to the left | |
|
XyliGUN wrote on Thu, 08 August 2013 20:08Oups, looks like I have to make it clear: there is no target coordinates.
There is just a target wormhole id, which is useless, since there are no wormhole with that id in m file if you cannot see it.
Ahhh, so less useful than I guessed, but still, once everybody gets to see the IDs of the WHs they know, they'll become just another piece of intel for trade. A valuable piece of intel that doesn't exist today.
Yay, innovation!
[Updated on: Thu, 08 August 2013 14:17]
So many Stars, so few Missiles!
In space no one can hear you scheme! Report message to a moderator
|
|
| | | |
Goto Forum:
Current Time: Fri Apr 26 10:02:21 EDT 2024
|