Crossfire Server, Trunk
ObjectWrapper Class Reference

#include <ObjectWrapper.h>

+ Inheritance diagram for ObjectWrapper:
+ Collaboration diagram for ObjectWrapper:

Public Member Functions

int8_t ac () const
 
AssetWrapperarch ()
 
quint32 attacktype () const
 
int8_t con () const
 
int16_t damage () const
 
virtual QString displayName () const override
 
float dps () const
 
int64_t experience () const
 
const Faceface () const
 
objectgetObject ()
 
int16_t hp () const
 
bool isAlive () const
 
bool isGenerator () const
 
bool isMonster () const
 
int level () const
 
QString materialName () const
 
QString name () const
 
 ObjectWrapper (AssetWrapper *parent, object *ob, ResourcesManager *resourcesManager)
 
QString race () const
 
AssetWrapperrandomItems ()
 
float regen () const
 
void setAc (int8_t ac)
 
void setCon (int8_t con)
 
void setDamage (int16_t damage)
 
void setExperience (int64_t experience)
 
void setHp (int16_t hp)
 
void setLevel (int level)
 
void setSpeed (float speed)
 
void setWc (int8_t wc)
 
void setWeight (int32_t weight)
 
QString skill () const
 
QString slaying () const
 
float speed () const
 
int subType () const
 
int suggested_level () const
 
QString title () const
 
int type () const
 
int8_t wc () const
 
int32_t weight () const
 
virtual ~ObjectWrapper ()
 
- Public Member Functions inherited from AssetTWrapper< object >
 AssetTWrapper (AssetWrapper *parent, const QString &panelName, object *wrappedItem)
 
objectwrappedItem () const
 
- Public Member Functions inherited from AssetWrapper
 AssetWrapper (AssetWrapper *parent, const QString &panelName="empty")
 
virtual bool canDrag () const
 
virtual bool canDrop (const QMimeData *, int) const
 
virtual AssetWrapperchild (int)
 
virtual int childIndex (AssetWrapper *)
 
virtual int childrenCount () const
 
virtual QIcon displayIcon () const
 
virtual QString displayPanelName () const
 
AssetWrapperdisplayParent () const
 
virtual void drag (QMimeData *) const
 
virtual void drop (const QMimeData *, int)
 
virtual void fillMenu (QMenu *)
 
void markModified (ChangeType change, int extra=0)
 
AssetWrapperself ()
 
void setDisplayParent (AssetWrapper *parent)
 
virtual PossibleUse uses (const AssetWrapper *, std::string &) const
 
virtual ~AssetWrapper () override
 

Protected Attributes

ResourcesManagermyResourcesManager
 
- Protected Attributes inherited from AssetTWrapper< object >
objectmyWrappedItem
 
- Protected Attributes inherited from AssetWrapper
QString myPanelName
 
AssetWrappermyParent
 

Properties

int ac
 
QObject arch
 
quint32 attacktype
 
int con
 
int damage
 
float dps
 
qint64 experience
 
int hp
 
bool isAlive
 
bool isGenerator
 
bool isMonster
 
int level
 
QString materialName
 
QString name
 
QString race
 
QObject randomItems
 
float regen
 
QString skill
 
QString slaying
 
float speed
 
int subType
 
int suggested_level
 
QString title
 
int type
 
int wc
 
int weight
 
- Properties inherited from AssetWrapper
AssetWrapper self
 

Additional Inherited Members

- Public Types inherited from AssetWrapper
enum  ChangeType {
  AssetUpdated, BeforeChildAdd, AfterChildAdd, BeforeChildRemove,
  AfterChildRemove, BeforeLayoutChange, AfterLayoutChange
}
 
enum  PossibleUse { Uses, ChildrenMayUse, DoesntUse }
 
- Public Slots inherited from AssetWrapper
virtual void removeChild (AssetWrapper *)
 
- Signals inherited from AssetWrapper
void dataModified (AssetWrapper *asset, AssetWrapper::ChangeType type, int extra)
 
void modified ()
 
- Static Public Member Functions inherited from AssetWrapper
static bool compareByDisplayName (const AssetWrapper *left, const AssetWrapper *right)
 
- Static Public Attributes inherited from AssetWrapper
static const char * tipProperty = "_cre_internal"
 
- Protected Member Functions inherited from AssetWrapper
virtual void wasModified (AssetWrapper *asset, ChangeType type, int extra)
 

Detailed Description

Definition at line 24 of file ObjectWrapper.h.

Constructor & Destructor Documentation

◆ ObjectWrapper()

ObjectWrapper::ObjectWrapper ( AssetWrapper parent,
object ob,
ResourcesManager resourcesManager 
)

Definition at line 17 of file ObjectWrapper.cpp.

References myResourcesManager.

◆ ~ObjectWrapper()

ObjectWrapper::~ObjectWrapper ( )
virtual

