Special Aircraft Service

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 [2] 3 4 5 ... 13   Go Down

Author Topic: UberQuick Mission Generator (UQMG) for BAT Project Development News (02 Mar 2021 // Update 004 Released, support BAT WAW 4.1.1)  (Read 29358 times)

0 Members and 2 Guests are viewing this topic.

RealDarko

  • Modder
  • member
  • Offline Offline
  • Posts: 2255

As you know UberDemon, I'm a long time user of your UQMG, very happy you're working on it again, looking forward to try it, and to start missions from the ground!!
Logged

UberDemon

  • UberDemon/danzigzag
  • Modder
  • member
  • Offline Offline
  • Posts: 1381

Below is some eye candy from the mission I mentioned last night.  This was the first succesful Blue team mission, which I had to do some debugging.

As I stated before, simple to create, yet immersive mission of 12x Romanian He-112B-2 intercepting 15x Yermolaev Yer-2 bombers over Kuban peninsula.  Took me about a minute to create. There are many start/take off options, and in this one it is a long flight mission.  All aircraft start flying over their bases already in formation.  There is plenty of ground scenery, as well as ground and naval units.















































Enjoy.
Logged
Best Regards, UberDemon/danzigzag, Get UQMG at SAS BAT Mission area.  www.uberdemon.net no longer exists.  (** Alienware Aurora R7 / i7-8700 3.20GHz / 16GB RAM / Win 10 x64 / NVIDIA GeForce GTX 1080 **)

UberDemon

  • UberDemon/danzigzag
  • Modder
  • member
  • Offline Offline
  • Posts: 1381

Some more eye candy.  Here we look at the ease of creating large composite missions.  Using the Flight Group concept, for those who are not familiar with UQMG, there are up to 4 Red and up to 4 Blue flight groups, each flight group can be cloned multiple times, depending on how many regiments exist.  That is how you create several flights.  So for a Kette of Stukas, or 3xJu-87, if you clone it 10 times in one flight group, you have 33 Stukas in that flight group alone.

With composites, you can only have one composite set.  So, say you want the Whitley to tow an Airspeed Horsa...  you select that composite flight, then if you clone it 8 times, you have 9 total Whitley/Horsa sets... do the same with Lancaster and Hamilcar... so in total you have 18 composite flights for 36 aircraft in two groups... add some escorts in the third group so a flight of 3xWhirlwids, cloned once and you have 6 total, and these will take off.

Now for your flight, let's used the Propaganda fighter, the He-100.  Create a flight of 4, then clone it 3 times and you have 16.  To get the mission going let's have all start in the air over the base.  Taking off would take forever.  Also the composites only behave well if you only have one set take off at a time.  You can do that with the delay feature... and sometimes you want the glider to spawn later.  Say the towing craft/tug takes off, then 5 minutes in the mission the glider appears behind the tower.  You can do that in UQMG.

So this was the first test with BAT composite flights.

Bugs I found
* Somehow the default He-100 load loads as "empty", it is the only one, I need to figure out why UQMG is doing that
* On an Air Start, the Hamilcar will not appear if it is being towed by a Short Stirling, but it will with something like the Lancaster or He-111Z (that is an IL-2 or mod issue, not an UQMG issue)

Anyway, pictures.  (The one below was the first try... I actually used 9 sets each of the composite flights... also, I had to change the distancing of the clones for the composite flights... yes you can do that too in UQMG, so they will not run into each other).





























































Enjoy.
Logged
Best Regards, UberDemon/danzigzag, Get UQMG at SAS BAT Mission area.  www.uberdemon.net no longer exists.  (** Alienware Aurora R7 / i7-8700 3.20GHz / 16GB RAM / Win 10 x64 / NVIDIA GeForce GTX 1080 **)

RealDarko

  • Modder
  • member
  • Offline Offline
  • Posts: 2255

Looks amazing! Hope you can add a way to add more maps!
Logged

Squashman

  • Modder
  • member
  • Offline Offline
  • Posts: 554
  • No, I am Spartacus

Great work Uber; only just picked up this thread. There are many superlatives that would do it justice but I will say simply - Bravo!
Logged

raf1659

  • member
  • Offline Offline
  • Posts: 356

WOWOWOWOWOW !!!  ]hello2[ ]hello2[ ]hello2[
Logged

UberDemon

  • UberDemon/danzigzag
  • Modder
  • member
  • Offline Offline
  • Posts: 1381

[UPDATE/EDIT FOUND A BATCH/POWERSHELL SOLUTION FOR ITEM IN PARAGRAPH "2)" BELOW!]

Thank you for the support.  I have run into a couple of snags, one is fixable, just have to code for it, and the other is just annoying, but I am trying to find a coding solution.

1) Trying to automate things as much as possible, and remembering UQMG Classic is quirky with handling of fields, I had to use some creative coding to handle mods and BAT text fields which include (1) stuff like special characters and periods in the names of java classes, and (2) stuff like commas in the text description of properties.  Whereas VB is really good in handling fielded lists, like CSV files, sometimes (yeah, sometimes) it chokes when it encounter things like "2xFAB250, 2xFAB50",2x250+2x50   .  In this case it really dislikes that comma inside the quotes, and the good thing (bad thing) is that it can be inconsistent when it likes it or not.  I have problem "1" dealt with with very painful coding.  Item 2, I use a special pattern, namely "@^@" to indicate a comma, then I replace it in the UQMG classic fields...  Well... dumb old me forgot to do the same for writing and identifying patterns, so I'll have to find that routine in UQMG Classic.  Just an old man forgetting things dumb mistake.  Will take a bit of time, but totally doable. [Edit, this is the problem related to the Empty load in the He-100 that I mentioned above, so that is good... that will solve issues.]

