summaryrefslogtreecommitdiff
path: root/Mouse.cs
diff options
context:
space:
mode:
authorSarah Duck <git@sarahduck.ca>2025-06-16 22:10:06 -0700
committerSarah Duck <git@sarahduck.ca>2025-06-16 22:10:06 -0700
commit48deeeabfd86cfc5b993936760e1332308a47ab2 (patch)
treea2dd297bb356cad7792fe0f75de52f47685ee03f /Mouse.cs
parentc5b8b31dc7f29fd5512ac482cdffa2d274e6e01b (diff)
Optimizations, and Transparent Window!
Diffstat (limited to 'Mouse.cs')
-rw-r--r--Mouse.cs4
1 files changed, 2 insertions, 2 deletions
diff --git a/Mouse.cs b/Mouse.cs
index fdf0c5c..67356ce 100644
--- a/Mouse.cs
+++ b/Mouse.cs
@@ -15,7 +15,7 @@ abstract class Mouse : Drawable
public static Action<Mouse>? Clicked;
- protected readonly static byte[] FallbackImg = EmbeddedResources.GetResource("misc.cursor.png");
+ protected readonly static Image FallbackImg = Raylib.LoadImageFromMemory(".png", EmbeddedResources.GetResource("misc.cursor.png"));
public Mouse() : base()
{
@@ -28,7 +28,7 @@ abstract class Mouse : Drawable
Cursor = Bitmap.FromPNGMemory(File.ReadAllBytes(CursorPath), 32, 32);
} else {
Console.WriteLine("The cursor PNG was either mising or too big. Using the default.");
- Cursor = Bitmap.FromPNGMemory(FallbackImg);
+ Cursor = new Bitmap(Raylib.ImageCopy(FallbackImg), 32, 32);
}
}