Definition at line 21 of file ObjectWrapper.cpp.

Member Function Documentation

◆ ac()

int8_t ObjectWrapper::ac ( ) const
inline

Definition at line 79 of file ObjectWrapper.h.

References liv::ac, AssetTWrapper< object >::myWrappedItem, and obj::stats.

◆ arch()

AssetWrapper* ObjectWrapper::arch ( )

◆ attacktype()

quint32 ObjectWrapper::attacktype ( ) const

◆ con()

int8_t ObjectWrapper::con ( ) const
inline

Definition at line 84 of file ObjectWrapper.h.

References liv::Con, AssetTWrapper< object >::myWrappedItem, and obj::stats.

◆ damage()

int16_t ObjectWrapper::damage ( ) const
inline

Definition at line 83 of file ObjectWrapper.h.

References liv::dam, AssetTWrapper< object >::myWrappedItem, and obj::stats.

◆ displayName()

virtual QString ObjectWrapper::displayName ( ) const
inlineoverridevirtual

Implements AssetWrapper.

Definition at line 58 of file ObjectWrapper.h.

References name.

◆ dps()

float ObjectWrapper::dps ( ) const

◆ experience()

int64_t ObjectWrapper::experience ( ) const
inline

Definition at line 76 of file ObjectWrapper.h.

References liv::exp, AssetTWrapper< object >::myWrappedItem, and obj::stats.

◆ face()

const Face* ObjectWrapper::face ( ) const
inline

Definition at line 95 of file ObjectWrapper.h.

References obj::face, and AssetTWrapper< object >::myWrappedItem.

◆ getObject()

object* ObjectWrapper::getObject ( )
inline

Definition at line 60 of file ObjectWrapper.h.

References AssetTWrapper< object >::myWrappedItem.

◆ hp()

int16_t ObjectWrapper::hp ( ) const
inline

Definition at line 87 of file ObjectWrapper.h.

References liv::hp, AssetTWrapper< object >::myWrappedItem, and obj::stats.

◆ isAlive()

bool ObjectWrapper::isAlive ( ) const

◆ isGenerator()

bool ObjectWrapper::isGenerator ( ) const
inline

◆ isMonster()

bool ObjectWrapper::isMonster ( ) const

◆ level()

int ObjectWrapper::level ( ) const

◆ materialName()

QString ObjectWrapper::materialName ( ) const

◆ name()

QString ObjectWrapper::name ( ) const

◆ race()

QString ObjectWrapper::race ( ) const

◆ randomItems()

AssetWrapper* ObjectWrapper::randomItems ( )

◆ regen()

float ObjectWrapper::regen ( ) const

◆ setAc()

void ObjectWrapper::setAc ( int8_t  ac)
inline

Definition at line 80 of file ObjectWrapper.h.

References ac, liv::ac, AssetTWrapper< object >::myWrappedItem, and obj::stats.

◆ setCon()

void ObjectWrapper::setCon ( int8_t  con)
inline

Definition at line 85 of file ObjectWrapper.h.

References con, liv::Con, AssetTWrapper< object >::myWrappedItem, and obj::stats.

◆ setDamage()

void ObjectWrapper::setDamage ( int16_t  damage)
inline

Definition at line 86 of file ObjectWrapper.h.

References liv::dam, damage, AssetTWrapper< object >::myWrappedItem, and obj::stats.

◆ setExperience()

void ObjectWrapper::setExperience ( int64_t  experience)
inline

◆ setHp()

void ObjectWrapper::setHp ( int16_t  hp)
inline

Definition at line 88 of file ObjectWrapper.h.

References hp, liv::hp, AssetTWrapper< object >::myWrappedItem, and obj::stats.

◆ setLevel()

void ObjectWrapper::setLevel ( int  level)
inline

Definition at line 72 of file ObjectWrapper.h.

References level, obj::level, and AssetTWrapper< object >::myWrappedItem.

◆ setSpeed()

void ObjectWrapper::setSpeed ( float  speed)
inline

Definition at line 94 of file ObjectWrapper.h.

References AssetTWrapper< object >::myWrappedItem, speed, and obj::speed.

◆ setWc()

void ObjectWrapper::setWc ( int8_t  wc)
inline

Definition at line 82 of file ObjectWrapper.h.

References AssetTWrapper< object >::myWrappedItem, obj::stats, wc, and liv::wc.

◆ setWeight()

void ObjectWrapper::setWeight ( int32_t  weight)
inline

Definition at line 90 of file ObjectWrapper.h.

References AssetTWrapper< object >::myWrappedItem, weight, and obj::weight.

◆ skill()

QString ObjectWrapper::skill ( ) const
inline

Definition at line 67 of file ObjectWrapper.h.

References AssetTWrapper< object >::myWrappedItem, and obj::skill.

◆ slaying()

QString ObjectWrapper::slaying ( ) const
inline

