123456789101112131415161718192021222324252627282930313233343536373839404142 |
- #include "ItemSkill.h"
- #include "ItemType.h"
- #include "StaticRegistry.h"
- ItemSkill::ItemSkill(int itemTypeId)
- : Framework::ReferenceCounter(),
- itemTypeId(itemTypeId)
- {}
- const ItemType* ItemSkill::zSkillType()
- {
- return StaticRegistry<ItemType>::INSTANCE.zElement(itemTypeId);
- }
- int ItemSkill::getTypeId()
- {
- return itemTypeId;
- }
- BasicItemSkill::BasicItemSkill(int itemTypeId,
- float maxXP,
- float durabilityModifier,
- float speedModifier,
- float luckModifier,
- float staminaModifier,
- float hungerModifier,
- float xpIncrease)
- : ItemSkill(itemTypeId),
- level(1),
- xp(0),
- maxXP(maxXP),
- durabilityModifier(durabilityModifier),
- speedModifier(speedModifier),
- luckModifier(luckModifier),
- staminaModifier(staminaModifier),
- hungerModifier(hungerModifier)
- {}
- void BasicItemSkill::use(Entity* zActor, Item* zUsedItem, Block* zTarget) {}
- void BasicItemSkill::use(Entity* zActor, Item* zUsedItem, Entity* zTarget) {}
|