Fix owner of selected actor not always being selected owner in editor
This commit is contained in:
committed by
Matthias Mailänder
parent
0898655175
commit
442752b6ba
@@ -156,6 +156,14 @@ namespace OpenRA.Mods.Common.Widgets.Logic
|
|||||||
ownersDropDown.Text = option.Name;
|
ownersDropDown.Text = option.Name;
|
||||||
ownersDropDown.TextColor = option.Color;
|
ownersDropDown.TextColor = option.Color;
|
||||||
InitializePreviews();
|
InitializePreviews();
|
||||||
|
|
||||||
|
var actor = editorCursor.Actor;
|
||||||
|
if (actor != null)
|
||||||
|
{
|
||||||
|
actor.Owner = option;
|
||||||
|
actor.ReplaceInit(new OwnerInit(option.Name));
|
||||||
|
actor.ReplaceInit(new FactionInit(option.Faction));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
protected override void InitializePreviews()
|
protected override void InitializePreviews()
|
||||||
|
|||||||
Reference in New Issue
Block a user