ScummVM API documentation
Sherlock::BaseObject Class Reference
Inheritance diagram for Sherlock::BaseObject:
Sherlock::Object Sherlock::Sprite Sherlock::Person Sherlock::Scalpel::ScalpelPerson Sherlock::Tattoo::TattooPerson

Public Member Functions

bool hasAborts () const
 
void checkObject ()
 
int checkNameForCodes (const Common::String &name, FixedTextActionId fixedTextActionId=kFixedTextAction_Invalid)
 
virtual void setObjTalkSequence (int seq)
 

Static Public Member Functions

static void setVm (SherlockEngine *vm)
 

Public Attributes

SpriteType _type
 
Common::String _description
 
byte * _sequences
 
ImageFile_images
 
ImageFrame_imageFrame
 
int _sequenceNumber
 
int _startSeq
 
int _walkCount
 
int _allow
 
int _frameNumber
 
Point32 _position
 
Point32 _delta
 
Common::Point _oldPosition
 
Common::Point _oldSize
 
Point32 _goto
 
int _lookFlag
 
int _requiredFlag [2]
 
Common::Point _noShapeSize
 
int _status
 
int8 _misc
 
int _maxFrames
 
int _flags
 
AType _aType
 
int _lookFrames
 
int _seqCounter
 
PositionFacing _lookPosition
 
int _lookcAnim
 
int _seqStack
 
int _seqTo
 
uint _descOffset
 
int _seqCounter2
 
uint _seqSize
 
UseType _use [6]
 
int _quickDraw
 
int _scaleVal
 
int _gotoSeq
 
int _talkSeq
 
int _restoreSlot
 

Static Public Attributes

static bool _countCAnimFrames
 

Protected Member Functions

bool checkEndOfSequence ()
 
void setObjSequence (int seq, bool wait)
 

Static Protected Attributes

static SherlockEngine_vm
 

Member Function Documentation

◆ checkEndOfSequence()

bool Sherlock::BaseObject::checkEndOfSequence ( )
protected

This will check to see if the object has reached the end of a sequence. If it has, it switch to whichever next sequence should be started.

Returns
true if the end of a sequence was reached

◆ setObjSequence()

void Sherlock::BaseObject::setObjSequence ( int  seq,
bool  wait 
)
protected

Scans through the sequences array and finds the designated sequence. It then sets the frame number of the start of that sequence

◆ hasAborts()

bool Sherlock::BaseObject::hasAborts ( ) const

Returns true if the object has an Allow Talk Code in the sequence that it's currently running, specified by the _talkSeq field of the object. If it's 0, then it's a regular sequence. If it's not 0 but below 128, then it's a Talk Sequence. If it's above 128, then it's one of the Listen sequences.

◆ checkObject()

void Sherlock::BaseObject::checkObject ( )

Check the state of the object

◆ checkNameForCodes()

int Sherlock::BaseObject::checkNameForCodes ( const Common::String name,
FixedTextActionId  fixedTextActionId = kFixedTextAction_Invalid 
)

Checks for codes

Parameters
nameThe name to check for codes
messagesProvides a lookup list of messages that can be printed
Returns
0 if no codes are found, 1 if codes were found

◆ setObjTalkSequence()

virtual void Sherlock::BaseObject::setObjTalkSequence ( int  seq)
inlinevirtual

Adjusts the frame and sequence variables of a sprite that corresponds to the current speaker so that it points to the beginning of the sequence number's talk sequence in the object's sequence buffer

Parameters
seqWhich sequence to use (if there's more than 1)
Remarks
1: First talk seq, 2: second talk seq, etc.

Reimplemented in Sherlock::Object, Sherlock::Sprite, and Sherlock::Tattoo::TattooPerson.


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