Move definition to thingtype.cpp file

Move definition from thingtype.h to thingtype.cpp file
This commit is contained in:
EgzoT 2017-11-15 02:20:33 +01:00 committed by GitHub
parent c51df93e3e
commit 5650db7ba2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 9 additions and 1 deletions

View File

@ -564,3 +564,11 @@ int ThingType::getExactSize(int layer, int xPattern, int yPattern, int zPattern,
Size size = m_texturesFramesOriginRects[animationPhase][frameIndex].size() - m_texturesFramesOffsets[animationPhase][frameIndex].toSize();
return std::max<int>(size.width(), size.height());
}
void ThingType::setPathable(bool var)
{
if(var == true)
m_attribs.remove(ThingAttrNotPathable);
else
m_attribs.set(ThingAttrNotPathable, true);
}

View File

@ -178,7 +178,7 @@ public:
bool isNotMoveable() { return m_attribs.has(ThingAttrNotMoveable); }
bool blockProjectile() { return m_attribs.has(ThingAttrBlockProjectile); }
bool isNotPathable() { return m_attribs.has(ThingAttrNotPathable); }
void setPathable(bool var) { var == true ? m_attribs.remove(ThingAttrNotPathable) : m_attribs.set(ThingAttrNotPathable, true); }
void setPathable(bool var);
bool isPickupable() { return m_attribs.has(ThingAttrPickupable); }
bool isHangable() { return m_attribs.has(ThingAttrHangable); }
bool isHookSouth() { return m_attribs.has(ThingAttrHookSouth); }