Skip to content
Open
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
125 changes: 125 additions & 0 deletions docs/groovy-script/mods/matteroverdrive/android.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,125 @@
---
title: "Android Biotic Stats"
titleTemplate: "MatterOverdrive: Refitted | CleanroomMC"
description: "Tweak Android biotic stats: xp cost, required items, enable/disable."
source_code_link: "https://github.com/Refitbench/MatterOverdrive/blob/master/src/main/java/matteroverdrive/compat/modules/groovyscript/AndroidCompat.java"
---

# Android Biotic Stats

## Description

Controls Matter Overdrive's Android biotic stat tree. Existing
stats can be enabled, disabled, re-priced, or have their unlock requirements
changed.

:::::::::: details Note {open id="note"}
Only stats that extend `matteroverdrive.data.biostats.AbstractBioticStat`
can be mutated through this compat. Mods adding
fully custom `IBioticStat` implementations may not be patchable here.
::::::::::

## Identifier

The identifier `mods.matteroverdrive.android` will be used as the default on this page.

:::::::::: details All Identifiers {open id="quote"}

Any of these can be used to refer to this compat:

```groovy:no-line-numbers {1}
mods.matteroverdrive.android/* Used as page default */ // [!code focus]
```

::::::::::

## Tweaking Stats

- Sets the xp cost to unlock or level up the given stat:

```groovy:no-line-numbers
mods.matteroverdrive.android.setXp(IBioticStat, int xp)
```

- Forces the stat enabled or disabled, overriding config-based rules:

```groovy:no-line-numbers
mods.matteroverdrive.android.enable(IBioticStat)
mods.matteroverdrive.android.disable(IBioticStat)
```

- Adds or clears the required items list for a stat:

```groovy:no-line-numbers
mods.matteroverdrive.android.addRequiredItem(IBioticStat, ItemStack)
mods.matteroverdrive.android.clearRequiredItems(IBioticStat)
```

:::::::::: details Example {open id="example"}
```groovy:no-line-numbers
def shield = androidStat('shield')
mods.matteroverdrive.android.setXp(shield, 50)
mods.matteroverdrive.android.clearRequiredItems(shield)
mods.matteroverdrive.android.addRequiredItem(shield, item('minecraft:iron_ingot') * 8)
mods.matteroverdrive.android.disable(androidStat('cloak'))
```

::::::::::

## Unregistering Stats

- Removes a stat from the registry. This will gray out the ability, and pass through dependants of the stat, if you want the full chain to be removed, unregister all stats individually.

```groovy:no-line-numbers
mods.matteroverdrive.android.unregister(String unlocalizedName)
```

:::::::::: details Example {open id="example"}
```groovy:no-line-numbers
mods.matteroverdrive.android.unregister('cloak')
```

::::::::::

## Object Mapper

The `androidStat` bracket handler resolves an unlocalized name to its
`IBioticStat`:

```groovy:no-line-numbers
androidStat('shield')
androidStat('nightvision')
```

### All Built-in Stat Names

| Name | Description |
|---|---|
| `teleport` | Short-range teleport |
| `nanobots` | Nanobot healing |
| `nano_armor` | Nano-scale armor plating |
| `floatation` | Water/lava flotation |
| `speed` | Movement speed boost |
| `high_jump` | Increased jump height |
| `inertial_dampers` | Fall damage reduction |
| `equalizer` | Spacetime equalizer ability |
| `shield` | Energy shield |
| `auto_shield` | Automatic shield activation |
| `cloak` | Optical cloaking |
| `attack` | Melee damage boost |
| `flash_cooling` | Flash cooling / fire immunity |
| `shockwave` | Melee shockwave burst |
| `nightvision` | Night vision |
| `minimap` | Minimap overlay |
| `step_assist` | Step-up assist |
| `zero_calories` | Zero caloric consumption |
| `oxygen` | Underwater oxygen supply |
| `wireless_charger` | Wireless energy charging |
| `item_magnet` | Item attraction magnet |
| `air_dash` | Mid-air dash |
| `tan_temperature` | Temperature regulation *(Requires Tough As Nails or Simple Difficulty)* |

