Core/Conditions: Added CONDITION_SCENE_IN_PROGRESS, useful for cases where you need phase things when a scene is in progress.
Port From (https://github.com/TrinityCore/TrinityCore/commit/bd401af0912eca2c938b6dd93fdb7689b9146c89)
This commit is contained in:
@@ -411,6 +411,12 @@ namespace Game.Conditions
|
||||
}
|
||||
break;
|
||||
}
|
||||
case ConditionTypes.SceneInProgress:
|
||||
{
|
||||
if (player != null)
|
||||
condMeets = player.GetSceneMgr().GetActiveSceneCount(ConditionValue1) > 0;
|
||||
break;
|
||||
}
|
||||
default:
|
||||
condMeets = false;
|
||||
break;
|
||||
@@ -527,6 +533,9 @@ namespace Game.Conditions
|
||||
case ConditionTypes.ScenarioStep:
|
||||
mask |= GridMapTypeMask.All;
|
||||
break;
|
||||
case ConditionTypes.SceneInProgress:
|
||||
mask |= GridMapTypeMask.Player;
|
||||
break;
|
||||
default:
|
||||
Cypher.Assert(false, "Condition.GetSearcherTypeMaskForCondition - missing condition handling!");
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user