Skip to main content

VIVIA โ€” Gameplay Systems

Everything on this page is verified against the code (Core/Src/gameplay.rs).

Survival Statsโ€‹

StatBehaviour
Healthdamage from combat, starvation and dehydration; death at 0
Hungerdecays over time; eating (eat) restores it; empty โ†’ starvation damage
Thirstdecays over time; drinking (drink) restores it; empty โ†’ dehydration damage

Regeneration (heal) works when you keep hunger and thirst topped up โ€” starve or dehydrate and attrition takes over. All rules live in PlayerStats::tick, covered by unit tests.

Day/Night Cycleโ€‹

GameClock drives a real day/night cycle: phase(), is_night(), darkness() (a 0..1 value the renderer feeds into sky and lighting), in-game clock (hour_minute()) and /time-style control via commands. Hostiles spawn after dark โ€” daytime is for gathering, night is for surviving.

Creaturesโ€‹

Wildlife (passive, biome-matched)โ€‹

AnimalNotes
Deerspawns in forest/mountain biomes, roams, animated walk cycle
Rabbitspawns in grassland biomes, quick, animated hop

Biome matching is data-driven (spawns_in) โ€” the spawner asks the climate system which species belong where.

Hostiles (night spawn, 4 types)โ€‹

EnemyBehaviour
Zombiemelee chaser
Skeletonmelee chaser, ranged-flavour combat tuning
Spiderfast melee
Creeperexplodes when close โ€” is_about_to_explode() gives you a window to run

Every hostile kill increments the session kill counter and can unlock achievements. Kill feedback (damage flashes, XP-style session feedback) flows through EnemyEvent / SessionFeedback.

Achievementsโ€‹

A persistent achievement system with unlocks such as: first-kill, hunter, slayer, monster-slayer, last-stand, creeper-killer, spider-slayer, skeleton-hunter, master-crafter, architect, builder, full-health, explorer โ€” tracked across combat, crafting, building and exploration.

Crafting (NVCrafter)โ€‹

  • Recipe registry with both shaped and shapeless recipes
  • The NVCrafter block is the crafting station (breaks into itself โ€” protected drop rules)
  • Tools with material tiers (wood โ†’ stone โ†’ iron โ†’ diamond, ToolTier) and per-tool stats (tool_stats)
  • Block hardness system (hardness()) gates mining speed by tool tier
  • In-game inventory with hotbar, slots and item stacking

Commandsโ€‹

In-game chat commands: /tp <coords> (teleport), /give <item> (item grant), /help, plus the AI toolkit: /ai_stats, /ai_export, /ai_import, /ai_dataset.

Planned (not in this build)โ€‹

Warmth/temperature survival, RPG progression (XP, levels, prestige), rarity tiers, quest chains, boss fights, potions/armor/enchanting โ€” all designed on paper, none in the code yet. They will land on this page only when they ship.