4jcraft/targets/minecraft/world/entity/monster/SharedMonsterAttributes.h
Tropical dd93cfe91e
Some checks are pending
Build (Linux, x86-64) / build-linux (push) Waiting to run
Format Check / clang-format (push) Waiting to run
format everything
2026-04-01 13:48:29 -05:00

34 lines
922 B
C++

#pragma once
class Attribute;
class AttributeInstance;
class AttributeModifier;
class BaseAttributeMap;
class CompoundTag;
template <class T>
class ListTag;
class SharedMonsterAttributes {
public:
static Attribute* MAX_HEALTH;
static Attribute* FOLLOW_RANGE;
static Attribute* KNOCKBACK_RESISTANCE;
static Attribute* MOVEMENT_SPEED;
static Attribute* ATTACK_DAMAGE;
static ListTag<CompoundTag>* saveAttributes(BaseAttributeMap* attributes);
private:
static CompoundTag* saveAttribute(AttributeInstance* instance);
static CompoundTag* saveAttributeModifier(AttributeModifier* modifier);
public:
static void loadAttributes(BaseAttributeMap* attributes,
ListTag<CompoundTag>* list);
private:
static void loadAttribute(AttributeInstance* instance, CompoundTag* tag);
public:
static AttributeModifier* loadAttributeModifier(CompoundTag* tag);
};