mirror of
https://github.com/GTNewHorizons/ForestryMC.git
synced 2026-11-21 12:32:23 +00:00
Add cocoon world genartion with config entry(default false) and add cocoon loot and a greenhouse butterfly hatch
This commit is contained in:
1 parent
bc0d105730
commit
cf23644f45
35 files changed
+748
-61
No files matched your search
@@ -5,10 +5,12 @@
|
||||
******************************************************************************/
|
||||
package forestry.api.greenhouse;
|
||||
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
|
||||
import forestry.api.core.EnumHumidity;
|
||||
import forestry.api.core.EnumTemperature;
|
||||
import forestry.api.multiblock.IMultiblockComponent;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
public interface IGreenhouseState {
|
||||
@@ -22,6 +24,8 @@ public interface IGreenhouseState {
|
||||
float getExactHumidity();
|
||||
|
||||
List<IInternalBlock> getInternalBlocks();
|
||||
|
||||
Collection<IMultiblockComponent> getGreenhouseComponents();
|
||||
|
||||
/**
|
||||
* @return The world in that the greenhouse standing
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* This work (the API) is licensed under the "MIT" License, see LICENSE.txt for details.
|
||||
******************************************************************************/
|
||||
@API(apiVersion = "5.0.0", owner = "ForestryAPI|greenhouse", provides = "ForestryAPI|greenhouse")
|
||||
@API(apiVersion = "5.0.0", owner = "ForestryAPI|core", provides = "ForestryAPI|greenhouse")
|
||||
package forestry.api.greenhouse;
|
||||
|
||||
import net.minecraftforge.fml.common.API;
|
||||
@@ -10,7 +10,10 @@
|
||||
******************************************************************************/
|
||||
package forestry.api.lepidopterology;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
import forestry.api.genetics.IAllele;
|
||||
import net.minecraft.item.ItemStack;
|
||||
|
||||
public interface IAlleleButterflyCocoon extends IAllele {
|
||||
|
||||
@@ -18,4 +21,6 @@ public interface IAlleleButterflyCocoon extends IAllele {
|
||||
|
||||
String getCocoonTexture(int age);
|
||||
|
||||
Map<ItemStack, Float> getCocoonLoot();
|
||||
|
||||
}
|
||||
@@ -78,6 +78,12 @@ public interface IButterfly extends IIndividualLiving {
|
||||
*/
|
||||
ItemStack[] getCaterpillarDrop(IButterflyNursery nursery, boolean playerKill, int lootLevel);
|
||||
|
||||
/**
|
||||
* @param cocoon
|
||||
* @return Array of itemstacks to drop on breaking of the cocoon.
|
||||
*/
|
||||
ItemStack[] getCocoonDrop(IButterflyCocoon cocoon);
|
||||
|
||||
/**
|
||||
* Create an exact copy of this butterfly.
|
||||
*/
|
||||
|
||||
@@ -13,7 +13,7 @@ package forestry.api.lepidopterology;
|
||||
import forestry.api.genetics.IHousing;
|
||||
|
||||
public interface IButterflyCocoon extends IHousing{
|
||||
|
||||
|
||||
IButterfly getCaterpillar();
|
||||
|
||||
void setCaterpillar(IButterfly butterfly);
|
||||
@@ -22,4 +22,6 @@ public interface IButterflyCocoon extends IHousing{
|
||||
|
||||
void setNursery(IButterflyNursery nursery);
|
||||
|
||||
boolean isSolid();
|
||||
|
||||
}
|
||||
@@ -8,6 +8,8 @@ package forestry.api.multiblock;
|
||||
import forestry.api.core.IClimateControlled;
|
||||
import forestry.api.greenhouse.IGreenhouseHousing;
|
||||
import forestry.api.greenhouse.IGreenhouseListener;
|
||||
import forestry.api.lepidopterology.IButterflyCocoon;
|
||||
import net.minecraft.item.ItemStack;
|
||||
|
||||
public interface IGreenhouseComponent<T extends IMultiblockLogicGreenhouse> extends IMultiblockComponent {
|
||||
@Override
|
||||
@@ -23,6 +25,10 @@ public interface IGreenhouseComponent<T extends IMultiblockLogicGreenhouse> exte
|
||||
interface Climatiser extends IGreenhouseComponent {
|
||||
<G extends IGreenhouseController & IGreenhouseHousing & IClimateControlled> void changeClimate(int tickCount, G greenhouse);
|
||||
}
|
||||
|
||||
interface ButterflyHatch extends IGreenhouseComponent {
|
||||
ItemStack[] addCocoonLoot(IButterflyCocoon cocoon);
|
||||
}
|
||||
|
||||
interface Active extends IGreenhouseComponent {
|
||||
void updateServer(int tickCount);
|
||||
|
||||
Reference in new issue
Block a user