WIP: infusion
This commit is contained in:
parent
e96d06337e
commit
437e8d9cdc
6 changed files with 306 additions and 23 deletions
|
@ -1,19 +1,42 @@
|
|||
package ru.betterend.rituals;
|
||||
|
||||
import net.minecraft.block.BlockState;
|
||||
import net.minecraft.entity.player.PlayerEntity;
|
||||
import net.minecraft.inventory.Inventory;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.CompoundTag;
|
||||
import net.minecraft.util.math.BlockPos;
|
||||
import net.minecraft.world.World;
|
||||
import ru.betterend.recipe.builders.InfusionRecipe;
|
||||
|
||||
public class InfusionRitual implements Inventory {
|
||||
|
||||
private final World world;
|
||||
private final BlockPos worldPos;
|
||||
private InfusionRecipe activeRecipe;
|
||||
private int progress = 0;
|
||||
private int time = 0;
|
||||
|
||||
public InfusionRitual(World world, BlockPos pos) {
|
||||
this.world = world;
|
||||
this.worldPos = pos;
|
||||
}
|
||||
|
||||
public void tick() {
|
||||
// TODO
|
||||
if (!hasRecipe()) return;
|
||||
this.progress++;
|
||||
if (progress == time) {
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
public boolean hasRecipe() {
|
||||
return this.activeRecipe != null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void clear() {
|
||||
// TODO Auto-generated method stub
|
||||
|
||||
// TODO
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -53,6 +76,13 @@ public class InfusionRitual implements Inventory {
|
|||
|
||||
@Override
|
||||
public boolean canPlayerUse(PlayerEntity player) {
|
||||
return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
public void fromTag(CompoundTag tag) {
|
||||
}
|
||||
|
||||
public CompoundTag toTag(CompoundTag tag) {
|
||||
return tag;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue