View Single Post
05/20/21, 07:49 AM   #2
Baertram
Super Moderator
 
Baertram's Avatar
WoWInterface Super Mod
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 4,989
The following SI_* "constants" (for the function GetString(SI_*) are given in the game and you might use them instead of re-translating values.
If possible.

Code:
"Attack Power", -- SI_DERIVEDSTATS1
    "Weapon and Spell Damage", -- SI_DERIVEDSTATS2
    "Armor Rating", -- SI_DERIVEDSTATS3
    "Max Magicka", -- SI_DERIVEDSTATS4
    "Magicka Recovery", -- SI_DERIVEDSTATS5
    "Magicka Recovery Idle", -- SI_DERIVEDSTATS6
    "Max Health", -- SI_DERIVEDSTATS7
    "Health Recovery", -- SI_DERIVEDSTATS8
    "Health Recovery Idle", -- SI_DERIVEDSTATS9
    "healing received", -- SI_DERIVEDSTATS10
    "Dodge", -- SI_DERIVEDSTATS11
    "Healing Done", -- SI_DERIVEDSTATS12
    "Spell Resist", -- SI_DERIVEDSTATS13
    "Block", -- SI_DERIVEDSTATS14
    "Bleed Resistance", -- SI_DERIVEDSTATS15
    "Weapon Critical", -- SI_DERIVEDSTATS16
    "Mitigation", -- SI_DERIVEDSTATS20
    "Armor", -- SI_DERIVEDSTATS22
    "Spell Critical", -- SI_DERIVEDSTATS23
    "Critical Resist", -- SI_DERIVEDSTATS24
    "Spell Damage", -- SI_DERIVEDSTATS25
    "Spell Mitigation", -- SI_DERIVEDSTATS26
    "Offensive Penetration", -- SI_DERIVEDSTATS27
    "Critical Chance", -- SI_DERIVEDSTATS28
    "Max Stamina", -- SI_DERIVEDSTATS29
    "Stamina Recovery", -- SI_DERIVEDSTATS30
    "Stamina Recovery Idle", -- SI_DERIVEDSTATS31
    "Miss", -- SI_DERIVEDSTATS32
    "Physical Penetration", -- SI_DERIVEDSTATS33
    "Spell Penetration", -- SI_DERIVEDSTATS34
    "Weapon Damage", -- SI_DERIVEDSTATS35
    "Generic Resistance", -- SI_DERIVEDSTATS37
    "Physical Resistance", -- SI_DERIVEDSTATS38
    "Fire Resistance", -- SI_DERIVEDSTATS39
    "Shock Resistance", -- SI_DERIVEDSTATS40
    "Oblivion Resistance", -- SI_DERIVEDSTATS41
    "Cold Resistance", -- SI_DERIVEDSTATS42
    "Earth Resistance", -- SI_DERIVEDSTATS43
    "Magic Resistance", -- SI_DERIVEDSTATS44
    "Drown Resistance", -- SI_DERIVEDSTATS45
    "Disease Resistance", -- SI_DERIVEDSTATS46
    "Poison Resistance", -- SI_DERIVEDSTATS47
    "Mount Stamina", -- SI_DERIVEDSTATS48
    "Mount Stamina Regen Combat", -- SI_DERIVEDSTATS49
    "Mount Stamina Regen Moving", -- SI_DERIVEDSTATS50
e.g. if you need "Physical Resistance" you can use GetString(SI_DERIVEDSTATS38) and it will return the translated value for the base game languages de, en, fr, ru and jp.

The given constants and texts EN can be found here:
https://raw.githubusercontent.com/es...tedstrings.lua

But if you need other translations, like "Spell resistance" which does not exist yet you need to manually translate them.

If you want to have the text with the numbers you have given you can concatenate the text like this:

Health = SI_ATTRIBUTES1
["filtertooltip3"] = "Maximum " .. GetString(SI_ATTRIBUTES1) .." +2225", --returns "Maximum Health +2225"

I'll provide you DE translations in the next post.
  Reply With Quote