Log in

View Full Version : [REL] AI Uboats with flags


SquareSteelBar
08-19-07, 04:21 AM
This mod provides four AI uboats with flags.
The files are placed in the appropriate folders, so the mod is nearly JSGME compatible - only the EnglishNames.cfg and the GermanNames.cfg in ...\data\Submarine folder have to be edited manually.

The mod was done because it was requested by members of the german UBI forum and some members of Subsim forum for harbour traffic eye-candy purposes.

But be aware that every additional unit will increase launch time of SH3 and slow down performance when added to campaign.


This is what I did in detail:

Type IIB
- added the 'Reichskriegsflagge' to the 'Wintergarten'
- changed the greenish uboat texture to a more grey tint
- changed watch crew texture

Type VIIC/41
- added the 'Reichskriegsflagge' to the 'Wintergarten'
- changed the greenish uboat texture to a more grey tint
- changed watch crew texture

US S-class type
- added US flag to conning tower
- corrected propeller texture

Soviet S-class type
- added USSR flag to conning tower
- changed the greenish uboat texture to a more grey tint
- some additional little texture changes
- replaced stock deck gun by a Russian one
- added gunsVaa_Liliput.dat, -.sim and -.zon into Library folder, extracted from New_Ru_Ships_V3 mod

All units
- several tiny changes and corrections [e.g. water reflections etc.]
- changed names of texture files so that it's possible to use different skins for subs with flags and same subs without flags [I didn't that in the first release to prevent unnecessary performance slow down by introducing additional tga files which also have to be rendered]


Known issues:
- The flags are permanently fixed to the uboats. They don't disappear when uboats leave the harbour.
- It's not possible yet to assign the uboats to different nations than given because always the same flag will appear. I don't know yet how to manage this. Maybe in a future update. For example if you want to assign the US S-class type to a different nation [e.g. British] you have to edit manually TurmUS_1_hd.dat by changing the tga's name from American.tga to British.tga [either in a hex editor or much easier in Skwasjer's S3Ditor].
- the flag isn't fixed to the flag pole and wriggles around it. Maybe it's an issue - I think it isn't: in RL a flag never is pinned directly to the flagstaff but it is hoisted by a slim line which is invisible in far distances. So the flag looks like dancing around the flag pole - in my opinion that's more realistic but it's a matter of taste.

AI Uboats with flags v1.0a (http://files.filefront.com//;8378323;;/)

Have fun with it,
SquareSteelBar;)


P.S.: Sorry for my poor English :oops:

************************************************** **************

just detected the first tiny careless mistake [only related to v1.0, not to v1.0a]http://img389.imageshack.us/img389/7081/bagwe3.gif:

when you're manually editing both files EnglishNames.cfg and GermanNames.cfg in ...\data\Submarine folder please insert these corrected lines:

SSType_RUf=USSR S-class Submarine flagged

SSType_RUf=UdSSR U-Boot S-Klasse beflaggt

denis_469
08-19-07, 04:30 AM
Thank for you work.

Kaleu. Jochen Mohr
08-19-07, 08:07 AM
downloading it right away. looking forward to see the other type's with flags to :up:

TheDarkWraith
08-19-07, 08:40 AM
It's not possible yet to assign the uboats to different nations than given because always the same flag will appear. I don't know yet how to manage this. Maybe in a future update. For example if you want to assign the US S-class type to a different nation [e.g. British] you have to edit manually TurmUS_1_hd.dat by changing the tga's name from American.tga to British.tga [either in a hex editor or much easier in Skwasjer's S3Ditor].
Have fun with it,
SquareSteelBar;)


I can help you out with assigning uboats to different nations (flag wise) without having the user hex editing if you can show me how to do reflections......

bigboywooly
08-19-07, 09:16 AM
Is it not possible to hex a normal flag node as in small ships so it takes the flag from the flags dat ?

TheDarkWraith
08-19-07, 09:27 AM
Is it not possible to hex a normal flag node as in small ships so it takes the flag from the flags dat ?

Yes, in theory that should work. Haven't tried it but see no reason why it wouldn't.
But why not make the flag universal so that YOU can change it to what you want?? Then the ship is multi-national and can be reused with a different flag for whatever nation it's needed for by simply dropping the new flag for the ship in \data\Textures\TNormal\tex. No need for multiple DATs of the same ship just to have different nationality flags flying.

bigboywooly
08-19-07, 09:31 AM
Well if you add a flag node the sub picks up the flag according to the roster its in
Same as the ships

TheDarkWraith
08-19-07, 09:39 AM
Well if you add a flag node the sub picks up the flag according to the roster its in
Same as the ships

That is correct because you are referencing a flag from the flag.dat or flags.dat file and you are using the 3D model (and ID for it) supplied from those files.
I use my own 3D models and IDs and thus don't reference flag.dat or flags.dat files for my flags.
SSB has used his 'own' 3D model in his mod and thus can't use the 'roster' to change his flag's nationality to suit other countries. He has to do another trick.....

SquareSteelBar
08-19-07, 09:59 AM
Is it not possible to hex a normal flag node as in small ships so it takes the flag from the flags dat ? Well if you add a flag node the sub picks up the flag according to the roster its in
Same as the ships I tried that but it doesn't work:
I created a separate flagU.dat [placed in Library folder] including my down scaled 3D models for small flags, hexed a flag node [named cfg#FLU] into turm files but no way. Something essential is missing which I couldn't find out yet. :damn:

BTW I noticed that it's not necessary to embed the flag tgas in the turm files so I removed them. They're even loaded from flag.dat or flagS.dat or from a tga in TNormal\tex folder if available.

TheDarkWraith
08-19-07, 10:05 AM
I created a separate flagU.dat [placed in Library folder] including my down scaled 3D models for small flags, hexed a flag node [named cfg#FLU] into turm files but no way. Something essential is missing which I couldn't find out yet. :damn:

My offer is still out there.....

EDIT:

I figured it out on my own.

lutzow
08-19-07, 12:44 PM
I created a separate flagU.dat [placed in Library folder] including my down scaled 3D models for small flags, hexed a flag node [named cfg#FLU] into turm files but no way. Something essential is missing which I couldn't find out yet. :damn:

My offer is still out there.....

EDIT:

I figured it out on my own.

Yes yes - i always know that you are a magician:up:.

Anvart
08-19-07, 04:42 PM
Is it not possible to hex a normal flag node as in small ships so it takes the flag from the flags dat ? Well if you add a flag node the sub picks up the flag according to the roster its in
Same as the ships I tried that but it doesn't work:
I created a separate flagU.dat [placed in Library folder] including my down scaled 3D models for small flags, hexed a flag node [named cfg#FLU] into turm files but no way. Something essential is missing which I couldn't find out yet. :damn:

BTW I noticed that it's not necessary to embed the flag tgas in the turm files so I removed them. They're even loaded from flag.dat or flagS.dat or from a tga in TNormal\tex folder if available.
You should use flag as equipment ...
You tried to insert flag node (cfg#...) into dat-file and to insert flag node into eqp-file too ...:hmm:

SquareSteelBar
08-21-07, 03:29 AM
You should use flag as equipment ...
You tried to insert flag node (cfg#...) into dat-file and to insert flag node into eqp-file too ...:hmm: Thanks, mate - but I tried that already and it didn't work. Maybe I did something wrong [any typing mistake?]. I'll check this again...

So long,
SquareSteelBar

SquareSteelBar
08-21-07, 04:36 AM
My offer is still out there.....

EDIT:

I figured it out on my own. Ooops... I'm afraid I missed something - sorry, mate. But you already managed it.
For this time I'll try it my own, too.
Nevertheless thanks for the offer :rock:

So long,
SquareSteelBar

SquareSteelBar
08-23-07, 05:53 AM
Little update - go to the first post (http://www.subsim.com/radioroom/showpost.php?p=624969&postcount=1).

I changed the names of embedded tga files so now it's possible to use different skins for subs with flags and the same subs without flags.
I didn't that in the first release to prevent unnecessary performance slow down by introducing additional tga files which also need system resources.
But now that ability has been requested in german UBI forum.

SquareSteelBar

Anvart
03-29-09, 02:27 AM
You can use "External Reference" controller (Type11/1) and have any name of flags file-name ... Skwas names this controller as "Placement" :D.
...
And sh3 have hardcoded names for flags nodes ...