mirror of
https://github.com/Such-Software/wownerogue.git
synced 2026-10-18 22:58:32 +02:00
fix(tavern): bigger cat + drop the green rug
- catSprites: scale the cat to ~2.7x its cell (the sprite is ~40% cat, 60% transparent padding) so it reads tile-sized instead of tiny. - tavernMap: remove the centre rug — tile 923 renders green, which looks wrong on the wood floor. (Re-add with a verified warm rug tile later.)
This commit is contained in:
@@ -28,10 +28,10 @@
|
||||
var frame = Math.floor((now || 0) / FRAME_MS) % FRAMES;
|
||||
var sx = frame * FW;
|
||||
// The cat occupies only ~40% of its 50x50 frame (lots of transparent padding), so scale
|
||||
// the frame to ~2x the cell and centre it — the visible cat then reads about tile-sized.
|
||||
var size = cell * 2.0;
|
||||
// the frame well past the cell and centre it — the visible cat then reads about tile-sized.
|
||||
var size = cell * 2.7;
|
||||
var dx = e.x * cell + (cell - size) / 2;
|
||||
var dy = e.y * cell + (cell - size) / 2 + cell * 0.2; // centred, nudged down onto the tile
|
||||
var dy = e.y * cell + (cell - size) / 2 + cell * 0.28; // centred, nudged down onto the tile
|
||||
ctx.save();
|
||||
ctx.imageSmoothingEnabled = false;
|
||||
if (e.facing === 'left') {
|
||||
|
||||
@@ -46,8 +46,7 @@ function buildDefaultTavern(cols = 28, rows = 15) {
|
||||
const tables = [[5, 6], [12, 6], [19, 6], [5, 10], [12, 10], [19, 10]];
|
||||
for (const [tx, ty] of tables) { put(tx, ty, 'T'); put(tx, ty + 1, 'c'); }
|
||||
|
||||
// A rug in the centre of the room.
|
||||
for (let y = 8; y <= 9; y++) for (let x = 11; x <= 15; x++) put(x, y, 'r');
|
||||
// (No rug for now — the rug tile renders green, which reads wrong on the wood floor.)
|
||||
|
||||
// Corner decor — barrels and crates.
|
||||
put(1, 1, 'B'); put(cols - 2, 1, 'C'); put(1, rows - 2, 'C'); put(cols - 2, rows - 2, 'B');
|
||||
|
||||
Reference in New Issue
Block a user