Valheim
You are viewing a potentially older version of this package. View Latest Version
Install with App

Details

Date Uploaded
2 weeks ago
Downloads
225
Size
385KB
ADDatHost Valheim hosting
30% off

ClockDaddy

A Valheim clock that tells you when to go to bed.

Someone on our server needed reminders to sleep. Someone else said "I'm not your daddy." So now there's a mod for it.

What it does

  • Clock on screen. Shows game time and day number. Put it anywhere, any size, any color.
  • Heads-up at 4 PM game time. One ping and "Head for bed soon." Once, no blinking.
  • Bedtime ping at 5 PM game time. Plays a chime and pops up "Time for bed." If you're still up, it pings again every couple of minutes (you choose how often and how many times).
  • Blinking clock. From bedtime until you're in bed, the clock flashes and adds a "BEDTIME" line.
  • Next-weather icon. A small icon of the weather that's coming next, with "Rain in 3m 20s" beside it. Turn it on or off and move it anywhere from F1.
  • Silence it for the night. Press End and it shuts up until tomorrow night. Press End again to undo.
  • Turn the alarm off entirely. Ctrl+End switches the whole alarm off or back on, and it stays that way.
  • Set everything from F1. Every setting is in the Configuration Manager window (F1) and takes effect immediately while you play. No config file editing needed.

It stops by itself when you get in bed, and resets every evening. The mod only runs on your own game: install it yourself for your own reminders. The server doesn't need it.

Settings (F1)

Section What's there
1 - Clock Show/hide, clock text template, time format, minute rounding, hide on map/menus/HUD
2 - Clock Look Position X/Y (%), alignment, font size, scale with resolution, bold text, colors, outline
3 - Bedtime Reminder On/off; Heads-Up Time (4:00 PM), Bedtime (5:00 PM) and Give Up At (6:00 AM), each picked from a drop-down of game times in 15-minute steps; heads-up and bedtime messages, message text and where it shows, sound (Chime / Bell / Beeps / None), volume, repeat interval, max repeats, Test Ping button
4 - Blink Blink on/off, blink color, blink speed, the extra "BEDTIME" clock line
5 - Weather Icon On/off, position X/Y (%), icon size, label text and size
6 - Hotkeys Silence Tonight (default End), Toggle Alarm on/off (default Ctrl+End), Toggle Clock (default Home)

The defaults are the AzuClock setup our server already used: "Game Time / Current Day / Real Time" in gold, green and pink across the top, 12-hour time, Home to hide it.

Clock text tokens

{gametime} {day} {tod} (Morning/Afternoon/Evening/Night) {realtime} {bedtime} {bedtimein} (game time left until the reminder) {biome} {weather} {nextweather} {weatherin} (real time until the weather changes) {silencekey}. AzuClock's {0} {1} {2} {3} also work, so an AzuClock clock string can be pasted straight in.

Type \n for a new line. Unity rich text works: <b>, <i>, <color=#ffcc00>, <size=18>.

Example: <b>{gametime}</b> Day {day}\n<size=16>bed in {bedtimein}</size>

Weather icons

The forecast re-runs the game's own weather roll for the next period, so it is exact as long as you're still in the same biome when the weather changes. There's no icon in places where the weather is fixed (crypts, caves, raids, boss fog).

Ten icons: clear_day clear_night mist light_rain rain storm snow snowstorm ash_rain dark. To use your own, put same-named PNGs (square, transparent) in BepInEx/plugins/ClockDaddy/icons/. They replace the built-in ones, no rebuild needed.

Install

Use r2modman / Thunderstore Mod Manager, or drop ClockDaddy.dll into BepInEx/plugins/ClockDaddy/. The F1 window comes from a Configuration Manager mod. Any of them works (shudnal's ConfigurationManager, Azumatt's Official BepInEx ConfigurationManager); it is not a hard dependency so you don't end up with two. Without it the settings are still in BepInEx/config/com.n8daniels.clockdaddy.cfg.

Building

  1. Copy Environment.props.example to Environment.props and set your Valheim path.
  2. dotnet build ClockDaddy.sln -c Release
  3. powershell -ExecutionPolicy Bypass -File tools\Build-Package.ps1 builds artifacts\ClockDaddy.zip.

Testing

An in-game harness loads a throwaway local character and world, winds the clock to bedtime and checks everything, then quits. See docs/TESTING.md.

Releasing

Bump the version in package/manifest.json, ClockDaddyPlugin.cs and CHANGELOG.md, build the package, then:

gh release create vX.Y.Z artifacts\ClockDaddy.zip --notes-file CHANGELOG.md

The GitHub Action uploads that zip to Thunderstore as Glasir-ClockDaddy (needs the THUNDERSTORE_TOKEN repo secret).

Inspired by Azumatt's AzuClock. Written from scratch.

Thunderstore development is made possible with ads. Please consider making an exception to your adblock.