Skip to content

Commit

Permalink
Update packages & optimize docs
Browse files Browse the repository at this point in the history
Signed-off-by: TheRealPear <20259871+TheRealPear@users.noreply.github.com>
  • Loading branch information
TheRealPear committed May 23, 2024
1 parent 16f2b03 commit 4af6a2b
Show file tree
Hide file tree
Showing 65 changed files with 14,776 additions and 14,841 deletions.
4 changes: 4 additions & 0 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ jobs:
steps:
- name: checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: setup
uses: actions/setup-node@v4
with:
Expand All @@ -24,6 +26,8 @@ jobs:
steps:
- name: checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: setup
uses: actions/setup-node@v4
with:
Expand Down
4 changes: 2 additions & 2 deletions docs/examples/airship-battle.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ Every map XML file starts with the XML header and then the base `<map>` module.
```

[<i className="icon-right">➡️</i>](/docs/modules/format/teams)
Define the teams' [colors](/docs/reference/misc/formatting#chatColors), names, and how many people can be on each team.
Define the teams' [colors](/docs/reference/misc/formatting#chat-colors), names, and how many people can be on each team.

```xml
<teams>
Expand Down Expand Up @@ -219,7 +219,7 @@ Stop players from being able to craft specific blocks or items.
</crafting>
```

[<i className="icon-right">➡️</i>](/docs/modules/environment/world/#build-height)
[<i className="icon-right">➡️</i>](/docs/modules/environment/world#build-height)

This specifies how high players can build, however, it does not stop them from walking or breaking blocks above this limit.

Expand Down
4 changes: 2 additions & 2 deletions docs/examples/harb.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ Every map XML file starts with the XML header and then the base `<map>` module.
```

[<i className="icon-right">➡️</i>](/docs/modules/format/teams)
Define the teams' [colors](/docs/reference/misc/formatting#chatColors), names, and how many people can be on each team.
Define the teams' [colors](/docs/reference/misc/formatting#chat-colors), names, and how many people can be on each team.

```xml
<teams>
Expand Down Expand Up @@ -157,7 +157,7 @@ Define the portals that players can walk through.
</portals>
```

