1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-18 00:12:54 +08:00
osu-lazer/osu.Game/GameModes/Backgrounds/BackgroundModeCustom.cs
2016-10-12 15:47:08 +09:00

29 lines
838 B
C#

//Copyright (c) 2007-2016 ppy Pty Ltd <contact@ppy.sh>.
//Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
using osu.Framework;
using osu.Game.Graphics.Background;
namespace osu.Game.GameModes.Backgrounds
{
public class BackgroundModeCustom : BackgroundMode
{
private readonly string textureName;
public BackgroundModeCustom(string textureName)
{
this.textureName = textureName;
}
public override void Load(BaseGame game)
{
base.Load(game);
Add(new Background(textureName));
}
public override bool Equals(BackgroundMode other)
{
return base.Equals(other) && textureName == ((BackgroundModeCustom)other).textureName;
}
}
}