Jump to content
Sign in to follow this  
arno

what's middleman good for.......

Recommended Posts

Guest

if I use fsregen to make library objects out of all my gmax objects?I've been using it, but Arno suggested not to, and i was surprised to find a keep files option right on makemdl.exe.Bob Bernstein

Share this post


Link to post
Share on other sites

I am not sure about this, but I think M$ has put most of the functions MiddleMan added in their new MakeMDL. So I also don't see the need to use it anymore, maybe someone else can provide some other thoughts on this?ArnoMember NL2000 Teamhttp://home.wanadoo.nl/arno.gerretsen


Arno

If the world should blow itself up, the last audible voice would be that of an expert saying it can't be done.

FSDeveloper.com | Former Microsoft FS MVP | Blog

Share this post


Link to post
Share on other sites

1) I am only getting GMAX to produce one asm file not another file called xxx_0.asm.2) Following on from your post I do not seem to need FSREGEN to do this and the asm file is now directly being generated by the new Middleman 1.1 and GMAX export, and the 'Keep Files' feature3) Now that I have the .asm and .azm files how do I use this within Airport? Rename them and edit by hand?Need some answers here. Thanks guys.Shez


Shez Ansari

Windows 11; CPU: Intel Core i7-8700K; GPU: EVGA GEFORCE GTX 1080Ti 11GB; MB: Gigabyte Z370 AORUS Gaming 5; RAM: 16GB; HD: Samsung 960 Pro 512GB SSD, Samsung 850 Pro 256GB SSD; Display: ASUS 4K 28", Asus UHD 26"

Share this post


Link to post
Share on other sites
Guest

I, too, did not need middleman when exporting with either new or old versions of makemdl.The use of .asm file was helpful in getting rid of some unwanted ground shadows.I had been eliminating the shadowcall feature by editing with notepad and using the BGLC that came with the microsoft effects SDK , I was able to recompile the same BGL .http://ftp.avsim.com/dcforum/DCForumID10/312.htmlall the best,biberwww.LTBA.net

Share this post


Link to post
Share on other sites
Guest

The nice thing about fsregen is the library object option...George has coded his gui so it repackages the gmax bglc code properly and assigns its object id that you can call from a scasm calling macro as you would with any library object.So, you run fsregen library object utility, saving the library file. Then compile the library file using bglc.Now you have the library object bgl.The macro you write in scasm calls the lib obj, using CallLibObj command.Make sense? I can post an example if you want it, but I'm at work right now.B

Share this post


Link to post
Share on other sites

Thanks Bob. Yes it would be good if you could post an example. Is this going to mean a manual edit of the .sca file? or can Airport do this? From what I see the only macro Airport can see are api macros...RegardsShez


Shez Ansari

Windows 11; CPU: Intel Core i7-8700K; GPU: EVGA GEFORCE GTX 1080Ti 11GB; MB: Gigabyte Z370 AORUS Gaming 5; RAM: 16GB; HD: Samsung 960 Pro 512GB SSD, Samsung 850 Pro 256GB SSD; Display: ASUS 4K 28", Asus UHD 26"

Share this post


Link to post
Share on other sites

After you have made a library of your GMax objects with FsRegen, you must create an API macro for each object, so you can place it using Airport or GroundMaker.Here is an example of such a macro:[tt]Area( 5 %1 %2 22 )PerspectiveCall( :L1 )ShadowCall( :L2 )Jump( : ):L1;Perspective:L2mif( %11 )RefPoint( 2 :E1 %4 %1 %2 E= %11 v1= %10 %13 %14 )melseRefPoint( 7 :E1 %4 %1 %2 v1= %10 %13 %14 )mifendRotatedCall( :R1 0 0 %5 )Return:R1CallLibObj( 0 11111979 27042002 00000000 00000001 ):E1ReturnEndA[/tt]Of course you should place the ID you gave your objects in the CallLibObj command.The only problem with this method is that you can not see the shape of the object while you are placing it. I am working on a little tool that will also solve these problems. I hope I find some time soon to finish it.ArnoMember NL2000 Teamhttp://home.wanadoo.nl/arno.gerretsen


Arno

If the world should blow itself up, the last audible voice would be that of an expert saying it can't be done.

FSDeveloper.com | Former Microsoft FS MVP | Blog

Share this post


Link to post
Share on other sites

OK I recognise the api format but the api macro is only generated by specific programs such as FSDS or VOD etc. which obviously cannot process this library code. So I guess you mean I use a simple macro code (like above) and just change the name of the library name of the object? :-hmmm Thanks for walking me through this.Shez


Shez Ansari

Windows 11; CPU: Intel Core i7-8700K; GPU: EVGA GEFORCE GTX 1080Ti 11GB; MB: Gigabyte Z370 AORUS Gaming 5; RAM: 16GB; HD: Samsung 960 Pro 512GB SSD, Samsung 850 Pro 256GB SSD; Display: ASUS 4K 28", Asus UHD 26"

Share this post


Link to post
Share on other sites

Yes, the best way is to make your macro in a text editor. Just edit the example above so it matches your ID.ArnoMember NL2000 Teamhttp://home.wanadoo.nl/arno.gerretsen


Arno

If the world should blow itself up, the last audible voice would be that of an expert saying it can't be done.

FSDeveloper.com | Former Microsoft FS MVP | Blog

Share this post


Link to post
Share on other sites

