SUBSIM: The Web's #1 resource for all submarine & naval simulations since 1997 |
|
10-05-20, 09:27 PM | #1 |
Stowaway
Posts: n/a
Downloads:
Uploads:
|
SH4 Stopped Saving "SaveData.map" Data For Stellarium
Hello,
The title tells it all. I have no idea why, but it is impossible to use the "SHtoStellarium" script to copy my SH4 time and position to Stellarium. The below spoiler contains some extensive information which may help. Thank you in advance for the assistance. |
10-06-20, 06:48 AM | #2 |
CTD - it's not just a job
|
With some of the older SH tools, you had to have the utility in the Save folder for it to properly find and gather the needed data. I'm sure a custom script could point the app to the proper location, but is it using your script still?
|
10-06-20, 12:11 PM | #3 |
Silent Hunter
Join Date: Dec 2004
Location: AN9771
Posts: 4,892
Downloads: 300
Uploads: 0
|
For debugging purpose I would add statements (or let the debugger show the contents of variables) that show what "content[longst+4:longnd]" or just longst and longnd contain. Something in this expression does not allow it to become a float. I'm too unfamiliar with Python to know what that could be, just familiar enough in general with such languages that it always helps to check the intermediate conversion steps.
__________________
My site downloads: https://ricojansen.nl/downloads |
10-07-20, 12:42 AM | #4 |
Stowaway
Posts: n/a
Downloads:
Uploads:
|
@propbeanie - My laptop crashed several hours ago, so I am having to start from scratch. I was using the script and it produced as file, but since the correct numerical data was not produced the script threw errors because the data it did read was alphanumeric which the script could not digest.
@Pisces - That is a good idea. Thanks. The problem is not the script. It works well if I feed it valid data manually. The culprit is SH4 itself. The SaveData.map files is not being populated. The framework is there, but no data, like my position is saved. I will report back. |
10-07-20, 09:17 AM | #5 |
CTD - it's not just a job
|
I have a SaveData.map in some of my "more involved" saves, and this is all it has:
[Mark]Near as I can tell, there is no "CurrentLocation", or whatever the game would call it. It does record the Waypoint locations, beginning the numbering at "zero". I'm not certain if that is long, lat, heading, or what for the Waypoints. Now, some of the Saves I have that do not have Waypoints or marks, etc., the SaveData.map is not present. I wonder if the py script has error catching for if the file does not exist yet? Also, since SH4 saves a lot of its data in txt files, the numerical characters would be string. Python does have a type-cast, doesn't it? Such that you can do a "string-to-float"? |
10-07-20, 11:04 AM | #6 |
Silent Hunter
Join Date: Dec 2004
Location: AN9771
Posts: 4,892
Downloads: 300
Uploads: 0
|
In that case, place a waypoint and save. Pt0 should be the location of the sub at time of the save.
__________________
My site downloads: https://ricojansen.nl/downloads |
|
|