SNES-style atmospheric music generator with customizable environments and scales. More...
| Import Statement: | import Clayground.Sound |
MoodPlayer creates procedural atmospheric music inspired by classic SNES RPG soundtracks like Chrono Trigger, Secret of Mana, and Zelda: A Link to the Past.
The generator is fully deterministic - the same seed with identical parameters will always produce the exact same music, enabling easy sharing of compositions.
import Clayground.Sound MoodPlayer { id: music environment: "cave" scale: "dorian" seed: 42 volume: 0.7 intensity: 0.5 onReadyChanged: if (ready) play() }
Share compositions using the shareCode property:
// Get shareable code console.log(music.shareCode) // "cave-dor-ampb-50-30-85-42" // Apply shared code music.shareCode = "mountain-pent-amb-80-20-90-1337"
| Environment | Character | Default Scale |
|---|---|---|
forest | Mysterious, flowing arpeggios (Secret of Mana style) | dorian |
dungeon | Dark, pulsing tension (Dark World style) | phrygian |
village | Peaceful, bright melodies (Kakariko Village style) | major |
cave | Deep, echoing drones with water drips | minor |
mountain | Majestic, airy atmosphere | lydian |
ocean | Rolling wave patterns, flowing movement | mixolydian |
desert | Exotic, shimmering heat haze | phrygian |
snow | Crystalline, ethereal cold | pentatonic |
major - Bright, happy (Ionian mode)minor - Sad, melancholic (Aeolian mode)dorian - Mysterious, jazzy minor with raised 6thphrygian - Dark, Spanish/Middle Eastern flavorlydian - Dreamy, floating with raised 4thmixolydian - Bright but with flat 7th, folk-likepentatonic - Simple 5-note scale, Asian feelblues - Soulful with blue notesControl which musical layers are active:
MoodPlayer { environment: "cave" layers: ["arp", "pad", "bass"] // melody disabled for ambient feel }
Available layers:
arp - Rhythmic arpeggiated chordsmelody - Thematic melodic linepad - Sustained atmospheric dronebass - Low-frequency foundation