[<i className="icon-right">➡️</i>](/docs/modules/objectives/scoring/#time-limit)
[<i className="icon-right">➡️</i>](/docs/modules/objectives/scoring#time-limit)
Set a 10 minute time limit for the map. The team with the most points after time is up wins.

```xml
Expand Down
4 changes: 2 additions & 2 deletions docs/examples/ozone.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ Specify that this is a teamless map, assign each player a random color, and allo
<players min="2" max="80" colors="true"/>
```

[<i className="icon-right">➡️</i>](/docs/modules/objectives/scoring/#time-limit)
[<i className="icon-right">➡️</i>](/docs/modules/objectives/scoring#time-limit)
Set a 10 minute time limit for the map. The player with the most points after time is up wins.

```xml
Expand Down Expand Up @@ -190,7 +190,7 @@ Players do not need to worry about hunger in this map, so hunger is disabled.
</hunger>
```

[<i className="icon-right">➡️</i>](/docs/modules/gear/projectiles/#modifying-bow-projectiles)
[<i className="icon-right">➡️</i>](/docs/modules/gear/projectiles#modifying-bow-projectiles)
This changes the properties of bows to shoot Ender Pearls, making players
able to quickly teleport around the map.

Expand Down
4 changes: 2 additions & 2 deletions docs/examples/race-for-victory.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ Every map XML file starts with the XML header and then the base `<map>` module.
```

[<i className="icon-right">➡️</i>](/docs/modules/format/teams)
Define the teams' [colors](/docs/reference/misc/formatting#chatColors), names, and how many people can be on each team.
Define the teams' [colors](/docs/reference/misc/formatting#chat-colors), names, and how many people can be on each team.

```xml
<teams>
Expand Down Expand Up @@ -240,7 +240,7 @@ how to deal with dropped items more easily.
</itemremove>
```

[<i className="icon-right">➡️</i>](/docs/modules/environment/world/#build-height)
[<i className="icon-right">➡️</i>](/docs/modules/environment/world#build-height)

This specifies how high players can build, however, it does not stop them from walking or breaking blocks above this limit.

Expand Down
4 changes: 2 additions & 2 deletions docs/examples/the-fenland.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ Every map XML file starts with the XML header and then the base `<map>` module.
```

[<i className="icon-right">➡️</i>](/docs/modules/format/teams)
Define the teams' [colors](/docs/reference/misc/formatting#chatColors), names, and how many people can be on each team.
Define the teams' [colors](/docs/reference/misc/formatting#chat-colors), names, and how many people can be on each team.

```xml
<teams>
Expand Down Expand Up @@ -214,7 +214,7 @@ TNT will instantly ignite when placed, players will not need a license, and team
<friendly-defuse>off</friendly-defuse>
</tnt>
```
[<i className="icon-right">➡️</i>](/docs/modules/environment/world/#build-height)
[<i className="icon-right">➡️</i>](/docs/modules/environment/world#build-height)
This specifies how high players can build, however, it does not stop them from walking or breaking blocks above this limit.

```xml
Expand Down
4 changes: 2 additions & 2 deletions docs/examples/warlock.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ Every map XML file starts with the XML header and then the base `<map>` module.
```

[<i className="icon-right">➡️</i>](/docs/modules/format/teams)
Define the teams' [colors](/docs/reference/misc/formatting#chatColors), names, and how many people can be on each team.
Define the teams' [colors](/docs/reference/misc/formatting#chat-colors), names, and how many people can be on each team.

```xml
<teams>
Expand Down Expand Up @@ -247,7 +247,7 @@ Players do not need to worry about hunger in this map, so hunger is disabled.
</hunger>
```

[<i className="icon-right">➡️</i>](/docs/modules/environment/world/#build-height)
[<i className="icon-right">➡️</i>](/docs/modules/environment/world#build-height)
This specifies how high players can build, however, it does not stop them from walking or breaking blocks above this limit.

```xml
Expand Down
5 changes: 2 additions & 3 deletions docs/guides/xml-pointers/applying-to-regions.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@ id: applying-to-regions
title: Using Filters and Regions
---

Regions define areas that can later be applied to [Filters](/docs/modules/mechanics/filters)
and other modules.
Regions define areas that can later be applied to [Filters](/docs/modules/mechanics/filters) and other modules.
Understanding how modules, regions and filters work together is important to make critical mechanics for a map.

## Creating a Filter
Expand All @@ -24,7 +23,7 @@ players on a certain team.

## Creating a Region

Creating a [Region](docs/modules/mechanics/filters) involves certain world coordinates.
Creating a [Region](/docs/modules/mechanics/regions) involves certain world coordinates.
In this example, we will create simple `<cuboid/>` regions inside a `<union>`, which we will save with IDs
which we can reference for later use.

Expand Down
2 changes: 1 addition & 1 deletion docs/guides/xml-pointers/filter-apply-order.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ title: Filter Apply Order

import ImageSwitcher from "@site/src/components/ImageSwitcher.js";

After proto `1.3.3` and above, the order that you [apply](/docs/modules/mechanics/regions#applying) filters to regions affects their behavior.
After proto `1.3.3` and above, the order that you [apply](/docs/modules/mechanics/regions#applying-things-to-regions) filters to regions affects their behavior.
Here is an example.

Let us start out with a basic filter that **denies** everything **except** TNT.
Expand Down
4 changes: 2 additions & 2 deletions docs/modules/blocks/blockdrops.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ Blocks broken by means other than mining or explosions currently do not cause cu
| `region` | <span className="badge badge--secondary" title="Can be either this attribute or a sub-element.">Property</span>The region this rule applies to. | [Region](/docs/modules/mechanics/regions) |
| `kit` | <span className="badge badge--secondary" title="Can be either this attribute or a sub-element.">Property</span>The kit to give players when this rule applies. | [Kit ID](/docs/modules/gear/kits) |
| `experience` | <span className="badge badge--secondary" title="Can be either this attribute or a sub-element.">Property</span>The amount of XP that gets dropped. | <span className="badge badge--primary">Number</span> |
| `replacement` | <span className="badge badge--secondary" title="Can be either this attribute or a sub-element.">Property</span>What to replace the mined block with. | [Single Material Pattern](/docs/reference/items/inventory#material_matchers) | <span className="badge badge--secondary">Air</span> |
| `replacement` | <span className="badge badge--secondary" title="Can be either this attribute or a sub-element.">Property</span>What to replace the mined block with. | [Single Material Pattern](/docs/reference/items/inventory#material-matchers) | <span className="badge badge--secondary">Air</span> |
| `wrong-tool` | <span className="badge badge--secondary" title="Can be either this attribute or a sub-element.">Property</span>Drop items regardless of what tool was used to mine the block. | <span className="badge badge--primary">true/false</span> | false |
| `punch` | <span className="badge badge--secondary" title="Can be either this attribute or a sub-element.">Property</span>Check this rule when a block is punched. | <span className="badge badge--primary">true/false</span> | false |
| `trample` | <span className="badge badge--secondary" title="Can be either this attribute or a sub-element.">Property</span>Check this rule when a block is walked on. | <span className="badge badge--primary">true/false</span> | false |
Expand All @@ -48,7 +48,7 @@ Blocks broken by means other than mining or explosions currently do not cause cu
| `<kit>` | <span className="badge badge--secondary" title="Can be either this attribute or a sub-element.">Property</span>The kit to give players when this rule applies. | [Kits](/docs/modules/gear/kits) |
| `<drops>` | The items which get dropped when a matching block is mined. | [Items](/docs/modules/gear/items)| |
| `<experience>` | <span className="badge badge--secondary" title="Can be either this attribute or a sub-element.">Property</span>The amount of XP that gets dropped. | <span className="badge badge--primary">Number</span> |
| `<replacement>` | <span className="badge badge--secondary" title="Can be either this attribute or a sub-element.">Property</span>What to replace the mined block with. | [Single Material Pattern](/docs/reference/items/inventory#material_matchers) | <span className="badge badge--secondary">Air</span> |
| `<replacement>` | <span className="badge badge--secondary" title="Can be either this attribute or a sub-element.">Property</span>What to replace the mined block with. | [Single Material Pattern](/docs/reference/items/inventory#material-matchers) | <span className="badge badge--secondary">Air</span> |
| `<wrong-tool>` | <span className="badge badge--secondary" title="Can be either this attribute or a sub-element.">Property</span>Drop items regardless of what tool was used to mine the block. | <span className="badge badge--primary">true/false</span> | false |
| `<punch>` | <span className="badge badge--secondary" title="Can be either this attribute or a sub-element.">Property</span>Check this rule when a player in adventure mode punches a block. | <span className="badge badge--primary">true/false</span> | false |
| `<trample>` | <span className="badge badge--secondary" title="Can be either this attribute or a sub-element.">Property</span>Check this rule when a block is walked on. | <span className="badge badge--primary">true/false</span> | false |
Expand Down
6 changes: 3 additions & 3 deletions docs/modules/environment/mobs.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,11 @@ Mob spawns can also be filtered against any other filter type, including regions

| Attributes || Value/Children |
|---|---|---|
| `filter` | <span className="badge badge--secondary" title="Can be either this sub-element or an attribute." >Property</span><span className="badge badge--danger">Required</span>Filter what mobs can spawn when and where. | [Filters](/docs/modules/mechanics/filters) |
| `filter` | <span className="badge badge--secondary" title="Can be either this sub-element or an attribute.">Property</span><span className="badge badge--danger">Required</span>Filter what mobs can spawn when and where. | [Filters](/docs/modules/mechanics/filters) |

| Sub-elements |||
|---|---|---|
| `<filter> </filter>` | <span className="badge badge--secondary" title="Can be either this sub-element or an attribute." >Property</span><span className="badge badge--danger">Required</span>Filter what mobs can spawn when and where. | [Filters](/docs/modules/mechanics/filters) |
| `<filter> </filter>` | <span className="badge badge--secondary" title="Can be either this sub-element or an attribute.">Property</span><span className="badge badge--danger">Required</span>Filter what mobs can spawn when and where. | [Filters](/docs/modules/mechanics/filters) |
</div>

##### Mob Spawning Filter Matchers
Expand All @@ -27,7 +27,7 @@ Mob spawns can also be filtered against any other filter type, including regions
| Element | Description | Value |
|---|---|---|
| `<spawn> </spawn>` | Filter the reason a mob is being spawned. | [Spawn Reason](/docs/reference/entities/spawn-reasons) |
| `<mob> </mob>` | The mob to filter for. | [Creature Type](/docs/reference/entities/entity-types#creatures) |
| `<mob> </mob>` | The mob to filter for. | [Creature Type](/docs/reference/entities/entity-types#creature-types) |
| `<entity> </entity>` | The entity to filter for. | [Entity Type](/docs/reference/entities/entity-types) |
</div>

Expand Down
2 changes: 1 addition & 1 deletion docs/modules/gear/classes.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ Players can then change their class in game with the `/class` command.
| `name` | <span className="badge badge--danger">Required</span>The class's name, must be unique. | <span className="badge badge--primary">String</span> |
| `description` | The description shown in the `/classes` command. | <span className="badge badge--primary">String</span> |
| `longdescription` | The description shown in class picker menu. | <span className="badge badge--primary">String</span> |
| `icon` | <span className="badge badge--danger">Required</span>The icon shown in the class picker menu. | [Single Material Pattern](/docs/reference/items/inventory#material_matchers) |
| `icon` | <span className="badge badge--danger">Required</span>The icon shown in the class picker menu. | [Single Material Pattern](/docs/reference/items/inventory#material-matchers) |
| `family` | <span className="badge badge--danger">Required</span>The "group" of classes. | [Class Family Name](/docs/modules/gear/classes) |
| `sticky` | If set to `true`, players cannot change the class mid-match, instead they must rejoin. | <span className="badge badge--primary">true/false</span> | false |
| `default` | Specify if the class is the default class for new players.<br />*One class must be set as the default.* | <span className="badge badge--primary">true/false</span> | false |
Expand Down
8 changes: 4 additions & 4 deletions docs/modules/gear/crafting.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ Vanilla recipes for a specific material can also be disabled to prevent crafting
| `<shaped>` | A shaped crafting recipe node. | <span className="badge badge--secondary">Shaped Recipe Sub-elements</span> |
| `<shapeless>` | A custom shapeless recipe node. | <span className="badge badge--secondary">Shapeless Recipe Sub-elements</span> |
| `<smelt>` | A custom smelting recipe. | <span className="badge badge--secondary">Smelt Recipe Sub-elements</span> |
| `<disable>` | Disable all vanilla recipes for this item. | [Single Material Pattern](/docs/reference/items/inventory#material_matchers) |
| `<disable>` | Disable all vanilla recipes for this item. | [Single Material Pattern](/docs/reference/items/inventory#material-matchers) |

</div>

Expand Down Expand Up @@ -59,7 +59,7 @@ Blank ingredient spots are specifed with a dot `.`
| Sub-elements | | Value/Children |
|---|---|---|
| `<shape>` | <span className="badge badge--danger">Required</span><span className="badge badge--warning" title="Only one of this child permitted per parent">Unique</span>An ingredient used in this recipe.<br />*Only one shape per recipe is allowed.* | `<row>` |
| `<ingredient>`&#124;`<i>` | <span className="badge badge--danger">Required</span> An ingredient used in this recipe.<br />*A shaped recipe requires at least one ingredient.* | [Single Material Pattern](/docs/reference/items/inventory#material_matchers) |
| `<ingredient>`&#124;`<i>` | <span className="badge badge--danger">Required</span> An ingredient used in this recipe.<br />*A shaped recipe requires at least one ingredient.* | [Single Material Pattern](/docs/reference/items/inventory#material-matchers) |
</div>

##### Shape Sub-elements
Expand Down Expand Up @@ -118,7 +118,7 @@ Unlike a shaped recipe, shapeless recipes do not require that their items are ar

| Sub-elements || Value/Children |
|---|---|---|
| `<ingredient>`&#124;`<i>` | <span className="badge badge--danger">Required</span>An ingredient used in this recipe.<br />*A shapeless recipe requires at least one ingredient.* | [Single Material Pattern](/docs/reference/items/inventory#material_matchers) |
| `<ingredient>`&#124;`<i>` | <span className="badge badge--danger">Required</span>An ingredient used in this recipe.<br />*A shapeless recipe requires at least one ingredient.* | [Single Material Pattern](/docs/reference/items/inventory#material-matchers) |
</div>

#### Shapeless Ingredient attributes
Expand Down Expand Up @@ -152,7 +152,7 @@ Smelt recipes specify what a material gets smelted into in a furnace.

| Sub-elements || Value/Children |
|---|---|---|
| `<ingredient>`&#124;`<i>` | <span className="badge badge--danger">Required</span><span className="badge badge--warning" title="Only one of this child permitted per parent">Unique</span>An ingredient used in this recipe.<br />*A smelt recipe only accepts one ingredient.* | [Single Material Pattern](/docs/reference/items/inventory#material_matchers) |
| `<ingredient>`&#124;`<i>` | <span className="badge badge--danger">Required</span><span className="badge badge--warning" title="Only one of this child permitted per parent">Unique</span>An ingredient used in this recipe.<br />*A smelt recipe only accepts one ingredient.* | [Single Material Pattern](/docs/reference/items/inventory#material-matchers) |
</div>

### Examples
Expand Down
2 changes: 1 addition & 1 deletion docs/modules/gear/item-mods.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ This can be used, for example, to make all gold swords unbreakable or give all i
<div className="table-container">
| Element | Description | Value/Children |
|---|---|---|
| `<material> </material>` | An individual material to match. | [Single Material Pattern](/docs/reference/items/inventory#material_matchers) |
| `<material> </material>` | An individual material to match. | [Single Material Pattern](/docs/reference/items/inventory#material-matchers) |
| `<all-materials/>` | Match all materials. |
| `<all-blocks/>` | Match all block type materials. |
</div>
Expand Down
Loading

0 comments on commit 4af6a2b

Please sign in to comment.