Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dashboard displays %ADJECTIVE% and %ADJ% instead of empire names #90

Closed
chennin opened this issue Dec 19, 2022 · 5 comments
Closed

Dashboard displays %ADJECTIVE% and %ADJ% instead of empire names #90

chennin opened this issue Dec 19, 2022 · 5 comments

Comments

@chennin
Copy link
Contributor

chennin commented Dec 19, 2022

(Pull request coming soon, this is for explanation and documentation)

Stellaris 3.6(?) added %ADJECTIVE% and %ADJ% templates while not adding them to the localisation files (I did verify files on Steam). There is an adj_format which would work for %ADJECTIVE% but not %ADJ%.

image

Here is the save file and an example straight from the save:

Nexitron_2246.06.28.sav.zip

                name={
                        key="%ADJECTIVE%"
                        variables={
                                {
                                        key="adjective"
                                        value={
                                                key="Nexitron"
                                        }
                                }
 {
                                        key="1"
                                        value={
                                                key="Awareness"
                                        }
                                }

                        }
                }

Which should be Nexitron Awareness

And here is a prettified JSON example of both:

{
  "key": "%ADJ%",
  "variables": [
    {
      "key": "1",
      "value": {
        "key": "Allied",
        "variables": [
          {
            "key": "1",
            "value": {
              "key": "%ADJECTIVE%",
              "variables": [
                {
                  "key": "adjective",
                  "value": {
                    "key": "Jing"
                  }
                },
                {
                  "key": "1",
                  "value": {
                    "key": "Systems"
                  }
                }
              ]
            }
          }
        ]
      }
    }
  ]
}

Which should be Allied Jing Systems.

Note how %ADJECTIVE% is in the usual format but %ADJ% doesn't follow the same template format.

@chennin
Copy link
Contributor Author

chennin commented Dec 20, 2022

Oops, here's an UNmodded 3.6.1 save that has the problem (same as just added to #92)

https://github.com/eliasdoehne/stellaris-dashboard/files/10269005/2200.01.01.sav.zip

image

@eliasdoehne
Copy link
Owner

eliasdoehne commented Dec 20, 2022

Right, I actually don't remember that well myself how the name rendering part is implemented, so I'm looking forward to the PR you mentioned but let me know if I can help with that.

This is actually a very interesting topic for another reason, I had a quick look at the localization files and it seems that a lot of in-game text was moved over there, so while the changes break some things for now it creates some very interesting options for the event ledger. It may now be possible to extract anomalies and special project from the save file and render them correctly at runtime with the event description (something like 2050.01.01 - 2050.07.01: Scientist ABC investigated the "Migrating Forests on XYZ" anomaly in the XYZ system or 2010.01.01: The XYZ completed the "Sublight Exploration Probes" event chain). This never worked before because there was no easy way to access them in one place so it would only show up as some technical identifier in the frontend which didn't seem worth the effort.

@chennin
Copy link
Contributor Author

chennin commented Dec 20, 2022

Yup - the PR is #91

@chennin
Copy link
Contributor Author

chennin commented Jan 2, 2023

The save format for leader names changed, and there's another new template. Updating the PR

Problem:

image

OLD:

                name={
                        first_name={
                                key="Golveso"
                        }
                        second_name={
                                key="Selvayn"
                        }
                        use_full_regnal_name=yes
                }

NEW:

                name={
                        full_names={                                                                                                                                                                                                key="%LEADER_2%"
                                variables={
                                        {
                                                key="1"
                                                value={
                                                        key="MAM2_CHR_Sarim"
                                                }
                                        }
 {
                                                key="2"
                                                value={
                                                        key="MAM2_CHR_denAramik"
                                                }
                                        }

                                }
                        }
                        use_full_regnal_name=yes
                }

                        name={
                                full_names={
                                        key="%LEADER_2%"
                                        variables={
                                                {
                                                        key="1"
                                                        value={
                                                                key="Golveso"
                                                        }
                                                }
 {
                                                        key="2"
                                                        value={
                                                                key="Selvayn"
                                                        }
                                                }

                                        }
                                }
                                use_full_regnal_name=yes
                        }

@chennin
Copy link
Contributor Author

chennin commented Jan 2, 2023

Aand I just found %LEADER_1%.

                name={
                        full_names={
                                key="%LEADER_1%"
                                variables={
                                        {
                                                key="1"
                                                value={
                                                        key="HUM4_CHR_Hema"
                                                }
                                        }
 {
                                                key="2"
                                                value={
                                                        key="HUM4_CHR_upAbna"
                                                }
                                        }

                                }
                        }
                        regnal_number=1
                }

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants