41 _active(false), _noCollide(false), _pcSpeaker(0), _area(0), _lastTriggerer(0) {
204 warning(
"TODO: Object::playAnimation(\"%s\")", animation.
c_str());
208 warning(
"TODO: Object::playAnimation(%d)", (
int) animation);
220 positional.
getVector(
"Position", x, y, z);
225 positional.
getVector(
"Orientation", x, y, z);
An object within a Jade Empire area.
Handling version V3.2/V3.3 of BioWare's GFFs (generic file format).
float _orientation[4]
The object's orientation.
virtual void highlight(bool enabled)
(Un)Highlight the object.
Common::UString _description
The object's description.
Common::UString _conversation
The object's default conversation.
Location getLocation() const
Create a Location out of the object's area, position and orientation.
bool isNoCollide() const
Is collision checking disabled?
#define TalkMan
Shortcut for accessing the talk manager.
Area * getArea() const
Return the area this object is currently in.
A class holding an UTF-8 string.
virtual void show()
Show the object's model(s).
void loadPositional(const Aurora::GFF3Struct &gff)
Load the object's positional gff struct which contains the position and orientation.
virtual void setPosition(float x, float y, float z)
Set the object's position within its area.
void setPosition(float x, float y, float z)
Set the location's position.
Utility functions for generating unique IDs.
const Common::UString & getDescription() const
Return the object's description.
virtual void playAnimation(const Common::UString &animation="", bool restart=true, int32 loopCount=0)
Play an object animation.
Area * _area
The area the object is currently in.
Aurora::NWScript::Object * getPCSpeaker() const
Return the PC currently speaking with this object.
bool hasScript(Script script) const
void setNoCollide(bool noCollide)
Enable or disable collision checking.
bool runScript(Script script, const Aurora::NWScript::ObjectReference owner=Aurora::NWScript::ObjectReference(), const Aurora::NWScript::ObjectReference triggerer=Aurora::NWScript::ObjectReference())
bool isClickable() const
Can the player click the object?
const Common::UString & getConversation() const
Return the object's default conversation (DLG).
virtual void enter()
The cursor entered the object.
float _position[3]
The object's position.
bool _static
Is the object static?
bool isUsable() const
Can the object be used by the PC?
const char * c_str() const
Return the (utf8 encoded) string data.
void getVector(const Common::UString &field, float &x, float &y, float &z) const
Basic Jade Empire type definitions.
Utility templates and functions.
bool _usable
Is the object usable?
An area in Jade Empire, holding all objects and rooms within, as well as general area properties like...
virtual void getOrientation(float &x, float &y, float &z, float &angle) const
Return the object's orientation.
void speakString(int32 resref)
Speak the specified string.
bool _active
Is the object currently active/available/visible?
virtual bool click(Object *triggerer=0)
The object was clicked.
void setPCSpeaker(Aurora::NWScript::Object *pc)
Set the PC currently speaking with this object.
virtual void getPosition(float &x, float &y, float &z) const
Return the object's position within its area.
bool isStatic() const
Is the object static (not manipulable at all)?
void warning(const char *s,...)
Object * getLastTriggerer() const
Return the object that last triggered this object.
An object within a Jade area.
std::list< uint32 > _ids
The object's model IDs.
bool isActive() const
Is the object currently active/available/visible?
const GFF3Struct & getStruct(const Common::UString &field) const
The global talk manager for Aurora strings.
virtual void hide()
Hide the object's model(s).
virtual void loadModel()
Load the object's model(s).
void status(const char *s,...)
bool _noCollide
Is collision checking for the object disabled?
void setArea(Area *)
Set the area this object is currently in.
virtual void leave()
The cursor left the object.
void setFacing(float facing)
Set the location's orientation.
virtual void unloadModel()
Unload the object's model(s).
Common::UString _name
The object's display name.
const std::list< uint32 > & getIDs() const
Return the object's model IDs.
ObjectType getType() const
Return the exact type of the object.
Object * _lastTriggerer
The object that last used this object.
const Common::UString & getName() const
Return the object's name.
virtual void setOrientation(float x, float y, float z, float angle)
Set the object's orientation.
uint32 generateIDNumber()
Aurora::NWScript::Object * _pcSpeaker
The current PC speaking with the object.
ObjectType _type
The object's type.
void setArea(Area *area)
Set the location's area.