Giter Site home page Giter Site logo

theoathman / godot-ios-location-plugin Goto Github PK

View Code? Open in Web Editor NEW
0.0 1.0 0.0 28 KB

A Godot iOS Plugin for location services.

License: MIT License

Python 18.58% Shell 14.53% Objective-C 2.03% Objective-C++ 34.99% C 3.67% C++ 4.10% GDScript 22.10%

godot-ios-location-plugin's Introduction

Godot iOS Location plugins

Godot iOS Plugin for Location Service. Retrieve user coordinates and handle client interactions seamlessly. based on Godot Android Plugin Template. Also see Creating Android plugins. To download the release, ready to use files go to the Release section.

How to setup

  • Make sure the addons and ios folder plugins are at res://addons and res://ios.
  • Go to Project -> Project settings -> Plugins.
  • Enable LocationIOS plugin.
  • Go to Project then click Reload Current Project.
  • Also enable the plugin from Project -> Export. From options tab Plugins -> Location Plugin
  • Now add LocationIOS node using the plus add-node button in the scene tab.

How to use

Once the LocationIOS node has been added to the scene. You can:

  • reference it from any script and start location service by calling begin_ios_location_serivce() method
$LocationIOS.begin_ios_location_serivce()
  • Connect to its signals by clicking connect from the Node tab. For example, connecting to location_updated(Latitude:float,Longitude:float) to receive location updates, or from code as follows
$LocationIOS.location_updated.connect(update_pin_position)

Building the plugin .xcframework

  • In order to build the plugin, we need Godot headers. For more details on how to get Godot headers see Godot repo. Place the headers at extracted_headers/godot_4.x. Make sure to follow steps here for more details on how to compile the Godot headers.

  • Run the script below with any Godot 4.X version as an input to produce debug and release plugin(.xcframework) files that are compatible with the target Godot version. Example:

./compileLocationPlugin.sh 4.3

This command will produce plugin(.xcframework) files for Godot 4.3. The result will be at bin/Godot_4.3. To use the plugin, Copy the resulting files and also copy Location.gdip into your Godot project res://ios/plugins/, copy the addons folder to res://addons. Don't forget to enable the plugin from project->plugins and from Export settings.

godot-ios-location-plugin's People

Watchers

Oprojects avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.