osb/source/game/interfaces/StarInspectableEntity.hpp

35 lines
766 B
C++
Raw Permalink Normal View History

#pragma once
2023-06-20 04:33:09 +00:00
2023-06-30 01:44:42 +00:00
#include "StarEntity.hpp"
2023-06-20 04:33:09 +00:00
namespace Star {
STAR_CLASS(InspectableEntity);
2023-06-30 01:44:42 +00:00
class InspectableEntity : public virtual Entity {
2023-06-20 04:33:09 +00:00
public:
// Default implementation returns true
virtual bool inspectable() const;
// If this entity can be entered into the player log, will return the log
// identifier.
virtual Maybe<String> inspectionLogName() const;
// Long description to display when inspected, if any
virtual Maybe<String> inspectionDescription(String const& species) const;
};
inline bool InspectableEntity::inspectable() const {
return true;
}
inline Maybe<String> InspectableEntity::inspectionLogName() const {
return {};
}
inline Maybe<String> InspectableEntity::inspectionDescription(String const&) const {
return {};
}
}