mirror of
https://github.com/MaddyThorson/StrawberryBF.git
synced 2026-11-09 18:15:14 +08:00
Sprite loading progress
This commit is contained in:
1 parent
a2f5f157fc
commit
6bfc6c7721
4 files changed
+38
-18
No files matched your search
@@ -36,5 +36,13 @@ namespace Strawberry
|
||||
SDL.SetRenderDrawColor(Game.Renderer, color.R, color.G, color.B, color.A);
|
||||
SDL.RenderDrawLine(Game.Renderer, (int32)fromn.X, (int32)fromn.Y, (int32)ton.X, (int32)ton.Y);
|
||||
}
|
||||
|
||||
static public void Sprite(Sprite sprite, int frame, Point position)
|
||||
{
|
||||
SDL.Rect src = Strawberry.Rect(0, 0, sprite.Width, sprite.Height);
|
||||
SDL.Rect dst = Strawberry.Rect(position.X, position.Y, sprite.Width, sprite.Height);
|
||||
|
||||
SDL.RenderCopy(Game.Renderer, sprite[frame].Texture, &src, &dst);
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user