mirror of
https://github.com/isledecomp/isle.git
synced 2025-05-09 12:20:28 -04:00
Match MxDiskStreamController::FUN_100c7db0
(#1265)
* Match `MxDiskStreamController::FUN_100c7db0` * Modern compiler fix
This commit is contained in:
parent
1b99d75543
commit
5ffa91d5fd
3 changed files with 12 additions and 2 deletions
LEGO1/omni
|
@ -92,6 +92,9 @@ private:
|
|||
// List<MxDSBuffer *>::~List<MxDSBuffer *>
|
||||
|
||||
// TEMPLATE: LEGO1 0x100c7ef0
|
||||
// list<MxNextActionDataStart *>::insert
|
||||
// list<MxNextActionDataStart *,allocator<MxNextActionDataStart *> >::insert
|
||||
|
||||
// TEMPLATE: BETA10 0x10150e60
|
||||
// MxUtilityList<MxNextActionDataStart *>::PushBack
|
||||
|
||||
#endif // MXDISKSTREAMCONTROLLER_H
|
||||
|
|
|
@ -18,6 +18,9 @@ public:
|
|||
this->pop_front();
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
// Note: does not take a reference
|
||||
void PushBack(T p_obj) { this->push_back(p_obj); }
|
||||
};
|
||||
|
||||
#endif // MXUTILITYLIST_H
|
||||
|
|
|
@ -248,27 +248,31 @@ MxResult MxDiskStreamController::FUN_100c7d10()
|
|||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100c7db0
|
||||
// FUNCTION: BETA10 0x101551d0
|
||||
MxDSStreamingAction* MxDiskStreamController::FUN_100c7db0()
|
||||
{
|
||||
AUTOLOCK(m_criticalSection);
|
||||
|
||||
for (MxNextActionDataStartList::iterator it = m_nextActionList.begin(); it != m_nextActionList.end(); it++) {
|
||||
MxNextActionDataStart* data = *it;
|
||||
|
||||
for (MxDSObjectList::iterator it2 = m_list0x64.begin(); it2 != m_list0x64.end(); it2++) {
|
||||
MxDSStreamingAction* streamingAction = (MxDSStreamingAction*) *it2;
|
||||
|
||||
if (streamingAction->GetObjectId() == data->GetObjectId() &&
|
||||
streamingAction->GetUnknown24() == data->GetUnknown24() &&
|
||||
streamingAction->GetBufferOffset() == data->GetData()) {
|
||||
m_nextActionList.erase(it);
|
||||
|
||||
data->SetData(m_provider->GetFileSize() + data->GetData());
|
||||
m_nextActionList.push_back(data);
|
||||
m_nextActionList.PushBack(data);
|
||||
|
||||
m_list0x64.erase(it2);
|
||||
return streamingAction;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue