Compatibility
Minecraft: Java Edition
Platforms
Supported environments
Links
Tags
Creators
Details
This mod adds cargo rockets to Ad Astra and, when used with CC:tweaked, allows you to automate the transport of items between planets.
Features added in this fork
Added particle and sound, and rework launch/landing animation
Use ad astra's sound and particle to expression
It can now take off and land more smoothly than before.
Also, a bug where the rocket would land on blocks without collision detection has been fixed.
New rocket type
Added three new tiers of rockets.
Each tier has a different maximum number of planets it can reach.
The same range limitations apply as for AdAstra's rockets
With the addition of rocket tiers, fuel and energy consumption now increases depending on the destination
Added New useful tag
This mod add itemtag denied_in_launch_pad to prevent to use specified item in launch pad (e.g. shulker box)
By using this tag,you can prevent illegal transport technic.
customizable the difficulty level and fuel efficiency for your destination
Change config/ad_astra_cargo_rockets.json to customize target destination cost and fuel efficient.
Added Useful CC's Function
๐ฅ loadAllItems([filter])
Moves all items from the launchpad's inventory to the rocket's inventory.
If you specify an item ID, you can move only that item.
๐ค unloadAllItems([filter])
Moves all items from the rocket's inventory to the launchpad's inventory.
If you specify an item ID, you can move only that item.
Parameters
filter? (string) : Name of the item to load or unload (e.g. "minecraft:cobblestone")
Rocket Launchpad Lua API
This API allows you to control a rocket launchpad from a CC:Tweaked computer. It provides functions to launch rockets, manage inventories, and check energy levels.
Connecting
You must connect the computer to the central block of the launch pad to access the below methods. Connecting to the outer blocks will allow you to access the generic inventory methods.
๐ฆ Inventory Slot Indexing
- All inventory slot indexes in Lua start at 1, matching CC:Tweaked's conventions.
๐งจ launch(planet)
Attempts to launch a rocket to the specified planet. (See getValidDestinations)
Parameters
planet(string): The name of the destination planet.
Errors
"No rocket found"โ No rocket is on the launchpad."<planet> is not a valid planet"โ The specified planet name is invalid."Not enough energy to launch"โ The launchpad lacks sufficient energy."<planet> is too high of a tier for this rocket"โ The rocket tier is too low for the destination.
๐ฅ moveItemsFromRocketToLaunchPad(rocketSlot, launchPadSlot)
Moves an item from the rocket's inventory to the launchpad's inventory.
Parameters
rocketSlot(int): Slot in the rocket's inventory.launchPadSlot(int): Slot in the launchpad's inventory.
Errors
"No rocket found""Destination full""Invalid slot"
๐ค moveItemsFromLaunchPadToRocket(launchPadSlot, rocketSlot)
Moves an item from the launchpad's inventory to the rocket's inventory.
Parameters
launchPadSlot(int): Slot in the launchpad's inventory.rocketSlot(int): Slot in the rocket's inventory.
Errors
"No rocket found""Destination full""Invalid slot"
โก getEnergyRequiredForLaunch()
Returns the amount of energy required to launch the rocket.
Returns
int: Energy required.
๐ getEnergy()
Returns the current stored energy in the launchpad.
Returns
long: Current energy.
๐ getMaxEnergy()
Returns the maximum energy capacity of the launchpad.
Returns
long: Maximum energy.
๐ getValidDestinations()
Returns a table of valid destination planet names, with the key being the planet and the value being the required rocket tier to reach it.
Returns
table<string, int>: Table with the key being the planet and the value being the required rocket tier to reach it.
๐ฆ listLaunchPadInventory()
Returns the current non-empty inventory of the launchpad.
Returns
table<int, table>: A table mapping slot indexes to item tables with:name(string): Display name.id(string): Registry ID.count(int): Stack size.max_count(int): Maximum stack size.
๐ฅ listLaunchPadInputSlotIndexes()
Lists which slot indexes are considered input slots. These are the slots hoppers and other item transportation mods can insert into.
Returns
int[]: List of input slot indexes (1-based).
๐ค listLaunchPadOutputSlotIndexes()
Lists which slot indexes are considered output slots. These are the slots hoppers and other item transportation mods can extract from.
Returns
int[]: List of output slot indexes (1-based).
๐ isRocketPresent()
Checks whether a rocket is present on the launchpad.
Returns
boolean:trueif a rocket is present,falseotherwise.
๐ listRocketInventory()
Returns the current non-empty inventory of the rocket.
Returns
table<int, table>|nil: Table mapping slot indexes to item data if rocket is present, ornilif no rocket is found. Item tables contain:name(string): Display name.id(string): Registry ID.count(int): Stack size.max_count(int): Maximum stack size.
Credit
Fork Source: Ad Astra Cargo Rockets by BillBodkin URL: https://modrinth.com/mod/ad-astra-cargo-rockets
![Ad Astra Cargo Rocket [Unofficial]](https://cdn.modrinth.com/data/lRJr3dkW/72e8d67b662bef4e42d322b58bd4b32c08060a5b.png)

