GSE: Sequences, Variables, Macros

GSE: Sequences, Variables, Macros

8M Downloads

Not all variables are translated. -- May need an updated macro from source

zemaree opened this issue ยท 3 comments

commented

Hi Timoty,

i use the italian client.

The traslation works very well for the main part but the macro part (keypressed and keyrelease) is not traslated.

Is this an issue? Or works as intended?

commented

The answer to this is not as easy to answer. The answer is it depends on what is in the variable. KeyPress and KeyRelease in GSE have no meaning beyond they are a label for a variable. A variable itself could be simple text like a list of spells or it could be a bunch of programming that returns a result.

For example a variable could look like:

/cast [mod] something
/targetenemy

it could also look like

function()
    if UnitRace("player") == "Orc" then
        return true
    else
        return false
    end
end

going a step further it could also look like

function()
    if UnitRace("player") == "Orc" then
        return "Bloodfury"
    elseif UnitRace("player") == "Maghar Orc"
        return "Ancestral Something"
    elseif UnitRace("player") == "Troll"
        return "Beserking"   
    end
end

Should the first be translated? probably. Should the last two? Definitely not. The last one, in particular, should look like this:

function()
    if UnitRace("player") == "Orc" then
        return 123435 -- the spellID for Blood Fury
    elseif UnitRace("player") == "Maghar Orc"
        return 146578 -- the spellID for the Maghar Orc Racial
    elseif UnitRace("player") == "Troll"
        return 5467456 -- the spellid for "Beserking"   
    end
end

(Note these spell ID's are not correct and purely for illustration purposes.) This last one will translate as the translation stuff is the last thing to happen to all the commands but the macro author would need to prepare the variable to be like this with the ID's in the first place.

Thats a long answer to say Im not sure what the best answer would be to cater for the different types of things that a variable could hold. GSE doesn't know what is in these. To it all three look the same and are just a collection of bits of text.

commented

If i play on an Italian client The Variable already translates for me and saves the spell ID. You may need to resave your macro as if you have one from before 3.0.25 i think it would not have and may still store the original value.

commented

What I mean by this is if the template was created before #989 was implemented then that template wont translate the variables until it is saved next.