Skip to content

Commit

Permalink
feat(docs): Update misc section
Browse files Browse the repository at this point in the history
  • Loading branch information
ChampionAsh5357 committed Oct 15, 2024
1 parent be95a9f commit 5785aa4
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 5 deletions.
7 changes: 6 additions & 1 deletion docs/misc/config.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,12 @@ A configuration can be created using a subtype of `IConfigSpec`. NeoForge implem
//Define a field to keep the config and spec for later
public static final ExampleConfig CONFIG;
public static final ModConfigSpec CONFIG_SPEC;


private ExampleConfig(ModConfigSpec.Builder builder) {
// Define properties used by the configuration
// ...
}

//CONFIG and CONFIG_SPEC are both built from the same builder, so we use a static block to seperate the properties
static {
Pair<ExampleConfig, ModConfigSpec> pair =
Expand Down
6 changes: 3 additions & 3 deletions docs/misc/debugprofiler.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,9 @@ Here is a small explanation of what each part means:
The Debug Profiler has basic support for `Entity` and `BlockEntity`. If you would like to profile something else, you may need to manually create your sections like so:

```java
ProfilerFiller#push(yourSectionName : String);
Profiler.get().push("yourSectionName");
//The code you want to profile
ProfilerFiller#pop();
Profiler.get().pop();
```
You can obtain the `ProfilerFiller` instance from a `Level`, `MinecraftServer`, or `Minecraft` instance.

Now you just need to search the results file for your section name.
2 changes: 1 addition & 1 deletion docs/misc/gametest.md
Original file line number Diff line number Diff line change
Expand Up @@ -249,7 +249,7 @@ There must be no spaces in-between namespaces; otherwise, the namespace will not
The Game Test Server is a special configuration which runs a build server. The build server returns an exit code of the number of required, failed Game Tests. All failed tests, whether required or optional, are logged. This server can be run using `gradlew runGameTestServer`.

<details>
<summary>Important infromation on NeoGradle</summary>
<summary>Important information on NeoGradle</summary>

:::caution
Due to a quirk in how Gradle works, by default, if a task forces a system exit, the Gradle daemon will be killed, causing the Gradle runner to report a build failure. NeoGradle sets by default a force exit on run tasks such that any subprojects are not executed in sequence. However, as such, the Game Test Server will always fail.
Expand Down

1 comment on commit 5785aa4

@neoforged-pages-deployments
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Deploying with Cloudflare Pages

Name Result
Last commit: 5785aa4bcc8b77b89dd1495814d3b05c784428dd
Status: ✅ Deploy successful!
Preview URL: https://6a1a6e07.neoforged-docs-previews.pages.dev
PR Preview URL: https://pr-178.neoforged-docs-previews.pages.dev

Please sign in to comment.