Dotfuscator 删除了 Windows Phone 7 语言支持?

发布于 2024-11-28 11:16:55 字数 311 浏览 2 评论 0原文

我正在为 WP7 开发的 XNA 游戏支持多种语言。然而,在混淆过程中似乎发生了一些事情,这似乎导致语言始终设置为英语(在本例中为默认语言),至少根据 Resource 类是这样。

例如,每个资源包都包含以下定义:

RESOURCE_IDX  ->  #

并且每个资源包都被赋予不同的#。在未混淆的版本中,会根据设备的当前语言提取正确的索引。然而,一旦发生混淆,即使设备设置为西班牙语,Resource 类也会自动选择与英语关联的值。

我在混淆过程中是否缺少导致此问题的设置?

The XNA game that I am working on for WP7 supports multiple languages. However, something seems to be happening during the obfuscation process which seems to cause the language to always be set to English (the default language, in this case), at least according to the Resource class.

For example, each resource pack contains the following definition:

RESOURCE_IDX  ->  #

And each resource pack is given a different #. In an un-obfuscated build, the correct index is pulled out based on the device's current language. However once obfuscation occurs, the Resource class automatically selects the value associated with English even if the device is set to Spanish.

Is there a setting that I'm missing in the obfuscation process that is causing this?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

蝶…霜飞 2024-12-05 11:16:55

看来我的问题与 Resource 类的重命名有关。该类只是一组基于资源包内容自动生成的 getter。不知何故,在混淆过程中对该类进行重命名会导致返回不正确的值(我不会推测原因)。

一旦我阻止该类被重命名,应用程序的其余部分就会按预期工作。

It would appear that my issue was related to the renaming of the Resource class. That class is simply a set of auto-generated getters based on the contents of the resource packs. Somehow, subjecting that class to renaming during obfuscation caused the improper value to be returned (I won't speculate on why).

Once I prevented that class from being renamed, the rest of the application worked as expected.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文