-
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adds def_taptic_engine, defold-clipboard, poki-sdk (#40)
Adds: - [def_taptic_engine](https://github.com/MaratGilyazov/def_taptic_engine) - [defold-clipboard](https://github.com/britzl/defold-clipboard) - [poki-sdk](https://github.com/defold/extension-poki-sdk)
- Loading branch information
1 parent
70dc972
commit c79fd91
Showing
9 changed files
with
144 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
/// <library version="1.2" src="https://github.com/MaratGilyazov/def_taptic_engine/archive/refs/tags/v1.2.zip" /> | ||
/// <reference path="./TapticEngine.d.ts" /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
/** @noSelfInFile */ | ||
|
||
/** | ||
* Native extension for Defold with Taptic Engine implementation for iOS | ||
* @url https://github.com/MaratGilyazov/def_taptic_engine | ||
* @noResolution | ||
*/ | ||
declare namespace taptic_engine { | ||
export const IMPACT_LIGHT: number; | ||
export const IMPACT_MEDIUM: number; | ||
export const IMPACT_HEAVY: number; | ||
export const NOTIFICATION_SUCCESS: number; | ||
export const NOTIFICATION_WARNING: number; | ||
export const NOTIFICATION_ERROR: number; | ||
|
||
/** | ||
* Returns bool flag saying if taptic engine is supported | ||
* @returns {boolean} | ||
*/ | ||
export function isSupported(): boolean; | ||
|
||
/** | ||
* Call Taptic Engine Impact feedback with given style | ||
* @param {number} style - one of 3 constants `taptic_engine.IMPACT_LIGHT`, `taptic_engine.IMPACT_MEDIUM`, `taptic_engine.IMPACT_HEAVY` | ||
*/ | ||
export function impact( | ||
style: typeof IMPACT_HEAVY | typeof IMPACT_LIGHT | typeof IMPACT_MEDIUM, | ||
): void; | ||
|
||
/** | ||
* Call Taptic Engine Notification feedback with given type | ||
* @param {number} type - one of 3 constants `taptic_engine.NOTIFICATION_SUCCESS`, `taptic_engine.NOTIFICATION_WARNING`, `taptic_engine.NOTIFICATION_ERROR` | ||
*/ | ||
export function notification( | ||
type: | ||
| typeof NOTIFICATION_ERROR | ||
| typeof NOTIFICATION_SUCCESS | ||
| typeof NOTIFICATION_WARNING, | ||
): void; | ||
|
||
/** | ||
* Call Taptic Engine Selection feedback | ||
*/ | ||
export function selection(): void; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{ | ||
"name": "def_taptic_engine", | ||
"url": "https://github.com/MaratGilyazov/def_taptic_engine" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
/// <library version="1.24.0" src="https://github.com/britzl/defold-clipboard/archive/refs/tags/1.24.0.zip" /> | ||
/// <reference path="./defold-clipboard.d.ts" /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
/** @noSelfInFile */ | ||
|
||
/** | ||
* Defold native extension to access the clipboard | ||
* @url https://github.com/britzl/defold-clipboard | ||
* @noResolution | ||
*/ | ||
declare namespace clipboard { | ||
/** | ||
* Copy text to the clipboard. | ||
* @param {string} text | ||
*/ | ||
export function copy(text: string): void; | ||
|
||
/** | ||
* Get text from the clipboard. | ||
* @returns {string} | ||
*/ | ||
export function paste(): string; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{ | ||
"name": "defold-clipboard", | ||
"url": "https://github.com/britzl/defold-clipboard" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{ | ||
"name": "poki-sdk", | ||
"url": "https://github.com/defold/extension-poki-sdk" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
/// <library version="1.5.0" src="https://github.com/defold/extension-poki-sdk/archive/refs/tags/1.5.0.zip" /> | ||
/// <reference path="./poki-sdk.d.ts" /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
/** @noSelfInFile */ | ||
|
||
/** | ||
* Poki SDK native extension for Defold game engine | ||
* @url https://github.com/defold/extension-poki-sdk | ||
* @noResolution | ||
*/ | ||
declare namespace poki_sdk { | ||
/** | ||
* Equivalent to the JS SDK's PokiSDK.gameplayStart() | ||
*/ | ||
export function gameplay_start(): void; | ||
|
||
/** | ||
* Equivalent to the JS SDK's PokiSDK.gameplayStop() | ||
*/ | ||
export function gameplay_stop(): void; | ||
|
||
/** | ||
* Equivalent to the JS SDK's PokiSDK.commercialBreak() | ||
* @param {function} callback | ||
*/ | ||
export function commercial_break(callback: () => void): void; | ||
|
||
/** | ||
* Equivalent to the JS SDK's PokiSDK.rewardedBreak() | ||
* @param {function} callback | ||
*/ | ||
export function rewarded_break(callback: () => void): void; | ||
|
||
/** | ||
* Equivalent to the JS SDK's PokiSDK.setDebug(value) | ||
* @param {boolean} is_debug | ||
*/ | ||
export function set_debug(is_debug: boolean): void; | ||
|
||
/** | ||
* Equivalent to the JS SDK's PokiSDK.captureError(error_string) | ||
* @param {string} error | ||
*/ | ||
export function capture_error(error: string): void; | ||
|
||
/** | ||
* Equivalent to the JS SDK's PokiSDK.shareableURL({}).then(url => {}) | ||
* @param {table} params | ||
* @param {function} callback | ||
*/ | ||
export function shareable_url(params: {}, callback: () => void): void; | ||
|
||
/** | ||
* Equivalent to the JS SDK's PokiSDK.getURLParam('id') | ||
* @param {string} key | ||
* @returns {string} | ||
*/ | ||
export function get_url_param(key: string): string; | ||
|
||
/** | ||
* @deprecated since version 1.5.0 | ||
*/ | ||
export function is_ad_blocked(): boolean; | ||
} |