Skip to content

Commit

Permalink
nitra plant + loot tables and recipes
Browse files Browse the repository at this point in the history
  • Loading branch information
MBatt1 committed Apr 14, 2024
1 parent 77234bf commit 98caab4
Show file tree
Hide file tree
Showing 28 changed files with 245 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
import net.id.paradiselost.blocks.mechanical.FoodBowlBlock;
import net.id.paradiselost.blocks.mechanical.FourBiteCakeBlock;
import net.id.paradiselost.blocks.mechanical.IncubatorBlock;
import net.id.paradiselost.blocks.mechanical.NitraBlock;
import net.id.paradiselost.blocks.mechanical.TreeTapBlock;
import net.id.paradiselost.blocks.natural.ParadiseLostGrassBlock;
import net.id.paradiselost.blocks.natural.ParadiseLostSaplingBlock;
Expand Down Expand Up @@ -335,6 +336,7 @@ private static Settings lichen() {
public static final AmadrysCropBlock AMADRYS = add("amadrys", new AmadrysCropBlock(crop().mapColor(MapColor.PINK)), flammablePlant, cutoutMippedRenderLayer);
public static final FlaxCropBlock FLAX = add("flax", new FlaxCropBlock(crop().mapColor(MapColor.OAK_TAN)), flammablePlant, cutoutRenderLayer);
public static final SwedrootCropBlock SWEDROOT = add("swedroot", new SwedrootCropBlock(shrub().mapColor(MapColor.BLUE)), flammablePlant, cutoutRenderLayer);
public static final CropBlock NITRA = add("nitra", new CropBlock(crop().mapColor(MapColor.PALE_YELLOW)), flammablePlant, cutoutMippedRenderLayer);

public static final Block FLAXWEAVE_CUSHION = add("flaxweave_cushion", new FlaxweaveCushionBlock(Settings.of(Material.WOOL).mapColor(MapColor.YELLOW).sounds(BlockSoundGroup.WOOL).strength(0.2F)), flammable(40, 10));

Expand Down Expand Up @@ -392,6 +394,7 @@ private static Settings cherineTorch() {
public static final IncubatorBlock INCUBATOR = add("incubator", new IncubatorBlock(of(Material.WOOD, MapColor.DULL_RED).strength(2.5f).sounds(BlockSoundGroup.WOOD).nonOpaque()), cutoutMippedRenderLayer);
public static final FoodBowlBlock FOOD_BOWL = add("food_bowl", new FoodBowlBlock(of(Material.WOOD, MapColor.DULL_RED).strength(2.5f).sounds(BlockSoundGroup.WOOD).nonOpaque()), cutoutMippedRenderLayer);
public static final Block TREE_TAP = add("tree_tap", new TreeTapBlock(of(Material.WOOD, MapColor.OAK_TAN).strength(2.5f).sounds(BlockSoundGroup.WOOD).nonOpaque().ticksRandomly()), cutoutRenderLayer);
public static final NitraBlock NITRA_BUNCH = add("nitra_bunch", new NitraBlock(of(Material.PLANT, MapColor.PALE_YELLOW).strength(0.5f).sounds(BlockSoundGroup.WET_GRASS)));

//dungeon
// public static final DungeonSwitchBlock DUNGEON_SWITCH = add("dungeonswitch", new DungeonSwitchBlock(of(Material.METAL, MapColor.BLUE).strength(-1.0F, 3600000.0F)));
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
package net.id.paradiselost.blocks.mechanical;

import net.minecraft.block.Block;

public class NitraBlock extends Block {

public NitraBlock(Settings settings) {
super(settings);
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
import net.minecraft.item.ItemConvertible;

class ParadiseLostItemActions {
protected static final RegistryQueue.Action<ItemConvertible> compostable15 = compostable(0.15f);
protected static final RegistryQueue.Action<ItemConvertible> compostable30 = compostable(0.3f);
protected static final RegistryQueue.Action<ItemConvertible> compostable50 = compostable(0.5f);
protected static final RegistryQueue.Action<ItemConvertible> compostable65 = compostable(0.65f);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,7 @@ private static Settings food(FoodComponent foodComponent, Rarity rarity) {
public static final AliasedBlockItem BLACKCURRANT = add("blackcurrant", new AliasedBlockItem(ParadiseLostBlocks.BLACKCURRANT_BUSH, food(ParadiseLostFoodComponent.BLACKCURRANT)), compostable30);
public static final Item ORANGE = add("orange", new Item(food(ParadiseLostFoodComponent.ORANGE)), compostable65);
public static final AliasedBlockItem AMADRYS_BUSHEL = add("amadrys_bushel", new AliasedBlockItem(ParadiseLostBlocks.AMADRYS, food(ParadiseLostFoodComponent.GENERIC_WORSE)), compostable30);
public static final AliasedBlockItem NITRA = add("nitra", new AliasedBlockItem(ParadiseLostBlocks.NITRA, food()), compostable15);
public static final Item AMADRYS_NOODLES = add("amadrys_noodles", new StewItem(food(ParadiseLostFoodComponent.AMADRYS_NOODLES)));
public static final Item AMADRYS_BREAD = add("amadrys_bread", new Item(food(ParadiseLostFoodComponent.AMADRYS_BREAD)));
public static final Item AMADRYS_BREAD_GLAZED = add("amadrys_bread_glazed", new Item(food(ParadiseLostFoodComponent.AMADRYS_BREAD_GLAZED)));
Expand All @@ -176,6 +177,7 @@ private static Settings misc() {
public static final BlockItem INCUBATOR = add("incubator", ParadiseLostBlocks.INCUBATOR, misc, fuel(300));
public static final BlockItem FOOD_BOWL = add("food_bowl", ParadiseLostBlocks.FOOD_BOWL, misc, fuel(300));
public static final BlockItem TREE_TAP = add("tree_tap", ParadiseLostBlocks.TREE_TAP, misc, fuel(300));
public static final BlockItem NITRA_BUNCH = add("nitra_bunch", ParadiseLostBlocks.NITRA_BUNCH, misc, fuel(3200));

public static final AurelBucketItem AUREL_BUCKET = add("aurel_bucket", new AurelBucketItem(misc().maxCount(16)), fuel(200), emptyBucketBehavior);

Expand Down
6 changes: 2 additions & 4 deletions src/main/resources/asset_helper.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,10 +80,8 @@ def generate_slab_block(block_id, base_block_id, texture):



generate_standard_block("levita")
generate_standard_block("levita_ore")
generate_standard_item("levita_gem")
generate_standard_item("levita_wand")
generate_standard_block("nitra_bunch")
generate_standard_item("nitra")



28 changes: 28 additions & 0 deletions src/main/resources/assets/paradise_lost/blockstates/nitra.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
{
"variants": {
"age=0": {
"model": "paradise_lost:block/nitra_stage0"
},
"age=1": {
"model": "paradise_lost:block/nitra_stage0"
},
"age=2": {
"model": "paradise_lost:block/nitra_stage1"
},
"age=3": {
"model": "paradise_lost:block/nitra_stage1"
},
"age=4": {
"model": "paradise_lost:block/nitra_stage1"
},
"age=5": {
"model": "paradise_lost:block/nitra_stage2"
},
"age=6": {
"model": "paradise_lost:block/nitra_stage2"
},
"age=7": {
"model": "paradise_lost:block/nitra_stage3"
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"variants": {
"": {
"model": "paradise_lost:block/nitra_bunch"
}
}
}
2 changes: 2 additions & 0 deletions src/main/resources/assets/paradise_lost/lang/en_us.json
Original file line number Diff line number Diff line change
Expand Up @@ -255,6 +255,7 @@
"block.paradise_lost.incubator": "Incubator",
"block.paradise_lost.food_bowl": "Feeding Trough",
"block.paradise_lost.tree_tap": "Tree Tap",
"block.paradise_lost.nitra_bunch": "Nitra Bunch",

"block.paradise_lost.crystal_chest": "Crystal Chest",
"block.paradise_lost.golden_oak_chest": "Mother Aurel Chest",
Expand Down Expand Up @@ -341,6 +342,7 @@
"item.paradise_lost.blackcurrant": "Blackcurrant",
"item.paradise_lost.orange": "Orange",
"item.paradise_lost.amadrys_bushel": "Amadrys Bushel",
"item.paradise_lost.nitra": "Nitra Bulb",
"item.paradise_lost.amadrys_noodles": "Amadrys Noodle Soup",
"item.paradise_lost.amadrys_bread": "Amadrys Loaf",
"item.paradise_lost.amadrys_bread_glazed": "Glazed Amadrys Loaf",
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
{
"ambientocclusion": false,
"textures": {
"particle": "#crop"
},
"elements": [
{ "from": [ 0.8, -1, 8 ],
"to": [ 15.2, 15, 8 ],
"rotation": { "origin": [ 8, 8, 8 ], "axis": "y", "angle": 45, "rescale": true },
"shade": false,
"faces": {
"north": { "uv": [ 0, 0, 16, 16 ], "texture": "#crop" },
"south": { "uv": [ 0, 0, 16, 16 ], "texture": "#crop" }
}
},
{ "from": [ 8, -1, 0.8 ],
"to": [ 8, 15, 15.2 ],
"rotation": { "origin": [ 8, 8, 8 ], "axis": "y", "angle": 45, "rescale": true },
"shade": false,
"faces": {
"west": { "uv": [ 0, 0, 16, 16 ], "texture": "#crop" },
"east": { "uv": [ 0, 0, 16, 16 ], "texture": "#crop" }
}
}
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"parent": "minecraft:block/cube_bottom_top",
"textures": {
"bottom": "paradise_lost:block/nitra_bunch_bottom",
"side": "paradise_lost:block/nitra_bunch_side",
"top": "paradise_lost:block/nitra_bunch_top"
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"parent": "paradise_lost:block/cross_crop",
"textures": {
"crop": "paradise_lost:block/nitra_stage0"
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"parent": "paradise_lost:block/cross_crop",
"textures": {
"crop": "paradise_lost:block/nitra_stage1"
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"parent": "paradise_lost:block/cross_crop",
"textures": {
"crop": "paradise_lost:block/nitra_stage2"
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"parent": "paradise_lost:block/cross_crop",
"textures": {
"crop": "paradise_lost:block/nitra_stage3"
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"parent": "minecraft:item/generated",
"textures": {
"layer0": "paradise_lost:item/nitra"
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"parent": "paradise_lost:block/nitra_bunch"
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
{
"type": "minecraft:block",
"pools": [
{
"rolls": 1.0,
"bonus_rolls": 0.0,
"entries": [
{
"type": "minecraft:item",
"name": "paradise_lost:nitra"
}
]
},
{
"rolls": 1.0,
"bonus_rolls": 0.0,
"entries": [
{
"type": "minecraft:item",
"functions": [
{
"function": "minecraft:apply_bonus",
"enchantment": "minecraft:fortune",
"formula": "minecraft:binomial_with_bonus_count",
"parameters": {
"extra": 3,
"probability": 0.5714286
}
}
],
"name": "paradise_lost:nitra"
}
],
"conditions": [
{
"condition": "minecraft:block_state_property",
"block": "paradise_lost:nitra",
"properties": {
"age": "7"
}
}
]
},
{
"rolls": 1.0,
"bonus_rolls": 0.0,
"entries": [
{
"type": "minecraft:item",
"conditions": [
{
"condition": "minecraft:random_chance",
"chance": 0.02
}
],
"name": "paradise_lost:nitra"
}
],
"conditions": [
{
"condition": "minecraft:block_state_property",
"block": "paradise_lost:nitra",
"properties": {
"age": "7"
}
}
]
}
],
"functions": [
{
"function": "minecraft:explosion_decay"
}
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"type": "minecraft:block",
"pools": [
{
"rolls": 1.0,
"bonus_rolls": 0.0,
"entries": [
{
"type": "minecraft:item",
"name": "paradise_lost:nitra_bunch"
}
],
"conditions": [
{
"condition": "minecraft:survives_explosion"
}
]
}
]
}
12 changes: 12 additions & 0 deletions src/main/resources/data/paradise_lost/recipes/nitra.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"type": "minecraft:crafting_shapeless",
"ingredients": [
{
"item": "paradise_lost:nitra_bunch"
}
],
"result": {
"item": "paradise_lost:nitra",
"count": 4
}
}
15 changes: 15 additions & 0 deletions src/main/resources/data/paradise_lost/recipes/nitra_bunch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"type": "minecraft:crafting_shaped",
"pattern": [
"##",
"##"
],
"key": {
"#": {
"item": "paradise_lost:nitra"
}
},
"result": {
"item": "paradise_lost:nitra_bunch"
}
}

0 comments on commit 98caab4

Please sign in to comment.