:::::::::: details Note {open id="note"}
`tan_temperature` is always registered, however it only has an effect when [Tough As Nails](https://www.curseforge.com/minecraft/mc-mods/tough-as-nails)
or [Simple Difficulty](https://www.curseforge.com/minecraft/mc-mods/simple-difficulty) is installed.
::::::::::
18 changes: 18 additions & 0 deletions docs/groovy-script/mods/matteroverdrive/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
---
aside: false
---


# MatterOverdrive: Refitted

## Categories

Has 4 subcategories.

* [Matter Registry](./matter.md)

* [Inscriber](./inscriber.md)

* [Android Biotic Stats](./android.md)

* [Replicator Blacklist](./replicator.md)
138 changes: 138 additions & 0 deletions docs/groovy-script/mods/matteroverdrive/inscriber.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,138 @@
---
title: "Inscriber"
titleTemplate: "MatterOverdrive: Refitted | CleanroomMC"
description: "Add or remove recipes for the Inscriber: two item inputs, one item output, plus energy and time costs."
source_code_link: "https://github.com/Refitbench/MatterOverdrive/blob/master/src/main/java/matteroverdrive/compat/modules/groovyscript/InscriberCompat.java"
---

# Inscriber (MatterOverdrive: Refitted)

## Description

Add or remove inscriber recipes.

## Identifier

The identifier `mods.matteroverdrive.inscriber` will be used as the default on this page.

:::::::::: details All Identifiers {open id="quote"}

Any of these can be used to refer to this compat:

```groovy:no-line-numbers {1}
mods.matteroverdrive.inscriber/* Used as page default */ // [!code focus]
```

::::::::::

## Adding Recipes

### Recipe Builder

Just like other recipe types, the Inscriber uses a recipe builder.

Don't know what a builder is? Check [the builder info page](../../getting_started/builder.md) out.

:::::::::: details Recipe Builder {open id="abstract"}

---

- Create the Recipe Builder.

```groovy:no-line-numbers
mods.matteroverdrive.inscriber.recipeBuilder()
```

---

- `IngredientList<IIngredient>`. Sets the item inputs of the recipe. Requires
exactly 2. The first is treated as the primary input, the second as the
secondary input.

```groovy:no-line-numbers
input(IIngredient)
input(IIngredient...)
input(Collection<IIngredient>)
```

- `ItemStackList`. Sets the item outputs of the recipe. Requires exactly 1.

```groovy:no-line-numbers
output(ItemStack)
```

- `int`. Sets the FE cost. Must be greater than 0. (Default `1000`).

```groovy:no-line-numbers
energy(int)
```

- `int`. Sets the processing time in ticks. Must be greater than 0. (Default `60`).

```groovy:no-line-numbers
time(int)
```

---

- First validates the builder, returning `null` and outputting errors to the log file if the validation failed, then registers the builder and returns the registered object. (returns `null` or `matteroverdrive.data.recipes.InscriberRecipe`).

```groovy:no-line-numbers
register()
```

---

::::::::: details Example {open id="example"}
```groovy:no-line-numbers
mods.matteroverdrive.inscriber.recipeBuilder()
.input(item('minecraft:redstone'))
.input(item('minecraft:gold_ingot'))
.output(item('matteroverdrive:circuit_basic'))
.energy(1000)
.time(80)
.register()
```

:::::::::

::::::::::

## Removing Recipes

- Removes any Inscriber recipe whose output matches the given stack:

```groovy:no-line-numbers
mods.matteroverdrive.inscriber.removeByOutput(ItemStack)
```

- Removes any Inscriber recipe whose primary and secondary input pair match
the given stacks (order matters):

```groovy:no-line-numbers
mods.matteroverdrive.inscriber.removeByInputs(ItemStack main, ItemStack sec)
```

- Removes all registered Inscriber recipes:

```groovy:no-line-numbers
mods.matteroverdrive.inscriber.removeAll()
```

:::::::::: details Example {open id="example"}
```groovy:no-line-numbers
mods.matteroverdrive.inscriber.removeByOutput(item('matteroverdrive:circuit_basic'))
mods.matteroverdrive.inscriber.removeByInputs(item('minecraft:redstone'), item('minecraft:gold_ingot'))
mods.matteroverdrive.inscriber.removeAll()
```

::::::::::

## Getting the value of recipes

- Iterates through every entry in the registry, with the ability to call
remove on any element to remove it:

```groovy:no-line-numbers
mods.matteroverdrive.inscriber.streamRecipes()
```
100 changes: 100 additions & 0 deletions docs/groovy-script/mods/matteroverdrive/matter.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,100 @@
---
title: "Matter Registry"
titleTemplate: "MatterOverdrive: Refitted | CleanroomMC"
description: "Add, remove, or replace the matter value of items and ore-dictionary entries used by the Matter Scanner and Replicator."
source_code_link: "https://github.com/Refitbench/MatterOverdrive/blob/master/src/main/java/matteroverdrive/compat/modules/groovyscript/MatterCompat.java"
---

# Matter Registry (MatterOverdrive: Refitted)

## Description

Controls the matter value assigned to each item and ore-dictionary entry, plus
the per-mod matter calculation blacklist. Matter values determine how much
"matter" the Decomposer extracts from an item and how much it costs to
replicate.

## Identifier

The identifier `mods.matteroverdrive.matter` will be used as the default on this page.

:::::::::: details All Identifiers {open id="quote"}

Any of these can be used to refer to this compat:

```groovy:no-line-numbers {1}
mods.matteroverdrive.matter/* Used as page default */ // [!code focus]
```

::::::::::

## Adding Entries

- Sets the matter value of an item (overwriting any existing value):

```groovy:no-line-numbers
mods.matteroverdrive.matter.add(String itemId, int matter)
mods.matteroverdrive.matter.add(Item item, int matter)
mods.matteroverdrive.matter.add(Item item, IMatterEntryHandler handler)
```

- Sets the matter value of an ore-dictionary entry:

```groovy:no-line-numbers
mods.matteroverdrive.matter.addOre(String oreName, int matter)
mods.matteroverdrive.matter.addOre(String oreName, IMatterEntryHandler handler)
```

:::::::::: details Example {open id="example"}
```groovy:no-line-numbers
mods.matteroverdrive.matter.add('minecraft:gold_ingot', 256)
mods.matteroverdrive.matter.addOre('oreCopper', 32)
```

::::::::::

## Removing Entries

- Removes the matter value for an item or ore-dictionary entry:

```groovy:no-line-numbers
mods.matteroverdrive.matter.remove(String itemId)
mods.matteroverdrive.matter.remove(Item item)
mods.matteroverdrive.matter.removeOre(String oreName)
```

:::::::::: details Example {open id="example"}
```groovy:no-line-numbers
mods.matteroverdrive.matter.remove('minecraft:apple')
mods.matteroverdrive.matter.removeOre('oreTin')
```

::::::::::

## Mod Blacklist

The mod blacklist prevents Matter Overdrive from auto-calculating matter
values for items belonging to the listed mods. Explicit `add()` calls still
work regardless of blacklist status.

- Adds a mod to the matter calculation blacklist:

```groovy:no-line-numbers
mods.matteroverdrive.matter.blacklistMod(String modId)
```

:::::::::: details Example {open id="example"}
```groovy:no-line-numbers
mods.matteroverdrive.matter.blacklistMod('thaumcraft')
```

::::::::::

## Object Mapper

The `matter` bracket handler resolves an item id to its existing
`MatterEntryItem`:

```groovy:no-line-numbers
matter('minecraft:gold_ingot')
```
Loading