Model to Asset generation

extract layers and audio specificatios from Model

  • kwik5-sample-books/Solar2D/App/TheLastSpark/asset_guide_and_yamls.prompt.md

    1. forest_scene_audios.yaml

      - name: sfx_rustling_cloth.wav
        description: ""
      - name: sfx_wind_gentle.wav
        description: ""
      - name: sfx_footsteps_forest.wav
        description: ""
      - name: sfx_crow_caw_distant.wav
        description: ""
      - name: sfx_wolf_growl_corrupted.wav
        description: ""
      - name: music_Tension_Builds.mp3
        description: "A slow-building, suspenseful track"
      - name: music_Tension_Sting.mp3
        description: "A short, sharp, startling sound"
    2. forest_scene_layers.yaml

      - name: bg_cabin_interior
       x: 0
       y: 0
       width: 1280
       height: 720
       color: "#8B7355"
       text: "Cabin Interior Background"
       font_size: 24
       text_color: "#FFFFFF"
      
      - name: bg_forest
       x: 0
       y: 0
       width: 1280
       height: 720
       color: "#2D5016"
       text: "Forest Background"
       font_size: 24
       text_color: "#FFFFFF"
      
      # Characters - Elara (Left/center positioning)
      - name: elara_neutral
       x: 320
       y: 110
       width: 300
       height: 500
       color: "#D4A574"
       text: "Elara (Neutral)"
       font_size: 18
       text_color: "#FFFFFF"
       ...
       ...
    3. forest_scene_asset_guide.md

      #### 2. Generating Images
       **A. Backgrounds**
       *   **Prompt for `bg_old_cabin_interior.png`:**
           `"interior of an abandoned, small wooden cabin, a dusty sunbeam shines through a broken window, dust motes in the air, highly detailed, painterly style, fantasy, soft lighting, wide-angle shot"`
      
       *   **Prompt for `bg_forest_path.png`:**
           `"an overgrown forest path, daytime but gloomy, muted colors, eerie and quiet, fantasy, digital painting, cinematic, Unreal Engine 5"`

Model to Mock files

Mock(dummy) audio and image files are created by the following script. These mock files help prevent errors caused by missing assets and provide a clear reference for creators and developers to define and organize file names. Update their versions, for psd files, you can use Kwik exporter extension to publish images to the Solar2D project

  • Misc/espeak_ng/create_wav_mp3.py

    This script reads a YAML file containing entries with names and optional descriptions, then uses espeak-ng to generate spoken audio files (WAV or MP3) for each entry. The output files are named after the entry names.

    it means sfx_rustling_cloth.wav is created by inputing “sfx reusling cloth” text to speech

    eSpeak ng is tts https://github.com/espeak-ng/espeak-ng

    python create_wav_mp3.py forest_scene_audios.yaml
  • Misc/psd_tools/create_layered_psd.py

    this script reads a YAML file describing layers (position, size, color, text, etc.) and generates a layered PSD file using psd-tools and Pillow. Each layer is also saved as a PNG.

    python3 create_layered_psd.py forest_scene_layers forest.psd

    forest.psd in Photoshop