Roger. Let me see how much I progress with this. Sounds like fun but also very time consuming when doing scenery....How would creating scenery object bgls and assigning them to lat/lon and then merging the bgls work?Shez


Shez Ansari

Windows 11; CPU: Intel Core i7-8700K; GPU: EVGA GEFORCE GTX 1080Ti 11GB; MB: Gigabyte Z370 AORUS Gaming 5; RAM: 16GB; HD: Samsung 960 Pro 512GB SSD, Samsung 850 Pro 256GB SSD; Display: ASUS 4K 28", Asus UHD 26"

Share this post


Link to post
Share on other sites
Guest

I suspect that would work, I prefer making object libraries, but each to their own.Remember, once you have a working calling macro, you can make a new one in seconds. Only thing that changes is the object ID.You are used to thinking that VOD or FSDS creates macros, they are just shortcuts to write scasm. When the scasm is this simple, what's the problem in writing it yourself? Probably just the shock of thinking differently. It takes only seconds to do. The example Arno gave you is a good one, but it can be simplified even further, if you plan to have the macro sitting on the ground. In that event you can produce an even shorter code. Here is Arno

Share this post


Link to post
Share on other sites

I think the issue at hand is that (as you are well aware), scenery design is a constant juggle back and forth between FSDS, Airport and FS2002 to check that the object etc. are correctly placed or sized or whatever. With this method it is forcing the designer to introduce new steps in this process.Another question, can the library name be anything eg. A1? or does it have to be the long Binary type code?ThanksShez


Shez Ansari

Windows 11; CPU: Intel Core i7-8700K; GPU: EVGA GEFORCE GTX 1080Ti 11GB; MB: Gigabyte Z370 AORUS Gaming 5; RAM: 16GB; HD: Samsung 960 Pro 512GB SSD, Samsung 850 Pro 256GB SSD; Display: ASUS 4K 28", Asus UHD 26"

Share this post


Link to post
Share on other sites

The ID has to be 4 x 8 digits, hexadecimal. You can then choose anything you want (as long as no one else has the same ID, it will work).ArnoMember NL2000 Teamhttp://home.wanadoo.nl/arno.gerretsen


Arno

If the world should blow itself up, the last audible voice would be that of an expert saying it can't be done.

FSDeveloper.com | Former Microsoft FS MVP | Blog

Share this post


Link to post
Share on other sites

OK I cannot seem to be able to call the macro...Here are the steps I am taking. Can someone audit this and tell me what I am doing wrong...please...:( 1) I have a simple building object in GMAX2) I export using Middleman 1.1 and tick mark 'keep files'3) The GMAX generates the bgl and when I go to FS2002 my building is there, great!4) I now have a test.asm and test.azm file5) I open FSregen 0.20b and on the main screen I go to 'Library Compiler'6) In the 'Library Compiler' in the top window I search for the .asm file and open it. At this point it comes up with a window that the filename_0.asm is not found and then another window stating that the scale command is not present. I ignore these warnings.7) a) I change the Object name to eg. 'building' :( Change the GUID to 12345678, 12345678, 12345678, 00000001 c) Do not change any of the four parameters below the GUID window d) Click 'Add to list' to add the file in the main window, which it does successfully e) In the output file window I change the name to test2.asm and click 'Create Library'. It says the create was successful and "compile with BGLC"8) I then drag & drop the test2.asm file into BGLC.exe. The DOS compile window appears and then disappears, does not seem to change the contents of the directory though9) I then use the simple macro above and change it to the following to add my unique ID,Area( 5 %1 %2 22 ) PerspectiveCall( :L1 )ShadowCall( :L1 )Jump( : ) :L1RefPoint( 7 :E1 %4 %1 %2 v1= %10 %13 %14 )RotatedCall( :R1 0 0 %5 )Return :R1CallLibObj( 0 12345678 12345678 12345678 00000001) :E1Return EndA10) I finally open Airport and call the macro as a user api and place it and compile the bgl. No error message.11) Go and add the scenery but....NO 3D OBJECT.What is wrong here guys?Thanks again for helping out.Shez


Shez Ansari

Windows 11; CPU: Intel Core i7-8700K; GPU: EVGA GEFORCE GTX 1080Ti 11GB; MB: Gigabyte Z370 AORUS Gaming 5; RAM: 16GB; HD: Samsung 960 Pro 512GB SSD, Samsung 850 Pro 256GB SSD; Display: ASUS 4K 28", Asus UHD 26"

Share this post


Link to post
Share on other sites
Guest

I think you need to download the makemdl SDK and use the makemdl from that, middleman1.1 was made for it anyway, but you don`t require mman with new makemdl because MS added a keep files box (i really made middleman for the virtual cockpit side of things but added the other stuff seeing i was there). FSregen looks like it requires the new one as well because......the original makemdl creates an azm and asm file and the new one creates an asm and _0.asm and that should sort out your missing file in fsregen. Chris File

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Tom Allensworth,
    Founder of AVSIM Online


  • Flight Simulation's Premier Resource!

    AVSIM is a free service to the flight simulation community. AVSIM is staffed completely by volunteers and all funds donated to AVSIM go directly back to supporting the community. Your donation here helps to pay our bandwidth costs, emergency funding, and other general costs that crop up from time to time. Thank you for your support!

    Click here for more information and to see all donations year to date.
×
×
  • Create New...