Editor Problem

Stop by here for help with RRT3 Editor problems and tips.
User avatar
BobTheBull
Hobo
Posts: 26
Joined: Wed Feb 17, 2010 5:06 pm

Editor Problem Unread post

I have been working on a mod of the Germany map, changing the goals from freight speed to freight hauled, among other things. In order to do this I have a lot of events to set up to track YTD & LTD freight for each RR, give bonuses for meeting certain goals, etc. I think this is much more realistic of the overall scenario as Germany at that time was interested in developing their railroads to support German industry; they could have cared about average train speed, they were interested in maximum hauling rates to get raw materials to industry and finished products to market. There was also emphasis in the German military as well.

At any rate, I had just finished setting up a lot of complicated events and was starting to test them when I discovered all the industry weightings in the Cities/Regions screen had been reset to 0, even though I had not gone into that screen during the editing session. I have seen this happed before, but it was more of an annoyance. Now, it has ruined several hours of work. Either I have to start all over and hope it doesn't happen again, or maybe use a hex editor to copy and paste the data from the previous map into the latest one. I think I have found the place for the data in the gmp file, but when I try to do that it won't work. During Loading Label Database I get an error: Pack element <marker 01> not found.

So, a) can anyone tell me how to copy that data successfully, and b) how to keep the weightings from getting reset to 0 again?
User avatar
OilCan
Engineer
Posts: 832
Joined: Tue Jan 13, 2009 2:03 pm
Location: East Tennessee, USA

Re: Editor Problem Unread post

No good answer for you...but wanted you to know someone read your post.

I don't know a thing about pasting data into the .gmp file. It is probably a good thing that I don't.

I have not had the industry weightings reset themselves to zero, but I have had the players list and the industry list reset themselves. It seems to occur when I drag the cursor across the page **!!!**. One more buggy thing to watch for....
User avatar
nedfumpkin
CEO
Posts: 2163
Joined: Sat Feb 16, 2008 9:16 pm
Location: Hamilton - Canada

Re: Editor Problem Unread post

I've looked at the gmp file with a hed editor, but I haven't so far been able to figure out where things are, or how to change them.

Oddly, I'd be interest in knowing how to reset the cities and regions all to 0 for when starting a map and not have to go into each city to do it.

Like Oilcan, I've had the overall industry uncheck everything, and a few others have had the same thing, but this seems to be from clicking somewhere in the screen which has the same effect as clicking clear all. This seems to be a 1.06 issue that was carried over to TM. So are you using 1.06 or 1.05?
User avatar
edbangor
Dispatcher
Posts: 311
Joined: Wed Sep 09, 2009 10:24 am
Location: Berks, England
Contact:

Re: Editor Problem Unread post

As the other said, the Industries getting re-set to 0 if you happen to click on the screen anywhere but an actual button is a bug in the editor and can be VERY annoying which is why I mentioned it a lot in my "converting maps from RT3 to TM" guide.

However, if it is just that screen that has changed then all your events will still be valid once the industries you need (or all of them if you want those that aren't set to spawn in cities / regions won't appear anyway) then everything will still work. There's no need to change the individual cities / regions weightings as once things are turned back on again in INDUSTRY OVERALL, your previous weighting settings will reappear.

As for setting new cities to 0 I do that on every map before just working down the list in the editor and then balance them up again.
I need a little less pressure, and a little more time
"A Little More Homework" by Jason Robert Brown from 13: the Musical
User avatar
BobTheBull
Hobo
Posts: 26
Joined: Wed Feb 17, 2010 5:06 pm

Re: Editor Problem Unread post

Sorry to be so slow in responding. Thanks for the help, guys, even if it didn't help. Even though it actually did.

First, Edbangor is right, and that was the original problem. The industry weightings for cities/regions were not set to 0. The Overall Industry page had been set to none, that is no industries were checked. When the appropriate industries were checked all the weightings were still there as they were. I know this because I had changed some of them and made notes on this and they were as I had changed them.

Second, editing the gmp file is doable if you can find the location of what you want to edit and know it's format, ie float, four byte hex, one byte hex, string, etc. While PJay and Milo do have some noes on this it is very sketchy. This is complicated by the fact that most of the sections are variable in length, so specific offsets are not usable, as they are in the bca files. Also, if the edited file is even one byte different in length from the original it will immediately ctd when loaded. In fact, it crashes so fast I am impressed! If you could find where in the header to find the file length/checksum info you could probably fix this, although it does not mean the edit would work.

I was able to locate the portion where the cities/regions are at least partly stored, but copying and pasting from that did not work. This is due in part to not knowing exactly where each section starts and ends but also because they will not be the same length unless they are identical, in which case you would not need to copy them.

I also identified the events block in the file. These are each fixed length at 2199 bytes and sections can be copied individually or in groups so long as you overwrite X number of sections with X number of copied sections. Copying the whole block will not work unless the two files have exactly the same number of events. However, the conditions are not stored in the event sections, but in their own block, and they are indexed by number starting with 1. This is presumably so there can be an unlimited number of conditions for each event; the condition sections do vary in length, according to how many and what they are. So copying new condition to old condition, or vice versa, will not work unless they are exactly the same length. ctd. I tried copying a condition from one file to another by making the copied section the same byte length as the target; this did not ctd, but did lock up at the point, "loading events database" in initialization. No surprise. We assume effects work the same way.

So, what have we learned class? The reset industries bug is the real culprit, but not that difficult to fix; just aggravating. Editing or copying and pasting with gmp files is theoretically possible but practically no doable. But I did learn a lot about the gmp file.
Post Reply