* start pizza

* Add some pizza vtable functions (they are stubs at the moment)

Unknown parameter types, likely either Pizzeria or PizzaMissionState.

* Pizza: Add/update functions as according to MxCore inheritance

IsleActor::Notify needs to be stubbed
---------

Co-authored-by: Kai Kaufman <ktkaufman@wpi.edu>

* match pizza destructor

* Update pizza members

* add size asserts

---------

Co-authored-by: Kai Kaufman <ktkaufman@wpi.edu>
Co-authored-by: itsmattkc <34096995+itsmattkc@users.noreply.github.com>
This commit is contained in:
Joshua Peisach 2023-08-03 12:54:08 -04:00 committed by GitHub
parent fa5417f58a
commit ac89815663
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 61 additions and 4 deletions

View file

@ -46,6 +46,7 @@ add_library(lego1 SHARED
LEGO1/jukeboxstate.cpp
LEGO1/legoact2state.cpp
LEGO1/legoactioncontrolpresenter.cpp
LEGO1/legoactor.cpp
LEGO1/legoanimactor.cpp
LEGO1/legoanimationmanager.cpp
LEGO1/legoanimmmpresenter.cpp

View file

@ -1 +1,4 @@
#include "isleactor.h"
// NOTE: This is copied from base class LegoActor. IsleActor may in fact be larger but we don't know yet.
DECOMP_SIZE_ASSERT(IsleActor, 0x78)

3
LEGO1/legoactor.cpp Normal file
View file

@ -0,0 +1,3 @@
#include "legoactor.h"
DECOMP_SIZE_ASSERT(LegoActor, 0x78)

View file

@ -1,6 +1,7 @@
#ifndef LEGOACTOR_H
#define LEGOACTOR_H
#include "decomp.h"
#include "legoentity.h"
// VTABLE 0x100d6d68
@ -20,6 +21,10 @@ class LegoActor : public LegoEntity
{
return !strcmp(name, LegoActor::ClassName()) || LegoEntity::IsA(name);
}
private:
undefined unk04_[0x68];
};
#endif // LEGOACTOR_H

View file

@ -1,13 +1,30 @@
#include "pizza.h"
// OFFSET: LEGO1 0x10037ef0 STUB
#include "decomp.h"
DECOMP_SIZE_ASSERT(Pizza, 0x9c);
// OFFSET: LEGO1 0x10037ef0
Pizza::Pizza()
{
// TODO
// FIXME: This inherits from LegoActor, probably why this isn't matching
this->m_unk80 = 0;
this->m_unk84 = 0;
this->m_unk88 = 0;
this->m_unk8c = -1;
this->m_unk98 = 0;
this->m_unk90 = 0x80000000;
}
// OFFSET: LEGO1 0x10038100 STUB
// OFFSET: LEGO1 0x10038100
Pizza::~Pizza()
{
// TODO
TickleManager()->Unregister(this);
}
// OFFSET: LEGO1 0x100388a0
MxResult Pizza::Tickle()
{
// TODO
return SUCCESS;
}

View file

@ -2,6 +2,10 @@
#define PIZZA_H
#include "isleactor.h"
#include "mxcore.h"
#include "mxomni.h"
#include "mxticklemanager.h"
#include "mxtypes.h"
// VTABLE 0x100d7380
// SIZE 0x9c
@ -11,6 +15,30 @@ class Pizza : public IsleActor
Pizza();
virtual ~Pizza() override;
virtual MxResult Tickle() override; // vtable+08
// OFFSET: LEGO1 0x10037f90
inline const char *ClassName() const //vtable+0c
{
// 0x100f038c
return "Pizza";
}
// OFFSET: LEGO1 0x10037fa0
inline MxBool Pizza::IsA(const char *name) const override //vtable+10
{
return !strcmp(name, Pizza::ClassName()) || IsleActor::IsA(name);
}
private:
MxS32 m_unk78;
MxS32 m_unk7c;
MxS32 m_unk80;
MxS32 m_unk84;
MxS32 m_unk88;
MxS32 m_unk8c;
MxU32 m_unk90;
MxS32 m_unk94;
MxS32 m_unk98;
};
#endif // PIZZA_H