Page 3 of 3

Re: Hidden fonctionalities AND ZOOM OUT FUNCTION

Posted: Tue Jan 30, 2018 2:41 pm
by GabeKnight
maitrebongo wrote:Hi,

Just zoom in... And you'll see it again ;)
Thanks for trying, but even with zooming, you still won't be able to see the health points of these units or the attack prognoses. Of course, you can work around it by zooming REAL close or hovering your mouse over the enemy unit to see its strength points, but it's tiresome and takes too much time, as I'd have to constantly zoom in and out on different locations on the map.
See screenshot: above "sefault", below "modded" and "modded zoomed in"
ZoomEdges2.jpg
ZoomEdges2.jpg (866.39 KiB) Viewed 2360 times

Re: Hidden fonctionalities AND ZOOM OUT FUNCTION

Posted: Tue Jan 30, 2018 3:54 pm
by Horst
Sounds like I wasn't too wrong with my comment that typos often work in games; or at least as intended. :P

No idea if it's related to this zooming, but I noticed some strange pink color-shifts of rivers on winter maps while zooming. Seeing pink colors could also have other reasons though. :D

Re: Hidden fonctionalities AND ZOOM OUT FUNCTION

Posted: Tue Jan 30, 2018 4:17 pm
by GabeKnight
Horst wrote:Sounds like I wasn't too wrong with my comment that typos often work in games; or at least as intended. :P
As said, a professional :) .
I'm wondering if there may be a missing option for adjusting the map layout in that text file, though, like "defaultMapBorder=xxx", to adjust it. That could have been the reason for discarding the viariables.txt with an intended flaw after all. But that's just speculation.
Horst wrote:No idea if it's related to this zooming, but I noticed some strange pink color-shifts of rivers on winter maps while zooming. Seeing pink colors could also have other reasons though. :D
Oh thank god, so it's not my weed... :wink:

Re: Hidden fonctionalities AND ZOOM OUT FUNCTION

Posted: Tue Jan 30, 2018 4:42 pm
by Horst
It's possible that more variables can be added in this file. No idea what external settings are all supported.
I'd love to edit the RP cost of bombard, mines and such abilities too somewhere.

By just browing the Assembly-CSharp and other dll-files, I see here following keywords about zoom:
zoomActive
defaultZoomLevel
defaultMinZoom
defaultMaxZoom
defaultMaxZoomEditor
maxZoom
minZoom
zoomLevel
totalZoomChange
zoomPercentage
zoomSpeed
zoom
zoomChange
SetCameraZoom
GetCameraZoom
fovZoomFactor
...

I know from other unity-engine games, that you can already do quite same game-changes in the Assembly-CSharp file. Game mechanic formulas could also be stored there and what not else. I still don't really have the proper tools or know-how to do changes there without tutorials either.

Re: Hidden fonctionalities AND ZOOM OUT FUNCTION

Posted: Tue Jan 30, 2018 5:23 pm
by Horst
Okay, after downloading and installing the freely available JustDecompile tool, I've browsed the Assembly-CSharp.dll file.
There are indeed hardcoded settings like minelaying-cost/cooldown and many other variables and functions there, but it doesn't look like there are more settings available for Data/variables.txt that we already see there:

Code: Select all

public static void ReadVariables()
    {
        StreamReader streamReader = new StreamReader(App.TryModPath("Data/variables.txt"));
        while (!streamReader.EndOfStream)
        {
            string str = streamReader.ReadLine();
            if (!(str != string.Empty) || str.Length <= 2 || str.StartsWith("//"))
            {
                continue;
            }
            string[] strArrays = str.Split(new char[] { "="[0] });
            if (strArrays[0].Trim() == "landMaxSize")
            {
                Map.landMaxSize = float.Parse(strArrays[1]);
            }
            else if (strArrays[0].Trim() == "landMinSize")
            {
                Map.landMinSize = float.Parse(strArrays[1]);
            }
            else if (strArrays[0].Trim() == "airMaxSize")
            {
                Map.airMaxSize = float.Parse(strArrays[1]);
            }
            else if (strArrays[0].Trim() == "airMinSize")
            {
                Map.airMinSize = float.Parse(strArrays[1]);
            }
            else if (strArrays[0].Trim() == "infantryMaxSize")
            {
                Map.infantryMaxSize = float.Parse(strArrays[1]);
            }
            else if (strArrays[0].Trim() == "infantryMinSize")
            {
                Map.infantryMinSize = float.Parse(strArrays[1]);
            }
            else if (strArrays[0].Trim() == "navalMaxSize")
            {
                Map.navalMaxSize = float.Parse(strArrays[1]);
            }
            else if (strArrays[0].Trim() == "navalMinSize")
            {
                Map.navalMinSize = float.Parse(strArrays[1]);
            }
            else if (strArrays[0].Trim() == "largeScaleFactor")
            {
                Map.largeScaleFactor = float.Parse(strArrays[1]);
            }
            else if (strArrays[0].Trim() == "defaultZoomLevel")
            {
                CameraControl.defaultZoomLevel = int.Parse(strArrays[1]);
            }
            else if (strArrays[0].Trim() == "defaultMinZoom")
            {
                CameraControl.defaultMinZoom = int.Parse(strArrays[1]);
            }
            else if (strArrays[0].Trim() == "defaultMaxZoom")
            {
                CameraControl.defaultMaxZoom = int.Parse(strArrays[1]);
            }
            else if (strArrays[0].Trim() != "defaultMaxZoomEditor")
            {
                if (strArrays[0].Trim() != "terrainTextureSize")
                {
                    continue;
                }
                Map3DGenerator.tileSize = float.Parse(strArrays[1]);
            }
            else
            {
                CameraControl.defaultMaxZoomEditor = int.Parse(strArrays[1]);
            }
        }
        streamReader.Close();
    }
It's theoretically still possible to add further variables though with proper compiling tool and coding knowledge of course. That's above my league.

Re: Hidden fonctionalities AND ZOOM OUT FUNCTION

Posted: Tue Jan 30, 2018 6:02 pm
by GabeKnight
And it's really just the "defaultMaxZoom" value messing things up, one can change the others, like "defaultMinZoom", without the border thing happening.

Reading further, I'd say, I'm looking for one of these values within the "CheckScrollLimits" procedure: visTop; visBot; visHorTop; visHorBot. But I'll stop there, too much code stuff.
Still, a pity. :?

Re: Hidden fonctionalities AND ZOOM OUT FUNCTION

Posted: Mon Feb 05, 2018 12:18 am
by GabeKnight
Found this:
adherbal wrote:Shift + C to open console, then type
#videomode on

Note this this will also hide damage numbers and the camera will no longer automatically focus on AI unit actions.

To reverse the effect:
#videomode off
Nice. Quite the workaround, to be honest, but at least there's a possibility to turn off the UI. And this could be great for screenshots !!!