BuildCraft|Core

BuildCraft|Core

7M Downloads

More flexible gate localisation

SpaceToad opened this issue ยท 8 comments

commented

String.format has support for ordered parameters:

String.format("%3$s %2$s %1$s %2$s", "a", "b", "c");

Output: c b a b

In other words Italians can use something like this:
gate.name=%2$s Gate %1$s

Nothing required.

commented

Ok, I'll try that.
If you don't mind I'll change the readme to let other translaters know this.

commented

Provided that the BC code already provides this level of support :-) Otherwise, changing the calls to String.format is not a big deal.

commented

@SpaceToad
GateDefinition.java:

...
            return String.format(StringUtils.localize("gate.name"), StringUtils.localize("gate.material." + material.getTag()),
                    StringUtils.localize("gate.logic." + logic.getTag()));

BC code already provides this level of support :)
You can close this.

commented

Cool then. Thanks guys :-)

commented

Thanks a lot for the info :D

commented

Just want to confirm that this work.

commented

Thanks for the confirmation @TheVikingWarrior!