25 #ifndef ENGINES_KOTOR2_OBJECT_H 26 #define ENGINES_KOTOR2_OBJECT_H 63 const std::list<uint32> &
getIDs()
const;
84 virtual void getPosition(
float &x,
float &y,
float &z)
const;
86 virtual void getOrientation(
float &x,
float &y,
float &z,
float &angle)
const;
89 virtual void setPosition(
float x,
float y,
float z);
91 virtual void setOrientation(
float x,
float y,
float z,
float angle);
103 virtual void enter();
104 virtual void leave();
151 #endif // ENGINES_KOTOR2_OBJECT_H
bool isStatic() const
Is the object static (not manipulable at all)?
virtual void getPosition(float &x, float &y, float &z) const
Return the object's position within its area.
Room * getRoom()
Get a room the object is in.
A class holding an UTF-8 string.
void stopSound()
Stop the current object sound.
virtual void playAnimation(const Common::UString &anim, bool restart=true, float length=0.0f, float speed=1.0f)
float _position[3]
The object's position.
float _orientation[4]
The object's orientation.
virtual void hideSoft()
Hide the object's model(s) if applicable.
virtual bool click(Object *triggerer=0)
The object was clicked.
virtual void setPosition(float x, float y, float z)
Set the object's position within its area.
virtual bool isVisible() const
Is the object's model(s) visible?
bool _usable
Is the object usable?
An object containing scripts.
virtual void enter()
The cursor entered the object.
virtual void getOrientation(float &x, float &y, float &z, float &angle) const
Return the object's orientation.
virtual void hide()
Hide the object's model(s).
virtual void highlight(bool enabled)
(Un)Highlight the object.
bool isClickable() const
Can the player click the object?
const Common::UString & getDescription() const
Return the object's description.
std::list< uint32 > _ids
The object's model IDs.
Common::UString _name
The object's display name.
Basic Star Wars: Knights of the Old Republic II - The Sith Lords type definitions.
Common::UString _portrait
The object's portrait.
Low-level type definitions to handle fixed width types portably.
void setRoom(Room *room)
Set a room the object is in.
Sound::ChannelHandle _sound
The currently playing object sound.
ObjectType _type
The object's type.
bool isUsable() const
Can the object be used by the PC?
void playSound(const Common::UString &sound, bool pitchVariance=false)
Play an object sound.
ObjectType getType() const
Return the exact type of the object.
ObjectType
Object type, matches the bitfield in nwscript.nss.
A handle to a sound channel.
virtual void setOrientation(float x, float y, float z, float angle)
Set the object's orientation.
bool _static
Is the object static?
virtual void show()
Show the object's model(s).
const Common::UString & getPortrait() const
Return the object's portrait.
virtual void leave()
The cursor left the object.
void makeLookAt(float x, float y)
Room * _room
Room the object is in.
const std::list< uint32 > & getIDs() const
Return the object's model IDs.
const Common::UString & getName() const
Return the object's name.
Common::UString _description
The object's description.