Bereitstellen mit einem Klick

Was ist Bereitstellung mit einem Klick?

One-click deploy is a feature that is available once a platform is properly configured and a supported device is connected to the computer. Since things can go wrong at many levels (platform may not be configured correctly, SDK may be incorrectly installed, device may be improperly configured, etc.), it's good to let the user know that it exists.

After adding an Android export preset marked as Runnable, Godot can detect when a USB device is connected to the computer and offer the user to automatically export, install and run the project (in debug mode) on the device. This feature is called one-click deploy.

Bemerkung

Die Bereitstellung mit einem Klick ist nur verfügbar, wenn eine Exportvorlage hinzugefügt wurde, die im Export-Dialogfeld als Runnable (lauffähig) gekennzeichnet ist. Es können mehrere Exportvoreinstellungen als lauffähig markiert werden, allerdings darf pro Plattform nur eine einzige Voreinstellung als lauffähig markiert werden. Wird dagegen eine zweite Voreinstellung in einer bestimmten Plattform ebenfalls als lauffähig markiert, wird die andere Voreinstellung nicht mehr als lauffähig markiert.

Unterstützte Plattformen

  • Android: Exportiert das Projekt mit aktiviertem debugging und startet es auf dem verbundenen Gerät.

    • Befolgen Sie unbedingt die in Exportiere für Android beschriebenen Schritte. Andernfalls wird der Button zur 1-Klick-Bereitstellung mit nicht angezeigt.

    • Falls mehr als ein Gerät angeschlossen ist, fragt Godot auf welches Gerät das Projekt exportiert werden soll.

  • HTML5: Startet einen lokalen Webserver und startet das exportierte Projekt, indem der Standardbrowser geöffnet wird.

Die Unterstützung für weitere Plattformen wie iOS ist geplant.

Using one-click deploy

  • Aktivieren Sie bei der Bereitstellung für Android den Entwicklermodus auf Ihrem mobilen Gerät und aktivieren Sie dann das USB-Debugging in den Einstellungen des Geräts.

  • Nachdem Sie USB-Debugging aktiviert haben verbinden Sie das Gerät an Ihren PC mit einem USB-Kabel.

    • Fortgeschrittene Anwender sollten in der Lage sein kabelloses ADB zu verwenden.

  • Es sollte sichergestellt werden, dass für die Zielplattform (Android oder HTML5) eine als Runnable gekennzeichnete Exportvorgabe vorhanden ist.

  • Wenn alles korrekt und fehlerfrei konfiguriert ist, erscheinen plattformspezifische Symbole in der oberen rechten Ecke des Editors.

  • Klicken Sie auf den Button, um mit einem Klick auf die gewünschte Plattform zu exportieren.

../../_images/oneclick.png

Fehlerbeseitigung

Android

If you can't see the device in the list of devices when running the adb devices command in a terminal, it will not be visible by Godot either. To resolve this:

  • Check if USB debugging is enabled and authorized on the device. Try unlocking your device and accepting the authorization prompt if you see any. If you can't see this prompt, running adb devices on your PC should make the authorization prompt appear on the device.

  • Try revoking the debugging authorization in the device's developer settings, then follow the steps again.

  • Try using USB debugging instead of wireless debugging or vice versa. Sometimes, one of those can work better than the other.

  • On Linux, you may be missing the required udev rules for your device to be recognized.