Skip to content

Commit b595b43

Browse files
committed
cleanup for many articles
1 parent 747ee6b commit b595b43

File tree

5 files changed

+14
-12
lines changed

5 files changed

+14
-12
lines changed

assets/content/cookbook/Advanced/1.HScript.md

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ HScript is extremely similar to Haxe, and provides access to almost all the vari
2424

2525
Many examples of working HScript can be found in Funkin's many script files (with the `.hxc` extenstion), but some easily found ones are stage scripts.
2626

27-
As an example, the Philly Streets script file (`phillyStreets.hxc`)
27+
As an example, the Philly Streets[^philly] script file:
2828

2929
```haxe
3030
// Top of the file
@@ -34,7 +34,7 @@ As an example, the Philly Streets script file (`phillyStreets.hxc`)
3434
import funkin.play.PlayState;
3535
import funkin.play.stage.Stage;
3636
37-
...
37+
// ...
3838
3939
// Line 114
4040
override function onCreate(event:ScriptEvent):Void
@@ -66,9 +66,11 @@ As an example, the Philly Streets script file (`phillyStreets.hxc`)
6666
resetStageValues();
6767
}
6868
69-
...
69+
// ...
7070
```
7171

7272
As you can see, you can basically use HScript like regular haxe, making it ideal for modding Friday Night Funkin'
7373

74+
[^philly]: <https://github.com/FunkinCrew/funkin.assets/blob/main/preload/scripts/stages/phillyStreets.hxc>
75+
7476
> Author: [EliteMasterEric](https://github.com/EliteMasterEric)

assets/content/cookbook/Advanced/7.DialogueCutscenes.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,7 @@ As shown in the previous chapter, we will use the same technique, but this time
147147

148148
```haxe
149149
150-
...
150+
// ...
151151
152152
// Line 30
153153
public override function onCountdownStart(event:CountdownScriptEvent):Void
@@ -172,7 +172,7 @@ As shown in the previous chapter, we will use the same technique, but this time
172172
}
173173
}
174174
175-
...
175+
// ...
176176
177177
// Line 75
178178
function transitionToDialogue()
@@ -216,7 +216,7 @@ As shown in the previous chapter, we will use the same technique, but this time
216216
PlayState.instance.startConversation(targetDialogue);
217217
}
218218
219-
...
219+
// ...
220220
221221
```
222222

assets/content/cookbook/Intermediate/3.CustomStickerPacks.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ You can use the [JSONPatch](../Introduction/5.AppendingAndMerge.md#merging) feat
4747

4848
For example, to add to Boyfriend's standard sticker pack, you can use the following JSON Patch file (placed in `mods/mymod/_merge/data/stickerpacks/standard-bf.json`, use a different file path to patch a different sticker pack):
4949

50-
```jsonc
50+
```json
5151
[
5252
// Add an asset path to the end of the sticker list.
5353
{ "op": "add", "path": "/stickers/-", "value": "path/to/custom/sticker" }

assets/content/cookbook/Intermediate/4.Migration.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ In v0.5.0, the system for merging into JSON files was fundamentally reworked. An
1414

1515
In your mod's `_merge` folder, look for any `json` files and rewrite their contents.
1616

17-
```jsonc
17+
```json
1818
// This is the format used by older versions of the game.
1919
{
2020
"merge": [
@@ -32,7 +32,7 @@ In your mod's `_merge` folder, look for any `json` files and rewrite their conte
3232
}
3333
```
3434

35-
```jsonc
35+
```json
3636
// This is the format which will be used starting with v0.5.0.
3737
[
3838
{ "op": "replace", "path": "/playData/characters/opponent", "value": "monster" }, // Replace the value of opponent with monster.
@@ -58,7 +58,7 @@ Any mods which utilized functions and classes provided by Flixel UI may need ref
5858

5959
Once all the migration steps above have been performed, the last step is to modify your mod's API version string. In your mod's `_polymod_meta.json` file, locate the `"api_version"` property and set it to `"0.5.0"`.
6060

61-
```jsonc
61+
```json
6262
{
6363
// ...
6464

assets/content/cookbook/Introduction/5.AppendingAndMerge.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ We can provide the file `mods/mymod/_append/data/mydata.json`:
4747

4848
And Polymod will mutate it to get this result:
4949

50-
```jsonc
50+
```json
5151
{
5252
// Unreferenced values are untouched.
5353
"test1": [1, 2, 3],
@@ -167,7 +167,7 @@ Say we have a JSON data file `data/songs/mysong-metadata.json` like below:
167167

168168
We can modify the above data with a document `mods/mymod/_merge/data/songs/mysong-metadata.json`:
169169

170-
```jsonc
170+
```json
171171
[
172172
{ "op": "replace", "path": "/playData/characters/opponent", "value": "monster" }, // Replace the value of opponent with monster.
173173
{ "op": "add", "path": "/playData/characters/girlfriend", "value": "nene" }, // Add a new key girlfriend with the value Nene.

0 commit comments

Comments
 (0)