stepstead-client/addons/stepcounter/export_plugin.gd
jts 6a1706051d İlk commit: Stepstead Godot istemci (4.6 Mobile)
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-11 11:31:35 +03:00

25 lines
1 KiB
GDScript
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

@tool
extends EditorExportPlugin
## Android export'unda StepCounter AAR'ını ve izinleri ekler.
const PLUGIN_NAME := "StepCounter"
# Derlenmiş AAR buraya kopyalanmalı (native/stepcounter-android/build çıktısı)
const AAR_PATH := "res://addons/stepcounter/stepcounter-release.aar"
func _supports_platform(platform: EditorExportPlatform) -> bool:
return platform is EditorExportPlatformAndroid
func _get_android_libraries(platform: EditorExportPlatform, debug: bool) -> PackedStringArray:
return PackedStringArray([AAR_PATH])
func _get_android_dependencies(platform: EditorExportPlatform, debug: bool) -> PackedStringArray:
return PackedStringArray(["org.jetbrains.kotlin:kotlin-stdlib:2.1.0"])
func _get_android_manifest_element_contents(platform: EditorExportPlatform, debug: bool) -> String:
return """
<uses-permission android:name="android.permission.ACTIVITY_RECOGNITION" />
<uses-feature android:name="android.hardware.sensor.stepcounter" android:required="false" />
"""
func _get_name() -> String:
return PLUGIN_NAME