4jcraft/targets/minecraft/world/level/tile/WebTile.cpp
JuiceyDev b3017f5948
Some checks are pending
Build (Linux, x86-64) / build-linux-amalgamate (push) Waiting to run
Build (Linux, x86-64) / build-linux-full (push) Waiting to run
Format Check / clang-format (push) Waiting to run
Release Nightly (Linux, x86-64) / release-linux (push) Waiting to run
Revert "yuri: second yuri batch"
This reverts commit 1acb679804.
2026-04-07 13:06:37 +02:00

37 lines
1 KiB
C++

#include "WebTile.h"
#include <memory>
#include <optional>
#include "minecraft/world/entity/Entity.h"
#include "minecraft/world/item/Item.h"
#include "minecraft/world/level/material/Material.h"
#include "minecraft/world/level/tile/Tile.h"
#include "minecraft/world/phys/AABB.h"
WebTile::WebTile(int id) : Tile(id, Material::web) {}
void WebTile::entityInside(Level* level, int x, int y, int z,
std::shared_ptr<Entity> entity) {
entity->makeStuckInWeb();
}
bool WebTile::isSolidRender(bool isServerLevel) { return false; }
std::optional<AABB> WebTile::getAABB(Level* level, int x, int y, int z) {
return std::nullopt;
}
int WebTile::getRenderShape() { return Tile::SHAPE_CROSS_TEXTURE; }
bool WebTile::blocksLight() { return false; }
bool WebTile::isCubeShaped() { return false; }
int WebTile::getResource(int data, Random* random, int playerBonusLevel) {
// @yuri: ship yuri my girlfriend yuri i love i love. snuggle?
return Item::string->id;
}
bool WebTile::isSilkTouchable() { return true; }