2) The second problem is something that has persisted through the life of VB6.  Remembering again that UQMG Classic is ancient code, I am having to deal with its quirky way to handle UNICODE characters.  It may affect users as it has in the past because they don't have a particular DLL in their Windows installation, and that is a non-distributable file (as in, it is not something that comes in an installation, but more associated with what kinds of MS Office items you have installed).  The file is "c:\Windows\SysWow64\FM20.dll"  That is not the only thing.

To make a long story short...  to display characters correctly, like "Bücker Bü-XXX" instead of "Bucker Bu-XXX" you have to have a combination of controls (like grids and list boxes) that can handle Unicode characters, you have to have the correct character set, the correct Font (like Tahoma, which can handle UNICODE), the controls that use FM20.dll... and doing it in VB6 is like clapping with one hand, like punching a whole in the wall with your face.

Well, I found a solution in the old hidden corners of the Web in which an Arab coder was dealing with a similar problem having a heck of a time trying to convert VB6 code to handle his company's customer entry form with Arabic characters... after several discussions that lead to nothing, like most of the ones in this subject (by that I mean a lot of experts that can explain the theory behind it, but no ability to generate code to fix it...) the coder found an easy solution , which was to change the Character set in the input text file... yeah, opening the file in NOTEPAD, and in the Save As dialog, changing the Encoding Field, which will display the default for most files (UTF-8), but can be changed to other values.

Out of sheer hope, I changed my input file to ASCII, and it fixed things... suddenly everything turned nice in UQMG classic.

Soo... great... how do I do it programmatically so that I don't have to do it manually like that?  That has been the problem.  I tried changing the encoding in the original files generated by UCT (UQMG Conversion Tool), which are most likely in UTF-8, and converting them to ASCII encoding, but things got botched up... and "Bücker Bü-XXX" became "B?cker B?-XXX".

I think I have one more thing to try before asking for help from the coders here.  My routines in UQMG use the very convenient Text / Text-field capabilities inherent in VB (for fast DB application building), but those can be odd if the input files are not exactly like what the program wants to find.  I may try using the Binary input and output and see if that fixes things when it comes to decoding and encoding.

WHY DO YOU CARE?  Probably not, but if you are a Coder, and you can lend me a hand I would appreciate it:
* I am looking for a VB, or otherwise routine, DLL, application (that can take command/execution input variables) that can essentially do what Notepad does, that is (1) Read content of a file (2) Rewrite file in the character encoding I specify.  Essentially opening a file in Notepad, Saving it as blablabla.whatever using the Encoding I specify.

I am looking further into this:  https://stackoverflow.com/questions/16598785/save-text-file-in-utf-8-encoding-using-cmd-exe#:~:text=The%20default%20encoding%20for%20command,and%20then%20run%20your%20command.&text=Change%20it%20back%20to%20default%20when%20done.

Maybe a CMD or PowerShell script will do it... but I wish I could do it programatically without failing.

EDIT:  PowerShell may have a slightly more elegant solution:  https://www.powershelladmin.com/wiki/Convert_from_most_encodings_to_utf8_with_powershell

Anyway, I am working at it, slowly, but surely.  Still, if anyone has a coding solution that would be awesome.

and, update in 2 weeks :D

EDIT / SOLUTION TO ITEM "2)" ABOVE REGARDING CHANGING INPUT FILE FROM UTF-8 TO ASCII:

* Looking at that last hyperlink and through trial and error, I was able to create a batch/PowerShell solution.  I wish I could program it, but I have a solution that I can somewhat automate, and that is good enough!

This is what the code looks like in a batch file called "encode.bat"
Code: [Select]
@echo off
rem *******************************************************************************
rem **** SCRIPT TO CHANGE UCT2020 TEXT INITIALIZATION FILES FROM UTF-8 TO ANSI ****
rem **** Based on info from: www.powershelladmin.com/wiki/Convert_from_most_encodings_to_utf8_with_powershell
rem **** Work in Progress v.1.1, by UberDemon, 12 June 2020                    ****
rem *******************************************************************************
cls
pause
ren fd_Aircraft.ini UTF8_fd_Aircraft.ini
ren fd_ComboAircraft.ini UTF8_fd_ComboAircraft.ini
ren fd_countryblue.ini UTF8_fd_countryblue.ini
ren fd_countryred.ini UTF8_fd_countryred.ini
ren fd_craftjump.ini UTF8_fd_craftjump.ini
ren fd_craftjumpval.ini UTF8_fd_craftjumpval.ini
ren fd_DogfightNames.ini UTF8_fd_DogfightNames.ini
ren fd_DogfightNamesFly.ini UTF8_fd_DogfightNamesFly.ini
ren fd_Regiments.ini UTF8_fd_Regiments.ini
ren fd_Skins.ini UTF8_fd_Skins.ini
ren fd_SpecialWeapons.ini UTF8_fd_SpecialWeapons.ini
ren fd_Weapons.ini UTF8_fd_Weapons.ini
ren LoadLastData.ini UTF8_LoadLastData.ini
ren SystemMainDefaults.ini UTF8_SystemMainDefaults.ini
pause
PowerShell.exe "Get-Content .\UTF8_fd_Aircraft.ini -Encoding UTF8 | Set-Content -Encoding String .\fd_Aircraft.ini"
PowerShell.exe "Get-Content .\UTF8_fd_ComboAircraft.ini -Encoding UTF8 | Set-Content -Encoding String .\fd_ComboAircraft.ini"
PowerShell.exe "Get-Content .\UTF8_fd_countryblue.ini -Encoding UTF8 | Set-Content -Encoding String .\fd_countryblue.ini"
PowerShell.exe "Get-Content .\UTF8_fd_countryred.ini -Encoding UTF8 | Set-Content -Encoding String .\fd_countryred.ini"
PowerShell.exe "Get-Content .\UTF8_fd_craftjump.ini -Encoding UTF8 | Set-Content -Encoding String .\fd_craftjump.ini"
PowerShell.exe "Get-Content .\UTF8_fd_craftjumpval.ini -Encoding UTF8 | Set-Content -Encoding String .\fd_craftjumpval.ini"
PowerShell.exe "Get-Content .\UTF8_fd_DogfightNames.ini -Encoding UTF8 | Set-Content -Encoding String .\fd_DogfightNames.ini"
PowerShell.exe "Get-Content .\UTF8_fd_DogfightNamesFly.ini -Encoding UTF8 | Set-Content -Encoding String .\fd_DogfightNamesFly.ini"
PowerShell.exe "Get-Content .\UTF8_fd_Regiments.ini -Encoding UTF8 | Set-Content -Encoding String .\fd_Regiments.ini"
PowerShell.exe "Get-Content .\UTF8_fd_Skins.ini -Encoding UTF8 | Set-Content -Encoding String .\fd_Skins.ini"
PowerShell.exe "Get-Content .\UTF8_fd_SpecialWeapons.ini -Encoding UTF8 | Set-Content -Encoding String .\fd_SpecialWeapons.ini"
PowerShell.exe "Get-Content .\UTF8_fd_Weapons.ini -Encoding UTF8 | Set-Content -Encoding String .\fd_Weapons.ini"
PowerShell.exe "Get-Content .\UTF8_LoadLastData.ini -Encoding UTF8 | Set-Content -Encoding String .\LoadLastData.ini"
PowerShell.exe "Get-Content .\UTF8_SystemMainDefaults.ini -Encoding UTF8 | Set-Content -Encoding String .\SystemMainDefaults.ini"

