decouple briefing from traitor (#19668)

Co-authored-by: deltanedas <@deltanedas:kde.org>
This commit is contained in:
deltanedas
2023-08-31 22:29:45 +01:00
committed by GitHub
parent 31282a3fc6
commit 7842f0d055
9 changed files with 70 additions and 14 deletions

View File

@@ -141,11 +141,14 @@ public sealed class CharacterUIController : UIController, IOnStateEntered<Gamepl
objectiveControl.AddChild(conditionControl);
}
_window.Objectives.AddChild(objectiveControl);
}
if (briefing != null)
{
var briefingControl = new ObjectiveBriefingControl();
briefingControl.Label.Text = briefing;
objectiveControl.AddChild(briefingControl);
_window.Objectives.AddChild(objectiveControl);
_window.Objectives.AddChild(briefingControl);
}
var controls = _characterInfo.GetCharacterInfoControls(entity);
@@ -154,7 +157,7 @@ public sealed class CharacterUIController : UIController, IOnStateEntered<Gamepl
_window.Objectives.AddChild(control);
}
_window.RolePlaceholder.Visible = !controls.Any() && !objectives.Any();
_window.RolePlaceholder.Visible = briefing == null && !controls.Any() && !objectives.Any();
}
private void CharacterDetached()