-
-
Notifications
You must be signed in to change notification settings - Fork 3
language stuff #123
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
language stuff #123
Conversation
Insprill
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How are map-specific locales supposed to be created? I don't see anything changed on the editor side.
Create locale.csv in the same folder as info,json of the map. For example:
locale.csv
You aren't supposed to ever create the zip manually though, when you build the map from the editor that should be the zip you distribute. There needs to be good editor tooling for creating localizations.
How much work would be involved with switching to the localization library most other mods now use? I think that would be a better route than continuing to reinvent the wheel, assuming it covers all our needs.
(this discussion was originally in a comment on #108)
Yes, that would be ideal. However, that would take more effort to make then I am currently willing to invest in this feature. |
|
How about switching to Language Helper? I haven't worked with it before, so I'm unsure how much work would be involved. If we do that, map creators could then just provide a link to a Google sheet in MapInfo, and we wouldn't have to worry about custom tooling or maintaining our own language implementation. |
|
Fun fact: I was wondering why the you made |
|
Using a MonoBehaviour for this is unnecessary. You can serialize to a string in either XML or JSON and deserialize after importing: |
Eh, but then we'd have to add the JSONObject library. I'd rather keep it as it is for now, it just works™ |
|
You don't need to, you can use the built-in XML serializer, or reference the same package DV already includes (JSONObject is just a wrapper over those for utility I believe). |
|
The MonoBehaviour hack is good when you need references to GameObjects or assets, but since this is simple data, it's easier/more reliable to use Wiz's approach. We already do the json thing for streaming scenes using Unity's dv-mapify/MapifyEditor/Streaming/SceneSplitData.cs Lines 5 to 16 in d1f7d45
dv-mapify/Mapify/Map/MapLifeCycle.cs Lines 266 to 267 in d1f7d45
|
|
It'd be nice to get this merged soon; the only thing blocking is the MonoBehaviour vs JSON thing. I'm more in favor of switching to JSON. Are there any arguments against it, or anything in particular blocking this? |
|
I tried to implement the JSON method, but it didn't work. I could give it another go some time |
|
This branch is borked by build 99.7, needs fixing |

Fixes #107
(This is a reopening of #108)