mirror of
https://github.com/kwsch/PKHeX
synced 2024-11-27 06:20:25 +00:00
Fix IsNew/IsFavorite flag clear
This commit is contained in:
parent
140196d9ab
commit
0ea152770a
1 changed files with 2 additions and 2 deletions
|
@ -24,8 +24,8 @@ public sealed record InventoryItem9 : InventoryItem, IItemFavorite, IItemNewFlag
|
|||
public uint Flags { get; set; }
|
||||
public uint Padding { get; set; }
|
||||
|
||||
public bool IsFavorite { get => (Flags & 0x2) != 0; set => Flags |= value ? 0x2u : 0x0u; }
|
||||
public bool IsNew { get => (Flags & 0x1) != 0; set => Flags |= value ? 0x1u : 0x0u; }
|
||||
public bool IsNew { get => (Flags & 0x1) != 0; set => Flags = (Flags & ~0x1u) | (value ? 0x1u : 0x0u); }
|
||||
public bool IsFavorite { get => (Flags & 0x2) != 0; set => Flags = (Flags & ~0x2u) | (value ? 0x2u : 0x0u); }
|
||||
|
||||
public override string ToString() => $"{Index:000} x{Count}{(IsNew ? "*" : "")}{(IsFavorite ? "F" : "")} - {Flags:X8}";
|
||||
|
||||
|
|
Loading…
Reference in a new issue