diff --git a/dist/shattered_sword_assets/spritesheets/slice.png b/dist/shattered_sword_assets/spritesheets/slice.png index 5308b53..8c0e5ec 100644 Binary files a/dist/shattered_sword_assets/spritesheets/slice.png and b/dist/shattered_sword_assets/spritesheets/slice.png differ diff --git a/src/shattered_sword/GameSystems/items/WeaponTypes/Slice.ts b/src/shattered_sword/GameSystems/items/WeaponTypes/Slice.ts index 9e38bc3..bad952b 100644 --- a/src/shattered_sword/GameSystems/items/WeaponTypes/Slice.ts +++ b/src/shattered_sword/GameSystems/items/WeaponTypes/Slice.ts @@ -16,15 +16,19 @@ export default class Slice extends WeaponType { } doAnimation(attacker: GameNode, direction: Vec2, extraRange:number,sliceSprite: AnimatedSprite): void { + + // Rotate this with the game node + // TODO - need to rotate the anim properly + //sliceSprite.rotation = attacker.rotation; + //sliceSprite.rotation = (attacker).invertX? .5* Math.PI : 1.5 * Math.PI; + sliceSprite.invertX = (attacker).invertX; + //TODO- //4 to scale up the default sprite - may be different later depending on atk anim sliceSprite.scaleX = 2*(1+extraRange); //might have to add extra range to y as well sliceSprite.scaleY = 2; - // Rotate this with the game node - // TODO - need to rotate the anim properly - sliceSprite.rotation = attacker.rotation; - sliceSprite.rotation = (attacker).invertX? .5* Math.PI : 1.5 * Math.PI; + // Move the slice out from the player //scale = num of pixels between center of sprite and atk anim sliceSprite.position = attacker.position.clone().add(direction.scaled(32));