Once the conversion is done, opening the file in Notepad displays both the correct characters, it also show in bottom right lower corner the Encoding to be ANSI.  This was trial and error.  The source is definitely UTF-8, which is the output from UCT2020, but trying to encode it to ASCII yields wrong results... String was an option for encoding and it worked, and got loaded correctly in UQMG Classic.
Logged
Best Regards, UberDemon/danzigzag, Get UQMG at SAS BAT Mission area.  www.uberdemon.net no longer exists.  (** Alienware Aurora R7 / i7-8700 3.20GHz / 16GB RAM / Win 10 x64 / NVIDIA GeForce GTX 1080 **)

UberDemon

  • UberDemon/danzigzag
  • Modder
  • member
  • Offline Offline
  • Posts: 1381

Unfortunately I found another issue that I don't have a solution right now.

This is related to the Message Banners.  Because how UQMG is programmed, for composite flights where there is a tug and a glider, when you go to the flight editor, it only considers the tug when it comes to Skins, Pilots and Nose art.  For Message Banners with custom wording to work, you must pick the target banner country of USA (that is the only one that works), and then you pick the load for the message, then you pick the nose art for one of the existing messages.

Because it is handling the tug first, you can't pick the message.  I have not been able to make towing those messages possible (in a player flown aircraft tug) despite reading all instructions, they always automatically detach, so I am not overly concerned about making this work, it seems hard to get it to work unless it is purely handled by AI...

But I don't have AI flights labeled as "Tug in Tow..."  Not sure how I would be able to do it, but if I do that may be a possible answer.  If anyone is able to make this towing banner thing work from a flyable plane, please let me know because I cannot, not even using the missions that came with the mod for Single player, they always automatically detach when the mission start, regardless of speed, taking off or starting in air.  Maybe I am just dumb.

Anyway, if I find a solution for UQMG I'll let you all know, but this is pretty low priority right now.  On the other hand, AI composite flights with the Target banners and decoy work well, as long as you are not towing it.
Logged
Best Regards, UberDemon/danzigzag, Get UQMG at SAS BAT Mission area.  www.uberdemon.net no longer exists.  (** Alienware Aurora R7 / i7-8700 3.20GHz / 16GB RAM / Win 10 x64 / NVIDIA GeForce GTX 1080 **)

raf1659

  • member
  • Offline Offline
  • Posts: 356

Disable/ignore -message banners-, is it stop the release ;)
Logged

UberDemon

  • UberDemon/danzigzag
  • Modder
  • member
  • Offline Offline
  • Posts: 1381

