Page 1 of 1
Units Positions
Posted: 2022-06-15 11:29, Wednesday
by danadi712
Hello.
First i want to say thank you for this wonderful mod.
Then i have a question.
It is possible to make a mod that keep the orientation of the units only in two positions like in PANZER GENERAL 1 (or PANZER CORPS 1)?
I mean i dont want units to rotate when i move them.
I want just two orientation :LEFT and RIGHT.
(Or at least one orientation LEFT OR RIGHT)
Re: Units Positions
Posted: 2022-06-17 11:31, Friday
by randowe
danadi712 wrote: ↑2022-06-15 11:29, Wednesday
Hello.
First i want to say thank you for this wonderful mod.
Then i have a question.
It is possible to make a mod that keep the orientation of the units only in two positions like in PANZER GENERAL 1 (or PANZER CORPS 1)?
I mean i dont want units to rotate when i move them.
I want just two orientation :LEFT and RIGHT.
(Or at least one orientation LEFT OR RIGHT)
Welcome to the forum
As far as i know it is not possible. Even if you cut all icons down to show only the side view of an unit and set FaceOffset so that a unit would not turn when initiating an attack, it still could turn around 180° when moving.
If the FaceOffset setting also comes into consideration when a unit is being attacked i don't know.
Re: Units Positions
Posted: 2022-06-17 11:45, Friday
by LuisGuzman
randowe wrote: ↑2022-06-17 11:31, Friday
danadi712 wrote: ↑2022-06-15 11:29, Wednesday
Hello.
First i want to say thank you for this wonderful mod.
Then i have a question.
It is possible to make a mod that keep the orientation of the units only in two positions like in PANZER GENERAL 1 (or PANZER CORPS 1)?
I mean i dont want units to rotate when i move them.
I want just two orientation :LEFT and RIGHT.
(Or at least one orientation LEFT OR RIGHT)
Welcome to the forum
As far as i know it is not possible. ...
For efiles using standard icons' png made with 9 images, is not possible to show only 2 faces for the unit' icon in game.
But if the efile uses icons' png made with just a single image (see EFILE_SON) then it shows only 2 faces like old PG.

Re: Units Positions
Posted: 2022-06-19 12:04, Sunday
by danadi712
So if i made unit png with one image and overwrite the original one it should work?
In original campaign of Panzer General 2?
Re: Units Positions
Posted: 2022-06-19 16:10, Sunday
by LuisGuzman
danadi712 wrote: ↑2022-06-19 12:04, Sunday
So if i made unit png with one image and overwrite the original one it should work?
In original campaign of Panzer General 2?
No need to overwrite anything if you only want 2 faces for EFILE_PG2 (or for only a few ones).
If you only want 2 faces units for only a few efiles, it's better to create a single png for each unit with just one image and locate them in the efile's OPENDAT folder.
Alternatively (If you want to use in many efiles), you can pack all the png files into a "OpenIconsLoc.dat" file and copy this file in the main efile's folder you want to use units with only 2 faces.
OG will detect it is a single unit image if eighth is less than 240 or width is less that 150 pixels of any of them are not multiple of 3.
I mean 241x150 will be loaded as a single face icon and 120x60 too

Re: Units Positions
Posted: 2022-06-27 12:59, Monday
by danadi712
So this is what i did.
I use EFILE_CC03
Made a png size 241x150 of Pz IIA (german tanc) with this name
Pz IIA.png
Put this png in OPENDAT folder of EFILE_CC03.
Begin new campaign BLITZ
Buy the unit.
Unit is still rotate 360 degree.
What is wrong?
Re: Units Positions
Posted: 2022-06-27 13:41, Monday
by randowe
danadi712 wrote: ↑2022-06-27 12:59, Monday
So this is what i did.
I use EFILE_CC03
Made a png size 241x150 of Pz IIA (german tanc) with this name
Pz IIA.png
Put this png in OPENDAT folder of EFILE_CC03.
Begin new campaign BLITZ
Buy the unit.
Unit is still rotate 360 degree.
What is wrong?
You have to rename your icon (png file) so it matches the original icon's designation of the icon used for a specific unit in the efile. In the case of your Pz IIA it has to be
g113.
I tested with this icon, with all other views cut off,

