Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@
<td width="50%" valign="top">
<img src="docs/screenshots/animals.jpg" alt="A cow, pigs, a chicken and colourful sheep in a meadow, with love hearts above a pig">
<h3>🐷 Friendly animals</h3>
Pigs, cows, chickens and sheep in six wool colours. Pat them, feed them apples and they'll have <b>babies</b> that grow up. Shear sheep for coloured wool. Befriend a <b>dog or cat</b> as your named pet that follows you everywhere. Nothing can hurt you, and you can't hurt them.
Pigs, cows, chickens and sheep in six wool colours. Pat them, feed them apples and they'll have <b>babies</b> that grow up. Shear sheep for coloured wool. Befriend a <b>dog or cat</b> as your named pet that follows you everywhere, then upgrade it with <b>pet armor</b>, a <b>pet backpack</b> that carries 9 stacks for you, and a <b>pet bed or doghouse</b> to rest in. Animals can't be hurt by you, and pets never die: if night creatures bump them too much in Adventure, they just take a nap.
</td>
</tr>
<tr>
Expand Down Expand Up @@ -296,6 +296,7 @@ Inverters, delays and pistons point away from you when you place them (look down
- **Feed an apple** (right click): hearts appear, and two animals in love make a baby. Feeding babies helps them grow.
- **Shear sheep** (right click without an apple): 1–3 wool in the sheep's colour, which regrows after a minute.
- **Pets:** now and then a lone dog or cat appears. Feed it an apple and it becomes your pet with its own name tag and a red collar. It follows you and catches up if you go far. Right-click it to make it sit and stay, or follow again. Feed two pets for a puppy or kitten. Creative has dog and cat eggs.
- **Pet upgrades:** craft pet armor (Cozy Coat, Iron, Starlight: blocks 25%, 50% or 75% of bumps) and right-click your pet while holding it. Craft a Pet Backpack for 9 slots of storage; right-click a pet with gear to open its panel (works on touch too). Place a Pet Bed or Doghouse and tell a pet to sit nearby: it walks over and heals while it rests. Saved with your world; in Play Together friends see the gear and the backpack stays with the host.
- Animals you've fed, bred or spawned are saved with your world.

### Quests and stars
Expand Down
1 change: 1 addition & 0 deletions ROADMAP.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ Nurturing instead of fighting. This fits the kid-safe direction perfectly.
- a wooden coop makes chickens hatch from eggs
- [x] **Fireflies at night:** tap one to catch a glowing lantern block for your room.
- [x] **Pet accessories:** party hat, tiny crown, sunglasses (small box models on the head).
- [x] **Pet upgrades:** pet armor in 3 tiers, a 9-slot pet backpack with its own panel, Pet Bed and Doghouse blocks, pet hearts that heal while resting (`src/petui.js`, `src/mobs.js`).
- [x] Quests: *Rainbow Garden*, *Little Farmer*, *Baker*, *Flutter By*, *Ribbit!*, *Firefly Catcher*, *Party Time*.

**Watch out:** check habitats occasionally (for example when a chunk loads or every few seconds near the player), not every frame.
Expand Down
2 changes: 1 addition & 1 deletion features.html
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ <h3>📷 Photo Mode</h3>
<p>Snap your builds, then add a frame, a filter, stickers and a caption, and save or share the picture. Photos stay on your device.</p></article>
<article><img src="docs/screenshots/critters.jpg" alt="A cat called Luna wearing sunglasses and a dog called Toby in a party hat next to a firefly lantern and a frog" loading="lazy" width="800" height="450">
<h3>🐶 Friendly animals and pets</h3>
<p>Pat, feed and shear animals, watch babies grow, and tame a dog or cat as your pet. Pets get name tags and can wear party hats, crowns and sunglasses. Frogs, butterflies and fireflies appear around your builds.</p></article>
<p>Pat, feed and shear animals, watch babies grow, and tame a dog or cat as your pet. Pets get name tags and can wear party hats, crowns and sunglasses. Later on, give them pet armor in three tiers, a backpack that holds 9 stacks of your things, and a pet bed or doghouse where they rest and get better. Frogs, butterflies and fireflies appear around your builds.</p></article>
<article><img src="docs/screenshots/garden.jpg" alt="A flower garden next to rows of wheat growing from green to golden" loading="lazy" width="800" height="450">
<h3>🌾 Farming and gardens</h3>
<p>Plant flowers, water your garden, grow wheat and bake bread. A watering can makes things bloom.</p></article>
Expand Down
20 changes: 20 additions & 0 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -296,6 +296,26 @@ <h2>Crafting</h2>
<div id="cursor-stack" class="hidden"></div>
</div>

<div id="pet" class="overlay hidden">
<div class="panel pet-panel">
<h2 id="pet-title">Your pet</h2>
<p id="pet-hearts" class="pet-hearts"></p>
<div class="pet-armor"><span id="pet-armor-icon" class="slot"></span><span id="pet-armor-name"></span><button id="pet-armor-off" type="button" class="hidden">Take off</button></div>
<p class="note" id="pet-note"></p>
<div id="pet-bag-wrap">
<h3>Backpack</h3>
<div id="pet-bag" class="slot-grid"></div>
<button id="pet-bag-off" type="button">Take the backpack off</button>
</div>
<div id="pet-inv-wrap">
<h3>Your things</h3>
<div id="pet-backpack" class="slot-grid"></div>
<div id="pet-hotbar" class="slot-grid hotrow"></div>
</div>
<div class="pet-actions"><button id="pet-sit" type="button">Sit</button><button id="pet-done" class="primary done">Done</button></div>
</div>
</div>

<div id="worlds" class="overlay hidden">
<div class="panel wide">
<h2>🗂 My worlds</h2>
Expand Down
2 changes: 1 addition & 1 deletion llms.txt
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ Key facts:
- Learning: 64 quests (counting, times tables, colours, shapes, coding) and Blockly coding for Bit the robot.

## Features
- [All features, with screenshots and FAQ](features.html): Course Maker, Play Together, Bit coding, Photo Mode, animals and pets, farming, fun blocks, villages, quests, Spark circuits, power tools, Adventure mode, tablets and phones
- [All features, with screenshots and FAQ](features.html): Course Maker, Play Together, Bit coding, Photo Mode, animals and pets (armor, backpack, pet beds and doghouses), farming, fun blocks, villages, quests, Spark circuits, power tools, Adventure mode, tablets and phones
- [Play the game](./)

## Policies
Expand Down
6 changes: 6 additions & 0 deletions src/blocks.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ export const B = {
PISTON: 96, PISTON_OUT: 101, PISTON_HEAD: 106,
// Course Maker: build your own obstacle courses and races.
COURSE_START: 107, COURSE_CHECK: 108, COURSE_FINISH: 109, COIN: 110, COIN_TAKEN: 111,
// Pet upgrades: a cushion pets rest on and a doghouse.
PET_BED: 112, KENNEL: 113,
};

export const BLOCKS = [];
Expand Down Expand Up @@ -155,6 +157,10 @@ def(B.COURSE_CHECK, 'Checkpoint', { top: TILE.COURSE_CHECK, bottom: TILE.PAD_SID
def(B.COURSE_FINISH, 'Course Finish', { top: TILE.COURSE_FINISH, bottom: TILE.PAD_SIDE, side: TILE.PAD_SIDE }, { course: 'finish' });
def(B.COIN, 'Coin', TILE.COIN, { solid: false, transparent: true, shape: 'plant', emissive: true, course: 'coin' });
def(B.COIN_TAKEN, 'Coin (collected)', TILE.COIN_TAKEN, { solid: false, transparent: true, shape: 'plant', course: 'taken', placeable: false });
// ---- Pet beds ----
// Tell a pet to sit near one and it walks over; pets resting by a bed or kennel slowly get better.
def(B.PET_BED, 'Pet Bed', TILE.PET_BED, { ...flat, pet: 'bed' });
def(B.KENNEL, 'Doghouse', { top: TILE.KENNEL_TOP, bottom: TILE.PLANKS, side: TILE.KENNEL_SIDE }, { pet: 'kennel' });
/** Facing-aware block: turns a placed directional item into the variant facing `dir`. */
export function sparkFacing(id, dir) {
const b = BLOCKS[id];
Expand Down
1 change: 1 addition & 0 deletions src/ideas.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ export const IDEAS = [
'Build a garden with every colour of flower 🌷',
'Make a waterfall into a pool 💧',
'Build a tiny village for your pets 🐶',
'Build a cosy doghouse with a pet bed inside a fence 🏠',
'Make a racetrack with speed strips 🏁',
'Build a snowman on top of a mountain ⛄',
'Make a neon city that glows at night 🌃',
Expand Down
27 changes: 27 additions & 0 deletions src/items.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ export const I = {
PARTY_HAT: 330, CROWN: 331, SUNGLASSES: 332,
WOOD_SWORD: 340, STONE_SWORD: 341, IRON_SWORD: 342, DIAMOND_SWORD: 343,
BOW: 344, ARROW: 345, SHIELD: 346, WOOL_ARMOR: 347, IRON_ARMOR: 348, DIAMOND_ARMOR: 349,
COZY_PET_COAT: 360, IRON_PET_ARMOR: 361, STAR_PET_ARMOR: 362, PET_BACKPACK: 363,
};

const TIERS = [
Expand Down Expand Up @@ -76,6 +77,14 @@ item(I.PARTY_HAT, 'Party Hat', { sprite: 'partyhat', color: [240, 80, 160], stac
item(I.CROWN, 'Tiny Crown', { sprite: 'crown', color: [250, 210, 60], stack: 16, accessory: 'crown' });
item(I.SUNGLASSES, 'Sunglasses', { sprite: 'glasses', color: [30, 30, 40], stack: 16, accessory: 'glasses' });

// Pet armor (right-click your pet while holding it) cuts the damage the pet takes; the backpack gives it 9 slots.
// `petArmor` is the share of damage blocked.
item(I.COZY_PET_COAT, 'Cozy Pet Coat', { sprite: 'petarmor', color: [120, 170, 235], stack: 1, petArmor: 0.25 });
item(I.IRON_PET_ARMOR, 'Iron Pet Armor', { sprite: 'petarmor', color: [205, 208, 215], stack: 1, petArmor: 0.5 });
item(I.STAR_PET_ARMOR, 'Starlight Pet Armor', { sprite: 'petarmor', color: [250, 205, 70], stack: 1, petArmor: 0.75 });
item(I.PET_BACKPACK, 'Pet Backpack', { sprite: 'backpack', color: [200, 80, 70], stack: 1, petBackpack: true });
export const PET_BAG_SLOTS = 9;

// Creative power tools. Shape tools: right-click two points to build, left-click two points to erase.
// They build with the last block you held.
item(I.LINE_WAND, 'Bridge Wand', { sprite: 'wand', color: [255, 220, 90], stack: 1, creativeOnly: true, shape: 'line' });
Expand Down Expand Up @@ -124,6 +133,8 @@ mine([B.LANTERN], 0.3);
mine([B.PORTAL_BLUE, B.PORTAL_ORANGE, B.PORTAL_GREEN, B.PORTAL_PURPLE], 0.4);
mine([B.CACTUS], 0.4);
mine(BLOCKS.filter((b) => b?.spark).map((b) => b.id), 0.3);
mine([B.PET_BED], 0.3);
mine([B.KENNEL], 1.5, 'axe');
mine(BLOCKS.filter((b) => b?.course).map((b) => b.id), 0.3);
mine([B.WOOL_WHITE, B.WOOL_RED, B.WOOL_BLUE, B.WOOL_YELLOW, B.WOOL_GREEN, B.WOOL_BLACK], 0.8);

Expand Down Expand Up @@ -173,6 +184,12 @@ recipe(B.CRAFTING_TABLE, 1, [[B.PLANKS, 4]]);
recipe(I.BREAD, 1, [[I.WHEAT, 3]]);
recipe(I.HOE, 1, [[B.PLANKS, 2], [I.STICK, 2]]);
recipe(I.PARTY_HAT, 1, [[B.WOOL_RED, 1], [B.WOOL_YELLOW, 1]]);
recipe(I.COZY_PET_COAT, 1, [[B.WOOL_BLUE, 3], [B.WOOL_WHITE, 2]]);
recipe(I.IRON_PET_ARMOR, 1, [[I.IRON_INGOT, 5]], 'table');
recipe(I.STAR_PET_ARMOR, 1, [[I.DIAMOND, 2], [I.GOLD_INGOT, 3], [B.STAR, 1]], 'table');
recipe(I.PET_BACKPACK, 1, [[B.WOOL_RED, 3], [I.IRON_INGOT, 1], [I.STICK, 2]], 'table');
recipe(B.PET_BED, 1, [[B.WOOL_RED, 2], [B.PLANKS, 2]]);
recipe(B.KENNEL, 1, [[B.PLANKS, 6], [B.WOOL_RED, 1]], 'table');
recipe(I.CROWN, 1, [[I.GOLD_INGOT, 2]], 'table');
recipe(B.STAR, 1, [[I.GOLD_INGOT, 1], [B.GLASS, 1]], 'table');
recipe(I.WOOD_SWORD, 1, [[B.PLANKS, 2], [I.STICK, 1]], 'table');
Expand Down Expand Up @@ -315,6 +332,16 @@ const SPRITES = {
'....########....', '....##dddd##....', '....########....', '....########....', '....########....', '....########....',
'.....######.....', '................', '................', '................',
],
petarmor: [
'................', '................', '...#########....', '..###########...', '.####dddddd####.', '.###d######d###.',
'.###d#yyyy#d###.', '.###d######d###.', '..##dddddddd##..', '..###########...', '...##.#####.##..', '...##.......##..',
'................', '................', '................', '................',
],
backpack: [
'................', '.....dddddd.....', '....d######d....', '...d########d...', '...##########...', '...#dddddddd#...',
'...#d######d#...', '...#d#yyyy#d#...', '...#d######d#...', '...#dddddddd#...', '...##########...', '...d########d...',
'....dddddddd....', '................', '................', '................',
],
partyhat: [
'.......dd.......', '.......##.......', '......####......', '......#dd#......', '.....######.....', '.....##dd##.....',
'....########....', '....###dd###....', '...##########...', '...####dd####...', '..############..', '................',
Expand Down
Loading
Loading