You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/modding/suitmodding/addinglocals copy.mdx
+49-34Lines changed: 49 additions & 34 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -19,17 +19,23 @@ import Tooltip from './tooltip';
19
19
/>
20
20
throughout the tutorial to explain any tricky terms as you encounter them.
21
21
22
-
<Tooltiptext={<><strong>Key terms</strong><spanclassName="icon-alert"></span></>}tooltip="These will need the most attention" /> are marked with an exclamation icon when they're necessary. <Tooltiptext={<italics>Hover over almost any</italics>}tooltip="almost" /> **bold**term for a quick explanation. Highlighted terms become easier to understand over the course of the tutorial.
22
+
<Tooltiptext={<><strong>Key terms</strong><spanclassName="icon-alert"></span></>}tooltip="These will need the most attention" /> are marked with an exclamation icon when they're first introduced. <Tooltiptext={<italics>Not everything</italics>}tooltip="like this one" /> in **bold**is a tooltip. Keyterms become easier to understand over the course of the tutorial.
23
23
24
24
>Explore the tooltips as needed for clarification
25
25
:::
26
26
</details>
27
27
28
28
### **1. Finding Your LOCR**
29
29
*We first need to locate where the text files are using their 'unique identifiers' called a* <Tooltiptext={<><strong>HASH</strong><spanclassName="icon-alert"></span></>}tooltip="A unique identifier that acts as the address or coordinates for a game file." />.
30
+
<details>
31
+
32
+
<summary>Help: HASH?</summary>
30
33
31
-
>It's an assembly path (ring any bells?) that's been converted into code.
34
+
>Hashes are basically assembly paths converted into code.
32
35
36
+
They are the specific addres of a game file and are easier to work with because of their size compared to full assembly paths.
37
+
38
+
</details>
33
39
*Let's find the text by locating where it's stored:*
34
40
#### Identify your LOCR
35
41
Below are some of the <Tooltiptext={<strong>HASH</strong>}tooltip="A unique identifier that acts as the address or coordinates for a file." /> for the suits:
@@ -46,7 +52,7 @@ import Tooltip from './tooltip';
46
52
<details>
47
53
<summary>**Advanced search guide**</summary>
48
54
49
-
*This guide will learn you how to find any text inside their respective LOCR files*
55
+
*This guide will teach you how to find ***any text*** with their respective LOCR files*
50
56
51
57
52
58
1. Click on the <Tooltiptext={<><strong>Advanced Search Tab</strong><spanclassName="icon-alert"></span></>}tooltip="A tab in GlacierKit for performing extended searches. It has a magnifying glass icon and, is like all other tabs, on the left side." />
@@ -117,15 +123,16 @@ Example of a Suit's Name line in a LOCR File:
117
123
```
118
124
- The **string**: `989928F2-06D6-42F3-871A-353F07DEF969_LEGACY_HERO_BLOODMONEYSUIT_M_HPA2293_NAME_`
119
125
- The **text**: `Blood Money Suit`
126
+
>Each text you see in game are hold by these "strings" just like the HASHes for game files. They are their 'unique identifiers'
120
127
</details>
121
128
122
129
---
123
130
124
131
### **3. MANIFESTING OUR TEXT**
125
-
*We will recreate the structure of a LOCR file in the manifest to replace the text*
126
-
>Want to dive deeper into how that works? See the LOCR breakdown below.
132
+
*Now, we will recreate the structure of the LOCR file in the manifest to replace the text in game*
133
+
>Want to dive deeper into how that works? See the breakdown below.
127
134
<details>
128
-
<summary>LOCR breakdown</summary>
135
+
<summary>*LOCR breakdown*</summary>
129
136
130
137
Let's take a closer look at a simplified LOCR file to understand how it's set up:
131
138
@@ -160,12 +167,12 @@ Looking carefully at the Syntax of a LOCR file, we can see:
160
167
>*We will recreate this structure in the manifest to replace the text, similar to how we handled blobsfolders.*
161
168
162
169
</details>
163
-
-**Open Your Manifest**: Navigate to your manifest file.
170
+
-**Open Your Manifest**: Navigate to your manifest file from the 'Files' Tab in GlacierKit
164
171
- Add this line: `"localisationOverrides": {}`
165
172
>Either copy it or type it in manually
166
173
167
174
:::tip using "suggestions"
168
-
*Learn to use the* <Tooltiptext={<><strong>suggestions feauture</strong><spanclassName="icon-alert"></span></>}tooltip="This feauture is only supported in Glacierkit or in VS code with a schema." />.
175
+
*Learn to type with the* <Tooltiptext={<><strong>suggestions feauture</strong><spanclassName="icon-alert"></span></>}tooltip="This feauture is only supported in Glacierkit or in VS code with a schema." />.
169
176
>Suggestions will show up as soon as you type a **quote**`"`
170
177
171
178
It will auto-complete most of the tedious functions in the steps to follow like:
@@ -177,7 +184,7 @@ It will auto-complete most of the tedious functions in the steps to follow like:
177
184
178
185
179
186
:::
180
-
- Add your LOCR HASH and a language array:
187
+
- Add your <Tooltiptext={<strong>LOCR HASH</strong>}tooltip="The code that appeared on top when you clicked on the LOCR File" /> and a language array:
181
188
```json
182
189
"localisationOverrides": {
183
190
"yourLOCRhash": {
@@ -208,16 +215,19 @@ It will auto-complete most of the tedious functions in the steps to follow like:
208
215
*We can't use a string directly in the manifest before we convert it into a* <Tooltiptext={<><strong>decimal number</strong><spanclassName="icon-alert"></span></>}tooltip="A string converted into a numeral form" />
209
216
210
217
To do that, you first have to:
211
-
-**Open the** <Tooltiptext={<><strong>Text Tools tab</strong><spanclassName="icon-alert"></span></>}tooltip="A tab in GlacierKit that provides tools for converting text and hashes for game modifications." />:
218
+
-**Open the** <Tooltiptext={<><strong>Text Tools tab</strong><spanclassName="icon-alert"></span></>}tooltip="A tab in GlacierKit that provides tools for converting text and hashes for game modifications." />
212
219
-**Paste Your String**:
213
220
>Use the <Tooltiptext={<><strong>Localisation Hash Calculator</strong><spanclassName="icon-alert"></span></>}tooltip="A tool that converts your string into a format the manifest can use, generating both hex and decimal codes." /> box to convert the string.
214
221
215
-
-**Copy the** <Tooltiptext={<strong>Decimal number</strong>}tooltip="A string converted into a numeral form" />: You'll have to use this instead of the long string.
216
-
-**Add decimal and New Text**: Return to your manifest and paste the new decimal with your custom text.
222
+
-**Copy theDecimal number**: You'll have to use this instead of the long string.
223
+
217
224
:::tip Clipboard
218
225
Use <Tooltiptext={<strong>Windows clipboard</strong>}tooltip="A built-in tool that stores multiple copied items." /> (`Windows + V`) to keep track of multiple copied code simultaneously.
219
226
>*Try making it a habit to paste using `Windows + V` instead of `Ctrl + V`.*
220
227
:::
228
+
229
+
-**Add decimal and New Text**: Return to your manifest and paste the <Tooltiptext={<strong>new decimal</strong>}tooltip="A string converted into a numeral form" /> with your custom text.
>“The steps below are optional but recommended for a more complete mod.”
249
+
You’ve successfully replaced the suit name and description in the game with your own custom text. Now, when you load up the game, your new text will appear in place of the default one.
250
+
>The steps below are optional but recommended for a more complete mod.
239
251
:::
240
252
241
253
@@ -247,11 +259,11 @@ We the best, next time the lorem ipsums
247
259
248
260
### 4. (Optionally) Change the Description
249
261
250
-
*To replace the description of your suit:*
262
+
*To replace the description of your suit as well:*
251
263
252
-
- Head back to your LOCR file
253
-
- Find and convert <Tooltip text={<strong>the string of suit's description</strong>} tooltip="Usually right below the string of your suit's name" />
254
-
- add the <Tooltip text={<strong>decimal</strong>} tooltip="A string converted into a numeral form" /> to your manifest.
264
+
- Head back to your <Tooltip text={<strong>LOCR File</strong>} tooltip="A file that holds game text in different languages, linked by unique 'strings'." />
265
+
- Find and convert <Tooltip text={<strong>the string of suit's description</strong>} tooltip="Usually right below the string of your suit's name" /> using Text Tools
266
+
- add the new <Tooltip text={<strong>decimal</strong>} tooltip="A string converted into a numeral form" /> to your manifest.
255
267
>Full example of a suit mod:
256
268
```json
257
269
"localisationOverrides": {
@@ -268,16 +280,16 @@ We the best, next time the lorem ipsums
268
280
<details>
269
281
270
282
271
-
<summary>More language</summary>
283
+
<summary>More language Support</summary>
272
284
273
285
### 5. (Optionally) Add more languages
274
286
#### Same Strings:
275
-
*Strings* are the same in each <Tooltiptext={<><strong>language array</strong><spanclassName="icon-alert"></span></>}tooltip="A single language array in a LOCR file consisting of strings" />
276
-
>*This will make adding languages for each entry very easy.*
287
+
To have your mod support more languages for users, you will need to make new <Tooltiptext={<><strong>language arrays</strong><spanclassName="icon-alert"></span></>}tooltip="A single language array consisting of strings holding text" />
288
+
277
289
278
290
279
-
To have your mod support more languages, simply:
280
-
- make another <Tooltiptext={<strong>language bracket</strong>}tooltip="A single language array that can contain multiple entries of strings each attached to text you see in-game" />
291
+
To add more languages, simply:
292
+
- make another <Tooltiptext={<strong>language bracket</strong>}tooltip="A single language array that can contain multiple entries of strings" />
281
293
- add the <Tooltiptext={<strong>same decimal</strong>}tooltip="A string converted into a numeral form" /> with your text
282
294
283
295
@@ -295,13 +307,15 @@ Example of a new language line:
295
307
}
296
308
}
297
309
```
310
+
>***Strings****are the same in each language array, making adding languages very easy in the manifest as well.*
298
311
299
-
:::info language codes
312
+
:::warning language codes
300
313
- The reason why `french` is used here and not `français` is because the manifest's <Tooltiptext={<strong>schema</strong>}tooltip="A structure used to validate and provide auto-completion for your manifest, helping you write error-free code." /> is coded in English.
301
314
- As for why it doesn't use the same <Tooltiptext={<strong>language codes</strong>}tooltip="The language identifiers in each language array of a LOCR file" /> as the actual <Tooltiptext={<strong>LOCR Files</strong>}tooltip="A file that holds game text in different languages, linked by unique 'strings'." /> like `en` or `fr`, is because the manifest's schema is coded like that.
302
315
303
-
To see how all languages have to be written down in the <Tooltiptext={<strong>manifest</strong>}tooltip="A file in your mod folder that holds important information and can execute code" />, see the <Tooltiptext={<strong>documentation in SMF</strong>}tooltip="It's the book icon on the left after enabling developer mode." />.
304
-
Or *expand below*
316
+
To see how all languages have to be written down in the manifest, see the
317
+
- <Tooltiptext={<><strong>documentation in SMF</strong><spanclassName="icon-alert"></span></>}tooltip="It's the book icon on the left after enabling developer mode in SMF." />.
318
+
- Or *expand* the tab below
305
319
<details>
306
320
<summary>All languages Codes</summary>
307
321
@@ -326,16 +340,17 @@ Or *expand below*
326
340
327
341
328
342
<details>
329
-
<summary>More locr?</summary>
343
+
<summary>More LOCR files</summary>
330
344
### Adding More LOCR Files
331
345
332
346
*If you need to modify more* <Tooltiptext={<strong>LOCR Files</strong>}tooltip="A file that holds game text in different languages, linked by unique 'strings'." />:
333
347
334
-
1.**Insert a Comma**: After your previous <Tooltiptext={<strong>LOCR Array</strong>}tooltip="an array in the manifest resembling the game's LOCR file syntax" /> in the <Tooltiptext={<strong>manifest</strong>}tooltip="A file in your mod folder that holds important information and can execute code" />.
335
-
2.**Repeat [the steps from start](#1-identify-your-locr)** (or continue here)
336
-
2.**Add a New** <Tooltiptext={<strong>LOCR Array</strong>}tooltip="an array in the manifest resembling the game's LOCR file syntax" />: Use the same structure, making sure to follow the <Tooltiptext={<strong>syntax rules</strong>}tooltip="A set of rules that define how code is written and organized." />.
348
+
1.**Insert a Comma** after your previous <Tooltiptext={<><strong>LOCR Array</strong><spanclassName="icon-alert"></span></>}tooltip="an array in the manifest resembling the game's LOCR file" /> in the manifest
349
+
2.**Repeat [the steps from start](#1-finding-your-locr)** (or continue here)
350
+
2.**Add a NewLOCR Array**: Add your LOCR's <Tooltiptext={<strong>HASH</strong>}tooltip="A unique identifier that acts as the address or coordinates for a file." /> and make new language array(s) as needed
337
351
3. <Tooltiptext={<strong>Repeat the Conversion</strong>}tooltip="Using the Localisation Hash calculator" />: Use <Tooltiptext={<strong>Text Tools</strong>}tooltip="A tab in GlacierKit that provides tools for converting text and hashes for game modifications." /> again to convert any new <Tooltiptext={<strong>strings</strong>}tooltip="A key that links to text in the LOCR File" /> into <Tooltiptext={<strong>decimals</strong>}tooltip="A string converted into a numeral form" />.
338
-
4.**Update the** <Tooltiptext={<strong>manifest</strong>}tooltip="A file in your mod folder that holds important information and can execute code" />: Add the new language entries, keeping everything consistent.
352
+
4.**Update the** <Tooltiptext={<strong>manifest</strong>}tooltip="A file in your mod folder that holds important information and can execute code" />: Add the new decimals and your new text.
353
+
>Remember the<Tooltiptext={<strong>syntax rules</strong>}tooltip="A set of rules that define how code is written and organized." /> and to keep your manifest clean and organized to avoid errors.
339
354
340
355
Example of every aspect from this tutorial applied:
0 commit comments