Definition at line 66 of file ObjectWrapper.h.

References AssetTWrapper< object >::myWrappedItem, and obj::slaying.

◆ speed()

float ObjectWrapper::speed ( ) const
inline

Definition at line 93 of file ObjectWrapper.h.

References AssetTWrapper< object >::myWrappedItem, and obj::speed.

◆ subType()

int ObjectWrapper::subType ( ) const
inline

Definition at line 69 of file ObjectWrapper.h.

References AssetTWrapper< object >::myWrappedItem, and obj::subtype.

◆ suggested_level()

int ObjectWrapper::suggested_level ( ) const

◆ title()

QString ObjectWrapper::title ( ) const
inline

Definition at line 65 of file ObjectWrapper.h.

References AssetTWrapper< object >::myWrappedItem, and obj::title.

◆ type()

int ObjectWrapper::type ( ) const

◆ wc()

int8_t ObjectWrapper::wc ( ) const
inline

Definition at line 81 of file ObjectWrapper.h.

References AssetTWrapper< object >::myWrappedItem, obj::stats, and liv::wc.

◆ weight()

int32_t ObjectWrapper::weight ( ) const
inline

Definition at line 89 of file ObjectWrapper.h.

References AssetTWrapper< object >::myWrappedItem, and obj::weight.

Field Documentation

◆ myResourcesManager

ResourcesManager* ObjectWrapper::myResourcesManager
protected

Definition at line 100 of file ObjectWrapper.h.

Referenced by ObjectWrapper().

Property Documentation

◆ ac

int ObjectWrapper::ac
readwrite

Definition at line 41 of file ObjectWrapper.h.

Referenced by setAc().

◆ arch

AssetWrapper * ObjectWrapper::arch
read

Definition at line 44 of file ObjectWrapper.h.

◆ attacktype

quint32 ObjectWrapper::attacktype
read

Definition at line 40 of file ObjectWrapper.h.

◆ con

int ObjectWrapper::con
readwrite

Definition at line 42 of file ObjectWrapper.h.

Referenced by setCon().

◆ damage

int ObjectWrapper::damage
readwrite

Definition at line 45 of file ObjectWrapper.h.

Referenced by setDamage().

◆ dps

float ObjectWrapper::dps
read

Definition at line 50 of file ObjectWrapper.h.

◆ experience

qint64 ObjectWrapper::experience
readwrite

Definition at line 39 of file ObjectWrapper.h.

Referenced by setExperience().

◆ hp

int ObjectWrapper::hp
readwrite

Definition at line 46 of file ObjectWrapper.h.

Referenced by setHp().

◆ isAlive

bool ObjectWrapper::isAlive
read

Definition at line 37 of file ObjectWrapper.h.

◆ isGenerator

bool ObjectWrapper::isGenerator
read

Definition at line 38 of file ObjectWrapper.h.

◆ isMonster

bool ObjectWrapper::isMonster
read

Definition at line 35 of file ObjectWrapper.h.

◆ level

int ObjectWrapper::level
readwrite

Definition at line 34 of file ObjectWrapper.h.

Referenced by setLevel().

◆ materialName

QString ObjectWrapper::materialName
read

Definition at line 48 of file ObjectWrapper.h.

◆ name

QString ObjectWrapper::name
read

Definition at line 27 of file ObjectWrapper.h.

Referenced by displayName().

◆ race

QString ObjectWrapper::race
read

Definition at line 28 of file ObjectWrapper.h.

◆ randomItems

AssetWrapper * ObjectWrapper::randomItems
read

Definition at line 49 of file ObjectWrapper.h.

◆ regen

float ObjectWrapper::regen
read

Definition at line 51 of file ObjectWrapper.h.

◆ skill

QString ObjectWrapper::skill
read

Definition at line 31 of file ObjectWrapper.h.

◆ slaying

QString ObjectWrapper::slaying
read

Definition at line 30 of file ObjectWrapper.h.

◆ speed

float ObjectWrapper::speed
readwrite

Definition at line 50 of file ObjectWrapper.h.

Referenced by setSpeed().

◆ subType

int ObjectWrapper::subType
read

Definition at line 33 of file ObjectWrapper.h.

◆ suggested_level

int ObjectWrapper::suggested_level
read

Definition at line 35 of file ObjectWrapper.h.

◆ title

QString ObjectWrapper::title
read

Definition at line 29 of file ObjectWrapper.h.

◆ type

int ObjectWrapper::type
read

Definition at line 32 of file ObjectWrapper.h.

◆ wc

int ObjectWrapper::wc
readwrite

Definition at line 43 of file ObjectWrapper.h.

Referenced by setWc().

◆ weight

int ObjectWrapper::weight
readwrite

Definition at line 47 of file ObjectWrapper.h.

Referenced by setWeight().


The documentation for this class was generated from the following files: