ScummVM API documentation
Nancy::Action::ShovelMeasurePuzzle Class Reference
Inheritance diagram for Nancy::Action::ShovelMeasurePuzzle:
Nancy::Action::PuzzleRecord Nancy::Action::RenderActionRecord Nancy::Action::ActionRecord Nancy::RenderObject

Classes

struct  Cell
 
struct  Stretch
 

Public Member Functions

void init () override
 
void readData (Common::SeekableReadStream &stream) override
 
void execute () override
 
void handleInput (NancyInput &input) override
 
bool isViewportRelative () const override
 
- Public Member Functions inherited from Nancy::Action::PuzzleRecord
 PuzzleRecord (uint zOrder)
 
Common::String getRecordExtraInfo () const override
 
- Public Member Functions inherited from Nancy::Action::RenderActionRecord
 RenderActionRecord (uint zOrder)
 
 RenderActionRecord (RenderActionRecord &&)=default
 
void onPause (bool pause) override
 
- Public Member Functions inherited from Nancy::Action::ActionRecord
virtual CursorManager::CursorType getHoverCursor () const
 
virtual bool cursorSetFromScript () const
 
virtual bool canHaveHotspot () const
 
virtual bool survivesSceneChange (bool nextSceneIsNoArt) const
 
- Public Member Functions inherited from Nancy::RenderObject
 RenderObject (uint16 zOrder)
 
 RenderObject (uint16 zOrder, Graphics::ManagedSurface &surface, const Common::Rect &srcBounds, const Common::Rect &destBounds)
 
 RenderObject (RenderObject &&)=default
 
virtual void registerGraphics ()
 
virtual void updateGraphics ()
 
void moveTo (const Common::Point &position)
 
void moveTo (const Common::Rect &bounds)
 
void setVisible (bool visible)
 
void setTransparent (bool isTransparent)
 
bool isVisible () const
 
bool needsRedraw () const
 
void setNeedsRedraw (bool needsRedraw)
 
void setHasMoved (bool hasMoved)
 
bool isNativeResolution () const
 
void setNativeResolution (bool isNative)
 
void grabPalette (byte *colors, uint paletteStart=0, uint paletteSize=256)
 
void setPalette (const Common::Path &paletteName, uint paletteStart=0, uint paletteSize=256)
 
void setPalette (const byte *colors, uint paletteStart=0, uint paletteSize=256)
 
bool hasMoved () const
 
void updatePreviousScreenPosition ()
 
Common::Rect getScreenPosition () const
 
Common::Rect getScreenPositionRaw () const
 
Common::Rect getPreviousScreenPosition () const
 
Common::Rect convertToLocal (const Common::Rect &screen) const
 
Common::Rect convertToScreen (const Common::Rect &rect) const
 
Common::Rect getBounds () const
 
uint16 getZOrder () const
 
void setZOrder (uint16 z)
 

Protected Types

enum  Direction {
  kNorth, kSouth, kEast, kWest,
  kNumDirections, kNoDirection = -1
}
 
enum  Command { kNoCommand, kFace, kStep }
 
enum  Outcome { kNone, kWon, kLost, kExited }
 

Protected Member Functions

Common::String getRecordTypeName () const override
 
bool isValidCell (const Common::Point &pos) const
 
Cell & getCell (const Common::Point &pos)
 
const Cell & getCell (const Common::Point &pos) const
 
Common::Point getCellCenter (const Common::Point &pos) const
 
void face (Direction direction)
 
void step ()
 
void finishMove ()
 
void updateMeasure ()
 
void drawRotated (const Common::Rect &src, const Common::Point &srcPivot, const Common::Point &destPivot, double angle)
 
void redraw ()
 
- Protected Member Functions inherited from Nancy::Action::PuzzleRecord
void loadImage ()
 
void initViewportSurface ()
 
void setDataCursor (uint16 cursorType, bool hotspotVariant=true) const
 
Common::Point getHeldPiecePos (const Common::Point &mousePos, const Common::Rect &src, const Common::Point &offset) const
 
SoundDescription playSoundBlock (const RandomSoundBlock &block)
 
bool isSoundBlockPlaying (const RandomSoundBlock &block) const
 
void readExitHotspot (Common::SeekableReadStream &stream)
 
bool isExitHotspotHovered (const NancyInput &input) const
 
void setExitCursor () const
 
bool hoverExitHotspot (const NancyInput &input) const
 
bool hasSolveSound () const
 
void playSolveSound ()
 
bool isSolveSoundPlaying () const
 
- Protected Member Functions inherited from Nancy::Action::ActionRecord
void finishExecution ()
 

Static Protected Member Functions

static Direction readDirection (Common::SeekableReadStream &stream)
 
static Common::Point getNeighbor (const Common::Point &pos, Direction direction)
 
static double getAngle (Direction direction)
 

Protected Attributes

uint16 _buttonCursor = 0
 
int32 _maxWrongSteps = 0
 
uint32 _moveTime = 0
 
Common::Rect _directionButtons [kNumDirections]
 
Common::Rect _dialSrc
 
Common::Rect _dialDest
 
Common::Point _dialPivot
 
Common::Rect _stepPressedSrc
 
Common::Rect _stepButton
 
Common::Point _startPos
 
Direction _startDirection = kNorth
 
Common::Rect _shovelSrc
 
Common::Rect _tapeDest
 
Common::Array< Common::Array< Common::Rect > > _tapeSrcs
 
uint _maxMeasure = 0
 
Common::Rect _firstCell
 
Common::Point _cellSpacing
 
int _numColumns = 0
 
int _numRows = 0
 
Common::Array< Cell > _cells
 
Common::Array< Stretch > _path
 
RandomSoundBlock _turnSound
 
RandomSoundBlock _stepSound
 
RandomSoundBlock _winSound
 
SceneChangeWithFlag _loseScene
 
RandomSoundBlock _loseSound
 
Common::Point _pos
 
Common::Point _targetPos
 
Direction _direction = kNorth
 
Direction _targetDirection = kNorth
 
Command _move = kNoCommand
 
uint32 _moveStartTime = 0
 
uint _measure = 0
 
uint _shownMeasure = 0
 
Common::Point _lastGuessPos
 
uint _currentStretch = 0
 
int32 _numWrongSteps = 0
 
Outcome _outcome = kNone
 
- Protected Attributes inherited from Nancy::Action::PuzzleRecord
Common::Path _imageName
 
Graphics::ManagedSurface _image
 
SceneChangeWithFlag _solveScene
 
SoundDescription _solveSound
 
uint16 _solveSoundDelay = 0
 
SceneChangeWithFlag _exitScene
 
Common::Rect _exitHotspot
 
uint16 _exitCursorType = 0
 
bool _exitCursorFromData = false
 
- Protected Attributes inherited from Nancy::RenderObject
bool _needsRedraw
 
bool _isVisible
 
bool _hasMoved
 
bool _isNativeResolution = false
 
uint16 _z
 
Common::Rect _previousScreenPosition
 
Common::Rect _screenPosition
 

Additional Inherited Members

- Public Types inherited from Nancy::Action::ActionRecord
enum  ExecutionState { kBegin, kRun, kActionTrigger }
 
enum  ExecutionType { kOneShot = 1, kRepeating = 2 }
 
- Public Attributes inherited from Nancy::Action::ActionRecord
Common::String _description
 
Common::String _includeSource
 
byte _type
 
ExecutionType _execType
 
DependencyRecord _dependencies
 
bool _isActive
 
bool _isDone
 
bool _hasHotspot
 
Common::Rect _hotspot
 
ExecutionState _state
 
DependencyRecord * _cursorDependency
 
- Public Attributes inherited from Nancy::RenderObject
Graphics::ManagedSurface _drawSurface
 

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