mirror of
https://github.com/glest/glest-source.git
synced 2025-08-21 07:31:21 +02:00
- bugfix for scripted scenario function registerCellTriggerEventForUnitToLocation not working properly
This commit is contained in:
@@ -285,7 +285,7 @@ void ScriptManager::onCellTriggerEvent(Unit *movingUnit) {
|
||||
case ctet_UnitPos:
|
||||
{
|
||||
if(movingUnit->getId() == event.sourceId) {
|
||||
bool srcInDst = world->getMap()->isInUnitTypeCells(0, event.destPos,movingUnit->getPos());
|
||||
bool srcInDst = world->getMap()->isInUnitTypeCells(movingUnit->getType(), event.destPos,movingUnit->getPos());
|
||||
if(SystemFlags::getSystemSettingType(SystemFlags::debugLUA).enabled) SystemFlags::OutputDebug(SystemFlags::debugLUA,"In [%s::%s Line: %d] movingUnit = %d, event.type = %d, movingUnit->getPos() = %s, event.sourceId = %d, event.destId = %d, event.destPos = %s, srcInDst = %d\n",
|
||||
__FILE__,__FUNCTION__,__LINE__,movingUnit->getId(),event.type,movingUnit->getPos().getString().c_str(),event.sourceId,event.destId,event.destPos.getString().c_str(),srcInDst);
|
||||
|
||||
|
Reference in New Issue
Block a user