Fix up the categories: Only need one book

This commit is contained in:
Aly 2020-12-15 17:55:13 -08:00
parent 1e68decf62
commit 796b47ab34
11 changed files with 59 additions and 17 deletions

View file

@ -5,7 +5,6 @@ import net.minecraft.item.ItemGroup
import net.minecraft.item.ItemStack
import net.minecraft.util.Identifier
import net.minecraft.util.registry.Registry
import tf.bug.monadmachines.books.IntroToComputing
val MONADMACHINES_ITEMGROUP: ItemGroup = FabricItemGroupBuilder.build(
Identifier("monadmachines", "group")
@ -13,7 +12,7 @@ val MONADMACHINES_ITEMGROUP: ItemGroup = FabricItemGroupBuilder.build(
@Suppress("unused")
fun init() {
Registry.register(Registry.ITEM, IntroToComputing.id, IntroToComputing)
Registry.register(Registry.ITEM, MonadMachinesManual.id, MonadMachinesManual)
Registry.register(Registry.BLOCK, ProgramWorkstation.id, ProgramWorkstation)
Registry.register(Registry.ITEM, ProgramWorkstation.id, ProgramWorkstation.item)

View file

@ -1,4 +1,4 @@
package tf.bug.monadmachines.books
package tf.bug.monadmachines
import net.fabricmc.loader.api.FabricLoader
import net.minecraft.client.item.TooltipContext
@ -11,12 +11,11 @@ import net.minecraft.text.TextColor
import net.minecraft.text.TranslatableText
import net.minecraft.util.*
import net.minecraft.world.World
import tf.bug.monadmachines.MONADMACHINES_ITEMGROUP
import vazkii.patchouli.api.PatchouliAPI
object IntroToComputing : Item(Settings().group(MONADMACHINES_ITEMGROUP)) {
object MonadMachinesManual : Item(Settings().group(MONADMACHINES_ITEMGROUP)) {
val id = Identifier("monadmachines", "intro_to_computing")
val id = Identifier("monadmachines", "manual")
fun getEdition(): Text {
return if(FabricLoader.getInstance().isModLoaded("patchouli")) {

View file

@ -2,8 +2,8 @@
"monadmachines.no_patchouli_tooltip": "Patchouli not found!",
"monadmachines.no_patchouli_message": "Patchouli was not detected to be loaded! Please install the mod, or check your logs for any errors that might cause it to not load.",
"item.monadmachines.intro_to_computing": "Intro to Computing",
"monadmachines.intro_to_computing.landing": "Getting Started with MonadMachines",
"item.monadmachines.manual": "Owner's Manual",
"monadmachines.manual.landing": "From your first computer to full automation",
"itemGroup.monadmachines.group": "MonadMachines",

View file

@ -1,6 +1,6 @@
{
"parent": "item/generated",
"textures": {
"layer0": "monadmachines:item/intro_to_computing"
"layer0": "monadmachines:item/manual"
}
}

View file

@ -1,8 +0,0 @@
{
"name": "item.monadmachines.intro_to_computing",
"landing_text": "monadmachines.intro_to_computing.landing",
"version": 1,
"dont_generate_book": true,
"custom_book_item": "monadmachines:intro_to_computing",
"creative_tab": "monadmachines.group"
}

View file

@ -0,0 +1,8 @@
{
"name": "item.monadmachines.manual",
"landing_text": "monadmachines.manual.landing",
"version": 1,
"dont_generate_book": true,
"custom_book_item": "monadmachines:manual",
"creative_tab": "monadmachines.group"
}

View file

@ -0,0 +1,6 @@
{
"name": "About MonadMachines",
"description": "What is MonadMachines? Do I need programming experience?",
"icon": "monadmachines:manual",
"sortnum": 0
}

View file

@ -0,0 +1,6 @@
{
"name": "Intro to Computing",
"description": "Build and program your first computer.",
"icon": "monadmachines:program_card",
"sortnum": 1
}

View file

@ -0,0 +1,16 @@
{
"name": "What is MonadMachines?",
"icon": "monadmachines:manual",
"category": "monadmachines:about",
"pages": [
{
"type": "text",
"text": "MonadMachines is a computing mod designed to be more powerful and less game-breaking than its predecessors. It requires more powerful items in the early-game and locks certain features away until late-game in hopes of preventing computers from being incredibly overpowered."
},
{
"type": "text",
"title": "I can't program!",
"text": "My hope is that MonadMachines is usable by and approachable to anyone who doesn't have prior experience programming. It's my belief that a mod like this is a great way to teach certain programming constructs and ideas if done correctly.$(br2)That being said, there's a great chance there are concepts not explained well in the book.$(br)$(4)TODO:$() $(7)Make a Discord for this$()"
}
]
}

View file

@ -0,0 +1,16 @@
{
"name": "Your First Computer",
"icon": "monadmachines:manual",
"category": "monadmachines:intro",
"pages": [
{
"type": "text",
"text": "To start writing programs for your first computer, you're going to need to craft a $(3)Program Card$() and a $(3)Program Workstation$()."
},
{
"type": "crafting",
"recipe": "monadmachines:program_card",
"recipe2": "monadmachines:program_workstation"
}
]
}