ResidualVM logo ResidualVM website - Forums - Contact us BuildBot - Doxygen - Wiki curved edge

Static Resource provider. More...

#include <staticprovider.h>

Collaboration diagram for Stark::StaticProvider:

List of all members.

Public Types

enum  UIElement {
  kInventoryScrollUpArrow = 1, kInventoryScrollDownArrow = 2, kImages = 4, kActionMenuBg = 5,
  kTextScrollUpArrow = 6, kTextScrollDownArrow = 7, kQuit = 8, kCheckMark = 13,
  kVolume = 14, kDiaryNormal = 15, kInventory = 16, kExitArrow = 17,
  kExitArrowLeft = 18, kExitArrowRight = 19, kTextBackgroundActive = 20, kTextBackgroundPassive = 21,
  kDiaryTabbed = 22
}
enum  UIImage { kInventoryBg = 0, kDialogOptionBullet = 4 }
enum  UISound { kInventoryNewItem = 2 }

Public Member Functions

 StaticProvider (ArchiveLoader *archiveLoader)
void init ()
 Load the static level archive.
void onGameLoop ()
 State update loop.
void shutdown ()
 Release the static resources.
Resources::LevelgetLevel () const
 Obtain the static level.
VisualImageXMGgetCursorImage (uint32 cursor) const
 Get an image for a static cursor.
VisualImageXMGgetUIElement (UIElement element) const
 Get an image for a static UI element.
VisualImageXMGgetUIElement (UIElement element, uint32 index) const
VisualImageXMGgetUIImage (UIImage image) const
 Get an image for a static UI element.
Resources::SoundgetUISound (UISound sound) const
 Get a static UI sound resource.
void goToAnimScriptStatement (UIElement stockUIElement, int animScriptItemIndex)
 Move execution of a static UI element anim script to the specified item.
Resources::LocationloadLocation (const char *locationName)
 Load a static location and set it as current.
bool isStaticLocation () const
 Is a static location currently loaded?
Resources::LocationgetLocation () const
 Obtain the currently loaded static location, if any.
Resources::SoundgetLocationSound (uint16 index) const
 Look up a sound resource in the current static location by its index.
void unloadLocation (Resources::Location *location)
 Unload the current static location.

Private Member Functions

Common::String buildLocationArchiveName (const char *locationName) const

Private Attributes

ArchiveLoader_archiveLoader
Resources::Level_level
Resources::Location_location
Common::Array< Resources::Anim * > _stockAnims
Common::Array< Resources::Image * > _stockImages

Detailed Description

Static Resource provider.

Maintains the static resource trees. Maintained trees are the level and the location ones.

Definition at line 49 of file staticprovider.h.


Member Enumeration Documentation

Enumerator:
kInventoryScrollUpArrow 
kInventoryScrollDownArrow 
kImages 
kActionMenuBg 
kTextScrollUpArrow 
kTextScrollDownArrow 
kQuit 
kCheckMark 
kVolume 
kDiaryNormal 
kInventory 
kExitArrow 
kExitArrowLeft 
kExitArrowRight 
kTextBackgroundActive 
kTextBackgroundPassive 
kDiaryTabbed 

Definition at line 53 of file staticprovider.h.

Enumerator:
kInventoryBg 
kDialogOptionBullet 

Definition at line 73 of file staticprovider.h.

Enumerator:
kInventoryNewItem 

Definition at line 78 of file staticprovider.h.


Constructor & Destructor Documentation

Stark::StaticProvider::StaticProvider ( ArchiveLoader archiveLoader  )  [explicit]

Definition at line 39 of file staticprovider.cpp.


Member Function Documentation

Common::String Stark::StaticProvider::buildLocationArchiveName ( const char *  locationName  )  const [private]

Definition at line 120 of file staticprovider.cpp.

VisualImageXMG * Stark::StaticProvider::getCursorImage ( uint32  cursor  )  const

Get an image for a static cursor.

Definition at line 81 of file staticprovider.cpp.

Resources::Level* Stark::StaticProvider::getLevel (  )  const [inline]

Obtain the static level.

Definition at line 92 of file staticprovider.h.

Resources::Location * Stark::StaticProvider::getLocation (  )  const

Obtain the currently loaded static location, if any.

Definition at line 160 of file staticprovider.cpp.

Resources::Sound * Stark::StaticProvider::getLocationSound ( uint16  index  )  const

Look up a sound resource in the current static location by its index.

Definition at line 164 of file staticprovider.cpp.

VisualImageXMG * Stark::StaticProvider::getUIElement ( UIElement  element  )  const

Get an image for a static UI element.

Definition at line 86 of file staticprovider.cpp.

VisualImageXMG * Stark::StaticProvider::getUIElement ( UIElement  element,
uint32  index 
) const

Definition at line 90 of file staticprovider.cpp.

VisualImageXMG * Stark::StaticProvider::getUIImage ( UIImage  image  )  const

Get an image for a static UI element.

Definition at line 101 of file staticprovider.cpp.

Resources::Sound * Stark::StaticProvider::getUISound ( UISound  sound  )  const

Get a static UI sound resource.

Definition at line 113 of file staticprovider.cpp.

void Stark::StaticProvider::goToAnimScriptStatement ( StaticProvider::UIElement  stockUIElement,
int  animScriptItemIndex 
)

Move execution of a static UI element anim script to the specified item.

Definition at line 106 of file staticprovider.cpp.

void Stark::StaticProvider::init (  ) 

Load the static level archive.

Definition at line 45 of file staticprovider.cpp.

bool Stark::StaticProvider::isStaticLocation (  )  const

Is a static location currently loaded?

Definition at line 156 of file staticprovider.cpp.

Resources::Location * Stark::StaticProvider::loadLocation ( const char *  locationName  ) 

Load a static location and set it as current.

Definition at line 124 of file staticprovider.cpp.

void Stark::StaticProvider::onGameLoop (  ) 

State update loop.

Definition at line 66 of file staticprovider.cpp.

void Stark::StaticProvider::shutdown (  ) 

Release the static resources.

Definition at line 70 of file staticprovider.cpp.

void Stark::StaticProvider::unloadLocation ( Resources::Location location  ) 

Unload the current static location.

Definition at line 144 of file staticprovider.cpp.


Member Data Documentation

Definition at line 128 of file staticprovider.h.


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


Generated on Sat May 18 2019 05:07:18 for ResidualVM by doxygen 1.7.1
curved edge   curved edge