fix build
GitOrigin-RevId: 76185e284b5506cd191287b51908deae0f4a71cc
This commit is contained in:
parent
6bb646e2ce
commit
cb2f9687fa
@ -68,12 +68,11 @@ namespace Jumpy {
|
|||||||
if (frameNum == 3) {
|
if (frameNum == 3) {
|
||||||
frameNum = 1;
|
frameNum = 1;
|
||||||
}
|
}
|
||||||
int sourceX = spriteTileSize * frameNum + spriteTileSize * 3;
|
int sourceX = spriteSize * frameNum + spriteSize * 3;
|
||||||
int sourceY = spriteTileSize * 0;
|
int sourceY = spriteSize * 0;
|
||||||
Rectangle source = new Rectangle(sourceX, sourceY, 144, 144);
|
Rectangle source = new Rectangle(sourceX, sourceY, spriteSize, spriteSize);
|
||||||
// Vector2 position = new Vector2(0, 0);
|
|
||||||
Vector2 position = new Vector2(100, 100);
|
Vector2 position = new Vector2(100, 100);
|
||||||
Vector2 spriteCenter = new Vector2(144 / 2, 144 / 2);
|
Vector2 spriteCenter = new Vector2(spriteSize / 2, spriteSize / 2);
|
||||||
spriteBatch.Begin();
|
spriteBatch.Begin();
|
||||||
spriteBatch.Draw(playerTexture, position, source, Color.White, 0f, spriteCenter, Vector2.One, SpriteEffects.FlipHorizontally, 0f);
|
spriteBatch.Draw(playerTexture, position, source, Color.White, 0f, spriteCenter, Vector2.One, SpriteEffects.FlipHorizontally, 0f);
|
||||||
spriteBatch.End();
|
spriteBatch.End();
|
||||||
|
Loading…
Reference in New Issue
Block a user