Runtime Error "9"

General discussion about Scenery Design. Questions about SBuilder for Flight Simulator FS2004.
Post Reply
gmoffatt
Posts: 5
Joined: Sat Oct 30, 2004 1:02 am

Runtime Error "9"

Post by gmoffatt » Sat Oct 30, 2004 1:02 am

Buenos dias!

I'm a brand new user of SBuilder, and for my first project, I'm trying to improve the landcover around my home. I've imported a Shapefile into the Polish Map format, and brought that into SBuilder. I've assigned textures to all of my classes. When I try to compile to BGL, I get "Runtime Error 9: Subscript out of range". Any ideas on what causes that?

Thanks!
Greg

User avatar
Luis Sa
Posts: 1736
Joined: Sun May 18, 2003 11:17 am
Location: Portugal
Contact:

Post by Luis Sa » Sat Oct 30, 2004 1:19 am

Bom dia Greg,

Could you please send me a ZIP file with the project (the SBP or the SBX file)?

luis@ptsim.com

Regards, Luis

gmoffatt
Posts: 5
Joined: Sat Oct 30, 2004 1:02 am

Post by gmoffatt » Sat Oct 30, 2004 1:46 am

Sent...

Thanks for the quick reply!

Greg

gmoffatt
Posts: 5
Joined: Sat Oct 30, 2004 1:02 am

Post by gmoffatt » Sat Oct 30, 2004 12:23 pm

To summarize:

I have a project that's pretty large, using VTP polygons instead of landclass to portray landcover and preserve some distinctive-looking forest patches, etc.

Following Luis' advice, I upgraded to v. 2.03, which uses long integers rather than short integers to store data. This solved the runtime error. And, in fact, it only took about 10 minutes to compile and resulted in a 1.3 MB BGL.

There are some crazy artifacts in the final result in FS, though -- polygon boundaries stretching down to a single point -- but that might be because of messy input data. I don't know.

Anyways, I'm going to try to lay down some landclass for urban and agriculture and then lay VTP forest polygons on top of that to see how it looks. The hard boundaries of the VTP polygons might be ugly but who knows... worth a try.

Anyways, just thought I'd add this to the topic in case somebody else is having the runtime problem.

Thanks again,
Greg

User avatar
Luis Sa
Posts: 1736
Joined: Sun May 18, 2003 11:17 am
Location: Portugal
Contact:

Post by Luis Sa » Sat Oct 30, 2004 8:07 pm

Greg,

About the crazy artifacts on VTP polys, it is worthing to learn the "incapacities" of SBuilder. I received many comments regarding LWM polygons and could correct many errors. But VTP polygons are not common so I did not spend many time running for the errors.

1) In a New project press F8 to see the Cell Boundaries. Go to Poly mode and enter a convex polygon with the mouse. The polygon should be enclosed in a single Cell. Give the poly the type of VTP (any type for the experiment to be fast). Compile (no copy of BGL files) and delete the polygon. Append the generated VTP BGL from the /tools/work/ folder. Is it equal to your original.

2) Repeat with a convex polygon that spans 2 Cells

3) Repeat with concave polygons

4) Repeat with very strange polygons

Regards, Luis

gmoffatt
Posts: 5
Joined: Sat Oct 30, 2004 1:02 am

Post by gmoffatt » Sat Oct 30, 2004 9:56 pm

Okay Luis, that was very illuminating and an excellent idea. It's always good to have an idea of the basic principles before one goes ahead with more complexity.

Thanks again,
G

Andrew
Posts: 17
Joined: Thu Jan 06, 2005 3:13 am
Contact:

Post by Andrew » Thu Jan 06, 2005 3:25 am

Luis, thanks for the info.

I am new at this, and started with a 1,3MB roads (VTP) file which I appended with Sbuilder 2.02. But when I tried to compile a BGL file, I got Runtime error 9. Luckily I found the info here, downloaded the 2.03 exe, which converted my file to the new standard. Finally I was able to delete a few roads (where my Gmax bridges will be), and was able to make a fully functioning BGL file which showed up perfectly in FS9.

But there is a minor problem: The 2.03 exe will not append a VTP BGL, it crashes. So I just brought back the 2.02 exe, appended my BGL file, then quit Sbuilder and changed to the 2.03 exe which lets me finish my work. [:D]

Oh bytheway...is it possible to see an English version of the forum? I was able to register in Portugese anyway.

No matter problems, Muyto Obrigado for this fine software!

Andrew

User avatar
Luis Sa
Posts: 1736
Joined: Sun May 18, 2003 11:17 am
Location: Portugal
Contact:

Post by Luis Sa » Thu Jan 06, 2005 5:21 am

Andrew,

The simpler problem first - since you are registered you can switch back to Portuguese and back to English languages at any time. Look to the top right corner of this page.

Now for the VTP appending crashes. It is very strange. Did you get the file sbxxx.zip from the PTSIM download folder? I lost the counting of the updates! Every week I add funcionalities but I need to stop in order to update the Help file. In any case I was convinced that the present sbxxx.zip was OK. Does the crash happens with any VTP or just with a particular one?

Thanks for using SBuilder,

Luis

Andrew
Posts: 17
Joined: Thu Jan 06, 2005 3:13 am
Contact:

Post by Andrew » Thu Jan 06, 2005 6:27 am

Luis,

Yes first things first: I see the messages fine in English, but the menu items and login stuff is still in Portugese. No problem...let me just find my old Portugese/English dictionary. [:)]

Regarding Sbuilder. Fist thing I did was just to download version 2.02 full. The I downloaded the Sbxxx.zip, which just included the ver. 2.03 exe. My "roads1" project were present from before (2.02), and was converted when I opened Sbuilder with the 2.03 exe. When trying to append a new VTP file (new project with ver 2.03 exe), Sbuilder crashed every time I tried.

Andrew

User avatar
Luis Sa
Posts: 1736
Joined: Sun May 18, 2003 11:17 am
Location: Portugal
Contact:

Post by Luis Sa » Thu Jan 06, 2005 9:05 am

Andrew,

First problem - the forum should look like:

Image

If it does not, I really do not know what is hapenning!

About Sbuilder I just uploaded the one I have in my disk. Please read the bottom of the page of the topic UPDATE. And make backups of your work just in case ...

Regards, Luis

Andrew
Posts: 17
Joined: Thu Jan 06, 2005 3:13 am
Contact:

Post by Andrew » Sat Jan 08, 2005 2:14 am

Luis,

Looks like the Firefox browser is my problem, it reverts back to Portugese when I select English. I can live with that!

I am still not able to open some files in SBuilder with the 2.04 exe. A 0.5MB VTP railroads BGL opens fine, but takes a long time to show up. If I try to open 1.3MB files, SBuilder freezes without any messages, and I get "program not responding" from Windows and have to end SBuilder. With the 2.03 exe everything opens fine, but a 2.5MB file crashed it.

Should there be a new ini file included with the 2.04 exe? The zip contains just the exe file.

User avatar
Luis Sa
Posts: 1736
Joined: Sun May 18, 2003 11:17 am
Location: Portugal
Contact:

Post by Luis Sa » Sat Jan 08, 2005 2:46 am

Hi,

If you get a BGL that does not open, please zip it and send to me. I will try to see what is the problem.

In the last update it is mandatory that you replace the objects.txt file or SBuilder will not start! If you want to use the Rwy12 objects just open the INI and add a line with a text editor. Save again and see if SBuilder finds Rwy12.

Regards, Luis

Andrew
Posts: 17
Joined: Thu Jan 06, 2005 3:13 am
Contact:

Post by Andrew » Mon Feb 14, 2005 4:32 am

I understand its mandatory the objects.txt should be replaced...but when I downloaded the 2.04 exe, there was no objects.txt included. I have added the Rwy12 stuff to the ini file, but I`m not using Rwy12 with SBuilder.

I still got the same problem. I can append a roads VTP file with the 2.03 exe but not with 2.04, and are able to make a BGL only with 2.04.

1.3MB files appends fine with 2.03, but bigger files (1,5 - 1,7MB just freezes SBuilder. Unforunately I can`t send you any files...they are payware. I have tried with other VTP roads files...same problem. Only thing I can tell is my files uses Layers 9, 14 and 15 for roads.

User avatar
Luis Sa
Posts: 1736
Joined: Sun May 18, 2003 11:17 am
Location: Portugal
Contact:

Post by Luis Sa » Tue Feb 15, 2005 3:28 am

Andrew,

I really can not help! I can append default VTP without problems and also the ones created by me. If you have a "bad" file that you can send I will try to see the error and then I destroy it.

Regards, Luis

Andrew
Posts: 17
Joined: Thu Jan 06, 2005 3:13 am
Contact:

Post by Andrew » Tue Feb 15, 2005 6:48 am

Luis,

Yeah I know, it`s driving me crazy too [:)]

Default or custom files, that might be the problem. I have only used SBuilder with custom files - never tried default.
I will se if I can get a file for you to try, and also try to open a huge default file myself.

BTW now the sbxxx.zip includes a objects.txt file. Thanks!

Post Reply