Disable/ignore -message banners-, is it stop the release ;)

 Ha ha!  Well, actually I was able to fly a Lysander TT with a tow winch and it works well as a banner/target/decoy tug in player mode, but I cannot change the nose art in the banner message in UQMG yet, so I'll have to do some digging, it is a nice to have but not a must have right now; besides you can still use the other banners and decoys, just not the custom messages.

In general the original stock tugs work well for towing anything (He-111 family, Bf-110 family, Pe-8/TB-7 family, Li-2/C-47/DC-3/L2D family, as well as the Japanese D3A1), particularly in player mode.  The Pe-8 (but not the TB-7) is the only one that can tow 1 to 3 gliders.  And of course the He-111Z, Pe-8 and TB-7 are the only ones that can handle towing the Me-321 Gigant.  You can attach an Me-321 to a Bf-110, but it does look ridiculous and taking off is hard... not really something I'll enable in the new version of UQMG going forward...  I think the reason the Bf-110 family was enabled as tugs to begin with was because at first, before the He-111Z was created, the Gigant was towed by 3x Bf-110s...  that just sounds like a suicidal solution... from a game design standpoint, it probably would be hard to implement.
Logged
Best Regards, UberDemon/danzigzag, Get UQMG at SAS BAT Mission area.  www.uberdemon.net no longer exists.  (** Alienware Aurora R7 / i7-8700 3.20GHz / 16GB RAM / Win 10 x64 / NVIDIA GeForce GTX 1080 **)

UberDemon

  • UberDemon/danzigzag
  • Modder
  • member
  • Offline Offline
  • Posts: 1381

      14 June 2020

      Greetings.  Here is a quick update:

  • Problem regarding commas in description text:  I think I nipped it in the bud in UCT
  • I did a lot of code clean up in UCT as well.
  • UNICODE display issues are solved with a batch file that invokes PowerShell to change encoding of files as proper.
  • Found routines in original VB6 for dealing with commas in display/description so that mission files are not botched when generated.  This was easy but I had to dig in the millions of lines of code (uh… thousands, not millions…) because there were multiple areas in the code where I had to fix things.
  • Next step:  I am happy with the code now, so I’ll work on porting the BAT 3.8.4 patch and see how that goes, in theory it should not be that problematic.

Some interface pics below:


1) Programming interface in VB2019 for UCT2020, and notice the addition of the “Final Fix” button/routine.  This is what takes care of placing a pattern in applicable files (Weapons, Composite Weapons, and Regiments) so the UQMG Classic does not mess up loading those elements in its interface.


2) Another mission test… you can see things are loading OK


3) Note I’ll be releasing a slight update of the UQMG executable as well, the one shown is the one that has the changes I have been talking about.


Here is some eye candy from the mission.  This one is a fictional scenario with some Pacific fighters flying in Europe, and it takes a look at the Ju-52 as a tug for the DFS-230 glider (20 trains in all).  I did not cheat on this one, I actually flew it.  I used the autopilot to get to the fighting, but after that it is all me baby!  To note, the Tiger Cat has really poor visibility.  You can only see 90 degrees to each side.  The armament is powerful.  I ended up getting 8 kills.  The Ju-52s and DFSs got me a few times and I had a fuel leak.  Towards the end of the mission, on my glide path, I got a nasty AAA shot in the tank, it was a rough landing, but I made it.  My wingman landed with one engine, but abandoned the plane in the runway.  My number 3 landed without any issues.  After I landed, I ran the clock at 256x and saw the sunset, so that is why you see the lights on in the end of the mission.



























































As always, team UberDemon/danzigzag, which is me, will have another update in two weeks.
Logged
Best Regards, UberDemon/danzigzag, Get UQMG at SAS BAT Mission area.  www.uberdemon.net no longer exists.  (** Alienware Aurora R7 / i7-8700 3.20GHz / 16GB RAM / Win 10 x64 / NVIDIA GeForce GTX 1080 **)

RealDarko

  • Modder
  • member
  • Offline Offline
  • Posts: 2255

Happy to see you're progressing, please keep at it!
Logged
Pages: 1 [2] 3 4 5 ... 13   Go Up
 

Page created in 0.032 seconds with 26 queries.