mirror of
https://github.com/krystalgamer/spidey-decomp.git
synced 2024-12-01 01:11:19 +00:00
Added info and CBody::InterleaveAI
This commit is contained in:
parent
91e3e5209f
commit
66329f9ab7
29
ob.cpp
29
ob.cpp
@ -67,11 +67,15 @@ void CItem::InitItem(const char * a1)
|
||||
|
||||
|
||||
|
||||
// @Ok
|
||||
// has weird xor eax, eax at the top
|
||||
int __inline CBody::IsDead(void) const{
|
||||
return (this->mCBodyFlags >> 6) & 1;
|
||||
}
|
||||
|
||||
|
||||
|
||||
// @Ok
|
||||
void CBody::Die(void){
|
||||
int isDead = this->IsDead();
|
||||
if(!isDead)
|
||||
@ -80,11 +84,14 @@ void CBody::Die(void){
|
||||
}
|
||||
}
|
||||
|
||||
// @Ok
|
||||
void CBody::ShadowOn(void){
|
||||
this->mCBodyFlags |= 8;
|
||||
}
|
||||
|
||||
|
||||
// @NotOk
|
||||
// dessutrctor
|
||||
void __inline CBody::KillShadow(void){
|
||||
|
||||
this->mCBodyFlags &= ~8u;
|
||||
@ -95,6 +102,8 @@ void __inline CBody::KillShadow(void){
|
||||
}
|
||||
}
|
||||
|
||||
// @NotOk
|
||||
// Inlined KillShadow and weird part where we store data but it's just xor eax, eax
|
||||
void CBody::UpdateShadow(void){
|
||||
|
||||
__int16 flags = this->mCBodyFlags;
|
||||
@ -153,6 +162,24 @@ void CBody::AttachTo(CBody** a1)
|
||||
|
||||
}
|
||||
|
||||
// @NotOk
|
||||
// missing vtable call
|
||||
void CBody::InterleaveAI(void)
|
||||
{
|
||||
if (this->mFlags & 2)
|
||||
{
|
||||
this->EveryFrame();
|
||||
CSuper *super = reinterpret_cast<CSuper*>(this);
|
||||
super->UpdateFrame();
|
||||
}
|
||||
else
|
||||
{
|
||||
this->EveryFrame();
|
||||
}
|
||||
|
||||
// vcall here
|
||||
}
|
||||
|
||||
|
||||
CSuper::CSuper(){
|
||||
this->gAnim = 1;
|
||||
@ -284,6 +311,8 @@ void CSuper::RunAnim(int, int, int){
|
||||
|
||||
static int * const gTimerRelated = (int*)0x006B4CA8;
|
||||
|
||||
// @NotOk
|
||||
// timerRelated needs to be fixed and call to print_if_false looks wrong
|
||||
void CBody::EveryFrame(void)
|
||||
{
|
||||
int v3; // edx
|
||||
|
Loading…
Reference in New Issue
Block a user