-
-
Notifications
You must be signed in to change notification settings - Fork 20
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #483 from LumpBloom7/Ex-modifier
Implement EX notes
- Loading branch information
Showing
20 changed files
with
229 additions
and
68 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
using System; | ||
using osu.Framework.Localisation; | ||
using osu.Game.Beatmaps; | ||
using osu.Game.Rulesets.Mods; | ||
using osu.Game.Rulesets.Sentakki.Objects; | ||
|
||
namespace osu.Game.Rulesets.Sentakki.Mods | ||
{ | ||
public class SentakkiModRelax : Mod, IApplicableAfterBeatmapConversion | ||
{ | ||
public override Type[] IncompatibleMods => new[] | ||
{ | ||
typeof(ModAutoplay), | ||
}; | ||
|
||
public override string Name => "Relax"; | ||
|
||
public override string Acronym => "RX"; | ||
|
||
public override LocalisableString Description => "All notes are EX notes, you've got nothing to prove!"; | ||
|
||
public override double ScoreMultiplier => 0.3; | ||
|
||
public void ApplyToBeatmap(IBeatmap beatmap) | ||
{ | ||
foreach (SentakkiHitObject ho in beatmap.HitObjects) | ||
ho.Ex = true; | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
53 changes: 44 additions & 9 deletions
53
osu.Game.Rulesets.Sentakki/Objects/Drawables/Pieces/ShadowPiece.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
35 changes: 29 additions & 6 deletions
35
osu.Game.Rulesets.Sentakki/Objects/Drawables/Pieces/Slides/StarPiece.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,28 +1,51 @@ | ||
using osu.Framework.Allocation; | ||
using osu.Framework.Bindables; | ||
using osu.Framework.Graphics; | ||
using osu.Framework.Graphics.Containers; | ||
using osu.Framework.Graphics.Sprites; | ||
using osu.Framework.Graphics.Textures; | ||
using osu.Game.Rulesets.Objects.Drawables; | ||
using osuTK.Graphics; | ||
|
||
namespace osu.Game.Rulesets.Sentakki.Objects.Drawables.Pieces.Slides | ||
{ | ||
public partial class StarPiece : CompositeDrawable | ||
{ | ||
private Sprite glowTexture = null!; | ||
|
||
private Bindable<bool> ExBindable = new Bindable<bool>(); | ||
|
||
public StarPiece() | ||
{ | ||
Anchor = Anchor.Centre; | ||
Origin = Anchor.Centre; | ||
} | ||
|
||
[BackgroundDependencyLoader] | ||
private void load(TextureStore textures) | ||
private void load(TextureStore textures, DrawableHitObject? hitObject) | ||
{ | ||
AddInternal(new Sprite | ||
{ | ||
Anchor = Anchor.Centre, | ||
Origin = Anchor.Centre, | ||
Texture = textures.Get("star"), | ||
AddRangeInternal(new Drawable[]{ | ||
glowTexture = new Sprite | ||
{ | ||
Anchor = Anchor.Centre, | ||
Origin = Anchor.Centre, | ||
Texture = textures.Get("starGlow"), | ||
Colour = Color4.Black | ||
}, | ||
new Sprite | ||
{ | ||
Anchor = Anchor.Centre, | ||
Origin = Anchor.Centre, | ||
Texture = textures.Get("star"), | ||
} | ||
}); | ||
|
||
if (hitObject is null) | ||
return; | ||
|
||
// Bind exnote | ||
ExBindable.BindTo(((DrawableSentakkiHitObject)hitObject).ExBindable); | ||
ExBindable.BindValueChanged(v => glowTexture.Colour = v.NewValue ? Color4.White : Color4.Black, true); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.