• It's not the position that matters, it's the adventure in getting there.
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.
  2. If you have any questions, please don't hesitate to ask. There's no such thing as a stupid question.

Huge BTB track into 3DSMax

Discussion in 'Bob's Track Builder' started by sevware, Apr 25, 2011.

  1. sevware


    Haven't been here for awhile.

    So I have gotten as far with Gimp, BTB, SimEd, and Xpacker as I can. I got Max2010 a year and a half ago, and getting pretty good at buildings, uv mapping (albeit with Gimp), and other track props.

    This week I got PS (and the nVidia plugins) installed, and got the export plugin, import script, and core shaders installed in MAX.

    The BTB built track, terrain, and AIW work really well in rFactor, but are limited due to xPacker's 2 frame animation limit, and all the other BTB limitations.

    So, my questions are:

    1. Since my track is 32 miles long (no, really), I have it devided into 24 track sections (with terrain on each side) in BTB. Do I bring the whole track into MAX, or bring it in by sections?

    2. Should I (or... can I) devide it further once in MAX so as to make the sections (GMTs ?) smaller (so that 4 lights are enough to light each section)?

    3. Is the unit you devide tracks into... separate GMTs?

    4. Can I use the AIW file that I generated in BTB (as I don't need to change the track shape or position in MAX)?

    5. Since the track goes through the (California) coast ranges to the beach and back, I built my own 16 panel horizon cylinder (actually a conical slice, so the sun hits it better) with a couple coasts, ocean, and mountains. Looks good in rF. Do you bring your skybox and horizon cylinder into MAX also... when you are track building in MAX?

    6. Where in MAX to you enable the use of the rFactor shaders for viewing while building?

    7. What type of light do you use in MAX to simulate what rF uses?

    8. In what BTB generated file(s) can I find the information to set up the lighting in MAX so that it is (as close as possible) to what my track's lighting is in rFactor? [color, color temperature, orientation in the "sky" etc..]

    9. Is it best to have the various houses, buildings, trees, signs etc... as part of each track section's gmt file (along with the track, terrain etc..), or do you make each object a separate gmt? [probably an extreme noob question..eh?].

    10. How much did I forget to ask?

    I've been thinking about writing a C# program that will automatically go through AIW, SCN, TDF, and GDB files to find and change all the parameters I usually end up having to manually enter (fuel usage, rotational trajectories for helicopters / aircraft, clip plane settings, max shadow range etc....)

    ...Unless something like this already exists.... (?)

    Thanks in advance for any help provided....
  2. Mikec87


    Hi. I can try to answer some of your questions.

    1: You should be able to import the whole track in one hit. It may take some time depending on your machine.
    2: You can divide in Max once improrted. Not sure what you mean by 4 lights?
    3: When you divide a track, Max will rename or you can name each .gmt as you want.
    4: Save the AIW file. Yes use it from BTB. rFactors own AIW maker is much much better.
    5: Save the sky box if it is good. Just import the track/terrain/objects/etc
    6: In Max you must use the ISI plug-ins or it will not work at all. See the rfactor web site in the deveopers area or search this forum.
    7: Umm, not sure you can at all. RFactor does the lighting in game.
    8: I do not think that is possible or nessesary. May be wrong :)
    9: All objects are usually seperate gmt files. Make the objects in Max, posiition in Max and when you export it makes it a gmt and places it correctly. You add can each object line by line in your SCN file. Or generate in Max.
    10: LOL! Lots probably.

    My first track, Lakeside Raceway made with BTB and Max took 700 hours of trial and error. There are lots of good people to help here. Making stuff from scratch is harder, but more rewarding when done.

    Mike :)
  3. Kyle Puttifer

    Kyle Puttifer
    @ Simberia @Simberia

    It's the ISI rule that says you can have a maximum of 4 lights per track GMT, otherwise it will screw up. If you want more than 4 lights on your track, you need to split it. :)
  4. sevware


    Hey Mike87,

    Thanks for your help. About bringing the track in to Max.... hopefully the extra cores & solid state drive will make that less painless (ie <8 hours). Not sure if MAX uses more than one core for anything but rendering though (like Autodesk Inventor). From what I read, there are even less random accesses once things are MAS'ed, and load in becomes quicker yet.

    On question 2 (dividing the track up for lighting reasons)... I read somewhere on the old RSC forum that rFactor only supports 4 trackside lights (for night racing) per "track section". My curiosity was if these "track sections" are the specific GMTs that you break the track into (?).

    A while back, I was still working on the AIW. I kept having problems with ISI's AIW editor. After a number of trial and error sessions (days & weeks long), I came to the (perhaps accurate?) conclusion that the ISI AIW editor crashes when presented with a track requiring over ~10,000 waypoints (or something like that.... been awhile now). Fortunately, Brendon came out with his AIW functionality in BTB about that time, alowing me to develop the AIW for my 32 miles of track via BTB.

    On the (above) MAX viewport lighting questions: I have all the ISI tools installed in MAX. What I was getting at... is being able to get the MAX viewport to have similar lighting to what rFactor does in game (WRT where rFactor positions it's "sun"... distance... type of lamp to use in MAX....flood or spot etc.. brightness, color, and all that). I guess I'm looking for a way to set up the lighting in my MAX viewport so that objects look as much like they will 'in game' as possible.... you know... less visual "surprises" once you get things 'in game'. Also wondering if MAX can somehow be made to use the rF shaders in the MAX viewport.... for even more of a realistic 'in game' look while modeling and texturing in MAX. It could also make texture baking more accurate looking.

    Thanks again for your help.... If you can tell me anything about making the MAX viewport look more like what rF displays, let me know...
  5. sevware


    Kyle... Thanks for the Lighting / GMT answer...
  6. mianiak


    Use omni lights and rename them to NightLight## where ## is a number 00, 01, 02, etc.

    Use the renaming tool in the tools menu (Tools > Rename Objects).

    Then you need to name the light glow mesh NightLight##Glow
    You need to do it twice, first set the basename and the number increment, then second uncheck basename and numbered and set the suffix.

    Max viewport will only show up to 10 lights, it should automatically switch to scene lights when you add them, you can toggle scene lights and standard lights in the viewport options.

    Think of the 4 light rule as 4 lights per mesh, not just track, if your terrain is all joined together and beside the track it will only show 4 lights too. So you need to also break up your terrain as well as your track. It also includes buildings trees etc etc. Any single object in the scene will only accept 4 lights.

    You can elongate the omni light to cover more than one street light, this will be helpful to keep your object count down when you have a long track. You can also use textures to show up the glow on the ground (much like a shadow texture). Check out James Burroughs' modification to Jacksonville, the light glow below the lights is a texture not an actual omni light.


    Try to join together track and terrain to one object as much as possible. Buildings no, leave them separate so you can set lods and shadows etc. But join nearby groups of buildings together.

    rF shader support is non existent in max, you only see the allocated texture. You can set up standard materials and make renders but it's not the same.
    You will have to either use SimEd or the rFactor scene viewer to view what the shaders are doing. I use SimEd for quick reference but to get a detailed look I use the scene viewer. Simed uses OpenGL whereas the game and the viewer use DirectX, so to see exactly what the game will show the scene viewer is the go.

    Max is infact a very bad representation of what the texture is doing, you need to do a lot of trial and error in the beginning until you develop a feel for it, especially when setting different texture mapping for different texture channels. Sometimes when you switch back to channel 1 after editing channel 2, max will show ch2 mapping on ch1 but infact ch1 is how you left it and not how max is showing it :D.
    Always have to export and check it.

    [ED] I fixed up a mistake I made, the lights themselves are named NightLight##, then the glow mesh is names NightLight##Glow
  7. sevware


    Very Cool, Mianiak... Especially that you covered so much that I should have asked.

    Before I try to bring the track into Max, I still have a couple things I want to work out. Perhaps you know how this is done:

    I've made pit garages in Max such that each team has a separate building. The garages have cinder block walls, an air compressor on the side, and an overhead fueling tank & hose rig.

    With Max, I've gotten pretty good at building things (camera 'copters, buildings, road furniture, etc..) ... but so far, I have only made UV maps with difuse textures (only).

    What I would like to find out is:

    How do I make my garage's block walls have a matte finish, while other parts of the garage's UV map, such as the fire, air, and fueling tanks remain glossy?

    Is it possible to use the wc car body shader for this (using grey scales in the alpha channel to denote matte or gloss)?

    Would using a car body shader for pit garages somehow limit how many different (actual) car bodys could be loaded into rFactor?

    Another question: On the UV map for my camera helicopters, if I want the body glossy, and and the cockpit windshield semi transparent, how would I go about this.... Presently, I'm using a separate 2d animation as the over cockpit rotor. Will I need to detach the windshield and make it a separate object if I want it semi transparent?

    I'd be using Max and PS with a full complement of plugins and scripts for whatever is the proper way, and will probably test it in game via SimEd & xpacker.

    I want to try to learn and implement this type of stuff prior to bringing whole the track into Max.

    Again, thanks, and thanks in advance...
  8. mianiak


    heh, I'm no expert, I only know the light thing cause I recently had to learn it and it's fresh in my mind :D But I'll give it a go see if I can help you.

    You can use cube map add alpha reflect t1, etc. for the whole thing, or you could use a separate material with cube map, you can control how much the cube reflects.
    I really don't think what ever shader you use will matter to anything, I don't even know if there is a limit, I think it boils down to how much a system can process.

    Personally, I'd use separate materials, I'd have a mat material with maybe specular map t1 and a gloss material with cube specular map t1, you can use the same texture for them both. That way you'd only need a dxt1 dds which can save you a few megabytes. You can fake an ambient occlusion effect with multa maps too if you want to go that far. You would not just use a single texture, you would at minimum use specular map t1. With the spec map and cube map together you can get a really nice effect.

    Does each model have different markings on them? like different team names and numbers/colours etc?
    You can use mesh overlays for decals and stuff, you don't need a whole new texture for it and you can use vertex shading for different colours.

    Make 2 different materials. open the Hammer up in simed and check out the window material and copy it (but don't use the wcwindow mat. name, give it a unique name). For the body once again I'd go for cube specular map t1 and set the cube blend to suit.
    (this is where you will see the benefit of mixing a spec with a cube map and what can be achieved by doing it, in the case of the hammer windows, they use specular colour instead of a spec map, which I think works the same as if you had a spec map with a single colour).

    Make sure to check the cube blend with the scene viewer, the cube rendering is different between the game and simed.

    If you go to the trouble to set up the materials in max, you really want to export it directly from max to gmt. Going from max to simed/xpacker via obj, dae or 3ds is not the way to go. Mainly because once you export it as another format you lose almost everything. You are only left with one material level and one mapping channel (although I haven't researched obj that much and it might be possible) but if your using max, keep it all in max and let max do all the work.

    It is very confusing to start with and you get lost quite easy. I must admit that at first I did cheat a lot, I'd export it with one texture level to gmt then tweak it in simed. But it gets tiresome when you have to do it each time over and over, plus the material controls in max give you much more things to play with, so you soon learn to do it all in max.

    A lot of help can be found here,http://www.mbdevteam.com/download/Tutorials/index.html Elwood from VLM has put together a nice list of tutorials that is quite enough to get you a long way.

    There is a link on that page "Trackmaking tutorial by Scott Juliano (ISI) (.pdf and .doc)" That has some good explanations to how the gmotor materials and tools work in max.

    Check out the "VirtuaLM_AutoShading" tutorial to learn how to bake a shadow layer that can be used as a multa map to give you that ambient occlusion effect.

    Also grab the modding max and the gmt wizard, they come in real handy to speed up a lot of things.

    You can also use a trick in your spec. maps to define edges, if you blend in a white(or light grey) line where the edges are, you will get a bright shine on that spot.

    Sorry for the wall of text, but this stuff can't be explained in just a few lines ;)
  9. sevware


    Thanks for pointing me in the right direction again, Mianiak....

    Also wanted to tell Mikec87 that I enjoyed his Lakeside Park track mod in a road car. I also took a V8 Buggy mod for a drive around the grounds.... I like the lake. It's in a nice area of the planet too.... I worked a couple of one month stays on consecutive years up in Surfers Paradice during Indycar Week for a company that makes motion simulators. Felt like the Long Beach of the Southern Hemisphere. Found myself at their "Indy Undie Ball" one year.... (geeze.... you Austrilians can make a wild party with great scenery out of most anything...).

    edit: spelling .. Australians.... sorry
  10. mianiak


    Your Welcome,

    That's where I live. On the Gold Coast. But you wont see me at Indy or anywhere near the main strip now days, I'm too old for it now, but in my younger days yeah, its a riot of a place, always a lot of fun to be had and plenty of 'scenery'. :thumbsup: