aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEugene Sandulenko2011-06-25 14:50:07 +0300
committerEugene Sandulenko2011-06-25 14:50:07 +0300
commit73d2d34e01fb929d5ed9af08646c9474ec5150ed (patch)
treee3ec1490ba868093468043789695813da0b883e3
parent7f5cd1ac82cb8dc8e7ceb426826b4a5367a27b49 (diff)
downloadscummvm-rg350-73d2d34e01fb929d5ed9af08646c9474ec5150ed.tar.gz
scummvm-rg350-73d2d34e01fb929d5ed9af08646c9474ec5150ed.tar.bz2
scummvm-rg350-73d2d34e01fb929d5ed9af08646c9474ec5150ed.zip
LASTEXPRESS: Give proper name to another sound struct member
-rw-r--r--engines/lastexpress/game/sound.cpp14
-rw-r--r--engines/lastexpress/game/sound.h2
-rw-r--r--engines/lastexpress/sound/entry.cpp2
-rw-r--r--engines/lastexpress/sound/entry.h2
4 files changed, 10 insertions, 10 deletions
diff --git a/engines/lastexpress/game/sound.cpp b/engines/lastexpress/game/sound.cpp
index adb82816f5..c95ef85701 100644
--- a/engines/lastexpress/game/sound.cpp
+++ b/engines/lastexpress/game/sound.cpp
@@ -255,11 +255,11 @@ bool SoundManager::isBuffered(Common::String filename, bool testForEntity) {
//////////////////////////////////////////////////////////////////////////
// Entry
//////////////////////////////////////////////////////////////////////////
-void SoundManager::setupEntry(SoundEntry *entry, Common::String name, SoundFlag flag, int a4) {
+void SoundManager::setupEntry(SoundEntry *entry, Common::String name, SoundFlag flag, int priority) {
if (!entry)
error("SoundManager::setupEntry: Invalid entry!");
- entry->field_4C = a4;
+ entry->priority = priority;
setEntryType(entry, flag);
entry->setStatus(flag);
@@ -354,7 +354,7 @@ bool SoundManager::setupCache(SoundEntry *entry) {
for (Common::List<SoundEntry *>::iterator i = _soundCache.begin(); i != _soundCache.end(); ++i) {
if (!((*i)->status.status & kSoundStatus_180)) {
- uint32 newSize = (*i)->field_4C + ((*i)->status.status & kSoundStatusClear1);
+ uint32 newSize = (*i)->priority + ((*i)->status.status & kSoundStatusClear1);
if (newSize < size) {
cacheEntry = (*i);
@@ -363,7 +363,7 @@ bool SoundManager::setupCache(SoundEntry *entry) {
}
}
- if (entry->field_4C <= size)
+ if (entry->priority <= size)
return false;
if (!cacheEntry)
@@ -574,7 +574,7 @@ void SoundManager::saveLoadWithSerializer(Common::Serializer &s) {
blockCount = 0;
s.syncAsUint32LE(blockCount); // blockCount;
- s.syncAsUint32LE(entry->field_4C); // field_20;
+ s.syncAsUint32LE(entry->priority); // field_20;
char name1[16];
strcpy((char *)&name1, entry->name1.c_str());
@@ -1769,10 +1769,10 @@ void SoundManager::updateSubtitles() {
|| status & 0x180
|| soundEntry->time == 0
|| (status & 0x1F) < 6
- || ((getFlags()->nis & 0x8000) && soundEntry->field_4C < 90)) {
+ || ((getFlags()->nis & 0x8000) && soundEntry->priority < 90)) {
current_index = 0;
} else {
- current_index = soundEntry->field_4C + (status & 0x1F);
+ current_index = soundEntry->priority + (status & 0x1F);
if (_currentSubtitle == (*i))
current_index += 4;
diff --git a/engines/lastexpress/game/sound.h b/engines/lastexpress/game/sound.h
index b2a1b4387b..e7b06609a9 100644
--- a/engines/lastexpress/game/sound.h
+++ b/engines/lastexpress/game/sound.h
@@ -161,7 +161,7 @@ private:
SoundEntry *getEntry(Common::String name);
SoundEntry *getEntry(SoundType type);
- void setupEntry(SoundEntry *entry, Common::String name, SoundFlag flag, int a4);
+ void setupEntry(SoundEntry *entry, Common::String name, SoundFlag flag, int priority);
void setEntryType(SoundEntry *entry, SoundFlag flag);
bool setupCache(SoundEntry *entry);
void removeFromCache(SoundEntry *entry);
diff --git a/engines/lastexpress/sound/entry.cpp b/engines/lastexpress/sound/entry.cpp
index 848e728ba4..67549cb5fe 100644
--- a/engines/lastexpress/sound/entry.cpp
+++ b/engines/lastexpress/sound/entry.cpp
@@ -53,7 +53,7 @@ SoundEntry::SoundEntry(LastExpressEngine *engine) : _engine(engine) {
field_40 = 0;
entity = kEntityPlayer;
field_48 = 0;
- field_4C = 0;
+ priority = 0;
subtitle = NULL;
diff --git a/engines/lastexpress/sound/entry.h b/engines/lastexpress/sound/entry.h
index 5671e0e74b..84a2342cf3 100644
--- a/engines/lastexpress/sound/entry.h
+++ b/engines/lastexpress/sound/entry.h
@@ -146,7 +146,7 @@ public:
int field_40;
EntityIndex entity;
int field_48;
- uint32 field_4C;
+ uint32 priority;
Common::String name1; //char[16];
Common::String name2; //char[16];
//int next; // offset to the next structure in the list (not used)