@defold-typescript/types 0.34.0 → 0.36.0
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/api-signatures.json +9547 -186
- package/api-targets.json +9 -66
- package/examples/translations.json +6 -6
- package/generated/buffer.d.ts +2 -2
- package/generated/collectionfactory.d.ts +2 -2
- package/generated/factory.d.ts +13 -12
- package/generated/gui.d.ts +23 -23
- package/generated/kinds/gui-script.d.ts +0 -4
- package/generated/kinds/render-script.d.ts +1 -4
- package/generated/kinds/script.d.ts +0 -4
- package/generated/model.d.ts +2 -2
- package/generated/profiler.d.ts +2 -4
- package/generated/render.d.ts +7 -155
- package/generated/sys.d.ts +1 -1
- package/generated/versions/defold-1.12.4/buffer.d.ts +2 -2
- package/generated/versions/defold-1.12.4/collectionfactory.d.ts +2 -2
- package/generated/versions/defold-1.12.4/factory.d.ts +13 -12
- package/generated/versions/defold-1.12.4/gui.d.ts +23 -23
- package/generated/versions/defold-1.12.4/index.d.ts +9 -4
- package/generated/versions/defold-1.12.4/model.d.ts +2 -2
- package/generated/versions/defold-1.12.4/profiler.d.ts +2 -4
- package/generated/versions/defold-1.12.4/render.d.ts +7 -155
- package/generated/versions/defold-1.12.4/sys.d.ts +1 -1
- package/generated/versions/defold-1.12.4/vmath.d.ts +0 -19
- package/generated/versions/defold-1.12.4/window.d.ts +2 -4
- package/generated/versions/defold-1.12.4/zlib.d.ts +2 -1
- package/generated/versions/defold-1.13.0/buffer.d.ts +2 -2
- package/generated/versions/defold-1.13.0/collectionfactory.d.ts +2 -2
- package/generated/versions/defold-1.13.0/factory.d.ts +13 -12
- package/generated/versions/defold-1.13.0/gui.d.ts +23 -23
- package/generated/versions/defold-1.13.0/index.d.ts +9 -4
- package/generated/versions/defold-1.13.0/model.d.ts +2 -2
- package/generated/versions/defold-1.13.0/profiler.d.ts +2 -4
- package/generated/versions/defold-1.13.0/render.d.ts +7 -155
- package/generated/versions/defold-1.13.0/sys.d.ts +1 -1
- package/generated/versions/defold-1.13.0/vmath.d.ts +0 -19
- package/generated/versions/defold-1.13.0/window.d.ts +2 -4
- package/generated/versions/defold-1.13.0/zlib.d.ts +2 -1
- package/generated/vmath.d.ts +0 -19
- package/generated/window.d.ts +2 -4
- package/generated/zlib.d.ts +2 -1
- package/index.d.ts +2 -4
- package/package.json +7 -2
- package/scripts/extension-goldens.ts +23 -0
- package/scripts/generate-api-signatures.ts +72 -8
- package/scripts/materialize-version.ts +15 -1
- package/scripts/regen.ts +109 -27
- package/scripts/signature-store-fs.ts +1 -0
- package/scripts/sync-api-docs.ts +5 -61
- package/src/emit-dts.ts +359 -58
- package/src/index.ts +1 -0
- package/src/optional-correction-provenance.ts +13 -2
- package/src/render-overloads.d.ts +46 -0
- package/src/vmath-overloads.d.ts +19 -0
- package/generated/iac.d.ts +0 -18
- package/generated/iap.d.ts +0 -60
- package/generated/push.d.ts +0 -66
- package/generated/versions/defold-1.12.4/iac.d.ts +0 -18
- package/generated/versions/defold-1.12.4/iap.d.ts +0 -60
- package/generated/versions/defold-1.12.4/push.d.ts +0 -66
- package/generated/versions/defold-1.12.4/webview.d.ts +0 -71
- package/generated/versions/defold-1.13.0/iac.d.ts +0 -18
- package/generated/versions/defold-1.13.0/iap.d.ts +0 -60
- package/generated/versions/defold-1.13.0/push.d.ts +0 -66
- package/generated/versions/defold-1.13.0/webview.d.ts +0 -71
- package/generated/webview.d.ts +0 -71
- package/scripts/fidelity-audit.ts +0 -684
package/api-targets.json
CHANGED
|
@@ -109,16 +109,6 @@
|
|
|
109
109
|
"fixture": "http_doc.json",
|
|
110
110
|
"outFile": "http.d.ts"
|
|
111
111
|
},
|
|
112
|
-
{
|
|
113
|
-
"namespace": "iac",
|
|
114
|
-
"fixture": "iac_doc.json",
|
|
115
|
-
"outFile": "iac.d.ts"
|
|
116
|
-
},
|
|
117
|
-
{
|
|
118
|
-
"namespace": "iap",
|
|
119
|
-
"fixture": "iap_doc.json",
|
|
120
|
-
"outFile": "iap.d.ts"
|
|
121
|
-
},
|
|
122
112
|
{
|
|
123
113
|
"namespace": "image",
|
|
124
114
|
"fixture": "image_doc.json",
|
|
@@ -170,15 +160,11 @@
|
|
|
170
160
|
"fixture": "profiler_doc.json",
|
|
171
161
|
"outFile": "profiler.d.ts"
|
|
172
162
|
},
|
|
173
|
-
{
|
|
174
|
-
"namespace": "push",
|
|
175
|
-
"fixture": "push_doc.json",
|
|
176
|
-
"outFile": "push.d.ts"
|
|
177
|
-
},
|
|
178
163
|
{
|
|
179
164
|
"namespace": "render",
|
|
180
165
|
"fixture": "render_doc.json",
|
|
181
|
-
"outFile": "render.d.ts"
|
|
166
|
+
"outFile": "render.d.ts",
|
|
167
|
+
"skipFunctions": ["render_target"]
|
|
182
168
|
},
|
|
183
169
|
{
|
|
184
170
|
"namespace": "resource",
|
|
@@ -224,12 +210,7 @@
|
|
|
224
210
|
"namespace": "vmath",
|
|
225
211
|
"fixture": "vmath_doc.json",
|
|
226
212
|
"outFile": "vmath.d.ts",
|
|
227
|
-
"skipFunctions": ["clamp", "lerp", "slerp", "mul_per_elem", "normalize"]
|
|
228
|
-
},
|
|
229
|
-
{
|
|
230
|
-
"namespace": "webview",
|
|
231
|
-
"fixture": "webview_doc.json",
|
|
232
|
-
"outFile": "webview.d.ts"
|
|
213
|
+
"skipFunctions": ["clamp", "euler_to_quat", "lerp", "slerp", "mul_per_elem", "normalize"]
|
|
233
214
|
},
|
|
234
215
|
{
|
|
235
216
|
"namespace": "window",
|
|
@@ -458,16 +439,6 @@
|
|
|
458
439
|
"fixture": "http_doc.json",
|
|
459
440
|
"outFile": "http.d.ts"
|
|
460
441
|
},
|
|
461
|
-
{
|
|
462
|
-
"namespace": "iac",
|
|
463
|
-
"fixture": "iac_doc.json",
|
|
464
|
-
"outFile": "iac.d.ts"
|
|
465
|
-
},
|
|
466
|
-
{
|
|
467
|
-
"namespace": "iap",
|
|
468
|
-
"fixture": "iap_doc.json",
|
|
469
|
-
"outFile": "iap.d.ts"
|
|
470
|
-
},
|
|
471
442
|
{
|
|
472
443
|
"namespace": "image",
|
|
473
444
|
"fixture": "image_doc.json",
|
|
@@ -519,15 +490,11 @@
|
|
|
519
490
|
"fixture": "profiler_doc.json",
|
|
520
491
|
"outFile": "profiler.d.ts"
|
|
521
492
|
},
|
|
522
|
-
{
|
|
523
|
-
"namespace": "push",
|
|
524
|
-
"fixture": "push_doc.json",
|
|
525
|
-
"outFile": "push.d.ts"
|
|
526
|
-
},
|
|
527
493
|
{
|
|
528
494
|
"namespace": "render",
|
|
529
495
|
"fixture": "render_doc.json",
|
|
530
|
-
"outFile": "render.d.ts"
|
|
496
|
+
"outFile": "render.d.ts",
|
|
497
|
+
"skipFunctions": ["render_target"]
|
|
531
498
|
},
|
|
532
499
|
{
|
|
533
500
|
"namespace": "resource",
|
|
@@ -573,12 +540,7 @@
|
|
|
573
540
|
"namespace": "vmath",
|
|
574
541
|
"fixture": "vmath_doc.json",
|
|
575
542
|
"outFile": "vmath.d.ts",
|
|
576
|
-
"skipFunctions": ["clamp", "lerp", "slerp", "mul_per_elem", "normalize"]
|
|
577
|
-
},
|
|
578
|
-
{
|
|
579
|
-
"namespace": "webview",
|
|
580
|
-
"fixture": "webview_doc.json",
|
|
581
|
-
"outFile": "webview.d.ts"
|
|
543
|
+
"skipFunctions": ["clamp", "euler_to_quat", "lerp", "slerp", "mul_per_elem", "normalize"]
|
|
582
544
|
},
|
|
583
545
|
{
|
|
584
546
|
"namespace": "window",
|
|
@@ -770,16 +732,6 @@
|
|
|
770
732
|
"fixture": "http_doc.json",
|
|
771
733
|
"outFile": "http.d.ts"
|
|
772
734
|
},
|
|
773
|
-
{
|
|
774
|
-
"namespace": "iac",
|
|
775
|
-
"fixture": "iac_doc.json",
|
|
776
|
-
"outFile": "iac.d.ts"
|
|
777
|
-
},
|
|
778
|
-
{
|
|
779
|
-
"namespace": "iap",
|
|
780
|
-
"fixture": "iap_doc.json",
|
|
781
|
-
"outFile": "iap.d.ts"
|
|
782
|
-
},
|
|
783
735
|
{
|
|
784
736
|
"namespace": "image",
|
|
785
737
|
"fixture": "image_doc.json",
|
|
@@ -826,15 +778,11 @@
|
|
|
826
778
|
"fixture": "profiler_doc.json",
|
|
827
779
|
"outFile": "profiler.d.ts"
|
|
828
780
|
},
|
|
829
|
-
{
|
|
830
|
-
"namespace": "push",
|
|
831
|
-
"fixture": "push_doc.json",
|
|
832
|
-
"outFile": "push.d.ts"
|
|
833
|
-
},
|
|
834
781
|
{
|
|
835
782
|
"namespace": "render",
|
|
836
783
|
"fixture": "render_doc.json",
|
|
837
|
-
"outFile": "render.d.ts"
|
|
784
|
+
"outFile": "render.d.ts",
|
|
785
|
+
"skipFunctions": ["render_target"]
|
|
838
786
|
},
|
|
839
787
|
{
|
|
840
788
|
"namespace": "resource",
|
|
@@ -880,12 +828,7 @@
|
|
|
880
828
|
"namespace": "vmath",
|
|
881
829
|
"fixture": "vmath_doc.json",
|
|
882
830
|
"outFile": "vmath.d.ts",
|
|
883
|
-
"skipFunctions": ["clamp", "lerp", "slerp", "mul_per_elem", "normalize"]
|
|
884
|
-
},
|
|
885
|
-
{
|
|
886
|
-
"namespace": "webview",
|
|
887
|
-
"fixture": "webview_doc.json",
|
|
888
|
-
"outFile": "webview.d.ts"
|
|
831
|
+
"skipFunctions": ["clamp", "euler_to_quat", "lerp", "slerp", "mul_per_elem", "normalize"]
|
|
889
832
|
},
|
|
890
833
|
{
|
|
891
834
|
"namespace": "window",
|
|
@@ -206,7 +206,7 @@
|
|
|
206
206
|
"factory.create": [
|
|
207
207
|
{
|
|
208
208
|
"sourceHash": "d2cd2037a9127ec6",
|
|
209
|
-
"ts": "// How to create a new game object:\nexport default defineScript({\n init(self) {\n // create a new game object and provide property values\n
|
|
209
|
+
"ts": "// How to create a new game object:\nexport default defineScript({\n init(self) {\n // create a new game object and provide property values\n const created = factory.create(\"#factory\", undefined, undefined, { my_value: 1 });\n // communicate with the object\n msg.post(created, \"hello\");\n },\n});\n\n// And then let the new game object have a script attached, in its own file:\n//\n// go.property(\"my_value\", 0);\n//\n// export default defineScript({\n// init(self) {\n// // do something with self.my_value which is now one\n// },\n// });"
|
|
210
210
|
}
|
|
211
211
|
],
|
|
212
212
|
"factory.load": [
|
|
@@ -320,7 +320,7 @@
|
|
|
320
320
|
"go.get_world_position": [
|
|
321
321
|
{
|
|
322
322
|
"sourceHash": "ab804a5cdcfd4f7d",
|
|
323
|
-
"ts": "// Get the world position of the game object the script is attached to:\nconst p = go.get_world_position();\n\n// Reach a sibling game object by its id
|
|
323
|
+
"ts": "// Get the world position of the game object the script is attached to:\nconst p = go.get_world_position();\n\n// Reach a sibling game object by its id — relative addressing, no socket prefix:\nconst p2 = go.get_world_position(\"x\");"
|
|
324
324
|
}
|
|
325
325
|
],
|
|
326
326
|
"go.get_world_rotation": [
|
|
@@ -368,7 +368,7 @@
|
|
|
368
368
|
"go.set_position": [
|
|
369
369
|
{
|
|
370
370
|
"sourceHash": "ad83d0274d776e8f",
|
|
371
|
-
"ts": "// `p` is the desired position (a Vector3).\nconst p = vmath.vector3();\n\n// Set the position of the game object the script is attached to:\ngo.set_position(p);\n\n// Reach a sibling game object by its id
|
|
371
|
+
"ts": "// `p` is the desired position (a Vector3).\nconst p = vmath.vector3();\n\n// Set the position of the game object the script is attached to:\ngo.set_position(p);\n\n// Reach a sibling game object by its id — relative addressing, no socket prefix:\ngo.set_position(p, \"x\");"
|
|
372
372
|
}
|
|
373
373
|
],
|
|
374
374
|
"go.set_rotation": [
|
|
@@ -770,7 +770,7 @@
|
|
|
770
770
|
"on_message": [
|
|
771
771
|
{
|
|
772
772
|
"sourceHash": "bfed6bd72e3242e2",
|
|
773
|
-
"ts": "// This example demonstrates how a game object instance, called \"a\", can communicate with another instance, called \"b\". It\n// is assumed that both script components of the instances has id \"script\".\n\n// a.script
|
|
773
|
+
"ts": "// This example demonstrates how a game object instance, called \"a\", can communicate with another instance, called \"b\". It\n// is assumed that both script components of the instances has id \"script\".\n\n// a.script — Script of instance \"a\":\nexport default defineScript({\n init() {\n // let b know about some important data\n msg.post(\"b#script\", \"my_data\", { important_value: 1 });\n },\n});\n\n// b.script — Script of instance \"b\":\nexport default defineScript({\n init() {\n // store the url of instance \"a\" for later use, by specifying undefined as socket we\n // automatically use our own socket\n return { a_url: msg.url(undefined, go.get_id(\"a\"), \"script\") };\n },\n\n on_message(self, message_id, message, sender) {\n // check message and sender\n if (message_id === hash(\"my_data\") && sender === self.a_url) {\n // use the data in some way\n self.important_value = message.important_value;\n }\n },\n});"
|
|
774
774
|
}
|
|
775
775
|
],
|
|
776
776
|
"on_reload": [
|
|
@@ -928,7 +928,7 @@
|
|
|
928
928
|
"render.clear": [
|
|
929
929
|
{
|
|
930
930
|
"sourceHash": "70406f065fc91216",
|
|
931
|
-
"ts": "// Clear the color buffer and the depth buffer.\
|
|
931
|
+
"ts": "// Clear the color buffer and the depth buffer.\nconst buffers = new LuaMap<render.ClearBufferKey, number | Vector4>();\nbuffers.set(graphics.BUFFER_TYPE_COLOR0_BIT, vmath.vector4(0, 0, 0, 0));\nbuffers.set(graphics.BUFFER_TYPE_DEPTH_BIT, 1);\nrender.clear(buffers);"
|
|
932
932
|
}
|
|
933
933
|
],
|
|
934
934
|
"render.constant_buffer": [
|
|
@@ -1978,7 +1978,7 @@
|
|
|
1978
1978
|
"zlib.inflate": [
|
|
1979
1979
|
{
|
|
1980
1980
|
"sourceHash": "6b8b8cc6d9afe679",
|
|
1981
|
-
"ts": "const data
|
|
1981
|
+
"ts": "const data =\n \"\\x78\\x5e\\x0b\\xc9\\xc8\\x2c\\x56\\x00\\xa2\\x44\\x85\\xe2\\x92\\xa2\\xcc\\xbc\\x74\\x85\\xf2\\xcc\\x92\\x0c\\x85\\xd2\\xbc\\xe4\\xfc\\xdc\\x82\\xa2\\xd4\\xe2\\xe2\\xd4\\x14\\x85\\x94\\xc4\\x92\\x44\\x3d\\x00\\x2c\\x43\\x0e\\xc9\";\nconst uncompressed_data = zlib.inflate(data);\nprint(uncompressed_data); //> This is a string with uncompressed data."
|
|
1982
1982
|
}
|
|
1983
1983
|
]
|
|
1984
1984
|
}
|
package/generated/buffer.d.ts
CHANGED
|
@@ -142,7 +142,7 @@ declare global {
|
|
|
142
142
|
* if (values) print(`${values.length} values in 'somefloats'`);
|
|
143
143
|
* ```
|
|
144
144
|
*/
|
|
145
|
-
function get_metadata(buf: Opaque<"buffer">, metadata_name: Hash | string): LuaMultiReturn<[number[] | undefined,
|
|
145
|
+
function get_metadata(buf: Opaque<"buffer">, metadata_name: Hash | string): LuaMultiReturn<[number[] | undefined, number & { readonly __brand: "buffer.VALUE_TYPE_FLOAT32" } | number & { readonly __brand: "buffer.VALUE_TYPE_INT16" } | number & { readonly __brand: "buffer.VALUE_TYPE_INT32" } | number & { readonly __brand: "buffer.VALUE_TYPE_INT64" } | number & { readonly __brand: "buffer.VALUE_TYPE_INT8" } | number & { readonly __brand: "buffer.VALUE_TYPE_UINT16" } | number & { readonly __brand: "buffer.VALUE_TYPE_UINT32" } | number & { readonly __brand: "buffer.VALUE_TYPE_UINT64" } | number & { readonly __brand: "buffer.VALUE_TYPE_UINT8" } | undefined]>;
|
|
146
146
|
/**
|
|
147
147
|
* Get a specified stream from a buffer.
|
|
148
148
|
*
|
|
@@ -169,7 +169,7 @@ declare global {
|
|
|
169
169
|
* buffer.set_metadata(buf, hash("somefloats"), [-2.5, 10.0, 32.2], buffer.VALUE_TYPE_FLOAT32);
|
|
170
170
|
* ```
|
|
171
171
|
*/
|
|
172
|
-
function set_metadata(buf: Opaque<"buffer">, metadata_name: Hash | string, values: number[], value_type:
|
|
172
|
+
function set_metadata(buf: Opaque<"buffer">, metadata_name: Hash | string, values: number[], value_type: number & { readonly __brand: "buffer.VALUE_TYPE_FLOAT32" } | number & { readonly __brand: "buffer.VALUE_TYPE_INT16" } | number & { readonly __brand: "buffer.VALUE_TYPE_INT32" } | number & { readonly __brand: "buffer.VALUE_TYPE_INT64" } | number & { readonly __brand: "buffer.VALUE_TYPE_INT8" } | number & { readonly __brand: "buffer.VALUE_TYPE_UINT16" } | number & { readonly __brand: "buffer.VALUE_TYPE_UINT32" } | number & { readonly __brand: "buffer.VALUE_TYPE_UINT64" } | number & { readonly __brand: "buffer.VALUE_TYPE_UINT8" }): void;
|
|
173
173
|
}
|
|
174
174
|
}
|
|
175
175
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/** @noSelfInFile */
|
|
2
|
-
import type { Hash,
|
|
2
|
+
import type { Hash, Quaternion, Url, Vector3 } from "../src/core-types";
|
|
3
3
|
|
|
4
4
|
declare global {
|
|
5
5
|
/**
|
|
@@ -92,7 +92,7 @@ declare global {
|
|
|
92
92
|
*
|
|
93
93
|
* - `collectionfactory.STATUS_LOADED`
|
|
94
94
|
*/
|
|
95
|
-
function get_status(url?: string | Hash | Url):
|
|
95
|
+
function get_status(url?: string | Hash | Url): number & { readonly __brand: "collectionfactory.STATUS_UNLOADED" } | number & { readonly __brand: "collectionfactory.STATUS_LOADING" } | number & { readonly __brand: "collectionfactory.STATUS_LOADED" };
|
|
96
96
|
/**
|
|
97
97
|
* Resources loaded are referenced by the collection factory component until the existing (parent) collection is destroyed or collectionfactory.unload is called.
|
|
98
98
|
* Calling this function when the factory is not marked as dynamic loading does nothing.
|
package/generated/factory.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/** @noSelfInFile */
|
|
2
|
-
import type { Hash,
|
|
2
|
+
import type { Hash, Quaternion, Url, Vector3 } from "../src/core-types";
|
|
3
3
|
|
|
4
4
|
declare global {
|
|
5
5
|
/**
|
|
@@ -39,20 +39,21 @@ declare global {
|
|
|
39
39
|
* export default defineScript({
|
|
40
40
|
* init(self) {
|
|
41
41
|
* // create a new game object and provide property values
|
|
42
|
-
*
|
|
42
|
+
* const created = factory.create("#factory", undefined, undefined, { my_value: 1 });
|
|
43
43
|
* // communicate with the object
|
|
44
|
-
* msg.post(
|
|
44
|
+
* msg.post(created, "hello");
|
|
45
45
|
* },
|
|
46
46
|
* });
|
|
47
47
|
*
|
|
48
|
-
* // And then let the new game object have a script attached:
|
|
49
|
-
*
|
|
50
|
-
*
|
|
51
|
-
*
|
|
52
|
-
*
|
|
53
|
-
*
|
|
54
|
-
*
|
|
55
|
-
* }
|
|
48
|
+
* // And then let the new game object have a script attached, in its own file:
|
|
49
|
+
* //
|
|
50
|
+
* // go.property("my_value", 0);
|
|
51
|
+
* //
|
|
52
|
+
* // export default defineScript({
|
|
53
|
+
* // init(self) {
|
|
54
|
+
* // // do something with self.my_value which is now one
|
|
55
|
+
* // },
|
|
56
|
+
* // });
|
|
56
57
|
* ```
|
|
57
58
|
*/
|
|
58
59
|
function create(url: string | Hash | Url, position?: Vector3, rotation?: Quaternion, properties?: Record<string | number, unknown>, scale?: number | Vector3): Hash;
|
|
@@ -70,7 +71,7 @@ declare global {
|
|
|
70
71
|
*
|
|
71
72
|
* - `factory.STATUS_LOADED`
|
|
72
73
|
*/
|
|
73
|
-
function get_status(url?: string | Hash | Url):
|
|
74
|
+
function get_status(url?: string | Hash | Url): number & { readonly __brand: "factory.STATUS_UNLOADED" } | number & { readonly __brand: "factory.STATUS_LOADING" } | number & { readonly __brand: "factory.STATUS_LOADED" };
|
|
74
75
|
/**
|
|
75
76
|
* Resources are referenced by the factory component until the existing (parent) collection is destroyed or factory.unload is called.
|
|
76
77
|
* Calling this function when the factory is not marked as dynamic loading does nothing.
|
package/generated/gui.d.ts
CHANGED
|
@@ -561,7 +561,7 @@ declare global {
|
|
|
561
561
|
* });
|
|
562
562
|
* ```
|
|
563
563
|
*/
|
|
564
|
-
function animate(node: Opaque<"node">, property: string |
|
|
564
|
+
function animate(node: Opaque<"node">, property: string | number & { readonly __brand: "gui.PROP_POSITION" } | number & { readonly __brand: "gui.PROP_ROTATION" } | number & { readonly __brand: "gui.PROP_EULER" } | number & { readonly __brand: "gui.PROP_SCALE" } | number & { readonly __brand: "gui.PROP_COLOR" } | number & { readonly __brand: "gui.PROP_OUTLINE" } | number & { readonly __brand: "gui.PROP_SHADOW" } | number & { readonly __brand: "gui.PROP_SIZE" } | number & { readonly __brand: "gui.PROP_FILL_ANGLE" } | number & { readonly __brand: "gui.PROP_INNER_RADIUS" } | number & { readonly __brand: "gui.PROP_LEADING" } | number & { readonly __brand: "gui.PROP_TRACKING" } | number & { readonly __brand: "gui.PROP_SLICE9" }, to: number | Vector3 | Vector4 | Quaternion, easing: number & { readonly __brand: "gui.EASING_INBACK" } | number & { readonly __brand: "gui.EASING_INBOUNCE" } | number & { readonly __brand: "gui.EASING_INCIRC" } | number & { readonly __brand: "gui.EASING_INCUBIC" } | number & { readonly __brand: "gui.EASING_INELASTIC" } | number & { readonly __brand: "gui.EASING_INEXPO" } | number & { readonly __brand: "gui.EASING_INOUTBACK" } | number & { readonly __brand: "gui.EASING_INOUTBOUNCE" } | number & { readonly __brand: "gui.EASING_INOUTCIRC" } | number & { readonly __brand: "gui.EASING_INOUTCUBIC" } | number & { readonly __brand: "gui.EASING_INOUTELASTIC" } | number & { readonly __brand: "gui.EASING_INOUTEXPO" } | number & { readonly __brand: "gui.EASING_INOUTQUAD" } | number & { readonly __brand: "gui.EASING_INOUTQUART" } | number & { readonly __brand: "gui.EASING_INOUTQUINT" } | number & { readonly __brand: "gui.EASING_INOUTSINE" } | number & { readonly __brand: "gui.EASING_INQUAD" } | number & { readonly __brand: "gui.EASING_INQUART" } | number & { readonly __brand: "gui.EASING_INQUINT" } | number & { readonly __brand: "gui.EASING_INSINE" } | number & { readonly __brand: "gui.EASING_LINEAR" } | number & { readonly __brand: "gui.EASING_OUTBACK" } | number & { readonly __brand: "gui.EASING_OUTBOUNCE" } | number & { readonly __brand: "gui.EASING_OUTCIRC" } | number & { readonly __brand: "gui.EASING_OUTCUBIC" } | number & { readonly __brand: "gui.EASING_OUTELASTIC" } | number & { readonly __brand: "gui.EASING_OUTEXPO" } | number & { readonly __brand: "gui.EASING_OUTINBACK" } | number & { readonly __brand: "gui.EASING_OUTINBOUNCE" } | number & { readonly __brand: "gui.EASING_OUTINCIRC" } | number & { readonly __brand: "gui.EASING_OUTINCUBIC" } | number & { readonly __brand: "gui.EASING_OUTINELASTIC" } | number & { readonly __brand: "gui.EASING_OUTINEXPO" } | number & { readonly __brand: "gui.EASING_OUTINQUAD" } | number & { readonly __brand: "gui.EASING_OUTINQUART" } | number & { readonly __brand: "gui.EASING_OUTINQUINT" } | number & { readonly __brand: "gui.EASING_OUTINSINE" } | number & { readonly __brand: "gui.EASING_OUTQUAD" } | number & { readonly __brand: "gui.EASING_OUTQUART" } | number & { readonly __brand: "gui.EASING_OUTQUINT" } | number & { readonly __brand: "gui.EASING_OUTSINE" } | Vector, duration: number, delay?: number, complete_function?: (self: unknown, node: unknown) => void, playback?: number & { readonly __brand: "gui.PLAYBACK_ONCE_FORWARD" } | number & { readonly __brand: "gui.PLAYBACK_ONCE_BACKWARD" } | number & { readonly __brand: "gui.PLAYBACK_ONCE_PINGPONG" } | number & { readonly __brand: "gui.PLAYBACK_LOOP_FORWARD" } | number & { readonly __brand: "gui.PLAYBACK_LOOP_BACKWARD" } | number & { readonly __brand: "gui.PLAYBACK_LOOP_PINGPONG" }): void;
|
|
565
565
|
/**
|
|
566
566
|
* If one or more animations of the specified node is currently running (started by `gui.animate`), they will immediately be canceled.
|
|
567
567
|
*
|
|
@@ -614,7 +614,7 @@ declare global {
|
|
|
614
614
|
* gui.cancel_animations(node);
|
|
615
615
|
* ```
|
|
616
616
|
*/
|
|
617
|
-
function cancel_animations(node: Opaque<"node">, property?: string |
|
|
617
|
+
function cancel_animations(node: Opaque<"node">, property?: string | number & { readonly __brand: "gui.PROP_POSITION" } | number & { readonly __brand: "gui.PROP_ROTATION" } | number & { readonly __brand: "gui.PROP_EULER" } | number & { readonly __brand: "gui.PROP_SCALE" } | number & { readonly __brand: "gui.PROP_COLOR" } | number & { readonly __brand: "gui.PROP_OUTLINE" } | number & { readonly __brand: "gui.PROP_SHADOW" } | number & { readonly __brand: "gui.PROP_SIZE" } | number & { readonly __brand: "gui.PROP_FILL_ANGLE" } | number & { readonly __brand: "gui.PROP_INNER_RADIUS" } | number & { readonly __brand: "gui.PROP_LEADING" } | number & { readonly __brand: "gui.PROP_TRACKING" } | number & { readonly __brand: "gui.PROP_SLICE9" }): void;
|
|
618
618
|
/**
|
|
619
619
|
* Cancels any running flipbook animation on the specified node.
|
|
620
620
|
*
|
|
@@ -744,7 +744,7 @@ declare global {
|
|
|
744
744
|
* const node_position = gui.get(node, "position");
|
|
745
745
|
* ```
|
|
746
746
|
*/
|
|
747
|
-
function get(node: Opaque<"node">, property: string | Hash |
|
|
747
|
+
function get(node: Opaque<"node">, property: string | Hash | number & { readonly __brand: "gui.PROP_POSITION" } | number & { readonly __brand: "gui.PROP_ROTATION" } | number & { readonly __brand: "gui.PROP_EULER" } | number & { readonly __brand: "gui.PROP_SCALE" } | number & { readonly __brand: "gui.PROP_COLOR" } | number & { readonly __brand: "gui.PROP_OUTLINE" } | number & { readonly __brand: "gui.PROP_SHADOW" } | number & { readonly __brand: "gui.PROP_SIZE" } | number & { readonly __brand: "gui.PROP_FILL_ANGLE" } | number & { readonly __brand: "gui.PROP_INNER_RADIUS" } | number & { readonly __brand: "gui.PROP_LEADING" } | number & { readonly __brand: "gui.PROP_TRACKING" } | number & { readonly __brand: "gui.PROP_SLICE9" }, options?: { index?: number }): unknown;
|
|
748
748
|
/**
|
|
749
749
|
* Returns the adjust mode of a node.
|
|
750
750
|
* The adjust mode defines how the node will adjust itself to screen
|
|
@@ -759,7 +759,7 @@ declare global {
|
|
|
759
759
|
*
|
|
760
760
|
* - `gui.ADJUST_STRETCH`
|
|
761
761
|
*/
|
|
762
|
-
function get_adjust_mode(node: Opaque<"node">):
|
|
762
|
+
function get_adjust_mode(node: Opaque<"node">): number & { readonly __brand: "gui.ADJUST_FIT" } | number & { readonly __brand: "gui.ADJUST_ZOOM" } | number & { readonly __brand: "gui.ADJUST_STRETCH" };
|
|
763
763
|
/**
|
|
764
764
|
* gets the node alpha
|
|
765
765
|
*
|
|
@@ -784,7 +784,7 @@ declare global {
|
|
|
784
784
|
*
|
|
785
785
|
* - `gui.BLEND_SCREEN`
|
|
786
786
|
*/
|
|
787
|
-
function get_blend_mode(node: Opaque<"node">):
|
|
787
|
+
function get_blend_mode(node: Opaque<"node">): number & { readonly __brand: "gui.BLEND_ALPHA" } | number & { readonly __brand: "gui.BLEND_ADD" } | number & { readonly __brand: "gui.BLEND_ADD_ALPHA" } | number & { readonly __brand: "gui.BLEND_MULT" } | number & { readonly __brand: "gui.BLEND_SCREEN" };
|
|
788
788
|
/**
|
|
789
789
|
* If node is set as an inverted clipping node, it will clip anything inside as opposed to outside.
|
|
790
790
|
*
|
|
@@ -802,7 +802,7 @@ declare global {
|
|
|
802
802
|
*
|
|
803
803
|
* - `gui.CLIPPING_MODE_STENCIL`
|
|
804
804
|
*/
|
|
805
|
-
function get_clipping_mode(node: Opaque<"node">):
|
|
805
|
+
function get_clipping_mode(node: Opaque<"node">): number & { readonly __brand: "gui.CLIPPING_MODE_NONE" } | number & { readonly __brand: "gui.CLIPPING_MODE_STENCIL" };
|
|
806
806
|
/**
|
|
807
807
|
* If node is set as visible clipping node, it will be shown as well as clipping. Otherwise, it will only clip but not show visually.
|
|
808
808
|
*
|
|
@@ -1028,7 +1028,7 @@ declare global {
|
|
|
1028
1028
|
*
|
|
1029
1029
|
* - `gui.PIEBOUNDS_ELLIPSE`
|
|
1030
1030
|
*/
|
|
1031
|
-
function get_outer_bounds(node: Opaque<"node">):
|
|
1031
|
+
function get_outer_bounds(node: Opaque<"node">): number & { readonly __brand: "gui.PIEBOUNDS_RECTANGLE" } | number & { readonly __brand: "gui.PIEBOUNDS_ELLIPSE" };
|
|
1032
1032
|
/**
|
|
1033
1033
|
* Returns the outline color of the supplied node.
|
|
1034
1034
|
* See gui.get_color for info how vectors encode color values.
|
|
@@ -1084,7 +1084,7 @@ declare global {
|
|
|
1084
1084
|
*
|
|
1085
1085
|
* - `gui.PIVOT_NW`
|
|
1086
1086
|
*/
|
|
1087
|
-
function get_pivot(node: Opaque<"node">):
|
|
1087
|
+
function get_pivot(node: Opaque<"node">): number & { readonly __brand: "gui.PIVOT_CENTER" } | number & { readonly __brand: "gui.PIVOT_N" } | number & { readonly __brand: "gui.PIVOT_NE" } | number & { readonly __brand: "gui.PIVOT_E" } | number & { readonly __brand: "gui.PIVOT_SE" } | number & { readonly __brand: "gui.PIVOT_S" } | number & { readonly __brand: "gui.PIVOT_SW" } | number & { readonly __brand: "gui.PIVOT_W" } | number & { readonly __brand: "gui.PIVOT_NW" };
|
|
1088
1088
|
/**
|
|
1089
1089
|
* Returns the position of the supplied node.
|
|
1090
1090
|
*
|
|
@@ -1146,7 +1146,7 @@ declare global {
|
|
|
1146
1146
|
*
|
|
1147
1147
|
* - `gui.SIZE_MODE_AUTO`
|
|
1148
1148
|
*/
|
|
1149
|
-
function get_size_mode(node: Opaque<"node">):
|
|
1149
|
+
function get_size_mode(node: Opaque<"node">): number & { readonly __brand: "gui.SIZE_MODE_MANUAL" } | number & { readonly __brand: "gui.SIZE_MODE_AUTO" };
|
|
1150
1150
|
/**
|
|
1151
1151
|
* Returns the slice9 configuration values for the node.
|
|
1152
1152
|
*
|
|
@@ -1189,7 +1189,7 @@ declare global {
|
|
|
1189
1189
|
*
|
|
1190
1190
|
* @param node - node from which to get the type
|
|
1191
1191
|
*/
|
|
1192
|
-
function get_type(node: Opaque<"node">): LuaMultiReturn<[
|
|
1192
|
+
function get_type(node: Opaque<"node">): LuaMultiReturn<[number & { readonly __brand: "gui.TYPE_BOX" } | number & { readonly __brand: "gui.TYPE_TEXT" } | number & { readonly __brand: "gui.TYPE_PIE" } | number & { readonly __brand: "gui.TYPE_PARTICLEFX" } | number & { readonly __brand: "gui.TYPE_CUSTOM" }, number | undefined]>;
|
|
1193
1193
|
/**
|
|
1194
1194
|
* Returns `true` if a node is visible and `false` if it's not.
|
|
1195
1195
|
* Invisible nodes are not rendered.
|
|
@@ -1216,7 +1216,7 @@ declare global {
|
|
|
1216
1216
|
*
|
|
1217
1217
|
* - `gui.ANCHOR_RIGHT`
|
|
1218
1218
|
*/
|
|
1219
|
-
function get_xanchor(node: Opaque<"node">):
|
|
1219
|
+
function get_xanchor(node: Opaque<"node">): number & { readonly __brand: "gui.ANCHOR_NONE" } | number & { readonly __brand: "gui.ANCHOR_LEFT" } | number & { readonly __brand: "gui.ANCHOR_RIGHT" };
|
|
1220
1220
|
/**
|
|
1221
1221
|
* The y-anchor specifies how the node is moved when the game is run in a different resolution.
|
|
1222
1222
|
*
|
|
@@ -1229,7 +1229,7 @@ declare global {
|
|
|
1229
1229
|
*
|
|
1230
1230
|
* - `gui.ANCHOR_BOTTOM`
|
|
1231
1231
|
*/
|
|
1232
|
-
function get_yanchor(node: Opaque<"node">):
|
|
1232
|
+
function get_yanchor(node: Opaque<"node">): number & { readonly __brand: "gui.ANCHOR_NONE" } | number & { readonly __brand: "gui.ANCHOR_TOP" } | number & { readonly __brand: "gui.ANCHOR_BOTTOM" };
|
|
1233
1233
|
/**
|
|
1234
1234
|
* Hides the on-display touch keyboard on the device.
|
|
1235
1235
|
*/
|
|
@@ -1798,7 +1798,7 @@ declare global {
|
|
|
1798
1798
|
* resource.release(atlas_id);
|
|
1799
1799
|
* ```
|
|
1800
1800
|
*/
|
|
1801
|
-
function set(node: Opaque<"node"> | Url, property: string | Hash |
|
|
1801
|
+
function set(node: Opaque<"node"> | Url, property: string | Hash | number & { readonly __brand: "gui.PROP_POSITION" } | number & { readonly __brand: "gui.PROP_ROTATION" } | number & { readonly __brand: "gui.PROP_EULER" } | number & { readonly __brand: "gui.PROP_SCALE" } | number & { readonly __brand: "gui.PROP_COLOR" } | number & { readonly __brand: "gui.PROP_OUTLINE" } | number & { readonly __brand: "gui.PROP_SHADOW" } | number & { readonly __brand: "gui.PROP_SIZE" } | number & { readonly __brand: "gui.PROP_FILL_ANGLE" } | number & { readonly __brand: "gui.PROP_INNER_RADIUS" } | number & { readonly __brand: "gui.PROP_LEADING" } | number & { readonly __brand: "gui.PROP_TRACKING" } | number & { readonly __brand: "gui.PROP_SLICE9" }, value?: number | Vector4 | Vector3 | Quaternion, options?: { index?: number; key?: Hash }): void;
|
|
1802
1802
|
/**
|
|
1803
1803
|
* Sets the adjust mode on a node.
|
|
1804
1804
|
* The adjust mode defines how the node will adjust itself to screen
|
|
@@ -1813,7 +1813,7 @@ declare global {
|
|
|
1813
1813
|
*
|
|
1814
1814
|
* - `gui.ADJUST_STRETCH`
|
|
1815
1815
|
*/
|
|
1816
|
-
function set_adjust_mode(node: Opaque<"node">, adjust_mode:
|
|
1816
|
+
function set_adjust_mode(node: Opaque<"node">, adjust_mode: number & { readonly __brand: "gui.ADJUST_FIT" } | number & { readonly __brand: "gui.ADJUST_ZOOM" } | number & { readonly __brand: "gui.ADJUST_STRETCH" }): void;
|
|
1817
1817
|
/**
|
|
1818
1818
|
* sets the node alpha
|
|
1819
1819
|
*
|
|
@@ -1838,7 +1838,7 @@ declare global {
|
|
|
1838
1838
|
*
|
|
1839
1839
|
* - `gui.BLEND_SCREEN`
|
|
1840
1840
|
*/
|
|
1841
|
-
function set_blend_mode(node: Opaque<"node">, blend_mode:
|
|
1841
|
+
function set_blend_mode(node: Opaque<"node">, blend_mode: number & { readonly __brand: "gui.BLEND_ALPHA" } | number & { readonly __brand: "gui.BLEND_ADD" } | number & { readonly __brand: "gui.BLEND_ADD_ALPHA" } | number & { readonly __brand: "gui.BLEND_MULT" } | number & { readonly __brand: "gui.BLEND_SCREEN" }): void;
|
|
1842
1842
|
/**
|
|
1843
1843
|
* If node is set as an inverted clipping node, it will clip anything inside as opposed to outside.
|
|
1844
1844
|
*
|
|
@@ -1856,7 +1856,7 @@ declare global {
|
|
|
1856
1856
|
*
|
|
1857
1857
|
* - `gui.CLIPPING_MODE_STENCIL`
|
|
1858
1858
|
*/
|
|
1859
|
-
function set_clipping_mode(node: Opaque<"node">, clipping_mode:
|
|
1859
|
+
function set_clipping_mode(node: Opaque<"node">, clipping_mode: number & { readonly __brand: "gui.CLIPPING_MODE_NONE" } | number & { readonly __brand: "gui.CLIPPING_MODE_STENCIL" }): void;
|
|
1860
1860
|
/**
|
|
1861
1861
|
* If node is set as an visible clipping node, it will be shown as well as clipping. Otherwise, it will only clip but not show visually.
|
|
1862
1862
|
*
|
|
@@ -2024,7 +2024,7 @@ declare global {
|
|
|
2024
2024
|
*
|
|
2025
2025
|
* - `gui.PIEBOUNDS_ELLIPSE`
|
|
2026
2026
|
*/
|
|
2027
|
-
function set_outer_bounds(node: Opaque<"node">, bounds_mode:
|
|
2027
|
+
function set_outer_bounds(node: Opaque<"node">, bounds_mode: number & { readonly __brand: "gui.PIEBOUNDS_RECTANGLE" } | number & { readonly __brand: "gui.PIEBOUNDS_ELLIPSE" }): void;
|
|
2028
2028
|
/**
|
|
2029
2029
|
* Sets the outline color of the supplied node.
|
|
2030
2030
|
* See gui.set_color for info how vectors encode color values.
|
|
@@ -2079,7 +2079,7 @@ declare global {
|
|
|
2079
2079
|
*
|
|
2080
2080
|
* - `gui.PIVOT_NW`
|
|
2081
2081
|
*/
|
|
2082
|
-
function set_pivot(node: Opaque<"node">, pivot:
|
|
2082
|
+
function set_pivot(node: Opaque<"node">, pivot: number & { readonly __brand: "gui.PIVOT_CENTER" } | number & { readonly __brand: "gui.PIVOT_N" } | number & { readonly __brand: "gui.PIVOT_NE" } | number & { readonly __brand: "gui.PIVOT_E" } | number & { readonly __brand: "gui.PIVOT_SE" } | number & { readonly __brand: "gui.PIVOT_S" } | number & { readonly __brand: "gui.PIVOT_SW" } | number & { readonly __brand: "gui.PIVOT_W" } | number & { readonly __brand: "gui.PIVOT_NW" }): void;
|
|
2083
2083
|
/**
|
|
2084
2084
|
* Sets the position of the supplied node.
|
|
2085
2085
|
*
|
|
@@ -2118,7 +2118,7 @@ declare global {
|
|
|
2118
2118
|
*
|
|
2119
2119
|
* - `gui.SAFE_AREA_BOTH`
|
|
2120
2120
|
*/
|
|
2121
|
-
function set_safe_area_mode(mode:
|
|
2121
|
+
function set_safe_area_mode(mode: number & { readonly __brand: "gui.SAFE_AREA_NONE" } | number & { readonly __brand: "gui.SAFE_AREA_LONG" } | number & { readonly __brand: "gui.SAFE_AREA_SHORT" } | number & { readonly __brand: "gui.SAFE_AREA_BOTH" }): void;
|
|
2122
2122
|
/**
|
|
2123
2123
|
* Sets the scaling of the supplied node.
|
|
2124
2124
|
*
|
|
@@ -2164,7 +2164,7 @@ declare global {
|
|
|
2164
2164
|
*
|
|
2165
2165
|
* - `gui.SIZE_MODE_AUTO`
|
|
2166
2166
|
*/
|
|
2167
|
-
function set_size_mode(node: Opaque<"node">, size_mode:
|
|
2167
|
+
function set_size_mode(node: Opaque<"node">, size_mode: number & { readonly __brand: "gui.SIZE_MODE_MANUAL" } | number & { readonly __brand: "gui.SIZE_MODE_AUTO" }): void;
|
|
2168
2168
|
/**
|
|
2169
2169
|
* Set the slice9 configuration values for the node.
|
|
2170
2170
|
*
|
|
@@ -2284,7 +2284,7 @@ declare global {
|
|
|
2284
2284
|
*
|
|
2285
2285
|
* - `gui.ANCHOR_RIGHT`
|
|
2286
2286
|
*/
|
|
2287
|
-
function set_xanchor(node: Opaque<"node">, anchor:
|
|
2287
|
+
function set_xanchor(node: Opaque<"node">, anchor: number & { readonly __brand: "gui.ANCHOR_NONE" } | number & { readonly __brand: "gui.ANCHOR_LEFT" } | number & { readonly __brand: "gui.ANCHOR_RIGHT" }): void;
|
|
2288
2288
|
/**
|
|
2289
2289
|
* The y-anchor specifies how the node is moved when the game is run in a different resolution.
|
|
2290
2290
|
*
|
|
@@ -2297,7 +2297,7 @@ declare global {
|
|
|
2297
2297
|
*
|
|
2298
2298
|
* - `gui.ANCHOR_BOTTOM`
|
|
2299
2299
|
*/
|
|
2300
|
-
function set_yanchor(node: Opaque<"node">, anchor:
|
|
2300
|
+
function set_yanchor(node: Opaque<"node">, anchor: number & { readonly __brand: "gui.ANCHOR_NONE" } | number & { readonly __brand: "gui.ANCHOR_TOP" } | number & { readonly __brand: "gui.ANCHOR_BOTTOM" }): void;
|
|
2301
2301
|
/**
|
|
2302
2302
|
* Shows the on-display touch keyboard.
|
|
2303
2303
|
* The specified type of keyboard is displayed if it is available on
|
|
@@ -2315,7 +2315,7 @@ declare global {
|
|
|
2315
2315
|
* - `gui.KEYBOARD_TYPE_PASSWORD`
|
|
2316
2316
|
* @param autoclose - if the keyboard should automatically close when clicking outside
|
|
2317
2317
|
*/
|
|
2318
|
-
function show_keyboard(type:
|
|
2318
|
+
function show_keyboard(type: number & { readonly __brand: "gui.KEYBOARD_TYPE_DEFAULT" } | number & { readonly __brand: "gui.KEYBOARD_TYPE_EMAIL" } | number & { readonly __brand: "gui.KEYBOARD_TYPE_NUMBER_PAD" } | number & { readonly __brand: "gui.KEYBOARD_TYPE_PASSWORD" }, autoclose: boolean): void;
|
|
2319
2319
|
/**
|
|
2320
2320
|
* Stops the particle fx for a gui node
|
|
2321
2321
|
*
|
|
@@ -19,8 +19,6 @@ import "../go";
|
|
|
19
19
|
import "../graphics";
|
|
20
20
|
import "../html5";
|
|
21
21
|
import "../http";
|
|
22
|
-
import "../iac";
|
|
23
|
-
import "../iap";
|
|
24
22
|
import "../image";
|
|
25
23
|
import "../json";
|
|
26
24
|
import "../label";
|
|
@@ -31,7 +29,6 @@ import "../msg";
|
|
|
31
29
|
import "../particlefx";
|
|
32
30
|
import "../physics";
|
|
33
31
|
import "../profiler";
|
|
34
|
-
import "../push";
|
|
35
32
|
import "../resource";
|
|
36
33
|
import "../socket";
|
|
37
34
|
import "../sound";
|
|
@@ -41,7 +38,6 @@ import "../tilemap";
|
|
|
41
38
|
import "../timer";
|
|
42
39
|
import "../types";
|
|
43
40
|
import "../vmath";
|
|
44
|
-
import "../webview";
|
|
45
41
|
import "../window";
|
|
46
42
|
import "../zlib";
|
|
47
43
|
import "../../src/custom-messages";
|
|
@@ -19,8 +19,6 @@ import "../go";
|
|
|
19
19
|
import "../graphics";
|
|
20
20
|
import "../html5";
|
|
21
21
|
import "../http";
|
|
22
|
-
import "../iac";
|
|
23
|
-
import "../iap";
|
|
24
22
|
import "../image";
|
|
25
23
|
import "../json";
|
|
26
24
|
import "../label";
|
|
@@ -31,7 +29,6 @@ import "../msg";
|
|
|
31
29
|
import "../particlefx";
|
|
32
30
|
import "../physics";
|
|
33
31
|
import "../profiler";
|
|
34
|
-
import "../push";
|
|
35
32
|
import "../resource";
|
|
36
33
|
import "../socket";
|
|
37
34
|
import "../sound";
|
|
@@ -41,7 +38,6 @@ import "../tilemap";
|
|
|
41
38
|
import "../timer";
|
|
42
39
|
import "../types";
|
|
43
40
|
import "../vmath";
|
|
44
|
-
import "../webview";
|
|
45
41
|
import "../window";
|
|
46
42
|
import "../zlib";
|
|
47
43
|
import "../../src/custom-messages";
|
|
@@ -49,6 +45,7 @@ import "../../src/engine-globals";
|
|
|
49
45
|
import "../../src/go-overloads";
|
|
50
46
|
import "../../src/message-guard";
|
|
51
47
|
import "../../src/msg-overloads";
|
|
48
|
+
import "../../src/render-overloads";
|
|
52
49
|
import "../../src/scene-addresses";
|
|
53
50
|
import "../../src/vmath-overloads";
|
|
54
51
|
import "../../src/window-event-guard";
|
|
@@ -19,8 +19,6 @@ import "../go";
|
|
|
19
19
|
import "../graphics";
|
|
20
20
|
import "../html5";
|
|
21
21
|
import "../http";
|
|
22
|
-
import "../iac";
|
|
23
|
-
import "../iap";
|
|
24
22
|
import "../image";
|
|
25
23
|
import "../json";
|
|
26
24
|
import "../label";
|
|
@@ -31,7 +29,6 @@ import "../msg";
|
|
|
31
29
|
import "../particlefx";
|
|
32
30
|
import "../physics";
|
|
33
31
|
import "../profiler";
|
|
34
|
-
import "../push";
|
|
35
32
|
import "../resource";
|
|
36
33
|
import "../socket";
|
|
37
34
|
import "../sound";
|
|
@@ -41,7 +38,6 @@ import "../tilemap";
|
|
|
41
38
|
import "../timer";
|
|
42
39
|
import "../types";
|
|
43
40
|
import "../vmath";
|
|
44
|
-
import "../webview";
|
|
45
41
|
import "../window";
|
|
46
42
|
import "../zlib";
|
|
47
43
|
import "../../src/custom-messages";
|
package/generated/model.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/** @noSelfInFile */
|
|
2
|
-
import type { Hash,
|
|
2
|
+
import type { Hash, Url, Vector3 } from "../src/core-types";
|
|
3
3
|
|
|
4
4
|
declare global {
|
|
5
5
|
/**
|
|
@@ -173,7 +173,7 @@ declare global {
|
|
|
173
173
|
* });
|
|
174
174
|
* ```
|
|
175
175
|
*/
|
|
176
|
-
function play_anim(url: string | Hash | Url, anim_id: string | Hash, playback:
|
|
176
|
+
function play_anim(url: string | Hash | Url, anim_id: string | Hash, playback: number & { readonly __brand: "go.PLAYBACK_ONCE_FORWARD" } | number & { readonly __brand: "go.PLAYBACK_ONCE_BACKWARD" } | number & { readonly __brand: "go.PLAYBACK_ONCE_PINGPONG" } | number & { readonly __brand: "go.PLAYBACK_LOOP_FORWARD" } | number & { readonly __brand: "go.PLAYBACK_LOOP_BACKWARD" } | number & { readonly __brand: "go.PLAYBACK_LOOP_PINGPONG" }, play_properties?: { blend_duration?: number; offset?: number; playback_rate?: number }, complete_function?: (self: unknown, message_id: unknown, message: unknown, sender: unknown) => void): void;
|
|
177
177
|
/**
|
|
178
178
|
* Resets a shader constant for a model component.
|
|
179
179
|
* The constant must be defined in the material assigned to the model.
|
package/generated/profiler.d.ts
CHANGED
|
@@ -1,6 +1,4 @@
|
|
|
1
1
|
/** @noSelfInFile */
|
|
2
|
-
import type { Opaque } from "../src/core-types";
|
|
3
|
-
|
|
4
2
|
declare global {
|
|
5
3
|
/**
|
|
6
4
|
* Functions for getting profiling data in runtime.
|
|
@@ -175,7 +173,7 @@ declare global {
|
|
|
175
173
|
* }
|
|
176
174
|
* ```
|
|
177
175
|
*/
|
|
178
|
-
function set_ui_mode(mode:
|
|
176
|
+
function set_ui_mode(mode: number & { readonly __brand: "profiler.MODE_RUN" } | number & { readonly __brand: "profiler.MODE_PAUSE" } | number & { readonly __brand: "profiler.MODE_SHOW_PEAK_FRAME" } | number & { readonly __brand: "profiler.MODE_RECORD" }): void;
|
|
179
177
|
/**
|
|
180
178
|
* Set the on-screen profile view mode - minimized or expanded
|
|
181
179
|
*
|
|
@@ -190,7 +188,7 @@ declare global {
|
|
|
190
188
|
* profiler.set_ui_view_mode(profiler.VIEW_MODE_MINIMIZED);
|
|
191
189
|
* ```
|
|
192
190
|
*/
|
|
193
|
-
function set_ui_view_mode(mode:
|
|
191
|
+
function set_ui_view_mode(mode: number & { readonly __brand: "profiler.VIEW_MODE_FULL" } | number & { readonly __brand: "profiler.VIEW_MODE_MINIMIZED" }): void;
|
|
194
192
|
/**
|
|
195
193
|
* Shows or hides the time the engine waits for vsync in the on-screen profiler
|
|
196
194
|
* Each frame the engine waits for vsync and depending on your vsync settings and how much time
|