diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml index 4b420e24..910576f0 100644 --- a/.github/ISSUE_TEMPLATE/config.yml +++ b/.github/ISSUE_TEMPLATE/config.yml @@ -1,5 +1,5 @@ -blank_issues_enabled: false +blank_issues_enabled: true contact_links: - name: Mod issues - url: https://github.com/Seniorendi/AdvancedPeripherals/issues + url: https://github.com/IntelligenceModding/AdvancedPeripherals/issues about: Please report bugs at the advanced peripherals repository. This repository is for documentation only. diff --git a/.gitignore b/.gitignore index dc81e498..930205d4 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,4 @@ site/ -.idea \ No newline at end of file +.idea +.cache/ +.DS_Store diff --git a/README.md b/README.md index 130f8ed6..75302587 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@
-[![Project](https://img.shields.io/badge/Project-2E9CFF?style=for-the-badge&logoColor=white&logo=Github)](https://github.com/SirEndii/AdvancedPeripherals) +[![Project](https://img.shields.io/badge/Project-2E9CFF?style=for-the-badge&logoColor=white&logo=Github)](https://github.com/IntelligenceModding/AdvancedPeripherals) ![Netlify Status](https://img.shields.io/website?down_color=red&down_message=offline&label=Netlify%28Host%29&style=for-the-badge&up_color=green&up_message=online&url=https%3A%2F%2Fadvancedperipherals.netlify.app&logoColor=white&logo=Netlify) [![Discord](https://img.shields.io/discord/734726882058174486?label=Discord&style=for-the-badge&color=7289da&logoColor=white&logo=Discord)](https://discord.intelligence-modding.de/) diff --git a/docs/changelogs/0.7.24r.md b/docs/changelogs/0.7.24r.md deleted file mode 100644 index c1a805ba..00000000 --- a/docs/changelogs/0.7.24r.md +++ /dev/null @@ -1,93 +0,0 @@ ---- -hide: - - toc ---- - -# Changelog 1.18.2-0.7.24r / 1.19.3-0.7.23b - -## Table of Contents - -1. [Item/Fluid Filter](#itemfluid-filter) -2. [Inventory manager](#inventory-manager) -3. [ME and RS Bridge](#me-and-rs-bridge) - -
- -The 0.7.24r update brings some changes to our inventory system. -All major and breaking changes are listed here to help with updating your scripts. - -### Item/Fluid Filter - -You may know that we use tables to filter for items for some of our inventory transferring functions. This system got a rework and is now used for more functions but also got some syntax changes. - -Fluids also now use a filter system. - -The following keys got removed: -- `json` -- `tag` - -The `nbt` key now uses json typed nbt values like `{nbt="{StoredEnchantments: [{lvl: 2s, id: \"minecraft:blast_protection\"}]}"}` - -The `name` key can now search for tags. -``` lua -{ - name="#minecraft:wool" -- searches for the wool tag - -- OR - name="#forge:ores/gold" -- searches for the forge gold tag - -- OR - name="minecraft:white_wool" -- searches for white wool -} -``` - -You CAN NOT search for multiple items/tags at once. - -Item Filters can filter for slots with `toSlot` and `fromSlot`. - -You can find the new filter documentation [here](/guides/filters) - -
- -### Inventory manager - -The following functions got deprecated: - -- `removeItemFromPlayer(direction: string, count: int[, slot: int, item: string])` - -- `addItemToPlayer(direction: string, count: int[, slot: int, item: string])` - -- `removeItemFromPlayerNBT(direction: string, count: int[, slot: int, item: table])` - -- `addItemToPlayerNBT(direction: string, count: int[, slot: int, item: table])` - -These will be replaced in the next major update with the following two functions: - -- `removeItemFromPlayer(direction: direction, string: table)` - -- `addItemToPlayer(direction: string, item: table)` - -The following functions now use the new [filter](/guides/filters) system: - -- `removeItemFromPlayerNBT(direction: string, count: int[, slot: int, item: filter])` - -- `addItemToPlayerNBT(direction: string, count: int[, slot: int, item: filter]))` - -
- -### ME and RS Bridge - -Added the following functions to the me bridge: - -- `getTotalItemStorage` -- `getTotalFluidStorage` -- `getUsedItemStorage` -- `getUsedFluidStorage` -- `getAvailableItemStorage` -- `getAvailableFluidStorage` -- `listCells` -- `isConnected` - -More functions now return a Method Result. This means they're capable to report errors if something wrong. For more information, refer to the documentation of the specific function. -This is not a breaking change. - - - diff --git a/docs/changelogs/0.7r.md b/docs/changelogs/0.7r.md deleted file mode 100644 index 95ee2a99..00000000 --- a/docs/changelogs/0.7r.md +++ /dev/null @@ -1,135 +0,0 @@ ---- -hide: - - toc ---- - -# Changelog 0.7r - -## Table of Contents - -1. [Update Video](#video) -2. [New Features](#features) - 1. [Integrated Dynamics Integration](#integrated-dynamics-integration-116) - 2. [Storage Drawer Integration](#storage-drawer-integration-116) - 3. [Colony Integrator](#colony-integrator) - 4. [Geo Scanner](#geo-scanner) - 5. [Block Reader](#block-reader) - 6. [NBT Storage](#nbt-storage) - 7. [New Turtles Upgrades](#new-turtles-upgrades) - 8. [New Ingame Documentation](#new-ingame-documentation) -3. [Small features and improvements](#small-features-and-improvements) - 1. [Breaking changes](#breaking-changes) - 2. [New functions, events and translations!](#new-functions-events-and-translations) - 3. [Improved mod integration](#improved-mod-integration) - 4. [Support for relative and cardinal directions](#support-for-relative-and-cardinal-directions) -4. [Bug fixes](#bug-fixes) - -
- -## First of all - -First of all, big thanks to SirEdvin and FatalMerlin! These awesome hoomans helped a lot with this update! - ---- - -### Video - -If you don't want to read, you can watch this wonderful short video! - - - -
- -## Features - -### New Integrations - -- #### Integrated Dynamics Integration -We added a peripheral to the "Variable Store" Block from [Integrated Dynamics](https://www.curseforge.com/minecraft/mc-mods/integrated-dynamics) to read variables from integrated dynamics. - - ##### [View here](../integrations/integrated_dynamics/variable_store.md) - -- #### Storage Drawer Integration -You can now access [Storage Drawers](https://www.curseforge.com/minecraft/mc-mods/storage-drawers). Store items, push and pull items or do whatever you want to do with items. This new feature is a mod integration. - - ##### [View here](../integrations/storage_drawers/drawer.md) - -### New Peripherals - -- #### Colony Integrator -We added the **Colony Integrator** that interacts with [MineColonies](https://www.curseforge.com/minecraft/mc-mods/minecolonies). You can use this peripheral to get information about your colony. It can be used as a [pocket upgrade](../items/pocket_computer.md) or as a block. - - ##### [View here](../peripherals/colony_integrator.md) - -- #### Geo Scanner -The **Geo Scanner** provides information about blocks around it and information about the current chunk. You could use it to search the current chunk and nearby blocks for ores. - - ##### [View here](../peripherals/geo_scanner.md) - -- #### Block Reader -With the **Block Reader** you can read the data of neighboring blocks and tile entites. - - ##### [View here](../peripherals/block_reader.md) - -- #### NBT Storage -With the **NBT Storage** peripheral you are able to store tables or other values into a block as NBT data. You can read and write values to the block with the peripheral functions. - - ##### [View here](../peripherals/nbt_storage.md) - -### New Turtles Upgrades -New powerful turtle upgrades! -With these small upgrades you finally can use any tools just from turtle inventories, perform right click on blocks, collect items in a small range, transport animals and much more! But be aware, the new abilities require fuel and most of them have a cooldown. Big thanks to SirEdvin who made these upgrades. - -### New Ingame Documentation -Advanced Peripherals now uses [Patchouli](https://www.curseforge.com/minecraft/mc-mods/patchouli) to generate ingame documentation. You can now get quick information about the mod in-game, without the need for internet access! - -
- -## Small features and improvements - -This update also provides a lot of small features and improvements. - ---- - -#### Breaking changes - -- We changed some function names of the ME Bridge and RS Bridge peripherals. -- Removed the Peripheral Proxy - ---- - -#### New functions, events and translations - -- Added the slot parameter to the functions of the [Inventory Manager](../peripherals/inventory_manager.md). -- Added `uuid` and `isHidden` return values to the chat event. -- Added a lot of new functions to the [Player Detector](../peripherals/player_detector.md). -- Added the `sendFormattedMessage` function to the chat box. -- Added russian translations by DrHesperus. - ---- - -#### Improved mod integration -You can now connect supported blocks directly with a modem. We completely removed the Peripheral Proxy. - ---- - -#### Support for relative and cardinal directions -You can now use relative directions (`right`, `left`, `front`, `back`, `top` `bottom`) and cardinal directions (`north`, `south`, `east`, `west`, `up`, `down`) at the same time. -**Example:** -```lua linenums="1" --- Both of these will work -redstoneIntegrator.setOutput("north", true) -redstoneIntegrator.setOutput("right", true) -``` - -
- -## Bug fixes - -*\* Not all fixed bugs are listed here* - -- Fixed server crashes with the RS Bridge -- Fixed chunky turtle performance issues -- Fixed that the redstone integrators lets pass redstone signal through it -- Fixed that the redstone integrator does not update blocks around it -- Improved chat event performance diff --git a/docs/guides/disabled_peripherals.md b/docs/guides/disabled_peripherals.md new file mode 100644 index 00000000..25e77184 --- /dev/null +++ b/docs/guides/disabled_peripherals.md @@ -0,0 +1,21 @@ +--- +comments: true +--- + +# Disabled Peripherals + +Peripherals can be disabled in the configuration file of AP in `{minecraft_folder}/config/Advancedperipherals/peripherals.toml`. + +When disabled, these peripherals can still be wrapped but all the functions throw a LuaException. Besides that, you can now find a new function called `peripheralDisabled`. +You can simply check in your script if a connected peripheral is disabled via the following example. + +```lua + box = peripheral.find("chat_box") -- (1) + if box.peripheralDisabled then -- (2) + error("Peripheral is Disabled", 0) + end + print("Peripheral is not Disabled") +``` + +1. Can be any peripheral, as long as it is from AP. +2. We just check if the function exists, we don't run it since the function does not exist when the peripheral is not disabled. diff --git a/docs/guides/filters.md b/docs/guides/filters.md index e5587b0c..86f332e9 100644 --- a/docs/guides/filters.md +++ b/docs/guides/filters.md @@ -28,7 +28,7 @@ This can be a tag or a name. To filter for tags, place a `#` in front of the nam ```lua { - name = "#forge:ores/gold" -- Will search for the gold ore tag, nbt values are ignored + name = "#c:ores/gold" -- Will search for the gold ore tag, nbt values are ignored } ``` diff --git a/docs/guides/how_to_report.md b/docs/guides/how_to_report.md index 28123ef8..3cc1f40c 100644 --- a/docs/guides/how_to_report.md +++ b/docs/guides/how_to_report.md @@ -27,6 +27,6 @@ We appreciate your dedication to making the project better by helping us squash
Remember, our modding community is built on collaboration and a love for Minecraft. Be friendly and respectful in your reports and requests. -To report a bug or request a feature, head over to our [github repository](https://github.com/SirEndii/AdvancedPeripherals/issues). Your feedback is important to us, and it makes the project what it is today! +To report a bug or request a feature, head over to our [github repository](https://github.com/IntelligenceModding/AdvancedPeripherals/issues). Your feedback is important to us, and it makes the project what it is today! If you need assistance or want to discuss a feature or something else, head out to our [discord](https://discord.intelligence-modding.de/) \ No newline at end of file diff --git a/docs/guides/lua_objects.md b/docs/guides/lua_objects.md new file mode 100644 index 00000000..c40ba635 --- /dev/null +++ b/docs/guides/lua_objects.md @@ -0,0 +1,162 @@ +# Common Lua Objects + +AP contains a lot of different objects based on in-game content, including Items, Item Stacks, Fluids, Entities and more. +This guide contains the most objects we have, including a description and every property with its type it can contain. + +## Item +Base item properties: + +| Property | Type | Description | +|----------|------|-------------| +| name | string | Registry key of the item | +| tags | table | List of item tags | + +## Item Stack +Represents a specific amount of an item with additional properties. Includes all Item properties plus: + +| Property | Type | Description | +|----------|------|-------------| +| name | string | Registry key of the item | +| tags | table | List of item tags | +| count | number | Amount of items in the stack | +| displayName | string | Display name of the item | +| maxStackSize | number | Maximum stack size | +| components | table | NBT component data | +| fingerprint | string | Unique identifier for the stack | +| slot | number | (Optional) Slot number when in inventory | + +## Fluid +Base fluid properties: + +| Property | Type | Description | +|----------|------|-------------| +| name | string | Registry key of the fluid | +| tags | table | List of fluid tags | + +## Fluid Stack +Represents a specific amount of fluid with additional properties. Includes all Fluid properties plus: + +| Property | Type | Description | +|----------|------|-------------| +| name | string | Registry key of the fluid | +| tags | table | List of fluid tags | +| count | number | Amount of fluid | +| displayName | string | Display name of the fluid | +| fluidType | table | [FluidType properties](#fluid-type) | +| components | table | NBT component data | +| fingerprint | string | Unique identifier for the stack | + +## Fluid Type +| Property | Type | Description | +|----------|------|-------------| +| viscosity | number | Fluid viscosity | +| density | number | Fluid density | +| canHydrate | boolean | Whether fluid can hydrate | +| canExtinguish | boolean | Whether fluid can extinguish | +| canDrownIn | boolean | Whether entities can drown in it | +| canSwim | boolean | Whether entities can swim in it | +| canPushEntity | boolean | Whether fluid can push entities | +| supportsBoating | boolean | Whether boats can float on it | +| canConvertToSource | boolean | Whether fluid can convert to source blocks | +| temperature | number | Fluid temperature | + +## Mekanism Chemical +Base chemical properties: + +| Property | Type | Description | +|----------|------|-------------| +| name | string | Registry key of the chemical | +| tags | table | List of chemical tags | +| isGaseous | boolean | Whether the chemical is gaseous | +| radioactivity | number | Radioactivity level of the chemical | + +## Mekanism Chemical Stack +Represents a specific amount of chemical with additional properties. Includes all Chemical properties plus: + +| Property | Type | Description | +|----------|------|-------------| +| count | number | Amount of chemical | +| displayName | string | Display name of the chemical | +| fingerprint | string | Unique identifier for the stack | + + +## Entity +| Property | Type | Description | +|----------|------|-------------| +| id | number | Entity ID | +| uuid | string | Entity UUID | +| name | string | Entity registry name | +| customName | string? | Entity custom name | +| displayName | string | Entity default display name | +| type | string | Entity type | +| tags | table | Entity tags | +| category | string | Entity category | +| canBurn | boolean | Whether entity can burn | +| canFreeze | boolean | Whether entity can freeze | +| isGlowing | boolean | Whether entity is glowing | +| isUnderWater | boolean | Whether entity is underwater | +| isInLava | boolean | Whether entity is in lava | +| isInWall | boolean | Whether entity is in a wall | +| team | table? | Entity [team info](#team) | + +## Living Entity +Inherits all properties from [Entity](#entity) + +| Property | Type | Description | +|----------|------|-------------| +| baby | boolean | Whether the entity is a baby | +| health | number | Current health | +| maxHealth | number | Maximum health | +| lastDamageSource | string | Last damage source (or nil) | +| effect | table | Effects on the entity | + +## Mob +Inherits all properties from [Living Entity](#living-entity) + +| Property | Type | Description | +|----------|------|-------------| +| aggressive | boolean | Whether the mob is in aggressive state | + +## Animal +Inherits all properties from [Mob](#mob) + +| Property | Type | Description | +|----------|------|-------------| +| inLove | boolean | Whether the animal is in love state | +| shareable | boolean | Whether the animal can be sheared (if applicable) | + +## Player +Inherits all properties from [Living Entity](#living-entity) + +| Property | Type | Description | +|----------|------|-------------| +| score | number | The player's score | +| luck | number | The luck of the player | +| handSlot | number | Selected hand slot of the player | +| inventory | table | Player's inventory | + +## BlockState +Represents a block and its state + +| Property | Type | Description | +|----------|------|-------------| +| name | string | The registry id of the block | +| tags | table | The tags on the block | +| state | table | The states of the block | + +## Position +Common block position object used for some filters and return values. + +| Property | Type | Description | +|----------|------|-------------| +| x | number | X coordinate | +| y | number | Y coordinate | +| z | number | Z coordinate | + +## Team +Entity team information + +| Property | Type | Description | +|----------|------|-------------| +| name | string | Team name | +| color | number | Team color in 0xRRGGBB format | diff --git a/docs/img/previews/ar_controller.png b/docs/img/previews/ar_controller.png deleted file mode 100644 index bfe42da1..00000000 Binary files a/docs/img/previews/ar_controller.png and /dev/null differ diff --git a/docs/img/previews/ar_goggles.png b/docs/img/previews/ar_goggles.png deleted file mode 100644 index 2fe13a32..00000000 Binary files a/docs/img/previews/ar_goggles.png and /dev/null differ diff --git a/docs/index.md b/docs/index.md index 08ab886b..139e6cd6 100644 --- a/docs/index.md +++ b/docs/index.md @@ -13,22 +13,25 @@ You can communicate with Refined Storage, Applied Energistics 2 or with the whol With Advanced Peripherals you can control your base in Minecraft only with messages in the chat, you can develop an AI that controls your farms - there really is no limit to what you can create with **CC:Tweaked** and **Advanced Peripherals**. +!!! hint + **Scroll back to the top** and check the **menu bar** for more documentations! + #### Links If you need help, join the [Discord](https://discord.intelligence-modding.de/) See the mod page on [Curseforge](https://www.curseforge.com/minecraft/mc-mods/advanced-peripherals) - Find the mod source code on [Github](https://github.com/SirEndii/AdvancedPeripherals) + Find the mod source code on [Github](https://github.com/IntelligenceModding/AdvancedPeripherals) #### Version support | Supported Version | 1.16.5 | 1.17.1 | 1.18.2 | 1.19.2 | 1.19.3 | 1.20.1 | 1.20.4 | 1.21.1 | |-------------------|--------------------|--------------------|--------------------|--------------------|--------------------|--------------------|--------------------|--------------------| | Security patches | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: | -| Critical fixes | :x: | :x: | :white_check_mark: | :white_check_mark: | :x: | :white_check_mark: | :white_check_mark: | :white_check_mark: | -| Minor fixes | :x: | :x: | :x: | :white_check_mark: | :x: | :white_check_mark: | :white_check_mark: | :white_check_mark: | -| Minor features | :x: | :x: | :x: | :white_check_mark: | :x: | :white_check_mark: | :white_check_mark: | :white_check_mark: | -| Fully supported | :x: | :x: | :x: | :white_check_mark: | :x: | :white_check_mark: | :white_check_mark: | :white_check_mark: | -| Will be supported | :x: | :x: | :o: | :o: | :o: | :o: | :o: | :o: | +| Critical fixes | :x: | :x: | :x: | :white_check_mark: | :x: | :white_check_mark: | :x: | :white_check_mark: | +| Minor fixes | :x: | :x: | :x: | :x: | :x: | :white_check_mark: | :x: | :white_check_mark: | +| Minor features | :x: | :x: | :x: | :x: | :x: | :white_check_mark: | :x: | :white_check_mark: | +| Fully supported | :x: | :x: | :x: | :x: | :x: | :white_check_mark: | :x: | :white_check_mark: | +| Will be supported | :x: | :x: | :x: | :o: | :x: | :o: | :x: | :o: | #### Netlify diff --git a/docs/integrations/ae2/cable_p2p_tunnel.md b/docs/integrations/ae2/cable_p2p_tunnel.md new file mode 100644 index 00000000..5d58deb3 --- /dev/null +++ b/docs/integrations/ae2/cable_p2p_tunnel.md @@ -0,0 +1,12 @@ +--- +comments: true +--- + +# Cable P2P Tunnel + +!!! picture inline end + ![!Images of Cable P2P Tunnel](../img/previews/cable_p2p_tunnel.png){ align=right } + +Cable P2P Tunnel is created by right clicking a P2P tunnel with CC: Tweaked's cable or wired modems. +It allows you control peripherals wirely across dimensions. +The in and out direction does not matter when connecting. diff --git a/docs/integrations/index.md b/docs/integrations/index.md index e18669db..6e81dd7d 100644 --- a/docs/integrations/index.md +++ b/docs/integrations/index.md @@ -21,7 +21,7 @@ print("Is on enchanted soul?: ".. flower.isOnEnchantedSoil()) --- ## Integration Requests -If you want to see more integrations, you can request a mod integration on [ Github](https://github.com/Seniorendi/AdvancedPeripherals/issues). +If you want to see more integrations, you can request a mod integration on [ Github](https://github.com/IntelligenceModding/AdvancedPeripherals/issues). --- diff --git a/docs/items/ar_goggles.md b/docs/items/ar_goggles.md deleted file mode 100644 index 3144567e..00000000 --- a/docs/items/ar_goggles.md +++ /dev/null @@ -1,24 +0,0 @@ ---- -comments: true ---- - -# AR Goggles - -!!! picture inline end - ![!Image of the AR Goggles item](../img/previews/ar_goggles.png){ align=right } - -The AR Goggles can be used in combination with the AR Controller to have a customizable overlay wherever you go. Fun! -See the documenation for the [AR Controller](../peripherals/ar_controller.md) to learn more. - -!!! hint - To link your goggles to an AR Controller, right click it with them in your hand. Multiple Goggles can be linked to one Controller. - -!!! bug - The AR Goggles are slightly buggy in 1.18x and completely disabled in 1.19x. We work on a rework of the AR Goggles system with a bunch of new features for 0.8/1.0 - ---- - -## Changelog/Trivia - -**0.5b** -Added the AR Controller and AR Goggles, made by Olfi01#6413 diff --git a/docs/items/smart_glasses.md b/docs/items/smart_glasses.md new file mode 100644 index 00000000..7b4bebc6 --- /dev/null +++ b/docs/items/smart_glasses.md @@ -0,0 +1,56 @@ +--- +comments: true +--- + +# Smart Glasses + +!!! picture inline end + ![!Image of the Smart Glasses item](../img/previews/smart_glasses.png){ align=right } + +The Smart Glasses can be used as an advanced pocket computer worn on the head, +equipped with most peripherials and various [modules](../modules/index.md)! + +You can access Smart Glasses worn on the head via a [Smart Glasses Interface](./smart_glasses_interface.md). + +--- + +## Module Peripheral + +The `back` side peripheral on Smart Glasses can be used to access modules. +[Modules](../modules/index.md) functions will be patched on the Module Peripheral. + +```lua linenums="1" +local modules = peripheral.wrap('back') +print('Available modules:', table.unpack(modules.getModules())) +``` + +!!! note + When modifing Smart Glasses modules, Module Peripheral will reload, + which triggers [`peripheral_detach`](https://tweaked.cc/event/peripheral_detach.html) + followed by [`peripheral`](https://tweaked.cc/event/peripheral.html) event. + +### Functions + +#### getModules +``` +getModules() -> table +``` + +returns a list of installed modules' ID. + +#### hasModule +``` +hasModule(id: string) -> boolean +``` + +check if the module with given ID is installed. + +--- + +## Changelog/Trivia + +**0.8** +Completely reworked AR Goggles and renamed it to Smart Glasses + +**0.5b** +Added the AR Controller and AR Goggles, made by Olfi01#6413 diff --git a/docs/items/smart_glasses_interface.md b/docs/items/smart_glasses_interface.md new file mode 100644 index 00000000..5e1720c6 --- /dev/null +++ b/docs/items/smart_glasses_interface.md @@ -0,0 +1,18 @@ +--- +comments: true +--- + +# Smart Glasses Interface + +!!! picture inline end + ![!Image of the Smart Glasses Interface item](../img/previews/smart_glasses_interface.png){ align=right } + +The Smart Glasses Interface let you access wearing [Smart Glasses](./smart_glasses.md) by righting the item. +You must have a Smart Glasses wearing in the armor head slot or in a curios slot. + +--- + +## Changelog/Trivia + +**0.8** +Completely reworked AR Goggles and renamed it to Smart Glasses diff --git a/docs/modules/hotkey.md b/docs/modules/hotkey.md new file mode 100644 index 00000000..1d119245 --- /dev/null +++ b/docs/modules/hotkey.md @@ -0,0 +1,35 @@ +--- +comments: true +--- + +# Hotkey Module + +!!! picture inline end + ![!Image of the Hotkey Module item](../img/previews/modules/hotkey_module.png){ align=right } + +The Hotkey Module can listen to the hotkey that players bound in their client. +Hotkey is configurable at player's client. + +--- + +## Events + +### glasses_key_pressed + +Fires when the player pressed the hotkey. + +**Values:** +1. `keyBind: string` The hotkey the player bound to. +2. `keyPressDuration: number` The duration the hotkey was held down, in milliseconds. + +```lua linenums="1" +local event, keyBind, keyPressDuration = os.pullEvent("glasses_key_pressed") +print("The hotkey " .. keyBind .. " pressed for " .. keyPressDuration .. "ms") +``` + +--- + +## Changelog/Trivia + +**0.8** +Added Hotkey Module diff --git a/docs/modules/index.md b/docs/modules/index.md new file mode 100644 index 00000000..e7f25c2b --- /dev/null +++ b/docs/modules/index.md @@ -0,0 +1,7 @@ +--- +comments: true +--- + +# Modules + +Modules are used in [Smart Glasses](../items/smart_glasses.md). diff --git a/docs/modules/keyboard.md b/docs/modules/keyboard.md new file mode 100644 index 00000000..8ca3ead9 --- /dev/null +++ b/docs/modules/keyboard.md @@ -0,0 +1,134 @@ +--- +comments: true +--- + +# Hotkey Module + +!!! picture inline end + ![!Image of the Keyboard item](../img/previews/modules/keyboard_module.png){ align=right } + +The Keyboard Module can listen to the same hotkey as [the Hotkey module](./hotkey.md) that players bound in their client. +When active, Keyboard Module will forward player's key events to Smart Glasses. +In addition, Keyboard Module may also capture player's mouse by invoking `setCaptureMouse(true)`, and then fire corresponding events. + +--- + +## Events + +### keyboard_open + +Fires when the player opened the keyboard. + +**Values:** *None* + +```lua linenums="1" +os.pullEvent("keyboard_open") +print('Keyboard opened!') +``` + +--- + +### keyboard_close + +Fires when the player closed the keyboard. + +**Values:** *None* + +```lua linenums="1" +os.pullEvent("keyboard_close") +print('Keyboard closed!') +``` + +--- + +### player_mouse_click + +Fires when a player pressed a mouse button while keyboard module is capturing mouse. + +**Values:** +1. `button: number` The mouse button which clicked down. + +```lua linenums="1" +local event, button = os.pullEvent("player_mouse_click") +print('Mouse button ' .. button .. ' pressed!') +``` + +--- + +### player_mouse_up + +Fires when the player released a mouse button while keyboard module is capturing mouse. + +**Values:** +1. `button: number` The mouse button which released up. + +```lua linenums="1" +local event, button = os.pullEvent("player_mouse_up") +print('Mouse button ' .. button .. ' released!') +``` + +--- + +### player_mouse_move + +Fires when a player moved mouse while keyboard module is capturing mouse. + +**Values:** +1. `dx: number` Horizontal mouse movement +2. `dy: number` Vertical mouse movement + +```lua linenums="1" +local event, dx, dy = os.pullEvent("player_mouse_move") +print('Mouse moving: dy=' .. dy .. ' dx=' .. dx) +``` + +--- + +### player_mouse_scroll + +Fires when a player scrolled mouse while keyboard module is capturing mouse. + +**Values:** +1. `dy: number` Vertical mouse scroll amount +2. `dx: number` Horizontal mouse scroll amount + +```lua linenums="1" +local event, dy, dx = os.pullEvent("player_mouse_scroll") +print('Mouse scrolling: dy=' .. dy .. ' dx=' .. dx) +``` + +--- + +## Functions + +### isCapturingKeys +``` +isCapturingKeys() -> boolean +``` + +returns `true` if the keyboard is currently open, `false` otherwise. + +--- + +### isCapturingMouse +``` +isCapturingMouse() -> boolean +``` + +returns `true` if the mouse is currently captured, `false` otherwise. + +--- + +### setCaptureMouse +``` +setCaptureMouse(enable: boolean) -> nil +``` + +set if the mouse should be captured. + +--- + +## Changelog/Trivia + +**0.8** +Added Hotkey Module diff --git a/docs/modules/night_vision.md b/docs/modules/night_vision.md new file mode 100644 index 00000000..8626959b --- /dev/null +++ b/docs/modules/night_vision.md @@ -0,0 +1,40 @@ +--- +comments: true +--- + +# Night Vision Module + +!!! picture inline end + ![!Image of the Night Vision Module item](../img/previews/modules/night_vision_module.png){ align=right } + +The Night Vision Module can provide an infinite night vision effect to the wearer. +The night vision effect will be enabled by default. + +While Night Vision Module is disabled, night vision potion does not take any effect. + +--- + +## Functions + +### isNightVisionEnabled +``` +isNightVisionEnabled() -> boolean +``` + +Returns if the night vision effect is enabled. + +--- + +### enableNightVision +``` +enableNightVision(enable: boolean) -> nil +``` + +If passed value is `true`, it will start applying night vision effect, `false` to start clearing any night vision effect. + +--- + +## Changelog/Trivia + +**0.8** +Added Night Vision Module diff --git a/docs/modules/overlay.md b/docs/modules/overlay.md new file mode 100644 index 00000000..fba29cf9 --- /dev/null +++ b/docs/modules/overlay.md @@ -0,0 +1,508 @@ +--- +comments: true +--- + +# Overlay Module + +!!! picture inline end + ![!Image of the Overlay Module item](../img/previews/modules/overlay_module.png){ align=right } + +The Overlay Module allows scripts render stuff on player's GUI. + +--- + +## Objects + +All fields will have a getter and a setter, which is defined as `getXxx` and `setXxx`. +For `boolean` fields, getter is defined as `isXxx` or `hasXxx`. + +--- + +### OverlayObject + +| Field | Type | Default | Description | +| ----- | ---- | ------- | ----------- | +| `enabled` | `boolean` | `true` | whether or not to render the object | + +#### type +``` +type() -> string +``` + +returns the object's type. + +#### getId +``` +getId() -> number +``` + +returns the object's integer ID. + +--- + +### RenderableObject + +Based on [OverlayObject](#overlayobject) + +| Field | Type | Default | Description | +| ----- | ---- | ------- | ----------- | +| `opacity` | `number` | `1` | A decimal number that determines the transparency of the object, in range of `[0.0, 1.0]` | +| `color` | `number` | `0xffffff` | An integer that determines the color of the object, in format of 0xRRGGBB | +| `x` | `number` | `0` | A decimal number of the object's X position | +| `y` | `number` | `0` | A decimal number of the object's Y position | +| `z` | `number` | `0` | A decimal number of the object's Z position | +| `rotX` | `number` | `0` | A decimal number determine the degrees the object's rotation around the X-axis, in range of `[0, 360]` | +| `rotY` | `number` | `0` | A decimal number determine the degrees the object's rotation around the Y-axis, in range of `[0, 360]` | +| `rotZ` | `number` | `0` | A decimal number determine the degrees the object's rotation around the Z-axis, in range of `[0, 360]` | + +#### getPos +``` +getPos() -> number, number, number +``` + +returns the object's `x`, `y`, `z`. + +#### setPos +``` +setPos(number, number, number) -> nil +``` + +sets the object's `x`, `y`, `z`. + +--- + +### CircleObject + +Based on [RenderableObject](#renderableobject) + +| Field | Type | Default | Description | +| ----- | ---- | ------- | ----------- | +| `radius` | `number` | `0` | Integer of the circle's radius, in range of `[0, ∞)` | +| `filled` | `boolean` | `true` | If the circle should be filled | +| `pixelated` | `boolean` | `true` | If the circle should be pixelated | +| `borderWidth` | `number` | `4` | Integer of the circle's border width, in range of `[0, 32767]` | +| `segments` | `number` | `25` | Integer of the circle's segments, in range of `[0, 100]` | + +--- + +### ItemObject + +Based on [RenderableObject](#renderableobject) + +| Field | Type | Default | Description | +| ----- | ---- | ------- | ----------- | +| `item` | `string | nil` | `nil` | The registry ID of the item to render | + +--- + +### LineObject + +Based on [RenderableObject](#renderableobject) + +| Field | Type | Default | Description | +| ----- | ---- | ------- | ----------- | +| `endX` | `number` | `0` | A decimal number of line's X end | +| `endY` | `number` | `0` | A decimal number of line's Y end | +| `pixelated` | `boolean` | `false` | If the line should be pixelated | +| `width` | `number` | `4` | Integer of the line's width, in range of `[0, 32767]` | + +#### getEndPos +``` +getEndPos() -> number, number +``` + +returns the object's `endX`, `endY`. + +#### setEndPos +``` +setEndPos(number, number) -> nil +``` + +sets the object's `endX`, `endY`. + +--- + +### RectangleObject + +Based on [RenderableObject](#renderableobject) + +| Field | Type | Default | Description | +| ----- | ---- | ------- | ----------- | +| `sizeX` | `number` | `0` | A decimal number of rectangle's X size, in range of `[0, ∞)` | +| `sizeY` | `number` | `0` | A decimal number of rectangle's Y size, in range of `[0, ∞)` | + +#### getSizes +``` +getSizes() -> number, number +``` + +returns the object's `sizeX`, `sizeY`. + +#### setSizes +``` +setSizes(number, number) -> nil +``` + +sets the object's `sizeX`, `sizeY`. + +--- + +### TextObject + +Based on [RenderableObject](#renderableobject) + +| Field | Type | Default | Description | +| ----- | ---- | ------- | ----------- | +| `content` | `string` | `""` | The text to render | +| `fontSize` | `number` | `1` | A decimal number represents the text's font size, in range of `[0.0, 128.0]` | +| `shadow` | `boolean` | `false` | Whether or not render a shadow for the text | +| `center` | `boolean` | `false` | If the text should be centered at its position | + +--- + +### ThreeDimensionalObject + +Based on [RenderableObject](#renderableobject) + +| Field | Type | Default | Description | +| ----- | ---- | ------- | ----------- | +| `relativePosition` | `boolean` | `false` | Should the object's position relative to the player's head | +| `relativeRotation` | `boolean` | `false` | Should the object's rotation relative to the player's head | +| `depthTest` | `boolean` | `true` | If the object should hide behind other objects | +| `culling` | `boolean` | `true` | If the object's hidden faces should not be seen | + +--- + +### BlockObject + +Based on [ThreeDimensionalObject](#threedimensionalobject) + +| Field | Type | Default | Description | +| ----- | ---- | ------- | ----------- | +| `block` | `string` | `"minecraft:air"` | The registry ID of the block to render | + +--- + +### BoxObject + +Based on [ThreeDimensionalObject](#threedimensionalobject) + +| Field | Type | Default | Description | +| ----- | ---- | ------- | ----------- | +| `sizeX` | `number` | `0` | A decimal number of rectangle's X size, in range of `[0, ∞)` | +| `sizeY` | `number` | `0` | A decimal number of rectangle's Y size, in range of `[0, ∞)` | +| `sizeZ` | `number` | `0` | A decimal number of rectangle's Z size, in range of `[0, ∞)` | + +#### getSizes +``` +getSizes() -> number, number, number +``` + +returns the object's `sizeX`, `sizeY`, `sizeZ`. + +#### setSizes +``` +setSizes(number, number, number) -> nil +``` + +sets the object's `sizeX`, `sizeY`, `sizeZ`. + +--- + +### SphereObject + +Based on [ThreeDimensionalObject](#threedimensionalobject) + +| Field | Type | Default | Description | +| ----- | ---- | ------- | ----------- | +| `sectors` | `number` | `16` | An integer in range of `[1, 1024]` | +| `stacks` | `number` | `16` | An integer in range of `[1, 1024]` | +| `radius` | `number` | `1` | A decimal number of the sphere's radius, in range of `(0, 128]` | + +--- + +### TorusObject + +Based on [ThreeDimensionalObject](#threedimensionalobject) + +| Field | Type | Default | Description | +| ----- | ---- | ------- | ----------- | +| `sides` | `number` | `32` | An integer in range of `[1, 1024]` | +| `rings` | `number` | `16` | An integer in range of `[1, 1024]` | +| `minorRadius` | `number` | `0.1` | A decimal number of inner radius of the ring, in range of `(0, 128]` | +| `majorRadius` | `number` | `0.5` | A decimal number of outer radius of the ring, in range of `(0, 128]` | + +--- + +### TriangleObject + +Based on [ThreeDimensionalObject](#threedimensionalobject) + +!!! note + Triangle objects only visible when the vertex is ordered in counter-clockwise. + +| Field | Type | Default | Description | +| ----- | ---- | ------- | ----------- | +| `x1` | `number` | `0` | A decimal number of the first vertex's X position | +| `y1` | `number` | `0` | A decimal number of the first vertex's Y position | +| `z1` | `number` | `0` | A decimal number of the first vertex's Z position | +| `x2` | `number` | `0` | A decimal number of the second vertex's X position | +| `y2` | `number` | `0` | A decimal number of the second vertex's Y position | +| `z2` | `number` | `0` | A decimal number of the second vertex's Z position | +| `x3` | `number` | `0` | A decimal number of the third vertex's X position | +| `y3` | `number` | `0` | A decimal number of the third vertex's Y position | +| `z3` | `number` | `0` | A decimal number of the third vertex's Z position | + +#### getPos1 +``` +getPos1() -> number, number, number +``` + +returns the object's `x1`, `y1`, `z1`. + +#### setPos1 +``` +setPos1(number, number, number) -> nil +``` + +sets the object's `x1`, `y1`, `z1`. + +#### getPos2 +``` +getPos2() -> number, number, number +``` + +returns the object's `x2`, `y2`, `z2`. + +#### setPos2 +``` +setPos2(number, number, number) -> nil +``` + +sets the object's `x2`, `y2`, `z2`. + +#### getPos3 +``` +getPos3() -> number, number, number +``` + +returns the object's `x3`, `y3`, `z3`. + +#### setPos3 +``` +setPos3(number, number, number) -> nil +``` + +sets the object's `x3`, `y3`, `z3`. + +--- + +## Functions + +### createObject +``` +createObject(id: string, object: table) -> table +``` + +`id` must be a valid object's type ID +`object` should contains the object's initial properties + +returns a copy of the `object` with getters & setters to change its properties. + +--- + +### createBlock +``` +createBlock(object: table) -> table +``` + +`object` is a [BlockObject](#blockobject) + +returns a copy of the `object` with getters & setters to change its properties. + +--- + +### createBox +``` +createBox(object: table) -> table +``` + +`object` is a [BoxObject](#boxobject) + +returns a copy of the `object` with getters & setters to change its properties. + +--- + +### createSphere +``` +createSphere(object: table) -> table +``` + +`object` is a [SphereObject](#sphereobject) + +returns a copy of the `object` with getters & setters to change its properties. + +--- + +### createTorus +``` +createTorus(object: table) -> table +``` + +`object` is a [TorusObject](#torusobject) + +returns a copy of the `object` with getters & setters to change its properties. + +--- + +### createTriangle +``` +createTriangle(object: table) -> table +``` + +`object` is a [TriangleObject](#triangleobject) + +returns a copy of the `object` with getters & setters to change its properties. + +--- + +### createCircle +``` +createCircle(object: table) -> table +``` + +`object` is a [CircleObject](#circleobject) + +returns a copy of the `object` with getters & setters to change its properties. + +--- + +### createItem +``` +createItem(object: table) -> table +``` + +`object` is a [ItemObject](#itemobject) + +returns a copy of the `object` with getters & setters to change its properties. + +--- + +### createLine +``` +createLine(object: table) -> table +``` + +`object` is a [LineObject](#lineobject) + +returns a copy of the `object` with getters & setters to change its properties. + +--- + +### createRectangle +``` +createRectangle(object: table) -> table +``` + +`object` is a [RectangleObject](#rectangleobject) + +returns a copy of the `object` with getters & setters to change its properties. + +--- + +### createText +``` +createText(object: table) -> table +``` + +`object` is a [TextObject](#textobject) + +returns a copy of the `object` with getters & setters to change its properties. + +--- + +### getObject +``` +getObject(id: number) -> table | nil +``` + +returns a [RenderableObject](#renderableobject) by the object's ID, or `nil` if the ID not exists. + +--- + +### removeObject +``` +removeObject(id: number) -> boolean +``` + +remove an object by its ID and returns if the object with given ID existed + +--- + +### clear +``` +clear() -> number +``` + +remove all objects, returns the number of removed object. + +--- + +### getObjectsCount +``` +getObjectsCount() -> number +``` + +returns the number of all objects. + +--- + +### getGuiSize +``` +getGuiSize() -> number, number, number +``` + +returns the client's width, height, and GUI scale + +--- + +### getEyePosition +``` +getEyePosition() -> number, number, number +``` + +returns the player's eye position + +--- + +### update +``` +update() -> number +``` + +manually update objects, returns the number of updated object. + +--- + +### autoUpdate +``` +autoUpdate() -> boolean +``` + +returns if objects will be auto synced to client when its fields updating + +--- + +### setAutoUpdate +``` +setAutoUpdate(value: boolean) -> nil +``` + +sets if objects will be auto synced to client + +--- + +## Changelog/Trivia + +**0.8** +Added Overlay Module diff --git a/docs/peripherals/ar_controller.md b/docs/peripherals/ar_controller.md deleted file mode 100644 index b019fd60..00000000 --- a/docs/peripherals/ar_controller.md +++ /dev/null @@ -1,312 +0,0 @@ ---- -comments: true ---- - -# AR Controller - -!!! picture inline end - ![!Image of the AR Controller block](../img/previews/ar_controller.png){ align=right } - -The AR Controller is used to control your [AR Goggles](../items/ar_goggles.md) wirelessly. You can draw anything you wish into an overlay that will be visible as long as you're wearing the goggles. - -!!! hint - To link your goggles to an AR Controller, right click it with them in your hand. Multiple Goggles can be linked to one Controller. - -!!! bug - The AR Goggles are currently slightly buggy. Sometimes, they just don't do what they should do. We will rework the AR System in 0.8r/1.0r - ---- - -
- -| Peripheral Name | Interfaces with | Has events | Introduced in | -| --------------- | --------------- | ---------- | ------------- | -| arController | AR Goggles | No | 0.5b | - -
- ---- - -While the Controller is in relative mode, it interprets all coordinates as if they were on a virtual screen of the size you specified, and then scales them according to your screen size. - -All color values are hexadecimal color codes (for example `0xff00ff`) - -Everything that is painted onto the canvas remains there until `clear()` or if the element is removed using `clearElement(id)`, however, it might be repositioned if relative mode is toggled on or off. - -## Functions - -### clear -``` -clear() -> void -``` - -Clears the entire canvas. - ---- - -### clearElement -``` -clearElement(id: string) -> void -``` - -Clears the element with the given `id`. - ---- - -### horizontalLine -``` -horizontalLine(minX: number, maxX: number, y: number, color: number) -> void -``` - -Draws a horizontal line in the given color from minX to maxX at vertical y. - ---- - -### horizontalLineWithId -``` -horizontalLineWithId(id: string, minX: number, maxX: number, y: number, color: number) -> void -``` - -The same as [`horizontalLine()`](#horizontalline), but has an id so it can be overridden later on or can be completely cleared. - ---- - -### verticalLine -``` -verticalLine(x: number, minY: number, maxY: number, color: number) -> void -``` - -Draws a vertical line in the given color from minY to maxY at horizontal x. - ---- - -### verticalLineWithId -``` -verticalLineWithId(id: string, x: number, minY: number, maxY: number, color: number) -> void -``` - -The same as [`verticalLine()`](#verticalline), but has an id so it can be overridden later on or can be completely cleared. - ---- - -### drawString -``` -drawString(text: string, x: number, y: number, color: number) -> void -``` - -Draws the given string to the specified position with the specified text color. - ---- - -### drawStringWithId -``` -drawStringWithId(id: string, text: string, x: number, y: number, color: number) -> void -``` - -The same as [`drawString()`](#drawstring), but has an id so it can be overridden later on or can be completely cleared. - ---- - -### drawCenteredString -``` -drawCenteredString(text: string, x: number, y: number, color: number) -> void -``` - -The same as [`drawString()`](#drawstring), but centers the string horizontally around the specified position. - ---- - -### drawCenteredStringWithId -``` -drawCenteredStringWithId(id: string, text: string, x: number, y: number, color: number) -> void -``` - -The same as [`drawCenteredString()`](#drawcenteredstring), but has an id so it can be overridden later on or can be completely cleared. - ---- - -### drawRightboundString -``` -drawRightboundString(text: string, x: number, y: number, color: number) -> void -``` - -The same as [`drawString()`](#drawstring), but the string is positioned with its right end at the specified position. - ---- - -### drawRightboundStringWithId -``` -drawRightboundStringWithId(id: string, text: string, x: number, y: number, color: number) -> void -``` - -The same as [`drawRightboundString()`](#drawrightboundstring), but has an id so it can be overridden later on or can be completely cleared. - ---- - -### drawItemIcon -``` -drawItemIcon(itemId: string, x: number, y: number) -> void -``` - -!!! success "Added in version 0.5.2b" - -Draws the given item to the specified position. - ---- - -### drawItemIconWithId -``` -drawItemIconWithId(id: string, itemId: string, x: number, y: number) -> void -``` - -!!! success "Added in version 0.5.2b" - -The same as [`drawItemIcon()`](#drawitemicon), but has an id so it can be overridden later on or can be completely cleared. - ---- - -### drawCircle -``` -drawCircle(x: number, y: number, radius: number, color: number) -> void -``` - -!!! success "Added in version 0.5.2b" - -Draws a circle without filling it. - ---- - -### drawCircleWithId -``` -drawCircleWithId(id: string, x: number, y: number, radius: number, color: number) -> void -``` - -!!! success "Added in version 0.5.2b" - -The same as [`drawCircle()`](#drawcircle), but has an id so it can be overridden later on or can be completely cleared. - ---- - -### fill -``` -fill(minX: number, minY: number, maxX: number, maxY: number, color: number) -``` - -Fills a rectangle with the given color from the corner minX, minY to maxX, maxY. - ---- - -### fillWithId -``` -fill(id: string, minX: number, minY: number, maxX: number, maxY: number, color: number) -``` - -The same as [`fill()`](#fill), but has an id so it can be overridden later on or can be completely cleared. - ---- - -### fillCircle -``` -fillCircle(x: number, y: number, radius: number, color: number) -> void -``` - -!!! success "Added in version 0.5.2b" - -Draws a full circle. - ---- - -### fillCircleWithId -``` -fillCircleWithId(id: string, x: number, y: number, radius: number, color: number) -> void -``` - -!!! success "Added in version 0.5.2b" - -The same as [`fillCircle()`](#fillcircle), but has an id so it can be overridden later on or can be completely cleared. - ---- - -### fillGradient -``` -fillGradient(minX: number, minY: number, maxX: number, maxY: number, colorFrom: number, colorTo: number) -> void -``` - -Draws a rectangular gradient from colorFrom to colorTo with the given corners. - ---- - -### fillGradientWithId -``` -fillGradientWithId(id: string, minX: number, minY: number, maxX: number, maxY: number, colorFrom: number, colorTo: number) -> void -``` - -The same as [`fillGradient()`](#fillgradient), but has an id so it can be overridden later on or can be completely cleared. - ---- - -### isRelativeMode -``` -isRelativeMode(): true, number, number | false -``` - -Returns true and the size of the virtual screen if relative mode is active, or just false if it isn't. - ---- - -### setRelativeMode -``` -setRelativeMode(enabled: boolean, virtualScreenWidth?: number, virtualScreenHeight?: number) -> void -``` - -Activates or deactivates relative mode. Requires virtual screen width and height if it is being enabled. - ---- - -!!! hint - Use negative coordinates to specify an x value from the right end of the screen or a y value from the bottom! - -## Examples - -### Example 1 - -Olfi01 made a simple script that shows the current date and time in the top right corner of the screen and updates every second. - -```lua linenums="1" -local controller = peripheral.find("arController") -- Finds the peripheral if one is connected - -if controller == nil then error("arController not found") end - -controller.setRelativeMode(true, 1600, 900) -- Convenient Aspect ratio for most screens -while true do - local timer = os.startTimer(1) - local event, id - repeat - event, id = os.pullEvent("timer") - until id == timer - controller.clear() -- If you don't do this, the texts will draw over each other - controller.drawRightboundString(os.date(), -10, 10, 0xffffff) -end -``` - -### Example 2 - -Olfi01 made another script to draw .nfp files, which you can draw with the paint program, in cc in your HUD. - -First, we have a script with more adaptability. You can define x, y, width and height. - -Script 1: [Github](https://gist.github.com/Seniorendi/ce4971245b20fb031ca9b65ec4fcb4d0) - -And we have another script which depends on the script above, but is simpler to use. - -Script 2: [Github](https://gist.github.com/Seniorendi/954e9888fac01efe8f23e82d0ae06e92) - ---- - -## Changelog/Trivia - -**0.5.2b** -Added `fillCircle`, `drawCircle` and `drawItemIcon`. - -**0.5b** -Added the AR Controller and Goggles, made by Olfi01#6413 diff --git a/docs/peripherals/energy_detector.md b/docs/peripherals/base_detector.md similarity index 67% rename from docs/peripherals/energy_detector.md rename to docs/peripherals/base_detector.md index 5e55482e..1e1b2c37 100644 --- a/docs/peripherals/energy_detector.md +++ b/docs/peripherals/base_detector.md @@ -2,12 +2,12 @@ comments: true --- -# Energy Detector +# Detectors !!! picture inline end ![!Image of the Energy Detector block](../img/previews/energy_detector.png){ align=right } -The Energy Detector can detect energy flow and acts as a resistor. You can define the max flow rate to use it as a resistor. +The detectors can detect content (e.g. energy, fluid) flow and acts as a resistor. You can define the max flow rate to use it as a resistor. !!! bug The Energy Detector does not work on versions below 0.4.5b. @@ -22,6 +22,8 @@ The Energy Detector can detect energy flow and acts as a resistor. You can defin | Peripheral Name | Interfaces with | Has events | Introduced in | | --------------- | --------------- | ---------- | ------------- | | energy_detector | Forge Energy | No | 0.4.1b | +| fluid_detector | Fluid | No | 0.8 | +| gas_detector | Mekanism Gas | No | 0.8 |
@@ -32,7 +34,7 @@ The Energy Detector can detect energy flow and acts as a resistor. You can defin ### getTransferRate ``` -getTransferRate() -> int +getTransferRate() -> number ``` Returns the current energy that is going through the block. @@ -50,7 +52,7 @@ print("Current transfer rate: " .. detector.getTransferRate() .. " FE/t") ### getTransferRateLimit ``` -getTransferRateLimit() -> int +getTransferRateLimit() -> number ``` Returns the max rate limit of energy through the block which has been set using [`setTransferRateLimit`](#settransferratelimit). @@ -60,7 +62,7 @@ Returns the max rate limit of energy through the block which has been set using ### setTransferRateLimit ``` -setTransferRateLimit(limit: int) -> void +setTransferRateLimit(limit: number) -> nil ``` Set the max energy rate that will go through the block. @@ -73,6 +75,36 @@ detector.setTransferRateLimit(512) -- Only 512 FE/t can go through the block --- +### getMaxTransferRate + +``` +getMaxTransferRate() -> number +``` + +Returns the max possible rate limit the can be set using [`setTransferRateLimit`](#settransferratelimit). + +--- + +### getLastTransferedId + +``` +getLastTransferedId() -> string | nil +``` + +Returns the previous transferred object's ID, or `nil` if nothing was ever transferred through the detector. + +--- + +### getReadyTransferId + +``` +getLastTransferedId() -> string | nil +``` + +Returns the ID of the object ready to transfer in the current tick, or `nil` if nothing is ready to transfer in the tick. + +--- + ## Changelog/Trivia The Energy Detector had some weird problems in versions before 0.4.6b diff --git a/docs/peripherals/base_peripheral.md b/docs/peripherals/base_peripheral.md new file mode 100644 index 00000000..936a68ee --- /dev/null +++ b/docs/peripherals/base_peripheral.md @@ -0,0 +1,70 @@ +--- +comments: true +--- + +# Base Peripheral + +All peripherals in AdvancedPeripherals contains these basic methods defined below. + +--- + +## Functions + +### getName +``` +getName() -> string +``` + +Returns the custom name of the peripheral. + +--- + +### setName +``` +setName(name: string) -> nil +``` + +Sets the custom name of the peripheral. + +--- + +### getConfiguration +``` +getConfiguration() -> table +``` + +Returns the configuration of the peripheral. + +Configuration table is in the following format: +``` +{ + []: string = + operations: table | nil = { + []: table = { + name: string = + type: string = + [] = + getCost(args...) -> number + } + } +} +``` + +!!! note + `operations` field only exists if any operation presents on the peripheral. + +--- + +### getOperationCooldown +``` +getOperationCooldown(operationName: string) -> number +``` + +!!! note + This method only exists if any operation presents on the peripheral. + +Returns the remaining cooldown of an operation in milliseconds. + +--- + +## Changelog/Trivia diff --git a/docs/peripherals/base_storage_bridge.md b/docs/peripherals/base_storage_bridge.md new file mode 100644 index 00000000..ee1924f6 --- /dev/null +++ b/docs/peripherals/base_storage_bridge.md @@ -0,0 +1,821 @@ +# Storage System Functions + +Starting from AP 0.8, the ME and RS Bridge both now share the same functionality along with the new crafting system. +The following functions can be used for both the ME and RS Bridge. + +!!! tip + You can use the command `/advancedperipherals getHashItem` with an item in your hand to get the hash of the NBT tags + of the item. An hash can look like this `5d955c751ee14ae5`. + +## Common Functions + +!!! info + The item arguments(`filter: table`) accepts our item/fluid/chemical filters, you can check the syntax of these + filters [here](../guides/filters.md). + +### isConnected + +``` +isConnected() -> boolean +``` + +Returns true if the block is currently connected to a grid + +--- + +### isOnline + +``` +isOnline() -> boolean +``` + +Returns true if the grid is currently online and available + +--- + +### getItem + +``` +getItem(filter: table) -> table | (nil, string) +``` + +Returns the first item that matches the filter. Or nil with a debug message if none could be found + +--- + +### getFluid + +``` +getFluid(filter: table) -> table | (nil, string) +``` + +Returns the first fluid that matches the filter. Or nil with a debug message if none could be found + +--- + +### getChemical + +``` +getChemical(filter: table) -> table | (nil, string) +``` + +Returns the first mekanism chemical that matches the filter. Or nil with a debug message if none could be found + +--- + +### getItems + +``` +getItems(filter: table) -> table | (nil, string) +``` + +Returns every item that matches the filter or an empty table if none could be found. +An empty filter can be provided to get every resource. +Returns nil if there was an issue parsing your table. + +--- + +### getFluids + +``` +getFluids(filter: table) -> table | (nil, string) +``` + +Returns every fluid that matches the filter or an empty table if none could be found. +An empty filter can be provided to get every resource. +Returns nil if there was an issue parsing your table. + +--- + +### getChemicals + +``` +getChemicals(filter: table) -> table | (nil, string) +``` + +Returns every mekanism chemical that matches the filter or an empty table if none could be found. +An empty filter can be provided to get every resource. +Returns nil if there was an issue parsing your table. + +--- + +### getCraftableItems + +``` +getCraftableItems(filter: table) -> table | (nil, string) +``` + +Returns every craftable item that matches the filter even if there is currently no item stored or an empty table if none +could be found. +An empty filter can be provided to get every resource. +Returns nil if there was an issue parsing your table. + +--- + +### getCraftableFluids + +``` +getCraftableFluids(filter: table) -> table | (nil, string) +``` + +Returns every craftable fluid that matches the filter even if there is currently no fluid stored or an empty table if +none could be found. +An empty filter can be provided to get every resource. +Returns nil if there was an issue parsing your table. + +--- + +### getCraftableChemicals + +``` +getCraftableChemicals(filter: table) -> table | (nil, string) +``` + +Returns every craftable mekanism chemical that matches the filter even if there is currently no chemical stored or an +empty table if none could be found. +An empty filter can be provided to get every resource. +Returns nil if there was an issue parsing your table. + +--- + +### getCells + +``` +getCells() -> table | (nil, string) +``` + +Returns every storage cell in the drives of the grid. Supports standard RS/ME cells and some third party cells. +Please open a feature request if some custom addon cells do not work + +--- + +### getDrives + +``` +getCells() -> table | (nil, string) +``` + +Returns every drive connected to the system with the cells in it. + +--- + +## Importing/Exporting functions + +You may are used to two different functions, `importItemFromPeripheral` and `importItem` +The functions now support both at the same time. It first tries to parse the given string `target` as a cardinal or +relative direction. +If that fails, it tries to search for a peripheral on the CC network which exposes an item handler or capability. + +### importItem + +``` +importItem(filter: table, target: string) -> table | (nil, string) +``` + +Imports an item from the specified target. The filter can be empty to import every item. +One call imports 64 of resources by default, can be set using the count filter key. + +--- + +### exportItem + +``` +exportItem(filter: table, target: string) -> table | (nil, string) +``` + +Exports an item to the specified target. The filter can be empty to export every item. +One call exports 64 of resources by default, can be set using the count filter key. + +--- + +### importFluid + +``` +importFluid(filter: table, target: string) -> table | (nil, string) +``` + +Imports a fluid from the specified target. The filter can be empty to import every fluid. +One call imports 1000mB of resources by default, can be set using the count filter key. + +--- + +### exportFluid + +``` +exportFluid(filter: table, target: string) -> table | (nil, string) +``` + +Exports a fluid to the specified target. The filter can be empty to export every fluid. +One call exports 1000mB of resources by default, can be set using the count filter key. + +--- + +### importChemical + +``` +importChemical(filter: table, target: string) -> table | (nil, string) +``` + +Imports a mekanism chemical from the specified target. The filter can be empty to import every chemical. +One call imports 1000mB of resources by default, can be set using the count filter key. + +--- + +### exportChemical + +``` +exportChemical(filter: table, target: string) -> table | (nil, string) +``` + +Exports a mekanism chemical to the specified target. The filter can be empty to export every chemical. +One call exports 1000Mb of resources by default, can be set using the count filter key. + +--- + +## Energy Related Functions + +### getStoredEnergy + +``` +getStoredEnergy() -> int +``` + +Returns the stored energy in the grid. + +--- + +### getEnergyCapacity + +``` +getEnergyCapacity() -> int +``` + +Returns the maximum energy capacity of the grid + +--- + +### getEnergyUsage + +``` +getEnergyUsage() -> int +``` + +Returns the energy usage of the grid + +--- + +!!! note + Currently only supported by the ME Bridge + +### getAvgPowerInjection + +``` +getAvgPowerInjection() -> int +``` + +Returns the average power that is injected into the system + +--- + +## Storage Related Functions + +!!! warning + The RS Bridge currently does not support Any external storage function, we will hopefully be able to support them when + RS2 is out of beta. + +### getTotalExternItemStorage + +``` +getTotalExternItemStorage() -> int +``` + +Returns the total amount of available external item storage. +External storage is available storage by either RS2's external storage bus or AE2's storage bus +This function returns the available storage in items even with the byte system from AE2 + +--- + +### getTotalExternFluidStorage + +``` +getTotalExternFluidStorage() -> int +``` + +Returns the total amount of available external fluid storage. +External storage is available storage by either RS2's external storage bus or AE2's storage bus +This function returns the available storage in millibuckets even with the byte system from AE2 + +--- + +### getTotalExternChemicalStorage + +``` +getTotalExternChemicalStorage() -> int +``` + +Returns the total amount of available external mekanism chemical storage. +External storage is available storage by either RS2's external storage bus or AE2's storage bus +This function returns the available storage in millibuckets even with the byte system from AE2 + +--- + +### getTotalItemStorage + +``` +getTotalItemStorage() -> int +``` + +Returns the total amount of available internal item storage. +This function returns the available storage in items for RS and in bytes for AE2 + +--- + +### getTotalFluidStorage + +``` +getTotalFluidStorage() -> int +``` + +Returns the total amount of available internal fluid storage. +This function returns the available storage in millibuckets for RS and in bytes for AE2 + +--- + +### getTotalChemicalStorage + +``` +getTotalChemicalStorage() -> int +``` + +Returns the total amount of available internal mekanism chemical storage. +This function returns the available storage in millibuckets for RS and in bytes for AE2 + +--- + +### getUsedExternItemStorage + +``` +getUsedExternItemStorage() -> int +``` + +Returns the total amount of used external item storage. +External storage is available storage by either RS2's external storage bus or AE2's storage bus +This function returns the used storage in items even with the byte system from AE2 + +--- + +### getUsedExternFluidStorage + +``` +getUsedExternFluidStorage() -> int +``` + +Returns the total amount of used external fluid storage. +External storage is available storage by either RS2's external storage bus or AE2's storage bus +This function returns the used storage in millibuckets even with the byte system from AE2 + +--- + +### getUsedExternChemicalStorage + +``` +getUsedExternChemicalStorage() -> int +``` + +Returns the total amount of used external mekanism chemical storage. +External storage is available storage by either RS2's external storage bus or AE2's storage bus +This function returns the used storage in millibuckets even with the byte system from AE2 + +--- + +### getUsedItemStorage + +``` +getUsedItemStorage() -> int +``` + +Returns the total amount of used internal item storage. +This function returns the used storage in items for RS and in bytes for AE2 + +--- + +### getUsedFluidStorage + +``` +getUsedFluidStorage() -> int +``` + +Returns the total amount of used internal fluid storage. +This function returns the used storage in millibuckets for RS and in bytes for AE2 + +--- + +### getUsedChemicalStorage + +``` +getUsedChemicalStorage() -> int +``` + +Returns the total amount of used internal mekanism chemical storage. +This function returns the used storage in millibuckets for RS and in bytes for AE2 + +--- + +### getAvailableExternItemStorage + +``` +getAvailableExternItemStorage() -> int +``` + +Returns the total amount of available and not used external item storage. +External storage is available storage by either RS2's external storage bus or AE2's storage bus +This function returns the available and not used storage in items even with the byte system from AE2 + +--- + +### getAvailableExternFluidStorage + +``` +getAvailableExternFluidStorage() -> int +``` + +Returns the total amount of available and not used external fluid storage. +External storage is available storage by either RS2's external storage bus or AE2's storage bus +This function returns the available and not used storage in millibuckets even with the byte system from AE2 + +--- + +### getAvailableExternChemicalStorage + +``` +getAvailableExternChemicalStorage() -> int +``` + +Returns the total amount of available and not used external mekanism chemical storage. +External storage is available storage by either RS2's external storage bus or AE2's storage bus +This function returns the available and not used storage in millibuckets even with the byte system from AE2 + +--- + +### getAvailableItemStorage + +``` +getAvailableItemStorage() -> int +``` + +Returns the total amount of available and not used internal item storage. +This function returns the available and not used storage in items for RS and in bytes for AE2 + +--- + +### getAvailableFluidStorage + +``` +getAvailableFluidStorage() -> int +``` + +Returns the total amount of available and not used internal fluid storage. +This function returns the available and not used storage in millibuckets for RS and in bytes for AE2 + +--- + +### getAvailableChemicalStorage + +``` +getAvailableChemicalStorage() -> int +``` + +Returns the total amount of available and not used internal mekanism chemical storage. +This function returns the available and not used storage in millibuckets for RS and in bytes for AE2 + +--- + +## Crafting System and functions + +Since 0.8 and beta 0.7 for 1.21.1 we created a new crafting system for both the ME and RS Bridge +The functionality is mostly the same but since the RS api is currently not as extensive as the AE2 api, the RS Craft Job +may miss some functions. + +The craft function now returns an object instead of a boolean. Using that object is optional. +That object contains information about the job, if it was canceled, what was requested, what items may miss if +calculation was not successful and much more. + +Crafting is in both RS and AE async. If you request a feature, it calculates the recipe in the background and if that +was successful it starts the task. +To support that in a simple way on a users end, we created that custom object. + +When you schedule a task, it firsts starts calculation in the background and sends an event that the item is either not +craftable or the calculation was started. +If calculation is done, there are several things that can happen. If the calculation was not successful and there were +missing items, it fires the crafting event with the message "MISSING_ITEMs". +The missing items can be retrieved using the object's function `getMissingItems`. +Depending on if you use RS or AE2, it also may return other debug messages if the calculation was nto successful like +overflow or cycle detected. + +If the calculation was successful, the event will fire with the message `CRAFTING_STARTED` and then starts the crafting. + +There are now two ways to track the progress. the `crafting` event will fire when the crafting is done, it was canceled +or if other things might happen that affects the task. +The event also gives you an id to get the crafting object you would also get from the initial `craftX` function. Simply +use `getCraftingJob` to get the object. + +The other way is to regularly check if the crafting is done or canceled by calling the objects `isDone` or `isCanceled` +function. +Using the event is more simple there. + +Every function and property is described in more details below. + +### Crafting Event + +The new crafting event will be fired when the state of a task will change. + +The name of the event is prefixed depending if you use the RS or ME Bridge. +Use `rs_crafting` for the RS Bridge and `me_crafting` for the ME Bridge. +**Values:** + +1. `error: boolean` If an error occurred and the calculation or crafting was not successful +2. `id: int` The id of the craft job. Can be used to get the craft object +3. `debug_message: string` A debug message describing the current task of the task + +```lua linenums="1" +local event, error, id, message = os.pullEvent("rs_crafting") +print("A crafting update occurred for Job #" .. id) +if error then + print("There was an error while calculating or crafting the resource with the message " .. message) +else + print("The new state of the task is " .. message) +end +``` + +### craftItem + +``` +craftItem(filter: table) -> table | (nil, string) +``` + +Schedules a craft job for items. Will fire the crafting event when changes occur. +Or nil if there was an issue with parsing the filter + +--- + +### craftFluid + +``` +craftFluid(filter: table) -> table | (nil, string) +``` + +Schedules a craft job for fluids. Will fire the crafting event when changes occur. +Or nil if there was an issue with parsing the filter + +--- + +### craftChemical + +``` +craftChemical(filter: table) -> table | (nil, string) +``` + +Schedules a craft job for mekanism chemicals. Will fire the crafting event when changes occur. +Or nil if there was an issue with parsing the filter + +--- + +### getCraftingTasks + +``` +getCraftingTasks() -> table +``` + +Returns every crafting task that is currently running. + +--- + +### getCraftingTask + +``` +getCraftingJob(id: int) -> table | (nil, string) +``` + +Returns the [Crafting Job Object](#crafting-job) with the id. Nil if no object could be found + +--- + +### cancelCraftingTasks + +``` +cancelCraftingTasks(filter: table) -> int +``` + +Cancels every crafting task where the output matches the filter + +--- + +### getPatterns + +``` +getPatterns(pattern_filter: table) -> table | (nil, string) +``` + +Returns every pattern available to the grid or nil if there was an issue with parsing one of the filters. +The filter of this function is a bit different + +You **can** specify filters for the output and input of patterns. If you don't provide any filter or just no argument at +all, it will return every pattern. + +To specify an input or output filter, you need to use an `input`/`output` key in the filters table. + +For example + +```lua linenums="1" +-- Filter for any patterns with sticks as an output +outputFilter = { + output = { + name="minecraft:stick" + } +} + +-- Filter for any patterns with sticks as an input +inputFilter = { + input = { + name="minecraft:stick" + } +} + +-- Filter for any patterns with sticks as an output and planks as an input +inputFilter = { + input = { + name = "minecraft:oak_planks" + }, + output = { + name="minecraft:stick" + } +} + +-- Or use the function without argument to get every pattern +patterns = bridge.getPatterns() +``` + +--- + +### isCraftable + +``` +isCraftable(filter: table) -> boolean +``` + +Returns true if there is a pattern for the provided filter or nil if there was an issue with parsing the filter. +The filter can be an item filter, a chemical filter or a fluid filter. See [filter types](../guides/filters.md#types) + +--- + +### isCrafting + +``` +isCrafting(filter: table) -> boolean +``` + +Returns true if there is a crafting job running for the provided filter or nil if there was an issue with parsing the +filter. +The filter can be an item filter, a chemical filter or a fluid filter. See [filter types](../guides/filters.md#types) + +## Objects + +Every object here is inherited from common lua objects, see [LuaObjects](../guides/lua_objects.md) +Please note that due to different natures of AE2 and RS that not every object is the same. + +### Item Stack + +| Property | Type | Description | +|-------------|---------|--------------------------------------------------| +| isCraftable | boolean | Whether the item is craftable (A pattern exists) | + +### Fluid Stack + +| Property | Type | Description | +|-------------|---------|--------------------------------------------------| +| isCraftable | boolean | Whether the item is craftable (A pattern exists) | + +### Chemical Stack + +| Property | Type | Description | +|-------------|---------|--------------------------------------------------| +| isCraftable | boolean | Whether the item is craftable (A pattern exists) | + +### Storage Disk + +AE2 and RS2 storage disks sadly have a bunch of different properties since AE2 works with types and bytes while RS does +not. + +#### Refined Storage Disk + +| Property | Type | Description | +|----------|--------|-----------------------------| +| used | number | Storage amount what is used | +| capacity | number | Total Capacity | +| state | string | RS Storage state[^1] | +| type | string | RS Storage type[^2] | + +#### Applied Energistics Disk + +| Property | Type | Description | +|--------------|----------------------------------------------|----------------------------------| +| item | [Item Object](../guides/lua_objects.md#item) | Disk as an Item | +| usedBytes | number | Used Bytes | +| totalBytes | number | Types capacity (Usually 63) | +| bytes | number | Bytes capacity | +| bytesPerType | number | Amount of bytes used by one type | +| type | string | AE2 Storage Type[^3] | +| fuzzyMode | string | AE2 Fuzzy[^4] | + +#### DISK Drive disk + +Storage DISK Drive from AE2 Things inherit the same properties from the classic AE2 disk. + +### Pattern + +| Property | Type | Description | +|---------------|--------------------------------------------------------------------------------------|--------------------------------------------| +| primaryOutput | [Item/Fluid/Chem Stack Object](#objects) | Primary Output | +| outputs | Array of [Item/Fluid/Chem Stack Object](#objects).
Or AE2 Pattern Input object | Outputs | +| inputs | Array of [Item/Fluid/Chem Stack Object](#objects) | Inputs | +| patternType | string | Pattern Type, different for AE2 and RS[^5] | +| id | string | Pattern ID, only for RS | + +### AE2 Pattern Input + +| Property | Type | Description | +|----------------|---------------------------------------------------|------------------------------------------------------------------------------------------| +| primaryInput | [Item/Fluid/Chem Stack Object](#objects) | Primary Input. | +| possibleInputs | Array of [Item/Fluid/Chem Stack Object](#objects) | Other possible Inputs | +| multiplier | number | How many possible inputs are necessary to craft this pattern | +| remaining | number | Remaining items like buckets when a water bucket was used. Nil for non crafting patterns | + +### AE2 Crafting CPU + +| Property | Type | Description | +|---------------|---------------------|---------------------------------------------------------| +| storage | number | Available storage in bytes | +| coProcessors | number | Available co processing unity | +| isBusy | boolean | Whether the CPU is currently performing a task | +| craftingJob | Crafting Job Object | The job it currently performs | +| name | string | Either "Unnamed" when not named for the name of the CPU | +| selectionMode | string | CPU Selection mode[^6] | + +### Crafting Job Details + +| Property | Type | Description | +|------------|----------------------------------------------|---------------------------------------------------------------| +| bridge_id | number | The ID of that task when scheduled via the bride or -1 if not | +| id | string | ID of the task | +| quantity | number | Amount scheduled | +| resource | [Item/Fluid/Chem Stack Object](#objects) | The scheduled resource | +| completion | floating number between 0 and 1 | Completion in percentage | +| crafted | number | Amount already crafted | +| cpu | [AE2 Crafting CPU Object](#ae2-crafting-cpu) | The crafting cpu, nil for RS | + +### Crafting Job + +With the new crafting system, we have a complete new crafting job object. While the basic crafting job only offers some simple details, the actual job that manages the crafting offers everything that RS or AE2 would offer. +Tho these are no properties/fields, these are functions since always pulling these information would be a waste of time. + +Represents a crafting job in the ME/RS system. Used for tracking crafting operations. + +| Function | Return Type | Description | +|------------------------------|-------------|---------------------------------------------------------------------| +| getId() | number | Returns the unique identifier of the crafting job | +| isDone() | boolean | Returns whether the crafting job is completed | +| isCanceled() | boolean | Returns whether the crafting job was canceled | +| isCraftingStarted() | boolean | Returns whether the crafting process has started | +| isCalculationStarted() | boolean | Returns whether the calculation process has started | +| isCalculationNotSuccessful() | boolean | Returns whether the calculation failed | +| hasErrorOccurred() | boolean | Returns whether an error occurred during the job | +| getDebugMessage() | string | Returns a debug message with additional information about the job | +| getRequestedItem() | object | Returns the requested item/fluid/chemical as an object | +| getElapsedTime() | number | Returns the elapsed time since the job was created | +| getTotalItems() | number | Returns the total number of items to be crafted | +| getItemProgress() | number | Returns the current progress of crafting (how many items completed) | +| getEmittedItems() | object | Returns an object representing the items already emitted by the job | +| getUsedItems() | object | Returns an object representing the items used in crafting | +| getMissingItems() | object | Returns an object representing items missing for crafting | +| hasMultiplePaths() | boolean | Returns whether there are multiple crafting paths available | +| getFinalOutput() | object | Returns the final output item/fluid/chemical | +| cancel() | boolean | Cancels the crafting job and returns whether it was successful | +| getUsedBytes() | number | Returns the used bytes for that job. AE2 only | + +[^1]: +Can be NONE, INACTIVE, NORMAL, NEAR_CAPACITY, FULL. + +[^2]: +Can be item, fluid, chemical, unknown (with an unknown addon). + +[^3]: +Can be ae2:f, ae2:i, ae2:chemical or storage types from other addons. + +[^4]: +Can be IGNORE_ALL, PERCENT_99, PERCENT_75, PERCENT_50, PERCENT_25. + +[^5]: +For RS: EXTERNAL, INTERNAL. For AE2: crafting, processing, smithing, stonecutting, unknown(for unknown third party patterns). + +[^6]: +Can be ANY, PLAYER_ONLY, MACHINE_ONLY. diff --git a/docs/peripherals/block_reader.md b/docs/peripherals/block_reader.md index 4364b83c..bc6cf813 100644 --- a/docs/peripherals/block_reader.md +++ b/docs/peripherals/block_reader.md @@ -27,10 +27,10 @@ This block is able to read data about any blocks or tile entities in front of it ### getBlockName ``` -getBlockName() -> string +getBlockName() -> string | nil ``` -Returns the registry name of the block (ex. `minecraft:dirt`) +Returns the registry name of the block (ex. `minecraft:dirt`), or `nil` if nothing is in front of the reader. ```lua linenums="1" local reader = peripheral.find("block_reader") @@ -40,43 +40,51 @@ print("There is a " .. read.getBlockName() .. " in front.") --- -### getBlockData +### getBlockState ``` -getBlockData() -> table | nil +getBlockState() -> table | nil ``` -Returns the block data of the block if block is a tile entity. +Returns the block state of the block, or `nil` if nothing is in front of the reader. ```lua linenums="1" local reader = peripheral.find("block_reader") ---Prints the contents of the data -for k, v in ipairs(reader.getBlockData()) do +for k, v in pairs(reader.getBlockState()) do print(k, v) end ``` --- -!!! success "Added in version 1.19.2-0.7.33r | 1.20.1-0.7.37r" - -### getBlockStates +### getBlockData ``` -getBlockStates() -> table | nil +getBlockData() -> table | nil ``` -Returns the properties of a block and its state +Returns the block data of the block if block is a tile entity. + +```lua linenums="1" +local reader = peripheral.find("block_reader") + +--Prints the contents of the data +for k, v in pairs(reader.getBlockData()) do + print(k, v) +end +``` --- !!! success "Added in version 1.19.2-0.7.33r | 1.20.1-0.7.37r" -### isTileEntity +### hasBlockEntity ``` -isTileEntity() -> boolean | nil +hasBlockEntity() -> boolean | nil ``` -Returns true whether the block is a tile entity or not +Returns whether the block is a block entity or not + +--- ## Changelog/Trivia diff --git a/docs/peripherals/chat_box.md b/docs/peripherals/chat_box.md index 6d8372a0..f994bf2a 100644 --- a/docs/peripherals/chat_box.md +++ b/docs/peripherals/chat_box.md @@ -29,15 +29,16 @@ The Chat Box is able to read and write messages to the in-game chat. You can sen ## Events ### chat -Fires when a player sends a message into the chat. +Fires when a chat message appears within a chatbox's detection range. **Values:** -1. `username: string` The username of the player who sent the message -2. `message: string` The message sent by the player -3. `uuid: string` The player's uuid -4. `isHidden: boolean` Whether the message is hidden or not +1. `uuid: string` Message sender's UUID. `nil` if triggered from a /say command +2. `name: string` Message sender's name. `[say]` if triggered from a /say command +3. `message: string` The chat message +4. `isHidden: boolean` Whether or not the message is privately sent to chatboxes +5. `encodedUtf8Message: string` The encoded chat message from utf8 ```lua linenums="1" -local event, username, message, uuid, isHidden = os.pullEvent("chat") +local event, uuid, username, message, isHidden = os.pullEvent("chat") print("The 'chat' event was fired with the username " .. username .. " and the message " .. message) ``` @@ -50,13 +51,22 @@ print("The 'chat' event was fired with the username " .. username .. " and the m ### sendMessage ``` -sendMessage(message: string[, prefix: string, brackets: string, bracketColor: string, range: number]) -> true | nil, string +sendMessage(message: string, options: table | nil) -> true | nil, string ``` + Broadcasts a message to the global chat or if `range` is specified it is sent to all players in the range. -The `prefix` will change the text that appears inside the brackets at the start of a message. Defaults to "AP". -To change the `brackets` used around the prefix you must specify a string like so: -`"[]"`, `"()"`, `"<>"`, ... -`bracketColor` specifies the color to use for the brackets, this must be in the [MOTD code format](https://www.digminecraft.com/lists/color_list_pc.php). +Returns true if the message is successfully sent, or nil and an error message if it fails. + +`options` format: +``` +{ + utf8: boolean = if strings and message should be treated as encoded utf8 + range: number = the broadcast range + prefix: string = change the text that appears inside the brackets at the start of a message. Defaults to "AP". + brackets: string = used around the prefix. Must specify a two length string like "[]", "()", "<>", ... + bracketColor: string = specifies the color to use for the brackets, must be in the [MOTD code format](https://www.digminecraft.com/lists/color_list_pc.php). +} +``` Returns true if the message is successfully sent, or nil and an error message if it fails. @@ -64,13 +74,13 @@ Returns true if the message is successfully sent, or nil and an error message if local chatBox = peripheral.find("chat_box") chatBox.sendMessage("Hello world!") -- Sends "[AP] Hello world!" in chat -os.sleep(1) -- We must account for the cooldown between messages, this is to prevent spam -chatBox.sendMessage("I am dave", "Dave") -- Sends "[Dave] I am dave" -os.sleep(1) +sleep(1) -- We must account for the cooldown between messages, this is to prevent spam +chatBox.sendMessage("I am dave", {prefix="Dave"}) -- Sends "[Dave] I am dave" +sleep(1) -- Sends message "Welcome!" with cyan <> brackets around "" -- to players within 30 blocks of the chat box -chatBox.sendMessage("Welcome!", "Box", "<>", "&b", 30) +chatBox.sendMessage("Welcome!", {prefix="Box", brackets="<>", bracketColor="&b", range=30}) ``` !!! tip @@ -82,36 +92,23 @@ chatBox.sendMessage("Welcome!", "Box", "<>", "&b", 30) ### sendMessageToPlayer ``` -sendMessageToPlayer(message: string, username: string[, prefix: string, brackets: string, bracketColor: string, range: number]) -> true | nil, string +sendMessageToPlayer(message: string, username: string, options: table | nil) -> true | nil, string ``` Similar to [`sendMessage()`](#sendmessage) this sends a message to one specific player. Specify the player to send the message to with the `username` parameter. -```lua linenums="1" -local chatBox = peripheral.find("chat_box") - -chatBox.sendMessageToPlayer("Hello there.", "Player123") -- Sends "[AP] Hello there." to Player123 in chat -``` - -### sendToastToPlayer -``` -sendToastToPlayer(message: string, title: string, username: string[, prefix: string, brackets: string, bracketColor: string, range: number]) -> true | nil, string -``` -Sends a toast to the specified player. The design of the toast is the classic notification design. It's planned to add a custom rendered design in the future. - -![!Image of the toast](../img/chat_box/toast.png) - +`username` is player's in game name or its uuid. ```lua linenums="1" local chatBox = peripheral.find("chat_box") -chatBox.sendToastToPlayer("I will chat box you", "Hello", "Dev", "&4&lBoxi", "()", "&c&l") +chatBox.sendMessageToPlayer("Hello there.", "Player123") -- Sends "[AP] Hello there." to Player123 in chat ``` --- ### sendFormattedMessage ``` -sendFormattedMessage(json: string[, prefix: string, brackets: string, bracketColor: string, range: number]) -> true | nil, string +sendFormattedMessage(json: string, options: table | nil) -> true | nil, string ``` This function is fundamentally the same as [`sendMessage()`](#sendmessage) except it takes a json text component as the first parameter. Find out more information on how the text component format works on the [minecraft wiki](https://minecraft.wiki/w/Text_component_format). @@ -145,17 +142,55 @@ chatBox.sendFormattedMessage(json) ### sendFormattedMessageToPlayer ``` -sendFormattedMessageToPlayer(json: string, username: string[, prefix: string, brackets: string, bracketColor: string, range: number]) -> true | nil, string +sendFormattedMessageToPlayer(json: string, username: string, options: table | nil) -> true | nil, string ``` Similar to [`sendFormattedMessage()`](#sendformattedmessage) this sends a formatted message to one specific player. Specify the player to send the message to with the `username` parameter. +`username` is player's in game name or its uuid. + +--- + +### sendToastToPlayer +``` +sendToastToPlayer(options: table) -> true | nil, string +``` +Sends a toast to the specified player. The design of the toast is the classic notification design. It's planned to add a custom rendered design in the future. + +![!Image of the toast](../img/chat_box/toast.png) + +`options` format: +``` +{ + utf8: boolean = if strings should be treated as encoded utf8 + message: string = the message in the toast + title: string = the title of the toast + player: string = player's name or uuid + prefix: string = change the text that appears inside the brackets at the start of a message. Defaults to "AP". + brackets: string = used around the prefix + bracketColor: string = specifies the color to use for the brackets +} +``` + +```lua linenums="1" +local chatBox = peripheral.find("chat_box") + +chatBox.sendToastToPlayer({ + message = "I will chat box you", + title = "Hello", + player = "Dev", + prefix = "&4&lBoxi", + brackets = "()", + bracketColor = "&c&l", +}) +``` + --- ### sendFormattedToastToPlayer ``` -sendFormattedToastToPlayer(messageJson: string, titleJson: string, username: string[, prefix: string, brackets: string, bracketColor: string, range: number]) -> true | nil, string +sendFormattedToastToPlayer(options: table) -> true | nil, string ``` -This function is fundamentally the same as [`sendToast()`](#sendtoasttoplayer) except it takes a json text component as the first and second parameter. +This function is fundamentally the same as [`sendToast()`](#sendtoasttoplayer) except it takes a json text component for `message`, and `title` fields. Find out more information on how the text component format works on the [minecraft wiki](https://minecraft.wiki/w/Text_component_format). You can generate the json at [minecraft.tools](https://minecraft.tools/en/json_text.php?json=Welcome%20to%20Minecraft%20Tools). @@ -178,7 +213,14 @@ local message = { local titleJson = textutils.serializeJSON(title) local messageJson = textutils.serialiseJSON(message) -successful, error = chatBox.sendFormattedToastToPlayer(messageJson, titleJson, "Dev", "&4&lBoxi", "()", "&c&l") +successful, error = chatBox.sendFormattedToastToPlayer({ + message = messageJson, + title = titleJson, + player = "Dev", + prefix = "&4&lBoxi", + brackets = "()", + bracketColor = "&c&l", +}) ``` --- diff --git a/docs/peripherals/colony_integrator.md b/docs/peripherals/colony_integrator.md index c10b6ca2..0f89cd59 100644 --- a/docs/peripherals/colony_integrator.md +++ b/docs/peripherals/colony_integrator.md @@ -396,14 +396,14 @@ Returns the current number of active construction sites. We made a script to show every citizens and their gender on a monitor. -You can view and download the script on [Github](https://github.com/Seniorendi/Lua-Projects/blob/master/Examples/colony_integrator_list.lua) +You can view and download the script on [Github](https://github.com/SirEndii/Lua-Projects/blob/master/Examples/colony_integrator_list.lua) ![!Image of the citizen list program](../img/colony_integrator/citizen_list.png) ### Colony Stats And here we have a script made for a pocket computer to show statistics about a colony. -You can view and download the script on [Github](https://github.com/Seniorendi/Lua-Projects/blob/master/Examples/colony_integrator_status.lua) +You can view and download the script on [Github](https://github.com/SirEndii/Lua-Projects/blob/master/Examples/colony_integrator_status.lua) ![!Image of the colony info program](../img/colony_integrator/colony_info.png) --- diff --git a/docs/peripherals/distance_detector.md b/docs/peripherals/distance_detector.md new file mode 100644 index 00000000..c27033c8 --- /dev/null +++ b/docs/peripherals/distance_detector.md @@ -0,0 +1,159 @@ +--- +comments: true +--- + +# Distance Detector + +!!! picture inline end + ![!Image of the Distance Detector block](../img/previews/distance_detector.png){ align=right } + +The Distance Detector can measure the distance between the peripheral and a object. + +

+ +--- + +
+ +| Peripheral Name | Interfaces with | Has events | Introduced in | +| ----------------- | ---------------- | ---------- | ------------- | +| distance_detector | Block / Entity | No | 0.8 | + +
+ +--- + +## Functions + +### laserVisibility +``` +laserVisibility() -> boolean +``` + +Returns if the laser is currently visible by players. + +--- + +### setLaserVisibility +``` +setLaserVisibility(value: boolean) -> nil +``` + +Sets if the laser should be visible by players. + +--- + +### ignoresTransparency +``` +ignoresTransparency() -> boolean +``` + +Returns if the laser is currently ignoring transparent blocks, such as glasses. + +--- + +### setIgnoreTransparency +``` +setIgnoreTransparency(value: boolean) -> nil +``` + +Sets if the laser should ignore transparent blocks. + +--- + +### detectsEntities +``` +detectsEntities() -> boolean +``` + +Returns if the laser is detecting entities. + +--- + +### detectsBlocks +``` +detectsBlocks() -> boolean +``` + +Returns if the laser is detecting blocks. + +--- + +### detectionMode +``` +detectionMode() -> string, number +``` + +Returns if the laser's detection mode. +First value is string code `BLOCK`, `ENTITY`, or `BOTH`. +Second value is corresponding number code 0, 1, or 2. + +--- + +### setDetectionMode +``` +setDetectionMode(value: string | number) -> nil +``` + +Sets the laser's detection mode, `value` may be either string code or number code. + +--- + +### distance +``` +distance() -> number +``` + +Returns the last distance between the peripheral and the first obstructing object. `-1` if nothing is detected within the max range. + +--- + +### calculateDistance +``` +calculateDistance() -> number +``` + +Calculates and returns the current distance between the peripheral and the first obstructing object. + +--- + +### shouldCalculatePeriodically +``` +shouldCalculatePeriodically() -> boolean +``` + +Returns if the laser will automatically recheck distance. + +--- + +### setCalculatePeriodically +``` +setCalculatePeriodically(value: boolean) -> nil +``` + +Sets if the laser should automatically recheck distance. + +--- + +### maxRange +``` +maxRange() -> number +``` + +Returns the max distance the laser will try to detect. + +--- + +### setMaxRange +``` +setMaxRange(range: number) -> nil +``` + +Sets the max distance the laser should try to detect. + +--- + +## Changelog/Trivia + +**0.8** +Added distance detector diff --git a/docs/peripherals/environment_detector.md b/docs/peripherals/environment_detector.md index c72274ba..21733da0 100644 --- a/docs/peripherals/environment_detector.md +++ b/docs/peripherals/environment_detector.md @@ -53,16 +53,6 @@ Returns the block light level (0 to 15) at the detector block, this can be influ --- -### getDayLightLevel - -``` -getDayLightLevel() -> number -``` - -Returns the day light level of the current world from 0 to 15. This is uneffected by blocks covering the peripheral. - ---- - ### getSkyLightLevel ``` @@ -73,142 +63,103 @@ Returns the current sky light level from 0 to 15 (like a daylight sensor). --- -### getDimensionName +### getDayLightLevel ``` -getDimensionName() -> string +getDayLightLevel() -> number ``` -Returns the name of the current dimension (ex. `overworld`, `the_nether` or `the_end`). - -```lua linenums="1" -local detector = peripheral.find("environment_detector") - --- e.g. prints "Dimension: the_nether" -print("Dimension: " .. detector.getDimensionName()) -``` +Returns the day light level of the current world from 0 to 15. This is uneffected by blocks covering the peripheral. --- -### getDimensionPaN +### getTime ``` -getDimensionPaN() -> string +getTime() -> number ``` -Similar to [`getDimensionName`](#getdimensionname) it returns the name of the dimension prefixed with the provider name (ex. `minecraft:overworld`). - ---- - -### getDimensionProvider - -``` -getDimensionProvider() -> string -``` +!!! warning "WIP" -Returns the provider of the dimension (ex. `minecraft`). +Returns the daytime of the current world. --- -### getMoonId +### isSlimeChunk ``` -getMoonId() -> number +isSlimeChunk() -> boolean ``` -Returns the current moon phase's id. - -!!! info - There are 8 different moon phases, see below a list of their names and ids +Returns true if the current chunk is a slime chunk. - `0 = Full moon`, `1 = Waning gibbous`, `2 = Third quarter`, `3 = Waning crescent`, `4 = New moon`, `5 = Waxing crescent`, `6 = First quarter`, `7 = Waxing gibbous` +--- -### getMoonName +### getDimension ``` -getMoonName() -> string +getDimension() -> string ``` -Returns the current moon phase's name. - ---- +Returns the name of the current dimension (ex. `minecraft:overworld`, `minecraft:the_nether` or `minecraft:the_end`). -### getTime +```lua linenums="1" +local detector = peripheral.find("environment_detector") -``` -getTime() -> number +-- e.g. prints "Dimension: the_nether" +print("Dimension: " .. detector.getDimension()) ``` -!!! warning "WIP" - -Returns the daytime of the current world. - --- -### getRadiation +### listDimensions ``` -getRadiation() -> table +listDimensions() -> table ``` -!!! success "Added in version 0.6.1b" - -!!! warning "Requirement" - Requires the [Mekanism](https://www.curseforge.com/minecraft/mc-mods/mekanism) mod to be installed - -Returns the current radiation level from the Mekanism mod with the radiation unit. - -#### Properties +Returns a table with all of the registered dimensions for the current world, this includes modded dimensions. -| table | Description | -| ------------------- | --------------------------------------- | -| radiation: `string` | The current radiation level as a string | -| unit: `string` | The radiation unit | +!!! example + As an example `listDimensions` might return a table like so: + ``` + {"minecraft:overworld", "minecraft:the_nether", "minecraft:the_end", "twilightforest:twilight_forest"} + ``` --- -### getRadiationRaw +### getMoon ``` -getRadiationRaw() -> number +getMoon() -> number, string ``` -!!! success "Added in version 0.6.5b" - -!!! warning "Requirement" - Requires the [Mekanism](https://www.curseforge.com/minecraft/mc-mods/mekanism) mod to be installed - -Returns the current raw radiation level in Sv/h. - ---- - -### isDimension +Returns the current moon phase's id and its name -``` -isDimension(dimension: string) -> boolean -``` +!!! info + There are 8 different moon phases, see below a list of their names and ids -Returns true if the current dimension matches the `dimension` parameter. + `0 = Full moon`, `1 = Waning gibbous`, `2 = Third quarter`, `3 = Waning crescent`, `4 = New moon`, `5 = Waxing crescent`, `6 = First quarter`, `7 = Waxing gibbous` --- -### isMoon +### isRaining ``` -isMoon(moonPhaseId: number) -> boolean +isRaining() -> boolean ``` -Returns true if the current moon phase matches the `moonPhaseId` parameter. +Returns true if it is raining. --- -### isRaining +### isThunder ``` -isRaining() -> boolean +isThunder() -> boolean ``` -Returns true if it is raining. +Returns true if it is thundering. --- @@ -222,39 +173,40 @@ Returns true if it is sunny. --- -### isThunder +### getRadiation ``` -isThunder() -> boolean +getRadiation() -> table ``` -Returns true if it is thundering. +!!! success "Added in version 0.6.1b" ---- +!!! warning "Requirement" + Requires the [Mekanism](https://www.curseforge.com/minecraft/mc-mods/mekanism) mod to be installed -### isSlimeChunk +Returns the current radiation level from the Mekanism mod with the radiation unit. -``` -isSlimeChunk() -> boolean -``` +#### Properties -Returns true if the current chunk is a slime chunk. +| table | Description | +| ------------------- | --------------------------------------- | +| radiation: `string` | The current radiation level as a string | +| unit: `string` | The radiation unit | --- -### listDimensions +### getRadiationRaw ``` -listDimensions() -> table +getRadiationRaw() -> number ``` -Returns a table with all of the registered dimensions for the current world, this includes modded dimensions. +!!! success "Added in version 0.6.5b" -!!! example - As an example `listDimensions` might return a table like so: - ``` - {"minecraft:overworld", "minecraft:the_nether", "minecraft:the_end", "twilightforest:twilight_forest"} - ``` +!!! warning "Requirement" + Requires the [Mekanism](https://www.curseforge.com/minecraft/mc-mods/mekanism) mod to be installed + +Returns the current raw radiation level in Sv/h. --- @@ -264,10 +216,11 @@ Returns a table with all of the registered dimensions for the current world, thi scanEntities(range: number) -> table ``` -Returns a table with all entities in the given range -Coordinates are relativ and not absolute +Returns a table with all entities in the given range. +Coordinates are relative and not absolute. !!! example + // TODO: update this example Example output for an entity: ```lua { @@ -288,9 +241,27 @@ Coordinates are relativ and not absolute } ``` +--- + +### scanShips + +``` +scanShips(range: number) -> table +``` + +!!! warning "Requirement" + Requires Valkyrien Skies to be installed. + +Returns a table with all ships in the given range. +Coordinates are relative and not absolute. + +--- ## Changelog/Trivia +**0.8** +Added vs2 integration `scanShips`, `scanShipCost`. + **0.6.5b** Added `getRadiationRaw` diff --git a/docs/peripherals/geo_scanner.md b/docs/peripherals/geo_scanner.md index 7b49012f..a599d073 100644 --- a/docs/peripherals/geo_scanner.md +++ b/docs/peripherals/geo_scanner.md @@ -45,41 +45,38 @@ Returns the maximum amount of possible stored fuel. --- -### cost +### scanBlocks ``` -cost(radius: number) -> number -``` - -Returns the cost in FE for a scan with the given `radius`. - ---- - -### scan -``` -scan(radius: number) -> table | nil, string +scanBlocks(radius: number) -> table | (nil, string) ``` Returns a list of data about all blocks in the radius. Or if the scan fails it returns nil and an error message. #### Block Properties -| block | Description | -| ---------------------- | --------------------------------------- | -| name: `string` | The registry name of the block | -| tags: `table` | A list of block tags | -| x: `number` | The block's x coordinate | -| y: `number` | The block's y coordinate | -| z: `number` | The block's z coordinate | +| block | Description | +| -------------- | ----------------------------------- | +| name: `string` | The registry name of the block | +| tags: `table` | A list of block tags | +| state: `table` | The block states | +| x: `number` | The block's relative x coordinate | +| y: `number` | The block's relative y coordinate | +| z: `number` | The block's relative z coordinate | +| f: `number` | The block's relative front distance | +| r: `number` | The block's relative right distance | +| u: `number` | The block's relative up distance | --- ### chunkAnalyze ``` -chunkAnalyze() -> table | nil, reason +chunkAnalyze(filter: string | nil) -> table | (nil, string) ``` Returns a table of data about how many of each ore type is in the block's chunk. Or if the analyze fails it returns nil and an error message. +`filter` can be a block id, or a block tag starts with `#` + --- ## Changelog/Trivia diff --git a/docs/peripherals/inventory_manager.md b/docs/peripherals/inventory_manager.md index 6ad8e89e..afde3315 100644 --- a/docs/peripherals/inventory_manager.md +++ b/docs/peripherals/inventory_manager.md @@ -26,61 +26,52 @@ The Inventory Manager can communicate with the player's inventory. You need to a --- -!!! failure -

You need to place the inventory you want to use next to the inventory manager and **NOT** next to the computer!

- ## Functions -### addItemToPlayer +### getOwner ``` -addItemToPlayer(direction: string, item: table) -> number +getOwner() -> (string, string) | nil ``` -Adds an item to the player's inventory and returns the amount of the item added. -The `direction` is the direction of the container relative to the peripheral. -The `slot` is the slot to take items from in the container. -The Inventory Manager will add a random item to the player's inventory if the `item` or `slot` argument are not provided. +Returns the uuid and the username of the owner of the memory card in the manager. +Returns `nil` if there is no memory card or owner is offline. -!!! tip "Since version 0.7r" - You can now use both relative (`right`, `left`, `front`, `back`, `top`, `bottom`) and cardinal (`north`, `south`, `east`, `west`, `up`, `down`) directions for the `direction` argument. - -```lua linenums="1" -local manager = peripheral.find("inventory_manager") +--- --- Add 32 cobblestone to the players offhand slot from the block above -manager.addItemToPlayer("up", {name="minecraft:cobblestone", toSlot=36, count=32}) +### size ``` +size() -> number +``` + +Returns the size of the player's inventory. --- -### removeItemFromPlayer +### getCuriosSizes ``` -removeItemFromPlayer(direction: string item: table) -> number +getCuriosSizes() -> table ``` -Removes an item from the player's inventory and returns the amount of the item removed. -The `direction` is the direction of the container relative to the peripheral to put the item into. -The `slot` is the slot to take items from in the player's inventory. -The Inventory Manager will remove a random item from the player's inventory if the `item` or `slot` argument are not provided. -The `slot` and `count` are overwritten if `fromSlot` or `count` is specified in the `item` filter -if the `item` argument is empty, the manager will move any item. +!!! warning "Requirement" + Requires the [Curios API mod](https://modrinth.com/mod/curios) to be installed -```lua linenums="1" -local manager = peripheral.find("inventory_manager") +Returns the sizes of the player's curios inventory. --- Remove up to 5 of the item in slot 1 of the player's inventory --- and place it in the block above -manager.removeItemFromPlayer("up", {name="minecraft:cobblestone", toSlot=3, fromSlot=1, count=5}) +Result format: +``` +{ + []: string = : number +} ``` --- -### getArmor +### list ``` -getArmor() -> table +list() -> table ``` -Returns a list of the player's current armor slots +Returns the contents of the player's inventory as a map of `slot` -> `item`. #### Item Properties @@ -90,109 +81,156 @@ Returns a list of the player's current armor slots | count: `number` | The amount of the item | | maxStackSize: `number` | Maximum stack size for the item type | | displayName: `string` | The item's display name | -| slot: `number` | The slot that the item stack is in | | tags: `table` | A list of item tags | -| nbt: `table` | The item's nbt data | +| components: `table` | The item's component data | -```lua linenums="1" -local manager = peripheral.find("inventory_manager") +--- + +### listCurios +``` +listCurios() -> table +``` + +!!! warning "Requirement" + Requires the [Curios API mod](https://modrinth.com/mod/curios) to be installed + +Returns the contents of the player's curios inventory. -local armor = manager.getArmor() -print("First armor piece is: " .. armor[1].displayName) +Result format: +``` +{ + []: string = { + []: number = : table + } +} ``` --- -### getItems +### pushItems ``` -getItems() -> table +pushItems(toName: string, filter: table) -> number ``` -Returns the contents of the player's inventory as a list of items +Removes items from the player's inventory and returns the amount of the item removed. -#### Item Properties +`toName` is the target inventory's peripheral name. +`filter` is an item filter to define how to move items. -| item | Description | -| ---------------------- | --------------------------------------- | -| name: `string` | The registry name of the item | -| count: `number` | The amount of the item | -| maxStackSize: `number` | Maximum stack size for the item type | -| slot: `number` | The slot that the item stack is in | -| displayName: `string` | The item's display name | -| tags: `table` | A list of item tags | -| nbt: `table` | The item's nbt data | +!!! tip + You can use both relative (`@right`, `@left`, `@front`, `@back`, `@top`, `@bottom`) and cardinal (`@north`, `@south`, `@east`, `@west`, `@up`, `@down`) directions for the `toName` argument to refer to an inventory directly relative to the inventory manager block. + +```lua linenums="1" +local manager = peripheral.find("inventory_manager") + +-- Remove up to 5 of the item in slot 1 of the player's inventory +-- and place it in the block above +manager.pushItems("@up", {name="minecraft:cobblestone", toSlot=3, fromSlot=1, count=5}) +``` --- -### getOwner +### pushCuriosItems ``` -getOwner() -> string | nil +pushCuriosItems(slotName: string, toName: string, filter: table) -> number ``` -Returns the username of the owner of the memory card in the manager or nil if there is no memory card or owner. +!!! warning "Requirement" + Requires the [Curios API mod](https://modrinth.com/mod/curios) to be installed + +Removes items from the player's curios inventory and returns the amount of the item added. --- -### isPlayerEquipped +### pullItems ``` -isPlayerEquipped() -> boolean +pullItems(fromName: string, filter: table) -> number ``` -Returns true if the player is wearing atleast one piece of armor. +Adds items to the player's inventory and returns the amount of the item added. + +`fromName` is the source inventory's peripheral name. +`filter` is an item filter to define how to move items. + +```lua linenums="1" +local manager = peripheral.find("inventory_manager") + +-- Add 32 cobblestone to the players offhand slot from the block above +manager.pullItems("@up", {name="minecraft:cobblestone", toSlot=36, count=32}) +``` --- -### isWearing +### pullCuriosItems ``` -isWearing(slot: number) -> boolean +pullCuriosItems(slotName: string, fromName: string, filter: table) -> number ``` -Returns true if the player is wearing a armor piece on the given slot. -Slots: `103`(Helmet) - `100`(Boots). +!!! warning "Requirement" + Requires the [Curios API mod](https://modrinth.com/mod/curios) to be installed + +Adds items from the player's curios inventory and returns the amount of the item added. --- -### getItemInHand +### wrapStorageItem ``` -getItemInHand() -> table +wrapStorageItem(slot: number) -> table ``` -!!! success "Added in version 0.7.4r" +Returns the wrapped operations of a storage item (e.g. backpack, bucket). -Returns the item in the player's main hand. +#### Wrapped Operations -#### Item Properties +| Operation | Description | +| --------------------------- | ------------------------------------------------------ | +| `isValid(): boolean` | If other operations are still valid to perform. | +| `isItemStorage(): boolean` | If item operations are valid to perform on this item. | +| `isFluidStorage(): boolean` | If fluid operations are valid to perform on this item. | -| item | Description | -| ---------------------- | --------------------------------------- | -| name: `string` | The registry name of the item | -| count: `number` | The amount of the item | -| maxStackSize: `number` | Maximum stack size for the item type | -| displayName: `string` | The item's display name | -| tags: `table` | A list of item tags | -| nbt: `table` | The item's nbt data | +| Item operation | Description | +| ------------------------------------------------ | ------------------------------------------------------------ | +| `size(): number` | Returns the inventory size of the storage item. | +| `list(): table` | List the available item in the storage item. | +| `pushItems(name: string, filter: table): number` | Push items from the storage item to an inventory peripheral. | +| `pullItems(name: string, filter: table): number` | Pull items from an inventory peripheral to the storage item. | + +| Fluid operation | Description | +| ------------------------------------------------ | --------------------------------------------------------------- | +| `tanks(): table` | List the available tanks in the storage item. | +| `pushFluid(name: string, filter: table): number` | Push fluid from the storage item to a fluid storage peripheral. | +| `pullFluid(name: string, filter: table): number` | Pull fluid from a fluid storage peripheral to the storage item. | --- -### getItemInOffHand +### wrapCuriosStorageItem ``` -getItemInOffHand() -> table +wrapCuriosStorageItem(slotName: number, slot: number) -> table ``` -!!! success "Added in version 0.7.4r" +!!! warning "Requirement" + Requires the [Curios API mod](https://modrinth.com/mod/curios) to be installed -Returns the item in the player's off hand. +Returns the wrapped operations of a storage item (e.g. backpack, bucket) in curios inventory. -#### Item Properties +--- -| item | Description | -| ---------------------- | --------------------------------------- | -| name: `string` | The registry name of the item | -| count: `number` | The amount of the item | -| maxStackSize: `number` | Maximum stack size for the item type | -| displayName: `string` | The item's display name | -| tags: `table` | A list of item tags | -| nbt: `table` | The item's nbt data | +### isWearing +``` +isWearing(armorIndex: number) -> boolean +``` + +Returns true if the player is wearing a armor piece on the given slot. +Armor index: `4`(Helmet) - `1`(Boots). + +--- + +### getEmptySlots +``` +getEmptySlots() -> number +``` + +Returns the number of empty slots in the player's inventory. --- @@ -201,31 +239,34 @@ Returns the item in the player's off hand. getFreeSlot() -> number ``` -!!! success "Added in version 0.7.4r" - -Returns the next free slot in the player's inventory. Or -1 if their inventory is full. +Returns the next free slot in the player's inventory. Or `0` if their inventory is full. --- -### isSpaceAvailable +### getHandSlot ``` -isSpaceAvailable() -> boolean +getHandSlot() -> number ``` -!!! success "Added in version 0.7.4r" - -Returns true if space is available in the player's inventory. +Returns the player's selected slot. --- -### getEmptySpace +### getItemInHand ``` -getEmptySpace() -> number +getItemInHand() -> table ``` -!!! success "Added in version 0.7.4r" +Returns the item in the player's main hand. + +--- -Returns the number of empty slots in the player's inventory. +### getItemInOffHand +``` +getItemInOffHand() -> table +``` + +Returns the item in the player's off hand. --- diff --git a/docs/peripherals/me_bridge.md b/docs/peripherals/me_bridge.md deleted file mode 100644 index 926d3c00..00000000 --- a/docs/peripherals/me_bridge.md +++ /dev/null @@ -1,445 +0,0 @@ ---- -comments: true ---- - -# ME Bridge - -!!! picture inline end - ![!Image of the ME Bridge block](../img/previews/me_bridge.png){ align=right } - -The ME Bridge is able to interact with Applied Energistics 2. -You can retrieve items, craft items, get all items as a list and more. The ME Bridge uses one channel. - -!!! warning "Requirement" - Requires the [Applied Energistics 2](https://www.curseforge.com/minecraft/mc-mods/applied-energistics-2) mod to be installed - -

- ---- - -
- -| Peripheral Name | Interfaces with | Has events | Introduced in | -| --------------- | --------------- | ---------- | ------------- | -| me_bridge | ME System | Yes | 0.3b | - -
- ---- - -!!! failure -

You need to place the inventory/tank you want to use to export/import stuff next to the ME Bridge and **NOT** next to the computer!

- -## Events - -### crafting -Fires when a crafting job starts or fails. -**Values:** -1. `success: boolean` Indicates whether a crafting job has successfully started or not -2. `message: string` A message about the status of the crafting job -These values are equivalent to the return values of [`craftItem()`](#craftitem). - -```lua linenums="1" -local event, success, message = os.pullEvent("crafting") -if success then - print("A crafting job has successfully started") -else - print("A crafting job has failed to start") -end -``` - -!!! Warning - The `crafting` event will fire when the ME Bridge is connected to an active ME System that is performing crafting operations. These operations **need** to be started by the bridge itself! - ---- - -!!! tip - You can use the command `/advancedperipherals getHashItem` with an item in your hand to get the MD5 hash of the NBT tags of the item. An MD5 Hash can look like this `ae70053c97f877de546b0248b9ddf525`. - -## Functions - -!!! info - The item arguments(`item: table`) accepts our item filters, you can check the syntax of these filters [here](/../guides/filters). - - -### craftItem -``` -craftItem(item: table[, craftingCpu: string]) -> boolean, err: string -``` - -Tries to craft the provided `item`. If a `craftingCpu`'s name is provided then it will use that cpu to craft the `item`. - -#### Item Properties - -Check the [item filters guide](/../guides/filters) for more info! - -| item | Description | -| ---------------- | ------------------------------------------- | -| name: `string` | The registry name of the item or a tag | -| count: `number?` | The amount of the item to craft | -| nbt: `string?` | NBT to match the item on | - -**OR** - -| item | Description | -| --------------------- | ------------------------------------------- | -| fingerprint: `string` | A unique fingerprint which identifies the
item to craft | -| count: `number?` | The amount of the item to craft | - ---- - -### craftFluid -``` -craftFluid(fluid: table[, craftingCpu: string]) -> boolean, err: string -``` - -Tries to craft the provided `fluid`. If a `craftingCpu`'s name is provided then it will use that cpu to craft the `fluid`. - -#### Fluid Properties - -Check the [fluid filters guide](/../guides/filters) for more info! - -| fluid | Description | -| ---------------- | ------------------------------------------- | -| name: `string` | The registry name of the fluid or a tag | -| count: `number?` | The amount of the fluid to craft | -| nbt: `string?` | NBT to match the fluid on | - -**OR** - -| fluid | Description | -| --------------------- | ------------------------------------------- | -| fingerprint: `string` | A unique fingerprint which identifies the
fluid to craft | -| count: `number?` | The amount of the fluid to craft | ---- - -### getItem -``` -getItem(item: table) -> table, err: string -``` - -Returns a table with information about the item type in the system. - -#### Properties - -| result | Description | -| ---------------------- | ------------------------------------------------------- | -| name: `string` | The registry name of the item | -| fingerprint: `string?` | A unique fingerprint which identifies the item to craft | -| amount: `number` | The amount of the item in the system | -| displayName: `string` | The display name for the item | -| isCraftable: `boolean` | Whether the item has a crafting pattern or not | -| nbt: `string?` | NBT to match the item on | -| tags: `table` | A list of all of the item tags | - ---- - -### importItem -``` -importItem(item: table, direction: string) -> number, err: string -``` - -Imports an `item` from a container in the `direction` to the ME System. -Returns the number of the `item` imported into the system. - -!!! tip "Since version 0.7r" - You can now use both relative (`right`, `left`, `front`, `back`, `top`, `bottom`) and cardinal (`north`, `south`, `east`, `west`, `up`, `down`) directions for the `direction` argument. - -```lua linenums="1" -local bridge = peripheral.find("me_bridge") - --- Imports 32 dirt from the container above into the system -bridge.importItem({name="minecraft:dirt", count=1}, "up") -``` - ---- - -### exportItem -``` -exportItem(item: table, direction: string) -> number, err: string -``` - -Exports an `item` to a container in the `direction` from the ME bridge block. -Returns the number of the `item` exported into the container. - -```lua linenums="1" -local bridge = peripheral.find("me_bridge") - --- Exports 1 "Protection I" book into the container above -bridge.exportItem({name="minecraft:enchanted_book", count=1, nbt="ae70053c97f877de546b0248b9ddf525"}, "up") -``` - ---- - -### importItemFromPeripheral -``` -importItemFromPeripheral(item: table, container: string) -> number, err: string -``` - -Similar to [`importItem()`](#importitem) it imports an `item` from a container which is connected to the peripheral network. -`container` should be the exact name of the container peripheral on the network. -Returns the number of the `item` imported from the container. - ---- - -### exportItemToPeripheral -``` -exportItemToPeripheral(item: table, container: string) -> number, err: string -``` - -Similar to [`exportItem()`](#exportitem) it exports an `item` to a container which is connected to the peripheral network. -`container` should be the exact name of the container peripheral on the network. -Returns the number of the `item` exported into the container. - ---- - -### getEnergyStorage -``` -getEnergyStorage() -> number, err: string -``` - -Returns the stored energy of the whole ME System in AE. - ---- - -### getMaxEnergyStorage -``` -getMaxEnergyStorage() -> number, err: string -``` - -Returns the maximum energy storage capacity of the whole ME system in AE. - ---- - -### getEnergyUsage -``` -getEnergyUsage() -> number, err: string -``` - -Returns the energy usage of the whole ME System in AE/t. - ---- - -### getCraftingCPUs -``` -getCraftingCPUs() -> table, err: string -``` - -Returns a list of all connected crafting cpus. - -#### CPU Properties - -| cpu | Description | -| ---------------------- | -------------------------------------- | -| storage: `number` | The amount of storage the CPU has | -| coProcessors: `number` | The number of coprocessors the CPU has | -| isBusy: `boolean` | If the cpu is currently crafting | - ---- - -### isItemCrafting -``` -isItemCrafting(item: table[, craftingCpu: string]) -> boolean, err: string -``` - -Returns true if a crafting job for the `item` exists. If a `craftingCpu`'s name is provided then it will check only if that cpu is crafting the `item`. - ---- - -### isItemCraftable -``` -isItemCraftable(item: table) -> boolean, err: string -``` - -Returns true if the `item` is craftable. - ---- - -### listCraftableItems -``` -listCraftableItems() -> table, err: string -``` - -Returns a list of information about all craftable items - -#### Properties - -| item / fluid | Description | -| ---------------------- | ------------------------------------------------------- | -| name: `string` | The registry name of the item | -| fingerprint: `string?` | A unique fingerprint which identifies the item to craft | -| amount: `number` | The amount of the item in the system | -| displayName: `string` | The display name for the item | -| isCraftable: `boolean` | Whether the item has a crafting pattern or not | -| nbt: `string?` | NBT to match the item on | -| tags: `table` | A list of all of the item tags | - -```lua linenums="1" -local bridge = peripheral.find("me_bridge") - --- print out all craftable items -craftableItems = bridge.listCraftableItems() -for _, item in pairs(craftableItems) do - print(item.name) -end -``` - ---- - -### listCraftableFluid -``` -listCraftableFluid() -> table, err: string -``` - -Returns a list of information about all craftable fluids - ---- - -### listItems -``` -listItems() -> table, err: string -``` - -Returns a list of information about all items in the ME System. - ---- - -### listFluid -``` -listFluid() -> table, err: string -``` - -Returns a list of information about all fluids in the ME System. - ---- - -### listGas -``` -listGas() -> table, err: string -``` - -Returns a list of information about all gases (Applied Mekanistics) in the ME System. - ---- - -!!! success "Added in version 1.18.2-0.7.24r | 1.19.2-0.7.23b" - -### listCells -``` -listCells() -> table, err: string -``` - -Returns a list of information about all cells in the disk drives of the ME System. - - -| cell | Description | -| ---------------------- | -------------------------------------- | -| item: `string` | The name of the cell. e.g. `ae2:64k_storage_cell | -| cellType: `string` | The type of the cell. `item` or `fluid`| -| bytesPerType: `int` | The bytes per type | -| totalBytes: `int` | Total available bytes of the cell | - ---- - -!!! success "Added in version 1.18.2-0.7.24r | 1.19.2-0.7.23b" - -### getTotalItemStorage -``` -getTotalItemStorage() -> int, err: string -``` - -Returns how much total item storage the system offers - ---- - -!!! success "Added in version 1.18.2-0.7.24r | 1.19.2-0.7.23b" - -### getTotalFluidStorage -``` -getTotalFluidStorage() -> int, err: string -``` - -Returns how much total fluid storage the system offers - ---- - -!!! success "Added in version 1.18.2-0.7.24r | 1.19.2-0.7.23b" - -### getUsedItemStorage -``` -getUsedItemStorage() -> int, err: string -``` - -Returns how much item storage is used - ---- - -!!! success "Added in version 1.18.2-0.7.24r | 1.19.2-0.7.23b" - -### getUsedFluidStorage -``` -getUsedFluidStorage() -> int, err: string -``` - -Returns how much fluid storage is used - ---- - -!!! success "Added in version 1.18.2-0.7.24r | 1.19.2-0.7.23b" - -### getAvailableItemStorage -``` -getAvailableItemStorage() -> int, err: string -``` - -Returns how much item storage is available - ---- - -!!! success "Added in version 1.18.2-0.7.24r | 1.19.2-0.7.23b" - -### getAvailableFluidStorage -``` -getAvailableFluidStorage() -> int, err: string -``` - -Returns how much fluid storage is available - ---- - -## Examples - -### Automatic Autocrafting - -This script automatically crafts items in a list. -Do you want 500 glass in your me system at all times? Add glass to the list and the script will craft it for you. -No need for level emitters or crafting cards! - -You can find instructions on how to install the script [here](https://github.com/SirEndii/Lua-Projects/tree/master) - -![Automatic autocrafting example script preview](../img/me_bridge/autocraft_example.png) - -### ME Crafting CPUs - -This script shows you some statistics about the ME crafting cpus. - -You can find instructions on how to install the script [here](https://github.com/SirEndii/Lua-Projects/tree/master) - -![Me system crafting cpu example script preview](../img/me_bridge/mecpus_example.png) - ---- - -## Changelog/Trivia - -**0.7r** -The ME Bridge does uses computercraft relative and cardinal directions. -We also changed some function names. - -**0.4b** -Reworked the system of the ME Bridge, it now has more features and a new system for the `item` parameter. - -**0.3.9b** -Added the `importItem` and `exportItem` from container functions. - -**0.3b** -Added the ME Bridge with a good amount of features. diff --git a/docs/peripherals/nbt_storage.md b/docs/peripherals/nbt_storage.md index 6a12b90f..33ef19a6 100644 --- a/docs/peripherals/nbt_storage.md +++ b/docs/peripherals/nbt_storage.md @@ -25,35 +25,27 @@ NBT Storage is a custom block that allows reading and writing of NBT data to the ## Functions -### read +### load ``` -read() -> table +load() -> table ``` Returns the NBT data stored in the block. --- -### writeJson +### save ``` -writeJson(json: string) -> boolean | nil, string +save(data: string | table) -> boolean | nil, string ``` -Writes the json as NBT data into the block and returns true if the json is valid and the data is successfully written. Otherwise it returns nil and an error message. - ---- - -### writeTable -``` -writeTable(nbt: table) -> boolean | nil, string -``` - -Writes NBT data into the block and returns true if the data is successfully written. Otherwise it returns nil and an error message. +Writes NBT data into the block and returns true if the data is successfully written. Otherwise it returns nil and an error message. +If the `data` is a string, it will be parsed as [SNBT format](https://minecraft.wiki/w/NBT_format#SNBT_format). ```lua linenums="1" local storage = peripheral.find("nbt_storage") -storage.writeTable({ +storage.save({ specialString = "A super special string" }) diff --git a/docs/peripherals/player_detector.md b/docs/peripherals/player_detector.md index cec746f4..ef013f53 100644 --- a/docs/peripherals/player_detector.md +++ b/docs/peripherals/player_detector.md @@ -26,62 +26,62 @@ You can get a list of all online players and detect when a player clicks on the ## Events -### playerClick +### player_click Fires when a player clicks on the block. -**Values:** -1. `username: string` The username of the player who clicked the block -2. `devicename: string` The name of the peripheral like `playerDetector_4` +**Values:** +1. `peripheralName: string` The name of the peripheral (e.g. `player_detector_4`) +2. `uuid: string` The uuid of the player who clicked the block +3. `username: string` The name of the player who clicked the block ```lua linenums="1" -local event, username, device = os.pullEvent("playerClick") +local event, peripheralName, uuid, username = os.pullEvent("player_click") print("The detector " .. device .. " was clicked by " .. username) ``` -### playerJoin +### player_join Fires when a player joins the world/a server. -**Values:** - -1. `username: string` The username of the player who clicked the block -2. `dimension: string` The resource id of the dimension the player is in +**Values:** +1. `uuid: string` The uuid of the player +2. `username: string` The name of the player +3. `dimension: string` The resource id of the dimension the player is in ```lua linenums="1" -local event, username, dimension = os.pullEvent("playerJoin") +local event, uuid, username, dimension = os.pullEvent("player_join") print("Player " .. username .. " joined the server in the dimension " .. dimension) ``` -### playerLeave +### player_leave Fires when a player leaves the world/a server. -**Values:** - -1. `username: string` The username of the player who clicked the block -2. `dimension: string` The resource id of the dimension the player was in +**Values:** +1. `uuid: string` The uuid of the player +2. `username: string` The name of the player +3. `dimension: string` The resource id of the dimension the player was in ```lua linenums="1" -local event, username, dimension = os.pullEvent("playerLeave") +local event, uuid, username, dimension = os.pullEvent("player_leave") print("Player " .. username .. " left the server in the dimension " .. dimension) ``` -### playerChangedDimension +### player_changed_dimension Fires when a player changes dimensions. -**Values:** - -1. `username: string` The username of the player who clicked the block -2. `fromDim: string` The resource id of the dimension the player was in -2. `toDim: string` The resource id of the dimension the player is in +**Values:** +1. `uuid: string` The uuid of the player +2. `username: string` The name of the player +3. `fromDim: string` The resource id of the dimension the player was in +4. `toDim: string` The resource id of the dimension the player is in ```lua linenums="1" -local event, username, fromDim, toDim = os.pullEvent("playerChangedDimension") +local event, uuid, username, fromDim, toDim = os.pullEvent("player_changed_dimension") print("Player " .. username .. " left the dimension " .. fromDim .. " and is now in " .. toDim) ``` !!! info The events will fire when a player detector has been connected to a computer. You don't have to `.wrap()` or `.find()` the peripheral (unless you intend to send messages). - --- ## Functions @@ -89,10 +89,10 @@ print("Player " .. username .. " left the dimension " .. fromDim .. " and is now !!! info The player detector supports multidimensional spying(Since 1.19.2-0.7.30r & 1.20.1-0.7.32a). This only works if the config option `playerDetMultiDimensional` is set to true and the option `playerDetMaxRange` is set to -1(infinite) -### getPlayerPos / getPlayer +### getPlayer ``` -getPlayerPos(username: string) -> table | nil +getPlayer(username: string) -> table | nil ``` Returns information about the player with the `username` passed. @@ -103,25 +103,30 @@ Returns information about the player with the `username` passed. | table | Description | |----------------------------|--------------------------------------------| +| x: `number` | The x coordinate | +| y: `number` | The y coordinate | +| z: `number` | The z coordinate | +| f: `number` | The relative front distance | +| r: `number` | The relative right distance | +| u: `number` | The relative up distance | +| uuid: `string` | The uuid of the player | +| name: `string` | The name of the player | +| yaw: `number` | The yaw of the player's head | +| pitch: `number` | The pitch of the player's head | | dimension: `string` | The dimension the player is in | | eyeHeight: `number` | The height of the player's eyes | -| pitch: `number` | The pitch of the player's head | | health: `number` | The health of the player | | maxHealth: `number` | The max health of the player | | airSupply: `number` | The air supply of the player | | respawnPosition: `number` | The respawn position of the player | | respawnDimension: `number` | The respawn dimension of the player | | respawnAngle: `number` | The respawn angle of the player in degrees | -| yaw: `number` | The yaw of the player's head | -| x: `number` | The x coordinate | -| y: `number` | The y coordinate | -| z: `number` | The z coordinate | ```lua linenums="1" local detector = peripheral.find("player_detector") -- Get the position of Player123 and print their coordinates -local pos = detector.getPlayerPos("Player123") +local pos = detector.getPlayer("Player123") print("Position: " .. pos.x .. "," .. pos.y .. "," .. pos.z) ``` diff --git a/docs/peripherals/rs_bridge.md b/docs/peripherals/rs_bridge.md deleted file mode 100644 index a672c51e..00000000 --- a/docs/peripherals/rs_bridge.md +++ /dev/null @@ -1,380 +0,0 @@ ---- -comments: true ---- - -# RS Bridge - -!!! picture inline end - ![!Image of the RS Bridge block](../img/previews/rs_bridge.png){ align=right } - -The RS Bridge is able to interact with Refined Storage. -You can retrieve items, craft items, get all items as a list and more. - -!!! warning "Requirement" - Requires the [Refined Storage](https://www.curseforge.com/minecraft/mc-mods/refined-storage) mod to be installed - -

- ---- - -
- -| Peripheral Name | Interfaces with | Has events | Introduced in | -| --------------- | --------------- | ---------- | ------------- | -| rs_bridge | Refined Storage | No | 0.3.6b | - -
- ---- - -!!! failure -

You need to place the inventory/tank you want to use to export/import stuff next to the RS Bridge and **NOT** next to the computer!

- -!!! tip - You can use the command `/advancedperipherals getHashItem` with an item in your hand to get the MD5 hash of the NBT tags of the item. An MD5 Hash can look like this `ae70053c97f877de546b0248b9ddf525`. - -## Functions - -!!! info - The item arguments(`item: table`) accepts our item filters, you can check the syntax of these filters [here](/../guides/filters). - -### craftItem -``` -craftItem(item: table) -> boolean -``` - -Tries to craft the provided `item`, returns true if it successfully starts crafting. - -#### Item Properties - -Check the [item filters guide](/../guides/filters) for more info! - -| item | Description | -| ---------------- | ------------------------------------------- | -| name: `string` | The registry name of the item or a tag | -| count: `number?` | The amount of the item to craft | -| nbt: `string?` | NBT to match the item on | - -**OR** - -| item | Description | -| --------------------- | ------------------------------------------- | -| fingerprint: `string` | A unique fingerprint which identifies the
item to craft | -| count: `number?` | The amount of the item to craft | - ---- - -### craftFluid -``` -craftFluid(fluid: table, amount: number) -> boolean -``` - -Tries to craft the provided `fluid` of the given `amount`, returns true if it successfully starts crafting. - -#### Fluid Properties - -Check the [fluid filters guide](/../guides/filters) for more info! - -| fluid | Description | -| ---------------- | ------------------------------------------- | -| name: `string` | The registry name of the fluid or a tag | -| count: `number?` | The amount of the fluid to craft | -| nbt: `string?` | NBT to match the fluid on | - -**OR** - -| fluid | Description | -| --------------------- | ------------------------------------------- | -| fingerprint: `string` | A unique fingerprint which identifies the
fluid to craft | -| count: `number?` | The amount of the fluid to craft - ---- - -### getItem -``` -getItem(item: table) -> table -``` - -Returns a table with information about the item type in the system. - -#### Properties - -| result | Description | -| ---------------------- | ------------------------------------------------------- | -| name: `string` | The registry name of the item | -| fingerprint: `string?` | A unique fingerprint which identifies the item to craft | -| amount: `number` | The amount of the item in the system | -| displayName: `string` | The display name for the item | -| isCraftable: `boolean` | Whether the item has a crafting pattern or not | -| nbt: `string?` | NBT to match the item on | -| tags: `table` | A list of all of the item tags | - ---- - -### importItem -``` -importItem(item: table, direction: string) -> number -``` - -Imports an `item` from a container in the `direction` to the RS System. -Returns the number of the `item` imported into the system. - -!!! tip "Since version 0.7r" - You can now use both relative (`right`, `left`, `front`, `back`, `top`, `bottom`) and cardinal (`north`, `south`, `east`, `west`, `up`, `down`) directions for the `direction` argument. - -```lua linenums="1" -local bridge = peripheral.find("rs_bridge") - --- Imports 32 dirt from the container above into the system -bridge.importItem({name="minecraft:dirt", count=1}, "up") -``` - ---- - -### exportItem -``` -exportItem(item: table, direction: string) -> number -``` - -Exports an `item` to a container in the `direction` from the RS bridge block. -Returns the number of the `item` exported into the container. - -```lua linenums="1" -local bridge = peripheral.find("rs_bridge") - --- Exports 1 "Protection I" book into the container above -bridge.exportItem({name="minecraft:enchanted_book", count=1, nbt="ae70053c97f877de546b0248b9ddf525"}, "up") -``` - ---- - -### importItemFromPeripheral -``` -importItemFromPeripheral(item: table, container: string) -> number -``` - -Similar to [`importItem()`](#importitem) it imports an `item` from a container which is connected to the peripheral network. -`container` should be the exact name of the container peripheral on the network. -Returns the number of the `item` imported from the container. - ---- - -### exportItemToPeripheral -``` -exportItemToPeripheral(item: table, container: string) -> number -``` - -Similar to [`exportItem()`](#exportitem) it exports an `item` to a container which is connected to the peripheral network. -`container` should be the exact name of the container peripheral on the network. -Returns the number of the `item` exported into the container. - ---- - -### getMaxItemDiskStorage -``` -getMaxItemDiskStorage() -> number -``` - -!!! success "Added in version 0.7.3r" - -Returns the total amount of available item disk storage. - ---- - -### getMaxFluidDiskStorage -``` -getMaxItemDiskStorage() -> number -``` - -!!! success "Added in version 0.7.3r" - -Returns the total amount of available fluid disk storage. - ---- - -### getMaxItemExternalStorage -``` -getMaxItemExternalStorage() -> number -``` - -!!! success "Added in version 0.7.3r" - -Returns the total amount of available external item disk storage. - ---- - -### getMaxFluidExternalStorage -``` -getMaxFluidExternalStorage() -> number -``` - -!!! success "Added in version 0.7.3r" - -Returns the total amount of available external fluid disk storage. - ---- - -### getEnergyStorage -``` -getEnergyStorage() -> number -``` - -Returns the stored energy of the whole RS System in FE. - ---- - -### getMaxEnergyStorage -``` -getMaxEnergyStorage() -> number -``` - -Returns the maximum energy storage capacity of the whole RS system in FE. - ---- - -### getEnergyUsage -``` -getEnergyUsage() -> number -``` - -Returns the energy usage of the whole RS System in FE/t. - ---- - -### getPattern -``` -getPattern(item: table) -> table | nil, string -``` - -!!! success "Added in version 0.7.3r" - -Returns the crafting pattern for the `item` if one exists. - -#### Properties - -| pattern | Description | -| --------------------- | ------------------------------------------------------- | -| inputs: `table` | A list of all the input items | -| outputs: `table` | A list of all of the output items | -| byproducts: `table` | A list of any byproduct items | -| processing: `boolean` | If the pattern is currently being used in crafting | - ---- - -### isItemCrafting -``` -isItemCrafting(item: table) -> boolean -``` - -Returns true if a crafting job for the `item` exists. - ---- - -### isItemCraftable -``` -isItemCraftable(item: table) -> boolean -``` - -!!! success "Added in version 0.7.3r" - -Returns true if the `item` is craftable. - ---- - -### listCraftableItems -``` -listCraftableItems() -> table -``` - -!!! danger "Does not exist in versions >=0.7.3r, <0.7.10b" - -Returns a list of information about all craftable items - -#### Properties - -| item / fluid | Description | -| ---------------------- | ------------------------------------------------------- | -| name: `string` | The registry name of the item | -| fingerprint: `string?` | A unique fingerprint which identifies the item to craft | -| amount: `number` | The amount of the item in the system | -| displayName: `string` | The display name for the item | -| isCraftable: `boolean` | Whether the item has a crafting pattern or not | -| nbt: `string?` | NBT to match the item on | -| tags: `table` | A list of all of the item tags | - -```lua linenums="1" -local bridge = peripheral.find("rs_bridge") - --- print out all craftable items -craftableItems = bridge.listCraftableItems() -for _, item in pairs(craftableItems) do - print(item.name) -end -``` - ---- - -### listCraftableFluids -``` -listCraftableFluids() -> table -``` - -!!! danger "Does not exist in versions >=0.7.3r, <0.7.10b" - -Returns a list of information about all craftable fluids - ---- - -### listItems -``` -listItems() -> table -``` - -Returns a list of information about all items in the RS System. - ---- - -### listFluids -``` -listFluids() -> table -``` - -Returns a list of information about all fluids in the RS System. - ---- - -## Examples - -### Autocrafting script - -Here is a script to craft items, the computer will re-craft every item needed (a specified amount) in the RS system. Everything is adjustable. - -[Click here](https://gist.github.com/Seniorendi/26bd8ecaec400146f2e38790faceead8) to view the script - -!!! bug - This script does not work on versions above 0.4b - ---- - -## Changelog/Trivia - -**0.7.10b** -Ported RS Bridge to 1.18.1. -Added `listCraftableItems` and `listCraftableFluids` back. - -**0.7.3r** -Added `getMaxItemDiskStorage`, `getMaxFluidDiskStorage`, `getMaxItemExternalStorage`, `getMaxFluidExternalStorage`, `getPattern` and `isItemCraftable`. -Removed `listCraftableItems` and `listCraftableFluids`. - -**0.7r** -The RS Bridge does uses computercraft relative and cardinal directions. -We also changed some function names. - -**0.4b** -Reworked the system of the RS Bridge, it has now more features and a new system for the `item` parameter. - -**0.3.9b** -Added the `importItem` and `exportItem` from container functions. - -**0.3.6b** -Added the RS Bridge with a good amount of features. diff --git a/docs/turtles/compass_turtle.md b/docs/turtles/compass_turtle.md index 0d3fda5a..be0b70dd 100644 --- a/docs/turtles/compass_turtle.md +++ b/docs/turtles/compass_turtle.md @@ -1,7 +1,11 @@ +--- +comments: true +--- + # Compass Turtle !!! picture inline end - No Picture for now :c + ![!Image of the Compass Turtle](../img/previews/compass_turtle.png){ align=right } The Compass Turtle allow you to know which direction is your turtle facing. The magnet power inside compass also allows you to place blocks more accurately with Automata Core. diff --git a/docs/turtles/metaphysics/end_automata.md b/docs/turtles/metaphysics/end_automata.md index 3102eeba..96e4e440 100644 --- a/docs/turtles/metaphysics/end_automata.md +++ b/docs/turtles/metaphysics/end_automata.md @@ -72,6 +72,15 @@ Returns true if the location is successfully saved, or nil and an error message. --- +### deletePoint +``` +deletePoint(name: string) -> true | nil, string +``` +Delete a saved warp point with the given `name`. +Returns true if the warp point exists and is successfully removed, or nil and an error message. + +--- + ### distanceToPoint ``` distanceToPoint(name: string) -> number | nil, string @@ -105,7 +114,38 @@ Returns true if the turtle is successfully teleported or nil and an error messag --- +### portalShipPrepare +``` +portalShipPrepare(direction: string | nil) -> table | nil, string +``` +Prepare to cross a portal. +Direction includes `up`, `top`, `down`, `bottom`, and `front` (default). +If a portal is detected, a table with target dimension's information will be returns. Or nil and an error message. + +| Field | Type | Description | +| ---------- | --------- | ----------- | +| `name` | `string` | Target dimension's ID | +| `pos` | `string` | Position after teleport | +| `facing` | `string` | Facing direction after teleport | +| `costs` | `number` | Costs to active teleport | +| `canSpawn` | `boolean` | `true` if the destination is not blocked so turtle can perform the teleport, `false` otherwise. | +| `shipId` | `string` | The teleport id, uses in `portalShipActive` | + +--- + +### portalShipActive +``` +portalShipActive(shipId: string) -> true | nil, string +``` +Active a portal and teleport through it. +Can only be invoked in a short period after `portalShipPrepare` returns the `shipId`. + +--- + ## Changelog/Trivia +**0.8** +Added cross portal ability to end automata. + **0.7r** Added the End Automata diff --git a/docs/turtles/metaphysics/weak_automata.md b/docs/turtles/metaphysics/weak_automata.md index 88ea51e4..a91edaa2 100644 --- a/docs/turtles/metaphysics/weak_automata.md +++ b/docs/turtles/metaphysics/weak_automata.md @@ -246,8 +246,60 @@ Returns true if it successfully placed block or nil and an error message. --- +### isOnShip +``` +isOnShip() -> boolean +``` + +!!! warning "Requirement" + Requires Valkyrien Skies to be installed. + +Returns `true` if turtle is on an assembled ship, `false` otherwise. + +--- + +### getCurrentShip +``` +getCurrentShip() -> table | nil +``` + +!!! warning "Requirement" + Requires Valkyrien Skies to be installed. + +Returns a table contains current ship's information, or `nil` if the turtle is not on a ship. + +--- + +### canMountToShip +``` +canMountToShip() -> table | nil +``` + +!!! warning "Requirement" + Requires Valkyrien Skies to be installed. + +Returns a table contains mountable ships' slugs, or `nil` if no ship is found. + +--- + +### mountToShip +``` +mountToShip(slug: string | nil) -> true | false, string +``` + +!!! warning "Requirement" + Requires Valkyrien Skies to be installed. + +Mount to a ship with given slug. Or chose a random one if no slug is provided. +Returns `true` if mount is succeed. Or `false` and an error message. + +--- + ## Changelog/Trivia +**0.8** +Added vs2 integration `isOnShip`, `getCurrentShip`, `canMountToShip`, and `mountToShip`. + **0.7.36r** Added `placeBlock` method for accure placement. diff --git a/docs/turtles/saddle_turtle.md b/docs/turtles/saddle_turtle.md new file mode 100644 index 00000000..a7c09f89 --- /dev/null +++ b/docs/turtles/saddle_turtle.md @@ -0,0 +1,59 @@ +--- +comments: true +--- + +# Saddle Turtle + +!!! picture inline end + ![!Image of the Saddle Turtle](../img/previews/saddle_turtle.png){ align=right } + +The Saddle Turtle allow you to capture an entity or a player on to the turtle. + +

+ +--- + +## Functions + +--- + +### capture +``` +capture() -> true | (nil, string) +``` + +Capture an entity / player in front of the turtle. + +--- + +### release +``` +release() -> true | (nil, string) +``` + +Release the current rider from the turtle. + +--- + +### hasRider +``` +hasRider() -> boolean +``` + +Check if the turtle has a rider. + +--- + +### getRider +``` +getRider(detailed: boolean) -> table | (nil, string) +``` + +Get the rider's information. + +--- + +## Changelog/Trivia + +**0.8** +Added the Saddle Turtle diff --git a/mkdocs.yml b/mkdocs.yml index 98e997c2..6a55fcbe 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -2,113 +2,115 @@ site_name: Advanced Peripherals site_url: 'https://docs.advanced-peripherals.de/' nav: - - 'Home': 'index.md' - - 'Blog': - - blog/index.md - - 'Guides': - - 'How to: report a bug or request a feature': 'guides/how_to_report.md' - - 'Item and Fluid Filters': 'guides/filters.md' - - 'Cooldowns and Fuel consumption': 'guides/cooldowns_and_fuel_consumption.md' - - 'Peripherals': - - 'Chat Box': 'peripherals/chat_box.md' - - 'Energy Detector': 'peripherals/energy_detector.md' - - 'Environment Detector': 'peripherals/environment_detector.md' - - 'Player Detector': 'peripherals/player_detector.md' - - 'Inventory Manager': 'peripherals/inventory_manager.md' - - 'NBT Storage': 'peripherals/nbt_storage.md' - - 'Block Reader': 'peripherals/block_reader.md' - - 'Geo Scanner': 'peripherals/geo_scanner.md' - - 'Redstone Integrator': 'peripherals/redstone_integrator.md' - - 'AR Controller': 'peripherals/ar_controller.md' - - 'ME Bridge': 'peripherals/me_bridge.md' - - 'RS Bridge': 'peripherals/rs_bridge.md' - - 'Colony Integrator': 'peripherals/colony_integrator.md' - - 'Turtles': - - 'Chatty Turtle': 'turtles/chatty_turtle.md' - - 'Chunky Turtle': 'turtles/chunky_turtle.md' - - 'Compass Turtle': 'turtles/compass_turtle.md' - - 'Environment Turtle': 'turtles/environment_turtle.md' - - 'Player Turtle': 'turtles/player_turtle.md' - - 'Geoscanning Turtle': 'turtles/geo_scanner_turtle.md' - - 'Metaphysics': - - 'Weak Automata': 'turtles/metaphysics/weak_automata.md' - - 'Husbandry Automata': 'turtles/metaphysics/husbandry_automata.md' - - 'End Automata': 'turtles/metaphysics/end_automata.md' - - 'Overpowered Automata': 'turtles/metaphysics/overpowered_automata.md' - - 'Items': - - 'AR Goggles': 'items/ar_goggles.md' - - 'Chunk Controller': 'items/chunk_controller.md' - - 'Computer Tool': 'items/computer_tool.md' - - 'Memory Card': 'items/memory_card.md' - - 'Pocket Computers': 'items/pocket_computer.md' - - 'Mod Integrations': - - 'integrations/index.md' - - 'Minecraft': - - 'Beacon': 'integrations/minecraft/beacon.md' - - 'Note Block': 'integrations/minecraft/noteblock.md' - - 'Botania': - - 'Flowers': 'integrations/botania/flowers.md' - - 'Mana Pool': 'integrations/botania/pool.md' - - 'Mana Spreader': 'integrations/botania/spreader.md' - - 'Create': - - 'Basin': 'integrations/create/basin.md' - - 'Blaze Burner': 'integrations/create/blazeburner.md' - - 'Fluid Tank': 'integrations/create/fluidtank.md' - - 'Mechanical Mixer': 'integrations/create/mechanicalmixer.md' - - 'Blocks with Scroll Behaviour': 'integrations/create/scrollbehaviour.md' - - 'Draconic Evolution': - - 'integrations/draconic_evolution/index.md' - - 'Immersive Engineering': - - 'Redstone Wire Connector': 'integrations/immersive_engineering/connector.md' - - 'Redstone Probe': 'integrations/immersive_engineering/probe.md' - - 'Integrated Dynamics': - - 'Variable Store': 'integrations/integrated_dynamics/variable_store.md' - - 'Mekanism': - - 'integrations/mekanism/index.md' - - 'Powah': - - 'Energy cell': 'integrations/powah/energy_cell.md' - - 'Furnator': 'integrations/powah/furnator.md' - - 'Magmator': 'integrations/powah/magmator.md' - - 'Reactor': 'integrations/powah/reactor.md' - - 'Solar panel': 'integrations/powah/solar_panel.md' - - 'Thermo generator': 'integrations/powah/thermo_generator.md' - - 'Storage Drawers': - - 'Drawer': 'integrations/storage_drawers/drawer.md' - - 'Changelogs': - - 'Changelog 0.7.24r': 'changelogs/0.7.24r.md' - - 'Changelog 0.7r': 'changelogs/0.7r.md' + - 'Home': 'index.md' + - 'Blog': + - blog/index.md + - 'Guides': + - 'Disabled Peripherals': 'guides/disabled_peripherals.md' + - 'Lua Objects': 'guides/lua_objects.md' + - 'Item and Fluid Filters': 'guides/filters.md' + - 'Cooldowns and Fuel consumption': 'guides/cooldowns_and_fuel_consumption.md' + - 'How to: report a bug or request a feature': 'guides/how_to_report.md' + - 'Peripherals': + - 'Base Peripheral': 'peripherals/base_peripheral.md' + - 'Chat Box': 'peripherals/chat_box.md' + - 'Distance Detector': 'peripherals/distance_detector.md' + - 'Environment Detector': 'peripherals/environment_detector.md' + - 'Geo Scanner': 'peripherals/geo_scanner.md' + - 'Player Detector': 'peripherals/player_detector.md' + - 'Energy/Fluid/Gas Detector': 'peripherals/base_detector.md' + - 'Block Reader': 'peripherals/block_reader.md' + - 'NBT Storage': 'peripherals/nbt_storage.md' + - 'Inventory Manager': 'peripherals/inventory_manager.md' + - 'Redstone Integrator': 'peripherals/redstone_integrator.md' + - 'Colony Integrator': 'peripherals/colony_integrator.md' + - 'ME/RS Bridge': 'peripherals/base_storage_bridge.md' + - 'Turtles': + - 'Chatty Turtle': 'turtles/chatty_turtle.md' + - 'Chunky Turtle': 'turtles/chunky_turtle.md' + - 'Compass Turtle': 'turtles/compass_turtle.md' + - 'Environment Turtle': 'turtles/environment_turtle.md' + - 'Geoscanning Turtle': 'turtles/geo_scanner_turtle.md' + - 'Player Turtle': 'turtles/player_turtle.md' + - 'Saddle Turtle': 'turtles/saddle_turtle.md' + - 'Metaphysics': + - 'Weak Automata': 'turtles/metaphysics/weak_automata.md' + - 'Husbandry Automata': 'turtles/metaphysics/husbandry_automata.md' + - 'End Automata': 'turtles/metaphysics/end_automata.md' + - 'Overpowered Automata': 'turtles/metaphysics/overpowered_automata.md' + - 'Modules': + - 'modules/index.md' + - 'Hotkey Module': 'modules/hotkey.md' + - 'Keyboard': 'modules/keyboard.md' + - 'Night Vision Module': 'modules/night_vision.md' + - 'Overlay Module': 'modules/overlay.md' + - 'Items': + - 'Chunk Controller': 'items/chunk_controller.md' + - 'Computer Tool': 'items/computer_tool.md' + - 'Memory Card': 'items/memory_card.md' + - 'Pocket Computers': 'items/pocket_computer.md' + - 'Smart Glasses': 'items/smart_glasses.md' + - 'Smart Glasses Interface': 'items/smart_glasses_interface.md' + - 'Mod Integrations': + - 'integrations/index.md' + - 'Minecraft': + - 'Beacon': 'integrations/minecraft/beacon.md' + - 'Note Block': 'integrations/minecraft/noteblock.md' + - 'Applied Energistics': + - 'Cable P2P Tunnel': 'integrations/ae2/cable_p2p_tunnel.md' + - 'Botania': + - 'Flowers': 'integrations/botania/flowers.md' + - 'Mana Pool': 'integrations/botania/pool.md' + - 'Mana Spreader': 'integrations/botania/spreader.md' + - 'Create': + - 'Basin': 'integrations/create/basin.md' + - 'Blaze Burner': 'integrations/create/blazeburner.md' + - 'Fluid Tank': 'integrations/create/fluidtank.md' + - 'Mechanical Mixer': 'integrations/create/mechanicalmixer.md' + - 'Blocks with Scroll Behaviour': 'integrations/create/scrollbehaviour.md' + - 'Powah': + - 'Ender cell': 'integrations/powah/ender_cell.md' + - 'Energy cell': 'integrations/powah/energy_cell.md' + - 'Furnator': 'integrations/powah/furnator.md' + - 'Magmator': 'integrations/powah/magmator.md' + - 'Reactor': 'integrations/powah/reactor.md' + - 'Solar panel': 'integrations/powah/solar_panel.md' + - 'Thermo generator': 'integrations/powah/thermo_generator.md' + # - 'Changelogs': + # - 'Changelog 0.7.24r': 'changelogs/0.7.24r.md' + # - 'Changelog 0.7r': 'changelogs/0.7r.md' watch: - overrides theme: - name: material - custom_dir: overrides - features: - - navigation.top - # - navigation.instant # Breaks 'lightgallery' extension - - navigation.indexes - - navigation.tabs - - navigation.footer - # - navigation.sections # Makes navigation too long - - content.code.annotate - - content.code.copy - - content.action.edit - - content.action.view - icon: - edit: material/file-edit-outline - view: material/file-eye-outline - palette: - - scheme: slate - primary: blue - toggle: - icon: material/weather-sunny - name: Switch to dark mode - - scheme: default - primary: blue - toggle: - icon: material/weather-night - name: Switch to light mode + name: material + custom_dir: overrides + features: + - navigation.top + # - navigation.instant # Breaks 'lightgallery' extension + - navigation.indexes + - navigation.tabs + - navigation.footer + # - navigation.sections # Makes navigation too long + - content.code.annotate + - content.code.copy + - content.action.edit + - content.action.view + icon: + edit: material/file-edit-outline + view: material/file-eye-outline + palette: + - scheme: slate + primary: blue + toggle: + icon: material/weather-sunny + name: Switch to dark mode + - scheme: default + primary: blue + toggle: + icon: material/weather-night + name: Switch to light mode plugins: - search: @@ -125,7 +127,7 @@ plugins: enabled: !ENV [CI, false] - git-committers: repository: IntelligenceModding/Advanced-Peripherals-Documentation - branch: "0.8" + branch: "0.7" token: !ENV GITHUB_TOKEN enabled: !ENV [CI, false] @@ -152,18 +154,23 @@ repo_name: IntelligenceModding/Advanced-Peripherals-Documentation edit_uri: edit/0.8/docs/ markdown_extensions: - - mdx_math - - def_list - - attr_list - - md_in_html - - pymdownx.tasklist: - custom_checkbox: true - - codehilite: - guess_lang: false - - toc: - permalink: true - - admonition - - pymdownx.superfences - - pymdownx.emoji: - emoji_index: !!python/name:material.extensions.emoji.twemoji - emoji_generator: !!python/name:material.extensions.emoji.to_svg + - tables + - md_in_html + - mdx_math + - def_list + - attr_list + - md_in_html + - pymdownx.tasklist: + custom_checkbox: true + - codehilite: + guess_lang: false + - toc: + permalink: true + - admonition + - pymdownx.superfences + - pymdownx.tabbed: + alternate_style: true + - pymdownx.emoji: + emoji_index: !!python/name:material.extensions.emoji.twemoji + emoji_generator: !!python/name:material.extensions.emoji.to_svg + - footnotes diff --git a/netlify.toml b/netlify.toml index 1397a760..bc9ec528 100644 --- a/netlify.toml +++ b/netlify.toml @@ -3,7 +3,7 @@ mkdocs build git config user.name "Version Deployment" git config user.email "netlifybot@example.com" - git remote set-url origin https://${GITHUB_TOKEN}@github.com/SirEndii/Advanced-Peripherals-Documentation.git + git remote set-url origin https://${GITHUB_TOKEN}@github.com/IntelligenceModding/Advanced-Peripherals-Documentation.git git config pull.rebase true git switch gh-pages git pull origin gh-pages @@ -24,4 +24,4 @@ [context.deploy-preview] command = "mkdocs build" #build the preview, but don't deploy with mike. - publish = "site" \ No newline at end of file + publish = "site" diff --git a/poetry.lock b/poetry.lock index 87335217..b118f156 100644 --- a/poetry.lock +++ b/poetry.lock @@ -1,4 +1,4 @@ -# This file is automatically @generated by Poetry 2.1.1 and should not be changed by hand. +# This file is automatically @generated by Poetry 2.1.3 and should not be changed by hand. [[package]] name = "babel" @@ -36,128 +36,128 @@ extras = ["regex"] [[package]] name = "certifi" -version = "2025.1.31" +version = "2025.4.26" description = "Python package for providing Mozilla's CA Bundle." optional = false python-versions = ">=3.6" groups = ["main"] files = [ - {file = "certifi-2025.1.31-py3-none-any.whl", hash = "sha256:ca78db4565a652026a4db2bcdf68f2fb589ea80d0be70e03929ed730746b84fe"}, - {file = "certifi-2025.1.31.tar.gz", hash = "sha256:3d5da6925056f6f18f119200434a4780a94263f10d1c21d032a6f6b2baa20651"}, + {file = "certifi-2025.4.26-py3-none-any.whl", hash = "sha256:30350364dfe371162649852c63336a15c70c6510c2ad5015b21c2345311805f3"}, + {file = "certifi-2025.4.26.tar.gz", hash = "sha256:0a816057ea3cdefcef70270d2c515e4506bbc954f417fa5ade2021213bb8f0c6"}, ] [[package]] name = "charset-normalizer" -version = "3.4.1" +version = "3.4.2" description = "The Real First Universal Charset Detector. Open, modern and actively maintained alternative to Chardet." optional = false python-versions = ">=3.7" groups = ["main"] files = [ - {file = "charset_normalizer-3.4.1-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:91b36a978b5ae0ee86c394f5a54d6ef44db1de0815eb43de826d41d21e4af3de"}, - {file = "charset_normalizer-3.4.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:7461baadb4dc00fd9e0acbe254e3d7d2112e7f92ced2adc96e54ef6501c5f176"}, - {file = "charset_normalizer-3.4.1-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:e218488cd232553829be0664c2292d3af2eeeb94b32bea483cf79ac6a694e037"}, - {file = "charset_normalizer-3.4.1-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:80ed5e856eb7f30115aaf94e4a08114ccc8813e6ed1b5efa74f9f82e8509858f"}, - {file = "charset_normalizer-3.4.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b010a7a4fd316c3c484d482922d13044979e78d1861f0e0650423144c616a46a"}, - {file = "charset_normalizer-3.4.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:4532bff1b8421fd0a320463030c7520f56a79c9024a4e88f01c537316019005a"}, - {file = "charset_normalizer-3.4.1-cp310-cp310-musllinux_1_2_aarch64.whl", hash = "sha256:d973f03c0cb71c5ed99037b870f2be986c3c05e63622c017ea9816881d2dd247"}, - {file = "charset_normalizer-3.4.1-cp310-cp310-musllinux_1_2_i686.whl", hash = "sha256:3a3bd0dcd373514dcec91c411ddb9632c0d7d92aed7093b8c3bbb6d69ca74408"}, - {file = "charset_normalizer-3.4.1-cp310-cp310-musllinux_1_2_ppc64le.whl", hash = "sha256:d9c3cdf5390dcd29aa8056d13e8e99526cda0305acc038b96b30352aff5ff2bb"}, - {file = "charset_normalizer-3.4.1-cp310-cp310-musllinux_1_2_s390x.whl", hash = "sha256:2bdfe3ac2e1bbe5b59a1a63721eb3b95fc9b6817ae4a46debbb4e11f6232428d"}, - {file = "charset_normalizer-3.4.1-cp310-cp310-musllinux_1_2_x86_64.whl", hash = "sha256:eab677309cdb30d047996b36d34caeda1dc91149e4fdca0b1a039b3f79d9a807"}, - {file = "charset_normalizer-3.4.1-cp310-cp310-win32.whl", hash = "sha256:c0429126cf75e16c4f0ad00ee0eae4242dc652290f940152ca8c75c3a4b6ee8f"}, - {file = "charset_normalizer-3.4.1-cp310-cp310-win_amd64.whl", hash = "sha256:9f0b8b1c6d84c8034a44893aba5e767bf9c7a211e313a9605d9c617d7083829f"}, - {file = "charset_normalizer-3.4.1-cp311-cp311-macosx_10_9_universal2.whl", hash = "sha256:8bfa33f4f2672964266e940dd22a195989ba31669bd84629f05fab3ef4e2d125"}, - {file = "charset_normalizer-3.4.1-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:28bf57629c75e810b6ae989f03c0828d64d6b26a5e205535585f96093e405ed1"}, - {file = "charset_normalizer-3.4.1-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:f08ff5e948271dc7e18a35641d2f11a4cd8dfd5634f55228b691e62b37125eb3"}, - {file = "charset_normalizer-3.4.1-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:234ac59ea147c59ee4da87a0c0f098e9c8d169f4dc2a159ef720f1a61bbe27cd"}, - {file = "charset_normalizer-3.4.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:fd4ec41f914fa74ad1b8304bbc634b3de73d2a0889bd32076342a573e0779e00"}, - {file = "charset_normalizer-3.4.1-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:eea6ee1db730b3483adf394ea72f808b6e18cf3cb6454b4d86e04fa8c4327a12"}, - {file = "charset_normalizer-3.4.1-cp311-cp311-musllinux_1_2_aarch64.whl", hash = "sha256:c96836c97b1238e9c9e3fe90844c947d5afbf4f4c92762679acfe19927d81d77"}, - {file = "charset_normalizer-3.4.1-cp311-cp311-musllinux_1_2_i686.whl", hash = "sha256:4d86f7aff21ee58f26dcf5ae81a9addbd914115cdebcbb2217e4f0ed8982e146"}, - {file = "charset_normalizer-3.4.1-cp311-cp311-musllinux_1_2_ppc64le.whl", hash = "sha256:09b5e6733cbd160dcc09589227187e242a30a49ca5cefa5a7edd3f9d19ed53fd"}, - {file = "charset_normalizer-3.4.1-cp311-cp311-musllinux_1_2_s390x.whl", hash = "sha256:5777ee0881f9499ed0f71cc82cf873d9a0ca8af166dfa0af8ec4e675b7df48e6"}, - {file = "charset_normalizer-3.4.1-cp311-cp311-musllinux_1_2_x86_64.whl", hash = "sha256:237bdbe6159cff53b4f24f397d43c6336c6b0b42affbe857970cefbb620911c8"}, - {file = "charset_normalizer-3.4.1-cp311-cp311-win32.whl", hash = "sha256:8417cb1f36cc0bc7eaba8ccb0e04d55f0ee52df06df3ad55259b9a323555fc8b"}, - {file = "charset_normalizer-3.4.1-cp311-cp311-win_amd64.whl", hash = "sha256:d7f50a1f8c450f3925cb367d011448c39239bb3eb4117c36a6d354794de4ce76"}, - {file = "charset_normalizer-3.4.1-cp312-cp312-macosx_10_13_universal2.whl", hash = "sha256:73d94b58ec7fecbc7366247d3b0b10a21681004153238750bb67bd9012414545"}, - {file = "charset_normalizer-3.4.1-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:dad3e487649f498dd991eeb901125411559b22e8d7ab25d3aeb1af367df5efd7"}, - {file = "charset_normalizer-3.4.1-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:c30197aa96e8eed02200a83fba2657b4c3acd0f0aa4bdc9f6c1af8e8962e0757"}, - {file = "charset_normalizer-3.4.1-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:2369eea1ee4a7610a860d88f268eb39b95cb588acd7235e02fd5a5601773d4fa"}, - {file = "charset_normalizer-3.4.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:bc2722592d8998c870fa4e290c2eec2c1569b87fe58618e67d38b4665dfa680d"}, - {file = "charset_normalizer-3.4.1-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:ffc9202a29ab3920fa812879e95a9e78b2465fd10be7fcbd042899695d75e616"}, - {file = "charset_normalizer-3.4.1-cp312-cp312-musllinux_1_2_aarch64.whl", hash = "sha256:804a4d582ba6e5b747c625bf1255e6b1507465494a40a2130978bda7b932c90b"}, - {file = "charset_normalizer-3.4.1-cp312-cp312-musllinux_1_2_i686.whl", hash = "sha256:0f55e69f030f7163dffe9fd0752b32f070566451afe180f99dbeeb81f511ad8d"}, - {file = "charset_normalizer-3.4.1-cp312-cp312-musllinux_1_2_ppc64le.whl", hash = "sha256:c4c3e6da02df6fa1410a7680bd3f63d4f710232d3139089536310d027950696a"}, - {file = "charset_normalizer-3.4.1-cp312-cp312-musllinux_1_2_s390x.whl", hash = "sha256:5df196eb874dae23dcfb968c83d4f8fdccb333330fe1fc278ac5ceeb101003a9"}, - {file = "charset_normalizer-3.4.1-cp312-cp312-musllinux_1_2_x86_64.whl", hash = "sha256:e358e64305fe12299a08e08978f51fc21fac060dcfcddd95453eabe5b93ed0e1"}, - {file = "charset_normalizer-3.4.1-cp312-cp312-win32.whl", hash = "sha256:9b23ca7ef998bc739bf6ffc077c2116917eabcc901f88da1b9856b210ef63f35"}, - {file = "charset_normalizer-3.4.1-cp312-cp312-win_amd64.whl", hash = "sha256:6ff8a4a60c227ad87030d76e99cd1698345d4491638dfa6673027c48b3cd395f"}, - {file = "charset_normalizer-3.4.1-cp313-cp313-macosx_10_13_universal2.whl", hash = "sha256:aabfa34badd18f1da5ec1bc2715cadc8dca465868a4e73a0173466b688f29dda"}, - {file = "charset_normalizer-3.4.1-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:22e14b5d70560b8dd51ec22863f370d1e595ac3d024cb8ad7d308b4cd95f8313"}, - {file = "charset_normalizer-3.4.1-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:8436c508b408b82d87dc5f62496973a1805cd46727c34440b0d29d8a2f50a6c9"}, - {file = "charset_normalizer-3.4.1-cp313-cp313-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:2d074908e1aecee37a7635990b2c6d504cd4766c7bc9fc86d63f9c09af3fa11b"}, - {file = "charset_normalizer-3.4.1-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:955f8851919303c92343d2f66165294848d57e9bba6cf6e3625485a70a038d11"}, - {file = "charset_normalizer-3.4.1-cp313-cp313-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:44ecbf16649486d4aebafeaa7ec4c9fed8b88101f4dd612dcaf65d5e815f837f"}, - {file = "charset_normalizer-3.4.1-cp313-cp313-musllinux_1_2_aarch64.whl", hash = "sha256:0924e81d3d5e70f8126529951dac65c1010cdf117bb75eb02dd12339b57749dd"}, - {file = "charset_normalizer-3.4.1-cp313-cp313-musllinux_1_2_i686.whl", hash = "sha256:2967f74ad52c3b98de4c3b32e1a44e32975e008a9cd2a8cc8966d6a5218c5cb2"}, - {file = "charset_normalizer-3.4.1-cp313-cp313-musllinux_1_2_ppc64le.whl", hash = "sha256:c75cb2a3e389853835e84a2d8fb2b81a10645b503eca9bcb98df6b5a43eb8886"}, - {file = "charset_normalizer-3.4.1-cp313-cp313-musllinux_1_2_s390x.whl", hash = "sha256:09b26ae6b1abf0d27570633b2b078a2a20419c99d66fb2823173d73f188ce601"}, - {file = "charset_normalizer-3.4.1-cp313-cp313-musllinux_1_2_x86_64.whl", hash = "sha256:fa88b843d6e211393a37219e6a1c1df99d35e8fd90446f1118f4216e307e48cd"}, - {file = "charset_normalizer-3.4.1-cp313-cp313-win32.whl", hash = "sha256:eb8178fe3dba6450a3e024e95ac49ed3400e506fd4e9e5c32d30adda88cbd407"}, - {file = "charset_normalizer-3.4.1-cp313-cp313-win_amd64.whl", hash = "sha256:b1ac5992a838106edb89654e0aebfc24f5848ae2547d22c2c3f66454daa11971"}, - {file = "charset_normalizer-3.4.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:f30bf9fd9be89ecb2360c7d94a711f00c09b976258846efe40db3d05828e8089"}, - {file = "charset_normalizer-3.4.1-cp37-cp37m-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:97f68b8d6831127e4787ad15e6757232e14e12060bec17091b85eb1486b91d8d"}, - {file = "charset_normalizer-3.4.1-cp37-cp37m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:7974a0b5ecd505609e3b19742b60cee7aa2aa2fb3151bc917e6e2646d7667dcf"}, - {file = "charset_normalizer-3.4.1-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:fc54db6c8593ef7d4b2a331b58653356cf04f67c960f584edb7c3d8c97e8f39e"}, - {file = "charset_normalizer-3.4.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:311f30128d7d333eebd7896965bfcfbd0065f1716ec92bd5638d7748eb6f936a"}, - {file = "charset_normalizer-3.4.1-cp37-cp37m-musllinux_1_2_aarch64.whl", hash = "sha256:7d053096f67cd1241601111b698f5cad775f97ab25d81567d3f59219b5f1adbd"}, - {file = "charset_normalizer-3.4.1-cp37-cp37m-musllinux_1_2_i686.whl", hash = "sha256:807f52c1f798eef6cf26beb819eeb8819b1622ddfeef9d0977a8502d4db6d534"}, - {file = "charset_normalizer-3.4.1-cp37-cp37m-musllinux_1_2_ppc64le.whl", hash = "sha256:dccbe65bd2f7f7ec22c4ff99ed56faa1e9f785482b9bbd7c717e26fd723a1d1e"}, - {file = "charset_normalizer-3.4.1-cp37-cp37m-musllinux_1_2_s390x.whl", hash = "sha256:2fb9bd477fdea8684f78791a6de97a953c51831ee2981f8e4f583ff3b9d9687e"}, - {file = "charset_normalizer-3.4.1-cp37-cp37m-musllinux_1_2_x86_64.whl", hash = "sha256:01732659ba9b5b873fc117534143e4feefecf3b2078b0a6a2e925271bb6f4cfa"}, - {file = "charset_normalizer-3.4.1-cp37-cp37m-win32.whl", hash = "sha256:7a4f97a081603d2050bfaffdefa5b02a9ec823f8348a572e39032caa8404a487"}, - {file = "charset_normalizer-3.4.1-cp37-cp37m-win_amd64.whl", hash = "sha256:7b1bef6280950ee6c177b326508f86cad7ad4dff12454483b51d8b7d673a2c5d"}, - {file = "charset_normalizer-3.4.1-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:ecddf25bee22fe4fe3737a399d0d177d72bc22be6913acfab364b40bce1ba83c"}, - {file = "charset_normalizer-3.4.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8c60ca7339acd497a55b0ea5d506b2a2612afb2826560416f6894e8b5770d4a9"}, - {file = "charset_normalizer-3.4.1-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:b7b2d86dd06bfc2ade3312a83a5c364c7ec2e3498f8734282c6c3d4b07b346b8"}, - {file = "charset_normalizer-3.4.1-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:dd78cfcda14a1ef52584dbb008f7ac81c1328c0f58184bf9a84c49c605002da6"}, - {file = "charset_normalizer-3.4.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6e27f48bcd0957c6d4cb9d6fa6b61d192d0b13d5ef563e5f2ae35feafc0d179c"}, - {file = "charset_normalizer-3.4.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:01ad647cdd609225c5350561d084b42ddf732f4eeefe6e678765636791e78b9a"}, - {file = "charset_normalizer-3.4.1-cp38-cp38-musllinux_1_2_aarch64.whl", hash = "sha256:619a609aa74ae43d90ed2e89bdd784765de0a25ca761b93e196d938b8fd1dbbd"}, - {file = "charset_normalizer-3.4.1-cp38-cp38-musllinux_1_2_i686.whl", hash = "sha256:89149166622f4db9b4b6a449256291dc87a99ee53151c74cbd82a53c8c2f6ccd"}, - {file = "charset_normalizer-3.4.1-cp38-cp38-musllinux_1_2_ppc64le.whl", hash = "sha256:7709f51f5f7c853f0fb938bcd3bc59cdfdc5203635ffd18bf354f6967ea0f824"}, - {file = "charset_normalizer-3.4.1-cp38-cp38-musllinux_1_2_s390x.whl", hash = "sha256:345b0426edd4e18138d6528aed636de7a9ed169b4aaf9d61a8c19e39d26838ca"}, - {file = "charset_normalizer-3.4.1-cp38-cp38-musllinux_1_2_x86_64.whl", hash = "sha256:0907f11d019260cdc3f94fbdb23ff9125f6b5d1039b76003b5b0ac9d6a6c9d5b"}, - {file = "charset_normalizer-3.4.1-cp38-cp38-win32.whl", hash = "sha256:ea0d8d539afa5eb2728aa1932a988a9a7af94f18582ffae4bc10b3fbdad0626e"}, - {file = "charset_normalizer-3.4.1-cp38-cp38-win_amd64.whl", hash = "sha256:329ce159e82018d646c7ac45b01a430369d526569ec08516081727a20e9e4af4"}, - {file = "charset_normalizer-3.4.1-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:b97e690a2118911e39b4042088092771b4ae3fc3aa86518f84b8cf6888dbdb41"}, - {file = "charset_normalizer-3.4.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:78baa6d91634dfb69ec52a463534bc0df05dbd546209b79a3880a34487f4b84f"}, - {file = "charset_normalizer-3.4.1-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:1a2bc9f351a75ef49d664206d51f8e5ede9da246602dc2d2726837620ea034b2"}, - {file = "charset_normalizer-3.4.1-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:75832c08354f595c760a804588b9357d34ec00ba1c940c15e31e96d902093770"}, - {file = "charset_normalizer-3.4.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:0af291f4fe114be0280cdd29d533696a77b5b49cfde5467176ecab32353395c4"}, - {file = "charset_normalizer-3.4.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:0167ddc8ab6508fe81860a57dd472b2ef4060e8d378f0cc555707126830f2537"}, - {file = "charset_normalizer-3.4.1-cp39-cp39-musllinux_1_2_aarch64.whl", hash = "sha256:2a75d49014d118e4198bcee5ee0a6f25856b29b12dbf7cd012791f8a6cc5c496"}, - {file = "charset_normalizer-3.4.1-cp39-cp39-musllinux_1_2_i686.whl", hash = "sha256:363e2f92b0f0174b2f8238240a1a30142e3db7b957a5dd5689b0e75fb717cc78"}, - {file = "charset_normalizer-3.4.1-cp39-cp39-musllinux_1_2_ppc64le.whl", hash = "sha256:ab36c8eb7e454e34e60eb55ca5d241a5d18b2c6244f6827a30e451c42410b5f7"}, - {file = "charset_normalizer-3.4.1-cp39-cp39-musllinux_1_2_s390x.whl", hash = "sha256:4c0907b1928a36d5a998d72d64d8eaa7244989f7aaaf947500d3a800c83a3fd6"}, - {file = "charset_normalizer-3.4.1-cp39-cp39-musllinux_1_2_x86_64.whl", hash = "sha256:04432ad9479fa40ec0f387795ddad4437a2b50417c69fa275e212933519ff294"}, - {file = "charset_normalizer-3.4.1-cp39-cp39-win32.whl", hash = "sha256:3bed14e9c89dcb10e8f3a29f9ccac4955aebe93c71ae803af79265c9ca5644c5"}, - {file = "charset_normalizer-3.4.1-cp39-cp39-win_amd64.whl", hash = "sha256:49402233c892a461407c512a19435d1ce275543138294f7ef013f0b63d5d3765"}, - {file = "charset_normalizer-3.4.1-py3-none-any.whl", hash = "sha256:d98b1668f06378c6dbefec3b92299716b931cd4e6061f3c875a71ced1780ab85"}, - {file = "charset_normalizer-3.4.1.tar.gz", hash = "sha256:44251f18cd68a75b56585dd00dae26183e102cd5e0f9f1466e6df5da2ed64ea3"}, + {file = "charset_normalizer-3.4.2-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:7c48ed483eb946e6c04ccbe02c6b4d1d48e51944b6db70f697e089c193404941"}, + {file = "charset_normalizer-3.4.2-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:b2d318c11350e10662026ad0eb71bb51c7812fc8590825304ae0bdd4ac283acd"}, + {file = "charset_normalizer-3.4.2-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:9cbfacf36cb0ec2897ce0ebc5d08ca44213af24265bd56eca54bee7923c48fd6"}, + {file = "charset_normalizer-3.4.2-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:18dd2e350387c87dabe711b86f83c9c78af772c748904d372ade190b5c7c9d4d"}, + {file = "charset_normalizer-3.4.2-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:8075c35cd58273fee266c58c0c9b670947c19df5fb98e7b66710e04ad4e9ff86"}, + {file = "charset_normalizer-3.4.2-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:5bf4545e3b962767e5c06fe1738f951f77d27967cb2caa64c28be7c4563e162c"}, + {file = "charset_normalizer-3.4.2-cp310-cp310-musllinux_1_2_aarch64.whl", hash = "sha256:7a6ab32f7210554a96cd9e33abe3ddd86732beeafc7a28e9955cdf22ffadbab0"}, + {file = "charset_normalizer-3.4.2-cp310-cp310-musllinux_1_2_i686.whl", hash = "sha256:b33de11b92e9f75a2b545d6e9b6f37e398d86c3e9e9653c4864eb7e89c5773ef"}, + {file = "charset_normalizer-3.4.2-cp310-cp310-musllinux_1_2_ppc64le.whl", hash = "sha256:8755483f3c00d6c9a77f490c17e6ab0c8729e39e6390328e42521ef175380ae6"}, + {file = "charset_normalizer-3.4.2-cp310-cp310-musllinux_1_2_s390x.whl", hash = "sha256:68a328e5f55ec37c57f19ebb1fdc56a248db2e3e9ad769919a58672958e8f366"}, + {file = "charset_normalizer-3.4.2-cp310-cp310-musllinux_1_2_x86_64.whl", hash = "sha256:21b2899062867b0e1fde9b724f8aecb1af14f2778d69aacd1a5a1853a597a5db"}, + {file = "charset_normalizer-3.4.2-cp310-cp310-win32.whl", hash = "sha256:e8082b26888e2f8b36a042a58307d5b917ef2b1cacab921ad3323ef91901c71a"}, + {file = "charset_normalizer-3.4.2-cp310-cp310-win_amd64.whl", hash = "sha256:f69a27e45c43520f5487f27627059b64aaf160415589230992cec34c5e18a509"}, + {file = "charset_normalizer-3.4.2-cp311-cp311-macosx_10_9_universal2.whl", hash = "sha256:be1e352acbe3c78727a16a455126d9ff83ea2dfdcbc83148d2982305a04714c2"}, + {file = "charset_normalizer-3.4.2-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:aa88ca0b1932e93f2d961bf3addbb2db902198dca337d88c89e1559e066e7645"}, + {file = "charset_normalizer-3.4.2-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:d524ba3f1581b35c03cb42beebab4a13e6cdad7b36246bd22541fa585a56cccd"}, + {file = "charset_normalizer-3.4.2-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:28a1005facc94196e1fb3e82a3d442a9d9110b8434fc1ded7a24a2983c9888d8"}, + {file = "charset_normalizer-3.4.2-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:fdb20a30fe1175ecabed17cbf7812f7b804b8a315a25f24678bcdf120a90077f"}, + {file = "charset_normalizer-3.4.2-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:0f5d9ed7f254402c9e7d35d2f5972c9bbea9040e99cd2861bd77dc68263277c7"}, + {file = "charset_normalizer-3.4.2-cp311-cp311-musllinux_1_2_aarch64.whl", hash = "sha256:efd387a49825780ff861998cd959767800d54f8308936b21025326de4b5a42b9"}, + {file = "charset_normalizer-3.4.2-cp311-cp311-musllinux_1_2_i686.whl", hash = "sha256:f0aa37f3c979cf2546b73e8222bbfa3dc07a641585340179d768068e3455e544"}, + {file = "charset_normalizer-3.4.2-cp311-cp311-musllinux_1_2_ppc64le.whl", hash = "sha256:e70e990b2137b29dc5564715de1e12701815dacc1d056308e2b17e9095372a82"}, + {file = "charset_normalizer-3.4.2-cp311-cp311-musllinux_1_2_s390x.whl", hash = "sha256:0c8c57f84ccfc871a48a47321cfa49ae1df56cd1d965a09abe84066f6853b9c0"}, + {file = "charset_normalizer-3.4.2-cp311-cp311-musllinux_1_2_x86_64.whl", hash = "sha256:6b66f92b17849b85cad91259efc341dce9c1af48e2173bf38a85c6329f1033e5"}, + {file = "charset_normalizer-3.4.2-cp311-cp311-win32.whl", hash = "sha256:daac4765328a919a805fa5e2720f3e94767abd632ae410a9062dff5412bae65a"}, + {file = "charset_normalizer-3.4.2-cp311-cp311-win_amd64.whl", hash = "sha256:e53efc7c7cee4c1e70661e2e112ca46a575f90ed9ae3fef200f2a25e954f4b28"}, + {file = "charset_normalizer-3.4.2-cp312-cp312-macosx_10_13_universal2.whl", hash = "sha256:0c29de6a1a95f24b9a1aa7aefd27d2487263f00dfd55a77719b530788f75cff7"}, + {file = "charset_normalizer-3.4.2-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:cddf7bd982eaa998934a91f69d182aec997c6c468898efe6679af88283b498d3"}, + {file = "charset_normalizer-3.4.2-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:fcbe676a55d7445b22c10967bceaaf0ee69407fbe0ece4d032b6eb8d4565982a"}, + {file = "charset_normalizer-3.4.2-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:d41c4d287cfc69060fa91cae9683eacffad989f1a10811995fa309df656ec214"}, + {file = "charset_normalizer-3.4.2-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:4e594135de17ab3866138f496755f302b72157d115086d100c3f19370839dd3a"}, + {file = "charset_normalizer-3.4.2-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:cf713fe9a71ef6fd5adf7a79670135081cd4431c2943864757f0fa3a65b1fafd"}, + {file = "charset_normalizer-3.4.2-cp312-cp312-musllinux_1_2_aarch64.whl", hash = "sha256:a370b3e078e418187da8c3674eddb9d983ec09445c99a3a263c2011993522981"}, + {file = "charset_normalizer-3.4.2-cp312-cp312-musllinux_1_2_i686.whl", hash = "sha256:a955b438e62efdf7e0b7b52a64dc5c3396e2634baa62471768a64bc2adb73d5c"}, + {file = "charset_normalizer-3.4.2-cp312-cp312-musllinux_1_2_ppc64le.whl", hash = "sha256:7222ffd5e4de8e57e03ce2cef95a4c43c98fcb72ad86909abdfc2c17d227fc1b"}, + {file = "charset_normalizer-3.4.2-cp312-cp312-musllinux_1_2_s390x.whl", hash = "sha256:bee093bf902e1d8fc0ac143c88902c3dfc8941f7ea1d6a8dd2bcb786d33db03d"}, + {file = "charset_normalizer-3.4.2-cp312-cp312-musllinux_1_2_x86_64.whl", hash = "sha256:dedb8adb91d11846ee08bec4c8236c8549ac721c245678282dcb06b221aab59f"}, + {file = "charset_normalizer-3.4.2-cp312-cp312-win32.whl", hash = "sha256:db4c7bf0e07fc3b7d89ac2a5880a6a8062056801b83ff56d8464b70f65482b6c"}, + {file = "charset_normalizer-3.4.2-cp312-cp312-win_amd64.whl", hash = "sha256:5a9979887252a82fefd3d3ed2a8e3b937a7a809f65dcb1e068b090e165bbe99e"}, + {file = "charset_normalizer-3.4.2-cp313-cp313-macosx_10_13_universal2.whl", hash = "sha256:926ca93accd5d36ccdabd803392ddc3e03e6d4cd1cf17deff3b989ab8e9dbcf0"}, + {file = "charset_normalizer-3.4.2-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:eba9904b0f38a143592d9fc0e19e2df0fa2e41c3c3745554761c5f6447eedabf"}, + {file = "charset_normalizer-3.4.2-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:3fddb7e2c84ac87ac3a947cb4e66d143ca5863ef48e4a5ecb83bd48619e4634e"}, + {file = "charset_normalizer-3.4.2-cp313-cp313-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:98f862da73774290f251b9df8d11161b6cf25b599a66baf087c1ffe340e9bfd1"}, + {file = "charset_normalizer-3.4.2-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6c9379d65defcab82d07b2a9dfbfc2e95bc8fe0ebb1b176a3190230a3ef0e07c"}, + {file = "charset_normalizer-3.4.2-cp313-cp313-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:e635b87f01ebc977342e2697d05b56632f5f879a4f15955dfe8cef2448b51691"}, + {file = "charset_normalizer-3.4.2-cp313-cp313-musllinux_1_2_aarch64.whl", hash = "sha256:1c95a1e2902a8b722868587c0e1184ad5c55631de5afc0eb96bc4b0d738092c0"}, + {file = "charset_normalizer-3.4.2-cp313-cp313-musllinux_1_2_i686.whl", hash = "sha256:ef8de666d6179b009dce7bcb2ad4c4a779f113f12caf8dc77f0162c29d20490b"}, + {file = "charset_normalizer-3.4.2-cp313-cp313-musllinux_1_2_ppc64le.whl", hash = "sha256:32fc0341d72e0f73f80acb0a2c94216bd704f4f0bce10aedea38f30502b271ff"}, + {file = "charset_normalizer-3.4.2-cp313-cp313-musllinux_1_2_s390x.whl", hash = "sha256:289200a18fa698949d2b39c671c2cc7a24d44096784e76614899a7ccf2574b7b"}, + {file = "charset_normalizer-3.4.2-cp313-cp313-musllinux_1_2_x86_64.whl", hash = "sha256:4a476b06fbcf359ad25d34a057b7219281286ae2477cc5ff5e3f70a246971148"}, + {file = "charset_normalizer-3.4.2-cp313-cp313-win32.whl", hash = "sha256:aaeeb6a479c7667fbe1099af9617c83aaca22182d6cf8c53966491a0f1b7ffb7"}, + {file = "charset_normalizer-3.4.2-cp313-cp313-win_amd64.whl", hash = "sha256:aa6af9e7d59f9c12b33ae4e9450619cf2488e2bbe9b44030905877f0b2324980"}, + {file = "charset_normalizer-3.4.2-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:1cad5f45b3146325bb38d6855642f6fd609c3f7cad4dbaf75549bf3b904d3184"}, + {file = "charset_normalizer-3.4.2-cp37-cp37m-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:b2680962a4848b3c4f155dc2ee64505a9c57186d0d56b43123b17ca3de18f0fa"}, + {file = "charset_normalizer-3.4.2-cp37-cp37m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:36b31da18b8890a76ec181c3cf44326bf2c48e36d393ca1b72b3f484113ea344"}, + {file = "charset_normalizer-3.4.2-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f4074c5a429281bf056ddd4c5d3b740ebca4d43ffffe2ef4bf4d2d05114299da"}, + {file = "charset_normalizer-3.4.2-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:c9e36a97bee9b86ef9a1cf7bb96747eb7a15c2f22bdb5b516434b00f2a599f02"}, + {file = "charset_normalizer-3.4.2-cp37-cp37m-musllinux_1_2_aarch64.whl", hash = "sha256:1b1bde144d98e446b056ef98e59c256e9294f6b74d7af6846bf5ffdafd687a7d"}, + {file = "charset_normalizer-3.4.2-cp37-cp37m-musllinux_1_2_i686.whl", hash = "sha256:915f3849a011c1f593ab99092f3cecfcb4d65d8feb4a64cf1bf2d22074dc0ec4"}, + {file = "charset_normalizer-3.4.2-cp37-cp37m-musllinux_1_2_ppc64le.whl", hash = "sha256:fb707f3e15060adf5b7ada797624a6c6e0138e2a26baa089df64c68ee98e040f"}, + {file = "charset_normalizer-3.4.2-cp37-cp37m-musllinux_1_2_s390x.whl", hash = "sha256:25a23ea5c7edc53e0f29bae2c44fcb5a1aa10591aae107f2a2b2583a9c5cbc64"}, + {file = "charset_normalizer-3.4.2-cp37-cp37m-musllinux_1_2_x86_64.whl", hash = "sha256:770cab594ecf99ae64c236bc9ee3439c3f46be49796e265ce0cc8bc17b10294f"}, + {file = "charset_normalizer-3.4.2-cp37-cp37m-win32.whl", hash = "sha256:6a0289e4589e8bdfef02a80478f1dfcb14f0ab696b5a00e1f4b8a14a307a3c58"}, + {file = "charset_normalizer-3.4.2-cp37-cp37m-win_amd64.whl", hash = "sha256:6fc1f5b51fa4cecaa18f2bd7a003f3dd039dd615cd69a2afd6d3b19aed6775f2"}, + {file = "charset_normalizer-3.4.2-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:76af085e67e56c8816c3ccf256ebd136def2ed9654525348cfa744b6802b69eb"}, + {file = "charset_normalizer-3.4.2-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e45ba65510e2647721e35323d6ef54c7974959f6081b58d4ef5d87c60c84919a"}, + {file = "charset_normalizer-3.4.2-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:046595208aae0120559a67693ecc65dd75d46f7bf687f159127046628178dc45"}, + {file = "charset_normalizer-3.4.2-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:75d10d37a47afee94919c4fab4c22b9bc2a8bf7d4f46f87363bcf0573f3ff4f5"}, + {file = "charset_normalizer-3.4.2-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6333b3aa5a12c26b2a4d4e7335a28f1475e0e5e17d69d55141ee3cab736f66d1"}, + {file = "charset_normalizer-3.4.2-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:e8323a9b031aa0393768b87f04b4164a40037fb2a3c11ac06a03ffecd3618027"}, + {file = "charset_normalizer-3.4.2-cp38-cp38-musllinux_1_2_aarch64.whl", hash = "sha256:24498ba8ed6c2e0b56d4acbf83f2d989720a93b41d712ebd4f4979660db4417b"}, + {file = "charset_normalizer-3.4.2-cp38-cp38-musllinux_1_2_i686.whl", hash = "sha256:844da2b5728b5ce0e32d863af26f32b5ce61bc4273a9c720a9f3aa9df73b1455"}, + {file = "charset_normalizer-3.4.2-cp38-cp38-musllinux_1_2_ppc64le.whl", hash = "sha256:65c981bdbd3f57670af8b59777cbfae75364b483fa8a9f420f08094531d54a01"}, + {file = "charset_normalizer-3.4.2-cp38-cp38-musllinux_1_2_s390x.whl", hash = "sha256:3c21d4fca343c805a52c0c78edc01e3477f6dd1ad7c47653241cf2a206d4fc58"}, + {file = "charset_normalizer-3.4.2-cp38-cp38-musllinux_1_2_x86_64.whl", hash = "sha256:dc7039885fa1baf9be153a0626e337aa7ec8bf96b0128605fb0d77788ddc1681"}, + {file = "charset_normalizer-3.4.2-cp38-cp38-win32.whl", hash = "sha256:8272b73e1c5603666618805fe821edba66892e2870058c94c53147602eab29c7"}, + {file = "charset_normalizer-3.4.2-cp38-cp38-win_amd64.whl", hash = "sha256:70f7172939fdf8790425ba31915bfbe8335030f05b9913d7ae00a87d4395620a"}, + {file = "charset_normalizer-3.4.2-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:005fa3432484527f9732ebd315da8da8001593e2cf46a3d817669f062c3d9ed4"}, + {file = "charset_normalizer-3.4.2-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e92fca20c46e9f5e1bb485887d074918b13543b1c2a1185e69bb8d17ab6236a7"}, + {file = "charset_normalizer-3.4.2-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:50bf98d5e563b83cc29471fa114366e6806bc06bc7a25fd59641e41445327836"}, + {file = "charset_normalizer-3.4.2-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:721c76e84fe669be19c5791da68232ca2e05ba5185575086e384352e2c309597"}, + {file = "charset_normalizer-3.4.2-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:82d8fd25b7f4675d0c47cf95b594d4e7b158aca33b76aa63d07186e13c0e0ab7"}, + {file = "charset_normalizer-3.4.2-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:b3daeac64d5b371dea99714f08ffc2c208522ec6b06fbc7866a450dd446f5c0f"}, + {file = "charset_normalizer-3.4.2-cp39-cp39-musllinux_1_2_aarch64.whl", hash = "sha256:dccab8d5fa1ef9bfba0590ecf4d46df048d18ffe3eec01eeb73a42e0d9e7a8ba"}, + {file = "charset_normalizer-3.4.2-cp39-cp39-musllinux_1_2_i686.whl", hash = "sha256:aaf27faa992bfee0264dc1f03f4c75e9fcdda66a519db6b957a3f826e285cf12"}, + {file = "charset_normalizer-3.4.2-cp39-cp39-musllinux_1_2_ppc64le.whl", hash = "sha256:eb30abc20df9ab0814b5a2524f23d75dcf83cde762c161917a2b4b7b55b1e518"}, + {file = "charset_normalizer-3.4.2-cp39-cp39-musllinux_1_2_s390x.whl", hash = "sha256:c72fbbe68c6f32f251bdc08b8611c7b3060612236e960ef848e0a517ddbe76c5"}, + {file = "charset_normalizer-3.4.2-cp39-cp39-musllinux_1_2_x86_64.whl", hash = "sha256:982bb1e8b4ffda883b3d0a521e23abcd6fd17418f6d2c4118d257a10199c0ce3"}, + {file = "charset_normalizer-3.4.2-cp39-cp39-win32.whl", hash = "sha256:43e0933a0eff183ee85833f341ec567c0980dae57c464d8a508e1b2ceb336471"}, + {file = "charset_normalizer-3.4.2-cp39-cp39-win_amd64.whl", hash = "sha256:d11b54acf878eef558599658b0ffca78138c8c3655cf4f3a4a673c437e67732e"}, + {file = "charset_normalizer-3.4.2-py3-none-any.whl", hash = "sha256:7f56930ab0abd1c45cd15be65cc741c28b1c9a34876ce8c17a2fa107810c0af0"}, + {file = "charset_normalizer-3.4.2.tar.gz", hash = "sha256:5baececa9ecba31eff645232d59845c07aa030f0c81ee70184a90d35099a0e63"}, ] [[package]] name = "click" -version = "8.1.8" +version = "8.2.1" description = "Composable command line interface toolkit" optional = false -python-versions = ">=3.7" +python-versions = ">=3.10" groups = ["main"] files = [ - {file = "click-8.1.8-py3-none-any.whl", hash = "sha256:63c132bbbed01578a06712a2d1f497bb62d9c1c0d329b7903a866228027263b2"}, - {file = "click-8.1.8.tar.gz", hash = "sha256:ed53c9d8990d83c2a27deae68e4ee337473f6330c040a31d4225c9574d16096a"}, + {file = "click-8.2.1-py3-none-any.whl", hash = "sha256:61a3265b914e850b85317d0b3109c7f8cd35a670f963866005d6ef1d5175a12b"}, + {file = "click-8.2.1.tar.gz", hash = "sha256:27c491cc05d968d271d5a1db13e3b5a184636d9d930f148c50b038f0d0646202"}, ] [package.dependencies] @@ -244,14 +244,14 @@ all = ["flake8 (>=7.1.1)", "mypy (>=1.11.2)", "pytest (>=8.3.2)", "ruff (>=0.6.2 [[package]] name = "importlib-metadata" -version = "8.6.1" +version = "8.7.0" description = "Read metadata from Python packages" optional = false python-versions = ">=3.9" groups = ["main"] files = [ - {file = "importlib_metadata-8.6.1-py3-none-any.whl", hash = "sha256:02a89390c1e15fdfdc0d7c6b25cb3e62650d0494005c97d6f148bf5b9787525e"}, - {file = "importlib_metadata-8.6.1.tar.gz", hash = "sha256:310b41d755445d74569f993ccfc22838295d9fe005425094fad953d7f15c8580"}, + {file = "importlib_metadata-8.7.0-py3-none-any.whl", hash = "sha256:e5dd1551894c77868a30651cef00984d50e1002d06942a7101d34870c5f02afd"}, + {file = "importlib_metadata-8.7.0.tar.gz", hash = "sha256:d13b81ad223b890aa16c5471f2ac3056cf76c5f10f82d6f9292f0b415f389000"}, ] [package.dependencies] @@ -288,14 +288,14 @@ type = ["pytest-mypy"] [[package]] name = "jinja2" -version = "3.1.5" +version = "3.1.6" description = "A very fast and expressive template engine." optional = false python-versions = ">=3.7" groups = ["main"] files = [ - {file = "jinja2-3.1.5-py3-none-any.whl", hash = "sha256:aba0f4dc9ed8013c424088f68a5c226f7d6097ed89b246d7749c2ec4175c6adb"}, - {file = "jinja2-3.1.5.tar.gz", hash = "sha256:8fefff8dc3034e27bb80d67c671eb8a9bc424c0ef4c0826edbff304cceff43bb"}, + {file = "jinja2-3.1.6-py3-none-any.whl", hash = "sha256:85ece4451f492d0c13c5dd7c13a64681a86afae63a5f347908daf103ce6d2f67"}, + {file = "jinja2-3.1.6.tar.gz", hash = "sha256:0137fb05990d35f1275a587e9aee6d56da821fc83491a0fb838183be43f66d6d"}, ] [package.dependencies] @@ -306,18 +306,18 @@ i18n = ["Babel (>=2.7)"] [[package]] name = "markdown" -version = "3.7" +version = "3.8" description = "Python implementation of John Gruber's Markdown." optional = false -python-versions = ">=3.8" +python-versions = ">=3.9" groups = ["main"] files = [ - {file = "Markdown-3.7-py3-none-any.whl", hash = "sha256:7eb6df5690b81a1d7942992c97fad2938e956e79df20cbc6186e9c3a77b1c803"}, - {file = "markdown-3.7.tar.gz", hash = "sha256:2ae2471477cfd02dbbf038d5d9bc226d40def84b4fe2986e49b59b6b472bbed2"}, + {file = "markdown-3.8-py3-none-any.whl", hash = "sha256:794a929b79c5af141ef5ab0f2f642d0f7b1872981250230e72682346f7cc90dc"}, + {file = "markdown-3.8.tar.gz", hash = "sha256:7df81e63f0df5c4b24b7d156eb81e4690595239b7d70937d0409f1b0de319c6f"}, ] [package.extras] -docs = ["mdx-gh-links (>=0.2)", "mkdocs (>=1.5)", "mkdocs-gen-files", "mkdocs-literate-nav", "mkdocs-nature (>=0.6)", "mkdocs-section-index", "mkdocstrings[python]"] +docs = ["mdx_gh_links (>=0.2)", "mkdocs (>=1.6)", "mkdocs-gen-files", "mkdocs-literate-nav", "mkdocs-nature (>=0.6)", "mkdocs-section-index", "mkdocstrings[python]"] testing = ["coverage", "pyyaml"] [[package]] @@ -496,26 +496,21 @@ requests = "*" [[package]] name = "mkdocs-git-revision-date-localized-plugin" -version = "1.3.0" +version = "1.4.7" description = "Mkdocs plugin that enables displaying the localized date of the last git modification of a markdown file." optional = false python-versions = ">=3.8" groups = ["main"] files = [ - {file = "mkdocs_git_revision_date_localized_plugin-1.3.0-py3-none-any.whl", hash = "sha256:c99377ee119372d57a9e47cff4e68f04cce634a74831c06bc89b33e456e840a1"}, - {file = "mkdocs_git_revision_date_localized_plugin-1.3.0.tar.gz", hash = "sha256:439e2f14582204050a664c258861c325064d97cdc848c541e48bb034a6c4d0cb"}, + {file = "mkdocs_git_revision_date_localized_plugin-1.4.7-py3-none-any.whl", hash = "sha256:056c0a90242409148f1dc94d5c9d2c25b5b8ddd8de45489fa38f7fa7ccad2bc4"}, + {file = "mkdocs_git_revision_date_localized_plugin-1.4.7.tar.gz", hash = "sha256:10a49eff1e1c3cb766e054b9d8360c904ce4fe8c33ac3f6cc083ac6459c91953"}, ] [package.dependencies] babel = ">=2.7.0" -GitPython = "*" +gitpython = ">=3.1.44" mkdocs = ">=1.0" -pytz = "*" - -[package.extras] -all = ["GitPython", "babel (>=2.7.0)", "click", "codecov", "mkdocs (>=1.0)", "mkdocs-gen-files", "mkdocs-git-authors-plugin", "mkdocs-material", "mkdocs-static-i18n", "pytest", "pytest-cov", "pytz"] -base = ["GitPython", "babel (>=2.7.0)", "mkdocs (>=1.0)", "pytz"] -dev = ["click", "codecov", "mkdocs-gen-files", "mkdocs-git-authors-plugin", "mkdocs-material", "mkdocs-static-i18n", "pytest", "pytest-cov"] +pytz = ">=2025.1" [[package]] name = "mkdocs-glightbox" @@ -531,21 +526,21 @@ files = [ [[package]] name = "mkdocs-material" -version = "9.6.7" +version = "9.6.14" description = "Documentation that simply works" optional = false python-versions = ">=3.8" groups = ["main"] files = [ - {file = "mkdocs_material-9.6.7-py3-none-any.whl", hash = "sha256:8a159e45e80fcaadd9fbeef62cbf928569b93df954d4dc5ba76d46820caf7b47"}, - {file = "mkdocs_material-9.6.7.tar.gz", hash = "sha256:3e2c1fceb9410056c2d91f334a00cdea3215c28750e00c691c1e46b2a33309b4"}, + {file = "mkdocs_material-9.6.14-py3-none-any.whl", hash = "sha256:3b9cee6d3688551bf7a8e8f41afda97a3c39a12f0325436d76c86706114b721b"}, + {file = "mkdocs_material-9.6.14.tar.gz", hash = "sha256:39d795e90dce6b531387c255bd07e866e027828b7346d3eba5ac3de265053754"}, ] [package.dependencies] babel = ">=2.10,<3.0" backrefs = ">=5.7.post1,<6.0" colorama = ">=0.4,<1.0" -jinja2 = ">=3.0,<4.0" +jinja2 = ">=3.1,<4.0" markdown = ">=3.2,<4.0" mkdocs = ">=1.6,<2.0" mkdocs-material-extensions = ">=1.3,<2.0" @@ -573,14 +568,14 @@ files = [ [[package]] name = "packaging" -version = "24.2" +version = "25.0" description = "Core utilities for Python packages" optional = false python-versions = ">=3.8" groups = ["main"] files = [ - {file = "packaging-24.2-py3-none-any.whl", hash = "sha256:09abb1bccd265c01f4a3aa3f7a7db064b36514d2cba19a2f694fe6150451a759"}, - {file = "packaging-24.2.tar.gz", hash = "sha256:c228a6dc5e932d346bc5739379109d49e8853dd8223571c7c5b55260edc0b97f"}, + {file = "packaging-25.0-py3-none-any.whl", hash = "sha256:29572ef2b1f17581046b3a2227d5c611fb25ec70ca1ba8554b24b0e69331a484"}, + {file = "packaging-25.0.tar.gz", hash = "sha256:d443872c98d677bf60f6a1f2f8c1cb748e8fe762d2bf9d3148b5599295b0fc4f"}, ] [[package]] @@ -613,20 +608,20 @@ files = [ [[package]] name = "platformdirs" -version = "4.3.6" +version = "4.3.8" description = "A small Python package for determining appropriate platform-specific dirs, e.g. a `user data dir`." optional = false -python-versions = ">=3.8" +python-versions = ">=3.9" groups = ["main"] files = [ - {file = "platformdirs-4.3.6-py3-none-any.whl", hash = "sha256:73e575e1408ab8103900836b97580d5307456908a03e92031bab39e4554cc3fb"}, - {file = "platformdirs-4.3.6.tar.gz", hash = "sha256:357fb2acbc885b0419afd3ce3ed34564c13c9b95c89360cd9563f73aa5e2b907"}, + {file = "platformdirs-4.3.8-py3-none-any.whl", hash = "sha256:ff7059bb7eb1179e2685604f4aaf157cfd9535242bd23742eadc3c13542139b4"}, + {file = "platformdirs-4.3.8.tar.gz", hash = "sha256:3d512d96e16bcb959a814c9f348431070822a6496326a4be0911c40b5a74c2bc"}, ] [package.extras] -docs = ["furo (>=2024.8.6)", "proselint (>=0.14)", "sphinx (>=8.0.2)", "sphinx-autodoc-typehints (>=2.4)"] -test = ["appdirs (==1.4.4)", "covdefaults (>=2.3)", "pytest (>=8.3.2)", "pytest-cov (>=5)", "pytest-mock (>=3.14)"] -type = ["mypy (>=1.11.2)"] +docs = ["furo (>=2024.8.6)", "proselint (>=0.14)", "sphinx (>=8.1.3)", "sphinx-autodoc-typehints (>=3)"] +test = ["appdirs (==1.4.4)", "covdefaults (>=2.3)", "pytest (>=8.3.4)", "pytest-cov (>=6)", "pytest-mock (>=3.14)"] +type = ["mypy (>=1.14.1)"] [[package]] name = "pygments" @@ -645,14 +640,14 @@ windows-terminal = ["colorama (>=0.4.6)"] [[package]] name = "pymdown-extensions" -version = "10.14.3" +version = "10.15" description = "Extension pack for Python Markdown." optional = false python-versions = ">=3.8" groups = ["main"] files = [ - {file = "pymdown_extensions-10.14.3-py3-none-any.whl", hash = "sha256:05e0bee73d64b9c71a4ae17c72abc2f700e8bc8403755a00580b49a4e9f189e9"}, - {file = "pymdown_extensions-10.14.3.tar.gz", hash = "sha256:41e576ce3f5d650be59e900e4ceff231e0aed2a88cf30acaee41e02f063a061b"}, + {file = "pymdown_extensions-10.15-py3-none-any.whl", hash = "sha256:46e99bb272612b0de3b7e7caf6da8dd5f4ca5212c0b273feb9304e236c484e5f"}, + {file = "pymdown_extensions-10.15.tar.gz", hash = "sha256:0e5994e32155f4b03504f939e501b981d306daf7ec2aa1cd2eb6bd300784f8f7"}, ] [package.dependencies] @@ -664,14 +659,14 @@ extra = ["pygments (>=2.19.1)"] [[package]] name = "pyparsing" -version = "3.2.1" +version = "3.2.3" description = "pyparsing module - Classes and methods to define and execute parsing grammars" optional = false python-versions = ">=3.9" groups = ["main"] files = [ - {file = "pyparsing-3.2.1-py3-none-any.whl", hash = "sha256:506ff4f4386c4cec0590ec19e6302d3aedb992fdc02c761e90416f158dacf8e1"}, - {file = "pyparsing-3.2.1.tar.gz", hash = "sha256:61980854fd66de3a90028d679a954d5f2623e83144b5afe5ee86f43d762e5f0a"}, + {file = "pyparsing-3.2.3-py3-none-any.whl", hash = "sha256:a749938e02d6fd0b59b356ca504a24982314bb090c383e3cf201c95ef7e2bfcf"}, + {file = "pyparsing-3.2.3.tar.gz", hash = "sha256:b9c13f1ab8b3b542f72e28f634bad4de758ab3ce4546e4301970ad6fa77c38be"}, ] [package.extras] @@ -709,14 +704,14 @@ Markdown = ">=3.0" [[package]] name = "pytz" -version = "2025.1" +version = "2025.2" description = "World timezone definitions, modern and historical" optional = false python-versions = "*" groups = ["main"] files = [ - {file = "pytz-2025.1-py2.py3-none-any.whl", hash = "sha256:89dd22dca55b46eac6eda23b2d72721bf1bdfef212645d81513ef5d03038de57"}, - {file = "pytz-2025.1.tar.gz", hash = "sha256:c2db42be2a2518b28e65f9207c4d05e6ff547d1efa4086469ef855e4ab70178e"}, + {file = "pytz-2025.2-py2.py3-none-any.whl", hash = "sha256:5ddf76296dd8c44c26eb8f4b6f35488f3ccbf6fbbd7adee0b7262d43f0ec2f00"}, + {file = "pytz-2025.2.tar.gz", hash = "sha256:360b9e3dbb49a209c21ad61809c7fb453643e048b38924c765813546746e81c3"}, ] [[package]] @@ -784,14 +779,14 @@ files = [ [[package]] name = "pyyaml-env-tag" -version = "0.1" -description = "A custom YAML tag for referencing environment variables in YAML files. " +version = "1.1" +description = "A custom YAML tag for referencing environment variables in YAML files." optional = false -python-versions = ">=3.6" +python-versions = ">=3.9" groups = ["main"] files = [ - {file = "pyyaml_env_tag-0.1-py3-none-any.whl", hash = "sha256:af31106dec8a4d68c60207c1886031cbf839b68aa7abccdb19868200532c2069"}, - {file = "pyyaml_env_tag-0.1.tar.gz", hash = "sha256:70092675bda14fdec33b31ba77e7543de9ddc88f2e5b99160396572d11525bdb"}, + {file = "pyyaml_env_tag-1.1-py3-none-any.whl", hash = "sha256:17109e1a528561e32f026364712fee1264bc2ea6715120891174ed1b980d2e04"}, + {file = "pyyaml_env_tag-1.1.tar.gz", hash = "sha256:2eb38b75a2d21ee0475d6d97ec19c63287a7e140231e4214969d0eac923cd7ff"}, ] [package.dependencies] @@ -845,14 +840,14 @@ files = [ [[package]] name = "urllib3" -version = "2.3.0" +version = "2.4.0" description = "HTTP library with thread-safe connection pooling, file post, and more." optional = false python-versions = ">=3.9" groups = ["main"] files = [ - {file = "urllib3-2.3.0-py3-none-any.whl", hash = "sha256:1cee9ad369867bfdbbb48b7dd50374c0967a0bb7710050facf0dd6911440e3df"}, - {file = "urllib3-2.3.0.tar.gz", hash = "sha256:f8c5449b3cf0861679ce7e0503c7b44b5ec981bec0d1d3795a07f1ba96f0204d"}, + {file = "urllib3-2.4.0-py3-none-any.whl", hash = "sha256:4e16665048960a0900c702d4a66415956a584919c03361cac9f1df5c5dd7e813"}, + {file = "urllib3-2.4.0.tar.gz", hash = "sha256:414bc6535b787febd7567804cc015fee39daab8ad86268f1310a9250697de466"}, ] [package.extras] @@ -921,14 +916,14 @@ watchmedo = ["PyYAML (>=3.10)"] [[package]] name = "zipp" -version = "3.21.0" +version = "3.22.0" description = "Backport of pathlib-compatible object wrapper for zip files" optional = false python-versions = ">=3.9" groups = ["main"] files = [ - {file = "zipp-3.21.0-py3-none-any.whl", hash = "sha256:ac1bbe05fd2991f160ebce24ffbac5f6d11d83dc90891255885223d42b3cd931"}, - {file = "zipp-3.21.0.tar.gz", hash = "sha256:2c9958f6430a2040341a52eb608ed6dd93ef4392e02ffe219417c1b28b5dd1f4"}, + {file = "zipp-3.22.0-py3-none-any.whl", hash = "sha256:fe208f65f2aca48b81f9e6fd8cf7b8b32c26375266b009b413d45306b6148343"}, + {file = "zipp-3.22.0.tar.gz", hash = "sha256:dd2f28c3ce4bc67507bfd3781d21b7bb2be31103b51a4553ad7d90b84e57ace5"}, ] [package.extras] @@ -936,7 +931,7 @@ check = ["pytest-checkdocs (>=2.4)", "pytest-ruff (>=0.2.1) ; sys_platform != \" cover = ["pytest-cov"] doc = ["furo", "jaraco.packaging (>=9.3)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx (>=3.5)", "sphinx-lint"] enabler = ["pytest-enabler (>=2.2)"] -test = ["big-O", "importlib-resources ; python_version < \"3.9\"", "jaraco.functools", "jaraco.itertools", "jaraco.test", "more-itertools", "pytest (>=6,!=8.1.*)", "pytest-ignore-flaky"] +test = ["big-O", "importlib_resources ; python_version < \"3.9\"", "jaraco.functools", "jaraco.itertools", "jaraco.test", "more_itertools", "pytest (>=6,!=8.1.*)", "pytest-ignore-flaky"] type = ["pytest-mypy"] [metadata] diff --git a/requirements.txt b/requirements.txt index 44ca9bc3..dc6d52c9 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,7 +1,43 @@ -mkdocs -mkdocs-material -python-markdown-math -mkdocs-glightbox -mkdocs-git-revision-date-localized-plugin -mkdocs-git-committers-plugin-2 -mike \ No newline at end of file +babel==2.17.0 ; python_version >= "3.12" and python_version < "4" +backrefs==5.8 ; python_version >= "3.12" and python_version < "4" +certifi==2025.4.26 ; python_version >= "3.12" and python_version < "4" +charset-normalizer==3.4.2 ; python_version >= "3.12" and python_version < "4" +click==8.2.1 ; python_version >= "3.12" and python_version < "4" +colorama==0.4.6 ; python_version >= "3.12" and python_version < "4" +ghp-import==2.1.0 ; python_version >= "3.12" and python_version < "4" +gitdb==4.0.12 ; python_version >= "3.12" and python_version < "4" +gitpython==3.1.44 ; python_version >= "3.12" and python_version < "4" +idna==3.10 ; python_version >= "3.12" and python_version < "4" +importlib-metadata==8.7.0 ; python_version >= "3.12" and python_version < "4" +importlib-resources==6.5.2 ; python_version >= "3.12" and python_version < "4" +jinja2==3.1.6 ; python_version >= "3.12" and python_version < "4" +markdown==3.8 ; python_version >= "3.12" and python_version < "4" +markupsafe==3.0.2 ; python_version >= "3.12" and python_version < "4" +mergedeep==1.3.4 ; python_version >= "3.12" and python_version < "4" +mike==2.1.3 ; python_version >= "3.12" and python_version < "4" +mkdocs-get-deps==0.2.0 ; python_version >= "3.12" and python_version < "4" +mkdocs-git-committers-plugin-2==2.5.0 ; python_version >= "3.12" and python_version < "4" +mkdocs-git-revision-date-localized-plugin==1.4.7 ; python_version >= "3.12" and python_version < "4" +mkdocs-glightbox==0.3.7 ; python_version >= "3.12" and python_version < "4" +mkdocs-material-extensions==1.3.1 ; python_version >= "3.12" and python_version < "4" +mkdocs-material==9.6.14 ; python_version >= "3.12" and python_version < "4" +mkdocs==1.6.1 ; python_version >= "3.12" and python_version < "4" +packaging==25.0 ; python_version >= "3.12" and python_version < "4" +paginate==0.5.7 ; python_version >= "3.12" and python_version < "4" +pathspec==0.12.1 ; python_version >= "3.12" and python_version < "4" +platformdirs==4.3.8 ; python_version >= "3.12" and python_version < "4" +pygments==2.19.1 ; python_version >= "3.12" and python_version < "4" +pymdown-extensions==10.15 ; python_version >= "3.12" and python_version < "4" +pyparsing==3.2.3 ; python_version >= "3.12" and python_version < "4" +python-dateutil==2.9.0.post0 ; python_version >= "3.12" and python_version < "4" +python-markdown-math==0.8 ; python_version >= "3.12" and python_version < "4" +pytz==2025.2 ; python_version >= "3.12" and python_version < "4" +pyyaml-env-tag==1.1 ; python_version >= "3.12" and python_version < "4" +pyyaml==6.0.2 ; python_version >= "3.12" and python_version < "4" +requests==2.32.3 ; python_version >= "3.12" and python_version < "4" +six==1.17.0 ; python_version >= "3.12" and python_version < "4" +smmap==5.0.2 ; python_version >= "3.12" and python_version < "4" +urllib3==2.4.0 ; python_version >= "3.12" and python_version < "4" +verspec==0.1.0 ; python_version >= "3.12" and python_version < "4" +watchdog==6.0.0 ; python_version >= "3.12" and python_version < "4" +zipp==3.22.0 ; python_version >= "3.12" and python_version < "4"