mirror of
https://github.com/openmoh/openmohaa.git
synced 2025-04-28 21:57:57 +03:00
Fixed code_pos being wrong after loadTop/storeTop
This commit is contained in:
parent
4263b2843a
commit
51116b933d
1 changed files with 2 additions and 4 deletions
|
@ -399,9 +399,8 @@ void ScriptVM::jumpBool(int offset, bool booleanValue)
|
|||
void ScriptVM::loadTopInternal(Listener* listener)
|
||||
{
|
||||
const const_str variable = fetchOpcodeValue<op_name_t>();
|
||||
const op_evName_t eventName = fetchOpcodeValue<op_evName_t>();
|
||||
|
||||
if (!eventName || !executeSetter(listener, eventName))
|
||||
if (!executeSetter(listener, variable))
|
||||
{
|
||||
// just set the variable
|
||||
const uintptr_t varIndex = m_VMStack.GetIndex();
|
||||
|
@ -426,10 +425,9 @@ void ScriptVM::loadTopInternal(Listener* listener)
|
|||
ScriptVariable* ScriptVM::storeTopInternal(Listener* listener)
|
||||
{
|
||||
const const_str variable = fetchOpcodeValue<op_name_t>();
|
||||
const op_evName_t eventName = fetchOpcodeValue<op_evName_t>();
|
||||
ScriptVariable* listenerVar;
|
||||
|
||||
if (!eventName || !executeGetter(listener, eventName))
|
||||
if (!executeGetter(listener, variable))
|
||||
{
|
||||
const uintptr_t varIndex = m_VMStack.GetIndex();
|
||||
ScriptVariable& pTop = m_VMStack.GetTop();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue