Langsung ke konten
Skillpedia
Pemrograman umum6.6k Β· #13821

godot-export

Fungsinya

Skill ini memandu agent mengubah proyek Godot 4 menjadi build jadi untuk setiap platform. Skill ini ditujukan untuk pembuat game yang siap membagikan atau merilis game mereka.

Kapan dipakai

  • βœ“Saat Anda ingin mengekspor game Godot untuk Windows, macOS, Linux, Web, atau Android.
  • βœ“Saat Anda perlu membuat atau mengubah preset ekspor dalam proyek Godot.
  • βœ“Saat Anda ingin menjalankan build Godot dari baris perintah, misalnya dalam pipeline CI.

Link skill

https://github.com/gamedev-skills/awesome-gamedev-agent-skills/blob/main/skills/godot/godot-export/SKILL.md

Salin lalu tempelkan ke AI Anda (Claude, ChatGPT, atau Cursor) dan minta AI mengikuti instruksinya.

Cara pakai

Cara paling mudah: salin pesan ini dan tempelkan ke AI Anda. AI akan membaca skill dan mengikuti instruksinya.

Pesan siap tempel

Gunakan skill ini untuk membantu saya: https://github.com/gamedev-skills/awesome-gamedev-agent-skills/blob/main/skills/godot/godot-export/SKILL.md Baca file SKILL.md di link tersebut dan ikuti instruksinya untuk tugas saya.
Mau AI Anda menemukan skill seperti ini sendiri?Pasang MCP Skillpedia gratis: cukup satu baris, dan AI mencari di antara 15.000+ skill sebelum tiap tugas.Pasang dalam 1 menit β†’

Contoh permintaan ke AI

β€œBantu saya mengekspor game Godot saya sebagai build Windows dan menyiapkan versi web juga.”

5 skill baru setiap minggu. 1 menit baca.

Cara kerjanya

Skill menjelaskan cara memasang template ekspor, mendefinisikan preset ekspor, dan menjalankan ekspor dari editor atau baris perintah, dengan catatan untuk build web dan server.

Konten teknis (SKILL.md asli)

Teks asli dari pembuat, dalam bahasa Inggris, langsung dari GitHub.

Godot Export & Builds (4.x)

Turn a project into runnable platform builds via export presets and the command line, and handle the web/dedicated-server gotchas. Targets Godot 4.7.

When to use

  • Use when producing a shippable build: installing export templates, creating/editing export presets, exporting from the editor or headless CLI (CI), or troubleshooting web (HTML5) and dedicated-server exports.

When not to use: storefront publishing flows β†’ steam-publish/itch-publish; the networking code of a server β†’ godot-multiplayer (this skill covers building it headless).

Core workflow

  1. Install export templates matching your engine version: Editor menu > Manage Export Templates (download), or install the .tpz offline. Versions must match the editor exactly. Since 4.7 the downloader can fetch templates for a single platform or architecture instead of the full set.
  2. Add export presets in Project > Export: pick a platform (Windows Desktop, macOS, Linux, Web, Android, iOS), set the export path, icons, features, and resource include/exclude filters. Presets are saved to export_presets.cfg.
  3. Export from the editor with Export Project (release) or Export PCK/ZIP.
  4. Or export headless from the CLI for automation/CI using --export-release "<preset name>" <output path>.
  5. Per platform: Web needs cross-origin isolation (COOP/COEP) only if the preset's Thread Support is on (off by default); Android needs the SDK/keystore; macOS/iOS need signing for distribution.
  6. Smoke-test the build on the target before shipping β€” exported builds use res:// read-only; write to user://.

Patterns

1. Headless CLI export (CI-friendly)

# Preset name must match exactly what's in Project > Export (quote it).
# Run from the project directory (where project.godot lives).
godot --headless --export-release "Windows Desktop" build/windows/game.exe
godot --headless --export-release "Linux"           build/linux/game.x86_64
godot --headless --export-release "Web"             build/web/index.html

# Debug build (includes debug symbols / remote debug):
godot --headless --export-debug "Windows Desktop" build/windows/game_debug.exe

# Export only the data pack (no executable):
godot --headless --export-pack "Linux" build/game.pck

# Export only files changed since the given base pack(s):
godot --headless --export-patch "Linux" build/patch1.pck --patches build/game.pck

2. Run a project headless (dedicated server / tests)

# No window/GPU β€” for a server build or automated runs.
godot --headless --path . res://server_main.tscn
# Quit after N main-loop iterations (frames, NOT seconds) β€” handy for a headless smoke test:
godot --headless --path . --quit-after 600

3. Detect the build context at runtime

func _ready() -> void:
    if OS.has_feature("dedicated_server") or DisplayServer.get_name() == "headless":
        _start_server_only()          # skip rendering/UI on a headless server
    if OS.has_feature("web"):
        _apply_web_tweaks()
    # Custom feature tags (added per preset) are also queryable:
    # if OS.has_feature("demo"): limit_content()

4. Choose write paths that survive export

# res:// is READ-ONLY in exported games. Always write to user://.
func save_path() -> String:
    return "user://savegame.tres"     # resolves to the OS app-data dir

func _ready() -> void:
    print(OS.get_user_data_dir())     # where user:// actually lives

Pitfalls

  • "No export template found". Templates must match the exact editor version (incl. beta/rc). Re-download via Manage Export Templates after upgrading Godot.
  • Preset name mismatch in CLI. --export-release "Windows" fails if the preset is named "Windows Desktop". Names are case- and space-sensitive; quote them.
  • Web build shows a blank page / threads error. Builds with the preset's Thread Support option enabled require the server to send Cross-Origin-Opener-Policy: same-origin and Cross-Origin-Embedder-Policy: require-corp (cross-origin isolation for SharedArrayBuffer). Must be served over HTTP(S), not opened as a file://. itch.io has a "SharedArrayBuffer support" toggle for this. If the host cannot set headers (GitHub Pages), leave Thread Support off β€” the default since 4.3.
  • Writing to res:// at runtime fails in exports (read-only, packed). Use user://.
  • **Missing resour
Pertanyaan umum

Apakah saya perlu memasang sesuatu sebelum mengekspor?

Ya. Template ekspor harus sesuai persis dengan versi Godot Anda, dan skill menjelaskan cara memasangnya.

Apakah build bisa diotomatisasi?

Ya. Skill mencakup ekspor baris perintah headless, yang dapat berjalan di sistem build otomatis.

Apakah skill ini menerbitkan game ke toko?

Tidak. Penerbitan ke toko ditangani oleh skill terpisah, sedangkan skill ini berfokus pada pembuatan file game.

Detail

Deskripsi asli dari pembuat

Export and build a Godot 4.7 project for distribution: install export templates, define export presets (Windows/macOS/Linux/Web/Android), run headless command-line exports for CI, and handle web (HTML5) COOP/COEP and dedicated-server/headless builds. Use when exporting a Godot game, configuring export_presets.cfg, building for web/desktop/mobile, or automating builds from the command line.

repo: gamedev-skills/awesome-gamedev-agent-skills

Popularitas

Bintang GitHub
6.6k
Peringkat
#13821
Lisensi
Apache-2.0
Diperbarui
28/10/2026

Apakah skill ini berguna?

0

Masuk untuk memberi suara.

Komentar

  • …

Skill lain dari repositori ini

Skill serupa