Skip to content

Commit a10bec2

Browse files
committed
fix: fix onCmdBlockExecute
1 parent 89952a9 commit a10bec2

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/lse/events/EventHooks.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -687,7 +687,7 @@ LL_TYPE_INSTANCE_HOOK(
687687
CallEventRtnValue(EVENT_TYPES::onOpenContainerScreen, false, PlayerClass::newPlayer(this));
688688
}
689689
IF_LISTENED_END(EVENT_TYPES::onOpenContainerScreen);
690-
return origin();
690+
return origin();
691691
}
692692

693693
LL_TYPE_INSTANCE_HOOK(
@@ -706,15 +706,15 @@ LL_TYPE_INSTANCE_HOOK(
706706
EVENT_TYPES::onCmdBlockExecute,
707707
false,
708708
String::newString(this->getCommand()),
709-
FloatPos::newPos(commandOrigin.getEntity()->getPosition(), commandOrigin.getEntity()->getDimensionId()),
709+
FloatPos::newPos(commandOrigin.getEntity()->getPosition(), region.getDimensionId()),
710710
Boolean::newBoolean(true)
711711
);
712712
} else {
713713
CallEventRtnValue(
714714
EVENT_TYPES::onCmdBlockExecute,
715715
false,
716716
String::newString(this->getCommand()),
717-
FloatPos::newPos(commandOrigin.getEntity()->getPosition(), commandOrigin.getEntity()->getDimensionId()),
717+
FloatPos::newPos(commandOrigin.getBlockPosition(), region.getDimensionId()),
718718
Boolean::newBoolean(false)
719719
);
720720
}

0 commit comments

Comments
 (0)