@momo2555/koppeliajs 0.0.169 → 0.0.170
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/scripts/device.d.ts
CHANGED
|
@@ -33,9 +33,9 @@ export declare class Device {
|
|
|
33
33
|
onEvent(eventName: string, callback: () => void): string;
|
|
34
34
|
/**
|
|
35
35
|
* Enables the cursor module and listens for coordinate updates.
|
|
36
|
-
* @param callback Function to execute with the incoming (x, y) coordinates.
|
|
36
|
+
* @param callback Function to execute with the incoming (x, y, a) coordinates.
|
|
37
37
|
*/
|
|
38
|
-
onCursor(callback: (x: number, y: number) => void): string;
|
|
38
|
+
onCursor(callback: (x: number, y: number, a: number) => void): string;
|
|
39
39
|
/**
|
|
40
40
|
* Enables the biking module and listens for speed updates.
|
|
41
41
|
* @param callback Function to execute with the incoming speed data.
|
package/dist/scripts/device.js
CHANGED
|
@@ -50,14 +50,14 @@ export class Device {
|
|
|
50
50
|
}
|
|
51
51
|
/**
|
|
52
52
|
* Enables the cursor module and listens for coordinate updates.
|
|
53
|
-
* @param callback Function to execute with the incoming (x, y) coordinates.
|
|
53
|
+
* @param callback Function to execute with the incoming (x, y, a) coordinates.
|
|
54
54
|
*/
|
|
55
55
|
onCursor(callback) {
|
|
56
56
|
this._enableModule("cursor");
|
|
57
57
|
this._attachEvent("cursor");
|
|
58
58
|
let callbackId = this._console.onRequest((request, params, form, address) => {
|
|
59
59
|
if (request == "cursor" && address == this._address) {
|
|
60
|
-
callback(params.x, params.y);
|
|
60
|
+
callback(params.x, params.y, params.a);
|
|
61
61
|
}
|
|
62
62
|
});
|
|
63
63
|
this._callbackIds.push(callbackId);
|