-
Notifications
You must be signed in to change notification settings - Fork 1
feat(ui): garden mode pacing, seed throttle, and flower colors #10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
c7d018f
77da43f
45bada1
5533a10
77f6ce8
32dc264
112daf0
95062e7
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -57,7 +57,8 @@ type UIConfig struct { | |
| ShowRainAnimation bool `mapstructure:"show_rain_animation" toml:"show_rain_animation"` | ||
|
|
||
| // Animation mode: "basic" (rain drops), "advanced" (clouds + rain + flowers), | ||
| // or "matrix" (falling code glyphs in the same column pattern). | ||
| // "matrix" (falling code glyphs in the same column pattern), or "garden" | ||
| // (seeds, rain, growth, then sun). | ||
| RainAnimationMode string `mapstructure:"rain_animation_mode" toml:"rain_animation_mode"` | ||
|
|
||
| // Show flavor quotes: TUI banner plus CLI motivation lines. | ||
|
|
@@ -76,6 +77,40 @@ type UIConfig struct { | |
| // Color profile for rain and TUI accents. | ||
| // Options: "storm", "drizzle", "monsoon", "rainbow", "synthwave". | ||
| ColorProfile string `mapstructure:"color_profile" toml:"color_profile"` | ||
|
|
||
| // Garden mode tuning (used when rain_animation_mode = "garden"). | ||
| // In the settings TUI, three rows appear under Rain animation mode; any | ||
| // field left at zero here still falls back to built-in defaults at runtime. | ||
|
|
||
| // GardenSeedRate is the target probability (0..1) for sky seeds; the | ||
| // simulator caps seeds per frame, so this reads as density, not i.i.d. | ||
| // rolls. Lower = rarer; default ~0.055. | ||
| GardenSeedRate float64 `mapstructure:"garden_seed_rate" toml:"garden_seed_rate,omitempty"` | ||
|
|
||
| // GardenGrowthPace multiplies the moisture thresholds for every growth | ||
| // stage. >1 slows growth; <1 speeds it up; 0 = use defaults. | ||
| GardenGrowthPace float64 `mapstructure:"garden_growth_pace" toml:"garden_growth_pace,omitempty"` | ||
|
|
||
| // GardenBloomDurationBase is the minimum bloom lifetime in animation | ||
| // frames before a flower starts to wither. 0 = default. | ||
| GardenBloomDurationBase int `mapstructure:"garden_bloom_duration_base" toml:"garden_bloom_duration_base,omitempty"` | ||
|
|
||
| // GardenBloomDurationJitter is added on top of the base bloom duration | ||
| // (uniform random in [0, jitter)). 0 = default. | ||
| GardenBloomDurationJitter int `mapstructure:"garden_bloom_duration_jitter" toml:"garden_bloom_duration_jitter,omitempty"` | ||
|
|
||
| // GardenWitherDuration is how many frames a withered plant lingers | ||
| // before crumbling and seeding offspring. 0 = default. | ||
| GardenWitherDuration int `mapstructure:"garden_wither_duration" toml:"garden_wither_duration,omitempty"` | ||
|
|
||
| // GardenOffspringMin/Max bound how many seeds a dying plant scatters. | ||
| // 0 = use defaults (currently 1 and 2). | ||
| GardenOffspringMin int `mapstructure:"garden_offspring_min" toml:"garden_offspring_min,omitempty"` | ||
| GardenOffspringMax int `mapstructure:"garden_offspring_max" toml:"garden_offspring_max,omitempty"` | ||
|
Comment on lines
+106
to
+109
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Stale doc: offspring defaults. The comment says "currently 1 and 2" but the README example and defaults.go example TOML list 🤖 Prompt for AI Agents |
||
|
|
||
| // GardenOffspringSpread is the half-width X jitter applied around the | ||
| // parent column when scattering offspring seeds. 0 = default. | ||
| GardenOffspringSpread int `mapstructure:"garden_offspring_spread" toml:"garden_offspring_spread,omitempty"` | ||
| } | ||
|
|
||
| const ( | ||
|
|
@@ -91,6 +126,7 @@ const ( | |
| UIRainAnimationBasic = "basic" | ||
| UIRainAnimationAdvanced = "advanced" | ||
| UIRainAnimationMatrix = "matrix" | ||
| UIRainAnimationGarden = "garden" | ||
| ) | ||
|
|
||
| // UIColorProfiles returns valid built-in UI color profile names. | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Stale doc: "three rows" claim.
The comment asserts that "three rows appear under Rain animation mode" in the settings TUI, but this block introduces eight garden tuning fields. Since the README explicitly states these are not surfaced in the in-app settings TUI, this inline comment is likely stale and misleading for future maintainers.
✏️ Suggested wording
📝 Committable suggestion
🤖 Prompt for AI Agents