49 return InventoryItem::Load<Skill>(
skillID );
59 if (skillRef.
get() ==
nullptr) {
100 if (timeElapsed > 60) {
106 _log(SKILL__TRACE,
"Skill::GetCurrentSP() for %s is %u - delta: %u, elapsed time: %us", \
107 name(), currentSP, delta, timeElapsed);
127 remainingSP -= ((timeLeft /60) * ch->
GetSPPerMin(
this));
151 return timeLeft - delta;
159 _log(SKILL__INFO,
"Skill %s level type != int. Fixing...",
name());
163 _log(SKILL__INFO,
"Skill %s sp type != int. Fixing...",
name());
171 _log(SKILL__MESSAGE,
"Begin SP check for %s. level %u: CurrentSP: %u", \
184 if (spCurrent < spThisLevel) {
185 _log(SKILL__WARNING,
"Skill %s points low. Updating from %u to %u",
name(), spCurrent, spThisLevel);
192 if (spCurrent > spNextLevel) {
195 _log(SKILL__WARNING,
" %s - Skillpoints high for L5. Updating SP from %u to %u.", \
196 name(), spCurrent, spNextLevel);
198 _log(SKILL__WARNING,
" %s - Skillpoints high. Updating level from %u to %u and SP from %u to %u.", \
199 name(), level -1, level, spCurrent, spNextLevel);
bool SkillPrereqsComplete(Character &ch)
#define _log(type, fmt,...)
bool HasAttribute(const uint16 attrID) const
uint8 GetSPPerMin(Skill *skill)
static bool FitModuleSkillCheck(InventoryItemRef item, CharacterRef ch)
Skill(uint32 _skillID, const ItemType &_type, const ItemData &_data)
static SkillRef Spawn(ItemData &data)
this is a class that kinda mimics how python polymorph's numbers.
uint32 GetSPForLevel(uint8 level)
uint32 PointsAtLevel(uint8 level, float rank)
#define is_log_enabled(type)
typeID Spawn an NPC with the specified type text Search for items matching the specified query() type()() itemID() copy() materialLevel()()() itemID() itemID Fits selected item to active ship() skillID(level)-gives skillID to specified level." ) COMMAND( online
uint8 LevelForPoints(uint32 currentSP, uint8 rank)
const uint8 MAXSKILLLEVEL
void SetAttribute(uint16 attrID, int num, bool notify=true)
static SkillRef Load(uint32 skillID)
bool ChangeSingleton(bool singleton, bool notify=false)
uint32 GetCurrentSP(Character *ch, int64 startTime=0)
EVEItemFlags flag() const
uint8 GetLevelForSP(uint32 currentSP)
static uint32 CreateItemID(ItemData &data)
EvilNumber GetAttribute(const uint16 attrID) const
int8 GetSkillLevel(uint16 skillTypeID, bool zeroForNotInjected=true) const
uint32 GetRemainingSP(Character *ch, int64 curTime=0)
uint32 GetTrainingTime(Character *ch, int64 startTime=0)
Reference-counting-based smart pointer.