Open Askaholic opened 5 years ago
The java server has a number for all server error messages, if you do the same we can someday translate then all by number
Hm. IDK if I'm a fan of error code numbers, but I can certainly mention them on the github issue if that helps integrate things on the client side.
Had a recent talk at work with a frontend developer at work. He said rather than a "random" error number, we should just use a unique translation key, as he wouldn't need to add an additional mapping from magic number to translation key. Same applies to the client here. We should use translation keys inside the message (if required then in addition to the error id).
@Brutus5000 I disagree: error codes are not only very common but also super easy and 100% fail-safe. The same can't be said about translation keys; they're subject to change, call for a naming convention that will always fall short at some point, they're easy to mess up and once they need to be changed for whatever reason, they're API-breaking. Error codes have none of these issues.
Client issue for FAForever/server#444.
In an effort to improve localization of server events, we should be sending more json descriptions and less English text. Of course this will require the client to handle such messages appropriately.
See the server issue for more details.