Match and relocate FUN_10006030

This commit is contained in:
Christian Semmler 2023-10-17 18:02:04 -04:00
parent 056c48eb41
commit 36281fd10f
2 changed files with 13 additions and 12 deletions

View File

@ -25,3 +25,16 @@ MxResult LegoState::VTable0x1C(LegoFileStream *p_legoFileStream)
}
return SUCCESS;
}
// OFFSET: LEGO1 0x10006030
LegoFileStream *LegoFileStream::FUN_10006030(MxString p_str)
{
const char *data = p_str.GetData();
MxU32 fullLength = strlen(data);
MxU16 limitedLength = fullLength;
Write(&limitedLength, sizeof(limitedLength));
Write(data, (MxS16) fullLength);
return this;
}

View File

@ -116,18 +116,6 @@ MxResult LegoFileStream::Open(const char* p_filename, OpenFlags p_mode)
return (m_hFile = fopen(p_filename, modeString)) ? SUCCESS : FAILURE;
}
// OFFSET: LEGO1 0x10006030
LegoFileStream *LegoFileStream::FUN_10006030(MxString p_str)
{
MxS16 strLength = strlen(p_str.GetData());
const char *strData = p_str.GetData();
Write(&strLength, sizeof(strLength));
Write(strData, strLength);
return this;
}
// OFFSET: LEGO1 0x10099080
LegoMemoryStream::LegoMemoryStream(char* p_buffer)
: LegoStream()