mirror of
https://github.com/Minecraft-Community-Edition/client.git
synced 2026-05-25 10:34:33 +00:00
reimplement aether stuff from personal repo
This commit is contained in:
26
Minecraft.World/AetherLeafTile.cpp
Normal file
26
Minecraft.World/AetherLeafTile.cpp
Normal file
@@ -0,0 +1,26 @@
|
||||
#include "stdafx.h"
|
||||
#include "AetherLeafTile.h"
|
||||
#include "net.minecraft.world.level.h"
|
||||
#include "net.minecraft.world.h"
|
||||
|
||||
AetherLeafTile::AetherLeafTile(int id) : TransparentTile(id, Material::leaves, true, isSolidRender())
|
||||
{
|
||||
setTicking(false);
|
||||
}
|
||||
|
||||
int AetherLeafTile::getResource(int data, Random *random, int playerBonusLevel)
|
||||
{
|
||||
// Skyroot leaves drop skyroot saplings, golden oak leaves drop golden oak saplings
|
||||
if (id == Tile::goldenOakLeaves_Id) return Tile::goldenOakSapling_Id;
|
||||
return Tile::skyrootSapling_Id;
|
||||
}
|
||||
|
||||
int AetherLeafTile::getResourceCount(Random *random)
|
||||
{
|
||||
return random->nextInt(20) == 0 ? 1 : 0;
|
||||
}
|
||||
|
||||
bool AetherLeafTile::isSeasonalLeaf() const
|
||||
{
|
||||
return false;
|
||||
}
|
||||
Reference in New Issue
Block a user