mirror of https://github.com/ppy/osu
Show smoke in replays
This commit is contained in:
parent
613564b5b9
commit
06178104c8
|
@ -31,6 +31,7 @@ public void FromLegacy(LegacyReplayFrame currentFrame, IBeatmap beatmap, ReplayF
|
|||
Position = currentFrame.Position;
|
||||
if (currentFrame.MouseLeft) Actions.Add(OsuAction.LeftButton);
|
||||
if (currentFrame.MouseRight) Actions.Add(OsuAction.RightButton);
|
||||
if (currentFrame.Smoke) Actions.Add(OsuAction.Smoke);
|
||||
}
|
||||
|
||||
public LegacyReplayFrame ToLegacy(IBeatmap beatmap)
|
||||
|
@ -41,6 +42,8 @@ public LegacyReplayFrame ToLegacy(IBeatmap beatmap)
|
|||
state |= ReplayButtonState.Left1;
|
||||
if (Actions.Contains(OsuAction.RightButton))
|
||||
state |= ReplayButtonState.Right1;
|
||||
if (Actions.Contains(OsuAction.Smoke))
|
||||
state |= ReplayButtonState.Smoke;
|
||||
|
||||
return new LegacyReplayFrame(Time, Position.X, Position.Y, state);
|
||||
}
|
||||
|
|
|
@ -46,6 +46,10 @@ public class LegacyReplayFrame : ReplayFrame
|
|||
[IgnoreMember]
|
||||
public bool MouseRight2 => ButtonState.HasFlagFast(ReplayButtonState.Right2);
|
||||
|
||||
[JsonIgnore]
|
||||
[IgnoreMember]
|
||||
public bool Smoke => ButtonState.HasFlagFast(ReplayButtonState.Smoke);
|
||||
|
||||
[Key(3)]
|
||||
public ReplayButtonState ButtonState;
|
||||
|
||||
|
|
Loading…
Reference in New Issue