in CC03 and it works. Only two views are shown, either the unit will look to the right or left.
Re: Units Positions
Posted: 2022-06-27 14:17, Monday
by danadi712
Thank you.
I can confirm that is working.
But i have some questions
-How did you obtain that png?And what width x length pixels did you have?
-How to make an OpenIconsLoc.dat file?
-I wonder if will be possible to insert equipement icon on highter resolution.
Like those in PANZER CORPS 1.
Re: Units Positions
Posted: 2022-06-27 14:40, Monday
by randowe
danadi712 wrote: ↑2022-06-27 14:17, Monday
-How did you obtain that png?And what width x length pixels did you have?
First i checked in the efile which icon is used for the unit: icon ID.
I loaded the original icon (240x150 pixel, all views) with photoshop. Then i set the working space to 80x50 pixel, center of the picture.
Then the rest of the icon picture becomes invisible (but is still there) and the image is centered on the central view of the unit.
Then i can save the new icon file, showing only the central view.
danadi712 wrote: ↑2022-06-27 14:17, Monday
-How to make an OpenIconsLoc.dat file?
You have to download the Icons Tool from Luis website. With this tool you can add icon pictures and save as dat file / work on dat files.
danadi712 wrote: ↑2022-06-27 14:17, Monday
-I wonder if will be possible to insert equipement icon on highter resolution.
Like those in PANZER CORPS 1.
Technically it is possible to use bigger icons, but then the units, adjacent to each other, are overlapping.
Keep in mind that the size of the hex grid and the size of the icons are coordinated/harmonious.
Bigger icons also overlap in buy screen, etc.
(Some players (with big screens) play with 200% zoom to get bigger icons.)
Re: Units Positions
Posted: 2022-06-27 19:48, Monday
by danadi712
I use another way.
With OpenSuite i open equipment file
Then using button View i see the png file for tank.
Print screen
Using Paint i isolate the central position of the tank
Then save.
I dont understand how do you get the icons
It is a pack of icons in game folder?
Re: Units Positions
Posted: 2022-06-27 20:45, Monday
by randowe
When i need a specific icon i download it from the database from the Open General homepage. To me it is the most comfortable way. But i only need few icons every now and then when i rework them to create new icons.
The icons are stored in openicons.dat file.
But you need to rework thousands of icons and i guess you should try to extract them all at once from the openicons.dat using the icons tool.
But then you have like 15 thousand icons or so. I don't know what is the most efficient way to get only the icons you need
And for example, if you rework all icons from CC3 according to your needs, other CC/efiles may use different or more icons and you then have to rework them too. All of this will take a very long time.
Re: Units Positions
Posted: 2022-06-28 10:40, Tuesday
by danadi712
Ok
When i try to load OpenIcons.dat using OpenGen suite says "No flag loaded" and does nothing.
Any idea why?
Re: Units Positions
Posted: 2022-06-28 13:19, Tuesday
by randowe
Did you use this option when you tried to load the openicons in suite?

Re: Units Positions
Posted: 2022-06-28 16:56, Tuesday
by danadi712
Yes i did and it was loaded.
It gives a file similar with Excel table.
But there is a way to extract all png from that table?
I mean to obtain png like in database from the Icons section on the site.
Re: Units Positions
Posted: 2022-06-28 17:16, Tuesday
by randowe
You need to download the icons tool i mentioned earlier. Download it from Luis' site. For link klick on banner under his post.
With the icons tool you can extract single icons from any dat file you load with the tool. I don't know if it is possible to extract all icons at once, because i never was lookingfor such an option. You have to check it out.
Re: Units Positions
Posted: 2022-06-29 08:53, Wednesday
by danadi712
Ok
Thank you again.