fix: use effective layout everywhere
This commit is contained in:
parent
cb1faf1167
commit
b8c99f1839
|
@ -106,7 +106,7 @@ namespace HUD_Manager {
|
||||||
return Marshal.PtrToStructure<Layout>(slotPtr);
|
return Marshal.PtrToStructure<Layout>(slotPtr);
|
||||||
}
|
}
|
||||||
|
|
||||||
public void WriteLayout(HudSlot slot, Layout layout) {
|
private void WriteLayout(HudSlot slot, Layout layout) {
|
||||||
var slotPtr = this.GetLayoutPointer(slot);
|
var slotPtr = this.GetLayoutPointer(slot);
|
||||||
|
|
||||||
var dict = layout.ToDictionary();
|
var dict = layout.ToDictionary();
|
||||||
|
|
|
@ -78,9 +78,7 @@ namespace HUD_Manager {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
var layout = entry.Value;
|
this.Hud.WriteEffectiveLayout(this.Config.StagingSlot, entry.Key);
|
||||||
|
|
||||||
this.Hud.WriteLayout(this.Config.StagingSlot, layout.ToLayout());
|
|
||||||
this.Hud.SelectSlot(this.Config.StagingSlot, true);
|
this.Hud.SelectSlot(this.Config.StagingSlot, true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -405,7 +405,7 @@ namespace HUD_Manager {
|
||||||
}
|
}
|
||||||
|
|
||||||
if (update) {
|
if (update) {
|
||||||
this.Plugin.Hud.WriteLayout(this.Plugin.Config.StagingSlot, layout.ToLayout());
|
this.Plugin.Hud.WriteEffectiveLayout(this.Plugin.Config.StagingSlot, this._selectedEditLayout);
|
||||||
this.Plugin.Hud.SelectSlot(this.Plugin.Config.StagingSlot, true);
|
this.Plugin.Hud.SelectSlot(this.Plugin.Config.StagingSlot, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue