MxStream provider and controller vtables (#191)

* MxStreamProvider and MxRamStreamProvider vtable

* Update mxramstreamprovider.h

* Match IsA

* Fixes, improvements

---------

Co-authored-by: Christian Semmler <mail@csemmler.com>
This commit is contained in:
Misha
2023-10-08 16:41:34 -04:00
committed by GitHub
parent 3ac0c5d86c
commit d82649c6f0
11 changed files with 181 additions and 12 deletions

View File

@@ -1,17 +1,16 @@
#ifndef MXSTREAMPROVIDER_H
#define MXSTREAMPROVIDER_H
#include "decomp.h"
#include "mxcore.h"
#include "mxdsfile.h"
// VTABLE 0x100dd100
// SIZE 0x10
class MxStreamProvider : public MxCore
{
public:
inline MxStreamProvider() {
this->m_pLookup = NULL;
this->m_pFile = NULL;
}
inline MxStreamProvider() : m_pLookup(NULL), m_pFile(NULL) {}
// OFFSET: LEGO1 0x100d07e0
inline virtual const char *ClassName() const override // vtable+0x0c
@@ -25,6 +24,13 @@ public:
return !strcmp(name, MxStreamProvider::ClassName()) || MxCore::IsA(name);
}
virtual MxResult SetResourceToGet(void* p_resource); //vtable+0x14
virtual MxU32 GetFileSize() = 0; //vtable+0x18
virtual MxU32 vtable0x1C() = 0; //vtable+0x1c
virtual void vtable0x20(undefined4 p_unknown1); //vtable+0x20
virtual MxU32 GetLengthInDWords() = 0; //vtable+0x24
virtual void* GetBufferForDWords() = 0; //vtable+0x28
protected:
void *m_pLookup;
MxDSFile* m_pFile;