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

Extract use actions of gun items for translation #71333

Merged
merged 1 commit into from
Jan 29, 2024

Conversation

BrettDong
Copy link
Member

Summary

None

Purpose of change

menu_text and msg in use_action embedded in GUN JSON definition is not translated.

{
    "id": "compbow",
    "looks_like": "longbow",
    "type": "GUN",
    "symbol": "(",
    "color": "yellow",
    "name": { "str": "compound hunting bow" },
    "use_action": {
      "menu_text": "Tighten Limbs", // <---
      "type": "transform",
      "target": "compbow_high",
      "qualities_needed": { "SCREW_FINE": 1 },
      "msg": "You tighten the limbs, increasing the strength of the bow.", // <---
      "ammo_scale": 0
    }
}

Describe the solution

Update string extractor script.

Describe alternatives you've considered

Testing

These text now appear in the generated translation template.

#. ~ "menu_text" action message of item "compound hunting bow"
#. ~ "menu_text" action message of item "compound hunting bow (low)"
#: data/json/items/ranged/archery.json
msgid "Tighten Limbs"
msgstr ""

#. ~ "msg" action message of item "compound hunting bow"
#. ~ "msg" action message of item "compound hunting bow (low)"
#: data/json/items/ranged/archery.json
msgid "You tighten the limbs, increasing the strength of the bow."
msgstr ""

Additional context

@github-actions github-actions bot added Translation I18n Items: Ammo / Guns Ammunition for all kinds of weapons and these weapons themselves [Python] Code made in Python astyled astyled PR, label is assigned by github actions json-styled JSON lint passed, label assigned by github actions labels Jan 29, 2024
@BrettDong BrettDong added <Bugfix> This is a fix for a bug (or closes open issue) 0.H Backport PR to backport to the 0.H stable release canddiate labels Jan 29, 2024
@akrieger akrieger merged commit a60d1e4 into CleverRaven:master Jan 29, 2024
22 checks passed
@github-actions github-actions bot added the BasicBuildPassed This PR builds correctly, label assigned by github actions label Jan 29, 2024
@BrettDong BrettDong deleted the translate-gun-use-action branch January 30, 2024 02:01
@Procyonae Procyonae mentioned this pull request May 16, 2024
dseguin added a commit that referenced this pull request May 16, 2024
@Procyonae Procyonae added 0.H Backported and removed 0.H Backport PR to backport to the 0.H stable release canddiate labels May 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
0.H Backported astyled astyled PR, label is assigned by github actions BasicBuildPassed This PR builds correctly, label assigned by github actions <Bugfix> This is a fix for a bug (or closes open issue) Items: Ammo / Guns Ammunition for all kinds of weapons and these weapons themselves json-styled JSON lint passed, label assigned by github actions [Python] Code made in Python Translation I18n
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants