diff --git a/harness/flattened-library-tests/gradle/wrapper/gradle-wrapper.properties b/harness/flattened-library-tests/gradle/wrapper/gradle-wrapper.properties index ed4c299adb..48b43d3506 100644 --- a/harness/flattened-library-tests/gradle/wrapper/gradle-wrapper.properties +++ b/harness/flattened-library-tests/gradle/wrapper/gradle-wrapper.properties @@ -1,6 +1,6 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-8.13-all.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-9.0.0-all.zip networkTimeout=10000 validateDistributionUrl=true zipStoreBase=GRADLE_USER_HOME diff --git a/harness/fqname-library-tests/gradle/wrapper/gradle-wrapper.properties b/harness/fqname-library-tests/gradle/wrapper/gradle-wrapper.properties index ed4c299adb..48b43d3506 100644 --- a/harness/fqname-library-tests/gradle/wrapper/gradle-wrapper.properties +++ b/harness/fqname-library-tests/gradle/wrapper/gradle-wrapper.properties @@ -1,6 +1,6 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-8.13-all.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-9.0.0-all.zip networkTimeout=10000 validateDistributionUrl=true zipStoreBase=GRADLE_USER_HOME diff --git a/harness/hierarchical-library-tests/gradle/wrapper/gradle-wrapper.properties b/harness/hierarchical-library-tests/gradle/wrapper/gradle-wrapper.properties index ed4c299adb..48b43d3506 100644 --- a/harness/hierarchical-library-tests/gradle/wrapper/gradle-wrapper.properties +++ b/harness/hierarchical-library-tests/gradle/wrapper/gradle-wrapper.properties @@ -1,6 +1,6 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-8.13-all.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-9.0.0-all.zip networkTimeout=10000 validateDistributionUrl=true zipStoreBase=GRADLE_USER_HOME diff --git a/harness/tests/gradle/wrapper/gradle-wrapper.properties b/harness/tests/gradle/wrapper/gradle-wrapper.properties index ed4c299adb..48b43d3506 100644 --- a/harness/tests/gradle/wrapper/gradle-wrapper.properties +++ b/harness/tests/gradle/wrapper/gradle-wrapper.properties @@ -1,6 +1,6 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-8.13-all.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-9.0.0-all.zip networkTimeout=10000 validateDistributionUrl=true zipStoreBase=GRADLE_USER_HOME diff --git a/harness/tests/scripts/godot/tests/CoreTypesIdentityTest.gdj b/harness/tests/scripts/godot/tests/CoreTypesIdentityTest.gdj index c542b7be20..a8dfc940d7 100644 --- a/harness/tests/scripts/godot/tests/CoreTypesIdentityTest.gdj +++ b/harness/tests/scripts/godot/tests/CoreTypesIdentityTest.gdj @@ -33,10 +33,10 @@ functions = [ basis, color, plane, - quat, rect2, - transform, transform2_d, vector2, - vector3 + vector3, + quat, + transform ] \ No newline at end of file diff --git a/harness/tests/scripts/godot/tests/Invocation.gdj b/harness/tests/scripts/godot/tests/Invocation.gdj index fdb7977afc..b6ae0b42f1 100644 --- a/harness/tests/scripts/godot/tests/Invocation.gdj +++ b/harness/tests/scripts/godot/tests/Invocation.gdj @@ -7,160 +7,160 @@ relativeSourcePath = src/main/kotlin/godot/tests/Invocation.kt baseType = Node3D supertypes = [ godot.api.Node3D, - godot.api.Node, - godot.api.Object, - godot.core.KtObject, - godot.common.interop.NativeWrapper, - godot.common.interop.NativePointer, - kotlin.Any + godot.api.Node, + godot.api.Object, + godot.core.KtObject, + godot.common.interop.NativeWrapper, + godot.common.interop.NativePointer, + kotlin.Any ] signals = [ ] properties = [ button, - enum_list, - vector_list, - enum_list_mutable, - register_object, - register_object_nullable, - register_object_nullable_pre_init, - register_object_non_nullable_pre_init, - vector, - x, - y, - z, - custom_name, - invocation, - enum_test, - resource_test, - jvm_id, - test_array_any, - nav_meshes, - nullable_array, - any_to_any_dictionary, - nav_meshes_dictionary, - nullable_dictionary, - color, - rid, - packed_byte_array, - packed_int32_array, - packed_float64_array, - packed_color_array, - packed_string_array, - packed_vector2_array, - packed_vector3_array, - p1, - p1_1, - p2, - p3, - p4, - p5, - p6, - p7, - p8, - p9, - p10, - p11, - p12, - p13, - p14, - p15, - p16, - p17, - stringtemplation, - test_string, - ascii_string, - utf8_string + enum_list, + vector_list, + enum_list_mutable, + register_object, + register_object_nullable, + register_object_nullable_pre_init, + register_object_non_nullable_pre_init, + vector, + x, + y, + z, + custom_name, + invocation, + enum_test, + resource_test, + jvm_id, + test_array_any, + nav_meshes, + nullable_array, + any_to_any_dictionary, + nav_meshes_dictionary, + nullable_dictionary, + color, + rid, + packed_byte_array, + packed_int32_array, + packed_float64_array, + packed_color_array, + packed_string_array, + packed_vector2_array, + packed_vector3_array, + p1, + p1_1, + p2, + p3, + p4, + p5, + p6, + p7, + p8, + p9, + p10, + p11, + p12, + p13, + p14, + p15, + p16, + p17, + stringtemplation, + test_string, + ascii_string, + utf8_string ] functions = [ int_value, - long_value, - float_value, - double_value, - boolean_value, - string_value, - int_addition, - init_nullables, - _enter_tree, - _ready, - get_rid_id, - get_nav_mesh_rid, - append_to_any_dict, - remove_from_any_dict, - get_from_any_dict, - any_dict_size, - append_to_string_nav_mesh_dict, - remove_from_string_nav_mesh_dict, - get_from_string_nav_mesh_dict, - string_nav_mesh_dict_size, - append_to_string_nav_mesh_nullable_dict, - remove_from_string_nav_mesh_nullable_dict, - string_nav_mesh_nullable_dict_size, - append_nullable_standard_nav_mesh, - append_nullable_nav_mesh, - remove_nullable_nav_mesh, - remove_nullable_nav_mesh_with_index, - nullable_nav_meshes_size, - append_standard_nav_mesh, - append_nav_mesh, - remove_nav_mesh, - remove_nav_mesh_with_index, - get_nav_mesh_from_array, - nav_meshes_size, - append_any_to_array, - remove_any_from_array, - get_any_from_array, - array_any_size, - count_namesh_instance, - get_nav_mesh_count, - parent_is_node3_d, - is_object_node3_d, - other_jvm_id, - has_camera_node, - add_byte_to_packed_array, - add_byte_array_to_packed_array, - delete_byte_from_packed_array, - get_byte_from_packed_array, - set_byte_in_packed_array, - resize_byte_packed_array, - add_color_to_packed_array, - add_color_array_to_packed_array, - delete_color_from_packed_array, - get_color_from_packed_array, - set_color_in_packed_array, - resize_color_packed_array, - add_int_to_packed_array, - add_int_array_to_packed_array, - delete_int_from_packed_array, - get_int_from_packed_array, - set_int_in_packed_array, - resize_int_packed_array, - add_real_to_packed_array, - add_real_array_to_packed_array, - read_string_from_byte_array, - delete_real_from_packed_array, - get_real_from_packed_array, - set_real_in_packed_array, - resize_real_packed_array, - add_string_to_packed_array, - add_string_array_to_packed_array, - delete_string_from_packed_array, - get_string_from_packed_array, - set_string_in_packed_array, - resize_string_packed_array, - add_vector2_to_packed_array, - add_vector2_array_to_packed_array, - delete_vector2_from_packed_array, - get_vector2_from_packed_array, - set_vector2_in_packed_array, - resize_vector2_packed_array, - add_vector3_to_packed_array, - add_vector3_array_to_packed_array, - delete_vector3_from_packed_array, - get_vector3_from_packed_array, - set_vector3_in_packed_array, - resize_vector3_packed_array, - is_sent_xr_same_instance_as_jvm_singleton, - create_variant_array_of_user_type -] + long_value, + float_value, + double_value, + boolean_value, + string_value, + int_addition, + init_nullables, + _enter_tree, + _ready, + get_rid_id, + get_nav_mesh_rid, + append_to_any_dict, + remove_from_any_dict, + get_from_any_dict, + any_dict_size, + append_to_string_nav_mesh_dict, + remove_from_string_nav_mesh_dict, + get_from_string_nav_mesh_dict, + string_nav_mesh_dict_size, + append_to_string_nav_mesh_nullable_dict, + remove_from_string_nav_mesh_nullable_dict, + string_nav_mesh_nullable_dict_size, + append_nullable_standard_nav_mesh, + append_nullable_nav_mesh, + remove_nullable_nav_mesh, + remove_nullable_nav_mesh_with_index, + nullable_nav_meshes_size, + append_standard_nav_mesh, + append_nav_mesh, + remove_nav_mesh, + remove_nav_mesh_with_index, + get_nav_mesh_from_array, + nav_meshes_size, + append_any_to_array, + remove_any_from_array, + get_any_from_array, + array_any_size, + count_namesh_instance, + get_nav_mesh_count, + parent_is_node3_d, + is_object_node3_d, + other_jvm_id, + has_camera_node, + add_byte_to_packed_array, + add_byte_array_to_packed_array, + delete_byte_from_packed_array, + get_byte_from_packed_array, + set_byte_in_packed_array, + resize_byte_packed_array, + add_color_to_packed_array, + add_color_array_to_packed_array, + delete_color_from_packed_array, + get_color_from_packed_array, + set_color_in_packed_array, + resize_color_packed_array, + add_int_to_packed_array, + add_int_array_to_packed_array, + delete_int_from_packed_array, + get_int_from_packed_array, + set_int_in_packed_array, + resize_int_packed_array, + add_real_to_packed_array, + add_real_array_to_packed_array, + read_string_from_byte_array, + delete_real_from_packed_array, + get_real_from_packed_array, + set_real_in_packed_array, + resize_real_packed_array, + add_string_to_packed_array, + add_string_array_to_packed_array, + delete_string_from_packed_array, + get_string_from_packed_array, + set_string_in_packed_array, + resize_string_packed_array, + add_vector2_to_packed_array, + add_vector2_array_to_packed_array, + delete_vector2_from_packed_array, + get_vector2_from_packed_array, + set_vector2_in_packed_array, + resize_vector2_packed_array, + add_vector3_to_packed_array, + add_vector3_array_to_packed_array, + delete_vector3_from_packed_array, + get_vector3_from_packed_array, + set_vector3_in_packed_array, + resize_vector3_packed_array, + is_sent_xr_same_instance_as_jvm_singleton, + create_variant_array_of_user_type +] \ No newline at end of file diff --git a/harness/tests/scripts/godot/tests/JavaTestClass.gdj b/harness/tests/scripts/godot/tests/JavaTestClass.gdj index 655a8a716a..39cc387528 100644 --- a/harness/tests/scripts/godot/tests/JavaTestClass.gdj +++ b/harness/tests/scripts/godot/tests/JavaTestClass.gdj @@ -32,8 +32,8 @@ properties = [ dictionary ] functions = [ - _ready, - greeting, + greeting, + _ready, connect_and_trigger_signal, signal_callback ] \ No newline at end of file diff --git a/harness/tests/scripts/godot/tests/packedarray/PackedArrayTest.gdj b/harness/tests/scripts/godot/tests/packedarray/PackedArrayTest.gdj index 07fa993352..1cd0293fda 100644 --- a/harness/tests/scripts/godot/tests/packedarray/PackedArrayTest.gdj +++ b/harness/tests/scripts/godot/tests/packedarray/PackedArrayTest.gdj @@ -25,9 +25,15 @@ functions = [ convert_long_array, convert_float_array, convert_double_array, + convert_vector2_array, + convert_vector3_array, + convert_vector4_array, get_byte_array_value, get_int_array_value, get_long_array_value, get_float_array_value, - get_double_array_value + get_double_array_value, + get_vector2_array_value, + get_vector3_array_value, + get_vector4_array_value ] \ No newline at end of file diff --git a/harness/tests/src/main/kotlin/godot/tests/inheritance/ClassInheritanceChild.kt b/harness/tests/src/main/kotlin/godot/tests/inheritance/ClassInheritanceChild.kt index c15a092089..c5d1fed657 100644 --- a/harness/tests/src/main/kotlin/godot/tests/inheritance/ClassInheritanceChild.kt +++ b/harness/tests/src/main/kotlin/godot/tests/inheritance/ClassInheritanceChild.kt @@ -27,9 +27,10 @@ class ClassInheritanceChild : ClassInheritanceParent() { childOpenFunctionHasBeenCalled = true } - @RegisterFunction - override fun _notification() = godotNotification { - GD.print("Called ClassInheritanceChild::_notification on $this with $it") - notificationCallBitFlag += notificationCallBitFlag or 2 - } + // TODO: enable once class instantiation issue in the registration phase is fixed +// @RegisterFunction +// override fun _notification() = godotNotification { +// GD.print("Called ClassInheritanceChild::_notification on $this with $it") +// notificationCallBitFlag += notificationCallBitFlag or 2 +// } } diff --git a/harness/tests/src/main/kotlin/godot/tests/inheritance/ClassInheritanceParent.kt b/harness/tests/src/main/kotlin/godot/tests/inheritance/ClassInheritanceParent.kt index 72674df2fb..d8a8ba29ca 100644 --- a/harness/tests/src/main/kotlin/godot/tests/inheritance/ClassInheritanceParent.kt +++ b/harness/tests/src/main/kotlin/godot/tests/inheritance/ClassInheritanceParent.kt @@ -48,10 +48,11 @@ open class ClassInheritanceParent : Node() { @RegisterProperty var notificationCallBitFlag = 0 - @RegisterFunction - override fun _notification(): GodotNotification = godotNotification { - GD.print("Called ClassInheritanceParent::_notification on $this with $it") - notificationCallBitFlag = notificationCallBitFlag or 1 - GD.print(notificationCallBitFlag) - } + // TODO: enable once class instantiation issue in the registration phase is fixed +// @RegisterFunction +// override fun _notification(): GodotNotification = godotNotification { +// GD.print("Called ClassInheritanceParent::_notification on $this with $it") +// notificationCallBitFlag = notificationCallBitFlag or 1 +// GD.print(notificationCallBitFlag) +// } } diff --git a/kt/api-generator/src/main/kotlin/godot/codegen/generation/rule/FileRule.kt b/kt/api-generator/src/main/kotlin/godot/codegen/generation/rule/FileRule.kt index 7f12d8e0a0..36f3d5b6fe 100644 --- a/kt/api-generator/src/main/kotlin/godot/codegen/generation/rule/FileRule.kt +++ b/kt/api-generator/src/main/kotlin/godot/codegen/generation/rule/FileRule.kt @@ -55,8 +55,8 @@ class WarningRule() : GodotApiRule() { } class StaticRule : GodotApiRule() { - override fun apply(fileTask: FileTask, context: GenerationContext) = configure(fileTask.builder) { - for (classTask in fileTask.classes) { + override fun apply(task: FileTask, context: GenerationContext) = configure(task.builder) { + for (classTask in task.classes) { for (method in classTask.enrichedStaticMethods) { method.builder.addAnnotation(JvmStatic::class) } @@ -114,7 +114,7 @@ class DocumentationRule : GodotApiRule() { private val codeBlockRegex = Regex("""```[\s\S]*?```""") private val doubleSkipRegex = Regex("(?, - @JsonProperty("builtin_class_member_offsets") val builtinClassMemberOffsets: List, - @JsonProperty("global_constants") val globalConstants: List, - @JsonProperty("global_enums") val globalEnums: List, - @JsonProperty("utility_functions") val utilityFunctions: List, - @JsonProperty("builtin_classes") val builtinClasses: List, - @JsonProperty("classes") val classes: List, - @JsonProperty("singletons") val singletons: List, - @JsonProperty("native_structures") val nativeStructures: List + @param:JsonProperty("header") val header: Header, + @param:JsonProperty("builtin_class_sizes") val builtinClassSizes: List, + @param:JsonProperty("builtin_class_member_offsets") val builtinClassMemberOffsets: List, + @param:JsonProperty("global_constants") val globalConstants: List, + @param:JsonProperty("global_enums") val globalEnums: List, + @param:JsonProperty("utility_functions") val utilityFunctions: List, + @param:JsonProperty("builtin_classes") val builtinClasses: List, + @param:JsonProperty("classes") val classes: List, + @param:JsonProperty("singletons") val singletons: List, + @param:JsonProperty("native_structures") val nativeStructures: List ) diff --git a/kt/api-generator/src/main/kotlin/godot/codegen/models/Argument.kt b/kt/api-generator/src/main/kotlin/godot/codegen/models/Argument.kt index fe4800ea71..35580653f3 100644 --- a/kt/api-generator/src/main/kotlin/godot/codegen/models/Argument.kt +++ b/kt/api-generator/src/main/kotlin/godot/codegen/models/Argument.kt @@ -4,8 +4,8 @@ import com.fasterxml.jackson.annotation.JsonCreator import com.fasterxml.jackson.annotation.JsonProperty data class Argument @JsonCreator constructor( - @JsonProperty("name") val name: String, - @JsonProperty("type") val type: String, - @JsonProperty("meta") val meta: String?, - @JsonProperty("default_value") val defaultValue: String? + @param:JsonProperty("name") val name: String, + @param:JsonProperty("type") val type: String, + @param:JsonProperty("meta") val meta: String?, + @param:JsonProperty("default_value") val defaultValue: String? ) diff --git a/kt/api-generator/src/main/kotlin/godot/codegen/models/BuiltinClass.kt b/kt/api-generator/src/main/kotlin/godot/codegen/models/BuiltinClass.kt index 4ea07f3896..b83b1d462f 100644 --- a/kt/api-generator/src/main/kotlin/godot/codegen/models/BuiltinClass.kt +++ b/kt/api-generator/src/main/kotlin/godot/codegen/models/BuiltinClass.kt @@ -4,16 +4,16 @@ import com.fasterxml.jackson.annotation.JsonCreator import com.fasterxml.jackson.annotation.JsonProperty data class BuiltinClass @JsonCreator constructor( - @JsonProperty("name") val name: String, - @JsonProperty("is_keyed") val isKeyed: Boolean, - @JsonProperty("operators") val operators: List, - @JsonProperty("constructors") val constructors: List, - @JsonProperty("has_destructor") val hasDestructor: Boolean, - @JsonProperty("methods") val methods: List?, - @JsonProperty("members") val members: List?, - @JsonProperty("constants") val constants: List?, - @JsonProperty("enums") val enums: List?, - @JsonProperty("indexing_return_type") val indexingReturnType: String?, - @JsonProperty("description") val description: String?, - @JsonProperty("brief_description") val briefDescription: String? + @param:JsonProperty("name") val name: String, + @param:JsonProperty("is_keyed") val isKeyed: Boolean, + @param:JsonProperty("operators") val operators: List, + @param:JsonProperty("constructors") val constructors: List, + @param:JsonProperty("has_destructor") val hasDestructor: Boolean, + @param:JsonProperty("methods") val methods: List?, + @param:JsonProperty("members") val members: List?, + @param:JsonProperty("constants") val constants: List?, + @param:JsonProperty("enums") val enums: List?, + @param:JsonProperty("indexing_return_type") val indexingReturnType: String?, + @param:JsonProperty("description") val description: String?, + @param:JsonProperty("brief_description") val briefDescription: String? ) diff --git a/kt/api-generator/src/main/kotlin/godot/codegen/models/BuiltinClassMemberOffsets.kt b/kt/api-generator/src/main/kotlin/godot/codegen/models/BuiltinClassMemberOffsets.kt index b9eb1568b9..6557144d7f 100644 --- a/kt/api-generator/src/main/kotlin/godot/codegen/models/BuiltinClassMemberOffsets.kt +++ b/kt/api-generator/src/main/kotlin/godot/codegen/models/BuiltinClassMemberOffsets.kt @@ -4,6 +4,6 @@ import com.fasterxml.jackson.annotation.JsonCreator import com.fasterxml.jackson.annotation.JsonProperty data class BuiltinClassMemberOffsets @JsonCreator constructor( - @JsonProperty("build_configuration") val buildConfiguration: String, - @JsonProperty("classes") val classes: List + @param:JsonProperty("build_configuration") val buildConfiguration: String, + @param:JsonProperty("classes") val classes: List ) diff --git a/kt/api-generator/src/main/kotlin/godot/codegen/models/BuiltinClassSizes.kt b/kt/api-generator/src/main/kotlin/godot/codegen/models/BuiltinClassSizes.kt index 49a8a04d82..b7b835175a 100644 --- a/kt/api-generator/src/main/kotlin/godot/codegen/models/BuiltinClassSizes.kt +++ b/kt/api-generator/src/main/kotlin/godot/codegen/models/BuiltinClassSizes.kt @@ -4,6 +4,6 @@ import com.fasterxml.jackson.annotation.JsonCreator import com.fasterxml.jackson.annotation.JsonProperty data class BuiltinClassSizes @JsonCreator constructor( - @JsonProperty("build_configuration") val buildConfiguration: String, - @JsonProperty("sizes") val sizes: List + @param:JsonProperty("build_configuration") val buildConfiguration: String, + @param:JsonProperty("sizes") val sizes: List ) diff --git a/kt/api-generator/src/main/kotlin/godot/codegen/models/Class.kt b/kt/api-generator/src/main/kotlin/godot/codegen/models/Class.kt index d31b35d860..60fae50736 100644 --- a/kt/api-generator/src/main/kotlin/godot/codegen/models/Class.kt +++ b/kt/api-generator/src/main/kotlin/godot/codegen/models/Class.kt @@ -4,18 +4,18 @@ import com.fasterxml.jackson.annotation.JsonCreator import com.fasterxml.jackson.annotation.JsonProperty data class Class @JsonCreator constructor( - @JsonProperty("name") val name: String, - @JsonProperty("is_refcounted") val isRefCounted: Boolean, - @JsonProperty("is_instantiable") val isInstantiable: Boolean, - @JsonProperty("inherits") val inherits: String?, - @JsonProperty("api_type") val apiType: String, - @JsonProperty("enums") val enums: List?, - @JsonProperty("methods") val methods: List?, - @JsonProperty("properties") val properties: List?, - @JsonProperty("constants") val constants: List?, - @JsonProperty("signals") val signals: List?, - @JsonProperty("description") val description: String?, - @JsonProperty("brief_description") val briefDescription: String? + @param:JsonProperty("name") val name: String, + @param:JsonProperty("is_refcounted") val isRefCounted: Boolean, + @param:JsonProperty("is_instantiable") val isInstantiable: Boolean, + @param:JsonProperty("inherits") val inherits: String?, + @param:JsonProperty("api_type") val apiType: String, + @param:JsonProperty("enums") val enums: List?, + @param:JsonProperty("methods") val methods: List?, + @param:JsonProperty("properties") val properties: List?, + @param:JsonProperty("constants") val constants: List?, + @param:JsonProperty("signals") val signals: List?, + @param:JsonProperty("description") val description: String?, + @param:JsonProperty("brief_description") val briefDescription: String? ) { fun copy(newName: String) = Class( newName, diff --git a/kt/api-generator/src/main/kotlin/godot/codegen/models/ClassMemberOffsets.kt b/kt/api-generator/src/main/kotlin/godot/codegen/models/ClassMemberOffsets.kt index 17e3bdbc77..941b12c7f5 100644 --- a/kt/api-generator/src/main/kotlin/godot/codegen/models/ClassMemberOffsets.kt +++ b/kt/api-generator/src/main/kotlin/godot/codegen/models/ClassMemberOffsets.kt @@ -3,6 +3,6 @@ package godot.codegen.models import com.fasterxml.jackson.annotation.JsonProperty data class ClassMemberOffsets( - @JsonProperty("name") val name: String, - @JsonProperty("members") val members: List + @param:JsonProperty("name") val name: String, + @param:JsonProperty("members") val members: List ) diff --git a/kt/api-generator/src/main/kotlin/godot/codegen/models/Constant.kt b/kt/api-generator/src/main/kotlin/godot/codegen/models/Constant.kt index 4a990833bb..2ba17e927f 100644 --- a/kt/api-generator/src/main/kotlin/godot/codegen/models/Constant.kt +++ b/kt/api-generator/src/main/kotlin/godot/codegen/models/Constant.kt @@ -4,9 +4,9 @@ import com.fasterxml.jackson.annotation.JsonCreator import com.fasterxml.jackson.annotation.JsonProperty data class Constant @JsonCreator constructor( - @JsonProperty("name") val name: String, - @JsonProperty("type") val type: String?, - @JsonProperty("value") val value: String, - @JsonProperty("description") val description: String?, - @JsonProperty("brief_description") val briefDescription: String? + @param:JsonProperty("name") val name: String, + @param:JsonProperty("type") val type: String?, + @param:JsonProperty("value") val value: String, + @param:JsonProperty("description") val description: String?, + @param:JsonProperty("brief_description") val briefDescription: String? ) diff --git a/kt/api-generator/src/main/kotlin/godot/codegen/models/Constructor.kt b/kt/api-generator/src/main/kotlin/godot/codegen/models/Constructor.kt index cb90d9d27a..705abeaccb 100644 --- a/kt/api-generator/src/main/kotlin/godot/codegen/models/Constructor.kt +++ b/kt/api-generator/src/main/kotlin/godot/codegen/models/Constructor.kt @@ -4,8 +4,8 @@ import com.fasterxml.jackson.annotation.JsonCreator import com.fasterxml.jackson.annotation.JsonProperty data class Constructor @JsonCreator constructor( - @JsonProperty("index") val index: Int, - @JsonProperty("arguments") val arguments: List?, - @JsonProperty("description") val description: String?, - @JsonProperty("brief_description") val briefDescription: String? + @param:JsonProperty("index") val index: Int, + @param:JsonProperty("arguments") val arguments: List?, + @param:JsonProperty("description") val description: String?, + @param:JsonProperty("brief_description") val briefDescription: String? ) diff --git a/kt/api-generator/src/main/kotlin/godot/codegen/models/Enum.kt b/kt/api-generator/src/main/kotlin/godot/codegen/models/Enum.kt index 60f7918a53..8ad6c1e128 100644 --- a/kt/api-generator/src/main/kotlin/godot/codegen/models/Enum.kt +++ b/kt/api-generator/src/main/kotlin/godot/codegen/models/Enum.kt @@ -4,7 +4,7 @@ import com.fasterxml.jackson.annotation.JsonCreator import com.fasterxml.jackson.annotation.JsonProperty data class Enum @JsonCreator constructor( - @JsonProperty("name") val name: String, - @JsonProperty("values") val values: List, - @JsonProperty("is_bitfield") val isBitField: Boolean = false + @param:JsonProperty("name") val name: String, + @param:JsonProperty("values") val values: List, + @param:JsonProperty("is_bitfield") val isBitField: Boolean = false ) diff --git a/kt/api-generator/src/main/kotlin/godot/codegen/models/EnumValue.kt b/kt/api-generator/src/main/kotlin/godot/codegen/models/EnumValue.kt index c4b2817f95..6d5cda3b53 100644 --- a/kt/api-generator/src/main/kotlin/godot/codegen/models/EnumValue.kt +++ b/kt/api-generator/src/main/kotlin/godot/codegen/models/EnumValue.kt @@ -4,7 +4,7 @@ import com.fasterxml.jackson.annotation.JsonCreator import com.fasterxml.jackson.annotation.JsonProperty data class EnumValue @JsonCreator constructor( - @JsonProperty("name") val name: String, - @JsonProperty("value") val value: Long, - @JsonProperty("description") val description: String? = null + @param:JsonProperty("name") val name: String, + @param:JsonProperty("value") val value: Long, + @param:JsonProperty("description") val description: String? = null ) diff --git a/kt/api-generator/src/main/kotlin/godot/codegen/models/Header.kt b/kt/api-generator/src/main/kotlin/godot/codegen/models/Header.kt index 8880518105..31913e219f 100644 --- a/kt/api-generator/src/main/kotlin/godot/codegen/models/Header.kt +++ b/kt/api-generator/src/main/kotlin/godot/codegen/models/Header.kt @@ -4,10 +4,10 @@ import com.fasterxml.jackson.annotation.JsonCreator import com.fasterxml.jackson.annotation.JsonProperty data class Header @JsonCreator constructor( - @JsonProperty("version_major") val versionMajor: Int, - @JsonProperty("version_minor") val versionMinor: Int, - @JsonProperty("version_patch") val versionPatch: Int, - @JsonProperty("version_status") val versionStatus: String, - @JsonProperty("version_build") val versionBuild: String, - @JsonProperty("version_full_name") val versionFullName: String + @param:JsonProperty("version_major") val versionMajor: Int, + @param:JsonProperty("version_minor") val versionMinor: Int, + @param:JsonProperty("version_patch") val versionPatch: Int, + @param:JsonProperty("version_status") val versionStatus: String, + @param:JsonProperty("version_build") val versionBuild: String, + @param:JsonProperty("version_full_name") val versionFullName: String ) diff --git a/kt/api-generator/src/main/kotlin/godot/codegen/models/Member.kt b/kt/api-generator/src/main/kotlin/godot/codegen/models/Member.kt index 243ab0a9f7..49dac54e53 100644 --- a/kt/api-generator/src/main/kotlin/godot/codegen/models/Member.kt +++ b/kt/api-generator/src/main/kotlin/godot/codegen/models/Member.kt @@ -4,8 +4,8 @@ import com.fasterxml.jackson.annotation.JsonCreator import com.fasterxml.jackson.annotation.JsonProperty data class Member @JsonCreator constructor( - @JsonProperty("name") val name: String, - @JsonProperty("type") val type: String, - @JsonProperty("description") val description: String?, - @JsonProperty("brief_description") val briefDescription: String? + @param:JsonProperty("name") val name: String, + @param:JsonProperty("type") val type: String, + @param:JsonProperty("description") val description: String?, + @param:JsonProperty("brief_description") val briefDescription: String? ) diff --git a/kt/api-generator/src/main/kotlin/godot/codegen/models/MemberOffset.kt b/kt/api-generator/src/main/kotlin/godot/codegen/models/MemberOffset.kt index 81bc17bc16..6c1a6fd253 100644 --- a/kt/api-generator/src/main/kotlin/godot/codegen/models/MemberOffset.kt +++ b/kt/api-generator/src/main/kotlin/godot/codegen/models/MemberOffset.kt @@ -4,7 +4,7 @@ import com.fasterxml.jackson.annotation.JsonCreator import com.fasterxml.jackson.annotation.JsonProperty data class MemberOffset @JsonCreator constructor( - @JsonProperty("member") val member: String, - @JsonProperty("offset") val offset: Int, - @JsonProperty("meta") val meta: String? + @param:JsonProperty("member") val member: String, + @param:JsonProperty("offset") val offset: Int, + @param:JsonProperty("meta") val meta: String? ) diff --git a/kt/api-generator/src/main/kotlin/godot/codegen/models/Method.kt b/kt/api-generator/src/main/kotlin/godot/codegen/models/Method.kt index 6e03738732..0825876f61 100644 --- a/kt/api-generator/src/main/kotlin/godot/codegen/models/Method.kt +++ b/kt/api-generator/src/main/kotlin/godot/codegen/models/Method.kt @@ -4,17 +4,17 @@ import com.fasterxml.jackson.annotation.JsonCreator import com.fasterxml.jackson.annotation.JsonProperty data class Method @JsonCreator constructor( - @JsonProperty("name") val name: String, - @JsonProperty("is_const") val isConst: Boolean, - @JsonProperty("is_vararg") val isVararg: Boolean, - @JsonProperty("is_virtual") val isVirtual: Boolean, - @JsonProperty("is_static") val isStatic: Boolean, - @JsonProperty("is_required") val isRequired: Boolean, - @JsonProperty("hash") val hash: Long, - @JsonProperty("hash_compatibility") val hashCompatibility: List?, - @JsonProperty("return_value") val returnValue: ReturnValue?, - @JsonProperty("return_type") val returnType: String?, - @JsonProperty("arguments") val arguments: List?, - @JsonProperty("description") val description: String?, - @JsonProperty("brief_description") val briefDescription: String? + @param:JsonProperty("name") val name: String, + @param:JsonProperty("is_const") val isConst: Boolean, + @param:JsonProperty("is_vararg") val isVararg: Boolean, + @param:JsonProperty("is_virtual") val isVirtual: Boolean, + @param:JsonProperty("is_static") val isStatic: Boolean, + @param:JsonProperty("is_required") val isRequired: Boolean, + @param:JsonProperty("hash") val hash: Long, + @param:JsonProperty("hash_compatibility") val hashCompatibility: List?, + @param:JsonProperty("return_value") val returnValue: ReturnValue?, + @param:JsonProperty("return_type") val returnType: String?, + @param:JsonProperty("arguments") val arguments: List?, + @param:JsonProperty("description") val description: String?, + @param:JsonProperty("brief_description") val briefDescription: String? ) diff --git a/kt/api-generator/src/main/kotlin/godot/codegen/models/NativeStructure.kt b/kt/api-generator/src/main/kotlin/godot/codegen/models/NativeStructure.kt index ade489649a..196d5a4787 100644 --- a/kt/api-generator/src/main/kotlin/godot/codegen/models/NativeStructure.kt +++ b/kt/api-generator/src/main/kotlin/godot/codegen/models/NativeStructure.kt @@ -4,6 +4,6 @@ import com.fasterxml.jackson.annotation.JsonCreator import com.fasterxml.jackson.annotation.JsonProperty data class NativeStructure @JsonCreator constructor( - @JsonProperty("name") val name: String, - @JsonProperty("format") val format: String + @param:JsonProperty("name") val name: String, + @param:JsonProperty("format") val format: String ) diff --git a/kt/api-generator/src/main/kotlin/godot/codegen/models/Operator.kt b/kt/api-generator/src/main/kotlin/godot/codegen/models/Operator.kt index 211c5d9290..e464a88422 100644 --- a/kt/api-generator/src/main/kotlin/godot/codegen/models/Operator.kt +++ b/kt/api-generator/src/main/kotlin/godot/codegen/models/Operator.kt @@ -4,9 +4,9 @@ import com.fasterxml.jackson.annotation.JsonCreator import com.fasterxml.jackson.annotation.JsonProperty data class Operator @JsonCreator constructor( - @JsonProperty("name") val name: String, - @JsonProperty("right_type") val rightType: String?, - @JsonProperty("return_type") val returnType: String, - @JsonProperty("description") val description: String?, - @JsonProperty("brief_description") val briefDescription: String? + @param:JsonProperty("name") val name: String, + @param:JsonProperty("right_type") val rightType: String?, + @param:JsonProperty("return_type") val returnType: String, + @param:JsonProperty("description") val description: String?, + @param:JsonProperty("brief_description") val briefDescription: String? ) diff --git a/kt/api-generator/src/main/kotlin/godot/codegen/models/Property.kt b/kt/api-generator/src/main/kotlin/godot/codegen/models/Property.kt index f883ad2a5b..841aa16b7a 100644 --- a/kt/api-generator/src/main/kotlin/godot/codegen/models/Property.kt +++ b/kt/api-generator/src/main/kotlin/godot/codegen/models/Property.kt @@ -4,11 +4,11 @@ import com.fasterxml.jackson.annotation.JsonCreator import com.fasterxml.jackson.annotation.JsonProperty data class Property @JsonCreator constructor( - @JsonProperty("type") val type: String, - @JsonProperty("name") val name: String, - @JsonProperty("setter") val setter: String?, - @JsonProperty("getter") val getter: String, - @JsonProperty("index") val index: Int?, - @JsonProperty("description") val description: String?, - @JsonProperty("brief_description") val briefDescription: String? + @param:JsonProperty("type") val type: String, + @param:JsonProperty("name") val name: String, + @param:JsonProperty("setter") val setter: String?, + @param:JsonProperty("getter") val getter: String, + @param:JsonProperty("index") val index: Int?, + @param:JsonProperty("description") val description: String?, + @param:JsonProperty("brief_description") val briefDescription: String? ) diff --git a/kt/api-generator/src/main/kotlin/godot/codegen/models/ReturnValue.kt b/kt/api-generator/src/main/kotlin/godot/codegen/models/ReturnValue.kt index c7241c9847..7ea254d540 100644 --- a/kt/api-generator/src/main/kotlin/godot/codegen/models/ReturnValue.kt +++ b/kt/api-generator/src/main/kotlin/godot/codegen/models/ReturnValue.kt @@ -4,6 +4,6 @@ import com.fasterxml.jackson.annotation.JsonCreator import com.fasterxml.jackson.annotation.JsonProperty data class ReturnValue @JsonCreator constructor( - @JsonProperty("type") val type: String, - @JsonProperty("meta") val meta: String?, + @param:JsonProperty("type") val type: String, + @param:JsonProperty("meta") val meta: String?, ) diff --git a/kt/api-generator/src/main/kotlin/godot/codegen/models/Signal.kt b/kt/api-generator/src/main/kotlin/godot/codegen/models/Signal.kt index aec3a4f75c..baf5e880aa 100644 --- a/kt/api-generator/src/main/kotlin/godot/codegen/models/Signal.kt +++ b/kt/api-generator/src/main/kotlin/godot/codegen/models/Signal.kt @@ -4,8 +4,8 @@ import com.fasterxml.jackson.annotation.JsonCreator import com.fasterxml.jackson.annotation.JsonProperty data class Signal @JsonCreator constructor( - @JsonProperty("name") val name: String, - @JsonProperty("arguments") val arguments: List?, - @JsonProperty("description") val description: String?, - @JsonProperty("brief_description") val briefDescription: String? + @param:JsonProperty("name") val name: String, + @param:JsonProperty("arguments") val arguments: List?, + @param:JsonProperty("description") val description: String?, + @param:JsonProperty("brief_description") val briefDescription: String? ) diff --git a/kt/api-generator/src/main/kotlin/godot/codegen/models/Singleton.kt b/kt/api-generator/src/main/kotlin/godot/codegen/models/Singleton.kt index d09f1f8304..15f8ec877c 100644 --- a/kt/api-generator/src/main/kotlin/godot/codegen/models/Singleton.kt +++ b/kt/api-generator/src/main/kotlin/godot/codegen/models/Singleton.kt @@ -4,6 +4,6 @@ import com.fasterxml.jackson.annotation.JsonCreator import com.fasterxml.jackson.annotation.JsonProperty data class Singleton @JsonCreator constructor( - @JsonProperty("name") val name: String, - @JsonProperty("type") val type: String + @param:JsonProperty("name") val name: String, + @param:JsonProperty("type") val type: String ) diff --git a/kt/api-generator/src/main/kotlin/godot/codegen/models/Size.kt b/kt/api-generator/src/main/kotlin/godot/codegen/models/Size.kt index 51e314c072..837023523f 100644 --- a/kt/api-generator/src/main/kotlin/godot/codegen/models/Size.kt +++ b/kt/api-generator/src/main/kotlin/godot/codegen/models/Size.kt @@ -4,6 +4,6 @@ import com.fasterxml.jackson.annotation.JsonCreator import com.fasterxml.jackson.annotation.JsonProperty data class Size @JsonCreator constructor( - @JsonProperty("name") val name: String, - @JsonProperty("size") val size: Int + @param:JsonProperty("name") val name: String, + @param:JsonProperty("size") val size: Int ) diff --git a/kt/api-generator/src/main/kotlin/godot/codegen/models/UtilityFunction.kt b/kt/api-generator/src/main/kotlin/godot/codegen/models/UtilityFunction.kt index c22db0b8cf..38565821e0 100644 --- a/kt/api-generator/src/main/kotlin/godot/codegen/models/UtilityFunction.kt +++ b/kt/api-generator/src/main/kotlin/godot/codegen/models/UtilityFunction.kt @@ -4,12 +4,12 @@ import com.fasterxml.jackson.annotation.JsonCreator import com.fasterxml.jackson.annotation.JsonProperty data class UtilityFunction @JsonCreator constructor( - @JsonProperty("name") val name: String, - @JsonProperty("return_type") val returnType: String?, - @JsonProperty("category") val category: String, - @JsonProperty("is_vararg") val isVararg: Boolean, - @JsonProperty("hash") val hash: Long, - @JsonProperty("arguments") val arguments: List?, - @JsonProperty("description") val description: String?, - @JsonProperty("brief_description") val briefDescription: String? + @param:JsonProperty("name") val name: String, + @param:JsonProperty("return_type") val returnType: String?, + @param:JsonProperty("category") val category: String, + @param:JsonProperty("is_vararg") val isVararg: Boolean, + @param:JsonProperty("hash") val hash: Long, + @param:JsonProperty("arguments") val arguments: List?, + @param:JsonProperty("description") val description: String?, + @param:JsonProperty("brief_description") val briefDescription: String? ) diff --git a/kt/api-generator/src/main/kotlin/godot/codegen/services/impl/LambdaCallableGenerationService.kt b/kt/api-generator/src/main/kotlin/godot/codegen/services/impl/LambdaCallableGenerationService.kt index fa09b25091..b37cd80fb8 100644 --- a/kt/api-generator/src/main/kotlin/godot/codegen/services/impl/LambdaCallableGenerationService.kt +++ b/kt/api-generator/src/main/kotlin/godot/codegen/services/impl/LambdaCallableGenerationService.kt @@ -249,8 +249,14 @@ object LambdaCallableGenerationService : ILambdaCallableGenerationService { val typeVariables = typeVariableNames.toMutableList() var removedTypeVariables = 0 while (typeVariables.isNotEmpty()) { - val bindReturnType = - ClassName(godotCorePackage, "$LAMBDA_CALLABLE_NAME${typeVariableNames.size - typeVariables.size}") + val bindReturnType = ClassName(godotCorePackage, "$LAMBDA_CALLABLE_NAME${typeVariableNames.size - typeVariables.size}") + + val returnType = if (removedTypeVariables > 0) { + bindReturnType.parameterizedBy(*typeVariableNames.take(typeVariableNames.size - typeVariables.size).toTypedArray(), returnTypeParameter) + } else { + bindReturnType.parameterizedBy(returnTypeParameter) + } + classBuilder.addFunction( FunSpec.builder("bind") .addParameters( @@ -291,6 +297,7 @@ object LambdaCallableGenerationService : ILambdaCallableGenerationService { bindReturnType, *typeVariableNames.take(removedTypeVariables).toTypedArray() ) + .returns(returnType) .build() ) @@ -304,6 +311,13 @@ object LambdaCallableGenerationService : ILambdaCallableGenerationService { callableFileSpec.addType(classBuilder.build()) val variantMapperMember = MemberName(godotCorePackage, "variantMapper") + + val returnTypeName = if (argCount > 0) { + ktCallableClassName.parameterizedBy(*typeVariableNames.toTypedArray(), returnTypeParameter) + } else { + ktCallableClassName.parameterizedBy(returnTypeParameter) + } + callableFileSpec.addFunction( FunSpec.builder(CALLABLE_FUNCTION_NAME + argCount) .addTypeVariables(typeVariableNames.map { it.copy(reified = true) }) @@ -347,6 +361,7 @@ object LambdaCallableGenerationService : ILambdaCallableGenerationService { .toTypedArray() ) ) + .returns(returnTypeName) .build() ) @@ -366,6 +381,7 @@ object LambdaCallableGenerationService : ILambdaCallableGenerationService { .build() ) .addCode("return·$CALLABLE_FUNCTION_NAME$argCount($ON_CANCEL_CALL_ARGUMENT_NAME,·this)") + .returns(returnTypeName) .build() ) } @@ -437,6 +453,7 @@ object LambdaCallableGenerationService : ILambdaCallableGenerationService { .addMember("\"create\"") .build() ) + .returns(genericClassNameInfo.className.parameterizedBy(*genericClassNameInfo.genericTypes.toTypedArray(), returnTypeParameter)) .build() ) .build() diff --git a/kt/api-generator/src/main/kotlin/godot/codegen/services/impl/SignalGenerationService.kt b/kt/api-generator/src/main/kotlin/godot/codegen/services/impl/SignalGenerationService.kt index 173454e9b0..c668073816 100644 --- a/kt/api-generator/src/main/kotlin/godot/codegen/services/impl/SignalGenerationService.kt +++ b/kt/api-generator/src/main/kotlin/godot/codegen/services/impl/SignalGenerationService.kt @@ -290,6 +290,7 @@ object SignalGenerationService : ISignalGenerationService { .addMember("\"create\"") .build() ) + .returns(genericClassNameInfo.genericClassName) .build() ) .build() @@ -314,6 +315,7 @@ object SignalGenerationService : ISignalGenerationService { .addMember("\"FUNCTION_NAME\"") .build() ) + .returns(genericClassNameInfo.genericClassName) .build() } @@ -331,6 +333,7 @@ object SignalGenerationService : ISignalGenerationService { CodeBlock.of("return·%T.$DELEGATE_PROPERTY_NAME·as·%T", genericClassNameInfo.className, genericReadOnlyPropertyClassName) } ) + .returns(genericReadOnlyPropertyClassName) .apply { if (argCount != 0) { addAnnotation( diff --git a/kt/entry-generation/godot-kotlin-symbol-processor/src/main/kotlin/godot/annotation/processor/ext/RegisteredClassMetadataContainerExt.kt b/kt/entry-generation/godot-kotlin-symbol-processor/src/main/kotlin/godot/annotation/processor/ext/RegisteredClassMetadataContainerExt.kt index eed2ea5df6..51447ea468 100644 --- a/kt/entry-generation/godot-kotlin-symbol-processor/src/main/kotlin/godot/annotation/processor/ext/RegisteredClassMetadataContainerExt.kt +++ b/kt/entry-generation/godot-kotlin-symbol-processor/src/main/kotlin/godot/annotation/processor/ext/RegisteredClassMetadataContainerExt.kt @@ -2,7 +2,6 @@ package godot.annotation.processor.ext import godot.annotation.processor.Settings import godot.tools.common.constants.FileExtensions -import org.jetbrains.kotlin.konan.properties.suffix internal fun provideRegistrationFilePathForInitialGenerationWithoutExtension( settings: Settings, @@ -28,5 +27,5 @@ internal fun provideRegistrationFilePathForInitialGenerationWithoutExtension( "${registrationFileOutDir}/$localResourcePath" } else { "${registrationFileOutDir}/dependencies/${classProjectName}/$localResourcePath" - }.suffix(FileExtensions.GodotKotlinJvm.registrationFile) + }.let { "${it}.${FileExtensions.GodotKotlinJvm.registrationFile}" } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/RegisterEngineTypes.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/RegisterEngineTypes.kt index 3a261ed171..688bbfcbd8 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/RegisterEngineTypes.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/RegisterEngineTypes.kt @@ -882,9 +882,8 @@ import godot.api.ZIPPacker import godot.api.ZIPReader import godot.core.VariantParser.OBJECT import godot.core.variantMapper -import kotlin.Unit -public fun registerVariantMapping(): Unit { +public fun registerVariantMapping() { variantMapper[Object::class] = OBJECT variantMapper[RefCounted::class] = OBJECT variantMapper[AESContext::class] = OBJECT @@ -1766,7 +1765,7 @@ public fun registerVariantMapping(): Unit { variantMapper[ZIPReader::class] = OBJECT } -public fun registerEngineTypeMethods(): Unit { +public fun registerEngineTypeMethods() { Object.MethodBindings RefCounted.MethodBindings AESContext.MethodBindings @@ -2648,7 +2647,7 @@ public fun registerEngineTypeMethods(): Unit { ZIPReader.MethodBindings } -public fun registerEngineTypes(): Unit { +public fun registerEngineTypes() { TypeManager.registerEngineType("Object", Object::class, ::Object) TypeManager.registerEngineType("RefCounted", RefCounted::class, ::RefCounted) TypeManager.registerEngineType("AESContext", AESContext::class, ::AESContext) diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AESContext.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AESContext.kt index c780f83b93..6b6e362cfe 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AESContext.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AESContext.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -18,12 +15,10 @@ import godot.core.VariantParser.PACKED_BYTE_ARRAY import kotlin.Int import kotlin.Long import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmOverloads /** - * This class holds the context information required for encryption and decryption operations with - * AES (Advanced Encryption Standard). Both AES-ECB and AES-CBC modes are supported. + * This class holds the context information required for encryption and decryption operations with AES (Advanced Encryption Standard). Both AES-ECB and AES-CBC modes are supported. * * ```gdscript * //gdscript @@ -33,8 +28,7 @@ import kotlin.jvm.JvmOverloads * * func _ready(): * var key = "My secret key!!!" # Key must be either 16 or 32 bytes. - * var data = "My secret text!!" # Data size must be multiple of 16 bytes, apply padding if - * needed. + * var data = "My secret text!!" # Data size must be multiple of 16 bytes, apply padding if needed. * # Encrypt ECB * aes.start(AESContext.MODE_ECB_ENCRYPT, key.to_utf8_buffer()) * var encrypted = aes.update(data.to_utf8_buffer()) @@ -71,8 +65,7 @@ import kotlin.jvm.JvmOverloads * public override void _Ready() * { * string key = "My secret key!!!"; // Key must be either 16 or 32 bytes. - * string data = "My secret text!!"; // Data size must be multiple of 16 bytes, apply - * padding if needed. + * string data = "My secret text!!"; // Data size must be multiple of 16 bytes, apply padding if needed. * // Encrypt ECB * _aes.Start(AesContext.Mode.EcbEncrypt, key.ToUtf8Buffer()); * byte[] encrypted = _aes.Update(data.ToUtf8Buffer()); @@ -101,14 +94,12 @@ import kotlin.jvm.JvmOverloads */ @GodotBaseType public open class AESContext : RefCounted() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(2, scriptIndex) } /** - * Start the AES context in the given [mode]. A [key] of either 16 or 32 bytes must always be - * provided, while an [iv] (initialization vector) of exactly 16 bytes, is only needed when [mode] is - * either [MODE_CBC_ENCRYPT] or [MODE_CBC_DECRYPT]. + * Start the AES context in the given [mode]. A [key] of either 16 or 32 bytes must always be provided, while an [iv] (initialization vector) of exactly 16 bytes, is only needed when [mode] is either [MODE_CBC_ENCRYPT] or [MODE_CBC_DECRYPT]. */ @JvmOverloads public final fun start( @@ -122,8 +113,7 @@ public open class AESContext : RefCounted() { } /** - * Run the desired operation for this AES context. Will return a [PackedByteArray] containing the - * result of encrypting (or decrypting) the given [src]. See [start] for mode of operation. + * Run the desired operation for this AES context. Will return a [PackedByteArray] containing the result of encrypting (or decrypting) the given [src]. See [start] for mode of operation. * * **Note:** The size of [src] must be a multiple of 16. Apply some padding if needed. */ @@ -134,11 +124,9 @@ public open class AESContext : RefCounted() { } /** - * Get the current IV state for this context (IV gets updated when calling [update]). You normally - * don't need this function. + * Get the current IV state for this context (IV gets updated when calling [update]). You normally don't need this function. * - * **Note:** This function only makes sense when the context is started with [MODE_CBC_ENCRYPT] or - * [MODE_CBC_DECRYPT]. + * **Note:** This function only makes sense when the context is started with [MODE_CBC_ENCRYPT] or [MODE_CBC_DECRYPT]. */ public final fun getIvState(): PackedByteArray { TransferContext.writeArguments() @@ -149,7 +137,7 @@ public open class AESContext : RefCounted() { /** * Close this AES context so it can be started again. See [start]. */ - public final fun finish(): Unit { + public final fun finish() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.finishPtr, NIL) } @@ -192,15 +180,16 @@ public open class AESContext : RefCounted() { public companion object public object MethodBindings { - internal val startPtr: VoidPtr = TypeManager.getMethodBindPtr("AESContext", "start", 3122411423) + internal val startPtr: VoidPtr = + TypeManager.getMethodBindPtr("AESContext", "start", 3_122_411_423) internal val updatePtr: VoidPtr = - TypeManager.getMethodBindPtr("AESContext", "update", 527836100) + TypeManager.getMethodBindPtr("AESContext", "update", 527_836_100) internal val getIvStatePtr: VoidPtr = - TypeManager.getMethodBindPtr("AESContext", "get_iv_state", 2115431945) + TypeManager.getMethodBindPtr("AESContext", "get_iv_state", 2_115_431_945) internal val finishPtr: VoidPtr = - TypeManager.getMethodBindPtr("AESContext", "finish", 3218959716) + TypeManager.getMethodBindPtr("AESContext", "finish", 3_218_959_716) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AStar2D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AStar2D.kt index b6f57b6dca..2a45afaa09 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AStar2D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AStar2D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -27,19 +24,16 @@ import kotlin.Int import kotlin.Long import kotlin.NotImplementedError import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmOverloads /** - * An implementation of the A* algorithm, used to find the shortest path between two vertices on a - * connected graph in 2D space. + * An implementation of the A* algorithm, used to find the shortest path between two vertices on a connected graph in 2D space. * - * See [AStar3D] for a more thorough explanation on how to use this class. [AStar2D] is a wrapper - * for [AStar3D] that enforces 2D coordinates. + * See [AStar3D] for a more thorough explanation on how to use this class. [AStar2D] is a wrapper for [AStar3D] that enforces 2D coordinates. */ @GodotBaseType public open class AStar2D : RefCounted() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(3, scriptIndex) } @@ -71,12 +65,9 @@ public open class AStar2D : RefCounted() { } /** - * Adds a new point at the given position with the given identifier. The [id] must be 0 or larger, - * and the [weightScale] must be 0.0 or greater. + * Adds a new point at the given position with the given identifier. The [id] must be 0 or larger, and the [weightScale] must be 0.0 or greater. * - * The [weightScale] is multiplied by the result of [_computeCost] when determining the overall - * cost of traveling across a segment from a neighboring point to this point. Thus, all else being - * equal, the algorithm prefers points with lower [weightScale]s to form a path. + * The [weightScale] is multiplied by the result of [_computeCost] when determining the overall cost of traveling across a segment from a neighboring point to this point. Thus, all else being equal, the algorithm prefers points with lower [weightScale]s to form a path. * * ```gdscript * //gdscript @@ -90,15 +81,14 @@ public open class AStar2D : RefCounted() { * astar.AddPoint(1, new Vector2(1, 0), 4); // Adds the point (1, 0) with weight_scale 4 and id 1 * ``` * - * If there already exists a point for the given [id], its position and weight scale are updated - * to the given values. + * If there already exists a point for the given [id], its position and weight scale are updated to the given values. */ @JvmOverloads public final fun addPoint( id: Long, position: Vector2, weightScale: Float = 1.0f, - ): Unit { + ) { TransferContext.writeArguments(LONG to id, VECTOR2 to position, DOUBLE to weightScale.toDouble()) TransferContext.callMethod(ptr, MethodBindings.addPointPtr, NIL) } @@ -115,7 +105,7 @@ public open class AStar2D : RefCounted() { /** * Sets the [position] for the point with the given [id]. */ - public final fun setPointPosition(id: Long, position: Vector2): Unit { + public final fun setPointPosition(id: Long, position: Vector2) { TransferContext.writeArguments(LONG to id, VECTOR2 to position) TransferContext.callMethod(ptr, MethodBindings.setPointPositionPtr, NIL) } @@ -130,11 +120,9 @@ public open class AStar2D : RefCounted() { } /** - * Sets the [weightScale] for the point with the given [id]. The [weightScale] is multiplied by - * the result of [_computeCost] when determining the overall cost of traveling across a segment from - * a neighboring point to this point. + * Sets the [weightScale] for the point with the given [id]. The [weightScale] is multiplied by the result of [_computeCost] when determining the overall cost of traveling across a segment from a neighboring point to this point. */ - public final fun setPointWeightScale(id: Long, weightScale: Float): Unit { + public final fun setPointWeightScale(id: Long, weightScale: Float) { TransferContext.writeArguments(LONG to id, DOUBLE to weightScale.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setPointWeightScalePtr, NIL) } @@ -142,7 +130,7 @@ public open class AStar2D : RefCounted() { /** * Removes the point associated with the given [id] from the points pool. */ - public final fun removePoint(id: Long): Unit { + public final fun removePoint(id: Long) { TransferContext.writeArguments(LONG to id) TransferContext.callMethod(ptr, MethodBindings.removePointPtr, NIL) } @@ -203,11 +191,10 @@ public open class AStar2D : RefCounted() { } /** - * Disables or enables the specified point for pathfinding. Useful for making a temporary - * obstacle. + * Disables or enables the specified point for pathfinding. Useful for making a temporary obstacle. */ @JvmOverloads - public final fun setPointDisabled(id: Long, disabled: Boolean = true): Unit { + public final fun setPointDisabled(id: Long, disabled: Boolean = true) { TransferContext.writeArguments(LONG to id, BOOL to disabled) TransferContext.callMethod(ptr, MethodBindings.setPointDisabledPtr, NIL) } @@ -222,8 +209,7 @@ public open class AStar2D : RefCounted() { } /** - * Creates a segment between the given points. If [bidirectional] is `false`, only movement from - * [id] to [toId] is allowed, not the reverse direction. + * Creates a segment between the given points. If [bidirectional] is `false`, only movement from [id] to [toId] is allowed, not the reverse direction. * * ```gdscript * //gdscript @@ -246,28 +232,26 @@ public open class AStar2D : RefCounted() { id: Long, toId: Long, bidirectional: Boolean = true, - ): Unit { + ) { TransferContext.writeArguments(LONG to id, LONG to toId, BOOL to bidirectional) TransferContext.callMethod(ptr, MethodBindings.connectPointsPtr, NIL) } /** - * Deletes the segment between the given points. If [bidirectional] is `false`, only movement from - * [id] to [toId] is prevented, and a unidirectional segment possibly remains. + * Deletes the segment between the given points. If [bidirectional] is `false`, only movement from [id] to [toId] is prevented, and a unidirectional segment possibly remains. */ @JvmOverloads public final fun disconnectPoints( id: Long, toId: Long, bidirectional: Boolean = true, - ): Unit { + ) { TransferContext.writeArguments(LONG to id, LONG to toId, BOOL to bidirectional) TransferContext.callMethod(ptr, MethodBindings.disconnectPointsPtr, NIL) } /** - * Returns whether there is a connection/segment between the given points. If [bidirectional] is - * `false`, returns whether movement from [id] to [toId] is possible through this segment. + * Returns whether there is a connection/segment between the given points. If [bidirectional] is `false`, returns whether movement from [id] to [toId] is possible through this segment. */ @JvmOverloads public final fun arePointsConnected( @@ -290,8 +274,7 @@ public open class AStar2D : RefCounted() { } /** - * Returns the capacity of the structure backing the points, useful in conjunction with - * [reserveSpace]. + * Returns the capacity of the structure backing the points, useful in conjunction with [reserveSpace]. */ public final fun getPointCapacity(): Long { TransferContext.writeArguments() @@ -300,11 +283,9 @@ public open class AStar2D : RefCounted() { } /** - * Reserves space internally for [numNodes] points. Useful if you're adding a known large number - * of points at once, such as points on a grid. The new capacity must be greater or equal to the old - * capacity. + * Reserves space internally for [numNodes] points. Useful if you're adding a known large number of points at once, such as points on a grid. The new capacity must be greater or equal to the old capacity. */ - public final fun reserveSpace(numNodes: Long): Unit { + public final fun reserveSpace(numNodes: Long) { TransferContext.writeArguments(LONG to numNodes) TransferContext.callMethod(ptr, MethodBindings.reserveSpacePtr, NIL) } @@ -312,17 +293,15 @@ public open class AStar2D : RefCounted() { /** * Clears all the points and segments. */ - public final fun clear(): Unit { + public final fun clear() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.clearPtr, NIL) } /** - * Returns the ID of the closest point to [toPosition], optionally taking disabled points into - * account. Returns `-1` if there are no points in the points pool. + * Returns the ID of the closest point to [toPosition], optionally taking disabled points into account. Returns `-1` if there are no points in the points pool. * - * **Note:** If several points are the closest to [toPosition], the one with the smallest ID will - * be returned, ensuring a deterministic result. + * **Note:** If several points are the closest to [toPosition], the one with the smallest ID will be returned, ensuring a deterministic result. */ @JvmOverloads public final fun getClosestPoint(toPosition: Vector2, includeDisabled: Boolean = false): Long { @@ -332,8 +311,7 @@ public open class AStar2D : RefCounted() { } /** - * Returns the closest position to [toPosition] that resides inside a segment between two - * connected points. + * Returns the closest position to [toPosition] that resides inside a segment between two connected points. * * ```gdscript * //gdscript @@ -353,8 +331,7 @@ public open class AStar2D : RefCounted() { * Vector2 res = astar.GetClosestPositionInSegment(new Vector2(3, 3)); // Returns (0, 3) * ``` * - * The result is in the segment that goes from `y = 0` to `y = 5`. It's the closest position in - * the segment to the given point. + * The result is in the segment that goes from `y = 0` to `y = 5`. It's the closest position in the segment to the given point. */ public final fun getClosestPositionInSegment(toPosition: Vector2): Vector2 { TransferContext.writeArguments(VECTOR2 to toPosition) @@ -363,17 +340,13 @@ public open class AStar2D : RefCounted() { } /** - * Returns an array with the points that are in the path found by AStar2D between the given - * points. The array is ordered from the starting point to the ending point of the path. + * Returns an array with the points that are in the path found by AStar2D between the given points. The array is ordered from the starting point to the ending point of the path. * - * If there is no valid path to the target, and [allowPartialPath] is `true`, returns a path to - * the point closest to the target that can be reached. + * If there is no valid path to the target, and [allowPartialPath] is `true`, returns a path to the point closest to the target that can be reached. * - * **Note:** This method is not thread-safe. If called from a [Thread], it will return an empty - * array and will print an error message. + * **Note:** This method is not thread-safe. If called from a [Thread], it will return an empty array and will print an error message. * - * Additionally, when [allowPartialPath] is `true` and [toId] is disabled the search may take an - * unusually long time to finish. + * Additionally, when [allowPartialPath] is `true` and [toId] is disabled the search may take an unusually long time to finish. */ @JvmOverloads public final fun getPointPath( @@ -387,14 +360,11 @@ public open class AStar2D : RefCounted() { } /** - * Returns an array with the IDs of the points that form the path found by AStar2D between the - * given points. The array is ordered from the starting point to the ending point of the path. + * Returns an array with the IDs of the points that form the path found by AStar2D between the given points. The array is ordered from the starting point to the ending point of the path. * - * If there is no valid path to the target, and [allowPartialPath] is `true`, returns a path to - * the point closest to the target that can be reached. + * If there is no valid path to the target, and [allowPartialPath] is `true`, returns a path to the point closest to the target that can be reached. * - * **Note:** When [allowPartialPath] is `true` and [toId] is disabled the search may take an - * unusually long time to finish. + * **Note:** When [allowPartialPath] is `true` and [toId] is disabled the search may take an unusually long time to finish. * * ```gdscript * //gdscript @@ -427,8 +397,7 @@ public open class AStar2D : RefCounted() { * long[] res = astar.GetIdPath(1, 3); // Returns [1, 2, 3] * ``` * - * If you change the 2nd point's weight to 3, then the result will be `[1, 4, 3]` instead, because - * now even though the distance is longer, it's "easier" to get through point 4 than through point 2. + * If you change the 2nd point's weight to 3, then the result will be `[1, 4, 3]` instead, because now even though the distance is longer, it's "easier" to get through point 4 than through point 2. */ @JvmOverloads public final fun getIdPath( @@ -445,71 +414,71 @@ public open class AStar2D : RefCounted() { public object MethodBindings { internal val getAvailablePointIdPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar2D", "get_available_point_id", 3905245786) + TypeManager.getMethodBindPtr("AStar2D", "get_available_point_id", 3_905_245_786) internal val addPointPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar2D", "add_point", 4074201818) + TypeManager.getMethodBindPtr("AStar2D", "add_point", 4_074_201_818) internal val getPointPositionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar2D", "get_point_position", 2299179447) + TypeManager.getMethodBindPtr("AStar2D", "get_point_position", 2_299_179_447) internal val setPointPositionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar2D", "set_point_position", 163021252) + TypeManager.getMethodBindPtr("AStar2D", "set_point_position", 163_021_252) internal val getPointWeightScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar2D", "get_point_weight_scale", 2339986948) + TypeManager.getMethodBindPtr("AStar2D", "get_point_weight_scale", 2_339_986_948) internal val setPointWeightScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar2D", "set_point_weight_scale", 1602489585) + TypeManager.getMethodBindPtr("AStar2D", "set_point_weight_scale", 1_602_489_585) internal val removePointPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar2D", "remove_point", 1286410249) + TypeManager.getMethodBindPtr("AStar2D", "remove_point", 1_286_410_249) internal val hasPointPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar2D", "has_point", 1116898809) + TypeManager.getMethodBindPtr("AStar2D", "has_point", 1_116_898_809) internal val getPointConnectionsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar2D", "get_point_connections", 2865087369) + TypeManager.getMethodBindPtr("AStar2D", "get_point_connections", 2_865_087_369) internal val getPointIdsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar2D", "get_point_ids", 3851388692) + TypeManager.getMethodBindPtr("AStar2D", "get_point_ids", 3_851_388_692) internal val setPointDisabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar2D", "set_point_disabled", 972357352) + TypeManager.getMethodBindPtr("AStar2D", "set_point_disabled", 972_357_352) internal val isPointDisabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar2D", "is_point_disabled", 1116898809) + TypeManager.getMethodBindPtr("AStar2D", "is_point_disabled", 1_116_898_809) internal val connectPointsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar2D", "connect_points", 3710494224) + TypeManager.getMethodBindPtr("AStar2D", "connect_points", 3_710_494_224) internal val disconnectPointsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar2D", "disconnect_points", 3710494224) + TypeManager.getMethodBindPtr("AStar2D", "disconnect_points", 3_710_494_224) internal val arePointsConnectedPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar2D", "are_points_connected", 2288175859) + TypeManager.getMethodBindPtr("AStar2D", "are_points_connected", 2_288_175_859) internal val getPointCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar2D", "get_point_count", 3905245786) + TypeManager.getMethodBindPtr("AStar2D", "get_point_count", 3_905_245_786) internal val getPointCapacityPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar2D", "get_point_capacity", 3905245786) + TypeManager.getMethodBindPtr("AStar2D", "get_point_capacity", 3_905_245_786) internal val reserveSpacePtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar2D", "reserve_space", 1286410249) + TypeManager.getMethodBindPtr("AStar2D", "reserve_space", 1_286_410_249) - internal val clearPtr: VoidPtr = TypeManager.getMethodBindPtr("AStar2D", "clear", 3218959716) + internal val clearPtr: VoidPtr = TypeManager.getMethodBindPtr("AStar2D", "clear", 3_218_959_716) internal val getClosestPointPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar2D", "get_closest_point", 2300324924) + TypeManager.getMethodBindPtr("AStar2D", "get_closest_point", 2_300_324_924) internal val getClosestPositionInSegmentPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar2D", "get_closest_position_in_segment", 2656412154) + TypeManager.getMethodBindPtr("AStar2D", "get_closest_position_in_segment", 2_656_412_154) internal val getPointPathPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar2D", "get_point_path", 3427490392) + TypeManager.getMethodBindPtr("AStar2D", "get_point_path", 3_427_490_392) internal val getIdPathPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar2D", "get_id_path", 3136199648) + TypeManager.getMethodBindPtr("AStar2D", "get_id_path", 3_136_199_648) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AStar3D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AStar3D.kt index bc5b280757..8362f04e5c 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AStar3D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AStar3D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -27,23 +24,14 @@ import kotlin.Int import kotlin.Long import kotlin.NotImplementedError import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmOverloads /** - * A* (A star) is a computer algorithm used in pathfinding and graph traversal, the process of - * plotting short paths among vertices (points), passing through a given set of edges (segments). It - * enjoys widespread use due to its performance and accuracy. Godot's A* implementation uses points in - * 3D space and Euclidean distances by default. + * A* (A star) is a computer algorithm used in pathfinding and graph traversal, the process of plotting short paths among vertices (points), passing through a given set of edges (segments). It enjoys widespread use due to its performance and accuracy. Godot's A* implementation uses points in 3D space and Euclidean distances by default. * - * You must add points manually with [addPoint] and create segments manually with [connectPoints]. - * Once done, you can test if there is a path between two points with the [arePointsConnected] - * function, get a path containing indices by [getIdPath], or one containing actual coordinates with - * [getPointPath]. + * You must add points manually with [addPoint] and create segments manually with [connectPoints]. Once done, you can test if there is a path between two points with the [arePointsConnected] function, get a path containing indices by [getIdPath], or one containing actual coordinates with [getPointPath]. * - * It is also possible to use non-Euclidean distances. To do so, create a script that extends - * [AStar3D] and override the methods [_computeCost] and [_estimateCost]. Both should take two point - * IDs and return the distance between the corresponding points. + * It is also possible to use non-Euclidean distances. To do so, create a script that extends [AStar3D] and override the methods [_computeCost] and [_estimateCost]. Both should take two point IDs and return the distance between the corresponding points. * * **Example:** Use Manhattan distance instead of Euclidean distance: * @@ -75,35 +63,25 @@ import kotlin.jvm.JvmOverloads * Vector3 fromPoint = GetPointPosition(fromId); * Vector3 toPoint = GetPointPosition(toId); * - * return Mathf.Abs(fromPoint.X - toPoint.X) + Mathf.Abs(fromPoint.Y - toPoint.Y) + - * Mathf.Abs(fromPoint.Z - toPoint.Z); + * return Mathf.Abs(fromPoint.X - toPoint.X) + Mathf.Abs(fromPoint.Y - toPoint.Y) + Mathf.Abs(fromPoint.Z - toPoint.Z); * } * * public override float _EstimateCost(long fromId, long toId) * { * Vector3 fromPoint = GetPointPosition(fromId); * Vector3 toPoint = GetPointPosition(toId); - * return Mathf.Abs(fromPoint.X - toPoint.X) + Mathf.Abs(fromPoint.Y - toPoint.Y) + - * Mathf.Abs(fromPoint.Z - toPoint.Z); + * return Mathf.Abs(fromPoint.X - toPoint.X) + Mathf.Abs(fromPoint.Y - toPoint.Y) + Mathf.Abs(fromPoint.Z - toPoint.Z); * } * } * ``` * - * [_estimateCost] should return a lower bound of the distance, i.e. `_estimate_cost(u, v) <= - * _compute_cost(u, v)`. This serves as a hint to the algorithm because the custom [_computeCost] might - * be computation-heavy. If this is not the case, make [_estimateCost] return the same value as - * [_computeCost] to provide the algorithm with the most accurate information. + * [_estimateCost] should return a lower bound of the distance, i.e. `_estimate_cost(u, v) <= _compute_cost(u, v)`. This serves as a hint to the algorithm because the custom [_computeCost] might be computation-heavy. If this is not the case, make [_estimateCost] return the same value as [_computeCost] to provide the algorithm with the most accurate information. * - * If the default [_estimateCost] and [_computeCost] methods are used, or if the supplied - * [_estimateCost] method returns a lower bound of the cost, then the paths returned by A* will be the - * lowest-cost paths. Here, the cost of a path equals the sum of the [_computeCost] results of all - * segments in the path multiplied by the `weight_scale`s of the endpoints of the respective segments. - * If the default methods are used and the `weight_scale`s of all points are set to `1.0`, then this - * equals the sum of Euclidean distances of all segments in the path. + * If the default [_estimateCost] and [_computeCost] methods are used, or if the supplied [_estimateCost] method returns a lower bound of the cost, then the paths returned by A* will be the lowest-cost paths. Here, the cost of a path equals the sum of the [_computeCost] results of all segments in the path multiplied by the `weight_scale`s of the endpoints of the respective segments. If the default methods are used and the `weight_scale`s of all points are set to `1.0`, then this equals the sum of Euclidean distances of all segments in the path. */ @GodotBaseType public open class AStar3D : RefCounted() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(4, scriptIndex) } @@ -135,12 +113,9 @@ public open class AStar3D : RefCounted() { } /** - * Adds a new point at the given position with the given identifier. The [id] must be 0 or larger, - * and the [weightScale] must be 0.0 or greater. + * Adds a new point at the given position with the given identifier. The [id] must be 0 or larger, and the [weightScale] must be 0.0 or greater. * - * The [weightScale] is multiplied by the result of [_computeCost] when determining the overall - * cost of traveling across a segment from a neighboring point to this point. Thus, all else being - * equal, the algorithm prefers points with lower [weightScale]s to form a path. + * The [weightScale] is multiplied by the result of [_computeCost] when determining the overall cost of traveling across a segment from a neighboring point to this point. Thus, all else being equal, the algorithm prefers points with lower [weightScale]s to form a path. * * ```gdscript * //gdscript @@ -151,19 +126,17 @@ public open class AStar3D : RefCounted() { * ```csharp * //csharp * var astar = new AStar3D(); - * astar.AddPoint(1, new Vector3(1, 0, 0), 4); // Adds the point (1, 0, 0) with weight_scale 4 and - * id 1 + * astar.AddPoint(1, new Vector3(1, 0, 0), 4); // Adds the point (1, 0, 0) with weight_scale 4 and id 1 * ``` * - * If there already exists a point for the given [id], its position and weight scale are updated - * to the given values. + * If there already exists a point for the given [id], its position and weight scale are updated to the given values. */ @JvmOverloads public final fun addPoint( id: Long, position: Vector3, weightScale: Float = 1.0f, - ): Unit { + ) { TransferContext.writeArguments(LONG to id, VECTOR3 to position, DOUBLE to weightScale.toDouble()) TransferContext.callMethod(ptr, MethodBindings.addPointPtr, NIL) } @@ -180,7 +153,7 @@ public open class AStar3D : RefCounted() { /** * Sets the [position] for the point with the given [id]. */ - public final fun setPointPosition(id: Long, position: Vector3): Unit { + public final fun setPointPosition(id: Long, position: Vector3) { TransferContext.writeArguments(LONG to id, VECTOR3 to position) TransferContext.callMethod(ptr, MethodBindings.setPointPositionPtr, NIL) } @@ -195,11 +168,9 @@ public open class AStar3D : RefCounted() { } /** - * Sets the [weightScale] for the point with the given [id]. The [weightScale] is multiplied by - * the result of [_computeCost] when determining the overall cost of traveling across a segment from - * a neighboring point to this point. + * Sets the [weightScale] for the point with the given [id]. The [weightScale] is multiplied by the result of [_computeCost] when determining the overall cost of traveling across a segment from a neighboring point to this point. */ - public final fun setPointWeightScale(id: Long, weightScale: Float): Unit { + public final fun setPointWeightScale(id: Long, weightScale: Float) { TransferContext.writeArguments(LONG to id, DOUBLE to weightScale.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setPointWeightScalePtr, NIL) } @@ -207,7 +178,7 @@ public open class AStar3D : RefCounted() { /** * Removes the point associated with the given [id] from the points pool. */ - public final fun removePoint(id: Long): Unit { + public final fun removePoint(id: Long) { TransferContext.writeArguments(LONG to id) TransferContext.callMethod(ptr, MethodBindings.removePointPtr, NIL) } @@ -267,11 +238,10 @@ public open class AStar3D : RefCounted() { } /** - * Disables or enables the specified point for pathfinding. Useful for making a temporary - * obstacle. + * Disables or enables the specified point for pathfinding. Useful for making a temporary obstacle. */ @JvmOverloads - public final fun setPointDisabled(id: Long, disabled: Boolean = true): Unit { + public final fun setPointDisabled(id: Long, disabled: Boolean = true) { TransferContext.writeArguments(LONG to id, BOOL to disabled) TransferContext.callMethod(ptr, MethodBindings.setPointDisabledPtr, NIL) } @@ -286,8 +256,7 @@ public open class AStar3D : RefCounted() { } /** - * Creates a segment between the given points. If [bidirectional] is `false`, only movement from - * [id] to [toId] is allowed, not the reverse direction. + * Creates a segment between the given points. If [bidirectional] is `false`, only movement from [id] to [toId] is allowed, not the reverse direction. * * ```gdscript * //gdscript @@ -310,28 +279,26 @@ public open class AStar3D : RefCounted() { id: Long, toId: Long, bidirectional: Boolean = true, - ): Unit { + ) { TransferContext.writeArguments(LONG to id, LONG to toId, BOOL to bidirectional) TransferContext.callMethod(ptr, MethodBindings.connectPointsPtr, NIL) } /** - * Deletes the segment between the given points. If [bidirectional] is `false`, only movement from - * [id] to [toId] is prevented, and a unidirectional segment possibly remains. + * Deletes the segment between the given points. If [bidirectional] is `false`, only movement from [id] to [toId] is prevented, and a unidirectional segment possibly remains. */ @JvmOverloads public final fun disconnectPoints( id: Long, toId: Long, bidirectional: Boolean = true, - ): Unit { + ) { TransferContext.writeArguments(LONG to id, LONG to toId, BOOL to bidirectional) TransferContext.callMethod(ptr, MethodBindings.disconnectPointsPtr, NIL) } /** - * Returns whether the two given points are directly connected by a segment. If [bidirectional] is - * `false`, returns whether movement from [id] to [toId] is possible through this segment. + * Returns whether the two given points are directly connected by a segment. If [bidirectional] is `false`, returns whether movement from [id] to [toId] is possible through this segment. */ @JvmOverloads public final fun arePointsConnected( @@ -354,8 +321,7 @@ public open class AStar3D : RefCounted() { } /** - * Returns the capacity of the structure backing the points, useful in conjunction with - * [reserveSpace]. + * Returns the capacity of the structure backing the points, useful in conjunction with [reserveSpace]. */ public final fun getPointCapacity(): Long { TransferContext.writeArguments() @@ -364,11 +330,9 @@ public open class AStar3D : RefCounted() { } /** - * Reserves space internally for [numNodes] points. Useful if you're adding a known large number - * of points at once, such as points on a grid. New capacity must be greater or equals to old - * capacity. + * Reserves space internally for [numNodes] points. Useful if you're adding a known large number of points at once, such as points on a grid. New capacity must be greater or equals to old capacity. */ - public final fun reserveSpace(numNodes: Long): Unit { + public final fun reserveSpace(numNodes: Long) { TransferContext.writeArguments(LONG to numNodes) TransferContext.callMethod(ptr, MethodBindings.reserveSpacePtr, NIL) } @@ -376,17 +340,15 @@ public open class AStar3D : RefCounted() { /** * Clears all the points and segments. */ - public final fun clear(): Unit { + public final fun clear() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.clearPtr, NIL) } /** - * Returns the ID of the closest point to [toPosition], optionally taking disabled points into - * account. Returns `-1` if there are no points in the points pool. + * Returns the ID of the closest point to [toPosition], optionally taking disabled points into account. Returns `-1` if there are no points in the points pool. * - * **Note:** If several points are the closest to [toPosition], the one with the smallest ID will - * be returned, ensuring a deterministic result. + * **Note:** If several points are the closest to [toPosition], the one with the smallest ID will be returned, ensuring a deterministic result. */ @JvmOverloads public final fun getClosestPoint(toPosition: Vector3, includeDisabled: Boolean = false): Long { @@ -396,8 +358,7 @@ public open class AStar3D : RefCounted() { } /** - * Returns the closest position to [toPosition] that resides inside a segment between two - * connected points. + * Returns the closest position to [toPosition] that resides inside a segment between two connected points. * * ```gdscript * //gdscript @@ -417,8 +378,7 @@ public open class AStar3D : RefCounted() { * Vector3 res = astar.GetClosestPositionInSegment(new Vector3(3, 3, 0)); // Returns (0, 3, 0) * ``` * - * The result is in the segment that goes from `y = 0` to `y = 5`. It's the closest position in - * the segment to the given point. + * The result is in the segment that goes from `y = 0` to `y = 5`. It's the closest position in the segment to the given point. */ public final fun getClosestPositionInSegment(toPosition: Vector3): Vector3 { TransferContext.writeArguments(VECTOR3 to toPosition) @@ -427,17 +387,13 @@ public open class AStar3D : RefCounted() { } /** - * Returns an array with the points that are in the path found by AStar3D between the given - * points. The array is ordered from the starting point to the ending point of the path. + * Returns an array with the points that are in the path found by AStar3D between the given points. The array is ordered from the starting point to the ending point of the path. * - * If there is no valid path to the target, and [allowPartialPath] is `true`, returns a path to - * the point closest to the target that can be reached. + * If there is no valid path to the target, and [allowPartialPath] is `true`, returns a path to the point closest to the target that can be reached. * - * **Note:** This method is not thread-safe. If called from a [Thread], it will return an empty - * array and will print an error message. + * **Note:** This method is not thread-safe. If called from a [Thread], it will return an empty array and will print an error message. * - * Additionally, when [allowPartialPath] is `true` and [toId] is disabled the search may take an - * unusually long time to finish. + * Additionally, when [allowPartialPath] is `true` and [toId] is disabled the search may take an unusually long time to finish. */ @JvmOverloads public final fun getPointPath( @@ -451,14 +407,11 @@ public open class AStar3D : RefCounted() { } /** - * Returns an array with the IDs of the points that form the path found by AStar3D between the - * given points. The array is ordered from the starting point to the ending point of the path. + * Returns an array with the IDs of the points that form the path found by AStar3D between the given points. The array is ordered from the starting point to the ending point of the path. * - * If there is no valid path to the target, and [allowPartialPath] is `true`, returns a path to - * the point closest to the target that can be reached. + * If there is no valid path to the target, and [allowPartialPath] is `true`, returns a path to the point closest to the target that can be reached. * - * **Note:** When [allowPartialPath] is `true` and [toId] is disabled the search may take an - * unusually long time to finish. + * **Note:** When [allowPartialPath] is `true` and [toId] is disabled the search may take an unusually long time to finish. * * ```gdscript * //gdscript @@ -490,8 +443,7 @@ public open class AStar3D : RefCounted() { * long[] res = astar.GetIdPath(1, 3); // Returns [1, 2, 3] * ``` * - * If you change the 2nd point's weight to 3, then the result will be `[1, 4, 3]` instead, because - * now even though the distance is longer, it's "easier" to get through point 4 than through point 2. + * If you change the 2nd point's weight to 3, then the result will be `[1, 4, 3]` instead, because now even though the distance is longer, it's "easier" to get through point 4 than through point 2. */ @JvmOverloads public final fun getIdPath( @@ -508,71 +460,71 @@ public open class AStar3D : RefCounted() { public object MethodBindings { internal val getAvailablePointIdPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar3D", "get_available_point_id", 3905245786) + TypeManager.getMethodBindPtr("AStar3D", "get_available_point_id", 3_905_245_786) internal val addPointPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar3D", "add_point", 1038703438) + TypeManager.getMethodBindPtr("AStar3D", "add_point", 1_038_703_438) internal val getPointPositionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar3D", "get_point_position", 711720468) + TypeManager.getMethodBindPtr("AStar3D", "get_point_position", 711_720_468) internal val setPointPositionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar3D", "set_point_position", 1530502735) + TypeManager.getMethodBindPtr("AStar3D", "set_point_position", 1_530_502_735) internal val getPointWeightScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar3D", "get_point_weight_scale", 2339986948) + TypeManager.getMethodBindPtr("AStar3D", "get_point_weight_scale", 2_339_986_948) internal val setPointWeightScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar3D", "set_point_weight_scale", 1602489585) + TypeManager.getMethodBindPtr("AStar3D", "set_point_weight_scale", 1_602_489_585) internal val removePointPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar3D", "remove_point", 1286410249) + TypeManager.getMethodBindPtr("AStar3D", "remove_point", 1_286_410_249) internal val hasPointPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar3D", "has_point", 1116898809) + TypeManager.getMethodBindPtr("AStar3D", "has_point", 1_116_898_809) internal val getPointConnectionsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar3D", "get_point_connections", 2865087369) + TypeManager.getMethodBindPtr("AStar3D", "get_point_connections", 2_865_087_369) internal val getPointIdsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar3D", "get_point_ids", 3851388692) + TypeManager.getMethodBindPtr("AStar3D", "get_point_ids", 3_851_388_692) internal val setPointDisabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar3D", "set_point_disabled", 972357352) + TypeManager.getMethodBindPtr("AStar3D", "set_point_disabled", 972_357_352) internal val isPointDisabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar3D", "is_point_disabled", 1116898809) + TypeManager.getMethodBindPtr("AStar3D", "is_point_disabled", 1_116_898_809) internal val connectPointsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar3D", "connect_points", 3710494224) + TypeManager.getMethodBindPtr("AStar3D", "connect_points", 3_710_494_224) internal val disconnectPointsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar3D", "disconnect_points", 3710494224) + TypeManager.getMethodBindPtr("AStar3D", "disconnect_points", 3_710_494_224) internal val arePointsConnectedPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar3D", "are_points_connected", 2288175859) + TypeManager.getMethodBindPtr("AStar3D", "are_points_connected", 2_288_175_859) internal val getPointCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar3D", "get_point_count", 3905245786) + TypeManager.getMethodBindPtr("AStar3D", "get_point_count", 3_905_245_786) internal val getPointCapacityPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar3D", "get_point_capacity", 3905245786) + TypeManager.getMethodBindPtr("AStar3D", "get_point_capacity", 3_905_245_786) internal val reserveSpacePtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar3D", "reserve_space", 1286410249) + TypeManager.getMethodBindPtr("AStar3D", "reserve_space", 1_286_410_249) - internal val clearPtr: VoidPtr = TypeManager.getMethodBindPtr("AStar3D", "clear", 3218959716) + internal val clearPtr: VoidPtr = TypeManager.getMethodBindPtr("AStar3D", "clear", 3_218_959_716) internal val getClosestPointPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar3D", "get_closest_point", 3241074317) + TypeManager.getMethodBindPtr("AStar3D", "get_closest_point", 3_241_074_317) internal val getClosestPositionInSegmentPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar3D", "get_closest_position_in_segment", 192990374) + TypeManager.getMethodBindPtr("AStar3D", "get_closest_position_in_segment", 192_990_374) internal val getPointPathPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar3D", "get_point_path", 1562654675) + TypeManager.getMethodBindPtr("AStar3D", "get_point_path", 1_562_654_675) internal val getIdPathPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStar3D", "get_id_path", 3136199648) + TypeManager.getMethodBindPtr("AStar3D", "get_id_path", 3_136_199_648) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AStarGrid2D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AStarGrid2D.kt index 55eec2303d..3ec3afc35c 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AStarGrid2D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AStarGrid2D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -40,13 +37,9 @@ import kotlin.jvm.JvmName import kotlin.jvm.JvmOverloads /** - * [AStarGrid2D] is a variant of [AStar2D] that is specialized for partial 2D grids. It is simpler - * to use because it doesn't require you to manually create points and connect them together. This - * class also supports multiple types of heuristics, modes for diagonal movement, and a jumping mode to - * speed up calculations. + * [AStarGrid2D] is a variant of [AStar2D] that is specialized for partial 2D grids. It is simpler to use because it doesn't require you to manually create points and connect them together. This class also supports multiple types of heuristics, modes for diagonal movement, and a jumping mode to speed up calculations. * - * To use [AStarGrid2D], you only need to set the [region] of the grid, optionally set the - * [cellSize], and then call the [update] method: + * To use [AStarGrid2D], you only need to set the [region] of the grid, optionally set the [cellSize], and then call the [update] method: * * ```gdscript * //gdscript @@ -54,10 +47,8 @@ import kotlin.jvm.JvmOverloads * astar_grid.region = Rect2i(0, 0, 32, 32) * astar_grid.cell_size = Vector2(16, 16) * astar_grid.update() - * print(astar_grid.get_id_path(Vector2i(0, 0), Vector2i(3, 4))) # Prints [(0, 0), (1, 1), (2, 2), - * (3, 3), (3, 4)] - * print(astar_grid.get_point_path(Vector2i(0, 0), Vector2i(3, 4))) # Prints [(0, 0), (16, 16), (32, - * 32), (48, 48), (48, 64)] + * print(astar_grid.get_id_path(Vector2i(0, 0), Vector2i(3, 4))) # Prints [(0, 0), (1, 1), (2, 2), (3, 3), (3, 4)] + * print(astar_grid.get_point_path(Vector2i(0, 0), Vector2i(3, 4))) # Prints [(0, 0), (16, 16), (32, 32), (48, 48), (48, 64)] * ``` * * ```csharp @@ -66,10 +57,8 @@ import kotlin.jvm.JvmOverloads * astarGrid.Region = new Rect2I(0, 0, 32, 32); * astarGrid.CellSize = new Vector2I(16, 16); * astarGrid.Update(); - * GD.Print(astarGrid.GetIdPath(Vector2I.Zero, new Vector2I(3, 4))); // Prints [(0, 0), (1, 1), (2, - * 2), (3, 3), (3, 4)] - * GD.Print(astarGrid.GetPointPath(Vector2I.Zero, new Vector2I(3, 4))); // Prints [(0, 0), (16, 16), - * (32, 32), (48, 48), (48, 64)] + * GD.Print(astarGrid.GetIdPath(Vector2I.Zero, new Vector2I(3, 4))); // Prints [(0, 0), (1, 1), (2, 2), (3, 3), (3, 4)] + * GD.Print(astarGrid.GetPointPath(Vector2I.Zero, new Vector2I(3, 4))); // Prints [(0, 0), (16, 16), (32, 32), (48, 48), (48, 64)] * ``` * * To remove a point from the pathfinding grid, it must be set as "solid" with [setPointSolid]. @@ -77,15 +66,11 @@ import kotlin.jvm.JvmOverloads @GodotBaseType public open class AStarGrid2D : RefCounted() { /** - * The region of grid cells available for pathfinding. If changed, [update] needs to be called - * before finding the next path. + * The region of grid cells available for pathfinding. If changed, [update] needs to be called before finding the next path. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var region: Rect2i @@ -97,15 +82,11 @@ public open class AStarGrid2D : RefCounted() { } /** - * The size of the grid (number of cells of size [cellSize] on each axis). If changed, [update] - * needs to be called before finding the next path. + * The size of the grid (number of cells of size [cellSize] on each axis). If changed, [update] needs to be called before finding the next path. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var size: Vector2i @@ -117,15 +98,11 @@ public open class AStarGrid2D : RefCounted() { } /** - * The offset of the grid which will be applied to calculate the resulting point position returned - * by [getPointPath]. If changed, [update] needs to be called before finding the next path. + * The offset of the grid which will be applied to calculate the resulting point position returned by [getPointPath]. If changed, [update] needs to be called before finding the next path. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var offset: Vector2 @@ -137,15 +114,11 @@ public open class AStarGrid2D : RefCounted() { } /** - * The size of the point cell which will be applied to calculate the resulting point position - * returned by [getPointPath]. If changed, [update] needs to be called before finding the next path. + * The size of the point cell which will be applied to calculate the resulting point position returned by [getPointPath]. If changed, [update] needs to be called before finding the next path. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var cellSize: Vector2 @@ -157,8 +130,7 @@ public open class AStarGrid2D : RefCounted() { } /** - * The cell shape. Affects how the positions are placed in the grid. If changed, [update] needs to - * be called before finding the next path. + * The cell shape. Affects how the positions are placed in the grid. If changed, [update] needs to be called before finding the next path. */ public final inline var cellShape: CellShape @JvmName("cellShapeProperty") @@ -169,11 +141,9 @@ public open class AStarGrid2D : RefCounted() { } /** - * Enables or disables jumping to skip up the intermediate points and speeds up the searching - * algorithm. + * Enables or disables jumping to skip up the intermediate points and speeds up the searching algorithm. * - * **Note:** Currently, toggling it on disables the consideration of weight scaling in - * pathfinding. + * **Note:** Currently, toggling it on disables the consideration of weight scaling in pathfinding. */ public final inline var jumpingEnabled: Boolean @JvmName("jumpingEnabledProperty") @@ -184,8 +154,7 @@ public open class AStarGrid2D : RefCounted() { } /** - * The default [Heuristic] which will be used to calculate the cost between two points if - * [_computeCost] was not overridden. + * The default [Heuristic] which will be used to calculate the cost between two points if [_computeCost] was not overridden. */ public final inline var defaultComputeHeuristic: Heuristic @JvmName("defaultComputeHeuristicProperty") @@ -196,8 +165,7 @@ public open class AStarGrid2D : RefCounted() { } /** - * The default [Heuristic] which will be used to calculate the cost between the point and the end - * point if [_estimateCost] was not overridden. + * The default [Heuristic] which will be used to calculate the cost between the point and the end point if [_estimateCost] was not overridden. */ public final inline var defaultEstimateHeuristic: Heuristic @JvmName("defaultEstimateHeuristicProperty") @@ -208,8 +176,7 @@ public open class AStarGrid2D : RefCounted() { } /** - * A specific [DiagonalMode] mode which will force the path to avoid or accept the specified - * diagonals. + * A specific [DiagonalMode] mode which will force the path to avoid or accept the specified diagonals. */ public final inline var diagonalMode: DiagonalMode @JvmName("diagonalModeProperty") @@ -219,7 +186,7 @@ public open class AStarGrid2D : RefCounted() { setDiagonalMode(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(5, scriptIndex) } @@ -234,8 +201,7 @@ public open class AStarGrid2D : RefCounted() { * astargrid2d.region = myCoreType * `````` * - * The region of grid cells available for pathfinding. If changed, [update] needs to be called - * before finding the next path. + * The region of grid cells available for pathfinding. If changed, [update] needs to be called before finding the next path. */ @CoreTypeHelper public final fun regionMutate(block: Rect2i.() -> Unit): Rect2i = region.apply { @@ -254,8 +220,7 @@ public open class AStarGrid2D : RefCounted() { * astargrid2d.size = myCoreType * `````` * - * The size of the grid (number of cells of size [cellSize] on each axis). If changed, [update] - * needs to be called before finding the next path. + * The size of the grid (number of cells of size [cellSize] on each axis). If changed, [update] needs to be called before finding the next path. */ @CoreTypeHelper public final fun sizeMutate(block: Vector2i.() -> Unit): Vector2i = size.apply { @@ -274,8 +239,7 @@ public open class AStarGrid2D : RefCounted() { * astargrid2d.offset = myCoreType * `````` * - * The offset of the grid which will be applied to calculate the resulting point position returned - * by [getPointPath]. If changed, [update] needs to be called before finding the next path. + * The offset of the grid which will be applied to calculate the resulting point position returned by [getPointPath]. If changed, [update] needs to be called before finding the next path. */ @CoreTypeHelper public final fun offsetMutate(block: Vector2.() -> Unit): Vector2 = offset.apply { @@ -294,8 +258,7 @@ public open class AStarGrid2D : RefCounted() { * astargrid2d.cellSize = myCoreType * `````` * - * The size of the point cell which will be applied to calculate the resulting point position - * returned by [getPointPath]. If changed, [update] needs to be called before finding the next path. + * The size of the point cell which will be applied to calculate the resulting point position returned by [getPointPath]. If changed, [update] needs to be called before finding the next path. */ @CoreTypeHelper public final fun cellSizeMutate(block: Vector2.() -> Unit): Vector2 = cellSize.apply { @@ -321,7 +284,7 @@ public open class AStarGrid2D : RefCounted() { throw NotImplementedError("AStarGrid2D::_computeCost is not implemented.") } - public final fun setRegion(region: Rect2i): Unit { + public final fun setRegion(region: Rect2i) { TransferContext.writeArguments(RECT2I to region) TransferContext.callMethod(ptr, MethodBindings.setRegionPtr, NIL) } @@ -332,7 +295,7 @@ public open class AStarGrid2D : RefCounted() { return (TransferContext.readReturnValue(RECT2I) as Rect2i) } - public final fun setSize(size: Vector2i): Unit { + public final fun setSize(size: Vector2i) { TransferContext.writeArguments(VECTOR2I to size) TransferContext.callMethod(ptr, MethodBindings.setSizePtr, NIL) } @@ -343,7 +306,7 @@ public open class AStarGrid2D : RefCounted() { return (TransferContext.readReturnValue(VECTOR2I) as Vector2i) } - public final fun setOffset(offset: Vector2): Unit { + public final fun setOffset(offset: Vector2) { TransferContext.writeArguments(VECTOR2 to offset) TransferContext.callMethod(ptr, MethodBindings.setOffsetPtr, NIL) } @@ -354,7 +317,7 @@ public open class AStarGrid2D : RefCounted() { return (TransferContext.readReturnValue(VECTOR2) as Vector2) } - public final fun setCellSize(cellSize: Vector2): Unit { + public final fun setCellSize(cellSize: Vector2) { TransferContext.writeArguments(VECTOR2 to cellSize) TransferContext.callMethod(ptr, MethodBindings.setCellSizePtr, NIL) } @@ -365,7 +328,7 @@ public open class AStarGrid2D : RefCounted() { return (TransferContext.readReturnValue(VECTOR2) as Vector2) } - public final fun setCellShape(cellShape: CellShape): Unit { + public final fun setCellShape(cellShape: CellShape) { TransferContext.writeArguments(LONG to cellShape.id) TransferContext.callMethod(ptr, MethodBindings.setCellShapePtr, NIL) } @@ -377,8 +340,7 @@ public open class AStarGrid2D : RefCounted() { } /** - * Returns `true` if the [x] and [y] is a valid grid coordinate (id), i.e. if it is inside - * [region]. Equivalent to `region.has_point(Vector2i(x, y))`. + * Returns `true` if the [x] and [y] is a valid grid coordinate (id), i.e. if it is inside [region]. Equivalent to `region.has_point(Vector2i(x, y))`. */ public final fun isInBounds(x: Int, y: Int): Boolean { TransferContext.writeArguments(LONG to x.toLong(), LONG to y.toLong()) @@ -387,8 +349,7 @@ public open class AStarGrid2D : RefCounted() { } /** - * Returns `true` if the [id] vector is a valid grid coordinate, i.e. if it is inside [region]. - * Equivalent to `region.has_point(id)`. + * Returns `true` if the [id] vector is a valid grid coordinate, i.e. if it is inside [region]. Equivalent to `region.has_point(id)`. */ public final fun isInBoundsv(id: Vector2i): Boolean { TransferContext.writeArguments(VECTOR2I to id) @@ -406,18 +367,16 @@ public open class AStarGrid2D : RefCounted() { } /** - * Updates the internal state of the grid according to the parameters to prepare it to search the - * path. Needs to be called if parameters like [region], [cellSize] or [offset] are changed. - * [isDirty] will return `true` if this is the case and this needs to be called. + * Updates the internal state of the grid according to the parameters to prepare it to search the path. Needs to be called if parameters like [region], [cellSize] or [offset] are changed. [isDirty] will return `true` if this is the case and this needs to be called. * * **Note:** All point data (solidity and weight scale) will be cleared. */ - public final fun update(): Unit { + public final fun update() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.updatePtr, NIL) } - public final fun setJumpingEnabled(enabled: Boolean): Unit { + public final fun setJumpingEnabled(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setJumpingEnabledPtr, NIL) } @@ -428,7 +387,7 @@ public open class AStarGrid2D : RefCounted() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setDiagonalMode(mode: DiagonalMode): Unit { + public final fun setDiagonalMode(mode: DiagonalMode) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setDiagonalModePtr, NIL) } @@ -439,7 +398,7 @@ public open class AStarGrid2D : RefCounted() { return DiagonalMode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setDefaultComputeHeuristic(heuristic: Heuristic): Unit { + public final fun setDefaultComputeHeuristic(heuristic: Heuristic) { TransferContext.writeArguments(LONG to heuristic.id) TransferContext.callMethod(ptr, MethodBindings.setDefaultComputeHeuristicPtr, NIL) } @@ -450,7 +409,7 @@ public open class AStarGrid2D : RefCounted() { return Heuristic.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setDefaultEstimateHeuristic(heuristic: Heuristic): Unit { + public final fun setDefaultEstimateHeuristic(heuristic: Heuristic) { TransferContext.writeArguments(LONG to heuristic.id) TransferContext.callMethod(ptr, MethodBindings.setDefaultEstimateHeuristicPtr, NIL) } @@ -462,13 +421,12 @@ public open class AStarGrid2D : RefCounted() { } /** - * Disables or enables the specified point for pathfinding. Useful for making an obstacle. By - * default, all points are enabled. + * Disables or enables the specified point for pathfinding. Useful for making an obstacle. By default, all points are enabled. * * **Note:** Calling [update] is not needed after the call of this function. */ @JvmOverloads - public final fun setPointSolid(id: Vector2i, solid: Boolean = true): Unit { + public final fun setPointSolid(id: Vector2i, solid: Boolean = true) { TransferContext.writeArguments(VECTOR2I to id, BOOL to solid) TransferContext.callMethod(ptr, MethodBindings.setPointSolidPtr, NIL) } @@ -483,13 +441,11 @@ public open class AStarGrid2D : RefCounted() { } /** - * Sets the [weightScale] for the point with the given [id]. The [weightScale] is multiplied by - * the result of [_computeCost] when determining the overall cost of traveling across a segment from - * a neighboring point to this point. + * Sets the [weightScale] for the point with the given [id]. The [weightScale] is multiplied by the result of [_computeCost] when determining the overall cost of traveling across a segment from a neighboring point to this point. * * **Note:** Calling [update] is not needed after the call of this function. */ - public final fun setPointWeightScale(id: Vector2i, weightScale: Float): Unit { + public final fun setPointWeightScale(id: Vector2i, weightScale: Float) { TransferContext.writeArguments(VECTOR2I to id, DOUBLE to weightScale.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setPointWeightScalePtr, NIL) } @@ -509,7 +465,7 @@ public open class AStarGrid2D : RefCounted() { * **Note:** Calling [update] is not needed after the call of this function. */ @JvmOverloads - public final fun fillSolidRegion(region: Rect2i, solid: Boolean = true): Unit { + public final fun fillSolidRegion(region: Rect2i, solid: Boolean = true) { TransferContext.writeArguments(RECT2I to region, BOOL to solid) TransferContext.callMethod(ptr, MethodBindings.fillSolidRegionPtr, NIL) } @@ -519,7 +475,7 @@ public open class AStarGrid2D : RefCounted() { * * **Note:** Calling [update] is not needed after the call of this function. */ - public final fun fillWeightScaleRegion(region: Rect2i, weightScale: Float): Unit { + public final fun fillWeightScaleRegion(region: Rect2i, weightScale: Float) { TransferContext.writeArguments(RECT2I to region, DOUBLE to weightScale.toDouble()) TransferContext.callMethod(ptr, MethodBindings.fillWeightScaleRegionPtr, NIL) } @@ -527,7 +483,7 @@ public open class AStarGrid2D : RefCounted() { /** * Clears the grid and sets the [region] to `Rect2i(0, 0, 0, 0)`. */ - public final fun clear(): Unit { + public final fun clear() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.clearPtr, NIL) } @@ -542,8 +498,7 @@ public open class AStarGrid2D : RefCounted() { } /** - * Returns an array of dictionaries with point data (`id`: [Vector2i], `position`: [Vector2], - * `solid`: [bool], `weight_scale`: [float]) within a [region]. + * Returns an array of dictionaries with point data (`id`: [Vector2i], `position`: [Vector2], `solid`: [bool], `weight_scale`: [float]) within a [region]. */ public final fun getPointDataInRegion(region: Rect2i): VariantArray> { TransferContext.writeArguments(RECT2I to region) @@ -552,17 +507,13 @@ public open class AStarGrid2D : RefCounted() { } /** - * Returns an array with the points that are in the path found by [AStarGrid2D] between the given - * points. The array is ordered from the starting point to the ending point of the path. + * Returns an array with the points that are in the path found by [AStarGrid2D] between the given points. The array is ordered from the starting point to the ending point of the path. * - * If there is no valid path to the target, and [allowPartialPath] is `true`, returns a path to - * the point closest to the target that can be reached. + * If there is no valid path to the target, and [allowPartialPath] is `true`, returns a path to the point closest to the target that can be reached. * - * **Note:** This method is not thread-safe. If called from a [Thread], it will return an empty - * array and will print an error message. + * **Note:** This method is not thread-safe. If called from a [Thread], it will return an empty array and will print an error message. * - * Additionally, when [allowPartialPath] is `true` and [toId] is solid the search may take an - * unusually long time to finish. + * Additionally, when [allowPartialPath] is `true` and [toId] is solid the search may take an unusually long time to finish. */ @JvmOverloads public final fun getPointPath( @@ -576,14 +527,11 @@ public open class AStarGrid2D : RefCounted() { } /** - * Returns an array with the IDs of the points that form the path found by AStar2D between the - * given points. The array is ordered from the starting point to the ending point of the path. + * Returns an array with the IDs of the points that form the path found by AStar2D between the given points. The array is ordered from the starting point to the ending point of the path. * - * If there is no valid path to the target, and [allowPartialPath] is `true`, returns a path to - * the point closest to the target that can be reached. + * If there is no valid path to the target, and [allowPartialPath] is `true`, returns a path to the point closest to the target that can be reached. * - * **Note:** When [allowPartialPath] is `true` and [toId] is solid the search may take an - * unusually long time to finish. + * **Note:** When [allowPartialPath] is `true` and [toId] is solid the search may take an unusually long time to finish. */ @JvmOverloads public final fun getIdPath( @@ -600,8 +548,7 @@ public open class AStarGrid2D : RefCounted() { id: Long, ) { /** - * The [url=https://en.wikipedia.org/wiki/Euclidean_distance]Euclidean heuristic[/url] to be - * used for the pathfinding using the following formula: + * The [url=https://en.wikipedia.org/wiki/Euclidean_distance]Euclidean heuristic[/url] to be used for the pathfinding using the following formula: * * ``` * dx = abs(to_id.x - from_id.x) @@ -609,13 +556,11 @@ public open class AStarGrid2D : RefCounted() { * result = sqrt(dx * dx + dy * dy) * ``` * - * **Note:** This is also the internal heuristic used in [AStar3D] and [AStar2D] by default - * (with the inclusion of possible z-axis coordinate). + * **Note:** This is also the internal heuristic used in [AStar3D] and [AStar2D] by default (with the inclusion of possible z-axis coordinate). */ EUCLIDEAN(0), /** - * The [url=https://en.wikipedia.org/wiki/Taxicab_geometry]Manhattan heuristic[/url] to be used - * for the pathfinding using the following formula: + * The [url=https://en.wikipedia.org/wiki/Taxicab_geometry]Manhattan heuristic[/url] to be used for the pathfinding using the following formula: * * ``` * dx = abs(to_id.x - from_id.x) @@ -623,8 +568,7 @@ public open class AStarGrid2D : RefCounted() { * result = dx + dy * ``` * - * **Note:** This heuristic is intended to be used with 4-side orthogonal movements, provided by - * setting the [diagonalMode] to [DIAGONAL_MODE_NEVER]. + * **Note:** This heuristic is intended to be used with 4-side orthogonal movements, provided by setting the [diagonalMode] to [DIAGONAL_MODE_NEVER]. */ MANHATTAN(1), /** @@ -639,8 +583,7 @@ public open class AStarGrid2D : RefCounted() { */ OCTILE(2), /** - * The [url=https://en.wikipedia.org/wiki/Chebyshev_distance]Chebyshev heuristic[/url] to be - * used for the pathfinding using the following formula: + * The [url=https://en.wikipedia.org/wiki/Chebyshev_distance]Chebyshev heuristic[/url] to be used for the pathfinding using the following formula: * * ``` * dx = abs(to_id.x - from_id.x) @@ -669,8 +612,7 @@ public open class AStarGrid2D : RefCounted() { id: Long, ) { /** - * The pathfinding algorithm will ignore solid neighbors around the target cell and allow - * passing using diagonals. + * The pathfinding algorithm will ignore solid neighbors around the target cell and allow passing using diagonals. */ ALWAYS(0), /** @@ -678,13 +620,11 @@ public open class AStarGrid2D : RefCounted() { */ NEVER(1), /** - * The pathfinding algorithm will avoid using diagonals if at least two obstacles have been - * placed around the neighboring cells of the specific path segment. + * The pathfinding algorithm will avoid using diagonals if at least two obstacles have been placed around the neighboring cells of the specific path segment. */ AT_LEAST_ONE_WALKABLE(2), /** - * The pathfinding algorithm will avoid using diagonals if any obstacle has been placed around - * the neighboring cells of the specific path segment. + * The pathfinding algorithm will avoid using diagonals if any obstacle has been placed around the neighboring cells of the specific path segment. */ ONLY_IF_NO_OBSTACLES(3), /** @@ -711,13 +651,11 @@ public open class AStarGrid2D : RefCounted() { */ SQUARE(0), /** - * Diamond cell shape (for isometric look). Cell coordinates layout where the horizontal axis - * goes up-right, and the vertical one goes down-right. + * Diamond cell shape (for isometric look). Cell coordinates layout where the horizontal axis goes up-right, and the vertical one goes down-right. */ ISOMETRIC_RIGHT(1), /** - * Diamond cell shape (for isometric look). Cell coordinates layout where the horizontal axis - * goes down-right, and the vertical one goes down-left. + * Diamond cell shape (for isometric look). Cell coordinates layout where the horizontal axis goes down-right, and the vertical one goes down-left. */ ISOMETRIC_DOWN(2), /** @@ -740,102 +678,102 @@ public open class AStarGrid2D : RefCounted() { public object MethodBindings { internal val setRegionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "set_region", 1763793166) + TypeManager.getMethodBindPtr("AStarGrid2D", "set_region", 1_763_793_166) internal val getRegionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "get_region", 410525958) + TypeManager.getMethodBindPtr("AStarGrid2D", "get_region", 410_525_958) internal val setSizePtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "set_size", 1130785943) + TypeManager.getMethodBindPtr("AStarGrid2D", "set_size", 1_130_785_943) internal val getSizePtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "get_size", 3690982128) + TypeManager.getMethodBindPtr("AStarGrid2D", "get_size", 3_690_982_128) internal val setOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "set_offset", 743155724) + TypeManager.getMethodBindPtr("AStarGrid2D", "set_offset", 743_155_724) internal val getOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "get_offset", 3341600327) + TypeManager.getMethodBindPtr("AStarGrid2D", "get_offset", 3_341_600_327) internal val setCellSizePtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "set_cell_size", 743155724) + TypeManager.getMethodBindPtr("AStarGrid2D", "set_cell_size", 743_155_724) internal val getCellSizePtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "get_cell_size", 3341600327) + TypeManager.getMethodBindPtr("AStarGrid2D", "get_cell_size", 3_341_600_327) internal val setCellShapePtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "set_cell_shape", 4130591146) + TypeManager.getMethodBindPtr("AStarGrid2D", "set_cell_shape", 4_130_591_146) internal val getCellShapePtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "get_cell_shape", 3293463634) + TypeManager.getMethodBindPtr("AStarGrid2D", "get_cell_shape", 3_293_463_634) internal val isInBoundsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "is_in_bounds", 2522259332) + TypeManager.getMethodBindPtr("AStarGrid2D", "is_in_bounds", 2_522_259_332) internal val isInBoundsvPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "is_in_boundsv", 3900751641) + TypeManager.getMethodBindPtr("AStarGrid2D", "is_in_boundsv", 3_900_751_641) internal val isDirtyPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "is_dirty", 36873697) + TypeManager.getMethodBindPtr("AStarGrid2D", "is_dirty", 36_873_697) internal val updatePtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "update", 3218959716) + TypeManager.getMethodBindPtr("AStarGrid2D", "update", 3_218_959_716) internal val setJumpingEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "set_jumping_enabled", 2586408642) + TypeManager.getMethodBindPtr("AStarGrid2D", "set_jumping_enabled", 2_586_408_642) internal val isJumpingEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "is_jumping_enabled", 36873697) + TypeManager.getMethodBindPtr("AStarGrid2D", "is_jumping_enabled", 36_873_697) internal val setDiagonalModePtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "set_diagonal_mode", 1017829798) + TypeManager.getMethodBindPtr("AStarGrid2D", "set_diagonal_mode", 1_017_829_798) internal val getDiagonalModePtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "get_diagonal_mode", 3129282674) + TypeManager.getMethodBindPtr("AStarGrid2D", "get_diagonal_mode", 3_129_282_674) internal val setDefaultComputeHeuristicPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "set_default_compute_heuristic", 1044375519) + TypeManager.getMethodBindPtr("AStarGrid2D", "set_default_compute_heuristic", 1_044_375_519) internal val getDefaultComputeHeuristicPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "get_default_compute_heuristic", 2074731422) + TypeManager.getMethodBindPtr("AStarGrid2D", "get_default_compute_heuristic", 2_074_731_422) internal val setDefaultEstimateHeuristicPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "set_default_estimate_heuristic", 1044375519) + TypeManager.getMethodBindPtr("AStarGrid2D", "set_default_estimate_heuristic", 1_044_375_519) internal val getDefaultEstimateHeuristicPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "get_default_estimate_heuristic", 2074731422) + TypeManager.getMethodBindPtr("AStarGrid2D", "get_default_estimate_heuristic", 2_074_731_422) internal val setPointSolidPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "set_point_solid", 1765703753) + TypeManager.getMethodBindPtr("AStarGrid2D", "set_point_solid", 1_765_703_753) internal val isPointSolidPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "is_point_solid", 3900751641) + TypeManager.getMethodBindPtr("AStarGrid2D", "is_point_solid", 3_900_751_641) internal val setPointWeightScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "set_point_weight_scale", 2262553149) + TypeManager.getMethodBindPtr("AStarGrid2D", "set_point_weight_scale", 2_262_553_149) internal val getPointWeightScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "get_point_weight_scale", 719993801) + TypeManager.getMethodBindPtr("AStarGrid2D", "get_point_weight_scale", 719_993_801) internal val fillSolidRegionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "fill_solid_region", 2261970063) + TypeManager.getMethodBindPtr("AStarGrid2D", "fill_solid_region", 2_261_970_063) internal val fillWeightScaleRegionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "fill_weight_scale_region", 2793244083) + TypeManager.getMethodBindPtr("AStarGrid2D", "fill_weight_scale_region", 2_793_244_083) internal val clearPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "clear", 3218959716) + TypeManager.getMethodBindPtr("AStarGrid2D", "clear", 3_218_959_716) internal val getPointPositionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "get_point_position", 108438297) + TypeManager.getMethodBindPtr("AStarGrid2D", "get_point_position", 108_438_297) internal val getPointDataInRegionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "get_point_data_in_region", 3893818462) + TypeManager.getMethodBindPtr("AStarGrid2D", "get_point_data_in_region", 3_893_818_462) internal val getPointPathPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "get_point_path", 1641925693) + TypeManager.getMethodBindPtr("AStarGrid2D", "get_point_path", 1_641_925_693) internal val getIdPathPtr: VoidPtr = - TypeManager.getMethodBindPtr("AStarGrid2D", "get_id_path", 1918132273) + TypeManager.getMethodBindPtr("AStarGrid2D", "get_id_path", 1_918_132_273) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AcceptDialog.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AcceptDialog.kt index 1f29ca30a1..beb1c1be4a 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AcceptDialog.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AcceptDialog.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -21,14 +18,11 @@ import kotlin.Boolean import kotlin.Int import kotlin.String import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName import kotlin.jvm.JvmOverloads /** - * The default use of [AcceptDialog] is to allow it to only be accepted or closed, with the same - * result. However, the [signal confirmed] and [signal canceled] signals allow to make the two actions - * different, and the [addButton] method allows to add custom buttons and actions. + * The default use of [AcceptDialog] is to allow it to only be accepted or closed, with the same result. However, the [signal confirmed] and [signal canceled] signals allow to make the two actions different, and the [addButton] method allows to add custom buttons and actions. */ @GodotBaseType public open class AcceptDialog : Window() { @@ -70,15 +64,9 @@ public open class AcceptDialog : Window() { } /** - * If `true`, the dialog is hidden when the OK button is pressed. You can set it to `false` if you - * want to do e.g. input validation when receiving the [signal confirmed] signal, and handle hiding - * the dialog in your own logic. + * If `true`, the dialog is hidden when the OK button is pressed. You can set it to `false` if you want to do e.g. input validation when receiving the [signal confirmed] signal, and handle hiding the dialog in your own logic. * - * **Note:** Some nodes derived from this class can have a different default value, and - * potentially their own built-in logic overriding this setting. For example [FileDialog] defaults to - * `false`, and has its own input validation code that is called when you press OK, which eventually - * hides the dialog if the input is valid. As such, this property can't be used in [FileDialog] to - * disable hiding the dialog when pressing OK. + * **Note:** Some nodes derived from this class can have a different default value, and potentially their own built-in logic overriding this setting. For example [FileDialog] defaults to `false`, and has its own input validation code that is called when you press OK, which eventually hides the dialog if the input is valid. As such, this property can't be used in [FileDialog] to disable hiding the dialog when pressing OK. */ public final inline var dialogHideOnOk: Boolean @JvmName("dialogHideOnOkProperty") @@ -110,15 +98,14 @@ public open class AcceptDialog : Window() { setAutowrap(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(6, scriptIndex) } /** * Returns the OK [Button] instance. * - * **Warning:** This is a required internal node, removing and freeing it may cause a crash. If - * you wish to hide it or any of its children, use their [CanvasItem.visible] property. + * **Warning:** This is a required internal node, removing and freeing it may cause a crash. If you wish to hide it or any of its children, use their [CanvasItem.visible] property. */ public final fun getOkButton(): Button? { TransferContext.writeArguments() @@ -129,8 +116,7 @@ public open class AcceptDialog : Window() { /** * Returns the label used for built-in text. * - * **Warning:** This is a required internal node, removing and freeing it may cause a crash. If - * you wish to hide it or any of its children, use their [CanvasItem.visible] property. + * **Warning:** This is a required internal node, removing and freeing it may cause a crash. If you wish to hide it or any of its children, use their [CanvasItem.visible] property. */ public final fun getLabel(): Label? { TransferContext.writeArguments() @@ -138,7 +124,7 @@ public open class AcceptDialog : Window() { return (TransferContext.readReturnValue(OBJECT) as Label?) } - public final fun setHideOnOk(enabled: Boolean): Unit { + public final fun setHideOnOk(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setHideOnOkPtr, NIL) } @@ -149,7 +135,7 @@ public open class AcceptDialog : Window() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setCloseOnEscape(enabled: Boolean): Unit { + public final fun setCloseOnEscape(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setCloseOnEscapePtr, NIL) } @@ -161,8 +147,7 @@ public open class AcceptDialog : Window() { } /** - * Adds a button with label [text] and a custom [action] to the dialog and returns the created - * button. [action] will be passed to the [signal custom_action] signal when pressed. + * Adds a button with label [text] and a custom [action] to the dialog and returns the created button. [action] will be passed to the [signal custom_action] signal when pressed. * * If `true`, [right] will place the button to the right of any sibling buttons. * @@ -180,8 +165,7 @@ public open class AcceptDialog : Window() { } /** - * Adds a button with label [name] and a cancel action to the dialog and returns the created - * button. + * Adds a button with label [name] and a cancel action to the dialog and returns the created button. * * You can use [removeButton] method to remove a button created with this method from the dialog. */ @@ -192,25 +176,22 @@ public open class AcceptDialog : Window() { } /** - * Removes the [button] from the dialog. Does NOT free the [button]. The [button] must be a - * [Button] added with [addButton] or [addCancelButton] method. After removal, pressing the [button] - * will no longer emit this dialog's [signal custom_action] or [signal canceled] signals. + * Removes the [button] from the dialog. Does NOT free the [button]. The [button] must be a [Button] added with [addButton] or [addCancelButton] method. After removal, pressing the [button] will no longer emit this dialog's [signal custom_action] or [signal canceled] signals. */ - public final fun removeButton(button: Button?): Unit { + public final fun removeButton(button: Button?) { TransferContext.writeArguments(OBJECT to button) TransferContext.callMethod(ptr, MethodBindings.removeButtonPtr, NIL) } /** - * Registers a [LineEdit] in the dialog. When the enter key is pressed, the dialog will be - * accepted. + * Registers a [LineEdit] in the dialog. When the enter key is pressed, the dialog will be accepted. */ - public final fun registerTextEnter(lineEdit: LineEdit?): Unit { + public final fun registerTextEnter(lineEdit: LineEdit?) { TransferContext.writeArguments(OBJECT to lineEdit) TransferContext.callMethod(ptr, MethodBindings.registerTextEnterPtr, NIL) } - public final fun setText(text: String): Unit { + public final fun setText(text: String) { TransferContext.writeArguments(STRING to text) TransferContext.callMethod(ptr, MethodBindings.setTextPtr, NIL) } @@ -221,7 +202,7 @@ public open class AcceptDialog : Window() { return (TransferContext.readReturnValue(STRING) as String) } - public final fun setAutowrap(autowrap: Boolean): Unit { + public final fun setAutowrap(autowrap: Boolean) { TransferContext.writeArguments(BOOL to autowrap) TransferContext.callMethod(ptr, MethodBindings.setAutowrapPtr, NIL) } @@ -232,7 +213,7 @@ public open class AcceptDialog : Window() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setOkButtonText(text: String): Unit { + public final fun setOkButtonText(text: String) { TransferContext.writeArguments(STRING to text) TransferContext.callMethod(ptr, MethodBindings.setOkButtonTextPtr, NIL) } @@ -247,51 +228,51 @@ public open class AcceptDialog : Window() { public object MethodBindings { internal val getOkButtonPtr: VoidPtr = - TypeManager.getMethodBindPtr("AcceptDialog", "get_ok_button", 1856205918) + TypeManager.getMethodBindPtr("AcceptDialog", "get_ok_button", 1_856_205_918) internal val getLabelPtr: VoidPtr = - TypeManager.getMethodBindPtr("AcceptDialog", "get_label", 566733104) + TypeManager.getMethodBindPtr("AcceptDialog", "get_label", 566_733_104) internal val setHideOnOkPtr: VoidPtr = - TypeManager.getMethodBindPtr("AcceptDialog", "set_hide_on_ok", 2586408642) + TypeManager.getMethodBindPtr("AcceptDialog", "set_hide_on_ok", 2_586_408_642) internal val getHideOnOkPtr: VoidPtr = - TypeManager.getMethodBindPtr("AcceptDialog", "get_hide_on_ok", 36873697) + TypeManager.getMethodBindPtr("AcceptDialog", "get_hide_on_ok", 36_873_697) internal val setCloseOnEscapePtr: VoidPtr = - TypeManager.getMethodBindPtr("AcceptDialog", "set_close_on_escape", 2586408642) + TypeManager.getMethodBindPtr("AcceptDialog", "set_close_on_escape", 2_586_408_642) internal val getCloseOnEscapePtr: VoidPtr = - TypeManager.getMethodBindPtr("AcceptDialog", "get_close_on_escape", 36873697) + TypeManager.getMethodBindPtr("AcceptDialog", "get_close_on_escape", 36_873_697) internal val addButtonPtr: VoidPtr = - TypeManager.getMethodBindPtr("AcceptDialog", "add_button", 3328440682) + TypeManager.getMethodBindPtr("AcceptDialog", "add_button", 3_328_440_682) internal val addCancelButtonPtr: VoidPtr = - TypeManager.getMethodBindPtr("AcceptDialog", "add_cancel_button", 242045556) + TypeManager.getMethodBindPtr("AcceptDialog", "add_cancel_button", 242_045_556) internal val removeButtonPtr: VoidPtr = - TypeManager.getMethodBindPtr("AcceptDialog", "remove_button", 2068354942) + TypeManager.getMethodBindPtr("AcceptDialog", "remove_button", 2_068_354_942) internal val registerTextEnterPtr: VoidPtr = - TypeManager.getMethodBindPtr("AcceptDialog", "register_text_enter", 3714008017) + TypeManager.getMethodBindPtr("AcceptDialog", "register_text_enter", 3_714_008_017) internal val setTextPtr: VoidPtr = - TypeManager.getMethodBindPtr("AcceptDialog", "set_text", 83702148) + TypeManager.getMethodBindPtr("AcceptDialog", "set_text", 83_702_148) internal val getTextPtr: VoidPtr = - TypeManager.getMethodBindPtr("AcceptDialog", "get_text", 201670096) + TypeManager.getMethodBindPtr("AcceptDialog", "get_text", 201_670_096) internal val setAutowrapPtr: VoidPtr = - TypeManager.getMethodBindPtr("AcceptDialog", "set_autowrap", 2586408642) + TypeManager.getMethodBindPtr("AcceptDialog", "set_autowrap", 2_586_408_642) internal val hasAutowrapPtr: VoidPtr = - TypeManager.getMethodBindPtr("AcceptDialog", "has_autowrap", 2240911060) + TypeManager.getMethodBindPtr("AcceptDialog", "has_autowrap", 2_240_911_060) internal val setOkButtonTextPtr: VoidPtr = - TypeManager.getMethodBindPtr("AcceptDialog", "set_ok_button_text", 83702148) + TypeManager.getMethodBindPtr("AcceptDialog", "set_ok_button_text", 83_702_148) internal val getOkButtonTextPtr: VoidPtr = - TypeManager.getMethodBindPtr("AcceptDialog", "get_ok_button_text", 201670096) + TypeManager.getMethodBindPtr("AcceptDialog", "get_ok_button_text", 201_670_096) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimatableBody2D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimatableBody2D.kt index 3014f1bd5e..44284b0a1a 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimatableBody2D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimatableBody2D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -15,24 +12,17 @@ import godot.core.VariantParser.NIL import kotlin.Boolean import kotlin.Int import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * An animatable 2D physics body. It can't be moved by external forces or contacts, but can be moved - * manually by other means such as code, [AnimationMixer]s (with [AnimationMixer.callbackModeProcess] - * set to [AnimationMixer.ANIMATION_CALLBACK_MODE_PROCESS_PHYSICS]), and [RemoteTransform2D]. + * An animatable 2D physics body. It can't be moved by external forces or contacts, but can be moved manually by other means such as code, [AnimationMixer]s (with [AnimationMixer.callbackModeProcess] set to [AnimationMixer.ANIMATION_CALLBACK_MODE_PROCESS_PHYSICS]), and [RemoteTransform2D]. * - * When [AnimatableBody2D] is moved, its linear and angular velocity are estimated and used to - * affect other physics bodies in its path. This makes it useful for moving platforms, doors, and other - * moving objects. + * When [AnimatableBody2D] is moved, its linear and angular velocity are estimated and used to affect other physics bodies in its path. This makes it useful for moving platforms, doors, and other moving objects. */ @GodotBaseType public open class AnimatableBody2D : StaticBody2D() { /** - * If `true`, the body's movement will be synchronized to the physics frame. This is useful when - * animating movement via [AnimationPlayer], for example on moving platforms. Do **not** use together - * with [PhysicsBody2D.moveAndCollide]. + * If `true`, the body's movement will be synchronized to the physics frame. This is useful when animating movement via [AnimationPlayer], for example on moving platforms. Do **not** use together with [PhysicsBody2D.moveAndCollide]. */ public final inline var syncToPhysics: Boolean @JvmName("syncToPhysicsProperty") @@ -42,11 +32,11 @@ public open class AnimatableBody2D : StaticBody2D() { setSyncToPhysics(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(7, scriptIndex) } - public final fun setSyncToPhysics(enable: Boolean): Unit { + public final fun setSyncToPhysics(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setSyncToPhysicsPtr, NIL) } @@ -61,9 +51,9 @@ public open class AnimatableBody2D : StaticBody2D() { public object MethodBindings { internal val setSyncToPhysicsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatableBody2D", "set_sync_to_physics", 2586408642) + TypeManager.getMethodBindPtr("AnimatableBody2D", "set_sync_to_physics", 2_586_408_642) internal val isSyncToPhysicsEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatableBody2D", "is_sync_to_physics_enabled", 36873697) + TypeManager.getMethodBindPtr("AnimatableBody2D", "is_sync_to_physics_enabled", 36_873_697) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimatableBody3D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimatableBody3D.kt index a454c651dc..436418f324 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimatableBody3D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimatableBody3D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -15,24 +12,17 @@ import godot.core.VariantParser.NIL import kotlin.Boolean import kotlin.Int import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * An animatable 3D physics body. It can't be moved by external forces or contacts, but can be moved - * manually by other means such as code, [AnimationMixer]s (with [AnimationMixer.callbackModeProcess] - * set to [AnimationMixer.ANIMATION_CALLBACK_MODE_PROCESS_PHYSICS]), and [RemoteTransform3D]. + * An animatable 3D physics body. It can't be moved by external forces or contacts, but can be moved manually by other means such as code, [AnimationMixer]s (with [AnimationMixer.callbackModeProcess] set to [AnimationMixer.ANIMATION_CALLBACK_MODE_PROCESS_PHYSICS]), and [RemoteTransform3D]. * - * When [AnimatableBody3D] is moved, its linear and angular velocity are estimated and used to - * affect other physics bodies in its path. This makes it useful for moving platforms, doors, and other - * moving objects. + * When [AnimatableBody3D] is moved, its linear and angular velocity are estimated and used to affect other physics bodies in its path. This makes it useful for moving platforms, doors, and other moving objects. */ @GodotBaseType public open class AnimatableBody3D : StaticBody3D() { /** - * If `true`, the body's movement will be synchronized to the physics frame. This is useful when - * animating movement via [AnimationPlayer], for example on moving platforms. Do **not** use together - * with [PhysicsBody3D.moveAndCollide]. + * If `true`, the body's movement will be synchronized to the physics frame. This is useful when animating movement via [AnimationPlayer], for example on moving platforms. Do **not** use together with [PhysicsBody3D.moveAndCollide]. */ public final inline var syncToPhysics: Boolean @JvmName("syncToPhysicsProperty") @@ -42,11 +32,11 @@ public open class AnimatableBody3D : StaticBody3D() { setSyncToPhysics(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(8, scriptIndex) } - public final fun setSyncToPhysics(enable: Boolean): Unit { + public final fun setSyncToPhysics(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setSyncToPhysicsPtr, NIL) } @@ -61,9 +51,9 @@ public open class AnimatableBody3D : StaticBody3D() { public object MethodBindings { internal val setSyncToPhysicsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatableBody3D", "set_sync_to_physics", 2586408642) + TypeManager.getMethodBindPtr("AnimatableBody3D", "set_sync_to_physics", 2_586_408_642) internal val isSyncToPhysicsEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatableBody3D", "is_sync_to_physics_enabled", 36873697) + TypeManager.getMethodBindPtr("AnimatableBody3D", "is_sync_to_physics_enabled", 36_873_697) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimatedSprite2D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimatedSprite2D.kt index fc72f78c94..3732a57b23 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimatedSprite2D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimatedSprite2D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -36,10 +33,7 @@ import kotlin.jvm.JvmName import kotlin.jvm.JvmOverloads /** - * [AnimatedSprite2D] is similar to the [Sprite2D] node, except it carries multiple textures as - * animation frames. Animations are created using a [SpriteFrames] resource, which allows you to import - * image files (or a folder containing said files) to provide the animation frames for the sprite. The - * [SpriteFrames] resource can be configured in the editor via the SpriteFrames bottom panel. + * [AnimatedSprite2D] is similar to the [Sprite2D] node, except it carries multiple textures as animation frames. Animations are created using a [SpriteFrames] resource, which allows you to import image files (or a folder containing said files) to provide the animation frames for the sprite. The [SpriteFrames] resource can be configured in the editor via the SpriteFrames bottom panel. */ @GodotBaseType public open class AnimatedSprite2D : Node2D() { @@ -64,16 +58,14 @@ public open class AnimatedSprite2D : Node2D() { public val animationLooped: Signal0 by Signal0 /** - * Emitted when the animation reaches the end, or the start if it is played in reverse. When the - * animation finishes, it pauses the playback. + * Emitted when the animation reaches the end, or the start if it is played in reverse. When the animation finishes, it pauses the playback. * * **Note:** This signal is not emitted if an animation is looping. */ public val animationFinished: Signal0 by Signal0 /** - * The [SpriteFrames] resource containing the animation(s). Allows you the option to load, edit, - * clear, make unique and save the states of the [SpriteFrames] resource. + * The [SpriteFrames] resource containing the animation(s). Allows you the option to load, edit, clear, make unique and save the states of the [SpriteFrames] resource. */ public final inline var spriteFrames: SpriteFrames? @JvmName("spriteFramesProperty") @@ -84,8 +76,7 @@ public open class AnimatedSprite2D : Node2D() { } /** - * The current animation from the [spriteFrames] resource. If this value is changed, the [frame] - * counter and the [frameProgress] are reset. + * The current animation from the [spriteFrames] resource. If this value is changed, the [frame] counter and the [frameProgress] are reset. */ public final inline var animation: StringName @JvmName("animationProperty") @@ -107,8 +98,7 @@ public open class AnimatedSprite2D : Node2D() { } /** - * The displayed animation frame's index. Setting this property also resets [frameProgress]. If - * this is not desired, use [setFrameAndProgress]. + * The displayed animation frame's index. Setting this property also resets [frameProgress]. If this is not desired, use [setFrameAndProgress]. */ public final inline var frame: Int @JvmName("frameProperty") @@ -119,8 +109,7 @@ public open class AnimatedSprite2D : Node2D() { } /** - * The progress value between `0.0` and `1.0` until the current frame transitions to the next - * frame. If the animation is playing backwards, the value transitions from `1.0` to `0.0`. + * The progress value between `0.0` and `1.0` until the current frame transitions to the next frame. If the animation is playing backwards, the value transitions from `1.0` to `0.0`. */ public final inline var frameProgress: Float @JvmName("frameProgressProperty") @@ -131,11 +120,9 @@ public open class AnimatedSprite2D : Node2D() { } /** - * The speed scaling ratio. For example, if this value is `1`, then the animation plays at normal - * speed. If it's `0.5`, then it plays at half speed. If it's `2`, then it plays at double speed. + * The speed scaling ratio. For example, if this value is `1`, then the animation plays at normal speed. If it's `0.5`, then it plays at half speed. If it's `2`, then it plays at double speed. * - * If set to a negative value, the animation is played in reverse. If set to `0`, the animation - * will not advance. + * If set to a negative value, the animation is played in reverse. If set to `0`, the animation will not advance. */ public final inline var speedScale: Float @JvmName("speedScaleProperty") @@ -148,10 +135,7 @@ public open class AnimatedSprite2D : Node2D() { /** * If `true`, texture will be centered. * - * **Note:** For games with a pixel art aesthetic, textures may appear deformed when centered. - * This is caused by their position being between pixels. To prevent this, set this property to - * `false`, or consider enabling [ProjectSettings.rendering/2d/snap/snap2dVerticesToPixel] and - * [ProjectSettings.rendering/2d/snap/snap2dTransformsToPixel]. + * **Note:** For games with a pixel art aesthetic, textures may appear deformed when centered. This is caused by their position being between pixels. To prevent this, set this property to `false`, or consider enabling [ProjectSettings.rendering/2d/snap/snap2dVerticesToPixel] and [ProjectSettings.rendering/2d/snap/snap2dTransformsToPixel]. */ public final inline var centered: Boolean @JvmName("centeredProperty") @@ -165,11 +149,8 @@ public open class AnimatedSprite2D : Node2D() { * The texture's drawing offset. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var offset: Vector2 @@ -202,7 +183,7 @@ public open class AnimatedSprite2D : Node2D() { setFlipV(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(9, scriptIndex) } @@ -225,7 +206,7 @@ public open class AnimatedSprite2D : Node2D() { offset = this } - public final fun setSpriteFrames(spriteFrames: SpriteFrames?): Unit { + public final fun setSpriteFrames(spriteFrames: SpriteFrames?) { TransferContext.writeArguments(OBJECT to spriteFrames) TransferContext.callMethod(ptr, MethodBindings.setSpriteFramesPtr, NIL) } @@ -236,7 +217,7 @@ public open class AnimatedSprite2D : Node2D() { return (TransferContext.readReturnValue(OBJECT) as SpriteFrames?) } - public final fun setAnimation(name: StringName): Unit { + public final fun setAnimation(name: StringName) { TransferContext.writeArguments(STRING_NAME to name) TransferContext.callMethod(ptr, MethodBindings.setAnimationPtr, NIL) } @@ -247,7 +228,7 @@ public open class AnimatedSprite2D : Node2D() { return (TransferContext.readReturnValue(STRING_NAME) as StringName) } - public final fun setAutoplay(name: String): Unit { + public final fun setAutoplay(name: String) { TransferContext.writeArguments(STRING to name) TransferContext.callMethod(ptr, MethodBindings.setAutoplayPtr, NIL) } @@ -259,8 +240,7 @@ public open class AnimatedSprite2D : Node2D() { } /** - * Returns `true` if an animation is currently playing (even if [speedScale] and/or `custom_speed` - * are `0`). + * Returns `true` if an animation is currently playing (even if [speedScale] and/or `custom_speed` are `0`). */ public final fun isPlaying(): Boolean { TransferContext.writeArguments() @@ -269,18 +249,16 @@ public open class AnimatedSprite2D : Node2D() { } /** - * Plays the animation with key [name]. If [customSpeed] is negative and [fromEnd] is `true`, the - * animation will play backwards (which is equivalent to calling [playBackwards]). + * Plays the animation with key [name]. If [customSpeed] is negative and [fromEnd] is `true`, the animation will play backwards (which is equivalent to calling [playBackwards]). * - * If this method is called with that same animation [name], or with no [name] parameter, the - * assigned animation will resume playing if it was paused. + * If this method is called with that same animation [name], or with no [name] parameter, the assigned animation will resume playing if it was paused. */ @JvmOverloads public final fun play( name: StringName = StringName(""), customSpeed: Float = 1.0f, fromEnd: Boolean = false, - ): Unit { + ) { TransferContext.writeArguments(STRING_NAME to name, DOUBLE to customSpeed.toDouble(), BOOL to fromEnd) TransferContext.callMethod(ptr, MethodBindings.playPtr, NIL) } @@ -288,36 +266,32 @@ public open class AnimatedSprite2D : Node2D() { /** * Plays the animation with key [name] in reverse. * - * This method is a shorthand for [play] with `custom_speed = -1.0` and `from_end = true`, so see - * its description for more information. + * This method is a shorthand for [play] with `custom_speed = -1.0` and `from_end = true`, so see its description for more information. */ - public final fun playBackwards(name: StringName = StringName("")): Unit { + public final fun playBackwards(name: StringName = StringName("")) { TransferContext.writeArguments(STRING_NAME to name) TransferContext.callMethod(ptr, MethodBindings.playBackwardsPtr, NIL) } /** - * Pauses the currently playing animation. The [frame] and [frameProgress] will be kept and - * calling [play] or [playBackwards] without arguments will resume the animation from the current - * playback position. + * Pauses the currently playing animation. The [frame] and [frameProgress] will be kept and calling [play] or [playBackwards] without arguments will resume the animation from the current playback position. * * See also [stop]. */ - public final fun pause(): Unit { + public final fun pause() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.pausePtr, NIL) } /** - * Stops the currently playing animation. The animation position is reset to `0` and the - * `custom_speed` is reset to `1.0`. See also [pause]. + * Stops the currently playing animation. The animation position is reset to `0` and the `custom_speed` is reset to `1.0`. See also [pause]. */ - public final fun stop(): Unit { + public final fun stop() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.stopPtr, NIL) } - public final fun setCentered(centered: Boolean): Unit { + public final fun setCentered(centered: Boolean) { TransferContext.writeArguments(BOOL to centered) TransferContext.callMethod(ptr, MethodBindings.setCenteredPtr, NIL) } @@ -328,7 +302,7 @@ public open class AnimatedSprite2D : Node2D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setOffset(offset: Vector2): Unit { + public final fun setOffset(offset: Vector2) { TransferContext.writeArguments(VECTOR2 to offset) TransferContext.callMethod(ptr, MethodBindings.setOffsetPtr, NIL) } @@ -339,7 +313,7 @@ public open class AnimatedSprite2D : Node2D() { return (TransferContext.readReturnValue(VECTOR2) as Vector2) } - public final fun setFlipH(flipH: Boolean): Unit { + public final fun setFlipH(flipH: Boolean) { TransferContext.writeArguments(BOOL to flipH) TransferContext.callMethod(ptr, MethodBindings.setFlipHPtr, NIL) } @@ -350,7 +324,7 @@ public open class AnimatedSprite2D : Node2D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setFlipV(flipV: Boolean): Unit { + public final fun setFlipV(flipV: Boolean) { TransferContext.writeArguments(BOOL to flipV) TransferContext.callMethod(ptr, MethodBindings.setFlipVPtr, NIL) } @@ -361,7 +335,7 @@ public open class AnimatedSprite2D : Node2D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setFrame(frame: Int): Unit { + public final fun setFrame(frame: Int) { TransferContext.writeArguments(LONG to frame.toLong()) TransferContext.callMethod(ptr, MethodBindings.setFramePtr, NIL) } @@ -372,7 +346,7 @@ public open class AnimatedSprite2D : Node2D() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setFrameProgress(progress: Float): Unit { + public final fun setFrameProgress(progress: Float) { TransferContext.writeArguments(DOUBLE to progress.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setFrameProgressPtr, NIL) } @@ -384,8 +358,7 @@ public open class AnimatedSprite2D : Node2D() { } /** - * Sets [frame] the [frameProgress] to the given values. Unlike setting [frame], this method does - * not reset the [frameProgress] to `0.0` implicitly. + * Sets [frame] the [frameProgress] to the given values. Unlike setting [frame], this method does not reset the [frameProgress] to `0.0` implicitly. * * **Example:** Change the animation while keeping the same [frame] and [frameProgress]: * @@ -397,12 +370,12 @@ public open class AnimatedSprite2D : Node2D() { * animated_sprite.set_frame_and_progress(current_frame, current_progress) * ``` */ - public final fun setFrameAndProgress(frame: Int, progress: Float): Unit { + public final fun setFrameAndProgress(frame: Int, progress: Float) { TransferContext.writeArguments(LONG to frame.toLong(), DOUBLE to progress.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setFrameAndProgressPtr, NIL) } - public final fun setSpeedScale(speedScale: Float): Unit { + public final fun setSpeedScale(speedScale: Float) { TransferContext.writeArguments(DOUBLE to speedScale.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setSpeedScalePtr, NIL) } @@ -414,9 +387,7 @@ public open class AnimatedSprite2D : Node2D() { } /** - * Returns the actual playing speed of current animation or `0` if not playing. This speed is the - * [speedScale] property multiplied by `custom_speed` argument specified when calling the [play] - * method. + * Returns the actual playing speed of current animation or `0` if not playing. This speed is the [speedScale] property multiplied by `custom_speed` argument specified when calling the [play] method. * * Returns a negative value if the current animation is playing backwards. */ @@ -426,112 +397,109 @@ public open class AnimatedSprite2D : Node2D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setAnimation(name: String) = setAnimation(name.asCachedStringName()) + public final fun setAnimation(name: String): Unit = setAnimation(name.asCachedStringName()) /** - * Plays the animation with key [name]. If [customSpeed] is negative and [fromEnd] is `true`, the - * animation will play backwards (which is equivalent to calling [playBackwards]). + * Plays the animation with key [name]. If [customSpeed] is negative and [fromEnd] is `true`, the animation will play backwards (which is equivalent to calling [playBackwards]). * - * If this method is called with that same animation [name], or with no [name] parameter, the - * assigned animation will resume playing if it was paused. + * If this method is called with that same animation [name], or with no [name] parameter, the assigned animation will resume playing if it was paused. */ @JvmOverloads public final fun play( name: String, customSpeed: Float = 1.0f, fromEnd: Boolean = false, - ) = play(name.asCachedStringName(), customSpeed, fromEnd) + ): Unit = play(name.asCachedStringName(), customSpeed, fromEnd) /** * Plays the animation with key [name] in reverse. * - * This method is a shorthand for [play] with `custom_speed = -1.0` and `from_end = true`, so see - * its description for more information. + * This method is a shorthand for [play] with `custom_speed = -1.0` and `from_end = true`, so see its description for more information. */ - public final fun playBackwards(name: String) = playBackwards(name.asCachedStringName()) + public final fun playBackwards(name: String): Unit = playBackwards(name.asCachedStringName()) public companion object public object MethodBindings { internal val setSpriteFramesPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite2D", "set_sprite_frames", 905781144) + TypeManager.getMethodBindPtr("AnimatedSprite2D", "set_sprite_frames", 905_781_144) internal val getSpriteFramesPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite2D", "get_sprite_frames", 3804851214) + TypeManager.getMethodBindPtr("AnimatedSprite2D", "get_sprite_frames", 3_804_851_214) internal val setAnimationPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite2D", "set_animation", 3304788590) + TypeManager.getMethodBindPtr("AnimatedSprite2D", "set_animation", 3_304_788_590) internal val getAnimationPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite2D", "get_animation", 2002593661) + TypeManager.getMethodBindPtr("AnimatedSprite2D", "get_animation", 2_002_593_661) internal val setAutoplayPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite2D", "set_autoplay", 83702148) + TypeManager.getMethodBindPtr("AnimatedSprite2D", "set_autoplay", 83_702_148) internal val getAutoplayPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite2D", "get_autoplay", 201670096) + TypeManager.getMethodBindPtr("AnimatedSprite2D", "get_autoplay", 201_670_096) internal val isPlayingPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite2D", "is_playing", 36873697) + TypeManager.getMethodBindPtr("AnimatedSprite2D", "is_playing", 36_873_697) internal val playPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite2D", "play", 3269405555) + TypeManager.getMethodBindPtr("AnimatedSprite2D", "play", 3_269_405_555) internal val playBackwardsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite2D", "play_backwards", 3323268493) + TypeManager.getMethodBindPtr("AnimatedSprite2D", "play_backwards", 3_323_268_493) internal val pausePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite2D", "pause", 3218959716) + TypeManager.getMethodBindPtr("AnimatedSprite2D", "pause", 3_218_959_716) internal val stopPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite2D", "stop", 3218959716) + TypeManager.getMethodBindPtr("AnimatedSprite2D", "stop", 3_218_959_716) internal val setCenteredPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite2D", "set_centered", 2586408642) + TypeManager.getMethodBindPtr("AnimatedSprite2D", "set_centered", 2_586_408_642) internal val isCenteredPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite2D", "is_centered", 36873697) + TypeManager.getMethodBindPtr("AnimatedSprite2D", "is_centered", 36_873_697) internal val setOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite2D", "set_offset", 743155724) + TypeManager.getMethodBindPtr("AnimatedSprite2D", "set_offset", 743_155_724) internal val getOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite2D", "get_offset", 3341600327) + TypeManager.getMethodBindPtr("AnimatedSprite2D", "get_offset", 3_341_600_327) internal val setFlipHPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite2D", "set_flip_h", 2586408642) + TypeManager.getMethodBindPtr("AnimatedSprite2D", "set_flip_h", 2_586_408_642) internal val isFlippedHPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite2D", "is_flipped_h", 36873697) + TypeManager.getMethodBindPtr("AnimatedSprite2D", "is_flipped_h", 36_873_697) internal val setFlipVPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite2D", "set_flip_v", 2586408642) + TypeManager.getMethodBindPtr("AnimatedSprite2D", "set_flip_v", 2_586_408_642) internal val isFlippedVPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite2D", "is_flipped_v", 36873697) + TypeManager.getMethodBindPtr("AnimatedSprite2D", "is_flipped_v", 36_873_697) internal val setFramePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite2D", "set_frame", 1286410249) + TypeManager.getMethodBindPtr("AnimatedSprite2D", "set_frame", 1_286_410_249) internal val getFramePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite2D", "get_frame", 3905245786) + TypeManager.getMethodBindPtr("AnimatedSprite2D", "get_frame", 3_905_245_786) internal val setFrameProgressPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite2D", "set_frame_progress", 373806689) + TypeManager.getMethodBindPtr("AnimatedSprite2D", "set_frame_progress", 373_806_689) internal val getFrameProgressPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite2D", "get_frame_progress", 1740695150) + TypeManager.getMethodBindPtr("AnimatedSprite2D", "get_frame_progress", 1_740_695_150) internal val setFrameAndProgressPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite2D", "set_frame_and_progress", 1602489585) + TypeManager.getMethodBindPtr("AnimatedSprite2D", "set_frame_and_progress", 1_602_489_585) internal val setSpeedScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite2D", "set_speed_scale", 373806689) + TypeManager.getMethodBindPtr("AnimatedSprite2D", "set_speed_scale", 373_806_689) internal val getSpeedScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite2D", "get_speed_scale", 1740695150) + TypeManager.getMethodBindPtr("AnimatedSprite2D", "get_speed_scale", 1_740_695_150) internal val getPlayingSpeedPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite2D", "get_playing_speed", 1740695150) + TypeManager.getMethodBindPtr("AnimatedSprite2D", "get_playing_speed", 1_740_695_150) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimatedSprite3D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimatedSprite3D.kt index 703bad1b8b..c7f99171b7 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimatedSprite3D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimatedSprite3D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -32,11 +29,7 @@ import kotlin.jvm.JvmName import kotlin.jvm.JvmOverloads /** - * [AnimatedSprite3D] is similar to the [Sprite3D] node, except it carries multiple textures as - * animation [spriteFrames]. Animations are created using a [SpriteFrames] resource, which allows you - * to import image files (or a folder containing said files) to provide the animation frames for the - * sprite. The [SpriteFrames] resource can be configured in the editor via the SpriteFrames bottom - * panel. + * [AnimatedSprite3D] is similar to the [Sprite3D] node, except it carries multiple textures as animation [spriteFrames]. Animations are created using a [SpriteFrames] resource, which allows you to import image files (or a folder containing said files) to provide the animation frames for the sprite. The [SpriteFrames] resource can be configured in the editor via the SpriteFrames bottom panel. */ @GodotBaseType public open class AnimatedSprite3D : SpriteBase3D() { @@ -61,16 +54,14 @@ public open class AnimatedSprite3D : SpriteBase3D() { public val animationLooped: Signal0 by Signal0 /** - * Emitted when the animation reaches the end, or the start if it is played in reverse. When the - * animation finishes, it pauses the playback. + * Emitted when the animation reaches the end, or the start if it is played in reverse. When the animation finishes, it pauses the playback. * * **Note:** This signal is not emitted if an animation is looping. */ public val animationFinished: Signal0 by Signal0 /** - * The [SpriteFrames] resource containing the animation(s). Allows you the option to load, edit, - * clear, make unique and save the states of the [SpriteFrames] resource. + * The [SpriteFrames] resource containing the animation(s). Allows you the option to load, edit, clear, make unique and save the states of the [SpriteFrames] resource. */ public final inline var spriteFrames: SpriteFrames? @JvmName("spriteFramesProperty") @@ -81,8 +72,7 @@ public open class AnimatedSprite3D : SpriteBase3D() { } /** - * The current animation from the [spriteFrames] resource. If this value is changed, the [frame] - * counter and the [frameProgress] are reset. + * The current animation from the [spriteFrames] resource. If this value is changed, the [frame] counter and the [frameProgress] are reset. */ public final inline var animation: StringName @JvmName("animationProperty") @@ -104,8 +94,7 @@ public open class AnimatedSprite3D : SpriteBase3D() { } /** - * The displayed animation frame's index. Setting this property also resets [frameProgress]. If - * this is not desired, use [setFrameAndProgress]. + * The displayed animation frame's index. Setting this property also resets [frameProgress]. If this is not desired, use [setFrameAndProgress]. */ public final inline var frame: Int @JvmName("frameProperty") @@ -116,8 +105,7 @@ public open class AnimatedSprite3D : SpriteBase3D() { } /** - * The progress value between `0.0` and `1.0` until the current frame transitions to the next - * frame. If the animation is playing backwards, the value transitions from `1.0` to `0.0`. + * The progress value between `0.0` and `1.0` until the current frame transitions to the next frame. If the animation is playing backwards, the value transitions from `1.0` to `0.0`. */ public final inline var frameProgress: Float @JvmName("frameProgressProperty") @@ -128,11 +116,9 @@ public open class AnimatedSprite3D : SpriteBase3D() { } /** - * The speed scaling ratio. For example, if this value is `1`, then the animation plays at normal - * speed. If it's `0.5`, then it plays at half speed. If it's `2`, then it plays at double speed. + * The speed scaling ratio. For example, if this value is `1`, then the animation plays at normal speed. If it's `0.5`, then it plays at half speed. If it's `2`, then it plays at double speed. * - * If set to a negative value, the animation is played in reverse. If set to `0`, the animation - * will not advance. + * If set to a negative value, the animation is played in reverse. If set to `0`, the animation will not advance. */ public final inline var speedScale: Float @JvmName("speedScaleProperty") @@ -142,11 +128,11 @@ public open class AnimatedSprite3D : SpriteBase3D() { setSpeedScale(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(10, scriptIndex) } - public final fun setSpriteFrames(spriteFrames: SpriteFrames?): Unit { + public final fun setSpriteFrames(spriteFrames: SpriteFrames?) { TransferContext.writeArguments(OBJECT to spriteFrames) TransferContext.callMethod(ptr, MethodBindings.setSpriteFramesPtr, NIL) } @@ -157,7 +143,7 @@ public open class AnimatedSprite3D : SpriteBase3D() { return (TransferContext.readReturnValue(OBJECT) as SpriteFrames?) } - public final fun setAnimation(name: StringName): Unit { + public final fun setAnimation(name: StringName) { TransferContext.writeArguments(STRING_NAME to name) TransferContext.callMethod(ptr, MethodBindings.setAnimationPtr, NIL) } @@ -168,7 +154,7 @@ public open class AnimatedSprite3D : SpriteBase3D() { return (TransferContext.readReturnValue(STRING_NAME) as StringName) } - public final fun setAutoplay(name: String): Unit { + public final fun setAutoplay(name: String) { TransferContext.writeArguments(STRING to name) TransferContext.callMethod(ptr, MethodBindings.setAutoplayPtr, NIL) } @@ -180,8 +166,7 @@ public open class AnimatedSprite3D : SpriteBase3D() { } /** - * Returns `true` if an animation is currently playing (even if [speedScale] and/or `custom_speed` - * are `0`). + * Returns `true` if an animation is currently playing (even if [speedScale] and/or `custom_speed` are `0`). */ public final fun isPlaying(): Boolean { TransferContext.writeArguments() @@ -190,18 +175,16 @@ public open class AnimatedSprite3D : SpriteBase3D() { } /** - * Plays the animation with key [name]. If [customSpeed] is negative and [fromEnd] is `true`, the - * animation will play backwards (which is equivalent to calling [playBackwards]). + * Plays the animation with key [name]. If [customSpeed] is negative and [fromEnd] is `true`, the animation will play backwards (which is equivalent to calling [playBackwards]). * - * If this method is called with that same animation [name], or with no [name] parameter, the - * assigned animation will resume playing if it was paused. + * If this method is called with that same animation [name], or with no [name] parameter, the assigned animation will resume playing if it was paused. */ @JvmOverloads public final fun play( name: StringName = StringName(""), customSpeed: Float = 1.0f, fromEnd: Boolean = false, - ): Unit { + ) { TransferContext.writeArguments(STRING_NAME to name, DOUBLE to customSpeed.toDouble(), BOOL to fromEnd) TransferContext.callMethod(ptr, MethodBindings.playPtr, NIL) } @@ -209,36 +192,32 @@ public open class AnimatedSprite3D : SpriteBase3D() { /** * Plays the animation with key [name] in reverse. * - * This method is a shorthand for [play] with `custom_speed = -1.0` and `from_end = true`, so see - * its description for more information. + * This method is a shorthand for [play] with `custom_speed = -1.0` and `from_end = true`, so see its description for more information. */ - public final fun playBackwards(name: StringName = StringName("")): Unit { + public final fun playBackwards(name: StringName = StringName("")) { TransferContext.writeArguments(STRING_NAME to name) TransferContext.callMethod(ptr, MethodBindings.playBackwardsPtr, NIL) } /** - * Pauses the currently playing animation. The [frame] and [frameProgress] will be kept and - * calling [play] or [playBackwards] without arguments will resume the animation from the current - * playback position. + * Pauses the currently playing animation. The [frame] and [frameProgress] will be kept and calling [play] or [playBackwards] without arguments will resume the animation from the current playback position. * * See also [stop]. */ - public final fun pause(): Unit { + public final fun pause() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.pausePtr, NIL) } /** - * Stops the currently playing animation. The animation position is reset to `0` and the - * `custom_speed` is reset to `1.0`. See also [pause]. + * Stops the currently playing animation. The animation position is reset to `0` and the `custom_speed` is reset to `1.0`. See also [pause]. */ - public final fun stop(): Unit { + public final fun stop() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.stopPtr, NIL) } - public final fun setFrame(frame: Int): Unit { + public final fun setFrame(frame: Int) { TransferContext.writeArguments(LONG to frame.toLong()) TransferContext.callMethod(ptr, MethodBindings.setFramePtr, NIL) } @@ -249,7 +228,7 @@ public open class AnimatedSprite3D : SpriteBase3D() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setFrameProgress(progress: Float): Unit { + public final fun setFrameProgress(progress: Float) { TransferContext.writeArguments(DOUBLE to progress.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setFrameProgressPtr, NIL) } @@ -261,8 +240,7 @@ public open class AnimatedSprite3D : SpriteBase3D() { } /** - * Sets [frame] the [frameProgress] to the given values. Unlike setting [frame], this method does - * not reset the [frameProgress] to `0.0` implicitly. + * Sets [frame] the [frameProgress] to the given values. Unlike setting [frame], this method does not reset the [frameProgress] to `0.0` implicitly. * * **Example:** Change the animation while keeping the same [frame] and [frameProgress]: * @@ -274,12 +252,12 @@ public open class AnimatedSprite3D : SpriteBase3D() { * animated_sprite.set_frame_and_progress(current_frame, current_progress) * ``` */ - public final fun setFrameAndProgress(frame: Int, progress: Float): Unit { + public final fun setFrameAndProgress(frame: Int, progress: Float) { TransferContext.writeArguments(LONG to frame.toLong(), DOUBLE to progress.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setFrameAndProgressPtr, NIL) } - public final fun setSpeedScale(speedScale: Float): Unit { + public final fun setSpeedScale(speedScale: Float) { TransferContext.writeArguments(DOUBLE to speedScale.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setSpeedScalePtr, NIL) } @@ -291,9 +269,7 @@ public open class AnimatedSprite3D : SpriteBase3D() { } /** - * Returns the actual playing speed of current animation or `0` if not playing. This speed is the - * [speedScale] property multiplied by `custom_speed` argument specified when calling the [play] - * method. + * Returns the actual playing speed of current animation or `0` if not playing. This speed is the [speedScale] property multiplied by `custom_speed` argument specified when calling the [play] method. * * Returns a negative value if the current animation is playing backwards. */ @@ -303,88 +279,85 @@ public open class AnimatedSprite3D : SpriteBase3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setAnimation(name: String) = setAnimation(name.asCachedStringName()) + public final fun setAnimation(name: String): Unit = setAnimation(name.asCachedStringName()) /** - * Plays the animation with key [name]. If [customSpeed] is negative and [fromEnd] is `true`, the - * animation will play backwards (which is equivalent to calling [playBackwards]). + * Plays the animation with key [name]. If [customSpeed] is negative and [fromEnd] is `true`, the animation will play backwards (which is equivalent to calling [playBackwards]). * - * If this method is called with that same animation [name], or with no [name] parameter, the - * assigned animation will resume playing if it was paused. + * If this method is called with that same animation [name], or with no [name] parameter, the assigned animation will resume playing if it was paused. */ @JvmOverloads public final fun play( name: String, customSpeed: Float = 1.0f, fromEnd: Boolean = false, - ) = play(name.asCachedStringName(), customSpeed, fromEnd) + ): Unit = play(name.asCachedStringName(), customSpeed, fromEnd) /** * Plays the animation with key [name] in reverse. * - * This method is a shorthand for [play] with `custom_speed = -1.0` and `from_end = true`, so see - * its description for more information. + * This method is a shorthand for [play] with `custom_speed = -1.0` and `from_end = true`, so see its description for more information. */ - public final fun playBackwards(name: String) = playBackwards(name.asCachedStringName()) + public final fun playBackwards(name: String): Unit = playBackwards(name.asCachedStringName()) public companion object public object MethodBindings { internal val setSpriteFramesPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite3D", "set_sprite_frames", 905781144) + TypeManager.getMethodBindPtr("AnimatedSprite3D", "set_sprite_frames", 905_781_144) internal val getSpriteFramesPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite3D", "get_sprite_frames", 3804851214) + TypeManager.getMethodBindPtr("AnimatedSprite3D", "get_sprite_frames", 3_804_851_214) internal val setAnimationPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite3D", "set_animation", 3304788590) + TypeManager.getMethodBindPtr("AnimatedSprite3D", "set_animation", 3_304_788_590) internal val getAnimationPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite3D", "get_animation", 2002593661) + TypeManager.getMethodBindPtr("AnimatedSprite3D", "get_animation", 2_002_593_661) internal val setAutoplayPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite3D", "set_autoplay", 83702148) + TypeManager.getMethodBindPtr("AnimatedSprite3D", "set_autoplay", 83_702_148) internal val getAutoplayPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite3D", "get_autoplay", 201670096) + TypeManager.getMethodBindPtr("AnimatedSprite3D", "get_autoplay", 201_670_096) internal val isPlayingPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite3D", "is_playing", 36873697) + TypeManager.getMethodBindPtr("AnimatedSprite3D", "is_playing", 36_873_697) internal val playPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite3D", "play", 3269405555) + TypeManager.getMethodBindPtr("AnimatedSprite3D", "play", 3_269_405_555) internal val playBackwardsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite3D", "play_backwards", 3323268493) + TypeManager.getMethodBindPtr("AnimatedSprite3D", "play_backwards", 3_323_268_493) internal val pausePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite3D", "pause", 3218959716) + TypeManager.getMethodBindPtr("AnimatedSprite3D", "pause", 3_218_959_716) internal val stopPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite3D", "stop", 3218959716) + TypeManager.getMethodBindPtr("AnimatedSprite3D", "stop", 3_218_959_716) internal val setFramePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite3D", "set_frame", 1286410249) + TypeManager.getMethodBindPtr("AnimatedSprite3D", "set_frame", 1_286_410_249) internal val getFramePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite3D", "get_frame", 3905245786) + TypeManager.getMethodBindPtr("AnimatedSprite3D", "get_frame", 3_905_245_786) internal val setFrameProgressPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite3D", "set_frame_progress", 373806689) + TypeManager.getMethodBindPtr("AnimatedSprite3D", "set_frame_progress", 373_806_689) internal val getFrameProgressPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite3D", "get_frame_progress", 1740695150) + TypeManager.getMethodBindPtr("AnimatedSprite3D", "get_frame_progress", 1_740_695_150) internal val setFrameAndProgressPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite3D", "set_frame_and_progress", 1602489585) + TypeManager.getMethodBindPtr("AnimatedSprite3D", "set_frame_and_progress", 1_602_489_585) internal val setSpeedScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite3D", "set_speed_scale", 373806689) + TypeManager.getMethodBindPtr("AnimatedSprite3D", "set_speed_scale", 373_806_689) internal val getSpeedScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite3D", "get_speed_scale", 1740695150) + TypeManager.getMethodBindPtr("AnimatedSprite3D", "get_speed_scale", 1_740_695_150) internal val getPlayingSpeedPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedSprite3D", "get_playing_speed", 1740695150) + TypeManager.getMethodBindPtr("AnimatedSprite3D", "get_playing_speed", 1_740_695_150) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimatedTexture.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimatedTexture.kt index 528238b581..ea5337cf01 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimatedTexture.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimatedTexture.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -22,33 +19,23 @@ import kotlin.Int import kotlin.Long import kotlin.NotImplementedError import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * [AnimatedTexture] is a resource format for frame-based animations, where multiple textures can be - * chained automatically with a predefined delay for each frame. Unlike [AnimationPlayer] or - * [AnimatedSprite2D], it isn't a [Node], but has the advantage of being usable anywhere a [Texture2D] - * resource can be used, e.g. in a [TileSet]. + * [AnimatedTexture] is a resource format for frame-based animations, where multiple textures can be chained automatically with a predefined delay for each frame. Unlike [AnimationPlayer] or [AnimatedSprite2D], it isn't a [Node], but has the advantage of being usable anywhere a [Texture2D] resource can be used, e.g. in a [TileSet]. * - * The playback of the animation is controlled by the [speedScale] property, as well as each frame's - * duration (see [setFrameDuration]). The animation loops, i.e. it will restart at frame 0 - * automatically after playing the last frame. + * The playback of the animation is controlled by the [speedScale] property, as well as each frame's duration (see [setFrameDuration]). The animation loops, i.e. it will restart at frame 0 automatically after playing the last frame. * - * [AnimatedTexture] currently requires all frame textures to have the same size, otherwise the - * bigger ones will be cropped to match the smallest one. + * [AnimatedTexture] currently requires all frame textures to have the same size, otherwise the bigger ones will be cropped to match the smallest one. * - * **Note:** AnimatedTexture doesn't support using [AtlasTexture]s. Each frame needs to be a - * separate [Texture2D]. + * **Note:** AnimatedTexture doesn't support using [AtlasTexture]s. Each frame needs to be a separate [Texture2D]. * * **Warning:** The current implementation is not efficient for the modern renderers. */ @GodotBaseType public open class AnimatedTexture : Texture2D() { /** - * Number of frames to use in the animation. While you can create the frames independently with - * [setFrameTexture], you need to set this value for the animation to take new frames into account. - * The maximum number of frames is [MAX_FRAMES]. + * Number of frames to use in the animation. While you can create the frames independently with [setFrameTexture], you need to set this value for the animation to take new frames into account. The maximum number of frames is [MAX_FRAMES]. */ public final inline var frames: Int @JvmName("framesProperty") @@ -59,8 +46,7 @@ public open class AnimatedTexture : Texture2D() { } /** - * Sets the currently visible frame of the texture. Setting this frame while playing resets the - * current frame time, so the newly selected frame plays for its whole configured frame duration. + * Sets the currently visible frame of the texture. Setting this frame while playing resets the current frame time, so the newly selected frame plays for its whole configured frame duration. */ public final inline var currentFrame: Int @JvmName("currentFrameProperty") @@ -71,8 +57,7 @@ public open class AnimatedTexture : Texture2D() { } /** - * If `true`, the animation will pause where it currently is (i.e. at [currentFrame]). The - * animation will continue from where it was paused when changing this property to `false`. + * If `true`, the animation will pause where it currently is (i.e. at [currentFrame]). The animation will continue from where it was paused when changing this property to `false`. */ public final inline var pause: Boolean @JvmName("pauseProperty") @@ -83,8 +68,7 @@ public open class AnimatedTexture : Texture2D() { } /** - * If `true`, the animation will only play once and will not loop back to the first frame after - * reaching the end. Note that reaching the end will not set [pause] to `true`. + * If `true`, the animation will only play once and will not loop back to the first frame after reaching the end. Note that reaching the end will not set [pause] to `true`. */ public final inline var oneShot: Boolean @JvmName("oneShotProperty") @@ -95,8 +79,7 @@ public open class AnimatedTexture : Texture2D() { } /** - * The animation speed is multiplied by this value. If set to a negative value, the animation is - * played in reverse. + * The animation speed is multiplied by this value. If set to a negative value, the animation is played in reverse. */ public final inline var speedScale: Float @JvmName("speedScaleProperty") @@ -106,11 +89,11 @@ public open class AnimatedTexture : Texture2D() { setSpeedScale(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(11, scriptIndex) } - public final fun setFrames(frames: Int): Unit { + public final fun setFrames(frames: Int) { TransferContext.writeArguments(LONG to frames.toLong()) TransferContext.callMethod(ptr, MethodBindings.setFramesPtr, NIL) } @@ -121,7 +104,7 @@ public open class AnimatedTexture : Texture2D() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setCurrentFrame(frame: Int): Unit { + public final fun setCurrentFrame(frame: Int) { TransferContext.writeArguments(LONG to frame.toLong()) TransferContext.callMethod(ptr, MethodBindings.setCurrentFramePtr, NIL) } @@ -132,7 +115,7 @@ public open class AnimatedTexture : Texture2D() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setPause(pause: Boolean): Unit { + public final fun setPause(pause: Boolean) { TransferContext.writeArguments(BOOL to pause) TransferContext.callMethod(ptr, MethodBindings.setPausePtr, NIL) } @@ -143,7 +126,7 @@ public open class AnimatedTexture : Texture2D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setOneShot(oneShot: Boolean): Unit { + public final fun setOneShot(oneShot: Boolean) { TransferContext.writeArguments(BOOL to oneShot) TransferContext.callMethod(ptr, MethodBindings.setOneShotPtr, NIL) } @@ -154,7 +137,7 @@ public open class AnimatedTexture : Texture2D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setSpeedScale(scale: Float): Unit { + public final fun setSpeedScale(scale: Float) { TransferContext.writeArguments(DOUBLE to scale.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setSpeedScalePtr, NIL) } @@ -166,13 +149,11 @@ public open class AnimatedTexture : Texture2D() { } /** - * Assigns a [Texture2D] to the given frame. Frame IDs start at 0, so the first frame has ID 0, - * and the last frame of the animation has ID [frames] - 1. + * Assigns a [Texture2D] to the given frame. Frame IDs start at 0, so the first frame has ID 0, and the last frame of the animation has ID [frames] - 1. * - * You can define any number of textures up to [MAX_FRAMES], but keep in mind that only frames - * from 0 to [frames] - 1 will be part of the animation. + * You can define any number of textures up to [MAX_FRAMES], but keep in mind that only frames from 0 to [frames] - 1 will be part of the animation. */ - public final fun setFrameTexture(frame: Int, texture: Texture2D?): Unit { + public final fun setFrameTexture(frame: Int, texture: Texture2D?) { TransferContext.writeArguments(LONG to frame.toLong(), OBJECT to texture) TransferContext.callMethod(ptr, MethodBindings.setFrameTexturePtr, NIL) } @@ -187,10 +168,9 @@ public open class AnimatedTexture : Texture2D() { } /** - * Sets the duration of any given [frame]. The final duration is affected by the [speedScale]. If - * set to `0`, the frame is skipped during playback. + * Sets the duration of any given [frame]. The final duration is affected by the [speedScale]. If set to `0`, the frame is skipped during playback. */ - public final fun setFrameDuration(frame: Int, duration: Float): Unit { + public final fun setFrameDuration(frame: Int, duration: Float) { TransferContext.writeArguments(LONG to frame.toLong(), DOUBLE to duration.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setFrameDurationPtr, NIL) } @@ -207,66 +187,65 @@ public open class AnimatedTexture : Texture2D() { /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _getWidth(): Int { + override fun _getWidth(): Int { throw NotImplementedError("AnimatedTexture::_getWidth can't be called from the JVM.") } /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _getHeight(): Int { + override fun _getHeight(): Int { throw NotImplementedError("AnimatedTexture::_getHeight can't be called from the JVM.") } public companion object { /** - * The maximum number of frames supported by [AnimatedTexture]. If you need more frames in your - * animation, use [AnimationPlayer] or [AnimatedSprite2D]. + * The maximum number of frames supported by [AnimatedTexture]. If you need more frames in your animation, use [AnimationPlayer] or [AnimatedSprite2D]. */ public final const val MAX_FRAMES: Long = 256 } public object MethodBindings { internal val setFramesPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedTexture", "set_frames", 1286410249) + TypeManager.getMethodBindPtr("AnimatedTexture", "set_frames", 1_286_410_249) internal val getFramesPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedTexture", "get_frames", 3905245786) + TypeManager.getMethodBindPtr("AnimatedTexture", "get_frames", 3_905_245_786) internal val setCurrentFramePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedTexture", "set_current_frame", 1286410249) + TypeManager.getMethodBindPtr("AnimatedTexture", "set_current_frame", 1_286_410_249) internal val getCurrentFramePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedTexture", "get_current_frame", 3905245786) + TypeManager.getMethodBindPtr("AnimatedTexture", "get_current_frame", 3_905_245_786) internal val setPausePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedTexture", "set_pause", 2586408642) + TypeManager.getMethodBindPtr("AnimatedTexture", "set_pause", 2_586_408_642) internal val getPausePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedTexture", "get_pause", 36873697) + TypeManager.getMethodBindPtr("AnimatedTexture", "get_pause", 36_873_697) internal val setOneShotPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedTexture", "set_one_shot", 2586408642) + TypeManager.getMethodBindPtr("AnimatedTexture", "set_one_shot", 2_586_408_642) internal val getOneShotPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedTexture", "get_one_shot", 36873697) + TypeManager.getMethodBindPtr("AnimatedTexture", "get_one_shot", 36_873_697) internal val setSpeedScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedTexture", "set_speed_scale", 373806689) + TypeManager.getMethodBindPtr("AnimatedTexture", "set_speed_scale", 373_806_689) internal val getSpeedScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedTexture", "get_speed_scale", 1740695150) + TypeManager.getMethodBindPtr("AnimatedTexture", "get_speed_scale", 1_740_695_150) internal val setFrameTexturePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedTexture", "set_frame_texture", 666127730) + TypeManager.getMethodBindPtr("AnimatedTexture", "set_frame_texture", 666_127_730) internal val getFrameTexturePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedTexture", "get_frame_texture", 3536238170) + TypeManager.getMethodBindPtr("AnimatedTexture", "get_frame_texture", 3_536_238_170) internal val setFrameDurationPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedTexture", "set_frame_duration", 1602489585) + TypeManager.getMethodBindPtr("AnimatedTexture", "set_frame_duration", 1_602_489_585) internal val getFrameDurationPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimatedTexture", "get_frame_duration", 2339986948) + TypeManager.getMethodBindPtr("AnimatedTexture", "get_frame_duration", 2_339_986_948) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Animation.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Animation.kt index c8d5454602..c809569267 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Animation.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Animation.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -47,9 +44,7 @@ import kotlin.jvm.JvmName import kotlin.jvm.JvmOverloads /** - * This resource holds data that can be used to animate anything in the engine. Animations are - * divided into tracks and each track must be linked to a node. The state of that node can be changed - * through time, by adding timed keys (events) to the track. + * This resource holds data that can be used to animate anything in the engine. Animations are divided into tracks and each track must be linked to a node. The state of that node can be changed through time, by adding timed keys (events) to the track. * * ```gdscript * //gdscript @@ -75,21 +70,16 @@ import kotlin.jvm.JvmOverloads * animation.Length = 2.0f; * ``` * - * Animations are just data containers, and must be added to nodes such as an [AnimationPlayer] to - * be played back. Animation tracks have different types, each with its own set of dedicated methods. - * Check [TrackType] to see available types. + * Animations are just data containers, and must be added to nodes such as an [AnimationPlayer] to be played back. Animation tracks have different types, each with its own set of dedicated methods. Check [TrackType] to see available types. * - * **Note:** For 3D position/rotation/scale, using the dedicated [TYPE_POSITION_3D], - * [TYPE_ROTATION_3D] and [TYPE_SCALE_3D] track types instead of [TYPE_VALUE] is recommended for - * performance reasons. + * **Note:** For 3D position/rotation/scale, using the dedicated [TYPE_POSITION_3D], [TYPE_ROTATION_3D] and [TYPE_SCALE_3D] track types instead of [TYPE_VALUE] is recommended for performance reasons. */ @GodotBaseType public open class Animation : Resource() { /** * The total length of the animation (in seconds). * - * **Note:** Length is not delimited by the last key, as this one may be before or after the end - * to ensure correct interpolation and looping. + * **Note:** Length is not delimited by the last key, as this one may be before or after the end to ensure correct interpolation and looping. */ public final inline var length: Float @JvmName("lengthProperty") @@ -100,9 +90,7 @@ public open class Animation : Resource() { } /** - * Determines the behavior of both ends of the animation timeline during animation playback. This - * is used for correct interpolation of animation cycles, and for hinting the player that it must - * restart the animation. + * Determines the behavior of both ends of the animation timeline during animation playback. This is used for correct interpolation of animation cycles, and for hinting the player that it must restart the animation. */ public final inline var loopMode: LoopMode @JvmName("loopModeProperty") @@ -124,14 +112,13 @@ public open class Animation : Resource() { } /** - * Returns `true` if the capture track is included. This is a cached readonly value for - * performance. + * Returns `true` if the capture track is included. This is a cached readonly value for performance. */ public final inline val captureIncluded: Boolean @JvmName("captureIncludedProperty") get() = isCaptureIncluded() - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(12, scriptIndex) } @@ -148,7 +135,7 @@ public open class Animation : Resource() { /** * Removes a track by specifying the track index. */ - public final fun removeTrack(trackIdx: Int): Unit { + public final fun removeTrack(trackIdx: Int) { TransferContext.writeArguments(LONG to trackIdx.toLong()) TransferContext.callMethod(ptr, MethodBindings.removeTrackPtr, NIL) } @@ -181,13 +168,11 @@ public open class Animation : Resource() { } /** - * Sets the path of a track. Paths must be valid scene-tree paths to a node and must be specified - * starting from the [AnimationMixer.rootNode] that will reproduce the animation. Tracks that control - * properties or bones must append their name after the path, separated by `":"`. + * Sets the path of a track. Paths must be valid scene-tree paths to a node and must be specified starting from the [AnimationMixer.rootNode] that will reproduce the animation. Tracks that control properties or bones must append their name after the path, separated by `":"`. * * For example, `"character/skeleton:ankle"` or `"character/mesh:transform/local"`. */ - public final fun trackSetPath(trackIdx: Int, path: NodePath): Unit { + public final fun trackSetPath(trackIdx: Int, path: NodePath) { TransferContext.writeArguments(LONG to trackIdx.toLong(), NODE_PATH to path) TransferContext.callMethod(ptr, MethodBindings.trackSetPathPtr, NIL) } @@ -204,7 +189,7 @@ public open class Animation : Resource() { /** * Moves a track up. */ - public final fun trackMoveUp(trackIdx: Int): Unit { + public final fun trackMoveUp(trackIdx: Int) { TransferContext.writeArguments(LONG to trackIdx.toLong()) TransferContext.callMethod(ptr, MethodBindings.trackMoveUpPtr, NIL) } @@ -212,7 +197,7 @@ public open class Animation : Resource() { /** * Moves a track down. */ - public final fun trackMoveDown(trackIdx: Int): Unit { + public final fun trackMoveDown(trackIdx: Int) { TransferContext.writeArguments(LONG to trackIdx.toLong()) TransferContext.callMethod(ptr, MethodBindings.trackMoveDownPtr, NIL) } @@ -220,7 +205,7 @@ public open class Animation : Resource() { /** * Changes the index position of track [trackIdx] to the one defined in [toIdx]. */ - public final fun trackMoveTo(trackIdx: Int, toIdx: Int): Unit { + public final fun trackMoveTo(trackIdx: Int, toIdx: Int) { TransferContext.writeArguments(LONG to trackIdx.toLong(), LONG to toIdx.toLong()) TransferContext.callMethod(ptr, MethodBindings.trackMoveToPtr, NIL) } @@ -228,7 +213,7 @@ public open class Animation : Resource() { /** * Swaps the track [trackIdx]'s index position with the track [withIdx]. */ - public final fun trackSwap(trackIdx: Int, withIdx: Int): Unit { + public final fun trackSwap(trackIdx: Int, withIdx: Int) { TransferContext.writeArguments(LONG to trackIdx.toLong(), LONG to withIdx.toLong()) TransferContext.callMethod(ptr, MethodBindings.trackSwapPtr, NIL) } @@ -236,7 +221,7 @@ public open class Animation : Resource() { /** * Sets the given track as imported or not. */ - public final fun trackSetImported(trackIdx: Int, imported: Boolean): Unit { + public final fun trackSetImported(trackIdx: Int, imported: Boolean) { TransferContext.writeArguments(LONG to trackIdx.toLong(), BOOL to imported) TransferContext.callMethod(ptr, MethodBindings.trackSetImportedPtr, NIL) } @@ -253,7 +238,7 @@ public open class Animation : Resource() { /** * Enables/disables the given track. Tracks are enabled by default. */ - public final fun trackSetEnabled(trackIdx: Int, enabled: Boolean): Unit { + public final fun trackSetEnabled(trackIdx: Int, enabled: Boolean) { TransferContext.writeArguments(LONG to trackIdx.toLong(), BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.trackSetEnabledPtr, NIL) } @@ -320,8 +305,7 @@ public open class Animation : Resource() { } /** - * Returns the interpolated position value at the given time (in seconds). The [trackIdx] must be - * the index of a 3D position track. + * Returns the interpolated position value at the given time (in seconds). The [trackIdx] must be the index of a 3D position track. */ @JvmOverloads public final fun positionTrackInterpolate( @@ -335,8 +319,7 @@ public open class Animation : Resource() { } /** - * Returns the interpolated rotation value at the given time (in seconds). The [trackIdx] must be - * the index of a 3D rotation track. + * Returns the interpolated rotation value at the given time (in seconds). The [trackIdx] must be the index of a 3D rotation track. */ @JvmOverloads public final fun rotationTrackInterpolate( @@ -350,8 +333,7 @@ public open class Animation : Resource() { } /** - * Returns the interpolated scale value at the given time (in seconds). The [trackIdx] must be the - * index of a 3D scale track. + * Returns the interpolated scale value at the given time (in seconds). The [trackIdx] must be the index of a 3D scale track. */ @JvmOverloads public final fun scaleTrackInterpolate( @@ -365,8 +347,7 @@ public open class Animation : Resource() { } /** - * Returns the interpolated blend shape value at the given time (in seconds). The [trackIdx] must - * be the index of a blend shape track. + * Returns the interpolated blend shape value at the given time (in seconds). The [trackIdx] must be the index of a blend shape track. */ @JvmOverloads public final fun blendShapeTrackInterpolate( @@ -397,7 +378,7 @@ public open class Animation : Resource() { /** * Removes a key by index in a given track. */ - public final fun trackRemoveKey(trackIdx: Int, keyIdx: Int): Unit { + public final fun trackRemoveKey(trackIdx: Int, keyIdx: Int) { TransferContext.writeArguments(LONG to trackIdx.toLong(), LONG to keyIdx.toLong()) TransferContext.callMethod(ptr, MethodBindings.trackRemoveKeyPtr, NIL) } @@ -405,7 +386,7 @@ public open class Animation : Resource() { /** * Removes a key at [time] in a given track. */ - public final fun trackRemoveKeyAtTime(trackIdx: Int, time: Double): Unit { + public final fun trackRemoveKeyAtTime(trackIdx: Int, time: Double) { TransferContext.writeArguments(LONG to trackIdx.toLong(), DOUBLE to time) TransferContext.callMethod(ptr, MethodBindings.trackRemoveKeyAtTimePtr, NIL) } @@ -417,20 +398,19 @@ public open class Animation : Resource() { trackIdx: Int, key: Int, `value`: Any?, - ): Unit { + ) { TransferContext.writeArguments(LONG to trackIdx.toLong(), LONG to key.toLong(), ANY to value) TransferContext.callMethod(ptr, MethodBindings.trackSetKeyValuePtr, NIL) } /** - * Sets the transition curve (easing) for a specific key (see the built-in math function - * [@GlobalScope.ease]). + * Sets the transition curve (easing) for a specific key (see the built-in math function [@GlobalScope.ease]). */ public final fun trackSetKeyTransition( trackIdx: Int, keyIdx: Int, transition: Float, - ): Unit { + ) { TransferContext.writeArguments(LONG to trackIdx.toLong(), LONG to keyIdx.toLong(), DOUBLE to transition.toDouble()) TransferContext.callMethod(ptr, MethodBindings.trackSetKeyTransitionPtr, NIL) } @@ -442,14 +422,13 @@ public open class Animation : Resource() { trackIdx: Int, keyIdx: Int, time: Double, - ): Unit { + ) { TransferContext.writeArguments(LONG to trackIdx.toLong(), LONG to keyIdx.toLong(), DOUBLE to time) TransferContext.callMethod(ptr, MethodBindings.trackSetKeyTimePtr, NIL) } /** - * Returns the transition curve (easing) for a specific key (see the built-in math function - * [@GlobalScope.ease]). + * Returns the transition curve (easing) for a specific key (see the built-in math function [@GlobalScope.ease]). */ public final fun trackGetKeyTransition(trackIdx: Int, keyIdx: Int): Float { TransferContext.writeArguments(LONG to trackIdx.toLong(), LONG to keyIdx.toLong()) @@ -485,17 +464,13 @@ public open class Animation : Resource() { } /** - * Finds the key index by time in a given track. Optionally, only find it if the approx/exact time - * is given. + * Finds the key index by time in a given track. Optionally, only find it if the approx/exact time is given. * * If [limit] is `true`, it does not return keys outside the animation range. * - * If [backward] is `true`, the direction is reversed in methods that rely on one directional - * processing. + * If [backward] is `true`, the direction is reversed in methods that rely on one directional processing. * - * For example, in case [findMode] is [FIND_MODE_NEAREST], if there is no key in the current - * position just after seeked, the first key found is retrieved by searching before the position, but - * if [backward] is `true`, the first key found is retrieved after the position. + * For example, in case [findMode] is [FIND_MODE_NEAREST], if there is no key in the current position just after seeked, the first key found is retrieved by searching before the position, but if [backward] is `true`, the first key found is retrieved after the position. */ @JvmOverloads public final fun trackFindKey( @@ -513,8 +488,7 @@ public open class Animation : Resource() { /** * Sets the interpolation type of a given track. */ - public final fun trackSetInterpolationType(trackIdx: Int, interpolation: InterpolationType): - Unit { + public final fun trackSetInterpolationType(trackIdx: Int, interpolation: InterpolationType) { TransferContext.writeArguments(LONG to trackIdx.toLong(), LONG to interpolation.id) TransferContext.callMethod(ptr, MethodBindings.trackSetInterpolationTypePtr, NIL) } @@ -531,14 +505,13 @@ public open class Animation : Resource() { /** * If `true`, the track at [trackIdx] wraps the interpolation loop. */ - public final fun trackSetInterpolationLoopWrap(trackIdx: Int, interpolation: Boolean): Unit { + public final fun trackSetInterpolationLoopWrap(trackIdx: Int, interpolation: Boolean) { TransferContext.writeArguments(LONG to trackIdx.toLong(), BOOL to interpolation) TransferContext.callMethod(ptr, MethodBindings.trackSetInterpolationLoopWrapPtr, NIL) } /** - * Returns `true` if the track at [trackIdx] wraps the interpolation loop. New tracks wrap the - * interpolation loop by default. + * Returns `true` if the track at [trackIdx] wraps the interpolation loop. New tracks wrap the interpolation loop by default. */ public final fun trackGetInterpolationLoopWrap(trackIdx: Int): Boolean { TransferContext.writeArguments(LONG to trackIdx.toLong()) @@ -558,7 +531,7 @@ public open class Animation : Resource() { /** * Sets the update mode (see [UpdateMode]) of a value track. */ - public final fun valueTrackSetUpdateMode(trackIdx: Int, mode: UpdateMode): Unit { + public final fun valueTrackSetUpdateMode(trackIdx: Int, mode: UpdateMode) { TransferContext.writeArguments(LONG to trackIdx.toLong(), LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.valueTrackSetUpdateModePtr, NIL) } @@ -573,12 +546,9 @@ public open class Animation : Resource() { } /** - * Returns the interpolated value at the given time (in seconds). The [trackIdx] must be the index - * of a value track. + * Returns the interpolated value at the given time (in seconds). The [trackIdx] must be the index of a value track. * - * A [backward] mainly affects the direction of key retrieval of the track with [UPDATE_DISCRETE] - * converted by [AnimationMixer.ANIMATION_CALLBACK_MODE_DISCRETE_FORCE_CONTINUOUS] to match the - * result with [trackFindKey]. + * A [backward] mainly affects the direction of key retrieval of the track with [UPDATE_DISCRETE] converted by [AnimationMixer.ANIMATION_CALLBACK_MODE_DISCRETE_FORCE_CONTINUOUS] to match the result with [trackFindKey]. */ @JvmOverloads public final fun valueTrackInterpolate( @@ -610,11 +580,9 @@ public open class Animation : Resource() { } /** - * Inserts a Bezier Track key at the given [time] in seconds. The [trackIdx] must be the index of - * a Bezier Track. + * Inserts a Bezier Track key at the given [time] in seconds. The [trackIdx] must be the index of a Bezier Track. * - * [inHandle] is the left-side weight of the added Bezier curve point, [outHandle] is the - * right-side one, while [value] is the actual value at this point. + * [inHandle] is the left-side weight of the added Bezier curve point, [outHandle] is the right-side one, while [value] is the actual value at this point. */ @JvmOverloads public final fun bezierTrackInsertKey( @@ -630,21 +598,19 @@ public open class Animation : Resource() { } /** - * Sets the value of the key identified by [keyIdx] to the given value. The [trackIdx] must be the - * index of a Bezier Track. + * Sets the value of the key identified by [keyIdx] to the given value. The [trackIdx] must be the index of a Bezier Track. */ public final fun bezierTrackSetKeyValue( trackIdx: Int, keyIdx: Int, `value`: Float, - ): Unit { + ) { TransferContext.writeArguments(LONG to trackIdx.toLong(), LONG to keyIdx.toLong(), DOUBLE to value.toDouble()) TransferContext.callMethod(ptr, MethodBindings.bezierTrackSetKeyValuePtr, NIL) } /** - * Sets the in handle of the key identified by [keyIdx] to value [inHandle]. The [trackIdx] must - * be the index of a Bezier Track. + * Sets the in handle of the key identified by [keyIdx] to value [inHandle]. The [trackIdx] must be the index of a Bezier Track. */ @JvmOverloads public final fun bezierTrackSetKeyInHandle( @@ -652,14 +618,13 @@ public open class Animation : Resource() { keyIdx: Int, inHandle: Vector2, balancedValueTimeRatio: Float = 1.0f, - ): Unit { + ) { TransferContext.writeArguments(LONG to trackIdx.toLong(), LONG to keyIdx.toLong(), VECTOR2 to inHandle, DOUBLE to balancedValueTimeRatio.toDouble()) TransferContext.callMethod(ptr, MethodBindings.bezierTrackSetKeyInHandlePtr, NIL) } /** - * Sets the out handle of the key identified by [keyIdx] to value [outHandle]. The [trackIdx] must - * be the index of a Bezier Track. + * Sets the out handle of the key identified by [keyIdx] to value [outHandle]. The [trackIdx] must be the index of a Bezier Track. */ @JvmOverloads public final fun bezierTrackSetKeyOutHandle( @@ -667,14 +632,13 @@ public open class Animation : Resource() { keyIdx: Int, outHandle: Vector2, balancedValueTimeRatio: Float = 1.0f, - ): Unit { + ) { TransferContext.writeArguments(LONG to trackIdx.toLong(), LONG to keyIdx.toLong(), VECTOR2 to outHandle, DOUBLE to balancedValueTimeRatio.toDouble()) TransferContext.callMethod(ptr, MethodBindings.bezierTrackSetKeyOutHandlePtr, NIL) } /** - * Returns the value of the key identified by [keyIdx]. The [trackIdx] must be the index of a - * Bezier Track. + * Returns the value of the key identified by [keyIdx]. The [trackIdx] must be the index of a Bezier Track. */ public final fun bezierTrackGetKeyValue(trackIdx: Int, keyIdx: Int): Float { TransferContext.writeArguments(LONG to trackIdx.toLong(), LONG to keyIdx.toLong()) @@ -683,8 +647,7 @@ public open class Animation : Resource() { } /** - * Returns the in handle of the key identified by [keyIdx]. The [trackIdx] must be the index of a - * Bezier Track. + * Returns the in handle of the key identified by [keyIdx]. The [trackIdx] must be the index of a Bezier Track. */ public final fun bezierTrackGetKeyInHandle(trackIdx: Int, keyIdx: Int): Vector2 { TransferContext.writeArguments(LONG to trackIdx.toLong(), LONG to keyIdx.toLong()) @@ -693,8 +656,7 @@ public open class Animation : Resource() { } /** - * Returns the out handle of the key identified by [keyIdx]. The [trackIdx] must be the index of a - * Bezier Track. + * Returns the out handle of the key identified by [keyIdx]. The [trackIdx] must be the index of a Bezier Track. */ public final fun bezierTrackGetKeyOutHandle(trackIdx: Int, keyIdx: Int): Vector2 { TransferContext.writeArguments(LONG to trackIdx.toLong(), LONG to keyIdx.toLong()) @@ -703,8 +665,7 @@ public open class Animation : Resource() { } /** - * Returns the interpolated value at the given [time] (in seconds). The [trackIdx] must be the - * index of a Bezier Track. + * Returns the interpolated value at the given [time] (in seconds). The [trackIdx] must be the index of a Bezier Track. */ public final fun bezierTrackInterpolate(trackIdx: Int, time: Double): Float { TransferContext.writeArguments(LONG to trackIdx.toLong(), DOUBLE to time) @@ -713,11 +674,9 @@ public open class Animation : Resource() { } /** - * Inserts an Audio Track key at the given [time] in seconds. The [trackIdx] must be the index of - * an Audio Track. + * Inserts an Audio Track key at the given [time] in seconds. The [trackIdx] must be the index of an Audio Track. * - * [stream] is the [AudioStream] resource to play. [startOffset] is the number of seconds cut off - * at the beginning of the audio stream, while [endOffset] is at the ending. + * [stream] is the [AudioStream] resource to play. [startOffset] is the number of seconds cut off at the beginning of the audio stream, while [endOffset] is at the ending. */ @JvmOverloads public final fun audioTrackInsertKey( @@ -733,47 +692,43 @@ public open class Animation : Resource() { } /** - * Sets the stream of the key identified by [keyIdx] to value [stream]. The [trackIdx] must be the - * index of an Audio Track. + * Sets the stream of the key identified by [keyIdx] to value [stream]. The [trackIdx] must be the index of an Audio Track. */ public final fun audioTrackSetKeyStream( trackIdx: Int, keyIdx: Int, stream: Resource?, - ): Unit { + ) { TransferContext.writeArguments(LONG to trackIdx.toLong(), LONG to keyIdx.toLong(), OBJECT to stream) TransferContext.callMethod(ptr, MethodBindings.audioTrackSetKeyStreamPtr, NIL) } /** - * Sets the start offset of the key identified by [keyIdx] to value [offset]. The [trackIdx] must - * be the index of an Audio Track. + * Sets the start offset of the key identified by [keyIdx] to value [offset]. The [trackIdx] must be the index of an Audio Track. */ public final fun audioTrackSetKeyStartOffset( trackIdx: Int, keyIdx: Int, offset: Float, - ): Unit { + ) { TransferContext.writeArguments(LONG to trackIdx.toLong(), LONG to keyIdx.toLong(), DOUBLE to offset.toDouble()) TransferContext.callMethod(ptr, MethodBindings.audioTrackSetKeyStartOffsetPtr, NIL) } /** - * Sets the end offset of the key identified by [keyIdx] to value [offset]. The [trackIdx] must be - * the index of an Audio Track. + * Sets the end offset of the key identified by [keyIdx] to value [offset]. The [trackIdx] must be the index of an Audio Track. */ public final fun audioTrackSetKeyEndOffset( trackIdx: Int, keyIdx: Int, offset: Float, - ): Unit { + ) { TransferContext.writeArguments(LONG to trackIdx.toLong(), LONG to keyIdx.toLong(), DOUBLE to offset.toDouble()) TransferContext.callMethod(ptr, MethodBindings.audioTrackSetKeyEndOffsetPtr, NIL) } /** - * Returns the audio stream of the key identified by [keyIdx]. The [trackIdx] must be the index of - * an Audio Track. + * Returns the audio stream of the key identified by [keyIdx]. The [trackIdx] must be the index of an Audio Track. */ public final fun audioTrackGetKeyStream(trackIdx: Int, keyIdx: Int): Resource? { TransferContext.writeArguments(LONG to trackIdx.toLong(), LONG to keyIdx.toLong()) @@ -782,8 +737,7 @@ public open class Animation : Resource() { } /** - * Returns the start offset of the key identified by [keyIdx]. The [trackIdx] must be the index of - * an Audio Track. + * Returns the start offset of the key identified by [keyIdx]. The [trackIdx] must be the index of an Audio Track. * * Start offset is the number of seconds cut off at the beginning of the audio stream. */ @@ -794,8 +748,7 @@ public open class Animation : Resource() { } /** - * Returns the end offset of the key identified by [keyIdx]. The [trackIdx] must be the index of - * an Audio Track. + * Returns the end offset of the key identified by [keyIdx]. The [trackIdx] must be the index of an Audio Track. * * End offset is the number of seconds cut off at the ending of the audio stream. */ @@ -806,10 +759,9 @@ public open class Animation : Resource() { } /** - * Sets whether the track will be blended with other animations. If `true`, the audio playback - * volume changes depending on the blend value. + * Sets whether the track will be blended with other animations. If `true`, the audio playback volume changes depending on the blend value. */ - public final fun audioTrackSetUseBlend(trackIdx: Int, enable: Boolean): Unit { + public final fun audioTrackSetUseBlend(trackIdx: Int, enable: Boolean) { TransferContext.writeArguments(LONG to trackIdx.toLong(), BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.audioTrackSetUseBlendPtr, NIL) } @@ -824,8 +776,7 @@ public open class Animation : Resource() { } /** - * Inserts a key with value [animation] at the given [time] (in seconds). The [trackIdx] must be - * the index of an Animation Track. + * Inserts a key with value [animation] at the given [time] (in seconds). The [trackIdx] must be the index of an Animation Track. */ public final fun animationTrackInsertKey( trackIdx: Int, @@ -838,21 +789,19 @@ public open class Animation : Resource() { } /** - * Sets the key identified by [keyIdx] to value [animation]. The [trackIdx] must be the index of - * an Animation Track. + * Sets the key identified by [keyIdx] to value [animation]. The [trackIdx] must be the index of an Animation Track. */ public final fun animationTrackSetKeyAnimation( trackIdx: Int, keyIdx: Int, animation: StringName, - ): Unit { + ) { TransferContext.writeArguments(LONG to trackIdx.toLong(), LONG to keyIdx.toLong(), STRING_NAME to animation) TransferContext.callMethod(ptr, MethodBindings.animationTrackSetKeyAnimationPtr, NIL) } /** - * Returns the animation name at the key identified by [keyIdx]. The [trackIdx] must be the index - * of an Animation Track. + * Returns the animation name at the key identified by [keyIdx]. The [trackIdx] must be the index of an Animation Track. */ public final fun animationTrackGetKeyAnimation(trackIdx: Int, keyIdx: Int): StringName { TransferContext.writeArguments(LONG to trackIdx.toLong(), LONG to keyIdx.toLong()) @@ -863,7 +812,7 @@ public open class Animation : Resource() { /** * Adds a marker to this Animation. */ - public final fun addMarker(name: StringName, time: Double): Unit { + public final fun addMarker(name: StringName, time: Double) { TransferContext.writeArguments(STRING_NAME to name, DOUBLE to time) TransferContext.callMethod(ptr, MethodBindings.addMarkerPtr, NIL) } @@ -871,7 +820,7 @@ public open class Animation : Resource() { /** * Removes the marker with the given name from this Animation. */ - public final fun removeMarker(name: StringName): Unit { + public final fun removeMarker(name: StringName) { TransferContext.writeArguments(STRING_NAME to name) TransferContext.callMethod(ptr, MethodBindings.removeMarkerPtr, NIL) } @@ -895,8 +844,7 @@ public open class Animation : Resource() { } /** - * Returns the closest marker that comes after the given time. If no such marker exists, an empty - * string is returned. + * Returns the closest marker that comes after the given time. If no such marker exists, an empty string is returned. */ public final fun getNextMarker(time: Double): StringName { TransferContext.writeArguments(DOUBLE to time) @@ -905,8 +853,7 @@ public open class Animation : Resource() { } /** - * Returns the closest marker that comes before the given time. If no such marker exists, an empty - * string is returned. + * Returns the closest marker that comes before the given time. If no such marker exists, an empty string is returned. */ public final fun getPrevMarker(time: Double): StringName { TransferContext.writeArguments(DOUBLE to time) @@ -944,12 +891,12 @@ public open class Animation : Resource() { /** * Sets the given marker's color. */ - public final fun setMarkerColor(name: StringName, color: Color): Unit { + public final fun setMarkerColor(name: StringName, color: Color) { TransferContext.writeArguments(STRING_NAME to name, COLOR to color) TransferContext.callMethod(ptr, MethodBindings.setMarkerColorPtr, NIL) } - public final fun setLength(timeSec: Float): Unit { + public final fun setLength(timeSec: Float) { TransferContext.writeArguments(DOUBLE to timeSec.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setLengthPtr, NIL) } @@ -960,7 +907,7 @@ public open class Animation : Resource() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setLoopMode(loopMode: LoopMode): Unit { + public final fun setLoopMode(loopMode: LoopMode) { TransferContext.writeArguments(LONG to loopMode.id) TransferContext.callMethod(ptr, MethodBindings.setLoopModePtr, NIL) } @@ -971,7 +918,7 @@ public open class Animation : Resource() { return LoopMode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setStep(sizeSec: Float): Unit { + public final fun setStep(sizeSec: Float) { TransferContext.writeArguments(DOUBLE to sizeSec.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setStepPtr, NIL) } @@ -985,7 +932,7 @@ public open class Animation : Resource() { /** * Clear the animation (clear all tracks and reset all). */ - public final fun clear(): Unit { + public final fun clear() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.clearPtr, NIL) } @@ -993,41 +940,35 @@ public open class Animation : Resource() { /** * Adds a new track to [toAnimation] that is a copy of the given track from this animation. */ - public final fun copyTrack(trackIdx: Int, toAnimation: Animation?): Unit { + public final fun copyTrack(trackIdx: Int, toAnimation: Animation?) { TransferContext.writeArguments(LONG to trackIdx.toLong(), OBJECT to toAnimation) TransferContext.callMethod(ptr, MethodBindings.copyTrackPtr, NIL) } /** - * Optimize the animation and all its tracks in-place. This will preserve only as many keys as are - * necessary to keep the animation within the specified bounds. + * Optimize the animation and all its tracks in-place. This will preserve only as many keys as are necessary to keep the animation within the specified bounds. */ @JvmOverloads public final fun optimize( allowedVelocityErr: Float = 0.01f, allowedAngularErr: Float = 0.01f, precision: Int = 3, - ): Unit { + ) { TransferContext.writeArguments(DOUBLE to allowedVelocityErr.toDouble(), DOUBLE to allowedAngularErr.toDouble(), LONG to precision.toLong()) TransferContext.callMethod(ptr, MethodBindings.optimizePtr, NIL) } /** - * Compress the animation and all its tracks in-place. This will make [trackIsCompressed] return - * `true` once called on this [Animation]. Compressed tracks require less memory to be played, and - * are designed to be used for complex 3D animations (such as cutscenes) imported from external 3D - * software. Compression is lossy, but the difference is usually not noticeable in real world - * conditions. + * Compress the animation and all its tracks in-place. This will make [trackIsCompressed] return `true` once called on this [Animation]. Compressed tracks require less memory to be played, and are designed to be used for complex 3D animations (such as cutscenes) imported from external 3D software. Compression is lossy, but the difference is usually not noticeable in real world conditions. * - * **Note:** Compressed tracks have various limitations (such as not being editable from the - * editor), so only use compressed animations if you actually need them. + * **Note:** Compressed tracks have various limitations (such as not being editable from the editor), so only use compressed animations if you actually need them. */ @JvmOverloads public final fun compress( pageSize: Long = 8192, fps: Long = 120, splitTolerance: Float = 4.0f, - ): Unit { + ) { TransferContext.writeArguments(LONG to pageSize, LONG to fps, DOUBLE to splitTolerance.toDouble()) TransferContext.callMethod(ptr, MethodBindings.compressPtr, NIL) } @@ -1039,24 +980,19 @@ public open class Animation : Resource() { } /** - * Sets the path of a track. Paths must be valid scene-tree paths to a node and must be specified - * starting from the [AnimationMixer.rootNode] that will reproduce the animation. Tracks that control - * properties or bones must append their name after the path, separated by `":"`. + * Sets the path of a track. Paths must be valid scene-tree paths to a node and must be specified starting from the [AnimationMixer.rootNode] that will reproduce the animation. Tracks that control properties or bones must append their name after the path, separated by `":"`. * * For example, `"character/skeleton:ankle"` or `"character/mesh:transform/local"`. */ - public final fun trackSetPath(trackIdx: Int, path: String) = - trackSetPath(trackIdx, path.asCachedNodePath()) + public final fun trackSetPath(trackIdx: Int, path: String): Unit = trackSetPath(trackIdx, path.asCachedNodePath()) /** * Returns the index of the specified track. If the track is not found, return -1. */ - public final fun findTrack(path: String, type: TrackType): Int = - findTrack(path.asCachedNodePath(), type) + public final fun findTrack(path: String, type: TrackType): Int = findTrack(path.asCachedNodePath(), type) /** - * Inserts a key with value [animation] at the given [time] (in seconds). The [trackIdx] must be - * the index of an Animation Track. + * Inserts a key with value [animation] at the given [time] (in seconds). The [trackIdx] must be the index of an Animation Track. */ public final fun animationTrackInsertKey( trackIdx: Int, @@ -1065,25 +1001,23 @@ public open class Animation : Resource() { ): Int = animationTrackInsertKey(trackIdx, time, animation.asCachedStringName()) /** - * Sets the key identified by [keyIdx] to value [animation]. The [trackIdx] must be the index of - * an Animation Track. + * Sets the key identified by [keyIdx] to value [animation]. The [trackIdx] must be the index of an Animation Track. */ public final fun animationTrackSetKeyAnimation( trackIdx: Int, keyIdx: Int, animation: String, - ) = animationTrackSetKeyAnimation(trackIdx, keyIdx, animation.asCachedStringName()) + ): Unit = animationTrackSetKeyAnimation(trackIdx, keyIdx, animation.asCachedStringName()) /** * Adds a marker to this Animation. */ - public final fun addMarker(name: String, time: Double) = - addMarker(name.asCachedStringName(), time) + public final fun addMarker(name: String, time: Double): Unit = addMarker(name.asCachedStringName(), time) /** * Removes the marker with the given name from this Animation. */ - public final fun removeMarker(name: String) = removeMarker(name.asCachedStringName()) + public final fun removeMarker(name: String): Unit = removeMarker(name.asCachedStringName()) /** * Returns `true` if this Animation contains a marker with the given name. @@ -1103,16 +1037,13 @@ public open class Animation : Resource() { /** * Sets the given marker's color. */ - public final fun setMarkerColor(name: String, color: Color) = - setMarkerColor(name.asCachedStringName(), color) + public final fun setMarkerColor(name: String, color: Color): Unit = setMarkerColor(name.asCachedStringName(), color) public enum class TrackType( id: Long, ) { /** - * Value tracks set values in node properties, but only those which can be interpolated. For 3D - * position/rotation/scale, using the dedicated [TYPE_POSITION_3D], [TYPE_ROTATION_3D] and - * [TYPE_SCALE_3D] track types instead of [TYPE_VALUE] is recommended for performance reasons. + * Value tracks set values in node properties, but only those which can be interpolated. For 3D position/rotation/scale, using the dedicated [TYPE_POSITION_3D], [TYPE_ROTATION_3D] and [TYPE_SCALE_3D] track types instead of [TYPE_VALUE] is recommended for performance reasons. */ TYPE_VALUE(0), /** @@ -1136,13 +1067,11 @@ public open class Animation : Resource() { */ TYPE_METHOD(5), /** - * Bezier tracks are used to interpolate a value using custom curves. They can also be used to - * animate sub-properties of vectors and colors (e.g. alpha value of a [Color]). + * Bezier tracks are used to interpolate a value using custom curves. They can also be used to animate sub-properties of vectors and colors (e.g. alpha value of a [Color]). */ TYPE_BEZIER(6), /** - * Audio tracks are used to play an audio stream with either type of [AudioStreamPlayer]. The - * stream can be trimmed and previewed in the animation. + * Audio tracks are used to play an audio stream with either type of [AudioStreamPlayer]. The stream can be trimmed and previewed in the animation. */ TYPE_AUDIO(7), /** @@ -1173,9 +1102,7 @@ public open class Animation : Resource() { */ LINEAR(1), /** - * Cubic interpolation. This looks smoother than linear interpolation, but is more expensive to - * interpolate. Stick to [INTERPOLATION_LINEAR] for complex 3D animations imported from external - * software, even if it requires using a higher animation framerate in return. + * Cubic interpolation. This looks smoother than linear interpolation, but is more expensive to interpolate. Stick to [INTERPOLATION_LINEAR] for complex 3D animations imported from external software, even if it requires using a higher animation framerate in return. */ CUBIC(2), /** @@ -1214,9 +1141,7 @@ public open class Animation : Resource() { */ DISCRETE(1), /** - * Same as [UPDATE_CONTINUOUS] but works as a flag to capture the value of the current object - * and perform interpolation in some methods. See also [AnimationMixer.capture], - * [AnimationPlayer.playbackAutoCapture], and [AnimationPlayer.playWithCapture]. + * Same as [UPDATE_CONTINUOUS] but works as a flag to capture the value of the current object and perform interpolation in some methods. See also [AnimationMixer.capture], [AnimationPlayer.playbackAutoCapture], and [AnimationPlayer.playWithCapture]. */ CAPTURE(2), ; @@ -1239,8 +1164,7 @@ public open class Animation : Resource() { */ NONE(0), /** - * At both ends of the animation, the animation will be repeated without changing the playback - * direction. + * At both ends of the animation, the animation will be repeated without changing the playback direction. */ LINEAR(1), /** @@ -1267,13 +1191,11 @@ public open class Animation : Resource() { */ NONE(0), /** - * This flag indicates that the animation has reached the end of the animation and just after - * loop processed. + * This flag indicates that the animation has reached the end of the animation and just after loop processed. */ END(1), /** - * This flag indicates that the animation has reached the start of the animation and just after - * loop processed. + * This flag indicates that the animation has reached the start of the animation and just after loop processed. */ START(2), ; @@ -1319,257 +1241,258 @@ public open class Animation : Resource() { public object MethodBindings { internal val addTrackPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "add_track", 3843682357) + TypeManager.getMethodBindPtr("Animation", "add_track", 3_843_682_357) internal val removeTrackPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "remove_track", 1286410249) + TypeManager.getMethodBindPtr("Animation", "remove_track", 1_286_410_249) internal val getTrackCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "get_track_count", 3905245786) + TypeManager.getMethodBindPtr("Animation", "get_track_count", 3_905_245_786) internal val trackGetTypePtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "track_get_type", 3445944217) + TypeManager.getMethodBindPtr("Animation", "track_get_type", 3_445_944_217) internal val trackGetPathPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "track_get_path", 408788394) + TypeManager.getMethodBindPtr("Animation", "track_get_path", 408_788_394) internal val trackSetPathPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "track_set_path", 2761262315) + TypeManager.getMethodBindPtr("Animation", "track_set_path", 2_761_262_315) internal val findTrackPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "find_track", 245376003) + TypeManager.getMethodBindPtr("Animation", "find_track", 245_376_003) internal val trackMoveUpPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "track_move_up", 1286410249) + TypeManager.getMethodBindPtr("Animation", "track_move_up", 1_286_410_249) internal val trackMoveDownPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "track_move_down", 1286410249) + TypeManager.getMethodBindPtr("Animation", "track_move_down", 1_286_410_249) internal val trackMoveToPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "track_move_to", 3937882851) + TypeManager.getMethodBindPtr("Animation", "track_move_to", 3_937_882_851) internal val trackSwapPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "track_swap", 3937882851) + TypeManager.getMethodBindPtr("Animation", "track_swap", 3_937_882_851) internal val trackSetImportedPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "track_set_imported", 300928843) + TypeManager.getMethodBindPtr("Animation", "track_set_imported", 300_928_843) internal val trackIsImportedPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "track_is_imported", 1116898809) + TypeManager.getMethodBindPtr("Animation", "track_is_imported", 1_116_898_809) internal val trackSetEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "track_set_enabled", 300928843) + TypeManager.getMethodBindPtr("Animation", "track_set_enabled", 300_928_843) internal val trackIsEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "track_is_enabled", 1116898809) + TypeManager.getMethodBindPtr("Animation", "track_is_enabled", 1_116_898_809) internal val positionTrackInsertKeyPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "position_track_insert_key", 2540608232) + TypeManager.getMethodBindPtr("Animation", "position_track_insert_key", 2_540_608_232) internal val rotationTrackInsertKeyPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "rotation_track_insert_key", 4165004800) + TypeManager.getMethodBindPtr("Animation", "rotation_track_insert_key", 4_165_004_800) internal val scaleTrackInsertKeyPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "scale_track_insert_key", 2540608232) + TypeManager.getMethodBindPtr("Animation", "scale_track_insert_key", 2_540_608_232) internal val blendShapeTrackInsertKeyPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "blend_shape_track_insert_key", 1534913637) + TypeManager.getMethodBindPtr("Animation", "blend_shape_track_insert_key", 1_534_913_637) internal val positionTrackInterpolatePtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "position_track_interpolate", 3530011197) + TypeManager.getMethodBindPtr("Animation", "position_track_interpolate", 3_530_011_197) internal val rotationTrackInterpolatePtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "rotation_track_interpolate", 2915876792) + TypeManager.getMethodBindPtr("Animation", "rotation_track_interpolate", 2_915_876_792) internal val scaleTrackInterpolatePtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "scale_track_interpolate", 3530011197) + TypeManager.getMethodBindPtr("Animation", "scale_track_interpolate", 3_530_011_197) internal val blendShapeTrackInterpolatePtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "blend_shape_track_interpolate", 2482365182) + TypeManager.getMethodBindPtr("Animation", "blend_shape_track_interpolate", 2_482_365_182) internal val trackInsertKeyPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "track_insert_key", 808952278) + TypeManager.getMethodBindPtr("Animation", "track_insert_key", 808_952_278) internal val trackRemoveKeyPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "track_remove_key", 3937882851) + TypeManager.getMethodBindPtr("Animation", "track_remove_key", 3_937_882_851) internal val trackRemoveKeyAtTimePtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "track_remove_key_at_time", 1602489585) + TypeManager.getMethodBindPtr("Animation", "track_remove_key_at_time", 1_602_489_585) internal val trackSetKeyValuePtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "track_set_key_value", 2060538656) + TypeManager.getMethodBindPtr("Animation", "track_set_key_value", 2_060_538_656) internal val trackSetKeyTransitionPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "track_set_key_transition", 3506521499) + TypeManager.getMethodBindPtr("Animation", "track_set_key_transition", 3_506_521_499) internal val trackSetKeyTimePtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "track_set_key_time", 3506521499) + TypeManager.getMethodBindPtr("Animation", "track_set_key_time", 3_506_521_499) internal val trackGetKeyTransitionPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "track_get_key_transition", 3085491603) + TypeManager.getMethodBindPtr("Animation", "track_get_key_transition", 3_085_491_603) internal val trackGetKeyCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "track_get_key_count", 923996154) + TypeManager.getMethodBindPtr("Animation", "track_get_key_count", 923_996_154) internal val trackGetKeyValuePtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "track_get_key_value", 678354945) + TypeManager.getMethodBindPtr("Animation", "track_get_key_value", 678_354_945) internal val trackGetKeyTimePtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "track_get_key_time", 3085491603) + TypeManager.getMethodBindPtr("Animation", "track_get_key_time", 3_085_491_603) internal val trackFindKeyPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "track_find_key", 4230953007) + TypeManager.getMethodBindPtr("Animation", "track_find_key", 4_230_953_007) internal val trackSetInterpolationTypePtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "track_set_interpolation_type", 4112932513) + TypeManager.getMethodBindPtr("Animation", "track_set_interpolation_type", 4_112_932_513) internal val trackGetInterpolationTypePtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "track_get_interpolation_type", 1530756894) + TypeManager.getMethodBindPtr("Animation", "track_get_interpolation_type", 1_530_756_894) internal val trackSetInterpolationLoopWrapPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "track_set_interpolation_loop_wrap", 300928843) + TypeManager.getMethodBindPtr("Animation", "track_set_interpolation_loop_wrap", 300_928_843) internal val trackGetInterpolationLoopWrapPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "track_get_interpolation_loop_wrap", 1116898809) + TypeManager.getMethodBindPtr("Animation", "track_get_interpolation_loop_wrap", 1_116_898_809) internal val trackIsCompressedPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "track_is_compressed", 1116898809) + TypeManager.getMethodBindPtr("Animation", "track_is_compressed", 1_116_898_809) internal val valueTrackSetUpdateModePtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "value_track_set_update_mode", 2854058312) + TypeManager.getMethodBindPtr("Animation", "value_track_set_update_mode", 2_854_058_312) internal val valueTrackGetUpdateModePtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "value_track_get_update_mode", 1440326473) + TypeManager.getMethodBindPtr("Animation", "value_track_get_update_mode", 1_440_326_473) internal val valueTrackInterpolatePtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "value_track_interpolate", 747269075) + TypeManager.getMethodBindPtr("Animation", "value_track_interpolate", 747_269_075) internal val methodTrackGetNamePtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "method_track_get_name", 351665558) + TypeManager.getMethodBindPtr("Animation", "method_track_get_name", 351_665_558) internal val methodTrackGetParamsPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "method_track_get_params", 2345056839) + TypeManager.getMethodBindPtr("Animation", "method_track_get_params", 2_345_056_839) internal val bezierTrackInsertKeyPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "bezier_track_insert_key", 3656773645) + TypeManager.getMethodBindPtr("Animation", "bezier_track_insert_key", 3_656_773_645) internal val bezierTrackSetKeyValuePtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "bezier_track_set_key_value", 3506521499) + TypeManager.getMethodBindPtr("Animation", "bezier_track_set_key_value", 3_506_521_499) internal val bezierTrackSetKeyInHandlePtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "bezier_track_set_key_in_handle", 1719223284) + TypeManager.getMethodBindPtr("Animation", "bezier_track_set_key_in_handle", 1_719_223_284) internal val bezierTrackSetKeyOutHandlePtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "bezier_track_set_key_out_handle", 1719223284) + TypeManager.getMethodBindPtr("Animation", "bezier_track_set_key_out_handle", 1_719_223_284) internal val bezierTrackGetKeyValuePtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "bezier_track_get_key_value", 3085491603) + TypeManager.getMethodBindPtr("Animation", "bezier_track_get_key_value", 3_085_491_603) internal val bezierTrackGetKeyInHandlePtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "bezier_track_get_key_in_handle", 3016396712) + TypeManager.getMethodBindPtr("Animation", "bezier_track_get_key_in_handle", 3_016_396_712) internal val bezierTrackGetKeyOutHandlePtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "bezier_track_get_key_out_handle", 3016396712) + TypeManager.getMethodBindPtr("Animation", "bezier_track_get_key_out_handle", 3_016_396_712) internal val bezierTrackInterpolatePtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "bezier_track_interpolate", 1900462983) + TypeManager.getMethodBindPtr("Animation", "bezier_track_interpolate", 1_900_462_983) internal val audioTrackInsertKeyPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "audio_track_insert_key", 4021027286) + TypeManager.getMethodBindPtr("Animation", "audio_track_insert_key", 4_021_027_286) internal val audioTrackSetKeyStreamPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "audio_track_set_key_stream", 3886397084) + TypeManager.getMethodBindPtr("Animation", "audio_track_set_key_stream", 3_886_397_084) internal val audioTrackSetKeyStartOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "audio_track_set_key_start_offset", 3506521499) + TypeManager.getMethodBindPtr("Animation", "audio_track_set_key_start_offset", 3_506_521_499) internal val audioTrackSetKeyEndOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "audio_track_set_key_end_offset", 3506521499) + TypeManager.getMethodBindPtr("Animation", "audio_track_set_key_end_offset", 3_506_521_499) internal val audioTrackGetKeyStreamPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "audio_track_get_key_stream", 635277205) + TypeManager.getMethodBindPtr("Animation", "audio_track_get_key_stream", 635_277_205) internal val audioTrackGetKeyStartOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "audio_track_get_key_start_offset", 3085491603) + TypeManager.getMethodBindPtr("Animation", "audio_track_get_key_start_offset", 3_085_491_603) internal val audioTrackGetKeyEndOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "audio_track_get_key_end_offset", 3085491603) + TypeManager.getMethodBindPtr("Animation", "audio_track_get_key_end_offset", 3_085_491_603) internal val audioTrackSetUseBlendPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "audio_track_set_use_blend", 300928843) + TypeManager.getMethodBindPtr("Animation", "audio_track_set_use_blend", 300_928_843) internal val audioTrackIsUseBlendPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "audio_track_is_use_blend", 1116898809) + TypeManager.getMethodBindPtr("Animation", "audio_track_is_use_blend", 1_116_898_809) internal val animationTrackInsertKeyPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "animation_track_insert_key", 158676774) + TypeManager.getMethodBindPtr("Animation", "animation_track_insert_key", 158_676_774) internal val animationTrackSetKeyAnimationPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "animation_track_set_key_animation", 117615382) + TypeManager.getMethodBindPtr("Animation", "animation_track_set_key_animation", 117_615_382) internal val animationTrackGetKeyAnimationPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "animation_track_get_key_animation", 351665558) + TypeManager.getMethodBindPtr("Animation", "animation_track_get_key_animation", 351_665_558) internal val addMarkerPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "add_marker", 4135858297) + TypeManager.getMethodBindPtr("Animation", "add_marker", 4_135_858_297) internal val removeMarkerPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "remove_marker", 3304788590) + TypeManager.getMethodBindPtr("Animation", "remove_marker", 3_304_788_590) internal val hasMarkerPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "has_marker", 2619796661) + TypeManager.getMethodBindPtr("Animation", "has_marker", 2_619_796_661) internal val getMarkerAtTimePtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "get_marker_at_time", 4079494655) + TypeManager.getMethodBindPtr("Animation", "get_marker_at_time", 4_079_494_655) internal val getNextMarkerPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "get_next_marker", 4079494655) + TypeManager.getMethodBindPtr("Animation", "get_next_marker", 4_079_494_655) internal val getPrevMarkerPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "get_prev_marker", 4079494655) + TypeManager.getMethodBindPtr("Animation", "get_prev_marker", 4_079_494_655) internal val getMarkerTimePtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "get_marker_time", 2349060816) + TypeManager.getMethodBindPtr("Animation", "get_marker_time", 2_349_060_816) internal val getMarkerNamesPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "get_marker_names", 1139954409) + TypeManager.getMethodBindPtr("Animation", "get_marker_names", 1_139_954_409) internal val getMarkerColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "get_marker_color", 3742943038) + TypeManager.getMethodBindPtr("Animation", "get_marker_color", 3_742_943_038) internal val setMarkerColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "set_marker_color", 4260178595) + TypeManager.getMethodBindPtr("Animation", "set_marker_color", 4_260_178_595) internal val setLengthPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "set_length", 373806689) + TypeManager.getMethodBindPtr("Animation", "set_length", 373_806_689) internal val getLengthPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "get_length", 1740695150) + TypeManager.getMethodBindPtr("Animation", "get_length", 1_740_695_150) internal val setLoopModePtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "set_loop_mode", 3155355575) + TypeManager.getMethodBindPtr("Animation", "set_loop_mode", 3_155_355_575) internal val getLoopModePtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "get_loop_mode", 1988889481) + TypeManager.getMethodBindPtr("Animation", "get_loop_mode", 1_988_889_481) internal val setStepPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "set_step", 373806689) + TypeManager.getMethodBindPtr("Animation", "set_step", 373_806_689) internal val getStepPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "get_step", 1740695150) + TypeManager.getMethodBindPtr("Animation", "get_step", 1_740_695_150) - internal val clearPtr: VoidPtr = TypeManager.getMethodBindPtr("Animation", "clear", 3218959716) + internal val clearPtr: VoidPtr = + TypeManager.getMethodBindPtr("Animation", "clear", 3_218_959_716) internal val copyTrackPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "copy_track", 148001024) + TypeManager.getMethodBindPtr("Animation", "copy_track", 148_001_024) internal val optimizePtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "optimize", 3303583852) + TypeManager.getMethodBindPtr("Animation", "optimize", 3_303_583_852) internal val compressPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "compress", 3608408117) + TypeManager.getMethodBindPtr("Animation", "compress", 3_608_408_117) internal val isCaptureIncludedPtr: VoidPtr = - TypeManager.getMethodBindPtr("Animation", "is_capture_included", 36873697) + TypeManager.getMethodBindPtr("Animation", "is_capture_included", 36_873_697) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationLibrary.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationLibrary.kt index e23cf7a69f..5e35534a4a 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationLibrary.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationLibrary.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -30,8 +27,7 @@ import kotlin.Suppress import kotlin.Unit /** - * An animation library stores a set of animations accessible through [StringName] keys, for use - * with [AnimationPlayer] nodes. + * An animation library stores a set of animations accessible through [StringName] keys, for use with [AnimationPlayer] nodes. */ @GodotBaseType public open class AnimationLibrary : Resource() { @@ -51,14 +47,13 @@ public open class AnimationLibrary : Resource() { public val animationRenamed: Signal2 by Signal2 /** - * Emitted when there's a change in one of the animations, e.g. tracks are added, moved or have - * changed paths. [name] is the key of the animation that was changed. + * Emitted when there's a change in one of the animations, e.g. tracks are added, moved or have changed paths. [name] is the key of the animation that was changed. * * See also [signal Resource.changed], which this acts as a relay for. */ public val animationChanged: Signal1 by Signal1 - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(13, scriptIndex) } @@ -74,7 +69,7 @@ public open class AnimationLibrary : Resource() { /** * Removes the [Animation] with the key [name]. */ - public final fun removeAnimation(name: StringName): Unit { + public final fun removeAnimation(name: StringName) { TransferContext.writeArguments(STRING_NAME to name) TransferContext.callMethod(ptr, MethodBindings.removeAnimationPtr, NIL) } @@ -82,7 +77,7 @@ public open class AnimationLibrary : Resource() { /** * Changes the key of the [Animation] associated with the key [name] to [newname]. */ - public final fun renameAnimation(name: StringName, newname: StringName): Unit { + public final fun renameAnimation(name: StringName, newname: StringName) { TransferContext.writeArguments(STRING_NAME to name, STRING_NAME to newname) TransferContext.callMethod(ptr, MethodBindings.renameAnimationPtr, NIL) } @@ -97,8 +92,7 @@ public open class AnimationLibrary : Resource() { } /** - * Returns the [Animation] with the key [name]. If the animation does not exist, `null` is - * returned and an error is logged. + * Returns the [Animation] with the key [name]. If the animation does not exist, `null` is returned and an error is logged. */ public final fun getAnimation(name: StringName): Animation? { TransferContext.writeArguments(STRING_NAME to name) @@ -127,19 +121,17 @@ public open class AnimationLibrary : Resource() { /** * Adds the [animation] to the library, accessible by the key [name]. */ - public final fun addAnimation(name: String, animation: Animation?): Error = - addAnimation(name.asCachedStringName(), animation) + public final fun addAnimation(name: String, animation: Animation?): Error = addAnimation(name.asCachedStringName(), animation) /** * Removes the [Animation] with the key [name]. */ - public final fun removeAnimation(name: String) = removeAnimation(name.asCachedStringName()) + public final fun removeAnimation(name: String): Unit = removeAnimation(name.asCachedStringName()) /** * Changes the key of the [Animation] associated with the key [name] to [newname]. */ - public final fun renameAnimation(name: String, newname: String) = - renameAnimation(name.asCachedStringName(), newname.asCachedStringName()) + public final fun renameAnimation(name: String, newname: String): Unit = renameAnimation(name.asCachedStringName(), newname.asCachedStringName()) /** * Returns `true` if the library stores an [Animation] with [name] as the key. @@ -147,8 +139,7 @@ public open class AnimationLibrary : Resource() { public final fun hasAnimation(name: String): Boolean = hasAnimation(name.asCachedStringName()) /** - * Returns the [Animation] with the key [name]. If the animation does not exist, `null` is - * returned and an error is logged. + * Returns the [Animation] with the key [name]. If the animation does not exist, `null` is returned and an error is logged. */ public final fun getAnimation(name: String): Animation? = getAnimation(name.asCachedStringName()) @@ -156,24 +147,24 @@ public open class AnimationLibrary : Resource() { public object MethodBindings { internal val addAnimationPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationLibrary", "add_animation", 1811855551) + TypeManager.getMethodBindPtr("AnimationLibrary", "add_animation", 1_811_855_551) internal val removeAnimationPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationLibrary", "remove_animation", 3304788590) + TypeManager.getMethodBindPtr("AnimationLibrary", "remove_animation", 3_304_788_590) internal val renameAnimationPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationLibrary", "rename_animation", 3740211285) + TypeManager.getMethodBindPtr("AnimationLibrary", "rename_animation", 3_740_211_285) internal val hasAnimationPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationLibrary", "has_animation", 2619796661) + TypeManager.getMethodBindPtr("AnimationLibrary", "has_animation", 2_619_796_661) internal val getAnimationPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationLibrary", "get_animation", 2933122410) + TypeManager.getMethodBindPtr("AnimationLibrary", "get_animation", 2_933_122_410) internal val getAnimationListPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationLibrary", "get_animation_list", 3995934104) + TypeManager.getMethodBindPtr("AnimationLibrary", "get_animation_list", 3_995_934_104) internal val getAnimationListSizePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationLibrary", "get_animation_list_size", 3905245786) + TypeManager.getMethodBindPtr("AnimationLibrary", "get_animation_list_size", 3_905_245_786) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationMixer.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationMixer.kt index aa6dce9e30..395e5cba34 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationMixer.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationMixer.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -45,11 +42,9 @@ import kotlin.jvm.JvmName import kotlin.jvm.JvmOverloads /** - * Base class for [AnimationPlayer] and [AnimationTree] to manage animation lists. It also has - * general properties and methods for playback and blending. + * Base class for [AnimationPlayer] and [AnimationTree] to manage animation lists. It also has general properties and methods for playback and blending. * - * After instantiating the playback information data within the extended class, the blending is - * processed by the [AnimationMixer]. + * After instantiating the playback information data within the extended class, the blending is processed by the [AnimationMixer]. */ @GodotBaseType public open class AnimationMixer internal constructor() : Node() { @@ -76,8 +71,7 @@ public open class AnimationMixer internal constructor() : Node() { public val animationStarted: Signal1 by Signal1 /** - * Notifies when the caches have been cleared, either automatically, or manually via - * [clearCaches]. + * Notifies when the caches have been cleared, either automatically, or manually via [clearCaches]. */ public val cachesCleared: Signal0 by Signal0 @@ -103,25 +97,17 @@ public open class AnimationMixer internal constructor() : Node() { } /** - * If `true`, the blending uses the deterministic algorithm. The total weight is not normalized - * and the result is accumulated with an initial value (`0` or a `"RESET"` animation if present). + * If `true`, the blending uses the deterministic algorithm. The total weight is not normalized and the result is accumulated with an initial value (`0` or a `"RESET"` animation if present). * - * This means that if the total amount of blending is `0.0`, the result is equal to the `"RESET"` - * animation. + * This means that if the total amount of blending is `0.0`, the result is equal to the `"RESET"` animation. * - * If the number of tracks between the blended animations is different, the animation with the - * missing track is treated as if it had the initial value. + * If the number of tracks between the blended animations is different, the animation with the missing track is treated as if it had the initial value. * - * If `false`, The blend does not use the deterministic algorithm. The total weight is normalized - * and always `1.0`. If the number of tracks between the blended animations is different, nothing is - * done about the animation that is missing a track. + * If `false`, The blend does not use the deterministic algorithm. The total weight is normalized and always `1.0`. If the number of tracks between the blended animations is different, nothing is done about the animation that is missing a track. * - * **Note:** In [AnimationTree], the blending with [AnimationNodeAdd2], [AnimationNodeAdd3], - * [AnimationNodeSub2] or the weight greater than `1.0` may produce unexpected results. + * **Note:** In [AnimationTree], the blending with [AnimationNodeAdd2], [AnimationNodeAdd3], [AnimationNodeSub2] or the weight greater than `1.0` may produce unexpected results. * - * For example, if [AnimationNodeAdd2] blends two nodes with the amount `1.0`, then total weight - * is `2.0` but it will be normalized to make the total amount `1.0` and the result will be equal to - * [AnimationNodeBlend2] with the amount `0.5`. + * For example, if [AnimationNodeAdd2] blends two nodes with the amount `1.0`, then total weight is `2.0` but it will be normalized to make the total amount `1.0` and the result will be equal to [AnimationNodeBlend2] with the amount `0.5`. */ public final inline var deterministic: Boolean @JvmName("deterministicProperty") @@ -132,12 +118,9 @@ public open class AnimationMixer internal constructor() : Node() { } /** - * This is used by the editor. If set to `true`, the scene will be saved with the effects of the - * reset animation (the animation with the key `"RESET"`) applied as if it had been seeked to time 0, - * with the editor keeping the values that the scene had before saving. + * This is used by the editor. If set to `true`, the scene will be saved with the effects of the reset animation (the animation with the key `"RESET"`) applied as if it had been seeked to time 0, with the editor keeping the values that the scene had before saving. * - * This makes it more convenient to preview and edit animations in the editor, as changes to the - * scene will not be saved as long as they are set in the reset animation. + * This makes it more convenient to preview and edit animations in the editor, as changes to the scene will not be saved as long as they are set in the reset animation. */ public final inline var resetOnSave: Boolean @JvmName("resetOnSaveProperty") @@ -159,15 +142,9 @@ public open class AnimationMixer internal constructor() : Node() { } /** - * The path to the Animation track used for root motion. Paths must be valid scene-tree paths to a - * node, and must be specified starting from the parent node of the node that will reproduce the - * animation. The [rootMotionTrack] uses the same format as [Animation.trackSetPath], but note that a - * bone must be specified. + * The path to the Animation track used for root motion. Paths must be valid scene-tree paths to a node, and must be specified starting from the parent node of the node that will reproduce the animation. The [rootMotionTrack] uses the same format as [Animation.trackSetPath], but note that a bone must be specified. * - * If the track has type [Animation.TYPE_POSITION_3D], [Animation.TYPE_ROTATION_3D], or - * [Animation.TYPE_SCALE_3D] the transformation will be canceled visually, and the animation will - * appear to stay in place. See also [getRootMotionPosition], [getRootMotionRotation], - * [getRootMotionScale], and [RootMotionView]. + * If the track has type [Animation.TYPE_POSITION_3D], [Animation.TYPE_ROTATION_3D], or [Animation.TYPE_SCALE_3D] the transformation will be canceled visually, and the animation will appear to stay in place. See also [getRootMotionPosition], [getRootMotionRotation], [getRootMotionScale], and [RootMotionView]. */ public final inline var rootMotionTrack: NodePath @JvmName("rootMotionTrackProperty") @@ -178,8 +155,7 @@ public open class AnimationMixer internal constructor() : Node() { } /** - * If `true`, [getRootMotionPosition] value is extracted as a local translation value before - * blending. In other words, it is treated like the translation is done after the rotation. + * If `true`, [getRootMotionPosition] value is extracted as a local translation value before blending. In other words, it is treated like the translation is done after the rotation. */ public final inline var rootMotionLocal: Boolean @JvmName("rootMotionLocalProperty") @@ -192,8 +168,7 @@ public open class AnimationMixer internal constructor() : Node() { /** * The number of possible simultaneous sounds for each of the assigned AudioStreamPlayers. * - * For example, if this value is `32` and the animation has two audio tracks, the two - * [AudioStreamPlayer]s assigned can play simultaneously up to `32` voices each. + * For example, if this value is `32` and the animation has two audio tracks, the two [AudioStreamPlayer]s assigned can play simultaneously up to `32` voices each. */ public final inline var audioMaxPolyphony: Int @JvmName("audioMaxPolyphonyProperty") @@ -226,16 +201,11 @@ public open class AnimationMixer internal constructor() : Node() { } /** - * Ordinarily, tracks can be set to [Animation.UPDATE_DISCRETE] to update infrequently, usually - * when using nearest interpolation. + * Ordinarily, tracks can be set to [Animation.UPDATE_DISCRETE] to update infrequently, usually when using nearest interpolation. * - * However, when blending with [Animation.UPDATE_CONTINUOUS] several results are considered. The - * [callbackModeDiscrete] specify it explicitly. See also [AnimationCallbackModeDiscrete]. + * However, when blending with [Animation.UPDATE_CONTINUOUS] several results are considered. The [callbackModeDiscrete] specify it explicitly. See also [AnimationCallbackModeDiscrete]. * - * To make the blended results look good, it is recommended to set this to - * [ANIMATION_CALLBACK_MODE_DISCRETE_FORCE_CONTINUOUS] to update every frame during blending. Other - * values exist for compatibility and they are fine if there is no blending, but not so, may produce - * artifacts. + * To make the blended results look good, it is recommended to set this to [ANIMATION_CALLBACK_MODE_DISCRETE_FORCE_CONTINUOUS] to update every frame during blending. Other values exist for compatibility and they are fine if there is no blending, but not so, may produce artifacts. */ public final inline var callbackModeDiscrete: AnimationCallbackModeDiscrete @JvmName("callbackModeDiscreteProperty") @@ -245,7 +215,7 @@ public open class AnimationMixer internal constructor() : Node() { setCallbackModeDiscrete(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(14, scriptIndex) } @@ -265,8 +235,7 @@ public open class AnimationMixer internal constructor() : Node() { /** * Adds [library] to the animation player, under the key [name]. * - * AnimationMixer has a global library by default with an empty string as key. For adding an - * animation to the global library: + * AnimationMixer has a global library by default with an empty string as key. For adding an animation to the global library: * * ```gdscript * //gdscript @@ -283,7 +252,7 @@ public open class AnimationMixer internal constructor() : Node() { /** * Removes the [AnimationLibrary] associated with the key [name]. */ - public final fun removeAnimationLibrary(name: StringName): Unit { + public final fun removeAnimationLibrary(name: StringName) { TransferContext.writeArguments(STRING_NAME to name) TransferContext.callMethod(ptr, MethodBindings.removeAnimationLibraryPtr, NIL) } @@ -291,7 +260,7 @@ public open class AnimationMixer internal constructor() : Node() { /** * Moves the [AnimationLibrary] associated with the key [name] to the key [newname]. */ - public final fun renameAnimationLibrary(name: StringName, newname: StringName): Unit { + public final fun renameAnimationLibrary(name: StringName, newname: StringName) { TransferContext.writeArguments(STRING_NAME to name, STRING_NAME to newname) TransferContext.callMethod(ptr, MethodBindings.renameAnimationLibraryPtr, NIL) } @@ -335,8 +304,7 @@ public open class AnimationMixer internal constructor() : Node() { } /** - * Returns the [Animation] with the key [name]. If the animation does not exist, `null` is - * returned and an error is logged. + * Returns the [Animation] with the key [name]. If the animation does not exist, `null` is returned and an error is logged. */ public final fun getAnimation(name: StringName): Animation? { TransferContext.writeArguments(STRING_NAME to name) @@ -353,7 +321,7 @@ public open class AnimationMixer internal constructor() : Node() { return (TransferContext.readReturnValue(PACKED_STRING_ARRAY) as PackedStringArray) } - public final fun setActive(active: Boolean): Unit { + public final fun setActive(active: Boolean) { TransferContext.writeArguments(BOOL to active) TransferContext.callMethod(ptr, MethodBindings.setActivePtr, NIL) } @@ -364,7 +332,7 @@ public open class AnimationMixer internal constructor() : Node() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setDeterministic(deterministic: Boolean): Unit { + public final fun setDeterministic(deterministic: Boolean) { TransferContext.writeArguments(BOOL to deterministic) TransferContext.callMethod(ptr, MethodBindings.setDeterministicPtr, NIL) } @@ -375,7 +343,7 @@ public open class AnimationMixer internal constructor() : Node() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setRootNode(path: NodePath): Unit { + public final fun setRootNode(path: NodePath) { TransferContext.writeArguments(NODE_PATH to path) TransferContext.callMethod(ptr, MethodBindings.setRootNodePtr, NIL) } @@ -386,7 +354,7 @@ public open class AnimationMixer internal constructor() : Node() { return (TransferContext.readReturnValue(NODE_PATH) as NodePath) } - public final fun setCallbackModeProcess(mode: AnimationCallbackModeProcess): Unit { + public final fun setCallbackModeProcess(mode: AnimationCallbackModeProcess) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setCallbackModeProcessPtr, NIL) } @@ -397,7 +365,7 @@ public open class AnimationMixer internal constructor() : Node() { return AnimationCallbackModeProcess.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setCallbackModeMethod(mode: AnimationCallbackModeMethod): Unit { + public final fun setCallbackModeMethod(mode: AnimationCallbackModeMethod) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setCallbackModeMethodPtr, NIL) } @@ -408,7 +376,7 @@ public open class AnimationMixer internal constructor() : Node() { return AnimationCallbackModeMethod.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setCallbackModeDiscrete(mode: AnimationCallbackModeDiscrete): Unit { + public final fun setCallbackModeDiscrete(mode: AnimationCallbackModeDiscrete) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setCallbackModeDiscretePtr, NIL) } @@ -419,7 +387,7 @@ public open class AnimationMixer internal constructor() : Node() { return AnimationCallbackModeDiscrete.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setAudioMaxPolyphony(maxPolyphony: Int): Unit { + public final fun setAudioMaxPolyphony(maxPolyphony: Int) { TransferContext.writeArguments(LONG to maxPolyphony.toLong()) TransferContext.callMethod(ptr, MethodBindings.setAudioMaxPolyphonyPtr, NIL) } @@ -430,7 +398,7 @@ public open class AnimationMixer internal constructor() : Node() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setRootMotionTrack(path: NodePath): Unit { + public final fun setRootMotionTrack(path: NodePath) { TransferContext.writeArguments(NODE_PATH to path) TransferContext.callMethod(ptr, MethodBindings.setRootMotionTrackPtr, NIL) } @@ -441,7 +409,7 @@ public open class AnimationMixer internal constructor() : Node() { return (TransferContext.readReturnValue(NODE_PATH) as NodePath) } - public final fun setRootMotionLocal(enabled: Boolean): Unit { + public final fun setRootMotionLocal(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setRootMotionLocalPtr, NIL) } @@ -453,11 +421,9 @@ public open class AnimationMixer internal constructor() : Node() { } /** - * Retrieve the motion delta of position with the [rootMotionTrack] as a [Vector3] that can be - * used elsewhere. + * Retrieve the motion delta of position with the [rootMotionTrack] as a [Vector3] that can be used elsewhere. * - * If [rootMotionTrack] is not a path to a track of type [Animation.TYPE_POSITION_3D], returns - * `Vector3(0, 0, 0)`. + * If [rootMotionTrack] is not a path to a track of type [Animation.TYPE_POSITION_3D], returns `Vector3(0, 0, 0)`. * * See also [rootMotionTrack] and [RootMotionView]. * @@ -476,8 +442,7 @@ public open class AnimationMixer internal constructor() : Node() { * move_and_slide() * ``` * - * By using this in combination with [getRootMotionRotationAccumulator], you can apply the root - * motion position more correctly to account for the rotation of the node. + * By using this in combination with [getRootMotionRotationAccumulator], you can apply the root motion position more correctly to account for the rotation of the node. * * ```gdscript * //gdscript @@ -485,14 +450,12 @@ public open class AnimationMixer internal constructor() : Node() { * if Input.is_action_just_pressed("animate"): * state_machine.travel("Animate") * set_quaternion(get_quaternion() * animation_tree.get_root_motion_rotation()) - * var velocity = (animation_tree.get_root_motion_rotation_accumulator().inverse() * - * get_quaternion()) * animation_tree.get_root_motion_position() / delta + * var velocity = (animation_tree.get_root_motion_rotation_accumulator().inverse() * get_quaternion()) * animation_tree.get_root_motion_position() / delta * set_velocity(velocity) * move_and_slide() * ``` * - * If [rootMotionLocal] is `true`, return the pre-multiplied translation value with the inverted - * rotation. + * If [rootMotionLocal] is `true`, return the pre-multiplied translation value with the inverted rotation. * * In this case, the code can be written as follows: * @@ -514,11 +477,9 @@ public open class AnimationMixer internal constructor() : Node() { } /** - * Retrieve the motion delta of rotation with the [rootMotionTrack] as a [Quaternion] that can be - * used elsewhere. + * Retrieve the motion delta of rotation with the [rootMotionTrack] as a [Quaternion] that can be used elsewhere. * - * If [rootMotionTrack] is not a path to a track of type [Animation.TYPE_ROTATION_3D], returns - * `Quaternion(0, 0, 0, 1)`. + * If [rootMotionTrack] is not a path to a track of type [Animation.TYPE_ROTATION_3D], returns `Quaternion(0, 0, 0, 1)`. * * See also [rootMotionTrack] and [RootMotionView]. * @@ -539,11 +500,9 @@ public open class AnimationMixer internal constructor() : Node() { } /** - * Retrieve the motion delta of scale with the [rootMotionTrack] as a [Vector3] that can be used - * elsewhere. + * Retrieve the motion delta of scale with the [rootMotionTrack] as a [Vector3] that can be used elsewhere. * - * If [rootMotionTrack] is not a path to a track of type [Animation.TYPE_SCALE_3D], returns - * `Vector3(0, 0, 0)`. + * If [rootMotionTrack] is not a path to a track of type [Animation.TYPE_SCALE_3D], returns `Vector3(0, 0, 0)`. * * See also [rootMotionTrack] and [RootMotionView]. * @@ -570,14 +529,11 @@ public open class AnimationMixer internal constructor() : Node() { } /** - * Retrieve the blended value of the position tracks with the [rootMotionTrack] as a [Vector3] - * that can be used elsewhere. + * Retrieve the blended value of the position tracks with the [rootMotionTrack] as a [Vector3] that can be used elsewhere. * * This is useful in cases where you want to respect the initial key values of the animation. * - * For example, if an animation with only one key `Vector3(0, 0, 0)` is played in the previous - * frame and then an animation with only one key `Vector3(1, 0, 1)` is played in the next frame, the - * difference can be calculated as follows: + * For example, if an animation with only one key `Vector3(0, 0, 0)` is played in the previous frame and then an animation with only one key `Vector3(1, 0, 1)` is played in the next frame, the difference can be calculated as follows: * * ```gdscript * //gdscript @@ -586,16 +542,13 @@ public open class AnimationMixer internal constructor() : Node() { * func _process(delta): * if Input.is_action_just_pressed("animate"): * state_machine.travel("Animate") - * var current_root_motion_position_accumulator = - * animation_tree.get_root_motion_position_accumulator() - * var difference = current_root_motion_position_accumulator - - * prev_root_motion_position_accumulator + * var current_root_motion_position_accumulator = animation_tree.get_root_motion_position_accumulator() + * var difference = current_root_motion_position_accumulator - prev_root_motion_position_accumulator * prev_root_motion_position_accumulator = current_root_motion_position_accumulator * transform.origin += difference * ``` * - * However, if the animation loops, an unintended discrete change may occur, so this is only - * useful for some simple use cases. + * However, if the animation loops, an unintended discrete change may occur, so this is only useful for some simple use cases. */ public final fun getRootMotionPositionAccumulator(): Vector3 { TransferContext.writeArguments() @@ -604,18 +557,13 @@ public open class AnimationMixer internal constructor() : Node() { } /** - * Retrieve the blended value of the rotation tracks with the [rootMotionTrack] as a [Quaternion] - * that can be used elsewhere. + * Retrieve the blended value of the rotation tracks with the [rootMotionTrack] as a [Quaternion] that can be used elsewhere. * - * This is necessary to apply the root motion position correctly, taking rotation into account. - * See also [getRootMotionPosition]. + * This is necessary to apply the root motion position correctly, taking rotation into account. See also [getRootMotionPosition]. * - * Also, this is useful in cases where you want to respect the initial key values of the - * animation. + * Also, this is useful in cases where you want to respect the initial key values of the animation. * - * For example, if an animation with only one key `Quaternion(0, 0, 0, 1)` is played in the - * previous frame and then an animation with only one key `Quaternion(0, 0.707, 0, 0.707)` is played - * in the next frame, the difference can be calculated as follows: + * For example, if an animation with only one key `Quaternion(0, 0, 0, 1)` is played in the previous frame and then an animation with only one key `Quaternion(0, 0.707, 0, 0.707)` is played in the next frame, the difference can be calculated as follows: * * ```gdscript * //gdscript @@ -624,16 +572,13 @@ public open class AnimationMixer internal constructor() : Node() { * func _process(delta): * if Input.is_action_just_pressed("animate"): * state_machine.travel("Animate") - * var current_root_motion_rotation_accumulator = - * animation_tree.get_root_motion_rotation_accumulator() - * var difference = prev_root_motion_rotation_accumulator.inverse() * - * current_root_motion_rotation_accumulator + * var current_root_motion_rotation_accumulator = animation_tree.get_root_motion_rotation_accumulator() + * var difference = prev_root_motion_rotation_accumulator.inverse() * current_root_motion_rotation_accumulator * prev_root_motion_rotation_accumulator = current_root_motion_rotation_accumulator * transform.basis *= Basis(difference) * ``` * - * However, if the animation loops, an unintended discrete change may occur, so this is only - * useful for some simple use cases. + * However, if the animation loops, an unintended discrete change may occur, so this is only useful for some simple use cases. */ public final fun getRootMotionRotationAccumulator(): Quaternion { TransferContext.writeArguments() @@ -642,12 +587,9 @@ public open class AnimationMixer internal constructor() : Node() { } /** - * Retrieve the blended value of the scale tracks with the [rootMotionTrack] as a [Vector3] that - * can be used elsewhere. + * Retrieve the blended value of the scale tracks with the [rootMotionTrack] as a [Vector3] that can be used elsewhere. * - * For example, if an animation with only one key `Vector3(1, 1, 1)` is played in the previous - * frame and then an animation with only one key `Vector3(2, 2, 2)` is played in the next frame, the - * difference can be calculated as follows: + * For example, if an animation with only one key `Vector3(1, 1, 1)` is played in the previous frame and then an animation with only one key `Vector3(2, 2, 2)` is played in the next frame, the difference can be calculated as follows: * * ```gdscript * //gdscript @@ -656,15 +598,13 @@ public open class AnimationMixer internal constructor() : Node() { * func _process(delta): * if Input.is_action_just_pressed("animate"): * state_machine.travel("Animate") - * var current_root_motion_scale_accumulator = - * animation_tree.get_root_motion_scale_accumulator() + * var current_root_motion_scale_accumulator = animation_tree.get_root_motion_scale_accumulator() * var difference = current_root_motion_scale_accumulator - prev_root_motion_scale_accumulator * prev_root_motion_scale_accumulator = current_root_motion_scale_accumulator * transform.basis = transform.basis.scaled(difference) * ``` * - * However, if the animation loops, an unintended discrete change may occur, so this is only - * useful for some simple use cases. + * However, if the animation loops, an unintended discrete change may occur, so this is only useful for some simple use cases. */ public final fun getRootMotionScaleAccumulator(): Vector3 { TransferContext.writeArguments() @@ -673,10 +613,9 @@ public open class AnimationMixer internal constructor() : Node() { } /** - * [AnimationMixer] caches animated nodes. It may not notice if a node disappears; [clearCaches] - * forces it to update the cache again. + * [AnimationMixer] caches animated nodes. It may not notice if a node disappears; [clearCaches] forces it to update the cache again. */ - public final fun clearCaches(): Unit { + public final fun clearCaches() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.clearCachesPtr, NIL) } @@ -684,23 +623,17 @@ public open class AnimationMixer internal constructor() : Node() { /** * Manually advance the animations by the specified time (in seconds). */ - public final fun advance(delta: Double): Unit { + public final fun advance(delta: Double) { TransferContext.writeArguments(DOUBLE to delta) TransferContext.callMethod(ptr, MethodBindings.advancePtr, NIL) } /** - * If the animation track specified by [name] has an option [Animation.UPDATE_CAPTURE], stores - * current values of the objects indicated by the track path as a cache. If there is already a - * captured cache, the old cache is discarded. + * If the animation track specified by [name] has an option [Animation.UPDATE_CAPTURE], stores current values of the objects indicated by the track path as a cache. If there is already a captured cache, the old cache is discarded. * - * After this it will interpolate with current animation blending result during the playback - * process for the time specified by [duration], working like a crossfade. + * After this it will interpolate with current animation blending result during the playback process for the time specified by [duration], working like a crossfade. * - * You can specify [transType] as the curve for the interpolation. For better results, it may be - * appropriate to specify [Tween.TRANS_LINEAR] for cases where the first key of the track begins with - * a non-zero value or where the key value does not change, and [Tween.TRANS_QUAD] for cases where - * the key value changes linearly. + * You can specify [transType] as the curve for the interpolation. For better results, it may be appropriate to specify [Tween.TRANS_LINEAR] for cases where the first key of the track begins with a non-zero value or where the key value does not change, and [Tween.TRANS_QUAD] for cases where the key value changes linearly. */ @JvmOverloads public final fun capture( @@ -708,12 +641,12 @@ public open class AnimationMixer internal constructor() : Node() { duration: Double, transType: Tween.TransitionType = Tween.TransitionType.LINEAR, easeType: Tween.EaseType = Tween.EaseType.IN, - ): Unit { + ) { TransferContext.writeArguments(STRING_NAME to name, DOUBLE to duration, LONG to transType.id, LONG to easeType.id) TransferContext.callMethod(ptr, MethodBindings.capturePtr, NIL) } - public final fun setResetOnSaveEnabled(enabled: Boolean): Unit { + public final fun setResetOnSaveEnabled(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setResetOnSaveEnabledPtr, NIL) } @@ -734,8 +667,7 @@ public open class AnimationMixer internal constructor() : Node() { } /** - * Returns the key for the [AnimationLibrary] that contains [animation] or an empty [StringName] - * if not found. + * Returns the key for the [AnimationLibrary] that contains [animation] or an empty [StringName] if not found. */ public final fun findAnimationLibrary(animation: Animation?): StringName { TransferContext.writeArguments(OBJECT to animation) @@ -746,8 +678,7 @@ public open class AnimationMixer internal constructor() : Node() { /** * Adds [library] to the animation player, under the key [name]. * - * AnimationMixer has a global library by default with an empty string as key. For adding an - * animation to the global library: + * AnimationMixer has a global library by default with an empty string as key. For adding an animation to the global library: * * ```gdscript * //gdscript @@ -755,34 +686,29 @@ public open class AnimationMixer internal constructor() : Node() { * global_library.add_animation("animation_name", animation_resource) * ``` */ - public final fun addAnimationLibrary(name: String, library: AnimationLibrary?): Error = - addAnimationLibrary(name.asCachedStringName(), library) + public final fun addAnimationLibrary(name: String, library: AnimationLibrary?): Error = addAnimationLibrary(name.asCachedStringName(), library) /** * Removes the [AnimationLibrary] associated with the key [name]. */ - public final fun removeAnimationLibrary(name: String) = - removeAnimationLibrary(name.asCachedStringName()) + public final fun removeAnimationLibrary(name: String): Unit = removeAnimationLibrary(name.asCachedStringName()) /** * Moves the [AnimationLibrary] associated with the key [name] to the key [newname]. */ - public final fun renameAnimationLibrary(name: String, newname: String) = - renameAnimationLibrary(name.asCachedStringName(), newname.asCachedStringName()) + public final fun renameAnimationLibrary(name: String, newname: String): Unit = renameAnimationLibrary(name.asCachedStringName(), newname.asCachedStringName()) /** * Returns `true` if the [AnimationMixer] stores an [AnimationLibrary] with key [name]. */ - public final fun hasAnimationLibrary(name: String): Boolean = - hasAnimationLibrary(name.asCachedStringName()) + public final fun hasAnimationLibrary(name: String): Boolean = hasAnimationLibrary(name.asCachedStringName()) /** * Returns the first [AnimationLibrary] with key [name] or `null` if not found. * * To get the [AnimationMixer]'s global animation library, use `get_animation_library("")`. */ - public final fun getAnimationLibrary(name: String): AnimationLibrary? = - getAnimationLibrary(name.asCachedStringName()) + public final fun getAnimationLibrary(name: String): AnimationLibrary? = getAnimationLibrary(name.asCachedStringName()) /** * Returns `true` if the [AnimationMixer] stores an [Animation] with key [name]. @@ -790,27 +716,20 @@ public open class AnimationMixer internal constructor() : Node() { public final fun hasAnimation(name: String): Boolean = hasAnimation(name.asCachedStringName()) /** - * Returns the [Animation] with the key [name]. If the animation does not exist, `null` is - * returned and an error is logged. + * Returns the [Animation] with the key [name]. If the animation does not exist, `null` is returned and an error is logged. */ public final fun getAnimation(name: String): Animation? = getAnimation(name.asCachedStringName()) - public final fun setRootNode(path: String) = setRootNode(path.asCachedNodePath()) + public final fun setRootNode(path: String): Unit = setRootNode(path.asCachedNodePath()) - public final fun setRootMotionTrack(path: String) = setRootMotionTrack(path.asCachedNodePath()) + public final fun setRootMotionTrack(path: String): Unit = setRootMotionTrack(path.asCachedNodePath()) /** - * If the animation track specified by [name] has an option [Animation.UPDATE_CAPTURE], stores - * current values of the objects indicated by the track path as a cache. If there is already a - * captured cache, the old cache is discarded. + * If the animation track specified by [name] has an option [Animation.UPDATE_CAPTURE], stores current values of the objects indicated by the track path as a cache. If there is already a captured cache, the old cache is discarded. * - * After this it will interpolate with current animation blending result during the playback - * process for the time specified by [duration], working like a crossfade. + * After this it will interpolate with current animation blending result during the playback process for the time specified by [duration], working like a crossfade. * - * You can specify [transType] as the curve for the interpolation. For better results, it may be - * appropriate to specify [Tween.TRANS_LINEAR] for cases where the first key of the track begins with - * a non-zero value or where the key value does not change, and [Tween.TRANS_QUAD] for cases where - * the key value changes linearly. + * You can specify [transType] as the curve for the interpolation. For better results, it may be appropriate to specify [Tween.TRANS_LINEAR] for cases where the first key of the track begins with a non-zero value or where the key value does not change, and [Tween.TRANS_QUAD] for cases where the key value changes linearly. */ @JvmOverloads public final fun capture( @@ -818,14 +737,13 @@ public open class AnimationMixer internal constructor() : Node() { duration: Double, transType: Tween.TransitionType = Tween.TransitionType.LINEAR, easeType: Tween.EaseType = Tween.EaseType.IN, - ) = capture(name.asCachedStringName(), duration, transType, easeType) + ): Unit = capture(name.asCachedStringName(), duration, transType, easeType) public enum class AnimationCallbackModeProcess( id: Long, ) { /** - * Process animation during physics frames (see [Node.NOTIFICATION_INTERNAL_PHYSICS_PROCESS]). - * This is especially useful when animating physics bodies. + * Process animation during physics frames (see [Node.NOTIFICATION_INTERNAL_PHYSICS_PROCESS]). This is especially useful when animating physics bodies. */ PHYSICS(0), /** @@ -844,8 +762,7 @@ public open class AnimationMixer internal constructor() : Node() { } public companion object { - public fun from(`value`: Long): AnimationCallbackModeProcess = - entries.single { it.id == `value` } + public fun from(`value`: Long): AnimationCallbackModeProcess = entries.single { it.id == `value` } } } @@ -853,9 +770,7 @@ public open class AnimationMixer internal constructor() : Node() { id: Long, ) { /** - * Batch method calls during the animation process, then do the calls after events are - * processed. This avoids bugs involving deleting nodes or modifying the AnimationPlayer while - * playing. + * Batch method calls during the animation process, then do the calls after events are processed. This avoids bugs involving deleting nodes or modifying the AnimationPlayer while playing. */ DEFERRED(0), /** @@ -870,8 +785,7 @@ public open class AnimationMixer internal constructor() : Node() { } public companion object { - public fun from(`value`: Long): AnimationCallbackModeMethod = - entries.single { it.id == `value` } + public fun from(`value`: Long): AnimationCallbackModeMethod = entries.single { it.id == `value` } } } @@ -879,24 +793,17 @@ public open class AnimationMixer internal constructor() : Node() { id: Long, ) { /** - * An [Animation.UPDATE_DISCRETE] track value takes precedence when blending - * [Animation.UPDATE_CONTINUOUS] or [Animation.UPDATE_CAPTURE] track values and - * [Animation.UPDATE_DISCRETE] track values. + * An [Animation.UPDATE_DISCRETE] track value takes precedence when blending [Animation.UPDATE_CONTINUOUS] or [Animation.UPDATE_CAPTURE] track values and [Animation.UPDATE_DISCRETE] track values. */ DOMINANT(0), /** - * An [Animation.UPDATE_CONTINUOUS] or [Animation.UPDATE_CAPTURE] track value takes precedence - * when blending the [Animation.UPDATE_CONTINUOUS] or [Animation.UPDATE_CAPTURE] track values and - * the [Animation.UPDATE_DISCRETE] track values. This is the default behavior for - * [AnimationPlayer]. + * An [Animation.UPDATE_CONTINUOUS] or [Animation.UPDATE_CAPTURE] track value takes precedence when blending the [Animation.UPDATE_CONTINUOUS] or [Animation.UPDATE_CAPTURE] track values and the [Animation.UPDATE_DISCRETE] track values. This is the default behavior for [AnimationPlayer]. */ RECESSIVE(1), /** - * Always treat the [Animation.UPDATE_DISCRETE] track value as [Animation.UPDATE_CONTINUOUS] - * with [Animation.INTERPOLATION_NEAREST]. This is the default behavior for [AnimationTree]. + * Always treat the [Animation.UPDATE_DISCRETE] track value as [Animation.UPDATE_CONTINUOUS] with [Animation.INTERPOLATION_NEAREST]. This is the default behavior for [AnimationTree]. * - * If a value track has un-interpolatable type key values, it is internally converted to use - * [ANIMATION_CALLBACK_MODE_DISCRETE_RECESSIVE] with [Animation.UPDATE_DISCRETE]. + * If a value track has un-interpolatable type key values, it is internally converted to use [ANIMATION_CALLBACK_MODE_DISCRETE_RECESSIVE] with [Animation.UPDATE_DISCRETE]. * * Un-interpolatable type list: * @@ -916,16 +823,11 @@ public open class AnimationMixer internal constructor() : Node() { * * - [@GlobalScope.TYPE_PACKED_BYTE_ARRAY] * - * [@GlobalScope.TYPE_BOOL] and [@GlobalScope.TYPE_INT] are treated as [@GlobalScope.TYPE_FLOAT] - * during blending and rounded when the result is retrieved. + * [@GlobalScope.TYPE_BOOL] and [@GlobalScope.TYPE_INT] are treated as [@GlobalScope.TYPE_FLOAT] during blending and rounded when the result is retrieved. * - * It is same for arrays and vectors with them such as [@GlobalScope.TYPE_PACKED_INT32_ARRAY] or - * [@GlobalScope.TYPE_VECTOR2I], they are treated as [@GlobalScope.TYPE_PACKED_FLOAT32_ARRAY] or - * [@GlobalScope.TYPE_VECTOR2]. Also note that for arrays, the size is also interpolated. + * It is same for arrays and vectors with them such as [@GlobalScope.TYPE_PACKED_INT32_ARRAY] or [@GlobalScope.TYPE_VECTOR2I], they are treated as [@GlobalScope.TYPE_PACKED_FLOAT32_ARRAY] or [@GlobalScope.TYPE_VECTOR2]. Also note that for arrays, the size is also interpolated. * - * [@GlobalScope.TYPE_STRING] and [@GlobalScope.TYPE_STRING_NAME] are interpolated between - * character codes and lengths, but note that there is a difference in algorithm between - * interpolation between keys and interpolation by blending. + * [@GlobalScope.TYPE_STRING] and [@GlobalScope.TYPE_STRING_NAME] are interpolated between character codes and lengths, but note that there is a difference in algorithm between interpolation between keys and interpolation by blending. */ FORCE_CONTINUOUS(2), ; @@ -936,8 +838,7 @@ public open class AnimationMixer internal constructor() : Node() { } public companion object { - public fun from(`value`: Long): AnimationCallbackModeDiscrete = - entries.single { it.id == `value` } + public fun from(`value`: Long): AnimationCallbackModeDiscrete = entries.single { it.id == `value` } } } @@ -945,123 +846,123 @@ public open class AnimationMixer internal constructor() : Node() { public object MethodBindings { internal val addAnimationLibraryPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "add_animation_library", 618909818) + TypeManager.getMethodBindPtr("AnimationMixer", "add_animation_library", 618_909_818) internal val removeAnimationLibraryPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "remove_animation_library", 3304788590) + TypeManager.getMethodBindPtr("AnimationMixer", "remove_animation_library", 3_304_788_590) internal val renameAnimationLibraryPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "rename_animation_library", 3740211285) + TypeManager.getMethodBindPtr("AnimationMixer", "rename_animation_library", 3_740_211_285) internal val hasAnimationLibraryPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "has_animation_library", 2619796661) + TypeManager.getMethodBindPtr("AnimationMixer", "has_animation_library", 2_619_796_661) internal val getAnimationLibraryPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "get_animation_library", 147342321) + TypeManager.getMethodBindPtr("AnimationMixer", "get_animation_library", 147_342_321) internal val getAnimationLibraryListPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "get_animation_library_list", 3995934104) + TypeManager.getMethodBindPtr("AnimationMixer", "get_animation_library_list", 3_995_934_104) internal val hasAnimationPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "has_animation", 2619796661) + TypeManager.getMethodBindPtr("AnimationMixer", "has_animation", 2_619_796_661) internal val getAnimationPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "get_animation", 2933122410) + TypeManager.getMethodBindPtr("AnimationMixer", "get_animation", 2_933_122_410) internal val getAnimationListPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "get_animation_list", 1139954409) + TypeManager.getMethodBindPtr("AnimationMixer", "get_animation_list", 1_139_954_409) internal val setActivePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "set_active", 2586408642) + TypeManager.getMethodBindPtr("AnimationMixer", "set_active", 2_586_408_642) internal val isActivePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "is_active", 36873697) + TypeManager.getMethodBindPtr("AnimationMixer", "is_active", 36_873_697) internal val setDeterministicPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "set_deterministic", 2586408642) + TypeManager.getMethodBindPtr("AnimationMixer", "set_deterministic", 2_586_408_642) internal val isDeterministicPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "is_deterministic", 36873697) + TypeManager.getMethodBindPtr("AnimationMixer", "is_deterministic", 36_873_697) internal val setRootNodePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "set_root_node", 1348162250) + TypeManager.getMethodBindPtr("AnimationMixer", "set_root_node", 1_348_162_250) internal val getRootNodePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "get_root_node", 4075236667) + TypeManager.getMethodBindPtr("AnimationMixer", "get_root_node", 4_075_236_667) internal val setCallbackModeProcessPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "set_callback_mode_process", 2153733086) + TypeManager.getMethodBindPtr("AnimationMixer", "set_callback_mode_process", 2_153_733_086) internal val getCallbackModeProcessPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "get_callback_mode_process", 1394468472) + TypeManager.getMethodBindPtr("AnimationMixer", "get_callback_mode_process", 1_394_468_472) internal val setCallbackModeMethodPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "set_callback_mode_method", 742218271) + TypeManager.getMethodBindPtr("AnimationMixer", "set_callback_mode_method", 742_218_271) internal val getCallbackModeMethodPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "get_callback_mode_method", 489449656) + TypeManager.getMethodBindPtr("AnimationMixer", "get_callback_mode_method", 489_449_656) internal val setCallbackModeDiscretePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "set_callback_mode_discrete", 1998944670) + TypeManager.getMethodBindPtr("AnimationMixer", "set_callback_mode_discrete", 1_998_944_670) internal val getCallbackModeDiscretePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "get_callback_mode_discrete", 3493168860) + TypeManager.getMethodBindPtr("AnimationMixer", "get_callback_mode_discrete", 3_493_168_860) internal val setAudioMaxPolyphonyPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "set_audio_max_polyphony", 1286410249) + TypeManager.getMethodBindPtr("AnimationMixer", "set_audio_max_polyphony", 1_286_410_249) internal val getAudioMaxPolyphonyPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "get_audio_max_polyphony", 3905245786) + TypeManager.getMethodBindPtr("AnimationMixer", "get_audio_max_polyphony", 3_905_245_786) internal val setRootMotionTrackPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "set_root_motion_track", 1348162250) + TypeManager.getMethodBindPtr("AnimationMixer", "set_root_motion_track", 1_348_162_250) internal val getRootMotionTrackPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "get_root_motion_track", 4075236667) + TypeManager.getMethodBindPtr("AnimationMixer", "get_root_motion_track", 4_075_236_667) internal val setRootMotionLocalPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "set_root_motion_local", 2586408642) + TypeManager.getMethodBindPtr("AnimationMixer", "set_root_motion_local", 2_586_408_642) internal val isRootMotionLocalPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "is_root_motion_local", 36873697) + TypeManager.getMethodBindPtr("AnimationMixer", "is_root_motion_local", 36_873_697) internal val getRootMotionPositionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "get_root_motion_position", 3360562783) + TypeManager.getMethodBindPtr("AnimationMixer", "get_root_motion_position", 3_360_562_783) internal val getRootMotionRotationPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "get_root_motion_rotation", 1222331677) + TypeManager.getMethodBindPtr("AnimationMixer", "get_root_motion_rotation", 1_222_331_677) internal val getRootMotionScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "get_root_motion_scale", 3360562783) + TypeManager.getMethodBindPtr("AnimationMixer", "get_root_motion_scale", 3_360_562_783) internal val getRootMotionPositionAccumulatorPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "get_root_motion_position_accumulator", 3360562783) + TypeManager.getMethodBindPtr("AnimationMixer", "get_root_motion_position_accumulator", 3_360_562_783) internal val getRootMotionRotationAccumulatorPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "get_root_motion_rotation_accumulator", 1222331677) + TypeManager.getMethodBindPtr("AnimationMixer", "get_root_motion_rotation_accumulator", 1_222_331_677) internal val getRootMotionScaleAccumulatorPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "get_root_motion_scale_accumulator", 3360562783) + TypeManager.getMethodBindPtr("AnimationMixer", "get_root_motion_scale_accumulator", 3_360_562_783) internal val clearCachesPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "clear_caches", 3218959716) + TypeManager.getMethodBindPtr("AnimationMixer", "clear_caches", 3_218_959_716) internal val advancePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "advance", 373806689) + TypeManager.getMethodBindPtr("AnimationMixer", "advance", 373_806_689) internal val capturePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "capture", 1333632127) + TypeManager.getMethodBindPtr("AnimationMixer", "capture", 1_333_632_127) internal val setResetOnSaveEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "set_reset_on_save_enabled", 2586408642) + TypeManager.getMethodBindPtr("AnimationMixer", "set_reset_on_save_enabled", 2_586_408_642) internal val isResetOnSaveEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "is_reset_on_save_enabled", 36873697) + TypeManager.getMethodBindPtr("AnimationMixer", "is_reset_on_save_enabled", 36_873_697) internal val findAnimationPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "find_animation", 1559484580) + TypeManager.getMethodBindPtr("AnimationMixer", "find_animation", 1_559_484_580) internal val findAnimationLibraryPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationMixer", "find_animation_library", 1559484580) + TypeManager.getMethodBindPtr("AnimationMixer", "find_animation_library", 1_559_484_580) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNode.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNode.kt index 6347089175..349fbd316c 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNode.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNode.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -42,17 +39,13 @@ import kotlin.jvm.JvmName import kotlin.jvm.JvmOverloads /** - * Base resource for [AnimationTree] nodes. In general, it's not used directly, but you can create - * custom ones with custom blending formulas. + * Base resource for [AnimationTree] nodes. In general, it's not used directly, but you can create custom ones with custom blending formulas. * - * Inherit this when creating animation nodes mainly for use in [AnimationNodeBlendTree], otherwise - * [AnimationRootNode] should be used instead. + * Inherit this when creating animation nodes mainly for use in [AnimationNodeBlendTree], otherwise [AnimationRootNode] should be used instead. * - * You can access the time information as read-only parameter which is processed and stored in the - * previous frame for all nodes except [AnimationNodeOutput]. + * You can access the time information as read-only parameter which is processed and stored in the previous frame for all nodes except [AnimationNodeOutput]. * - * **Note:** If multiple inputs exist in the [AnimationNode], which time information takes - * precedence depends on the type of [AnimationNode]. + * **Note:** If multiple inputs exist in the [AnimationNode], which time information takes precedence depends on the type of [AnimationNode]. * * ``` * var current_length = $AnimationTree[parameters/AnimationNodeName/current_length] @@ -63,26 +56,17 @@ import kotlin.jvm.JvmOverloads @GodotBaseType public open class AnimationNode : Resource() { /** - * Emitted by nodes that inherit from this class and that have an internal tree when one of their - * animation nodes changes. The animation nodes that emit this signal are - * [AnimationNodeBlendSpace1D], [AnimationNodeBlendSpace2D], [AnimationNodeStateMachine], - * [AnimationNodeBlendTree] and [AnimationNodeTransition]. + * Emitted by nodes that inherit from this class and that have an internal tree when one of their animation nodes changes. The animation nodes that emit this signal are [AnimationNodeBlendSpace1D], [AnimationNodeBlendSpace2D], [AnimationNodeStateMachine], [AnimationNodeBlendTree] and [AnimationNodeTransition]. */ public val treeChanged: Signal0 by Signal0 /** - * Emitted by nodes that inherit from this class and that have an internal tree when one of their - * animation node names changes. The animation nodes that emit this signal are - * [AnimationNodeBlendSpace1D], [AnimationNodeBlendSpace2D], [AnimationNodeStateMachine], and - * [AnimationNodeBlendTree]. + * Emitted by nodes that inherit from this class and that have an internal tree when one of their animation node names changes. The animation nodes that emit this signal are [AnimationNodeBlendSpace1D], [AnimationNodeBlendSpace2D], [AnimationNodeStateMachine], and [AnimationNodeBlendTree]. */ public val animationNodeRenamed: Signal3 by Signal3 /** - * Emitted by nodes that inherit from this class and that have an internal tree when one of their - * animation nodes removes. The animation nodes that emit this signal are - * [AnimationNodeBlendSpace1D], [AnimationNodeBlendSpace2D], [AnimationNodeStateMachine], and - * [AnimationNodeBlendTree]. + * Emitted by nodes that inherit from this class and that have an internal tree when one of their animation nodes removes. The animation nodes that emit this signal are [AnimationNodeBlendSpace1D], [AnimationNodeBlendSpace2D], [AnimationNodeStateMachine], and [AnimationNodeBlendTree]. */ public val animationNodeRemoved: Signal2 by Signal2 @@ -97,61 +81,49 @@ public open class AnimationNode : Resource() { setFilterEnabled(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(15, scriptIndex) } /** - * When inheriting from [AnimationRootNode], implement this virtual method to return all child - * animation nodes in order as a `name: node` dictionary. + * When inheriting from [AnimationRootNode], implement this virtual method to return all child animation nodes in order as a `name: node` dictionary. */ public open fun _getChildNodes(): Dictionary { throw NotImplementedError("AnimationNode::_getChildNodes is not implemented.") } /** - * When inheriting from [AnimationRootNode], implement this virtual method to return a list of the - * properties on this animation node. Parameters are custom local memory used for your animation - * nodes, given a resource can be reused in multiple trees. Format is similar to - * [Object.getPropertyList]. + * When inheriting from [AnimationRootNode], implement this virtual method to return a list of the properties on this animation node. Parameters are custom local memory used for your animation nodes, given a resource can be reused in multiple trees. Format is similar to [Object.getPropertyList]. */ public open fun _getParameterList(): VariantArray { throw NotImplementedError("AnimationNode::_getParameterList is not implemented.") } /** - * When inheriting from [AnimationRootNode], implement this virtual method to return a child - * animation node by its [name]. + * When inheriting from [AnimationRootNode], implement this virtual method to return a child animation node by its [name]. */ public open fun _getChildByName(name: StringName): AnimationNode? { throw NotImplementedError("AnimationNode::_getChildByName is not implemented.") } /** - * When inheriting from [AnimationRootNode], implement this virtual method to return the default - * value of a [parameter]. Parameters are custom local memory used for your animation nodes, given a - * resource can be reused in multiple trees. + * When inheriting from [AnimationRootNode], implement this virtual method to return the default value of a [parameter]. Parameters are custom local memory used for your animation nodes, given a resource can be reused in multiple trees. */ public open fun _getParameterDefaultValue(parameter: StringName): Any? { throw NotImplementedError("AnimationNode::_getParameterDefaultValue is not implemented.") } /** - * When inheriting from [AnimationRootNode], implement this virtual method to return whether the - * [parameter] is read-only. Parameters are custom local memory used for your animation nodes, given - * a resource can be reused in multiple trees. + * When inheriting from [AnimationRootNode], implement this virtual method to return whether the [parameter] is read-only. Parameters are custom local memory used for your animation nodes, given a resource can be reused in multiple trees. */ public open fun _isParameterReadOnly(parameter: StringName): Boolean { throw NotImplementedError("AnimationNode::_isParameterReadOnly is not implemented.") } /** - * When inheriting from [AnimationRootNode], implement this virtual method to run some code when - * this animation node is processed. The [time] parameter is a relative delta, unless [seek] is - * `true`, in which case it is absolute. + * When inheriting from [AnimationRootNode], implement this virtual method to run some code when this animation node is processed. The [time] parameter is a relative delta, unless [seek] is `true`, in which case it is absolute. * - * Here, call the [blendInput], [blendNode] or [blendAnimation] functions. You can also use - * [getParameter] and [setParameter] to modify local memory. + * Here, call the [blendInput], [blendNode] or [blendAnimation] functions. You can also use [getParameter] and [setParameter] to modify local memory. * * This function should return the delta. */ @@ -165,24 +137,21 @@ public open class AnimationNode : Resource() { } /** - * When inheriting from [AnimationRootNode], implement this virtual method to override the text - * caption for this animation node. + * When inheriting from [AnimationRootNode], implement this virtual method to override the text caption for this animation node. */ public open fun _getCaption(): String { throw NotImplementedError("AnimationNode::_getCaption is not implemented.") } /** - * When inheriting from [AnimationRootNode], implement this virtual method to return whether the - * blend tree editor should display filter editing on this animation node. + * When inheriting from [AnimationRootNode], implement this virtual method to return whether the blend tree editor should display filter editing on this animation node. */ public open fun _hasFilter(): Boolean { throw NotImplementedError("AnimationNode::_hasFilter is not implemented.") } /** - * Adds an input to the animation node. This is only useful for animation nodes created for use in - * an [AnimationNodeBlendTree]. If the addition fails, returns `false`. + * Adds an input to the animation node. This is only useful for animation nodes created for use in an [AnimationNodeBlendTree]. If the addition fails, returns `false`. */ public final fun addInput(name: String): Boolean { TransferContext.writeArguments(STRING to name) @@ -193,7 +162,7 @@ public open class AnimationNode : Resource() { /** * Removes an input, call this only when inactive. */ - public final fun removeInput(index: Int): Unit { + public final fun removeInput(index: Int) { TransferContext.writeArguments(LONG to index.toLong()) TransferContext.callMethod(ptr, MethodBindings.removeInputPtr, NIL) } @@ -217,8 +186,7 @@ public open class AnimationNode : Resource() { } /** - * Amount of inputs in this animation node, only useful for animation nodes that go into - * [AnimationNodeBlendTree]. + * Amount of inputs in this animation node, only useful for animation nodes that go into [AnimationNodeBlendTree]. */ public final fun getInputCount(): Int { TransferContext.writeArguments() @@ -238,7 +206,7 @@ public open class AnimationNode : Resource() { /** * Adds or removes a path for the filter. */ - public final fun setFilterPath(path: NodePath, enable: Boolean): Unit { + public final fun setFilterPath(path: NodePath, enable: Boolean) { TransferContext.writeArguments(NODE_PATH to path, BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setFilterPathPtr, NIL) } @@ -252,7 +220,7 @@ public open class AnimationNode : Resource() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setFilterEnabled(enable: Boolean): Unit { + public final fun setFilterEnabled(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setFilterEnabledPtr, NIL) } @@ -266,8 +234,7 @@ public open class AnimationNode : Resource() { /** * Returns the object id of the [AnimationTree] that owns this node. * - * **Note:** This method should only be called from within the - * [AnimationNodeExtension.ProcessAnimationNode] method, and will return an invalid id otherwise. + * **Note:** This method should only be called from within the [AnimationNodeExtension.ProcessAnimationNode] method, and will return an invalid id otherwise. */ public final fun getProcessingAnimationTreeInstanceId(): Long { TransferContext.writeArguments() @@ -285,11 +252,9 @@ public open class AnimationNode : Resource() { } /** - * Blend an animation by [blend] amount (name must be valid in the linked [AnimationPlayer]). A - * [time] and [delta] may be passed, as well as whether [seeked] happened. + * Blend an animation by [blend] amount (name must be valid in the linked [AnimationPlayer]). A [time] and [delta] may be passed, as well as whether [seeked] happened. * - * A [loopedFlag] is used by internal processing immediately after the loop. See also - * [Animation.LoopedFlag]. + * A [loopedFlag] is used by internal processing immediately after the loop. See also [Animation.LoopedFlag]. */ @JvmOverloads public final fun blendAnimation( @@ -300,15 +265,13 @@ public open class AnimationNode : Resource() { isExternalSeeking: Boolean, blend: Float, loopedFlag: Animation.LoopedFlag = Animation.LoopedFlag.NONE, - ): Unit { + ) { TransferContext.writeArguments(STRING_NAME to animation, DOUBLE to time, DOUBLE to delta, BOOL to seeked, BOOL to isExternalSeeking, DOUBLE to blend.toDouble(), LONG to loopedFlag.id) TransferContext.callMethod(ptr, MethodBindings.blendAnimationPtr, NIL) } /** - * Blend another animation node (in case this animation node contains child animation nodes). This - * function is only useful if you inherit from [AnimationRootNode] instead, otherwise editors will - * not display your animation node for addition. + * Blend another animation node (in case this animation node contains child animation nodes). This function is only useful if you inherit from [AnimationRootNode] instead, otherwise editors will not display your animation node for addition. */ @JvmOverloads public final fun blendNode( @@ -328,10 +291,7 @@ public open class AnimationNode : Resource() { } /** - * Blend an input. This is only useful for animation nodes created for an - * [AnimationNodeBlendTree]. The [time] parameter is a relative delta, unless [seek] is `true`, in - * which case it is absolute. A filter mode may be optionally passed (see [FilterAction] for - * options). + * Blend an input. This is only useful for animation nodes created for an [AnimationNodeBlendTree]. The [time] parameter is a relative delta, unless [seek] is `true`, in which case it is absolute. A filter mode may be optionally passed (see [FilterAction] for options). */ @JvmOverloads public final fun blendInput( @@ -350,17 +310,15 @@ public open class AnimationNode : Resource() { } /** - * Sets a custom parameter. These are used as local memory, because resources can be reused across - * the tree or scenes. + * Sets a custom parameter. These are used as local memory, because resources can be reused across the tree or scenes. */ - public final fun setParameter(name: StringName, `value`: Any?): Unit { + public final fun setParameter(name: StringName, `value`: Any?) { TransferContext.writeArguments(STRING_NAME to name, ANY to value) TransferContext.callMethod(ptr, MethodBindings.setParameterPtr, NIL) } /** - * Gets the value of a parameter. Parameters are custom local memory used for your animation - * nodes, given a resource can be reused in multiple trees. + * Gets the value of a parameter. Parameters are custom local memory used for your animation nodes, given a resource can be reused in multiple trees. */ public final fun getParameter(name: StringName): Any? { TransferContext.writeArguments(STRING_NAME to name) @@ -371,8 +329,7 @@ public open class AnimationNode : Resource() { /** * Adds or removes a path for the filter. */ - public final fun setFilterPath(path: String, enable: Boolean) = - setFilterPath(path.asCachedNodePath(), enable) + public final fun setFilterPath(path: String, enable: Boolean): Unit = setFilterPath(path.asCachedNodePath(), enable) /** * Returns `true` if the given path is filtered. @@ -380,11 +337,9 @@ public open class AnimationNode : Resource() { public final fun isPathFiltered(path: String): Boolean = isPathFiltered(path.asCachedNodePath()) /** - * Blend an animation by [blend] amount (name must be valid in the linked [AnimationPlayer]). A - * [time] and [delta] may be passed, as well as whether [seeked] happened. + * Blend an animation by [blend] amount (name must be valid in the linked [AnimationPlayer]). A [time] and [delta] may be passed, as well as whether [seeked] happened. * - * A [loopedFlag] is used by internal processing immediately after the loop. See also - * [Animation.LoopedFlag]. + * A [loopedFlag] is used by internal processing immediately after the loop. See also [Animation.LoopedFlag]. */ @JvmOverloads public final fun blendAnimation( @@ -395,13 +350,10 @@ public open class AnimationNode : Resource() { isExternalSeeking: Boolean, blend: Float, loopedFlag: Animation.LoopedFlag = Animation.LoopedFlag.NONE, - ) = - blendAnimation(animation.asCachedStringName(), time, delta, seeked, isExternalSeeking, blend, loopedFlag) + ): Unit = blendAnimation(animation.asCachedStringName(), time, delta, seeked, isExternalSeeking, blend, loopedFlag) /** - * Blend another animation node (in case this animation node contains child animation nodes). This - * function is only useful if you inherit from [AnimationRootNode] instead, otherwise editors will - * not display your animation node for addition. + * Blend another animation node (in case this animation node contains child animation nodes). This function is only useful if you inherit from [AnimationRootNode] instead, otherwise editors will not display your animation node for addition. */ @JvmOverloads public final fun blendNode( @@ -414,19 +366,15 @@ public open class AnimationNode : Resource() { filter: FilterAction = AnimationNode.FilterAction.IGNORE, sync: Boolean = true, testOnly: Boolean = false, - ): Double = - blendNode(name.asCachedStringName(), node, time, seek, isExternalSeeking, blend, filter, sync, testOnly) + ): Double = blendNode(name.asCachedStringName(), node, time, seek, isExternalSeeking, blend, filter, sync, testOnly) /** - * Sets a custom parameter. These are used as local memory, because resources can be reused across - * the tree or scenes. + * Sets a custom parameter. These are used as local memory, because resources can be reused across the tree or scenes. */ - public final fun setParameter(name: String, `value`: Any?) = - setParameter(name.asCachedStringName(), value) + public final fun setParameter(name: String, `value`: Any?): Unit = setParameter(name.asCachedStringName(), value) /** - * Gets the value of a parameter. Parameters are custom local memory used for your animation - * nodes, given a resource can be reused in multiple trees. + * Gets the value of a parameter. Parameters are custom local memory used for your animation nodes, given a resource can be reused in multiple trees. */ public final fun getParameter(name: String): Any? = getParameter(name.asCachedStringName()) @@ -465,54 +413,54 @@ public open class AnimationNode : Resource() { public object MethodBindings { internal val addInputPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNode", "add_input", 2323990056) + TypeManager.getMethodBindPtr("AnimationNode", "add_input", 2_323_990_056) internal val removeInputPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNode", "remove_input", 1286410249) + TypeManager.getMethodBindPtr("AnimationNode", "remove_input", 1_286_410_249) internal val setInputNamePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNode", "set_input_name", 215573526) + TypeManager.getMethodBindPtr("AnimationNode", "set_input_name", 215_573_526) internal val getInputNamePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNode", "get_input_name", 844755477) + TypeManager.getMethodBindPtr("AnimationNode", "get_input_name", 844_755_477) internal val getInputCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNode", "get_input_count", 3905245786) + TypeManager.getMethodBindPtr("AnimationNode", "get_input_count", 3_905_245_786) internal val findInputPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNode", "find_input", 1321353865) + TypeManager.getMethodBindPtr("AnimationNode", "find_input", 1_321_353_865) internal val setFilterPathPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNode", "set_filter_path", 3868023870) + TypeManager.getMethodBindPtr("AnimationNode", "set_filter_path", 3_868_023_870) internal val isPathFilteredPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNode", "is_path_filtered", 861721659) + TypeManager.getMethodBindPtr("AnimationNode", "is_path_filtered", 861_721_659) internal val setFilterEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNode", "set_filter_enabled", 2586408642) + TypeManager.getMethodBindPtr("AnimationNode", "set_filter_enabled", 2_586_408_642) internal val isFilterEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNode", "is_filter_enabled", 36873697) + TypeManager.getMethodBindPtr("AnimationNode", "is_filter_enabled", 36_873_697) internal val getProcessingAnimationTreeInstanceIdPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNode", "get_processing_animation_tree_instance_id", 3905245786) + TypeManager.getMethodBindPtr("AnimationNode", "get_processing_animation_tree_instance_id", 3_905_245_786) internal val isProcessTestingPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNode", "is_process_testing", 36873697) + TypeManager.getMethodBindPtr("AnimationNode", "is_process_testing", 36_873_697) internal val blendAnimationPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNode", "blend_animation", 1630801826) + TypeManager.getMethodBindPtr("AnimationNode", "blend_animation", 1_630_801_826) internal val blendNodePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNode", "blend_node", 1746075988) + TypeManager.getMethodBindPtr("AnimationNode", "blend_node", 1_746_075_988) internal val blendInputPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNode", "blend_input", 1361527350) + TypeManager.getMethodBindPtr("AnimationNode", "blend_input", 1_361_527_350) internal val setParameterPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNode", "set_parameter", 3776071444) + TypeManager.getMethodBindPtr("AnimationNode", "set_parameter", 3_776_071_444) internal val getParameterPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNode", "get_parameter", 2760726917) + TypeManager.getMethodBindPtr("AnimationNode", "get_parameter", 2_760_726_917) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeAdd2.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeAdd2.kt index 8b53716b70..f9178b7087 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeAdd2.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeAdd2.kt @@ -1,29 +1,22 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api import godot.`annotation`.GodotBaseType import kotlin.Int import kotlin.Suppress -import kotlin.Unit /** - * A resource to add to an [AnimationNodeBlendTree]. Blends two animations additively based on the - * amount value. + * A resource to add to an [AnimationNodeBlendTree]. Blends two animations additively based on the amount value. * - * If the amount is greater than `1.0`, the animation connected to "in" port is blended with the - * amplified animation connected to "add" port. + * If the amount is greater than `1.0`, the animation connected to "in" port is blended with the amplified animation connected to "add" port. * - * If the amount is less than `0.0`, the animation connected to "in" port is blended with the - * inverted animation connected to "add" port. + * If the amount is less than `0.0`, the animation connected to "in" port is blended with the inverted animation connected to "add" port. */ @GodotBaseType public open class AnimationNodeAdd2 : AnimationNodeSync() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(16, scriptIndex) } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeAdd3.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeAdd3.kt index 299b6cec40..fc88204ffd 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeAdd3.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeAdd3.kt @@ -1,19 +1,14 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api import godot.`annotation`.GodotBaseType import kotlin.Int import kotlin.Suppress -import kotlin.Unit /** - * A resource to add to an [AnimationNodeBlendTree]. Blends two animations out of three additively - * out of three based on the amount value. + * A resource to add to an [AnimationNodeBlendTree]. Blends two animations out of three additively out of three based on the amount value. * * This animation node has three inputs: * @@ -23,12 +18,11 @@ import kotlin.Unit * * - A "+add" animation to blend with when the blend amount is positive * - * If the absolute value of the amount is greater than `1.0`, the animation connected to "in" port - * is blended with the amplified animation connected to "-add"/"+add" port. + * If the absolute value of the amount is greater than `1.0`, the animation connected to "in" port is blended with the amplified animation connected to "-add"/"+add" port. */ @GodotBaseType public open class AnimationNodeAdd3 : AnimationNodeSync() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(17, scriptIndex) } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeAnimation.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeAnimation.kt index 1eea452bdf..709e2b6126 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeAnimation.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeAnimation.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -27,14 +24,12 @@ import kotlin.Unit import kotlin.jvm.JvmName /** - * A resource to add to an [AnimationNodeBlendTree]. Only has one output port using the [animation] - * property. Used as an input for [AnimationNode]s that blend animations together. + * A resource to add to an [AnimationNodeBlendTree]. Only has one output port using the [animation] property. Used as an input for [AnimationNode]s that blend animations together. */ @GodotBaseType public open class AnimationNodeAnimation : AnimationRootNode() { /** - * Animation to use as an output. It is one of the animations provided by - * [AnimationTree.animPlayer]. + * Animation to use as an output. It is one of the animations provided by [AnimationTree.animPlayer]. */ public final inline var animation: StringName @JvmName("animationProperty") @@ -56,8 +51,7 @@ public open class AnimationNodeAnimation : AnimationRootNode() { } /** - * If `true`, on receiving a request to play an animation from the start, the first frame is not - * drawn, but only processed, and playback starts from the next frame. + * If `true`, on receiving a request to play an animation from the start, the first frame is not drawn, but only processed, and playback starts from the next frame. * * See also the notes of [AnimationPlayer.play]. */ @@ -70,8 +64,7 @@ public open class AnimationNodeAnimation : AnimationRootNode() { } /** - * If `true`, [AnimationNode] provides an animation based on the [Animation] resource with some - * parameters adjusted. + * If `true`, [AnimationNode] provides an animation based on the [Animation] resource with some parameters adjusted. */ public final inline var useCustomTimeline: Boolean @JvmName("useCustomTimelineProperty") @@ -97,8 +90,7 @@ public open class AnimationNodeAnimation : AnimationRootNode() { * * This is useful for matching the periods of walking and running animations. * - * If `false`, the original animation length is respected. If you set the loop to [loopMode], the - * animation will loop in [timelineLength]. + * If `false`, the original animation length is respected. If you set the loop to [loopMode], the animation will loop in [timelineLength]. */ public final inline var stretchTimeScale: Boolean @JvmName("stretchTimeScaleProperty") @@ -122,12 +114,9 @@ public open class AnimationNodeAnimation : AnimationRootNode() { } /** - * If [useCustomTimeline] is `true`, override the loop settings of the original [Animation] - * resource with the value. + * If [useCustomTimeline] is `true`, override the loop settings of the original [Animation] resource with the value. * - * **Note:** If the [Animation.loopMode] isn't set to looping, the - * [Animation.trackSetInterpolationLoopWrap] option will not be respected. If you cannot get the - * expected behavior, consider duplicating the [Animation] resource and changing the loop settings. + * **Note:** If the [Animation.loopMode] isn't set to looping, the [Animation.trackSetInterpolationLoopWrap] option will not be respected. If you cannot get the expected behavior, consider duplicating the [Animation] resource and changing the loop settings. */ public final inline var loopMode: Animation.LoopMode @JvmName("loopModeProperty") @@ -137,11 +126,11 @@ public open class AnimationNodeAnimation : AnimationRootNode() { setLoopMode(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(18, scriptIndex) } - public final fun setAnimation(name: StringName): Unit { + public final fun setAnimation(name: StringName) { TransferContext.writeArguments(STRING_NAME to name) TransferContext.callMethod(ptr, MethodBindings.setAnimationPtr, NIL) } @@ -152,7 +141,7 @@ public open class AnimationNodeAnimation : AnimationRootNode() { return (TransferContext.readReturnValue(STRING_NAME) as StringName) } - public final fun setPlayMode(mode: PlayMode): Unit { + public final fun setPlayMode(mode: PlayMode) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setPlayModePtr, NIL) } @@ -163,7 +152,7 @@ public open class AnimationNodeAnimation : AnimationRootNode() { return PlayMode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setAdvanceOnStart(advanceOnStart: Boolean): Unit { + public final fun setAdvanceOnStart(advanceOnStart: Boolean) { TransferContext.writeArguments(BOOL to advanceOnStart) TransferContext.callMethod(ptr, MethodBindings.setAdvanceOnStartPtr, NIL) } @@ -174,7 +163,7 @@ public open class AnimationNodeAnimation : AnimationRootNode() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setUseCustomTimeline(useCustomTimeline: Boolean): Unit { + public final fun setUseCustomTimeline(useCustomTimeline: Boolean) { TransferContext.writeArguments(BOOL to useCustomTimeline) TransferContext.callMethod(ptr, MethodBindings.setUseCustomTimelinePtr, NIL) } @@ -185,7 +174,7 @@ public open class AnimationNodeAnimation : AnimationRootNode() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setTimelineLength(timelineLength: Double): Unit { + public final fun setTimelineLength(timelineLength: Double) { TransferContext.writeArguments(DOUBLE to timelineLength) TransferContext.callMethod(ptr, MethodBindings.setTimelineLengthPtr, NIL) } @@ -196,7 +185,7 @@ public open class AnimationNodeAnimation : AnimationRootNode() { return (TransferContext.readReturnValue(DOUBLE) as Double) } - public final fun setStretchTimeScale(stretchTimeScale: Boolean): Unit { + public final fun setStretchTimeScale(stretchTimeScale: Boolean) { TransferContext.writeArguments(BOOL to stretchTimeScale) TransferContext.callMethod(ptr, MethodBindings.setStretchTimeScalePtr, NIL) } @@ -207,7 +196,7 @@ public open class AnimationNodeAnimation : AnimationRootNode() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setStartOffset(startOffset: Double): Unit { + public final fun setStartOffset(startOffset: Double) { TransferContext.writeArguments(DOUBLE to startOffset) TransferContext.callMethod(ptr, MethodBindings.setStartOffsetPtr, NIL) } @@ -218,7 +207,7 @@ public open class AnimationNodeAnimation : AnimationRootNode() { return (TransferContext.readReturnValue(DOUBLE) as Double) } - public final fun setLoopMode(loopMode: Animation.LoopMode): Unit { + public final fun setLoopMode(loopMode: Animation.LoopMode) { TransferContext.writeArguments(LONG to loopMode.id) TransferContext.callMethod(ptr, MethodBindings.setLoopModePtr, NIL) } @@ -229,7 +218,7 @@ public open class AnimationNodeAnimation : AnimationRootNode() { return Animation.LoopMode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setAnimation(name: String) = setAnimation(name.asCachedStringName()) + public final fun setAnimation(name: String): Unit = setAnimation(name.asCachedStringName()) public enum class PlayMode( id: Long, @@ -258,51 +247,51 @@ public open class AnimationNodeAnimation : AnimationRootNode() { public object MethodBindings { internal val setAnimationPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeAnimation", "set_animation", 3304788590) + TypeManager.getMethodBindPtr("AnimationNodeAnimation", "set_animation", 3_304_788_590) internal val getAnimationPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeAnimation", "get_animation", 2002593661) + TypeManager.getMethodBindPtr("AnimationNodeAnimation", "get_animation", 2_002_593_661) internal val setPlayModePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeAnimation", "set_play_mode", 3347718873) + TypeManager.getMethodBindPtr("AnimationNodeAnimation", "set_play_mode", 3_347_718_873) internal val getPlayModePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeAnimation", "get_play_mode", 2061244637) + TypeManager.getMethodBindPtr("AnimationNodeAnimation", "get_play_mode", 2_061_244_637) internal val setAdvanceOnStartPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeAnimation", "set_advance_on_start", 2586408642) + TypeManager.getMethodBindPtr("AnimationNodeAnimation", "set_advance_on_start", 2_586_408_642) internal val isAdvanceOnStartPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeAnimation", "is_advance_on_start", 36873697) + TypeManager.getMethodBindPtr("AnimationNodeAnimation", "is_advance_on_start", 36_873_697) internal val setUseCustomTimelinePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeAnimation", "set_use_custom_timeline", 2586408642) + TypeManager.getMethodBindPtr("AnimationNodeAnimation", "set_use_custom_timeline", 2_586_408_642) internal val isUsingCustomTimelinePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeAnimation", "is_using_custom_timeline", 36873697) + TypeManager.getMethodBindPtr("AnimationNodeAnimation", "is_using_custom_timeline", 36_873_697) internal val setTimelineLengthPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeAnimation", "set_timeline_length", 373806689) + TypeManager.getMethodBindPtr("AnimationNodeAnimation", "set_timeline_length", 373_806_689) internal val getTimelineLengthPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeAnimation", "get_timeline_length", 1740695150) + TypeManager.getMethodBindPtr("AnimationNodeAnimation", "get_timeline_length", 1_740_695_150) internal val setStretchTimeScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeAnimation", "set_stretch_time_scale", 2586408642) + TypeManager.getMethodBindPtr("AnimationNodeAnimation", "set_stretch_time_scale", 2_586_408_642) internal val isStretchingTimeScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeAnimation", "is_stretching_time_scale", 36873697) + TypeManager.getMethodBindPtr("AnimationNodeAnimation", "is_stretching_time_scale", 36_873_697) internal val setStartOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeAnimation", "set_start_offset", 373806689) + TypeManager.getMethodBindPtr("AnimationNodeAnimation", "set_start_offset", 373_806_689) internal val getStartOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeAnimation", "get_start_offset", 1740695150) + TypeManager.getMethodBindPtr("AnimationNodeAnimation", "get_start_offset", 1_740_695_150) internal val setLoopModePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeAnimation", "set_loop_mode", 3155355575) + TypeManager.getMethodBindPtr("AnimationNodeAnimation", "set_loop_mode", 3_155_355_575) internal val getLoopModePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeAnimation", "get_loop_mode", 1988889481) + TypeManager.getMethodBindPtr("AnimationNodeAnimation", "get_loop_mode", 1_988_889_481) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeBlend2.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeBlend2.kt index 5804428a1d..979cf0c8e6 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeBlend2.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeBlend2.kt @@ -1,26 +1,20 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api import godot.`annotation`.GodotBaseType import kotlin.Int import kotlin.Suppress -import kotlin.Unit /** - * A resource to add to an [AnimationNodeBlendTree]. Blends two animations linearly based on the - * amount value. + * A resource to add to an [AnimationNodeBlendTree]. Blends two animations linearly based on the amount value. * - * In general, the blend value should be in the `[0.0, 1.0]` range. Values outside of this range can - * blend amplified or inverted animations, however, [AnimationNodeAdd2] works better for this purpose. + * In general, the blend value should be in the `[0.0, 1.0]` range. Values outside of this range can blend amplified or inverted animations, however, [AnimationNodeAdd2] works better for this purpose. */ @GodotBaseType public open class AnimationNodeBlend2 : AnimationNodeSync() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(19, scriptIndex) } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeBlend3.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeBlend3.kt index 0618958a50..4cb0f6bd3a 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeBlend3.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeBlend3.kt @@ -1,19 +1,14 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api import godot.`annotation`.GodotBaseType import kotlin.Int import kotlin.Suppress -import kotlin.Unit /** - * A resource to add to an [AnimationNodeBlendTree]. Blends two animations out of three linearly out - * of three based on the amount value. + * A resource to add to an [AnimationNodeBlendTree]. Blends two animations out of three linearly out of three based on the amount value. * * This animation node has three inputs: * @@ -23,12 +18,11 @@ import kotlin.Unit * * - A "+blend" animation to blend with when the blend amount is positive value * - * In general, the blend value should be in the `[-1.0, 1.0]` range. Values outside of this range - * can blend amplified animations, however, [AnimationNodeAdd3] works better for this purpose. + * In general, the blend value should be in the `[-1.0, 1.0]` range. Values outside of this range can blend amplified animations, however, [AnimationNodeAdd3] works better for this purpose. */ @GodotBaseType public open class AnimationNodeBlend3 : AnimationNodeSync() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(20, scriptIndex) } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeBlendSpace1D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeBlendSpace1D.kt index d1f124f1a3..aaa18f720b 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeBlendSpace1D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeBlendSpace1D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -23,16 +20,13 @@ import kotlin.Int import kotlin.Long import kotlin.String import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName import kotlin.jvm.JvmOverloads /** * A resource used by [AnimationNodeBlendTree]. * - * [AnimationNodeBlendSpace1D] represents a virtual axis on which any type of [AnimationRootNode]s - * can be added using [addBlendPoint]. Outputs the linear blend of the two [AnimationRootNode]s - * adjacent to the current value. + * [AnimationNodeBlendSpace1D] represents a virtual axis on which any type of [AnimationRootNode]s can be added using [addBlendPoint]. Outputs the linear blend of the two [AnimationRootNode]s adjacent to the current value. * * You can set the extents of the axis with [minSpace] and [maxSpace]. */ @@ -106,21 +100,19 @@ public open class AnimationNodeBlendSpace1D : AnimationRootNode() { setUseSync(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(21, scriptIndex) } /** - * Adds a new point that represents a [node] on the virtual axis at a given position set by [pos]. - * You can insert it at a specific index using the [atIndex] argument. If you use the default value - * for [atIndex], the point is inserted at the end of the blend points array. + * Adds a new point that represents a [node] on the virtual axis at a given position set by [pos]. You can insert it at a specific index using the [atIndex] argument. If you use the default value for [atIndex], the point is inserted at the end of the blend points array. */ @JvmOverloads public final fun addBlendPoint( node: AnimationRootNode?, pos: Float, atIndex: Int = -1, - ): Unit { + ) { TransferContext.writeArguments(OBJECT to node, DOUBLE to pos.toDouble(), LONG to atIndex.toLong()) TransferContext.callMethod(ptr, MethodBindings.addBlendPointPtr, NIL) } @@ -128,7 +120,7 @@ public open class AnimationNodeBlendSpace1D : AnimationRootNode() { /** * Updates the position of the point at index [point] on the blend axis. */ - public final fun setBlendPointPosition(point: Int, pos: Float): Unit { + public final fun setBlendPointPosition(point: Int, pos: Float) { TransferContext.writeArguments(LONG to point.toLong(), DOUBLE to pos.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setBlendPointPositionPtr, NIL) } @@ -145,7 +137,7 @@ public open class AnimationNodeBlendSpace1D : AnimationRootNode() { /** * Changes the [AnimationNode] referenced by the point at index [point]. */ - public final fun setBlendPointNode(point: Int, node: AnimationRootNode?): Unit { + public final fun setBlendPointNode(point: Int, node: AnimationRootNode?) { TransferContext.writeArguments(LONG to point.toLong(), OBJECT to node) TransferContext.callMethod(ptr, MethodBindings.setBlendPointNodePtr, NIL) } @@ -162,7 +154,7 @@ public open class AnimationNodeBlendSpace1D : AnimationRootNode() { /** * Removes the point at index [point] from the blend axis. */ - public final fun removeBlendPoint(point: Int): Unit { + public final fun removeBlendPoint(point: Int) { TransferContext.writeArguments(LONG to point.toLong()) TransferContext.callMethod(ptr, MethodBindings.removeBlendPointPtr, NIL) } @@ -176,7 +168,7 @@ public open class AnimationNodeBlendSpace1D : AnimationRootNode() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setMinSpace(minSpace: Float): Unit { + public final fun setMinSpace(minSpace: Float) { TransferContext.writeArguments(DOUBLE to minSpace.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setMinSpacePtr, NIL) } @@ -187,7 +179,7 @@ public open class AnimationNodeBlendSpace1D : AnimationRootNode() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setMaxSpace(maxSpace: Float): Unit { + public final fun setMaxSpace(maxSpace: Float) { TransferContext.writeArguments(DOUBLE to maxSpace.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setMaxSpacePtr, NIL) } @@ -198,7 +190,7 @@ public open class AnimationNodeBlendSpace1D : AnimationRootNode() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setSnap(snap: Float): Unit { + public final fun setSnap(snap: Float) { TransferContext.writeArguments(DOUBLE to snap.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setSnapPtr, NIL) } @@ -209,7 +201,7 @@ public open class AnimationNodeBlendSpace1D : AnimationRootNode() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setValueLabel(text: String): Unit { + public final fun setValueLabel(text: String) { TransferContext.writeArguments(STRING to text) TransferContext.callMethod(ptr, MethodBindings.setValueLabelPtr, NIL) } @@ -220,7 +212,7 @@ public open class AnimationNodeBlendSpace1D : AnimationRootNode() { return (TransferContext.readReturnValue(STRING) as String) } - public final fun setBlendMode(mode: BlendMode): Unit { + public final fun setBlendMode(mode: BlendMode) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setBlendModePtr, NIL) } @@ -231,7 +223,7 @@ public open class AnimationNodeBlendSpace1D : AnimationRootNode() { return BlendMode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setUseSync(enable: Boolean): Unit { + public final fun setUseSync(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setUseSyncPtr, NIL) } @@ -250,13 +242,11 @@ public open class AnimationNodeBlendSpace1D : AnimationRootNode() { */ INTERPOLATED(0), /** - * The blend space plays the animation of the animation node which blending position is closest - * to. Useful for frame-by-frame 2D animations. + * The blend space plays the animation of the animation node which blending position is closest to. Useful for frame-by-frame 2D animations. */ DISCRETE(1), /** - * Similar to [BLEND_MODE_DISCRETE], but starts the new animation at the last animation's - * playback position. + * Similar to [BLEND_MODE_DISCRETE], but starts the new animation at the last animation's playback position. */ DISCRETE_CARRY(2), ; @@ -275,60 +265,60 @@ public open class AnimationNodeBlendSpace1D : AnimationRootNode() { public object MethodBindings { internal val addBlendPointPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "add_blend_point", 285050433) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "add_blend_point", 285_050_433) internal val setBlendPointPositionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "set_blend_point_position", 1602489585) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "set_blend_point_position", 1_602_489_585) internal val getBlendPointPositionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "get_blend_point_position", 2339986948) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "get_blend_point_position", 2_339_986_948) internal val setBlendPointNodePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "set_blend_point_node", 4240341528) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "set_blend_point_node", 4_240_341_528) internal val getBlendPointNodePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "get_blend_point_node", 665599029) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "get_blend_point_node", 665_599_029) internal val removeBlendPointPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "remove_blend_point", 1286410249) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "remove_blend_point", 1_286_410_249) internal val getBlendPointCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "get_blend_point_count", 3905245786) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "get_blend_point_count", 3_905_245_786) internal val setMinSpacePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "set_min_space", 373806689) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "set_min_space", 373_806_689) internal val getMinSpacePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "get_min_space", 1740695150) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "get_min_space", 1_740_695_150) internal val setMaxSpacePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "set_max_space", 373806689) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "set_max_space", 373_806_689) internal val getMaxSpacePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "get_max_space", 1740695150) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "get_max_space", 1_740_695_150) internal val setSnapPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "set_snap", 373806689) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "set_snap", 373_806_689) internal val getSnapPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "get_snap", 1740695150) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "get_snap", 1_740_695_150) internal val setValueLabelPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "set_value_label", 83702148) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "set_value_label", 83_702_148) internal val getValueLabelPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "get_value_label", 201670096) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "get_value_label", 201_670_096) internal val setBlendModePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "set_blend_mode", 2600869457) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "set_blend_mode", 2_600_869_457) internal val getBlendModePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "get_blend_mode", 1547667849) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "get_blend_mode", 1_547_667_849) internal val setUseSyncPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "set_use_sync", 2586408642) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "set_use_sync", 2_586_408_642) internal val isUsingSyncPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "is_using_sync", 36873697) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace1D", "is_using_sync", 36_873_697) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeBlendSpace2D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeBlendSpace2D.kt index 2aeefe3207..83730bff7a 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeBlendSpace2D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeBlendSpace2D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -32,26 +29,19 @@ import kotlin.jvm.JvmOverloads /** * A resource used by [AnimationNodeBlendTree]. * - * [AnimationNodeBlendSpace2D] represents a virtual 2D space on which [AnimationRootNode]s are - * placed. Outputs the linear blend of the three adjacent animations using a [Vector2] weight. Adjacent - * in this context means the three [AnimationRootNode]s making up the triangle that contains the - * current value. + * [AnimationNodeBlendSpace2D] represents a virtual 2D space on which [AnimationRootNode]s are placed. Outputs the linear blend of the three adjacent animations using a [Vector2] weight. Adjacent in this context means the three [AnimationRootNode]s making up the triangle that contains the current value. * - * You can add vertices to the blend space with [addBlendPoint] and automatically triangulate it by - * setting [autoTriangles] to `true`. Otherwise, use [addTriangle] and [removeTriangle] to triangulate - * the blend space by hand. + * You can add vertices to the blend space with [addBlendPoint] and automatically triangulate it by setting [autoTriangles] to `true`. Otherwise, use [addTriangle] and [removeTriangle] to triangulate the blend space by hand. */ @GodotBaseType public open class AnimationNodeBlendSpace2D : AnimationRootNode() { /** - * Emitted every time the blend space's triangles are created, removed, or when one of their - * vertices changes position. + * Emitted every time the blend space's triangles are created, removed, or when one of their vertices changes position. */ public val trianglesUpdated: Signal0 by Signal0 /** - * If `true`, the blend space is triangulated automatically. The mesh updates every time you add - * or remove points with [addBlendPoint] and [removeBlendPoint]. + * If `true`, the blend space is triangulated automatically. The mesh updates every time you add or remove points with [addBlendPoint] and [removeBlendPoint]. */ public final inline var autoTriangles: Boolean @JvmName("autoTrianglesProperty") @@ -65,11 +55,8 @@ public open class AnimationNodeBlendSpace2D : AnimationRootNode() { * The blend space's X and Y axes' lower limit for the points' position. See [addBlendPoint]. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var minSpace: Vector2 @@ -84,11 +71,8 @@ public open class AnimationNodeBlendSpace2D : AnimationRootNode() { * The blend space's X and Y axes' upper limit for the points' position. See [addBlendPoint]. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var maxSpace: Vector2 @@ -103,11 +87,8 @@ public open class AnimationNodeBlendSpace2D : AnimationRootNode() { * Position increment to snap to when moving a point. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var snap: Vector2 @@ -164,7 +145,7 @@ public open class AnimationNodeBlendSpace2D : AnimationRootNode() { setUseSync(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(22, scriptIndex) } @@ -226,16 +207,14 @@ public open class AnimationNodeBlendSpace2D : AnimationRootNode() { } /** - * Adds a new point that represents a [node] at the position set by [pos]. You can insert it at a - * specific index using the [atIndex] argument. If you use the default value for [atIndex], the point - * is inserted at the end of the blend points array. + * Adds a new point that represents a [node] at the position set by [pos]. You can insert it at a specific index using the [atIndex] argument. If you use the default value for [atIndex], the point is inserted at the end of the blend points array. */ @JvmOverloads public final fun addBlendPoint( node: AnimationRootNode?, pos: Vector2, atIndex: Int = -1, - ): Unit { + ) { TransferContext.writeArguments(OBJECT to node, VECTOR2 to pos, LONG to atIndex.toLong()) TransferContext.callMethod(ptr, MethodBindings.addBlendPointPtr, NIL) } @@ -243,7 +222,7 @@ public open class AnimationNodeBlendSpace2D : AnimationRootNode() { /** * Updates the position of the point at index [point] in the blend space. */ - public final fun setBlendPointPosition(point: Int, pos: Vector2): Unit { + public final fun setBlendPointPosition(point: Int, pos: Vector2) { TransferContext.writeArguments(LONG to point.toLong(), VECTOR2 to pos) TransferContext.callMethod(ptr, MethodBindings.setBlendPointPositionPtr, NIL) } @@ -260,7 +239,7 @@ public open class AnimationNodeBlendSpace2D : AnimationRootNode() { /** * Changes the [AnimationNode] referenced by the point at index [point]. */ - public final fun setBlendPointNode(point: Int, node: AnimationRootNode?): Unit { + public final fun setBlendPointNode(point: Int, node: AnimationRootNode?) { TransferContext.writeArguments(LONG to point.toLong(), OBJECT to node) TransferContext.callMethod(ptr, MethodBindings.setBlendPointNodePtr, NIL) } @@ -277,7 +256,7 @@ public open class AnimationNodeBlendSpace2D : AnimationRootNode() { /** * Removes the point at index [point] from the blend space. */ - public final fun removeBlendPoint(point: Int): Unit { + public final fun removeBlendPoint(point: Int) { TransferContext.writeArguments(LONG to point.toLong()) TransferContext.callMethod(ptr, MethodBindings.removeBlendPointPtr, NIL) } @@ -292,9 +271,7 @@ public open class AnimationNodeBlendSpace2D : AnimationRootNode() { } /** - * Creates a new triangle using three points [x], [y], and [z]. Triangles can overlap. You can - * insert the triangle at a specific index using the [atIndex] argument. If you use the default value - * for [atIndex], the point is inserted at the end of the blend points array. + * Creates a new triangle using three points [x], [y], and [z]. Triangles can overlap. You can insert the triangle at a specific index using the [atIndex] argument. If you use the default value for [atIndex], the point is inserted at the end of the blend points array. */ @JvmOverloads public final fun addTriangle( @@ -302,7 +279,7 @@ public open class AnimationNodeBlendSpace2D : AnimationRootNode() { y: Int, z: Int, atIndex: Int = -1, - ): Unit { + ) { TransferContext.writeArguments(LONG to x.toLong(), LONG to y.toLong(), LONG to z.toLong(), LONG to atIndex.toLong()) TransferContext.callMethod(ptr, MethodBindings.addTrianglePtr, NIL) } @@ -319,7 +296,7 @@ public open class AnimationNodeBlendSpace2D : AnimationRootNode() { /** * Removes the triangle at index [triangle] from the blend space. */ - public final fun removeTriangle(triangle: Int): Unit { + public final fun removeTriangle(triangle: Int) { TransferContext.writeArguments(LONG to triangle.toLong()) TransferContext.callMethod(ptr, MethodBindings.removeTrianglePtr, NIL) } @@ -333,7 +310,7 @@ public open class AnimationNodeBlendSpace2D : AnimationRootNode() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setMinSpace(minSpace: Vector2): Unit { + public final fun setMinSpace(minSpace: Vector2) { TransferContext.writeArguments(VECTOR2 to minSpace) TransferContext.callMethod(ptr, MethodBindings.setMinSpacePtr, NIL) } @@ -344,7 +321,7 @@ public open class AnimationNodeBlendSpace2D : AnimationRootNode() { return (TransferContext.readReturnValue(VECTOR2) as Vector2) } - public final fun setMaxSpace(maxSpace: Vector2): Unit { + public final fun setMaxSpace(maxSpace: Vector2) { TransferContext.writeArguments(VECTOR2 to maxSpace) TransferContext.callMethod(ptr, MethodBindings.setMaxSpacePtr, NIL) } @@ -355,7 +332,7 @@ public open class AnimationNodeBlendSpace2D : AnimationRootNode() { return (TransferContext.readReturnValue(VECTOR2) as Vector2) } - public final fun setSnap(snap: Vector2): Unit { + public final fun setSnap(snap: Vector2) { TransferContext.writeArguments(VECTOR2 to snap) TransferContext.callMethod(ptr, MethodBindings.setSnapPtr, NIL) } @@ -366,7 +343,7 @@ public open class AnimationNodeBlendSpace2D : AnimationRootNode() { return (TransferContext.readReturnValue(VECTOR2) as Vector2) } - public final fun setXLabel(text: String): Unit { + public final fun setXLabel(text: String) { TransferContext.writeArguments(STRING to text) TransferContext.callMethod(ptr, MethodBindings.setXLabelPtr, NIL) } @@ -377,7 +354,7 @@ public open class AnimationNodeBlendSpace2D : AnimationRootNode() { return (TransferContext.readReturnValue(STRING) as String) } - public final fun setYLabel(text: String): Unit { + public final fun setYLabel(text: String) { TransferContext.writeArguments(STRING to text) TransferContext.callMethod(ptr, MethodBindings.setYLabelPtr, NIL) } @@ -388,7 +365,7 @@ public open class AnimationNodeBlendSpace2D : AnimationRootNode() { return (TransferContext.readReturnValue(STRING) as String) } - public final fun setAutoTriangles(enable: Boolean): Unit { + public final fun setAutoTriangles(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setAutoTrianglesPtr, NIL) } @@ -399,7 +376,7 @@ public open class AnimationNodeBlendSpace2D : AnimationRootNode() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setBlendMode(mode: BlendMode): Unit { + public final fun setBlendMode(mode: BlendMode) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setBlendModePtr, NIL) } @@ -410,7 +387,7 @@ public open class AnimationNodeBlendSpace2D : AnimationRootNode() { return BlendMode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setUseSync(enable: Boolean): Unit { + public final fun setUseSync(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setUseSyncPtr, NIL) } @@ -429,13 +406,11 @@ public open class AnimationNodeBlendSpace2D : AnimationRootNode() { */ INTERPOLATED(0), /** - * The blend space plays the animation of the animation node which blending position is closest - * to. Useful for frame-by-frame 2D animations. + * The blend space plays the animation of the animation node which blending position is closest to. Useful for frame-by-frame 2D animations. */ DISCRETE(1), /** - * Similar to [BLEND_MODE_DISCRETE], but starts the new animation at the last animation's - * playback position. + * Similar to [BLEND_MODE_DISCRETE], but starts the new animation at the last animation's playback position. */ DISCRETE_CARRY(2), ; @@ -454,84 +429,84 @@ public open class AnimationNodeBlendSpace2D : AnimationRootNode() { public object MethodBindings { internal val addBlendPointPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "add_blend_point", 402261981) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "add_blend_point", 402_261_981) internal val setBlendPointPositionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "set_blend_point_position", 163021252) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "set_blend_point_position", 163_021_252) internal val getBlendPointPositionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "get_blend_point_position", 2299179447) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "get_blend_point_position", 2_299_179_447) internal val setBlendPointNodePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "set_blend_point_node", 4240341528) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "set_blend_point_node", 4_240_341_528) internal val getBlendPointNodePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "get_blend_point_node", 665599029) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "get_blend_point_node", 665_599_029) internal val removeBlendPointPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "remove_blend_point", 1286410249) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "remove_blend_point", 1_286_410_249) internal val getBlendPointCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "get_blend_point_count", 3905245786) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "get_blend_point_count", 3_905_245_786) internal val addTrianglePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "add_triangle", 753017335) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "add_triangle", 753_017_335) internal val getTrianglePointPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "get_triangle_point", 50157827) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "get_triangle_point", 50_157_827) internal val removeTrianglePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "remove_triangle", 1286410249) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "remove_triangle", 1_286_410_249) internal val getTriangleCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "get_triangle_count", 3905245786) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "get_triangle_count", 3_905_245_786) internal val setMinSpacePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "set_min_space", 743155724) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "set_min_space", 743_155_724) internal val getMinSpacePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "get_min_space", 3341600327) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "get_min_space", 3_341_600_327) internal val setMaxSpacePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "set_max_space", 743155724) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "set_max_space", 743_155_724) internal val getMaxSpacePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "get_max_space", 3341600327) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "get_max_space", 3_341_600_327) internal val setSnapPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "set_snap", 743155724) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "set_snap", 743_155_724) internal val getSnapPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "get_snap", 3341600327) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "get_snap", 3_341_600_327) internal val setXLabelPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "set_x_label", 83702148) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "set_x_label", 83_702_148) internal val getXLabelPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "get_x_label", 201670096) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "get_x_label", 201_670_096) internal val setYLabelPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "set_y_label", 83702148) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "set_y_label", 83_702_148) internal val getYLabelPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "get_y_label", 201670096) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "get_y_label", 201_670_096) internal val setAutoTrianglesPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "set_auto_triangles", 2586408642) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "set_auto_triangles", 2_586_408_642) internal val getAutoTrianglesPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "get_auto_triangles", 36873697) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "get_auto_triangles", 36_873_697) internal val setBlendModePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "set_blend_mode", 81193520) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "set_blend_mode", 81_193_520) internal val getBlendModePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "get_blend_mode", 1398433632) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "get_blend_mode", 1_398_433_632) internal val setUseSyncPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "set_use_sync", 2586408642) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "set_use_sync", 2_586_408_642) internal val isUsingSyncPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "is_using_sync", 36873697) + TypeManager.getMethodBindPtr("AnimationNodeBlendSpace2D", "is_using_sync", 36_873_697) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeBlendTree.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeBlendTree.kt index cea9776520..75650a0b6b 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeBlendTree.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeBlendTree.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -32,9 +29,7 @@ import kotlin.jvm.JvmName import kotlin.jvm.JvmOverloads /** - * This animation node may contain a sub-tree of any other type animation nodes, such as - * [AnimationNodeTransition], [AnimationNodeBlend2], [AnimationNodeBlend3], [AnimationNodeOneShot], - * etc. This is one of the most commonly used animation node roots. + * This animation node may contain a sub-tree of any other type animation nodes, such as [AnimationNodeTransition], [AnimationNodeBlend2], [AnimationNodeBlend3], [AnimationNodeOneShot], etc. This is one of the most commonly used animation node roots. * * An [AnimationNodeOutput] node named `output` is created by default. */ @@ -49,11 +44,8 @@ public open class AnimationNodeBlendTree : AnimationRootNode() { * The global offset of all sub animation nodes. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var graphOffset: Vector2 @@ -64,7 +56,7 @@ public open class AnimationNodeBlendTree : AnimationRootNode() { setGraphOffset(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(23, scriptIndex) } @@ -88,15 +80,14 @@ public open class AnimationNodeBlendTree : AnimationRootNode() { } /** - * Adds an [AnimationNode] at the given [position]. The [name] is used to identify the created sub - * animation node later. + * Adds an [AnimationNode] at the given [position]. The [name] is used to identify the created sub animation node later. */ @JvmOverloads public final fun addNode( name: StringName, node: AnimationNode?, position: Vector2 = Vector2(0, 0), - ): Unit { + ) { TransferContext.writeArguments(STRING_NAME to name, OBJECT to node, VECTOR2 to position) TransferContext.callMethod(ptr, MethodBindings.addNodePtr, NIL) } @@ -113,7 +104,7 @@ public open class AnimationNodeBlendTree : AnimationRootNode() { /** * Removes a sub animation node. */ - public final fun removeNode(name: StringName): Unit { + public final fun removeNode(name: StringName) { TransferContext.writeArguments(STRING_NAME to name) TransferContext.callMethod(ptr, MethodBindings.removeNodePtr, NIL) } @@ -121,7 +112,7 @@ public open class AnimationNodeBlendTree : AnimationRootNode() { /** * Changes the name of a sub animation node. */ - public final fun renameNode(name: StringName, newName: StringName): Unit { + public final fun renameNode(name: StringName, newName: StringName) { TransferContext.writeArguments(STRING_NAME to name, STRING_NAME to newName) TransferContext.callMethod(ptr, MethodBindings.renameNodePtr, NIL) } @@ -136,14 +127,13 @@ public open class AnimationNodeBlendTree : AnimationRootNode() { } /** - * Connects the output of an [AnimationNode] as input for another [AnimationNode], at the input - * port specified by [inputIndex]. + * Connects the output of an [AnimationNode] as input for another [AnimationNode], at the input port specified by [inputIndex]. */ public final fun connectNode( inputNode: StringName, inputIndex: Int, outputNode: StringName, - ): Unit { + ) { TransferContext.writeArguments(STRING_NAME to inputNode, LONG to inputIndex.toLong(), STRING_NAME to outputNode) TransferContext.callMethod(ptr, MethodBindings.connectNodePtr, NIL) } @@ -151,7 +141,7 @@ public open class AnimationNodeBlendTree : AnimationRootNode() { /** * Disconnects the animation node connected to the specified input. */ - public final fun disconnectNode(inputNode: StringName, inputIndex: Int): Unit { + public final fun disconnectNode(inputNode: StringName, inputIndex: Int) { TransferContext.writeArguments(STRING_NAME to inputNode, LONG to inputIndex.toLong()) TransferContext.callMethod(ptr, MethodBindings.disconnectNodePtr, NIL) } @@ -159,7 +149,7 @@ public open class AnimationNodeBlendTree : AnimationRootNode() { /** * Modifies the position of a sub animation node. */ - public final fun setNodePosition(name: StringName, position: Vector2): Unit { + public final fun setNodePosition(name: StringName, position: Vector2) { TransferContext.writeArguments(STRING_NAME to name, VECTOR2 to position) TransferContext.callMethod(ptr, MethodBindings.setNodePositionPtr, NIL) } @@ -173,7 +163,7 @@ public open class AnimationNodeBlendTree : AnimationRootNode() { return (TransferContext.readReturnValue(VECTOR2) as Vector2) } - public final fun setGraphOffset(offset: Vector2): Unit { + public final fun setGraphOffset(offset: Vector2) { TransferContext.writeArguments(VECTOR2 to offset) TransferContext.callMethod(ptr, MethodBindings.setGraphOffsetPtr, NIL) } @@ -185,15 +175,14 @@ public open class AnimationNodeBlendTree : AnimationRootNode() { } /** - * Adds an [AnimationNode] at the given [position]. The [name] is used to identify the created sub - * animation node later. + * Adds an [AnimationNode] at the given [position]. The [name] is used to identify the created sub animation node later. */ @JvmOverloads public final fun addNode( name: String, node: AnimationNode?, position: Vector2 = Vector2(0, 0), - ) = addNode(name.asCachedStringName(), node, position) + ): Unit = addNode(name.asCachedStringName(), node, position) /** * Returns the sub animation node with the specified [name]. @@ -203,13 +192,12 @@ public open class AnimationNodeBlendTree : AnimationRootNode() { /** * Removes a sub animation node. */ - public final fun removeNode(name: String) = removeNode(name.asCachedStringName()) + public final fun removeNode(name: String): Unit = removeNode(name.asCachedStringName()) /** * Changes the name of a sub animation node. */ - public final fun renameNode(name: String, newName: String) = - renameNode(name.asCachedStringName(), newName.asCachedStringName()) + public final fun renameNode(name: String, newName: String): Unit = renameNode(name.asCachedStringName(), newName.asCachedStringName()) /** * Returns `true` if a sub animation node with specified [name] exists. @@ -217,32 +205,28 @@ public open class AnimationNodeBlendTree : AnimationRootNode() { public final fun hasNode(name: String): Boolean = hasNode(name.asCachedStringName()) /** - * Connects the output of an [AnimationNode] as input for another [AnimationNode], at the input - * port specified by [inputIndex]. + * Connects the output of an [AnimationNode] as input for another [AnimationNode], at the input port specified by [inputIndex]. */ public final fun connectNode( inputNode: String, inputIndex: Int, outputNode: String, - ) = connectNode(inputNode.asCachedStringName(), inputIndex, outputNode.asCachedStringName()) + ): Unit = connectNode(inputNode.asCachedStringName(), inputIndex, outputNode.asCachedStringName()) /** * Disconnects the animation node connected to the specified input. */ - public final fun disconnectNode(inputNode: String, inputIndex: Int) = - disconnectNode(inputNode.asCachedStringName(), inputIndex) + public final fun disconnectNode(inputNode: String, inputIndex: Int): Unit = disconnectNode(inputNode.asCachedStringName(), inputIndex) /** * Modifies the position of a sub animation node. */ - public final fun setNodePosition(name: String, position: Vector2) = - setNodePosition(name.asCachedStringName(), position) + public final fun setNodePosition(name: String, position: Vector2): Unit = setNodePosition(name.asCachedStringName(), position) /** * Returns the position of the sub animation node with the specified [name]. */ - public final fun getNodePosition(name: String): Vector2 = - getNodePosition(name.asCachedStringName()) + public final fun getNodePosition(name: String): Vector2 = getNodePosition(name.asCachedStringName()) public companion object { /** @@ -278,36 +262,36 @@ public open class AnimationNodeBlendTree : AnimationRootNode() { public object MethodBindings { internal val addNodePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendTree", "add_node", 1980270704) + TypeManager.getMethodBindPtr("AnimationNodeBlendTree", "add_node", 1_980_270_704) internal val getNodePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendTree", "get_node", 625644256) + TypeManager.getMethodBindPtr("AnimationNodeBlendTree", "get_node", 625_644_256) internal val removeNodePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendTree", "remove_node", 3304788590) + TypeManager.getMethodBindPtr("AnimationNodeBlendTree", "remove_node", 3_304_788_590) internal val renameNodePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendTree", "rename_node", 3740211285) + TypeManager.getMethodBindPtr("AnimationNodeBlendTree", "rename_node", 3_740_211_285) internal val hasNodePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendTree", "has_node", 2619796661) + TypeManager.getMethodBindPtr("AnimationNodeBlendTree", "has_node", 2_619_796_661) internal val connectNodePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendTree", "connect_node", 2168001410) + TypeManager.getMethodBindPtr("AnimationNodeBlendTree", "connect_node", 2_168_001_410) internal val disconnectNodePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendTree", "disconnect_node", 2415702435) + TypeManager.getMethodBindPtr("AnimationNodeBlendTree", "disconnect_node", 2_415_702_435) internal val setNodePositionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendTree", "set_node_position", 1999414630) + TypeManager.getMethodBindPtr("AnimationNodeBlendTree", "set_node_position", 1_999_414_630) internal val getNodePositionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendTree", "get_node_position", 3100822709) + TypeManager.getMethodBindPtr("AnimationNodeBlendTree", "get_node_position", 3_100_822_709) internal val setGraphOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendTree", "set_graph_offset", 743155724) + TypeManager.getMethodBindPtr("AnimationNodeBlendTree", "set_graph_offset", 743_155_724) internal val getGraphOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeBlendTree", "get_graph_offset", 3341600327) + TypeManager.getMethodBindPtr("AnimationNodeBlendTree", "get_graph_offset", 3_341_600_327) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeExtension.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeExtension.kt index 8db9cdf35b..33785afba2 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeExtension.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeExtension.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -19,38 +16,25 @@ import kotlin.Boolean import kotlin.Double import kotlin.Int import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmStatic /** - * [AnimationNodeExtension] exposes the APIs of [AnimationRootNode] to allow users to extend it from - * GDScript, C#, or C++. This class is not meant to be used directly, but to be extended by other - * classes. It is used to create custom nodes for the [AnimationTree] system. + * [AnimationNodeExtension] exposes the APIs of [AnimationRootNode] to allow users to extend it from GDScript, C#, or C++. This class is not meant to be used directly, but to be extended by other classes. It is used to create custom nodes for the [AnimationTree] system. */ @GodotBaseType public abstract class AnimationNodeExtension : AnimationNode() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(24, scriptIndex) } /** - * A version of the [AnimationNode.Process] method that is meant to be overridden by custom nodes. - * It returns a [PackedFloat32Array] with the processed animation data. + * A version of the [AnimationNode.Process] method that is meant to be overridden by custom nodes. It returns a [PackedFloat32Array] with the processed animation data. * - * The [PackedFloat64Array] parameter contains the playback information, containing the following - * values encoded as floating point numbers (in order): playback time and delta, start and end times, - * whether a seek was requested (encoded as a float greater than `0`), whether the seek request was - * externally requested (encoded as a float greater than `0`), the current [Animation.LoopedFlag] - * (encoded as a float), and the current blend weight. + * The [PackedFloat64Array] parameter contains the playback information, containing the following values encoded as floating point numbers (in order): playback time and delta, start and end times, whether a seek was requested (encoded as a float greater than `0`), whether the seek request was externally requested (encoded as a float greater than `0`), the current [Animation.LoopedFlag] (encoded as a float), and the current blend weight. * - * The function must return a [PackedFloat32Array] of the node's time info, containing the - * following values (in order): animation length, time position, delta, [Animation.LoopMode] (encoded - * as a float), whether the animation is about to end (encoded as a float greater than `0`) and - * whether the animation is infinite (encoded as a float greater than `0`). All values must be - * included in the returned array. + * The function must return a [PackedFloat32Array] of the node's time info, containing the following values (in order): animation length, time position, delta, [Animation.LoopMode] (encoded as a float), whether the animation is about to end (encoded as a float greater than `0`) and whether the animation is infinite (encoded as a float greater than `0`). All values must be included in the returned array. */ - public abstract fun _processAnimationNode(playbackInfo: PackedFloat64Array, testOnly: Boolean): - PackedFloat32Array + public abstract fun _processAnimationNode(playbackInfo: PackedFloat64Array, testOnly: Boolean): PackedFloat32Array public companion object { /** @@ -64,9 +48,7 @@ public abstract class AnimationNodeExtension : AnimationNode() { } /** - * Returns the animation's remaining time for the given node info. For looping animations, it - * will only return the remaining time if [breakLoop] is `true`, a large integer value will be - * returned otherwise. + * Returns the animation's remaining time for the given node info. For looping animations, it will only return the remaining time if [breakLoop] is `true`, a large integer value will be returned otherwise. */ @JvmStatic public final fun getRemainingTime(nodeInfo: PackedFloat32Array, breakLoop: Boolean): Double { @@ -78,9 +60,9 @@ public abstract class AnimationNodeExtension : AnimationNode() { public object MethodBindings { internal val isLoopingPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeExtension", "is_looping", 2035584311) + TypeManager.getMethodBindPtr("AnimationNodeExtension", "is_looping", 2_035_584_311) internal val getRemainingTimePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeExtension", "get_remaining_time", 2851904656) + TypeManager.getMethodBindPtr("AnimationNodeExtension", "get_remaining_time", 2_851_904_656) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeOneShot.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeOneShot.kt index f4c1d9742f..c3e0ba6711 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeOneShot.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeOneShot.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -20,17 +17,12 @@ import kotlin.Double import kotlin.Int import kotlin.Long import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * A resource to add to an [AnimationNodeBlendTree]. This animation node will execute a - * sub-animation and return once it finishes. Blend times for fading in and out can be customized, as - * well as filters. + * A resource to add to an [AnimationNodeBlendTree]. This animation node will execute a sub-animation and return once it finishes. Blend times for fading in and out can be customized, as well as filters. * - * After setting the request and changing the animation playback, the one-shot node automatically - * clears the request on the next process frame by setting its `request` value to - * [ONE_SHOT_REQUEST_NONE]. + * After setting the request and changing the animation playback, the one-shot node automatically clears the request on the next process frame by setting its `request` value to [ONE_SHOT_REQUEST_NONE]. * * ```gdscript * //gdscript @@ -69,8 +61,7 @@ import kotlin.jvm.JvmName * animationTree.Set("parameters/OneShot/request", (int)AnimationNodeOneShot.OneShotRequest.Abort); * * // Abort child animation with fading out connected to "shot" port. - * animationTree.Set("parameters/OneShot/request", - * (int)AnimationNodeOneShot.OneShotRequest.FadeOut); + * animationTree.Set("parameters/OneShot/request", (int)AnimationNodeOneShot.OneShotRequest.FadeOut); * * // Get current state (read-only). * animationTree.Get("parameters/OneShot/active"); @@ -93,14 +84,9 @@ public open class AnimationNodeOneShot : AnimationNodeSync() { } /** - * The fade-in duration. For example, setting this to `1.0` for a 5 second length animation will - * produce a cross-fade that starts at 0 second and ends at 1 second during the animation. + * The fade-in duration. For example, setting this to `1.0` for a 5 second length animation will produce a cross-fade that starts at 0 second and ends at 1 second during the animation. * - * **Note:** [AnimationNodeOneShot] transitions the current state after the end of the fading. - * When [AnimationNodeOutput] is considered as the most upstream, so the [fadeinTime] is scaled - * depending on the downstream delta. For example, if this value is set to `1.0` and a - * [AnimationNodeTimeScale] with a value of `2.0` is chained downstream, the actual processing time - * will be 0.5 second. + * **Note:** [AnimationNodeOneShot] transitions the current state after the end of the fading. When [AnimationNodeOutput] is considered as the most upstream, so the [fadeinTime] is scaled depending on the downstream delta. For example, if this value is set to `1.0` and a [AnimationNodeTimeScale] with a value of `2.0` is chained downstream, the actual processing time will be 0.5 second. */ public final inline var fadeinTime: Double @JvmName("fadeinTimeProperty") @@ -111,8 +97,7 @@ public open class AnimationNodeOneShot : AnimationNodeSync() { } /** - * Determines how cross-fading between animations is eased. If empty, the transition will be - * linear. Should be a unit [Curve]. + * Determines how cross-fading between animations is eased. If empty, the transition will be linear. Should be a unit [Curve]. */ public final inline var fadeinCurve: Curve? @JvmName("fadeinCurveProperty") @@ -123,14 +108,9 @@ public open class AnimationNodeOneShot : AnimationNodeSync() { } /** - * The fade-out duration. For example, setting this to `1.0` for a 5 second length animation will - * produce a cross-fade that starts at 4 second and ends at 5 second during the animation. + * The fade-out duration. For example, setting this to `1.0` for a 5 second length animation will produce a cross-fade that starts at 4 second and ends at 5 second during the animation. * - * **Note:** [AnimationNodeOneShot] transitions the current state after the end of the fading. - * When [AnimationNodeOutput] is considered as the most upstream, so the [fadeoutTime] is scaled - * depending on the downstream delta. For example, if this value is set to `1.0` and an - * [AnimationNodeTimeScale] with a value of `2.0` is chained downstream, the actual processing time - * will be 0.5 second. + * **Note:** [AnimationNodeOneShot] transitions the current state after the end of the fading. When [AnimationNodeOutput] is considered as the most upstream, so the [fadeoutTime] is scaled depending on the downstream delta. For example, if this value is set to `1.0` and an [AnimationNodeTimeScale] with a value of `2.0` is chained downstream, the actual processing time will be 0.5 second. */ public final inline var fadeoutTime: Double @JvmName("fadeoutTimeProperty") @@ -141,8 +121,7 @@ public open class AnimationNodeOneShot : AnimationNodeSync() { } /** - * Determines how cross-fading between animations is eased. If empty, the transition will be - * linear. Should be a unit [Curve]. + * Determines how cross-fading between animations is eased. If empty, the transition will be linear. Should be a unit [Curve]. */ public final inline var fadeoutCurve: Curve? @JvmName("fadeoutCurveProperty") @@ -153,8 +132,7 @@ public open class AnimationNodeOneShot : AnimationNodeSync() { } /** - * If `true`, breaks the loop at the end of the loop cycle for transition, even if the animation - * is looping. + * If `true`, breaks the loop at the end of the loop cycle for transition, even if the animation is looping. */ public final inline var breakLoopAtEnd: Boolean @JvmName("breakLoopAtEndProperty") @@ -167,10 +145,7 @@ public open class AnimationNodeOneShot : AnimationNodeSync() { /** * If `true`, the sub-animation will restart automatically after finishing. * - * In other words, to start auto restarting, the animation must be played once with the - * [ONE_SHOT_REQUEST_FIRE] request. The [ONE_SHOT_REQUEST_ABORT] request stops the auto restarting, - * but it does not disable the [autorestart] itself. So, the [ONE_SHOT_REQUEST_FIRE] request will - * start auto restarting again. + * In other words, to start auto restarting, the animation must be played once with the [ONE_SHOT_REQUEST_FIRE] request. The [ONE_SHOT_REQUEST_ABORT] request stops the auto restarting, but it does not disable the [autorestart] itself. So, the [ONE_SHOT_REQUEST_FIRE] request will start auto restarting again. */ public final inline var autorestart: Boolean @JvmName("autorestartProperty") @@ -192,8 +167,7 @@ public open class AnimationNodeOneShot : AnimationNodeSync() { } /** - * If [autorestart] is `true`, a random additional delay (in seconds) between 0 and this value - * will be added to [autorestartDelay]. + * If [autorestart] is `true`, a random additional delay (in seconds) between 0 and this value will be added to [autorestartDelay]. */ public final inline var autorestartRandomDelay: Double @JvmName("autorestartRandomDelayProperty") @@ -203,11 +177,11 @@ public open class AnimationNodeOneShot : AnimationNodeSync() { setAutorestartRandomDelay(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(25, scriptIndex) } - public final fun setFadeinTime(time: Double): Unit { + public final fun setFadeinTime(time: Double) { TransferContext.writeArguments(DOUBLE to time) TransferContext.callMethod(ptr, MethodBindings.setFadeinTimePtr, NIL) } @@ -218,7 +192,7 @@ public open class AnimationNodeOneShot : AnimationNodeSync() { return (TransferContext.readReturnValue(DOUBLE) as Double) } - public final fun setFadeinCurve(curve: Curve?): Unit { + public final fun setFadeinCurve(curve: Curve?) { TransferContext.writeArguments(OBJECT to curve) TransferContext.callMethod(ptr, MethodBindings.setFadeinCurvePtr, NIL) } @@ -229,7 +203,7 @@ public open class AnimationNodeOneShot : AnimationNodeSync() { return (TransferContext.readReturnValue(OBJECT) as Curve?) } - public final fun setFadeoutTime(time: Double): Unit { + public final fun setFadeoutTime(time: Double) { TransferContext.writeArguments(DOUBLE to time) TransferContext.callMethod(ptr, MethodBindings.setFadeoutTimePtr, NIL) } @@ -240,7 +214,7 @@ public open class AnimationNodeOneShot : AnimationNodeSync() { return (TransferContext.readReturnValue(DOUBLE) as Double) } - public final fun setFadeoutCurve(curve: Curve?): Unit { + public final fun setFadeoutCurve(curve: Curve?) { TransferContext.writeArguments(OBJECT to curve) TransferContext.callMethod(ptr, MethodBindings.setFadeoutCurvePtr, NIL) } @@ -251,7 +225,7 @@ public open class AnimationNodeOneShot : AnimationNodeSync() { return (TransferContext.readReturnValue(OBJECT) as Curve?) } - public final fun setBreakLoopAtEnd(enable: Boolean): Unit { + public final fun setBreakLoopAtEnd(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setBreakLoopAtEndPtr, NIL) } @@ -262,7 +236,7 @@ public open class AnimationNodeOneShot : AnimationNodeSync() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setAutorestart(active: Boolean): Unit { + public final fun setAutorestart(active: Boolean) { TransferContext.writeArguments(BOOL to active) TransferContext.callMethod(ptr, MethodBindings.setAutorestartPtr, NIL) } @@ -273,7 +247,7 @@ public open class AnimationNodeOneShot : AnimationNodeSync() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setAutorestartDelay(time: Double): Unit { + public final fun setAutorestartDelay(time: Double) { TransferContext.writeArguments(DOUBLE to time) TransferContext.callMethod(ptr, MethodBindings.setAutorestartDelayPtr, NIL) } @@ -284,7 +258,7 @@ public open class AnimationNodeOneShot : AnimationNodeSync() { return (TransferContext.readReturnValue(DOUBLE) as Double) } - public final fun setAutorestartRandomDelay(time: Double): Unit { + public final fun setAutorestartRandomDelay(time: Double) { TransferContext.writeArguments(DOUBLE to time) TransferContext.callMethod(ptr, MethodBindings.setAutorestartRandomDelayPtr, NIL) } @@ -295,7 +269,7 @@ public open class AnimationNodeOneShot : AnimationNodeSync() { return (TransferContext.readReturnValue(DOUBLE) as Double) } - public final fun setMixMode(mode: MixMode): Unit { + public final fun setMixMode(mode: MixMode) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setMixModePtr, NIL) } @@ -364,57 +338,57 @@ public open class AnimationNodeOneShot : AnimationNodeSync() { public object MethodBindings { internal val setFadeinTimePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeOneShot", "set_fadein_time", 373806689) + TypeManager.getMethodBindPtr("AnimationNodeOneShot", "set_fadein_time", 373_806_689) internal val getFadeinTimePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeOneShot", "get_fadein_time", 1740695150) + TypeManager.getMethodBindPtr("AnimationNodeOneShot", "get_fadein_time", 1_740_695_150) internal val setFadeinCurvePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeOneShot", "set_fadein_curve", 270443179) + TypeManager.getMethodBindPtr("AnimationNodeOneShot", "set_fadein_curve", 270_443_179) internal val getFadeinCurvePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeOneShot", "get_fadein_curve", 2460114913) + TypeManager.getMethodBindPtr("AnimationNodeOneShot", "get_fadein_curve", 2_460_114_913) internal val setFadeoutTimePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeOneShot", "set_fadeout_time", 373806689) + TypeManager.getMethodBindPtr("AnimationNodeOneShot", "set_fadeout_time", 373_806_689) internal val getFadeoutTimePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeOneShot", "get_fadeout_time", 1740695150) + TypeManager.getMethodBindPtr("AnimationNodeOneShot", "get_fadeout_time", 1_740_695_150) internal val setFadeoutCurvePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeOneShot", "set_fadeout_curve", 270443179) + TypeManager.getMethodBindPtr("AnimationNodeOneShot", "set_fadeout_curve", 270_443_179) internal val getFadeoutCurvePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeOneShot", "get_fadeout_curve", 2460114913) + TypeManager.getMethodBindPtr("AnimationNodeOneShot", "get_fadeout_curve", 2_460_114_913) internal val setBreakLoopAtEndPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeOneShot", "set_break_loop_at_end", 2586408642) + TypeManager.getMethodBindPtr("AnimationNodeOneShot", "set_break_loop_at_end", 2_586_408_642) internal val isLoopBrokenAtEndPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeOneShot", "is_loop_broken_at_end", 36873697) + TypeManager.getMethodBindPtr("AnimationNodeOneShot", "is_loop_broken_at_end", 36_873_697) internal val setAutorestartPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeOneShot", "set_autorestart", 2586408642) + TypeManager.getMethodBindPtr("AnimationNodeOneShot", "set_autorestart", 2_586_408_642) internal val hasAutorestartPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeOneShot", "has_autorestart", 36873697) + TypeManager.getMethodBindPtr("AnimationNodeOneShot", "has_autorestart", 36_873_697) internal val setAutorestartDelayPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeOneShot", "set_autorestart_delay", 373806689) + TypeManager.getMethodBindPtr("AnimationNodeOneShot", "set_autorestart_delay", 373_806_689) internal val getAutorestartDelayPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeOneShot", "get_autorestart_delay", 1740695150) + TypeManager.getMethodBindPtr("AnimationNodeOneShot", "get_autorestart_delay", 1_740_695_150) internal val setAutorestartRandomDelayPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeOneShot", "set_autorestart_random_delay", 373806689) + TypeManager.getMethodBindPtr("AnimationNodeOneShot", "set_autorestart_random_delay", 373_806_689) internal val getAutorestartRandomDelayPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeOneShot", "get_autorestart_random_delay", 1740695150) + TypeManager.getMethodBindPtr("AnimationNodeOneShot", "get_autorestart_random_delay", 1_740_695_150) internal val setMixModePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeOneShot", "set_mix_mode", 1018899799) + TypeManager.getMethodBindPtr("AnimationNodeOneShot", "set_mix_mode", 1_018_899_799) internal val getMixModePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeOneShot", "get_mix_mode", 3076550526) + TypeManager.getMethodBindPtr("AnimationNodeOneShot", "get_mix_mode", 3_076_550_526) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeOutput.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeOutput.kt index 9569842600..b20448dced 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeOutput.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeOutput.kt @@ -1,22 +1,18 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api import godot.`annotation`.GodotBaseType import kotlin.Int import kotlin.Suppress -import kotlin.Unit /** * A node created automatically in an [AnimationNodeBlendTree] that outputs the final animation. */ @GodotBaseType public open class AnimationNodeOutput : AnimationNode() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(26, scriptIndex) } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeStateMachine.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeStateMachine.kt index 3c4bc16ea6..e9f03cf116 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeStateMachine.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeStateMachine.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -29,10 +26,7 @@ import kotlin.jvm.JvmName import kotlin.jvm.JvmOverloads /** - * Contains multiple [AnimationRootNode]s representing animation states, connected in a graph. State - * transitions can be configured to happen automatically or via code, using a shortest-path algorithm. - * Retrieve the [AnimationNodeStateMachinePlayback] object from the [AnimationTree] node to control it - * programmatically. + * Contains multiple [AnimationRootNode]s representing animation states, connected in a graph. State transitions can be configured to happen automatically or via code, using a shortest-path algorithm. Retrieve the [AnimationNodeStateMachinePlayback] object from the [AnimationTree] node to control it programmatically. * * ```gdscript * //gdscript @@ -42,16 +36,14 @@ import kotlin.jvm.JvmOverloads * * ```csharp * //csharp - * var stateMachine = GetNode("AnimationTree").Get("parameters/playback") as - * AnimationNodeStateMachinePlayback; + * var stateMachine = GetNode("AnimationTree").Get("parameters/playback") as AnimationNodeStateMachinePlayback; * stateMachine.Travel("some_state"); * ``` */ @GodotBaseType public open class AnimationNodeStateMachine : AnimationRootNode() { /** - * This property can define the process of transitions for different use cases. See also - * [AnimationNodeStateMachine.StateMachineType]. + * This property can define the process of transitions for different use cases. See also [AnimationNodeStateMachine.StateMachineType]. */ public final inline var stateMachineType: StateMachineType @JvmName("stateMachineTypeProperty") @@ -62,9 +54,7 @@ public open class AnimationNodeStateMachine : AnimationRootNode() { } /** - * If `true`, allows teleport to the self state with [AnimationNodeStateMachinePlayback.travel]. - * When the reset option is enabled in [AnimationNodeStateMachinePlayback.travel], the animation is - * restarted. If `false`, nothing happens on the teleportation to the self state. + * If `true`, allows teleport to the self state with [AnimationNodeStateMachinePlayback.travel]. When the reset option is enabled in [AnimationNodeStateMachinePlayback.travel], the animation is restarted. If `false`, nothing happens on the teleportation to the self state. */ public final inline var allowTransitionToSelf: Boolean @JvmName("allowTransitionToSelfProperty") @@ -77,9 +67,7 @@ public open class AnimationNodeStateMachine : AnimationRootNode() { /** * If `true`, treat the cross-fade to the start and end nodes as a blend with the RESET animation. * - * In most cases, when additional cross-fades are performed in the parent [AnimationNode] of the - * state machine, setting this property to `false` and matching the cross-fade time of the parent - * [AnimationNode] and the state machine's start node and end node gives good results. + * In most cases, when additional cross-fades are performed in the parent [AnimationNode] of the state machine, setting this property to `false` and matching the cross-fade time of the parent [AnimationNode] and the state machine's start node and end node gives good results. */ public final inline var resetEnds: Boolean @JvmName("resetEndsProperty") @@ -89,7 +77,7 @@ public open class AnimationNodeStateMachine : AnimationRootNode() { setResetEnds(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(27, scriptIndex) } @@ -101,7 +89,7 @@ public open class AnimationNodeStateMachine : AnimationRootNode() { name: StringName, node: AnimationNode?, position: Vector2 = Vector2(0, 0), - ): Unit { + ) { TransferContext.writeArguments(STRING_NAME to name, OBJECT to node, VECTOR2 to position) TransferContext.callMethod(ptr, MethodBindings.addNodePtr, NIL) } @@ -109,7 +97,7 @@ public open class AnimationNodeStateMachine : AnimationRootNode() { /** * Replaces the given animation node with a new animation node. */ - public final fun replaceNode(name: StringName, node: AnimationNode?): Unit { + public final fun replaceNode(name: StringName, node: AnimationNode?) { TransferContext.writeArguments(STRING_NAME to name, OBJECT to node) TransferContext.callMethod(ptr, MethodBindings.replaceNodePtr, NIL) } @@ -126,7 +114,7 @@ public open class AnimationNodeStateMachine : AnimationRootNode() { /** * Deletes the given animation node from the graph. */ - public final fun removeNode(name: StringName): Unit { + public final fun removeNode(name: StringName) { TransferContext.writeArguments(STRING_NAME to name) TransferContext.callMethod(ptr, MethodBindings.removeNodePtr, NIL) } @@ -134,7 +122,7 @@ public open class AnimationNodeStateMachine : AnimationRootNode() { /** * Renames the given animation node. */ - public final fun renameNode(name: StringName, newName: StringName): Unit { + public final fun renameNode(name: StringName, newName: StringName) { TransferContext.writeArguments(STRING_NAME to name, STRING_NAME to newName) TransferContext.callMethod(ptr, MethodBindings.renameNodePtr, NIL) } @@ -160,7 +148,7 @@ public open class AnimationNodeStateMachine : AnimationRootNode() { /** * Sets the animation node's coordinates. Used for display in the editor. */ - public final fun setNodePosition(name: StringName, position: Vector2): Unit { + public final fun setNodePosition(name: StringName, position: Vector2) { TransferContext.writeArguments(STRING_NAME to name, VECTOR2 to position) TransferContext.callMethod(ptr, MethodBindings.setNodePositionPtr, NIL) } @@ -190,7 +178,7 @@ public open class AnimationNodeStateMachine : AnimationRootNode() { from: StringName, to: StringName, transition: AnimationNodeStateMachineTransition?, - ): Unit { + ) { TransferContext.writeArguments(STRING_NAME to from, STRING_NAME to to, OBJECT to transition) TransferContext.callMethod(ptr, MethodBindings.addTransitionPtr, NIL) } @@ -234,7 +222,7 @@ public open class AnimationNodeStateMachine : AnimationRootNode() { /** * Deletes the given transition by index. */ - public final fun removeTransitionByIndex(idx: Int): Unit { + public final fun removeTransitionByIndex(idx: Int) { TransferContext.writeArguments(LONG to idx.toLong()) TransferContext.callMethod(ptr, MethodBindings.removeTransitionByIndexPtr, NIL) } @@ -242,7 +230,7 @@ public open class AnimationNodeStateMachine : AnimationRootNode() { /** * Deletes the transition between the two specified animation nodes. */ - public final fun removeTransition(from: StringName, to: StringName): Unit { + public final fun removeTransition(from: StringName, to: StringName) { TransferContext.writeArguments(STRING_NAME to from, STRING_NAME to to) TransferContext.callMethod(ptr, MethodBindings.removeTransitionPtr, NIL) } @@ -250,7 +238,7 @@ public open class AnimationNodeStateMachine : AnimationRootNode() { /** * Sets the draw offset of the graph. Used for display in the editor. */ - public final fun setGraphOffset(offset: Vector2): Unit { + public final fun setGraphOffset(offset: Vector2) { TransferContext.writeArguments(VECTOR2 to offset) TransferContext.callMethod(ptr, MethodBindings.setGraphOffsetPtr, NIL) } @@ -264,7 +252,7 @@ public open class AnimationNodeStateMachine : AnimationRootNode() { return (TransferContext.readReturnValue(VECTOR2) as Vector2) } - public final fun setStateMachineType(stateMachineType: StateMachineType): Unit { + public final fun setStateMachineType(stateMachineType: StateMachineType) { TransferContext.writeArguments(LONG to stateMachineType.id) TransferContext.callMethod(ptr, MethodBindings.setStateMachineTypePtr, NIL) } @@ -275,7 +263,7 @@ public open class AnimationNodeStateMachine : AnimationRootNode() { return StateMachineType.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setAllowTransitionToSelf(enable: Boolean): Unit { + public final fun setAllowTransitionToSelf(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setAllowTransitionToSelfPtr, NIL) } @@ -286,7 +274,7 @@ public open class AnimationNodeStateMachine : AnimationRootNode() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setResetEnds(enable: Boolean): Unit { + public final fun setResetEnds(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setResetEndsPtr, NIL) } @@ -305,13 +293,12 @@ public open class AnimationNodeStateMachine : AnimationRootNode() { name: String, node: AnimationNode?, position: Vector2 = Vector2(0, 0), - ) = addNode(name.asCachedStringName(), node, position) + ): Unit = addNode(name.asCachedStringName(), node, position) /** * Replaces the given animation node with a new animation node. */ - public final fun replaceNode(name: String, node: AnimationNode?) = - replaceNode(name.asCachedStringName(), node) + public final fun replaceNode(name: String, node: AnimationNode?): Unit = replaceNode(name.asCachedStringName(), node) /** * Returns the animation node with the given name. @@ -321,13 +308,12 @@ public open class AnimationNodeStateMachine : AnimationRootNode() { /** * Deletes the given animation node from the graph. */ - public final fun removeNode(name: String) = removeNode(name.asCachedStringName()) + public final fun removeNode(name: String): Unit = removeNode(name.asCachedStringName()) /** * Renames the given animation node. */ - public final fun renameNode(name: String, newName: String) = - renameNode(name.asCachedStringName(), newName.asCachedStringName()) + public final fun renameNode(name: String, newName: String): Unit = renameNode(name.asCachedStringName(), newName.asCachedStringName()) /** * Returns `true` if the graph contains the given animation node. @@ -337,20 +323,17 @@ public open class AnimationNodeStateMachine : AnimationRootNode() { /** * Sets the animation node's coordinates. Used for display in the editor. */ - public final fun setNodePosition(name: String, position: Vector2) = - setNodePosition(name.asCachedStringName(), position) + public final fun setNodePosition(name: String, position: Vector2): Unit = setNodePosition(name.asCachedStringName(), position) /** * Returns the given animation node's coordinates. Used for display in the editor. */ - public final fun getNodePosition(name: String): Vector2 = - getNodePosition(name.asCachedStringName()) + public final fun getNodePosition(name: String): Vector2 = getNodePosition(name.asCachedStringName()) /** * Returns `true` if there is a transition between the given animation nodes. */ - public final fun hasTransition(from: String, to: String): Boolean = - hasTransition(from.asCachedStringName(), to.asCachedStringName()) + public final fun hasTransition(from: String, to: String): Boolean = hasTransition(from.asCachedStringName(), to.asCachedStringName()) /** * Adds a transition between the given animation nodes. @@ -359,32 +342,26 @@ public open class AnimationNodeStateMachine : AnimationRootNode() { from: String, to: String, transition: AnimationNodeStateMachineTransition?, - ) = addTransition(from.asCachedStringName(), to.asCachedStringName(), transition) + ): Unit = addTransition(from.asCachedStringName(), to.asCachedStringName(), transition) /** * Deletes the transition between the two specified animation nodes. */ - public final fun removeTransition(from: String, to: String) = - removeTransition(from.asCachedStringName(), to.asCachedStringName()) + public final fun removeTransition(from: String, to: String): Unit = removeTransition(from.asCachedStringName(), to.asCachedStringName()) public enum class StateMachineType( id: Long, ) { /** - * Seeking to the beginning is treated as playing from the start state. Transition to the end - * state is treated as exiting the state machine. + * Seeking to the beginning is treated as playing from the start state. Transition to the end state is treated as exiting the state machine. */ ROOT(0), /** - * Seeking to the beginning is treated as seeking to the beginning of the animation in the - * current state. Transition to the end state, or the absence of transitions in each state, is - * treated as exiting the state machine. + * Seeking to the beginning is treated as seeking to the beginning of the animation in the current state. Transition to the end state, or the absence of transitions in each state, is treated as exiting the state machine. */ NESTED(1), /** - * This is a grouped state machine that can be controlled from a parent state machine. It does - * not work independently. There must be a state machine with [stateMachineType] of - * [STATE_MACHINE_TYPE_ROOT] or [STATE_MACHINE_TYPE_NESTED] in the parent or ancestor. + * This is a grouped state machine that can be controlled from a parent state machine. It does not work independently. There must be a state machine with [stateMachineType] of [STATE_MACHINE_TYPE_ROOT] or [STATE_MACHINE_TYPE_NESTED] in the parent or ancestor. */ GROUPED(2), ; @@ -403,78 +380,78 @@ public open class AnimationNodeStateMachine : AnimationRootNode() { public object MethodBindings { internal val addNodePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "add_node", 1980270704) + TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "add_node", 1_980_270_704) internal val replaceNodePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "replace_node", 2559412862) + TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "replace_node", 2_559_412_862) internal val getNodePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "get_node", 625644256) + TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "get_node", 625_644_256) internal val removeNodePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "remove_node", 3304788590) + TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "remove_node", 3_304_788_590) internal val renameNodePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "rename_node", 3740211285) + TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "rename_node", 3_740_211_285) internal val hasNodePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "has_node", 2619796661) + TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "has_node", 2_619_796_661) internal val getNodeNamePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "get_node_name", 739213945) + TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "get_node_name", 739_213_945) internal val setNodePositionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "set_node_position", 1999414630) + TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "set_node_position", 1_999_414_630) internal val getNodePositionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "get_node_position", 3100822709) + TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "get_node_position", 3_100_822_709) internal val hasTransitionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "has_transition", 471820014) + TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "has_transition", 471_820_014) internal val addTransitionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "add_transition", 795486887) + TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "add_transition", 795_486_887) internal val getTransitionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "get_transition", 4192381260) + TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "get_transition", 4_192_381_260) internal val getTransitionFromPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "get_transition_from", 659327637) + TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "get_transition_from", 659_327_637) internal val getTransitionToPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "get_transition_to", 659327637) + TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "get_transition_to", 659_327_637) internal val getTransitionCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "get_transition_count", 3905245786) + TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "get_transition_count", 3_905_245_786) internal val removeTransitionByIndexPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "remove_transition_by_index", 1286410249) + TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "remove_transition_by_index", 1_286_410_249) internal val removeTransitionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "remove_transition", 3740211285) + TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "remove_transition", 3_740_211_285) internal val setGraphOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "set_graph_offset", 743155724) + TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "set_graph_offset", 743_155_724) internal val getGraphOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "get_graph_offset", 3341600327) + TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "get_graph_offset", 3_341_600_327) internal val setStateMachineTypePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "set_state_machine_type", 2584759088) + TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "set_state_machine_type", 2_584_759_088) internal val getStateMachineTypePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "get_state_machine_type", 1140726469) + TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "get_state_machine_type", 1_140_726_469) internal val setAllowTransitionToSelfPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "set_allow_transition_to_self", 2586408642) + TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "set_allow_transition_to_self", 2_586_408_642) internal val isAllowTransitionToSelfPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "is_allow_transition_to_self", 36873697) + TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "is_allow_transition_to_self", 36_873_697) internal val setResetEndsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "set_reset_ends", 2586408642) + TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "set_reset_ends", 2_586_408_642) internal val areEndsResetPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "are_ends_reset", 36873697) + TypeManager.getMethodBindPtr("AnimationNodeStateMachine", "are_ends_reset", 36_873_697) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeStateMachinePlayback.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeStateMachinePlayback.kt index 2897a679f0..12e0b65da4 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeStateMachinePlayback.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeStateMachinePlayback.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -28,8 +25,7 @@ import kotlin.Unit import kotlin.jvm.JvmOverloads /** - * Allows control of [AnimationTree] state machines created with [AnimationNodeStateMachine]. - * Retrieve with `$AnimationTree.get("parameters/playback")`. + * Allows control of [AnimationTree] state machines created with [AnimationNodeStateMachine]. Retrieve with `$AnimationTree.get("parameters/playback")`. * * ```gdscript * //gdscript @@ -39,28 +35,25 @@ import kotlin.jvm.JvmOverloads * * ```csharp * //csharp - * var stateMachine = - * GetNode("AnimationTree").Get("parameters/playback").As(); + * var stateMachine = GetNode("AnimationTree").Get("parameters/playback").As(); * stateMachine.Travel("some_state"); * ``` */ @GodotBaseType public open class AnimationNodeStateMachinePlayback : Resource() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(28, scriptIndex) } /** * Transitions from the current state to another one, following the shortest path. * - * If the path does not connect from the current state, the animation will play after the state - * teleports. + * If the path does not connect from the current state, the animation will play after the state teleports. * - * If [resetOnTeleport] is `true`, the animation is played from the beginning when the travel - * cause a teleportation. + * If [resetOnTeleport] is `true`, the animation is played from the beginning when the travel cause a teleportation. */ @JvmOverloads - public final fun travel(toNode: StringName, resetOnTeleport: Boolean = true): Unit { + public final fun travel(toNode: StringName, resetOnTeleport: Boolean = true) { TransferContext.writeArguments(STRING_NAME to toNode, BOOL to resetOnTeleport) TransferContext.callMethod(ptr, MethodBindings.travelPtr, NIL) } @@ -71,16 +64,15 @@ public open class AnimationNodeStateMachinePlayback : Resource() { * If [reset] is `true`, the animation is played from the beginning. */ @JvmOverloads - public final fun start(node: StringName, reset: Boolean = true): Unit { + public final fun start(node: StringName, reset: Boolean = true) { TransferContext.writeArguments(STRING_NAME to node, BOOL to reset) TransferContext.callMethod(ptr, MethodBindings.startPtr, NIL) } /** - * If there is a next path by travel or auto advance, immediately transitions from the current - * state to the next state. + * If there is a next path by travel or auto advance, immediately transitions from the current state to the next state. */ - public final fun next(): Unit { + public final fun next() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.nextPtr, NIL) } @@ -88,7 +80,7 @@ public open class AnimationNodeStateMachinePlayback : Resource() { /** * Stops the currently playing animation. */ - public final fun stop(): Unit { + public final fun stop() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.stopPtr, NIL) } @@ -105,8 +97,7 @@ public open class AnimationNodeStateMachinePlayback : Resource() { /** * Returns the currently playing animation state. * - * **Note:** When using a cross-fade, the current state changes to the next state immediately - * after the cross-fade begins. + * **Note:** When using a cross-fade, the current state changes to the next state immediately after the cross-fade begins. */ public final fun getCurrentNode(): StringName { TransferContext.writeArguments() @@ -126,10 +117,7 @@ public open class AnimationNodeStateMachinePlayback : Resource() { /** * Returns the current state length. * - * **Note:** It is possible that any [AnimationRootNode] can be nodes as well as animations. This - * means that there can be multiple animations within a single state. Which animation length has - * priority depends on the nodes connected inside it. Also, if a transition does not reset, the - * remaining length at that point will be returned. + * **Note:** It is possible that any [AnimationRootNode] can be nodes as well as animations. This means that there can be multiple animations within a single state. Which animation length has priority depends on the nodes connected inside it. Also, if a transition does not reset, the remaining length at that point will be returned. */ public final fun getCurrentLength(): Float { TransferContext.writeArguments() @@ -158,15 +146,12 @@ public open class AnimationNodeStateMachinePlayback : Resource() { /** * Transitions from the current state to another one, following the shortest path. * - * If the path does not connect from the current state, the animation will play after the state - * teleports. + * If the path does not connect from the current state, the animation will play after the state teleports. * - * If [resetOnTeleport] is `true`, the animation is played from the beginning when the travel - * cause a teleportation. + * If [resetOnTeleport] is `true`, the animation is played from the beginning when the travel cause a teleportation. */ @JvmOverloads - public final fun travel(toNode: String, resetOnTeleport: Boolean = true) = - travel(toNode.asCachedStringName(), resetOnTeleport) + public final fun travel(toNode: String, resetOnTeleport: Boolean = true): Unit = travel(toNode.asCachedStringName(), resetOnTeleport) /** * Starts playing the given animation. @@ -174,40 +159,39 @@ public open class AnimationNodeStateMachinePlayback : Resource() { * If [reset] is `true`, the animation is played from the beginning. */ @JvmOverloads - public final fun start(node: String, reset: Boolean = true) = - start(node.asCachedStringName(), reset) + public final fun start(node: String, reset: Boolean = true): Unit = start(node.asCachedStringName(), reset) public companion object public object MethodBindings { internal val travelPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachinePlayback", "travel", 3823612587) + TypeManager.getMethodBindPtr("AnimationNodeStateMachinePlayback", "travel", 3_823_612_587) internal val startPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachinePlayback", "start", 3823612587) + TypeManager.getMethodBindPtr("AnimationNodeStateMachinePlayback", "start", 3_823_612_587) internal val nextPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachinePlayback", "next", 3218959716) + TypeManager.getMethodBindPtr("AnimationNodeStateMachinePlayback", "next", 3_218_959_716) internal val stopPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachinePlayback", "stop", 3218959716) + TypeManager.getMethodBindPtr("AnimationNodeStateMachinePlayback", "stop", 3_218_959_716) internal val isPlayingPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachinePlayback", "is_playing", 36873697) + TypeManager.getMethodBindPtr("AnimationNodeStateMachinePlayback", "is_playing", 36_873_697) internal val getCurrentNodePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachinePlayback", "get_current_node", 2002593661) + TypeManager.getMethodBindPtr("AnimationNodeStateMachinePlayback", "get_current_node", 2_002_593_661) internal val getCurrentPlayPositionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachinePlayback", "get_current_play_position", 1740695150) + TypeManager.getMethodBindPtr("AnimationNodeStateMachinePlayback", "get_current_play_position", 1_740_695_150) internal val getCurrentLengthPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachinePlayback", "get_current_length", 1740695150) + TypeManager.getMethodBindPtr("AnimationNodeStateMachinePlayback", "get_current_length", 1_740_695_150) internal val getFadingFromNodePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachinePlayback", "get_fading_from_node", 2002593661) + TypeManager.getMethodBindPtr("AnimationNodeStateMachinePlayback", "get_fading_from_node", 2_002_593_661) internal val getTravelPathPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachinePlayback", "get_travel_path", 3995934104) + TypeManager.getMethodBindPtr("AnimationNodeStateMachinePlayback", "get_travel_path", 3_995_934_104) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeStateMachineTransition.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeStateMachineTransition.kt index adea86df26..36b053c2d6 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeStateMachineTransition.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeStateMachineTransition.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -31,8 +28,7 @@ import kotlin.Unit import kotlin.jvm.JvmName /** - * The path generated when using [AnimationNodeStateMachinePlayback.travel] is limited to the nodes - * connected by [AnimationNodeStateMachineTransition]. + * The path generated when using [AnimationNodeStateMachinePlayback.travel] is limited to the nodes connected by [AnimationNodeStateMachineTransition]. * * You can set the timing and conditions of the transition in detail. */ @@ -46,10 +42,7 @@ public open class AnimationNodeStateMachineTransition : Resource() { /** * The time to cross-fade between this state and the next. * - * **Note:** [AnimationNodeStateMachine] transitions the current state immediately after the start - * of the fading. The precise remaining time can only be inferred from the main animation. When - * [AnimationNodeOutput] is considered as the most upstream, so the [xfadeTime] is not scaled - * depending on the downstream delta. See also [AnimationNodeOneShot.fadeoutTime]. + * **Note:** [AnimationNodeStateMachine] transitions the current state immediately after the start of the fading. The precise remaining time can only be inferred from the main animation. When [AnimationNodeOutput] is considered as the most upstream, so the [xfadeTime] is not scaled depending on the downstream delta. See also [AnimationNodeOneShot.fadeoutTime]. */ public final inline var xfadeTime: Float @JvmName("xfadeTimeProperty") @@ -60,8 +53,7 @@ public open class AnimationNodeStateMachineTransition : Resource() { } /** - * Ease curve for better control over cross-fade between this state and the next. Should be a unit - * [Curve]. + * Ease curve for better control over cross-fade between this state and the next. Should be a unit [Curve]. */ public final inline var xfadeCurve: Curve? @JvmName("xfadeCurveProperty") @@ -72,8 +64,7 @@ public open class AnimationNodeStateMachineTransition : Resource() { } /** - * If `true`, breaks the loop at the end of the loop cycle for transition, even if the animation - * is looping. + * If `true`, breaks the loop at the end of the loop cycle for transition, even if the animation is looping. */ public final inline var breakLoopAtEnd: Boolean @JvmName("breakLoopAtEndProperty") @@ -95,8 +86,7 @@ public open class AnimationNodeStateMachineTransition : Resource() { } /** - * Lower priority transitions are preferred when travelling through the tree via - * [AnimationNodeStateMachinePlayback.travel] or [advanceMode] is set to [ADVANCE_MODE_AUTO]. + * Lower priority transitions are preferred when travelling through the tree via [AnimationNodeStateMachinePlayback.travel] or [advanceMode] is set to [ADVANCE_MODE_AUTO]. */ public final inline var priority: Int @JvmName("priorityProperty") @@ -118,9 +108,7 @@ public open class AnimationNodeStateMachineTransition : Resource() { } /** - * Determines whether the transition should be disabled, enabled when using - * [AnimationNodeStateMachinePlayback.travel], or traversed automatically if the [advanceCondition] - * and [advanceExpression] checks are `true` (if assigned). + * Determines whether the transition should be disabled, enabled when using [AnimationNodeStateMachinePlayback.travel], or traversed automatically if the [advanceCondition] and [advanceExpression] checks are `true` (if assigned). */ public final inline var advanceMode: AdvanceMode @JvmName("advanceModeProperty") @@ -131,11 +119,7 @@ public open class AnimationNodeStateMachineTransition : Resource() { } /** - * Turn on auto advance when this condition is set. The provided name will become a boolean - * parameter on the [AnimationTree] that can be controlled from code (see - * [url=$DOCS_URL/tutorials/animation/animation_tree.html#controlling-from-code]Using - * AnimationTree[/url]). For example, if [AnimationTree.treeRoot] is an [AnimationNodeStateMachine] - * and [advanceCondition] is set to `"idle"`: + * Turn on auto advance when this condition is set. The provided name will become a boolean parameter on the [AnimationTree] that can be controlled from code (see [url=$DOCS_URL/tutorials/animation/animation_tree.html#controlling-from-code]Using AnimationTree[/url]). For example, if [AnimationTree.treeRoot] is an [AnimationNodeStateMachine] and [advanceCondition] is set to `"idle"`: * * ```gdscript * //gdscript @@ -144,8 +128,7 @@ public open class AnimationNodeStateMachineTransition : Resource() { * * ```csharp * //csharp - * GetNode("animation_tree").Set("parameters/conditions/idle", IsOnFloor && - * (LinearVelocity.X == 0)); + * GetNode("animation_tree").Set("parameters/conditions/idle", IsOnFloor && (LinearVelocity.X == 0)); * ``` */ public final inline var advanceCondition: StringName @@ -157,9 +140,7 @@ public open class AnimationNodeStateMachineTransition : Resource() { } /** - * Use an expression as a condition for state machine transitions. It is possible to create - * complex animation advance conditions for switching between states and gives much greater - * flexibility for creating complex state machines by directly interfacing with the script code. + * Use an expression as a condition for state machine transitions. It is possible to create complex animation advance conditions for switching between states and gives much greater flexibility for creating complex state machines by directly interfacing with the script code. */ public final inline var advanceExpression: String @JvmName("advanceExpressionProperty") @@ -169,11 +150,11 @@ public open class AnimationNodeStateMachineTransition : Resource() { setAdvanceExpression(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(29, scriptIndex) } - public final fun setSwitchMode(mode: SwitchMode): Unit { + public final fun setSwitchMode(mode: SwitchMode) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setSwitchModePtr, NIL) } @@ -184,7 +165,7 @@ public open class AnimationNodeStateMachineTransition : Resource() { return SwitchMode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setAdvanceMode(mode: AdvanceMode): Unit { + public final fun setAdvanceMode(mode: AdvanceMode) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setAdvanceModePtr, NIL) } @@ -195,7 +176,7 @@ public open class AnimationNodeStateMachineTransition : Resource() { return AdvanceMode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setAdvanceCondition(name: StringName): Unit { + public final fun setAdvanceCondition(name: StringName) { TransferContext.writeArguments(STRING_NAME to name) TransferContext.callMethod(ptr, MethodBindings.setAdvanceConditionPtr, NIL) } @@ -206,7 +187,7 @@ public open class AnimationNodeStateMachineTransition : Resource() { return (TransferContext.readReturnValue(STRING_NAME) as StringName) } - public final fun setXfadeTime(secs: Float): Unit { + public final fun setXfadeTime(secs: Float) { TransferContext.writeArguments(DOUBLE to secs.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setXfadeTimePtr, NIL) } @@ -217,7 +198,7 @@ public open class AnimationNodeStateMachineTransition : Resource() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setXfadeCurve(curve: Curve?): Unit { + public final fun setXfadeCurve(curve: Curve?) { TransferContext.writeArguments(OBJECT to curve) TransferContext.callMethod(ptr, MethodBindings.setXfadeCurvePtr, NIL) } @@ -228,7 +209,7 @@ public open class AnimationNodeStateMachineTransition : Resource() { return (TransferContext.readReturnValue(OBJECT) as Curve?) } - public final fun setBreakLoopAtEnd(enable: Boolean): Unit { + public final fun setBreakLoopAtEnd(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setBreakLoopAtEndPtr, NIL) } @@ -239,7 +220,7 @@ public open class AnimationNodeStateMachineTransition : Resource() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setReset(reset: Boolean): Unit { + public final fun setReset(reset: Boolean) { TransferContext.writeArguments(BOOL to reset) TransferContext.callMethod(ptr, MethodBindings.setResetPtr, NIL) } @@ -250,7 +231,7 @@ public open class AnimationNodeStateMachineTransition : Resource() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setPriority(priority: Int): Unit { + public final fun setPriority(priority: Int) { TransferContext.writeArguments(LONG to priority.toLong()) TransferContext.callMethod(ptr, MethodBindings.setPriorityPtr, NIL) } @@ -261,7 +242,7 @@ public open class AnimationNodeStateMachineTransition : Resource() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setAdvanceExpression(text: String): Unit { + public final fun setAdvanceExpression(text: String) { TransferContext.writeArguments(STRING to text) TransferContext.callMethod(ptr, MethodBindings.setAdvanceExpressionPtr, NIL) } @@ -272,25 +253,21 @@ public open class AnimationNodeStateMachineTransition : Resource() { return (TransferContext.readReturnValue(STRING) as String) } - public final fun setAdvanceCondition(name: String) = - setAdvanceCondition(name.asCachedStringName()) + public final fun setAdvanceCondition(name: String): Unit = setAdvanceCondition(name.asCachedStringName()) public enum class SwitchMode( id: Long, ) { /** - * Switch to the next state immediately. The current state will end and blend into the beginning - * of the new one. + * Switch to the next state immediately. The current state will end and blend into the beginning of the new one. */ IMMEDIATE(0), /** - * Switch to the next state immediately, but will seek the new state to the playback position of - * the old state. + * Switch to the next state immediately, but will seek the new state to the playback position of the old state. */ SYNC(1), /** - * Wait for the current state playback to end, then switch to the beginning of the next state - * animation. + * Wait for the current state playback to end, then switch to the beginning of the next state animation. */ AT_END(2), ; @@ -317,8 +294,7 @@ public open class AnimationNodeStateMachineTransition : Resource() { */ ENABLED(1), /** - * Automatically use this transition if the [advanceCondition] and [advanceExpression] checks - * are `true` (if assigned). + * Automatically use this transition if the [advanceCondition] and [advanceExpression] checks are `true` (if assigned). */ AUTO(2), ; @@ -337,57 +313,57 @@ public open class AnimationNodeStateMachineTransition : Resource() { public object MethodBindings { internal val setSwitchModePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "set_switch_mode", 2074906633) + TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "set_switch_mode", 2_074_906_633) internal val getSwitchModePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "get_switch_mode", 2138562085) + TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "get_switch_mode", 2_138_562_085) internal val setAdvanceModePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "set_advance_mode", 1210869868) + TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "set_advance_mode", 1_210_869_868) internal val getAdvanceModePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "get_advance_mode", 61101689) + TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "get_advance_mode", 61_101_689) internal val setAdvanceConditionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "set_advance_condition", 3304788590) + TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "set_advance_condition", 3_304_788_590) internal val getAdvanceConditionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "get_advance_condition", 2002593661) + TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "get_advance_condition", 2_002_593_661) internal val setXfadeTimePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "set_xfade_time", 373806689) + TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "set_xfade_time", 373_806_689) internal val getXfadeTimePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "get_xfade_time", 1740695150) + TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "get_xfade_time", 1_740_695_150) internal val setXfadeCurvePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "set_xfade_curve", 270443179) + TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "set_xfade_curve", 270_443_179) internal val getXfadeCurvePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "get_xfade_curve", 2460114913) + TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "get_xfade_curve", 2_460_114_913) internal val setBreakLoopAtEndPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "set_break_loop_at_end", 2586408642) + TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "set_break_loop_at_end", 2_586_408_642) internal val isLoopBrokenAtEndPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "is_loop_broken_at_end", 36873697) + TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "is_loop_broken_at_end", 36_873_697) internal val setResetPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "set_reset", 2586408642) + TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "set_reset", 2_586_408_642) internal val isResetPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "is_reset", 36873697) + TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "is_reset", 36_873_697) internal val setPriorityPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "set_priority", 1286410249) + TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "set_priority", 1_286_410_249) internal val getPriorityPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "get_priority", 3905245786) + TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "get_priority", 3_905_245_786) internal val setAdvanceExpressionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "set_advance_expression", 83702148) + TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "set_advance_expression", 83_702_148) internal val getAdvanceExpressionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "get_advance_expression", 201670096) + TypeManager.getMethodBindPtr("AnimationNodeStateMachineTransition", "get_advance_expression", 201_670_096) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeSub2.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeSub2.kt index e1b64c28fc..18c15f3342 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeSub2.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeSub2.kt @@ -1,34 +1,24 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api import godot.`annotation`.GodotBaseType import kotlin.Int import kotlin.Suppress -import kotlin.Unit /** - * A resource to add to an [AnimationNodeBlendTree]. Blends two animations subtractively based on - * the amount value. + * A resource to add to an [AnimationNodeBlendTree]. Blends two animations subtractively based on the amount value. * - * This animation node is usually used for pre-calculation to cancel out any extra poses from the - * animation for the "add" animation source in [AnimationNodeAdd2] or [AnimationNodeAdd3]. + * This animation node is usually used for pre-calculation to cancel out any extra poses from the animation for the "add" animation source in [AnimationNodeAdd2] or [AnimationNodeAdd3]. * - * In general, the blend value should be in the `[0.0, 1.0]` range, but values outside of this range - * can be used for amplified or inverted animations. + * In general, the blend value should be in the `[0.0, 1.0]` range, but values outside of this range can be used for amplified or inverted animations. * - * **Note:** This calculation is different from using a negative value in [AnimationNodeAdd2], since - * the transformation matrices do not satisfy the commutative law. [AnimationNodeSub2] multiplies the - * transformation matrix of the inverted animation from the left side, while negative - * [AnimationNodeAdd2] multiplies it from the right side. + * **Note:** This calculation is different from using a negative value in [AnimationNodeAdd2], since the transformation matrices do not satisfy the commutative law. [AnimationNodeSub2] multiplies the transformation matrix of the inverted animation from the left side, while negative [AnimationNodeAdd2] multiplies it from the right side. */ @GodotBaseType public open class AnimationNodeSub2 : AnimationNodeSync() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(30, scriptIndex) } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeSync.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeSync.kt index b0b476e53f..0294bb9e81 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeSync.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeSync.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -15,12 +12,10 @@ import godot.core.VariantParser.NIL import kotlin.Boolean import kotlin.Int import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * An animation node used to combine, mix, or blend two or more animations together while keeping - * them synchronized within an [AnimationTree]. + * An animation node used to combine, mix, or blend two or more animations together while keeping them synchronized within an [AnimationTree]. */ @GodotBaseType public open class AnimationNodeSync : AnimationNode() { @@ -37,11 +32,11 @@ public open class AnimationNodeSync : AnimationNode() { setUseSync(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(31, scriptIndex) } - public final fun setUseSync(enable: Boolean): Unit { + public final fun setUseSync(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setUseSyncPtr, NIL) } @@ -56,9 +51,9 @@ public open class AnimationNodeSync : AnimationNode() { public object MethodBindings { internal val setUseSyncPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeSync", "set_use_sync", 2586408642) + TypeManager.getMethodBindPtr("AnimationNodeSync", "set_use_sync", 2_586_408_642) internal val isUsingSyncPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeSync", "is_using_sync", 36873697) + TypeManager.getMethodBindPtr("AnimationNodeSync", "is_using_sync", 36_873_697) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeTimeScale.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeTimeScale.kt index f0d55eb5c9..fa34beb971 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeTimeScale.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeTimeScale.kt @@ -1,23 +1,18 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api import godot.`annotation`.GodotBaseType import kotlin.Int import kotlin.Suppress -import kotlin.Unit /** - * Allows to scale the speed of the animation (or reverse it) in any child [AnimationNode]s. Setting - * it to `0.0` will pause the animation. + * Allows to scale the speed of the animation (or reverse it) in any child [AnimationNode]s. Setting it to `0.0` will pause the animation. */ @GodotBaseType public open class AnimationNodeTimeScale : AnimationNode() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(32, scriptIndex) } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeTimeSeek.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeTimeSeek.kt index 9a6ece5994..c290253e67 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeTimeSeek.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeTimeSeek.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -15,16 +12,12 @@ import godot.core.VariantParser.NIL import kotlin.Boolean import kotlin.Int import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * This animation node can be used to cause a seek command to happen to any sub-children of the - * animation graph. Use to play an [Animation] from the start or a certain playback position inside the - * [AnimationNodeBlendTree]. + * This animation node can be used to cause a seek command to happen to any sub-children of the animation graph. Use to play an [Animation] from the start or a certain playback position inside the [AnimationNodeBlendTree]. * - * After setting the time and changing the animation playback, the time seek node automatically goes - * into sleep mode on the next process frame by setting its `seek_request` value to `-1.0`. + * After setting the time and changing the animation playback, the time seek node automatically goes into sleep mode on the next process frame by setting its `seek_request` value to `-1.0`. * * ```gdscript * //gdscript @@ -51,8 +44,7 @@ import kotlin.jvm.JvmName @GodotBaseType public open class AnimationNodeTimeSeek : AnimationNode() { /** - * If `true`, some processes are executed to handle keys between seeks, such as calculating root - * motion and finding the nearest discrete key. + * If `true`, some processes are executed to handle keys between seeks, such as calculating root motion and finding the nearest discrete key. */ public final inline var explicitElapse: Boolean @JvmName("explicitElapseProperty") @@ -62,11 +54,11 @@ public open class AnimationNodeTimeSeek : AnimationNode() { setExplicitElapse(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(33, scriptIndex) } - public final fun setExplicitElapse(enable: Boolean): Unit { + public final fun setExplicitElapse(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setExplicitElapsePtr, NIL) } @@ -81,9 +73,9 @@ public open class AnimationNodeTimeSeek : AnimationNode() { public object MethodBindings { internal val setExplicitElapsePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeTimeSeek", "set_explicit_elapse", 2586408642) + TypeManager.getMethodBindPtr("AnimationNodeTimeSeek", "set_explicit_elapse", 2_586_408_642) internal val isExplicitElapsePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeTimeSeek", "is_explicit_elapse", 36873697) + TypeManager.getMethodBindPtr("AnimationNodeTimeSeek", "is_explicit_elapse", 36_873_697) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeTransition.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeTransition.kt index 84c192f0c6..5bbeb7a44b 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeTransition.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationNodeTransition.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -19,18 +16,14 @@ import kotlin.Boolean import kotlin.Double import kotlin.Int import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * Simple state machine for cases which don't require a more advanced [AnimationNodeStateMachine]. - * Animations can be connected to the inputs and transition times can be specified. + * Simple state machine for cases which don't require a more advanced [AnimationNodeStateMachine]. Animations can be connected to the inputs and transition times can be specified. * - * After setting the request and changing the animation playback, the transition node automatically - * clears the request on the next process frame by setting its `transition_request` value to empty. + * After setting the request and changing the animation playback, the transition node automatically clears the request on the next process frame by setting its `transition_request` value to empty. * - * **Note:** When using a cross-fade, `current_state` and `current_index` change to the next state - * immediately after the cross-fade begins. + * **Note:** When using a cross-fade, `current_state` and `current_index` change to the next state immediately after the cross-fade begins. * * ```gdscript * //gdscript @@ -67,10 +60,7 @@ public open class AnimationNodeTransition : AnimationNodeSync() { /** * Cross-fading time (in seconds) between each animation connected to the inputs. * - * **Note:** [AnimationNodeTransition] transitions the current state immediately after the start - * of the fading. The precise remaining time can only be inferred from the main animation. When - * [AnimationNodeOutput] is considered as the most upstream, so the [xfadeTime] is not scaled - * depending on the downstream delta. See also [AnimationNodeOneShot.fadeoutTime]. + * **Note:** [AnimationNodeTransition] transitions the current state immediately after the start of the fading. The precise remaining time can only be inferred from the main animation. When [AnimationNodeOutput] is considered as the most upstream, so the [xfadeTime] is not scaled depending on the downstream delta. See also [AnimationNodeOneShot.fadeoutTime]. */ public final inline var xfadeTime: Double @JvmName("xfadeTimeProperty") @@ -81,8 +71,7 @@ public open class AnimationNodeTransition : AnimationNodeSync() { } /** - * Determines how cross-fading between animations is eased. If empty, the transition will be - * linear. Should be a unit [Curve]. + * Determines how cross-fading between animations is eased. If empty, the transition will be linear. Should be a unit [Curve]. */ public final inline var xfadeCurve: Curve? @JvmName("xfadeCurveProperty") @@ -93,8 +82,7 @@ public open class AnimationNodeTransition : AnimationNodeSync() { } /** - * If `true`, allows transition to the self state. When the reset option is enabled in input, the - * animation is restarted. If `false`, nothing happens on the transition to the self state. + * If `true`, allows transition to the self state. When the reset option is enabled in input, the animation is restarted. If `false`, nothing happens on the transition to the self state. */ public final inline var allowTransitionToSelf: Boolean @JvmName("allowTransitionToSelfProperty") @@ -115,21 +103,19 @@ public open class AnimationNodeTransition : AnimationNodeSync() { setInputCount(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(34, scriptIndex) } - public final fun setInputCount(inputCount: Int): Unit { + public final fun setInputCount(inputCount: Int) { TransferContext.writeArguments(LONG to inputCount.toLong()) TransferContext.callMethod(ptr, MethodBindings.setInputCountPtr, NIL) } /** - * Enables or disables auto-advance for the given [input] index. If enabled, state changes to the - * next input after playing the animation once. If enabled for the last input state, it loops to the - * first. + * Enables or disables auto-advance for the given [input] index. If enabled, state changes to the next input after playing the animation once. If enabled for the last input state, it loops to the first. */ - public final fun setInputAsAutoAdvance(input: Int, enable: Boolean): Unit { + public final fun setInputAsAutoAdvance(input: Int, enable: Boolean) { TransferContext.writeArguments(LONG to input.toLong(), BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setInputAsAutoAdvancePtr, NIL) } @@ -144,10 +130,9 @@ public open class AnimationNodeTransition : AnimationNodeSync() { } /** - * If `true`, breaks the loop at the end of the loop cycle for transition, even if the animation - * is looping. + * If `true`, breaks the loop at the end of the loop cycle for transition, even if the animation is looping. */ - public final fun setInputBreakLoopAtEnd(input: Int, enable: Boolean): Unit { + public final fun setInputBreakLoopAtEnd(input: Int, enable: Boolean) { TransferContext.writeArguments(LONG to input.toLong(), BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setInputBreakLoopAtEndPtr, NIL) } @@ -164,7 +149,7 @@ public open class AnimationNodeTransition : AnimationNodeSync() { /** * If `true`, the destination animation is restarted when the animation transitions. */ - public final fun setInputReset(input: Int, enable: Boolean): Unit { + public final fun setInputReset(input: Int, enable: Boolean) { TransferContext.writeArguments(LONG to input.toLong(), BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setInputResetPtr, NIL) } @@ -178,7 +163,7 @@ public open class AnimationNodeTransition : AnimationNodeSync() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setXfadeTime(time: Double): Unit { + public final fun setXfadeTime(time: Double) { TransferContext.writeArguments(DOUBLE to time) TransferContext.callMethod(ptr, MethodBindings.setXfadeTimePtr, NIL) } @@ -189,7 +174,7 @@ public open class AnimationNodeTransition : AnimationNodeSync() { return (TransferContext.readReturnValue(DOUBLE) as Double) } - public final fun setXfadeCurve(curve: Curve?): Unit { + public final fun setXfadeCurve(curve: Curve?) { TransferContext.writeArguments(OBJECT to curve) TransferContext.callMethod(ptr, MethodBindings.setXfadeCurvePtr, NIL) } @@ -200,7 +185,7 @@ public open class AnimationNodeTransition : AnimationNodeSync() { return (TransferContext.readReturnValue(OBJECT) as Curve?) } - public final fun setAllowTransitionToSelf(enable: Boolean): Unit { + public final fun setAllowTransitionToSelf(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setAllowTransitionToSelfPtr, NIL) } @@ -215,42 +200,42 @@ public open class AnimationNodeTransition : AnimationNodeSync() { public object MethodBindings { internal val setInputCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeTransition", "set_input_count", 1286410249) + TypeManager.getMethodBindPtr("AnimationNodeTransition", "set_input_count", 1_286_410_249) internal val setInputAsAutoAdvancePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeTransition", "set_input_as_auto_advance", 300928843) + TypeManager.getMethodBindPtr("AnimationNodeTransition", "set_input_as_auto_advance", 300_928_843) internal val isInputSetAsAutoAdvancePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeTransition", "is_input_set_as_auto_advance", 1116898809) + TypeManager.getMethodBindPtr("AnimationNodeTransition", "is_input_set_as_auto_advance", 1_116_898_809) internal val setInputBreakLoopAtEndPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeTransition", "set_input_break_loop_at_end", 300928843) + TypeManager.getMethodBindPtr("AnimationNodeTransition", "set_input_break_loop_at_end", 300_928_843) internal val isInputLoopBrokenAtEndPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeTransition", "is_input_loop_broken_at_end", 1116898809) + TypeManager.getMethodBindPtr("AnimationNodeTransition", "is_input_loop_broken_at_end", 1_116_898_809) internal val setInputResetPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeTransition", "set_input_reset", 300928843) + TypeManager.getMethodBindPtr("AnimationNodeTransition", "set_input_reset", 300_928_843) internal val isInputResetPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeTransition", "is_input_reset", 1116898809) + TypeManager.getMethodBindPtr("AnimationNodeTransition", "is_input_reset", 1_116_898_809) internal val setXfadeTimePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeTransition", "set_xfade_time", 373806689) + TypeManager.getMethodBindPtr("AnimationNodeTransition", "set_xfade_time", 373_806_689) internal val getXfadeTimePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeTransition", "get_xfade_time", 1740695150) + TypeManager.getMethodBindPtr("AnimationNodeTransition", "get_xfade_time", 1_740_695_150) internal val setXfadeCurvePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeTransition", "set_xfade_curve", 270443179) + TypeManager.getMethodBindPtr("AnimationNodeTransition", "set_xfade_curve", 270_443_179) internal val getXfadeCurvePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeTransition", "get_xfade_curve", 2460114913) + TypeManager.getMethodBindPtr("AnimationNodeTransition", "get_xfade_curve", 2_460_114_913) internal val setAllowTransitionToSelfPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeTransition", "set_allow_transition_to_self", 2586408642) + TypeManager.getMethodBindPtr("AnimationNodeTransition", "set_allow_transition_to_self", 2_586_408_642) internal val isAllowTransitionToSelfPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationNodeTransition", "is_allow_transition_to_self", 36873697) + TypeManager.getMethodBindPtr("AnimationNodeTransition", "is_allow_transition_to_self", 36_873_697) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationPlayer.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationPlayer.kt index 9e9294ad83..e6786c8abb 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationPlayer.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationPlayer.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -37,17 +34,11 @@ import kotlin.jvm.JvmName import kotlin.jvm.JvmOverloads /** - * An animation player is used for general-purpose playback of animations. It contains a dictionary - * of [AnimationLibrary] resources and custom blend times between animation transitions. + * An animation player is used for general-purpose playback of animations. It contains a dictionary of [AnimationLibrary] resources and custom blend times between animation transitions. * - * Some methods and properties use a single key to reference an animation directly. These keys are - * formatted as the key for the library, followed by a forward slash, then the key for the animation - * within the library, for example `"movement/run"`. If the library's key is an empty string (known as - * the default library), the forward slash is omitted, being the same key used by the library. + * Some methods and properties use a single key to reference an animation directly. These keys are formatted as the key for the library, followed by a forward slash, then the key for the animation within the library, for example `"movement/run"`. If the library's key is an empty string (known as the default library), the forward slash is omitted, being the same key used by the library. * - * [AnimationPlayer] is better-suited than [Tween] for more complex animations, for example ones - * with non-trivial timings. It can also be used over [Tween] if the animation track editor is more - * convenient than doing it in code. + * [AnimationPlayer] is better-suited than [Tween] for more complex animations, for example ones with non-trivial timings. It can also be used over [Tween] if the animation track editor is more convenient than doing it in code. * * Updating the target properties of animations occurs at the process frame. */ @@ -59,22 +50,16 @@ public open class AnimationPlayer : AnimationMixer() { public val currentAnimationChanged: Signal1 by Signal1 /** - * Emitted when a queued animation plays after the previous animation finished. See also - * [AnimationPlayer.queue]. + * Emitted when a queued animation plays after the previous animation finished. See also [AnimationPlayer.queue]. * - * **Note:** The signal is not emitted when the animation is changed via [AnimationPlayer.play] or - * by an [AnimationTree]. + * **Note:** The signal is not emitted when the animation is changed via [AnimationPlayer.play] or by an [AnimationTree]. */ public val animationChanged: Signal2 by Signal2 /** - * The key of the currently playing animation. If no animation is playing, the property's value is - * an empty string. Changing this value does not restart the animation. See [play] for more - * information on playing animations. + * The key of the currently playing animation. If no animation is playing, the property's value is an empty string. Changing this value does not restart the animation. See [play] for more information on playing animations. * - * **Note:** While this property appears in the Inspector, it's not meant to be edited, and it's - * not saved in the scene. This property is mainly used to get the currently playing animation, and - * internally for animation playback tracks. For more information, see [Animation]. + * **Note:** While this property appears in the Inspector, it's not meant to be edited, and it's not saved in the scene. This property is mainly used to get the currently playing animation, and internally for animation playback tracks. For more information, see [Animation]. */ public final inline var currentAnimation: String @JvmName("currentAnimationProperty") @@ -85,8 +70,7 @@ public open class AnimationPlayer : AnimationMixer() { } /** - * If playing, the current animation's key, otherwise, the animation last played. When set, this - * changes the animation, but will not play it unless already playing. See also [currentAnimation]. + * If playing, the current animation's key, otherwise, the animation last played. When set, this changes the animation, but will not play it unless already playing. See also [currentAnimation]. */ public final inline var assignedAnimation: String @JvmName("assignedAnimationProperty") @@ -122,11 +106,9 @@ public open class AnimationPlayer : AnimationMixer() { get() = getCurrentAnimationPosition() /** - * If `true`, performs [AnimationMixer.capture] before playback automatically. This means just - * [playWithCapture] is executed with default arguments instead of [play]. + * If `true`, performs [AnimationMixer.capture] before playback automatically. This means just [playWithCapture] is executed with default arguments instead of [play]. * - * **Note:** Capture interpolation is only performed if the animation contains a capture track. - * See also [Animation.UPDATE_CAPTURE]. + * **Note:** Capture interpolation is only performed if the animation contains a capture track. See also [Animation.UPDATE_CAPTURE]. */ public final inline var playbackAutoCapture: Boolean @JvmName("playbackAutoCaptureProperty") @@ -139,8 +121,7 @@ public open class AnimationPlayer : AnimationMixer() { /** * See also [playWithCapture] and [AnimationMixer.capture]. * - * If [playbackAutoCaptureDuration] is negative value, the duration is set to the interval between - * the current position and the first key. + * If [playbackAutoCaptureDuration] is negative value, the duration is set to the interval between the current position and the first key. */ public final inline var playbackAutoCaptureDuration: Double @JvmName("playbackAutoCaptureDurationProperty") @@ -184,11 +165,9 @@ public open class AnimationPlayer : AnimationMixer() { } /** - * The speed scaling ratio. For example, if this value is `1`, then the animation plays at normal - * speed. If it's `0.5`, then it plays at half speed. If it's `2`, then it plays at double speed. + * The speed scaling ratio. For example, if this value is `1`, then the animation plays at normal speed. If it's `0.5`, then it plays at half speed. If it's `2`, then it plays at double speed. * - * If set to a negative value, the animation is played in reverse. If set to `0`, the animation - * will not advance. + * If set to a negative value, the animation is played in reverse. If set to `0`, the animation will not advance. */ public final inline var speedScale: Float @JvmName("speedScaleProperty") @@ -199,12 +178,9 @@ public open class AnimationPlayer : AnimationMixer() { } /** - * If `true` and the engine is running in Movie Maker mode (see [MovieWriter]), exits the engine - * with [SceneTree.quit] as soon as an animation is done playing in this [AnimationPlayer]. A message - * is printed when the engine quits for this reason. + * If `true` and the engine is running in Movie Maker mode (see [MovieWriter]), exits the engine with [SceneTree.quit] as soon as an animation is done playing in this [AnimationPlayer]. A message is printed when the engine quits for this reason. * - * **Note:** This obeys the same logic as the [signal AnimationMixer.animation_finished] signal, - * so it will not quit the engine if the animation is set to be looping. + * **Note:** This obeys the same logic as the [signal AnimationMixer.animation_finished] signal, so it will not quit the engine if the animation is set to be looping. */ public final inline var movieQuitOnFinish: Boolean @JvmName("movieQuitOnFinishProperty") @@ -214,14 +190,14 @@ public open class AnimationPlayer : AnimationMixer() { setMovieQuitOnFinishEnabled(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(35, scriptIndex) } /** * Triggers the [animationTo] animation when the [animationFrom] animation completes. */ - public final fun animationSetNext(animationFrom: StringName, animationTo: StringName): Unit { + public final fun animationSetNext(animationFrom: StringName, animationTo: StringName) { TransferContext.writeArguments(STRING_NAME to animationFrom, STRING_NAME to animationTo) TransferContext.callMethod(ptr, MethodBindings.animationSetNextPtr, NIL) } @@ -242,7 +218,7 @@ public open class AnimationPlayer : AnimationMixer() { animationFrom: StringName, animationTo: StringName, sec: Double, - ): Unit { + ) { TransferContext.writeArguments(STRING_NAME to animationFrom, STRING_NAME to animationTo, DOUBLE to sec) TransferContext.callMethod(ptr, MethodBindings.setBlendTimePtr, NIL) } @@ -256,7 +232,7 @@ public open class AnimationPlayer : AnimationMixer() { return (TransferContext.readReturnValue(DOUBLE) as Double) } - public final fun setDefaultBlendTime(sec: Double): Unit { + public final fun setDefaultBlendTime(sec: Double) { TransferContext.writeArguments(DOUBLE to sec) TransferContext.callMethod(ptr, MethodBindings.setDefaultBlendTimePtr, NIL) } @@ -267,7 +243,7 @@ public open class AnimationPlayer : AnimationMixer() { return (TransferContext.readReturnValue(DOUBLE) as Double) } - public final fun setAutoCapture(autoCapture: Boolean): Unit { + public final fun setAutoCapture(autoCapture: Boolean) { TransferContext.writeArguments(BOOL to autoCapture) TransferContext.callMethod(ptr, MethodBindings.setAutoCapturePtr, NIL) } @@ -278,7 +254,7 @@ public open class AnimationPlayer : AnimationMixer() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setAutoCaptureDuration(autoCaptureDuration: Double): Unit { + public final fun setAutoCaptureDuration(autoCaptureDuration: Double) { TransferContext.writeArguments(DOUBLE to autoCaptureDuration) TransferContext.callMethod(ptr, MethodBindings.setAutoCaptureDurationPtr, NIL) } @@ -289,8 +265,7 @@ public open class AnimationPlayer : AnimationMixer() { return (TransferContext.readReturnValue(DOUBLE) as Double) } - public final fun setAutoCaptureTransitionType(autoCaptureTransitionType: Tween.TransitionType): - Unit { + public final fun setAutoCaptureTransitionType(autoCaptureTransitionType: Tween.TransitionType) { TransferContext.writeArguments(LONG to autoCaptureTransitionType.id) TransferContext.callMethod(ptr, MethodBindings.setAutoCaptureTransitionTypePtr, NIL) } @@ -301,7 +276,7 @@ public open class AnimationPlayer : AnimationMixer() { return Tween.TransitionType.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setAutoCaptureEaseType(autoCaptureEaseType: Tween.EaseType): Unit { + public final fun setAutoCaptureEaseType(autoCaptureEaseType: Tween.EaseType) { TransferContext.writeArguments(LONG to autoCaptureEaseType.id) TransferContext.callMethod(ptr, MethodBindings.setAutoCaptureEaseTypePtr, NIL) } @@ -315,18 +290,11 @@ public open class AnimationPlayer : AnimationMixer() { /** * Plays the animation with key [name]. Custom blend times and speed can be set. * - * The [fromEnd] option only affects when switching to a new animation track, or if the same track - * but at the start or end. It does not affect resuming playback that was paused in the middle of an - * animation. If [customSpeed] is negative and [fromEnd] is `true`, the animation will play backwards - * (which is equivalent to calling [playBackwards]). + * The [fromEnd] option only affects when switching to a new animation track, or if the same track but at the start or end. It does not affect resuming playback that was paused in the middle of an animation. If [customSpeed] is negative and [fromEnd] is `true`, the animation will play backwards (which is equivalent to calling [playBackwards]). * - * The [AnimationPlayer] keeps track of its current or last played animation with - * [assignedAnimation]. If this method is called with that same animation [name], or with no [name] - * parameter, the assigned animation will resume playing if it was paused. + * The [AnimationPlayer] keeps track of its current or last played animation with [assignedAnimation]. If this method is called with that same animation [name], or with no [name] parameter, the assigned animation will resume playing if it was paused. * - * **Note:** The animation will be updated the next time the [AnimationPlayer] is processed. If - * other variables are updated at the same time this is called, they may be updated too early. To - * perform the update immediately, call `advance(0)`. + * **Note:** The animation will be updated the next time the [AnimationPlayer] is processed. If other variables are updated at the same time this is called, they may be updated too early. To perform the update immediately, call `advance(0)`. */ @JvmOverloads public final fun play( @@ -334,17 +302,15 @@ public open class AnimationPlayer : AnimationMixer() { customBlend: Double = -1.0, customSpeed: Float = 1.0f, fromEnd: Boolean = false, - ): Unit { + ) { TransferContext.writeArguments(STRING_NAME to name, DOUBLE to customBlend, DOUBLE to customSpeed.toDouble(), BOOL to fromEnd) TransferContext.callMethod(ptr, MethodBindings.playPtr, NIL) } /** - * Plays the animation with key [name] and the section starting from [startMarker] and ending on - * [endMarker]. + * Plays the animation with key [name] and the section starting from [startMarker] and ending on [endMarker]. * - * If the start marker is empty, the section starts from the beginning of the animation. If the - * end marker is empty, the section ends on the end of the animation. See also [play]. + * If the start marker is empty, the section starts from the beginning of the animation. If the end marker is empty, the section ends on the end of the animation. See also [play]. */ @JvmOverloads public final fun playSectionWithMarkers( @@ -354,19 +320,15 @@ public open class AnimationPlayer : AnimationMixer() { customBlend: Double = -1.0, customSpeed: Float = 1.0f, fromEnd: Boolean = false, - ): Unit { + ) { TransferContext.writeArguments(STRING_NAME to name, STRING_NAME to startMarker, STRING_NAME to endMarker, DOUBLE to customBlend, DOUBLE to customSpeed.toDouble(), BOOL to fromEnd) TransferContext.callMethod(ptr, MethodBindings.playSectionWithMarkersPtr, NIL) } /** - * Plays the animation with key [name] and the section starting from [startTime] and ending on - * [endTime]. See also [play]. + * Plays the animation with key [name] and the section starting from [startTime] and ending on [endTime]. See also [play]. * - * Setting [startTime] to a value outside the range of the animation means the start of the - * animation will be used instead, and setting [endTime] to a value outside the range of the - * animation means the end of the animation will be used instead. [startTime] cannot be equal to - * [endTime]. + * Setting [startTime] to a value outside the range of the animation means the start of the animation will be used instead, and setting [endTime] to a value outside the range of the animation means the end of the animation will be used instead. [startTime] cannot be equal to [endTime]. */ @JvmOverloads public final fun playSection( @@ -376,7 +338,7 @@ public open class AnimationPlayer : AnimationMixer() { customBlend: Double = -1.0, customSpeed: Float = 1.0f, fromEnd: Boolean = false, - ): Unit { + ) { TransferContext.writeArguments(STRING_NAME to name, DOUBLE to startTime, DOUBLE to endTime, DOUBLE to customBlend, DOUBLE to customSpeed.toDouble(), BOOL to fromEnd) TransferContext.callMethod(ptr, MethodBindings.playSectionPtr, NIL) } @@ -384,22 +346,18 @@ public open class AnimationPlayer : AnimationMixer() { /** * Plays the animation with key [name] in reverse. * - * This method is a shorthand for [play] with `custom_speed = -1.0` and `from_end = true`, so see - * its description for more information. + * This method is a shorthand for [play] with `custom_speed = -1.0` and `from_end = true`, so see its description for more information. */ @JvmOverloads - public final fun playBackwards(name: StringName = StringName(""), customBlend: Double = -1.0): - Unit { + public final fun playBackwards(name: StringName = StringName(""), customBlend: Double = -1.0) { TransferContext.writeArguments(STRING_NAME to name, DOUBLE to customBlend) TransferContext.callMethod(ptr, MethodBindings.playBackwardsPtr, NIL) } /** - * Plays the animation with key [name] and the section starting from [startMarker] and ending on - * [endMarker] in reverse. + * Plays the animation with key [name] and the section starting from [startMarker] and ending on [endMarker] in reverse. * - * This method is a shorthand for [playSectionWithMarkers] with `custom_speed = -1.0` and - * `from_end = true`, see its description for more information. + * This method is a shorthand for [playSectionWithMarkers] with `custom_speed = -1.0` and `from_end = true`, see its description for more information. */ @JvmOverloads public final fun playSectionWithMarkersBackwards( @@ -407,17 +365,15 @@ public open class AnimationPlayer : AnimationMixer() { startMarker: StringName = StringName(""), endMarker: StringName = StringName(""), customBlend: Double = -1.0, - ): Unit { + ) { TransferContext.writeArguments(STRING_NAME to name, STRING_NAME to startMarker, STRING_NAME to endMarker, DOUBLE to customBlend) TransferContext.callMethod(ptr, MethodBindings.playSectionWithMarkersBackwardsPtr, NIL) } /** - * Plays the animation with key [name] and the section starting from [startTime] and ending on - * [endTime] in reverse. + * Plays the animation with key [name] and the section starting from [startTime] and ending on [endTime] in reverse. * - * This method is a shorthand for [playSection] with `custom_speed = -1.0` and `from_end = true`, - * see its description for more information. + * This method is a shorthand for [playSection] with `custom_speed = -1.0` and `from_end = true`, see its description for more information. */ @JvmOverloads public final fun playSectionBackwards( @@ -425,7 +381,7 @@ public open class AnimationPlayer : AnimationMixer() { startTime: Double = -1.0, endTime: Double = -1.0, customBlend: Double = -1.0, - ): Unit { + ) { TransferContext.writeArguments(STRING_NAME to name, DOUBLE to startTime, DOUBLE to endTime, DOUBLE to customBlend) TransferContext.callMethod(ptr, MethodBindings.playSectionBackwardsPtr, NIL) } @@ -433,9 +389,7 @@ public open class AnimationPlayer : AnimationMixer() { /** * See also [AnimationMixer.capture]. * - * You can use this method to use more detailed options for capture than those performed by - * [playbackAutoCapture]. When [playbackAutoCapture] is `false`, this method is almost the same as - * the following: + * You can use this method to use more detailed options for capture than those performed by [playbackAutoCapture]. When [playbackAutoCapture] is `false`, this method is almost the same as the following: * * ``` * capture(name, duration, trans_type, ease_type) @@ -444,13 +398,9 @@ public open class AnimationPlayer : AnimationMixer() { * * If [name] is blank, it specifies [assignedAnimation]. * - * If [duration] is a negative value, the duration is set to the interval between the current - * position and the first key, when [fromEnd] is `true`, uses the interval between the current - * position and the last key instead. + * If [duration] is a negative value, the duration is set to the interval between the current position and the first key, when [fromEnd] is `true`, uses the interval between the current position and the last key instead. * - * **Note:** The [duration] takes [speedScale] into account, but [customSpeed] does not, because - * the capture cache is interpolated with the blend result and the result may contain multiple - * animations. + * **Note:** The [duration] takes [speedScale] into account, but [customSpeed] does not, because the capture cache is interpolated with the blend result and the result may contain multiple animations. */ @JvmOverloads public final fun playWithCapture( @@ -461,40 +411,36 @@ public open class AnimationPlayer : AnimationMixer() { fromEnd: Boolean = false, transType: Tween.TransitionType = Tween.TransitionType.LINEAR, easeType: Tween.EaseType = Tween.EaseType.IN, - ): Unit { + ) { TransferContext.writeArguments(STRING_NAME to name, DOUBLE to duration, DOUBLE to customBlend, DOUBLE to customSpeed.toDouble(), BOOL to fromEnd, LONG to transType.id, LONG to easeType.id) TransferContext.callMethod(ptr, MethodBindings.playWithCapturePtr, NIL) } /** - * Pauses the currently playing animation. The [currentAnimationPosition] will be kept and calling - * [play] or [playBackwards] without arguments or with the same animation name as [assignedAnimation] - * will resume the animation. + * Pauses the currently playing animation. The [currentAnimationPosition] will be kept and calling [play] or [playBackwards] without arguments or with the same animation name as [assignedAnimation] will resume the animation. * * See also [stop]. */ - public final fun pause(): Unit { + public final fun pause() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.pausePtr, NIL) } /** - * Stops the currently playing animation. The animation position is reset to `0` and the - * `custom_speed` is reset to `1.0`. See also [pause]. + * Stops the currently playing animation. The animation position is reset to `0` and the `custom_speed` is reset to `1.0`. See also [pause]. * * If [keepState] is `true`, the animation state is not updated visually. * * **Note:** The method / audio / animation playback tracks will not be processed by this method. */ @JvmOverloads - public final fun stop(keepState: Boolean = false): Unit { + public final fun stop(keepState: Boolean = false) { TransferContext.writeArguments(BOOL to keepState) TransferContext.callMethod(ptr, MethodBindings.stopPtr, NIL) } /** - * Returns `true` if an animation is currently playing (even if [speedScale] and/or `custom_speed` - * are `0`). + * Returns `true` if an animation is currently playing (even if [speedScale] and/or `custom_speed` are `0`). */ public final fun isPlaying(): Boolean { TransferContext.writeArguments() @@ -502,7 +448,7 @@ public open class AnimationPlayer : AnimationMixer() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setCurrentAnimation(animation: String): Unit { + public final fun setCurrentAnimation(animation: String) { TransferContext.writeArguments(STRING to animation) TransferContext.callMethod(ptr, MethodBindings.setCurrentAnimationPtr, NIL) } @@ -513,7 +459,7 @@ public open class AnimationPlayer : AnimationMixer() { return (TransferContext.readReturnValue(STRING) as String) } - public final fun setAssignedAnimation(animation: String): Unit { + public final fun setAssignedAnimation(animation: String) { TransferContext.writeArguments(STRING to animation) TransferContext.callMethod(ptr, MethodBindings.setAssignedAnimationPtr, NIL) } @@ -525,13 +471,11 @@ public open class AnimationPlayer : AnimationMixer() { } /** - * Queues an animation for playback once the current animation and all previously queued - * animations are done. + * Queues an animation for playback once the current animation and all previously queued animations are done. * - * **Note:** If a looped animation is currently playing, the queued animation will never play - * unless the looped animation is stopped somehow. + * **Note:** If a looped animation is currently playing, the queued animation will never play unless the looped animation is stopped somehow. */ - public final fun queue(name: StringName): Unit { + public final fun queue(name: StringName) { TransferContext.writeArguments(STRING_NAME to name) TransferContext.callMethod(ptr, MethodBindings.queuePtr, NIL) } @@ -548,12 +492,12 @@ public open class AnimationPlayer : AnimationMixer() { /** * Clears all queued, unplayed animations. */ - public final fun clearQueue(): Unit { + public final fun clearQueue() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.clearQueuePtr, NIL) } - public final fun setSpeedScale(speed: Float): Unit { + public final fun setSpeedScale(speed: Float) { TransferContext.writeArguments(DOUBLE to speed.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setSpeedScalePtr, NIL) } @@ -565,9 +509,7 @@ public open class AnimationPlayer : AnimationMixer() { } /** - * Returns the actual playing speed of current animation or `0` if not playing. This speed is the - * [speedScale] property multiplied by `custom_speed` argument specified when calling the [play] - * method. + * Returns the actual playing speed of current animation or `0` if not playing. This speed is the [speedScale] property multiplied by `custom_speed` argument specified when calling the [play] method. * * Returns a negative value if the current animation is playing backwards. */ @@ -577,7 +519,7 @@ public open class AnimationPlayer : AnimationMixer() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setAutoplay(name: String): Unit { + public final fun setAutoplay(name: String) { TransferContext.writeArguments(STRING to name) TransferContext.callMethod(ptr, MethodBindings.setAutoplayPtr, NIL) } @@ -588,7 +530,7 @@ public open class AnimationPlayer : AnimationMixer() { return (TransferContext.readReturnValue(STRING) as String) } - public final fun setMovieQuitOnFinishEnabled(enabled: Boolean): Unit { + public final fun setMovieQuitOnFinishEnabled(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setMovieQuitOnFinishEnabledPtr, NIL) } @@ -612,24 +554,20 @@ public open class AnimationPlayer : AnimationMixer() { } /** - * Changes the start and end markers of the section being played. The current playback position - * will be clamped within the new section. See also [playSectionWithMarkers]. + * Changes the start and end markers of the section being played. The current playback position will be clamped within the new section. See also [playSectionWithMarkers]. * - * If the argument is empty, the section uses the beginning or end of the animation. If both are - * empty, it means that the section is not set. + * If the argument is empty, the section uses the beginning or end of the animation. If both are empty, it means that the section is not set. */ - public final fun setSectionWithMarkers(startMarker: StringName = StringName(""), - endMarker: StringName = StringName("")): Unit { + public final fun setSectionWithMarkers(startMarker: StringName = StringName(""), endMarker: StringName = StringName("")) { TransferContext.writeArguments(STRING_NAME to startMarker, STRING_NAME to endMarker) TransferContext.callMethod(ptr, MethodBindings.setSectionWithMarkersPtr, NIL) } /** - * Changes the start and end times of the section being played. The current playback position will - * be clamped within the new section. See also [playSection]. + * Changes the start and end times of the section being played. The current playback position will be clamped within the new section. See also [playSection]. */ @JvmOverloads - public final fun setSection(startTime: Double = -1.0, endTime: Double = -1.0): Unit { + public final fun setSection(startTime: Double = -1.0, endTime: Double = -1.0) { TransferContext.writeArguments(DOUBLE to startTime, DOUBLE to endTime) TransferContext.callMethod(ptr, MethodBindings.setSectionPtr, NIL) } @@ -637,7 +575,7 @@ public open class AnimationPlayer : AnimationMixer() { /** * Resets the current section if section is set. */ - public final fun resetSection(): Unit { + public final fun resetSection() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.resetSectionPtr, NIL) } @@ -670,23 +608,18 @@ public open class AnimationPlayer : AnimationMixer() { } /** - * Seeks the animation to the [seconds] point in time (in seconds). If [update] is `true`, the - * animation updates too, otherwise it updates at process time. Events between the current frame and - * [seconds] are skipped. + * Seeks the animation to the [seconds] point in time (in seconds). If [update] is `true`, the animation updates too, otherwise it updates at process time. Events between the current frame and [seconds] are skipped. * - * If [updateOnly] is `true`, the method / audio / animation playback tracks will not be - * processed. + * If [updateOnly] is `true`, the method / audio / animation playback tracks will not be processed. * - * **Note:** Seeking to the end of the animation doesn't emit [signal - * AnimationMixer.animation_finished]. If you want to skip animation and emit the signal, use - * [AnimationMixer.advance]. + * **Note:** Seeking to the end of the animation doesn't emit [signal AnimationMixer.animation_finished]. If you want to skip animation and emit the signal, use [AnimationMixer.advance]. */ @JvmOverloads public final fun seek( seconds: Double, update: Boolean = false, updateOnly: Boolean = false, - ): Unit { + ) { TransferContext.writeArguments(DOUBLE to seconds, BOOL to update, BOOL to updateOnly) TransferContext.callMethod(ptr, MethodBindings.seekPtr, NIL) } @@ -694,7 +627,7 @@ public open class AnimationPlayer : AnimationMixer() { /** * Sets the process notification in which to update animations. */ - public final fun setProcessCallback(mode: AnimationProcessCallback): Unit { + public final fun setProcessCallback(mode: AnimationProcessCallback) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setProcessCallbackPtr, NIL) } @@ -711,7 +644,7 @@ public open class AnimationPlayer : AnimationMixer() { /** * Sets the call mode used for "Call Method" tracks. */ - public final fun setMethodCallMode(mode: AnimationMethodCallMode): Unit { + public final fun setMethodCallMode(mode: AnimationMethodCallMode) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setMethodCallModePtr, NIL) } @@ -728,7 +661,7 @@ public open class AnimationPlayer : AnimationMixer() { /** * Sets the node which node path references will travel from. */ - public final fun setRoot(path: NodePath): Unit { + public final fun setRoot(path: NodePath) { TransferContext.writeArguments(NODE_PATH to path) TransferContext.callMethod(ptr, MethodBindings.setRootPtr, NIL) } @@ -745,14 +678,12 @@ public open class AnimationPlayer : AnimationMixer() { /** * Triggers the [animationTo] animation when the [animationFrom] animation completes. */ - public final fun animationSetNext(animationFrom: String, animationTo: String) = - animationSetNext(animationFrom.asCachedStringName(), animationTo.asCachedStringName()) + public final fun animationSetNext(animationFrom: String, animationTo: String): Unit = animationSetNext(animationFrom.asCachedStringName(), animationTo.asCachedStringName()) /** * Returns the key of the animation which is queued to play after the [animationFrom] animation. */ - public final fun animationGetNext(animationFrom: String): StringName = - animationGetNext(animationFrom.asCachedStringName()) + public final fun animationGetNext(animationFrom: String): StringName = animationGetNext(animationFrom.asCachedStringName()) /** * Specifies a blend time (in seconds) between two animations, referenced by their keys. @@ -761,29 +692,21 @@ public open class AnimationPlayer : AnimationMixer() { animationFrom: String, animationTo: String, sec: Double, - ) = setBlendTime(animationFrom.asCachedStringName(), animationTo.asCachedStringName(), sec) + ): Unit = setBlendTime(animationFrom.asCachedStringName(), animationTo.asCachedStringName(), sec) /** * Returns the blend time (in seconds) between two animations, referenced by their keys. */ - public final fun getBlendTime(animationFrom: String, animationTo: String): Double = - getBlendTime(animationFrom.asCachedStringName(), animationTo.asCachedStringName()) + public final fun getBlendTime(animationFrom: String, animationTo: String): Double = getBlendTime(animationFrom.asCachedStringName(), animationTo.asCachedStringName()) /** * Plays the animation with key [name]. Custom blend times and speed can be set. * - * The [fromEnd] option only affects when switching to a new animation track, or if the same track - * but at the start or end. It does not affect resuming playback that was paused in the middle of an - * animation. If [customSpeed] is negative and [fromEnd] is `true`, the animation will play backwards - * (which is equivalent to calling [playBackwards]). + * The [fromEnd] option only affects when switching to a new animation track, or if the same track but at the start or end. It does not affect resuming playback that was paused in the middle of an animation. If [customSpeed] is negative and [fromEnd] is `true`, the animation will play backwards (which is equivalent to calling [playBackwards]). * - * The [AnimationPlayer] keeps track of its current or last played animation with - * [assignedAnimation]. If this method is called with that same animation [name], or with no [name] - * parameter, the assigned animation will resume playing if it was paused. + * The [AnimationPlayer] keeps track of its current or last played animation with [assignedAnimation]. If this method is called with that same animation [name], or with no [name] parameter, the assigned animation will resume playing if it was paused. * - * **Note:** The animation will be updated the next time the [AnimationPlayer] is processed. If - * other variables are updated at the same time this is called, they may be updated too early. To - * perform the update immediately, call `advance(0)`. + * **Note:** The animation will be updated the next time the [AnimationPlayer] is processed. If other variables are updated at the same time this is called, they may be updated too early. To perform the update immediately, call `advance(0)`. */ @JvmOverloads public final fun play( @@ -791,14 +714,12 @@ public open class AnimationPlayer : AnimationMixer() { customBlend: Double = -1.0, customSpeed: Float = 1.0f, fromEnd: Boolean = false, - ) = play(name.asCachedStringName(), customBlend, customSpeed, fromEnd) + ): Unit = play(name.asCachedStringName(), customBlend, customSpeed, fromEnd) /** - * Plays the animation with key [name] and the section starting from [startMarker] and ending on - * [endMarker]. + * Plays the animation with key [name] and the section starting from [startMarker] and ending on [endMarker]. * - * If the start marker is empty, the section starts from the beginning of the animation. If the - * end marker is empty, the section ends on the end of the animation. See also [play]. + * If the start marker is empty, the section starts from the beginning of the animation. If the end marker is empty, the section ends on the end of the animation. See also [play]. */ @JvmOverloads public final fun playSectionWithMarkers( @@ -808,17 +729,12 @@ public open class AnimationPlayer : AnimationMixer() { customBlend: Double = -1.0, customSpeed: Float = 1.0f, fromEnd: Boolean = false, - ) = - playSectionWithMarkers(name.asCachedStringName(), startMarker.asCachedStringName(), endMarker.asCachedStringName(), customBlend, customSpeed, fromEnd) + ): Unit = playSectionWithMarkers(name.asCachedStringName(), startMarker.asCachedStringName(), endMarker.asCachedStringName(), customBlend, customSpeed, fromEnd) /** - * Plays the animation with key [name] and the section starting from [startTime] and ending on - * [endTime]. See also [play]. + * Plays the animation with key [name] and the section starting from [startTime] and ending on [endTime]. See also [play]. * - * Setting [startTime] to a value outside the range of the animation means the start of the - * animation will be used instead, and setting [endTime] to a value outside the range of the - * animation means the end of the animation will be used instead. [startTime] cannot be equal to - * [endTime]. + * Setting [startTime] to a value outside the range of the animation means the start of the animation will be used instead, and setting [endTime] to a value outside the range of the animation means the end of the animation will be used instead. [startTime] cannot be equal to [endTime]. */ @JvmOverloads public final fun playSection( @@ -828,24 +744,20 @@ public open class AnimationPlayer : AnimationMixer() { customBlend: Double = -1.0, customSpeed: Float = 1.0f, fromEnd: Boolean = false, - ) = playSection(name.asCachedStringName(), startTime, endTime, customBlend, customSpeed, fromEnd) + ): Unit = playSection(name.asCachedStringName(), startTime, endTime, customBlend, customSpeed, fromEnd) /** * Plays the animation with key [name] in reverse. * - * This method is a shorthand for [play] with `custom_speed = -1.0` and `from_end = true`, so see - * its description for more information. + * This method is a shorthand for [play] with `custom_speed = -1.0` and `from_end = true`, so see its description for more information. */ @JvmOverloads - public final fun playBackwards(name: String, customBlend: Double = -1.0) = - playBackwards(name.asCachedStringName(), customBlend) + public final fun playBackwards(name: String, customBlend: Double = -1.0): Unit = playBackwards(name.asCachedStringName(), customBlend) /** - * Plays the animation with key [name] and the section starting from [startMarker] and ending on - * [endMarker] in reverse. + * Plays the animation with key [name] and the section starting from [startMarker] and ending on [endMarker] in reverse. * - * This method is a shorthand for [playSectionWithMarkers] with `custom_speed = -1.0` and - * `from_end = true`, see its description for more information. + * This method is a shorthand for [playSectionWithMarkers] with `custom_speed = -1.0` and `from_end = true`, see its description for more information. */ @JvmOverloads public final fun playSectionWithMarkersBackwards( @@ -853,15 +765,12 @@ public open class AnimationPlayer : AnimationMixer() { startMarker: String, endMarker: String, customBlend: Double = -1.0, - ) = - playSectionWithMarkersBackwards(name.asCachedStringName(), startMarker.asCachedStringName(), endMarker.asCachedStringName(), customBlend) + ): Unit = playSectionWithMarkersBackwards(name.asCachedStringName(), startMarker.asCachedStringName(), endMarker.asCachedStringName(), customBlend) /** - * Plays the animation with key [name] and the section starting from [startTime] and ending on - * [endTime] in reverse. + * Plays the animation with key [name] and the section starting from [startTime] and ending on [endTime] in reverse. * - * This method is a shorthand for [playSection] with `custom_speed = -1.0` and `from_end = true`, - * see its description for more information. + * This method is a shorthand for [playSection] with `custom_speed = -1.0` and `from_end = true`, see its description for more information. */ @JvmOverloads public final fun playSectionBackwards( @@ -869,14 +778,12 @@ public open class AnimationPlayer : AnimationMixer() { startTime: Double = -1.0, endTime: Double = -1.0, customBlend: Double = -1.0, - ) = playSectionBackwards(name.asCachedStringName(), startTime, endTime, customBlend) + ): Unit = playSectionBackwards(name.asCachedStringName(), startTime, endTime, customBlend) /** * See also [AnimationMixer.capture]. * - * You can use this method to use more detailed options for capture than those performed by - * [playbackAutoCapture]. When [playbackAutoCapture] is `false`, this method is almost the same as - * the following: + * You can use this method to use more detailed options for capture than those performed by [playbackAutoCapture]. When [playbackAutoCapture] is `false`, this method is almost the same as the following: * * ``` * capture(name, duration, trans_type, ease_type) @@ -885,13 +792,9 @@ public open class AnimationPlayer : AnimationMixer() { * * If [name] is blank, it specifies [assignedAnimation]. * - * If [duration] is a negative value, the duration is set to the interval between the current - * position and the first key, when [fromEnd] is `true`, uses the interval between the current - * position and the last key instead. + * If [duration] is a negative value, the duration is set to the interval between the current position and the first key, when [fromEnd] is `true`, uses the interval between the current position and the last key instead. * - * **Note:** The [duration] takes [speedScale] into account, but [customSpeed] does not, because - * the capture cache is interpolated with the blend result and the result may contain multiple - * animations. + * **Note:** The [duration] takes [speedScale] into account, but [customSpeed] does not, because the capture cache is interpolated with the blend result and the result may contain multiple animations. */ @JvmOverloads public final fun playWithCapture( @@ -902,32 +805,26 @@ public open class AnimationPlayer : AnimationMixer() { fromEnd: Boolean = false, transType: Tween.TransitionType = Tween.TransitionType.LINEAR, easeType: Tween.EaseType = Tween.EaseType.IN, - ) = - playWithCapture(name.asCachedStringName(), duration, customBlend, customSpeed, fromEnd, transType, easeType) + ): Unit = playWithCapture(name.asCachedStringName(), duration, customBlend, customSpeed, fromEnd, transType, easeType) /** - * Queues an animation for playback once the current animation and all previously queued - * animations are done. + * Queues an animation for playback once the current animation and all previously queued animations are done. * - * **Note:** If a looped animation is currently playing, the queued animation will never play - * unless the looped animation is stopped somehow. + * **Note:** If a looped animation is currently playing, the queued animation will never play unless the looped animation is stopped somehow. */ - public final fun queue(name: String) = queue(name.asCachedStringName()) + public final fun queue(name: String): Unit = queue(name.asCachedStringName()) /** - * Changes the start and end markers of the section being played. The current playback position - * will be clamped within the new section. See also [playSectionWithMarkers]. + * Changes the start and end markers of the section being played. The current playback position will be clamped within the new section. See also [playSectionWithMarkers]. * - * If the argument is empty, the section uses the beginning or end of the animation. If both are - * empty, it means that the section is not set. + * If the argument is empty, the section uses the beginning or end of the animation. If both are empty, it means that the section is not set. */ - public final fun setSectionWithMarkers(startMarker: String, endMarker: String) = - setSectionWithMarkers(startMarker.asCachedStringName(), endMarker.asCachedStringName()) + public final fun setSectionWithMarkers(startMarker: String, endMarker: String): Unit = setSectionWithMarkers(startMarker.asCachedStringName(), endMarker.asCachedStringName()) /** * Sets the node which node path references will travel from. */ - public final fun setRoot(path: String) = setRoot(path.asCachedNodePath()) + public final fun setRoot(path: String): Unit = setRoot(path.asCachedNodePath()) public enum class AnimationProcessCallback( id: Long, @@ -968,162 +865,162 @@ public open class AnimationPlayer : AnimationMixer() { public object MethodBindings { internal val animationSetNextPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "animation_set_next", 3740211285) + TypeManager.getMethodBindPtr("AnimationPlayer", "animation_set_next", 3_740_211_285) internal val animationGetNextPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "animation_get_next", 1965194235) + TypeManager.getMethodBindPtr("AnimationPlayer", "animation_get_next", 1_965_194_235) internal val setBlendTimePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "set_blend_time", 3231131886) + TypeManager.getMethodBindPtr("AnimationPlayer", "set_blend_time", 3_231_131_886) internal val getBlendTimePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "get_blend_time", 1958752504) + TypeManager.getMethodBindPtr("AnimationPlayer", "get_blend_time", 1_958_752_504) internal val setDefaultBlendTimePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "set_default_blend_time", 373806689) + TypeManager.getMethodBindPtr("AnimationPlayer", "set_default_blend_time", 373_806_689) internal val getDefaultBlendTimePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "get_default_blend_time", 1740695150) + TypeManager.getMethodBindPtr("AnimationPlayer", "get_default_blend_time", 1_740_695_150) internal val setAutoCapturePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "set_auto_capture", 2586408642) + TypeManager.getMethodBindPtr("AnimationPlayer", "set_auto_capture", 2_586_408_642) internal val isAutoCapturePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "is_auto_capture", 36873697) + TypeManager.getMethodBindPtr("AnimationPlayer", "is_auto_capture", 36_873_697) internal val setAutoCaptureDurationPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "set_auto_capture_duration", 373806689) + TypeManager.getMethodBindPtr("AnimationPlayer", "set_auto_capture_duration", 373_806_689) internal val getAutoCaptureDurationPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "get_auto_capture_duration", 1740695150) + TypeManager.getMethodBindPtr("AnimationPlayer", "get_auto_capture_duration", 1_740_695_150) internal val setAutoCaptureTransitionTypePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "set_auto_capture_transition_type", 1058637742) + TypeManager.getMethodBindPtr("AnimationPlayer", "set_auto_capture_transition_type", 1_058_637_742) internal val getAutoCaptureTransitionTypePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "get_auto_capture_transition_type", 3842314528) + TypeManager.getMethodBindPtr("AnimationPlayer", "get_auto_capture_transition_type", 3_842_314_528) internal val setAutoCaptureEaseTypePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "set_auto_capture_ease_type", 1208105857) + TypeManager.getMethodBindPtr("AnimationPlayer", "set_auto_capture_ease_type", 1_208_105_857) internal val getAutoCaptureEaseTypePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "get_auto_capture_ease_type", 631880200) + TypeManager.getMethodBindPtr("AnimationPlayer", "get_auto_capture_ease_type", 631_880_200) internal val playPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "play", 3118260607) + TypeManager.getMethodBindPtr("AnimationPlayer", "play", 3_118_260_607) internal val playSectionWithMarkersPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "play_section_with_markers", 1421431412) + TypeManager.getMethodBindPtr("AnimationPlayer", "play_section_with_markers", 1_421_431_412) internal val playSectionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "play_section", 284774635) + TypeManager.getMethodBindPtr("AnimationPlayer", "play_section", 284_774_635) internal val playBackwardsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "play_backwards", 2787282401) + TypeManager.getMethodBindPtr("AnimationPlayer", "play_backwards", 2_787_282_401) internal val playSectionWithMarkersBackwardsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "play_section_with_markers_backwards", 910195100) + TypeManager.getMethodBindPtr("AnimationPlayer", "play_section_with_markers_backwards", 910_195_100) internal val playSectionBackwardsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "play_section_backwards", 831955981) + TypeManager.getMethodBindPtr("AnimationPlayer", "play_section_backwards", 831_955_981) internal val playWithCapturePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "play_with_capture", 1572969103) + TypeManager.getMethodBindPtr("AnimationPlayer", "play_with_capture", 1_572_969_103) internal val pausePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "pause", 3218959716) + TypeManager.getMethodBindPtr("AnimationPlayer", "pause", 3_218_959_716) internal val stopPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "stop", 107499316) + TypeManager.getMethodBindPtr("AnimationPlayer", "stop", 107_499_316) internal val isPlayingPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "is_playing", 36873697) + TypeManager.getMethodBindPtr("AnimationPlayer", "is_playing", 36_873_697) internal val setCurrentAnimationPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "set_current_animation", 83702148) + TypeManager.getMethodBindPtr("AnimationPlayer", "set_current_animation", 83_702_148) internal val getCurrentAnimationPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "get_current_animation", 201670096) + TypeManager.getMethodBindPtr("AnimationPlayer", "get_current_animation", 201_670_096) internal val setAssignedAnimationPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "set_assigned_animation", 83702148) + TypeManager.getMethodBindPtr("AnimationPlayer", "set_assigned_animation", 83_702_148) internal val getAssignedAnimationPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "get_assigned_animation", 201670096) + TypeManager.getMethodBindPtr("AnimationPlayer", "get_assigned_animation", 201_670_096) internal val queuePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "queue", 3304788590) + TypeManager.getMethodBindPtr("AnimationPlayer", "queue", 3_304_788_590) internal val getQueuePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "get_queue", 2981934095) + TypeManager.getMethodBindPtr("AnimationPlayer", "get_queue", 2_981_934_095) internal val clearQueuePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "clear_queue", 3218959716) + TypeManager.getMethodBindPtr("AnimationPlayer", "clear_queue", 3_218_959_716) internal val setSpeedScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "set_speed_scale", 373806689) + TypeManager.getMethodBindPtr("AnimationPlayer", "set_speed_scale", 373_806_689) internal val getSpeedScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "get_speed_scale", 1740695150) + TypeManager.getMethodBindPtr("AnimationPlayer", "get_speed_scale", 1_740_695_150) internal val getPlayingSpeedPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "get_playing_speed", 1740695150) + TypeManager.getMethodBindPtr("AnimationPlayer", "get_playing_speed", 1_740_695_150) internal val setAutoplayPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "set_autoplay", 83702148) + TypeManager.getMethodBindPtr("AnimationPlayer", "set_autoplay", 83_702_148) internal val getAutoplayPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "get_autoplay", 201670096) + TypeManager.getMethodBindPtr("AnimationPlayer", "get_autoplay", 201_670_096) internal val setMovieQuitOnFinishEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "set_movie_quit_on_finish_enabled", 2586408642) + TypeManager.getMethodBindPtr("AnimationPlayer", "set_movie_quit_on_finish_enabled", 2_586_408_642) internal val isMovieQuitOnFinishEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "is_movie_quit_on_finish_enabled", 36873697) + TypeManager.getMethodBindPtr("AnimationPlayer", "is_movie_quit_on_finish_enabled", 36_873_697) internal val getCurrentAnimationPositionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "get_current_animation_position", 1740695150) + TypeManager.getMethodBindPtr("AnimationPlayer", "get_current_animation_position", 1_740_695_150) internal val getCurrentAnimationLengthPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "get_current_animation_length", 1740695150) + TypeManager.getMethodBindPtr("AnimationPlayer", "get_current_animation_length", 1_740_695_150) internal val setSectionWithMarkersPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "set_section_with_markers", 794792241) + TypeManager.getMethodBindPtr("AnimationPlayer", "set_section_with_markers", 794_792_241) internal val setSectionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "set_section", 3749779719) + TypeManager.getMethodBindPtr("AnimationPlayer", "set_section", 3_749_779_719) internal val resetSectionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "reset_section", 3218959716) + TypeManager.getMethodBindPtr("AnimationPlayer", "reset_section", 3_218_959_716) internal val getSectionStartTimePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "get_section_start_time", 1740695150) + TypeManager.getMethodBindPtr("AnimationPlayer", "get_section_start_time", 1_740_695_150) internal val getSectionEndTimePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "get_section_end_time", 1740695150) + TypeManager.getMethodBindPtr("AnimationPlayer", "get_section_end_time", 1_740_695_150) internal val hasSectionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "has_section", 36873697) + TypeManager.getMethodBindPtr("AnimationPlayer", "has_section", 36_873_697) internal val seekPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "seek", 1807872683) + TypeManager.getMethodBindPtr("AnimationPlayer", "seek", 1_807_872_683) internal val setProcessCallbackPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "set_process_callback", 1663839457) + TypeManager.getMethodBindPtr("AnimationPlayer", "set_process_callback", 1_663_839_457) internal val getProcessCallbackPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "get_process_callback", 4207496604) + TypeManager.getMethodBindPtr("AnimationPlayer", "get_process_callback", 4_207_496_604) internal val setMethodCallModePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "set_method_call_mode", 3413514846) + TypeManager.getMethodBindPtr("AnimationPlayer", "set_method_call_mode", 3_413_514_846) internal val getMethodCallModePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "get_method_call_mode", 3583380054) + TypeManager.getMethodBindPtr("AnimationPlayer", "get_method_call_mode", 3_583_380_054) internal val setRootPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "set_root", 1348162250) + TypeManager.getMethodBindPtr("AnimationPlayer", "set_root", 1_348_162_250) internal val getRootPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationPlayer", "get_root", 4075236667) + TypeManager.getMethodBindPtr("AnimationPlayer", "get_root", 4_075_236_667) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationRootNode.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationRootNode.kt index 5746b53a0d..b5a0e3515b 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationRootNode.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationRootNode.kt @@ -1,31 +1,20 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api import godot.`annotation`.GodotBaseType import kotlin.Int import kotlin.Suppress -import kotlin.Unit /** - * [AnimationRootNode] is a base class for [AnimationNode]s that hold a complete animation. A - * complete animation refers to the output of an [AnimationNodeOutput] in an [AnimationNodeBlendTree] - * or the output of another [AnimationRootNode]. Used for [AnimationTree.treeRoot] or in other - * [AnimationRootNode]s. + * [AnimationRootNode] is a base class for [AnimationNode]s that hold a complete animation. A complete animation refers to the output of an [AnimationNodeOutput] in an [AnimationNodeBlendTree] or the output of another [AnimationRootNode]. Used for [AnimationTree.treeRoot] or in other [AnimationRootNode]s. * - * Examples of built-in root nodes include [AnimationNodeBlendTree] (allows blending nodes between - * each other using various modes), [AnimationNodeStateMachine] (allows to configure blending and - * transitions between nodes using a state machine pattern), [AnimationNodeBlendSpace2D] (allows linear - * blending between **three** [AnimationNode]s), [AnimationNodeBlendSpace1D] (allows linear blending - * only between **two** [AnimationNode]s). + * Examples of built-in root nodes include [AnimationNodeBlendTree] (allows blending nodes between each other using various modes), [AnimationNodeStateMachine] (allows to configure blending and transitions between nodes using a state machine pattern), [AnimationNodeBlendSpace2D] (allows linear blending between **three** [AnimationNode]s), [AnimationNodeBlendSpace1D] (allows linear blending only between **two** [AnimationNode]s). */ @GodotBaseType public open class AnimationRootNode : AnimationNode() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(36, scriptIndex) } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationTree.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationTree.kt index 2b942f6ac3..986986199c 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationTree.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AnimationTree.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -27,10 +24,7 @@ import kotlin.jvm.JvmName /** * A node used for advanced animation transitions in an [AnimationPlayer]. * - * **Note:** When linked with an [AnimationPlayer], several properties and methods of the - * corresponding [AnimationPlayer] will not function as expected. Playback and transitions should be - * handled using only the [AnimationTree] and its constituent [AnimationNode](s). The [AnimationPlayer] - * node should be used solely for adding, deleting, and editing animations. + * **Note:** When linked with an [AnimationPlayer], several properties and methods of the corresponding [AnimationPlayer] will not function as expected. Playback and transitions should be handled using only the [AnimationTree] and its constituent [AnimationNode](s). The [AnimationPlayer] node should be used solely for adding, deleting, and editing animations. */ @GodotBaseType public open class AnimationTree : AnimationMixer() { @@ -51,8 +45,7 @@ public open class AnimationTree : AnimationMixer() { } /** - * The path to the [Node] used to evaluate the [AnimationNode] [Expression] if one is not - * explicitly specified internally. + * The path to the [Node] used to evaluate the [AnimationNode] [Expression] if one is not explicitly specified internally. */ public final inline var advanceExpressionBaseNode: NodePath @JvmName("advanceExpressionBaseNodeProperty") @@ -73,11 +66,11 @@ public open class AnimationTree : AnimationMixer() { setAnimationPlayer(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(37, scriptIndex) } - public final fun setTreeRoot(animationNode: AnimationRootNode?): Unit { + public final fun setTreeRoot(animationNode: AnimationRootNode?) { TransferContext.writeArguments(OBJECT to animationNode) TransferContext.callMethod(ptr, MethodBindings.setTreeRootPtr, NIL) } @@ -88,7 +81,7 @@ public open class AnimationTree : AnimationMixer() { return (TransferContext.readReturnValue(OBJECT) as AnimationRootNode?) } - public final fun setAdvanceExpressionBaseNode(path: NodePath): Unit { + public final fun setAdvanceExpressionBaseNode(path: NodePath) { TransferContext.writeArguments(NODE_PATH to path) TransferContext.callMethod(ptr, MethodBindings.setAdvanceExpressionBaseNodePtr, NIL) } @@ -99,7 +92,7 @@ public open class AnimationTree : AnimationMixer() { return (TransferContext.readReturnValue(NODE_PATH) as NodePath) } - public final fun setAnimationPlayer(path: NodePath): Unit { + public final fun setAnimationPlayer(path: NodePath) { TransferContext.writeArguments(NODE_PATH to path) TransferContext.callMethod(ptr, MethodBindings.setAnimationPlayerPtr, NIL) } @@ -113,7 +106,7 @@ public open class AnimationTree : AnimationMixer() { /** * Sets the process notification in which to update animations. */ - public final fun setProcessCallback(mode: AnimationProcessCallback): Unit { + public final fun setProcessCallback(mode: AnimationProcessCallback) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setProcessCallbackPtr, NIL) } @@ -127,10 +120,9 @@ public open class AnimationTree : AnimationMixer() { return AnimationProcessCallback.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setAdvanceExpressionBaseNode(path: String) = - setAdvanceExpressionBaseNode(path.asCachedNodePath()) + public final fun setAdvanceExpressionBaseNode(path: String): Unit = setAdvanceExpressionBaseNode(path.asCachedNodePath()) - public final fun setAnimationPlayer(path: String) = setAnimationPlayer(path.asCachedNodePath()) + public final fun setAnimationPlayer(path: String): Unit = setAnimationPlayer(path.asCachedNodePath()) public enum class AnimationProcessCallback( id: Long, @@ -154,27 +146,27 @@ public open class AnimationTree : AnimationMixer() { public object MethodBindings { internal val setTreeRootPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationTree", "set_tree_root", 2581683800) + TypeManager.getMethodBindPtr("AnimationTree", "set_tree_root", 2_581_683_800) internal val getTreeRootPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationTree", "get_tree_root", 4110384712) + TypeManager.getMethodBindPtr("AnimationTree", "get_tree_root", 4_110_384_712) internal val setAdvanceExpressionBaseNodePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationTree", "set_advance_expression_base_node", 1348162250) + TypeManager.getMethodBindPtr("AnimationTree", "set_advance_expression_base_node", 1_348_162_250) internal val getAdvanceExpressionBaseNodePtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationTree", "get_advance_expression_base_node", 4075236667) + TypeManager.getMethodBindPtr("AnimationTree", "get_advance_expression_base_node", 4_075_236_667) internal val setAnimationPlayerPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationTree", "set_animation_player", 1348162250) + TypeManager.getMethodBindPtr("AnimationTree", "set_animation_player", 1_348_162_250) internal val getAnimationPlayerPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationTree", "get_animation_player", 4075236667) + TypeManager.getMethodBindPtr("AnimationTree", "get_animation_player", 4_075_236_667) internal val setProcessCallbackPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationTree", "set_process_callback", 1723352826) + TypeManager.getMethodBindPtr("AnimationTree", "set_process_callback", 1_723_352_826) internal val getProcessCallbackPtr: VoidPtr = - TypeManager.getMethodBindPtr("AnimationTree", "get_process_callback", 891317132) + TypeManager.getMethodBindPtr("AnimationTree", "get_process_callback", 891_317_132) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Area2D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Area2D.kt index 49fca5d5d0..c81530691d 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Area2D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Area2D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -38,27 +35,18 @@ import kotlin.Unit import kotlin.jvm.JvmName /** - * [Area2D] is a region of 2D space defined by one or multiple [CollisionShape2D] or - * [CollisionPolygon2D] child nodes. It detects when other [CollisionObject2D]s enter or exit it, and - * it also keeps track of which collision objects haven't exited it yet (i.e. which one are overlapping - * it). + * [Area2D] is a region of 2D space defined by one or multiple [CollisionShape2D] or [CollisionPolygon2D] child nodes. It detects when other [CollisionObject2D]s enter or exit it, and it also keeps track of which collision objects haven't exited it yet (i.e. which one are overlapping it). * - * This node can also locally alter or override physics parameters (gravity, damping) and route - * audio to custom audio buses. + * This node can also locally alter or override physics parameters (gravity, damping) and route audio to custom audio buses. * - * **Note:** Areas and bodies created with [PhysicsServer2D] might not interact as expected with - * [Area2D]s, and might not emit signals or track objects correctly. + * **Note:** Areas and bodies created with [PhysicsServer2D] might not interact as expected with [Area2D]s, and might not emit signals or track objects correctly. */ @GodotBaseType public open class Area2D : CollisionObject2D() { /** - * Emitted when a [Shape2D] of the received [body] enters a shape of this area. [body] can be a - * [PhysicsBody2D] or a [TileMap]. [TileMap]s are detected if their [TileSet] has collision shapes - * configured. Requires [monitoring] to be set to `true`. + * Emitted when a [Shape2D] of the received [body] enters a shape of this area. [body] can be a [PhysicsBody2D] or a [TileMap]. [TileMap]s are detected if their [TileSet] has collision shapes configured. Requires [monitoring] to be set to `true`. * - * [localShapeIndex] and [bodyShapeIndex] contain indices of the interacting shapes from this area - * and the interacting body, respectively. [bodyRid] contains the [RID] of the body. These values can - * be used with the [PhysicsServer2D]. + * [localShapeIndex] and [bodyShapeIndex] contain indices of the interacting shapes from this area and the interacting body, respectively. [bodyRid] contains the [RID] of the body. These values can be used with the [PhysicsServer2D]. * * **Example:** Get the [CollisionShape2D] node from the shape index: * @@ -74,35 +62,26 @@ public open class Area2D : CollisionObject2D() { public val bodyShapeEntered: Signal4 by Signal4 /** - * Emitted when a [Shape2D] of the received [body] exits a shape of this area. [body] can be a - * [PhysicsBody2D] or a [TileMap]. [TileMap]s are detected if their [TileSet] has collision shapes - * configured. Requires [monitoring] to be set to `true`. + * Emitted when a [Shape2D] of the received [body] exits a shape of this area. [body] can be a [PhysicsBody2D] or a [TileMap]. [TileMap]s are detected if their [TileSet] has collision shapes configured. Requires [monitoring] to be set to `true`. * * See also [signal body_shape_entered]. */ public val bodyShapeExited: Signal4 by Signal4 /** - * Emitted when the received [body] enters this area. [body] can be a [PhysicsBody2D] or a - * [TileMap]. [TileMap]s are detected if their [TileSet] has collision shapes configured. Requires - * [monitoring] to be set to `true`. + * Emitted when the received [body] enters this area. [body] can be a [PhysicsBody2D] or a [TileMap]. [TileMap]s are detected if their [TileSet] has collision shapes configured. Requires [monitoring] to be set to `true`. */ public val bodyEntered: Signal1 by Signal1 /** - * Emitted when the received [body] exits this area. [body] can be a [PhysicsBody2D] or a - * [TileMap]. [TileMap]s are detected if their [TileSet] has collision shapes configured. Requires - * [monitoring] to be set to `true`. + * Emitted when the received [body] exits this area. [body] can be a [PhysicsBody2D] or a [TileMap]. [TileMap]s are detected if their [TileSet] has collision shapes configured. Requires [monitoring] to be set to `true`. */ public val bodyExited: Signal1 by Signal1 /** - * Emitted when a [Shape2D] of the received [area] enters a shape of this area. Requires - * [monitoring] to be set to `true`. + * Emitted when a [Shape2D] of the received [area] enters a shape of this area. Requires [monitoring] to be set to `true`. * - * [localShapeIndex] and [areaShapeIndex] contain indices of the interacting shapes from this area - * and the other area, respectively. [areaRid] contains the [RID] of the other area. These values can - * be used with the [PhysicsServer2D]. + * [localShapeIndex] and [areaShapeIndex] contain indices of the interacting shapes from this area and the other area, respectively. [areaRid] contains the [RID] of the other area. These values can be used with the [PhysicsServer2D]. * * **Example:** Get the [CollisionShape2D] node from the shape index: * @@ -118,8 +97,7 @@ public open class Area2D : CollisionObject2D() { public val areaShapeEntered: Signal4 by Signal4 /** - * Emitted when a [Shape2D] of the received [area] exits a shape of this area. Requires - * [monitoring] to be set to `true`. + * Emitted when a [Shape2D] of the received [area] exits a shape of this area. Requires [monitoring] to be set to `true`. * * See also [signal area_shape_entered]. */ @@ -158,8 +136,7 @@ public open class Area2D : CollisionObject2D() { } /** - * The area's priority. Higher priority areas are processed first. The [World2D]'s physics is - * always processed last, after all areas. + * The area's priority. Higher priority areas are processed first. The [World2D]'s physics is always processed last, after all areas. */ public final inline var priority: Int @JvmName("priorityProperty") @@ -170,8 +147,7 @@ public open class Area2D : CollisionObject2D() { } /** - * Override mode for gravity calculations within this area. See [SpaceOverride] for possible - * values. + * Override mode for gravity calculations within this area. See [SpaceOverride] for possible values. */ public final inline var gravitySpaceOverride: SpaceOverride @JvmName("gravitySpaceOverrideProperty") @@ -182,8 +158,7 @@ public open class Area2D : CollisionObject2D() { } /** - * If `true`, gravity is calculated from a point (set via [gravityPointCenter]). See also - * [gravitySpaceOverride]. + * If `true`, gravity is calculated from a point (set via [gravityPointCenter]). See also [gravitySpaceOverride]. */ public final inline var gravityPoint: Boolean @JvmName("gravityPointProperty") @@ -194,14 +169,9 @@ public open class Area2D : CollisionObject2D() { } /** - * The distance at which the gravity strength is equal to [gravity]. For example, on a planet 100 - * pixels in radius with a surface gravity of 4.0 px/s², set the [gravity] to 4.0 and the unit - * distance to 100.0. The gravity will have falloff according to the inverse square law, so in the - * example, at 200 pixels from the center the gravity will be 1.0 px/s² (twice the distance, 1/4th - * the gravity), at 50 pixels it will be 16.0 px/s² (half the distance, 4x the gravity), and so on. + * The distance at which the gravity strength is equal to [gravity]. For example, on a planet 100 pixels in radius with a surface gravity of 4.0 px/s², set the [gravity] to 4.0 and the unit distance to 100.0. The gravity will have falloff according to the inverse square law, so in the example, at 200 pixels from the center the gravity will be 1.0 px/s² (twice the distance, 1/4th the gravity), at 50 pixels it will be 16.0 px/s² (half the distance, 4x the gravity), and so on. * - * The above is true only when the unit distance is a positive number. When this is set to 0.0, - * the gravity will be constant regardless of distance. + * The above is true only when the unit distance is a positive number. When this is set to 0.0, the gravity will be constant regardless of distance. */ public final inline var gravityPointUnitDistance: Float @JvmName("gravityPointUnitDistanceProperty") @@ -215,11 +185,8 @@ public open class Area2D : CollisionObject2D() { * If gravity is a point (see [gravityPoint]), this will be the point of attraction. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var gravityPointCenter: Vector2 @@ -234,11 +201,8 @@ public open class Area2D : CollisionObject2D() { * The area's gravity vector (not normalized). * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var gravityDirection: Vector2 @@ -250,8 +214,7 @@ public open class Area2D : CollisionObject2D() { } /** - * The area's gravity intensity (in pixels per second squared). This value multiplies the gravity - * direction. This is useful to alter the force of gravity without altering its direction. + * The area's gravity intensity (in pixels per second squared). This value multiplies the gravity direction. This is useful to alter the force of gravity without altering its direction. */ public final inline var gravity: Float @JvmName("gravityProperty") @@ -262,8 +225,7 @@ public open class Area2D : CollisionObject2D() { } /** - * Override mode for linear damping calculations within this area. See [SpaceOverride] for - * possible values. + * Override mode for linear damping calculations within this area. See [SpaceOverride] for possible values. */ public final inline var linearDampSpaceOverride: SpaceOverride @JvmName("linearDampSpaceOverrideProperty") @@ -274,8 +236,7 @@ public open class Area2D : CollisionObject2D() { } /** - * The rate at which objects stop moving in this area. Represents the linear velocity lost per - * second. + * The rate at which objects stop moving in this area. Represents the linear velocity lost per second. * * See [ProjectSettings.physics/2d/defaultLinearDamp] for more details about damping. */ @@ -288,8 +249,7 @@ public open class Area2D : CollisionObject2D() { } /** - * Override mode for angular damping calculations within this area. See [SpaceOverride] for - * possible values. + * Override mode for angular damping calculations within this area. See [SpaceOverride] for possible values. */ public final inline var angularDampSpaceOverride: SpaceOverride @JvmName("angularDampSpaceOverrideProperty") @@ -300,8 +260,7 @@ public open class Area2D : CollisionObject2D() { } /** - * The rate at which objects stop spinning in this area. Represents the angular velocity lost per - * second. + * The rate at which objects stop spinning in this area. Represents the angular velocity lost per second. * * See [ProjectSettings.physics/2d/defaultAngularDamp] for more details about damping. */ @@ -335,7 +294,7 @@ public open class Area2D : CollisionObject2D() { setAudioBusName(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(38, scriptIndex) } @@ -353,8 +312,7 @@ public open class Area2D : CollisionObject2D() { * If gravity is a point (see [gravityPoint]), this will be the point of attraction. */ @CoreTypeHelper - public final fun gravityPointCenterMutate(block: Vector2.() -> Unit): Vector2 = - gravityPointCenter.apply { + public final fun gravityPointCenterMutate(block: Vector2.() -> Unit): Vector2 = gravityPointCenter.apply { block(this) gravityPointCenter = this } @@ -373,13 +331,12 @@ public open class Area2D : CollisionObject2D() { * The area's gravity vector (not normalized). */ @CoreTypeHelper - public final fun gravityDirectionMutate(block: Vector2.() -> Unit): Vector2 = - gravityDirection.apply { + public final fun gravityDirectionMutate(block: Vector2.() -> Unit): Vector2 = gravityDirection.apply { block(this) gravityDirection = this } - public final fun setGravitySpaceOverrideMode(spaceOverrideMode: SpaceOverride): Unit { + public final fun setGravitySpaceOverrideMode(spaceOverrideMode: SpaceOverride) { TransferContext.writeArguments(LONG to spaceOverrideMode.id) TransferContext.callMethod(ptr, MethodBindings.setGravitySpaceOverrideModePtr, NIL) } @@ -390,7 +347,7 @@ public open class Area2D : CollisionObject2D() { return SpaceOverride.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setGravityIsPoint(enable: Boolean): Unit { + public final fun setGravityIsPoint(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setGravityIsPointPtr, NIL) } @@ -401,7 +358,7 @@ public open class Area2D : CollisionObject2D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setGravityPointUnitDistance(distanceScale: Float): Unit { + public final fun setGravityPointUnitDistance(distanceScale: Float) { TransferContext.writeArguments(DOUBLE to distanceScale.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setGravityPointUnitDistancePtr, NIL) } @@ -412,7 +369,7 @@ public open class Area2D : CollisionObject2D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setGravityPointCenter(center: Vector2): Unit { + public final fun setGravityPointCenter(center: Vector2) { TransferContext.writeArguments(VECTOR2 to center) TransferContext.callMethod(ptr, MethodBindings.setGravityPointCenterPtr, NIL) } @@ -423,7 +380,7 @@ public open class Area2D : CollisionObject2D() { return (TransferContext.readReturnValue(VECTOR2) as Vector2) } - public final fun setGravityDirection(direction: Vector2): Unit { + public final fun setGravityDirection(direction: Vector2) { TransferContext.writeArguments(VECTOR2 to direction) TransferContext.callMethod(ptr, MethodBindings.setGravityDirectionPtr, NIL) } @@ -434,7 +391,7 @@ public open class Area2D : CollisionObject2D() { return (TransferContext.readReturnValue(VECTOR2) as Vector2) } - public final fun setGravity(gravity: Float): Unit { + public final fun setGravity(gravity: Float) { TransferContext.writeArguments(DOUBLE to gravity.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setGravityPtr, NIL) } @@ -445,7 +402,7 @@ public open class Area2D : CollisionObject2D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setLinearDampSpaceOverrideMode(spaceOverrideMode: SpaceOverride): Unit { + public final fun setLinearDampSpaceOverrideMode(spaceOverrideMode: SpaceOverride) { TransferContext.writeArguments(LONG to spaceOverrideMode.id) TransferContext.callMethod(ptr, MethodBindings.setLinearDampSpaceOverrideModePtr, NIL) } @@ -456,7 +413,7 @@ public open class Area2D : CollisionObject2D() { return SpaceOverride.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setAngularDampSpaceOverrideMode(spaceOverrideMode: SpaceOverride): Unit { + public final fun setAngularDampSpaceOverrideMode(spaceOverrideMode: SpaceOverride) { TransferContext.writeArguments(LONG to spaceOverrideMode.id) TransferContext.callMethod(ptr, MethodBindings.setAngularDampSpaceOverrideModePtr, NIL) } @@ -467,7 +424,7 @@ public open class Area2D : CollisionObject2D() { return SpaceOverride.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setLinearDamp(linearDamp: Float): Unit { + public final fun setLinearDamp(linearDamp: Float) { TransferContext.writeArguments(DOUBLE to linearDamp.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setLinearDampPtr, NIL) } @@ -478,7 +435,7 @@ public open class Area2D : CollisionObject2D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setAngularDamp(angularDamp: Float): Unit { + public final fun setAngularDamp(angularDamp: Float) { TransferContext.writeArguments(DOUBLE to angularDamp.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setAngularDampPtr, NIL) } @@ -489,7 +446,7 @@ public open class Area2D : CollisionObject2D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setPriority(priority: Int): Unit { + public final fun setPriority(priority: Int) { TransferContext.writeArguments(LONG to priority.toLong()) TransferContext.callMethod(ptr, MethodBindings.setPriorityPtr, NIL) } @@ -500,7 +457,7 @@ public open class Area2D : CollisionObject2D() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setMonitoring(enable: Boolean): Unit { + public final fun setMonitoring(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setMonitoringPtr, NIL) } @@ -511,7 +468,7 @@ public open class Area2D : CollisionObject2D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setMonitorable(enable: Boolean): Unit { + public final fun setMonitorable(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setMonitorablePtr, NIL) } @@ -523,13 +480,9 @@ public open class Area2D : CollisionObject2D() { } /** - * Returns a list of intersecting [PhysicsBody2D]s and [TileMap]s. The overlapping body's - * [CollisionObject2D.collisionLayer] must be part of this area's [CollisionObject2D.collisionMask] - * in order to be detected. + * Returns a list of intersecting [PhysicsBody2D]s and [TileMap]s. The overlapping body's [CollisionObject2D.collisionLayer] must be part of this area's [CollisionObject2D.collisionMask] in order to be detected. * - * For performance reasons (collisions are all processed at the same time) this list is modified - * once during the physics step, not immediately after objects are moved. Consider using signals - * instead. + * For performance reasons (collisions are all processed at the same time) this list is modified once during the physics step, not immediately after objects are moved. Consider using signals instead. */ public final fun getOverlappingBodies(): VariantArray { TransferContext.writeArguments() @@ -538,13 +491,9 @@ public open class Area2D : CollisionObject2D() { } /** - * Returns a list of intersecting [Area2D]s. The overlapping area's - * [CollisionObject2D.collisionLayer] must be part of this area's [CollisionObject2D.collisionMask] - * in order to be detected. + * Returns a list of intersecting [Area2D]s. The overlapping area's [CollisionObject2D.collisionLayer] must be part of this area's [CollisionObject2D.collisionMask] in order to be detected. * - * For performance reasons (collisions are all processed at the same time) this list is modified - * once during the physics step, not immediately after objects are moved. Consider using signals - * instead. + * For performance reasons (collisions are all processed at the same time) this list is modified once during the physics step, not immediately after objects are moved. Consider using signals instead. */ public final fun getOverlappingAreas(): VariantArray { TransferContext.writeArguments() @@ -553,13 +502,9 @@ public open class Area2D : CollisionObject2D() { } /** - * Returns `true` if intersecting any [PhysicsBody2D]s or [TileMap]s, otherwise returns `false`. - * The overlapping body's [CollisionObject2D.collisionLayer] must be part of this area's - * [CollisionObject2D.collisionMask] in order to be detected. + * Returns `true` if intersecting any [PhysicsBody2D]s or [TileMap]s, otherwise returns `false`. The overlapping body's [CollisionObject2D.collisionLayer] must be part of this area's [CollisionObject2D.collisionMask] in order to be detected. * - * For performance reasons (collisions are all processed at the same time) the list of overlapping - * bodies is modified once during the physics step, not immediately after objects are moved. Consider - * using signals instead. + * For performance reasons (collisions are all processed at the same time) the list of overlapping bodies is modified once during the physics step, not immediately after objects are moved. Consider using signals instead. */ public final fun hasOverlappingBodies(): Boolean { TransferContext.writeArguments() @@ -568,13 +513,9 @@ public open class Area2D : CollisionObject2D() { } /** - * Returns `true` if intersecting any [Area2D]s, otherwise returns `false`. The overlapping area's - * [CollisionObject2D.collisionLayer] must be part of this area's [CollisionObject2D.collisionMask] - * in order to be detected. + * Returns `true` if intersecting any [Area2D]s, otherwise returns `false`. The overlapping area's [CollisionObject2D.collisionLayer] must be part of this area's [CollisionObject2D.collisionMask] in order to be detected. * - * For performance reasons (collisions are all processed at the same time) the list of overlapping - * areas is modified once during the physics step, not immediately after objects are moved. Consider - * using signals instead. + * For performance reasons (collisions are all processed at the same time) the list of overlapping areas is modified once during the physics step, not immediately after objects are moved. Consider using signals instead. */ public final fun hasOverlappingAreas(): Boolean { TransferContext.writeArguments() @@ -583,15 +524,11 @@ public open class Area2D : CollisionObject2D() { } /** - * Returns `true` if the given physics body intersects or overlaps this [Area2D], `false` - * otherwise. + * Returns `true` if the given physics body intersects or overlaps this [Area2D], `false` otherwise. * - * **Note:** The result of this test is not immediate after moving objects. For performance, list - * of overlaps is updated once per frame and before the physics step. Consider using signals instead. + * **Note:** The result of this test is not immediate after moving objects. For performance, list of overlaps is updated once per frame and before the physics step. Consider using signals instead. * - * The [body] argument can either be a [PhysicsBody2D] or a [TileMap] instance. While TileMaps are - * not physics bodies themselves, they register their tiles with collision shapes as a virtual - * physics body. + * The [body] argument can either be a [PhysicsBody2D] or a [TileMap] instance. While TileMaps are not physics bodies themselves, they register their tiles with collision shapes as a virtual physics body. */ public final fun overlapsBody(body: Node?): Boolean { TransferContext.writeArguments(OBJECT to body) @@ -602,9 +539,7 @@ public open class Area2D : CollisionObject2D() { /** * Returns `true` if the given [Area2D] intersects or overlaps this [Area2D], `false` otherwise. * - * **Note:** The result of this test is not immediate after moving objects. For performance, the - * list of overlaps is updated once per frame and before the physics step. Consider using signals - * instead. + * **Note:** The result of this test is not immediate after moving objects. For performance, the list of overlaps is updated once per frame and before the physics step. Consider using signals instead. */ public final fun overlapsArea(area: Node?): Boolean { TransferContext.writeArguments(OBJECT to area) @@ -612,7 +547,7 @@ public open class Area2D : CollisionObject2D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setAudioBusName(name: StringName): Unit { + public final fun setAudioBusName(name: StringName) { TransferContext.writeArguments(STRING_NAME to name) TransferContext.callMethod(ptr, MethodBindings.setAudioBusNamePtr, NIL) } @@ -623,7 +558,7 @@ public open class Area2D : CollisionObject2D() { return (TransferContext.readReturnValue(STRING_NAME) as StringName) } - public final fun setAudioBusOverride(enable: Boolean): Unit { + public final fun setAudioBusOverride(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setAudioBusOverridePtr, NIL) } @@ -634,7 +569,7 @@ public open class Area2D : CollisionObject2D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setAudioBusName(name: String) = setAudioBusName(name.asCachedStringName()) + public final fun setAudioBusName(name: String): Unit = setAudioBusName(name.asCachedStringName()) public enum class SpaceOverride( id: Long, @@ -644,13 +579,11 @@ public open class Area2D : CollisionObject2D() { */ DISABLED(0), /** - * This area adds its gravity/damping values to whatever has been calculated so far (in - * [priority] order). + * This area adds its gravity/damping values to whatever has been calculated so far (in [priority] order). */ COMBINE(1), /** - * This area adds its gravity/damping values to whatever has been calculated so far (in - * [priority] order), ignoring any lower priority areas. + * This area adds its gravity/damping values to whatever has been calculated so far (in [priority] order), ignoring any lower priority areas. */ COMBINE_REPLACE(2), /** @@ -658,8 +591,7 @@ public open class Area2D : CollisionObject2D() { */ REPLACE(3), /** - * This area replaces any gravity/damping calculated so far (in [priority] order), but keeps - * calculating the rest of the areas. + * This area replaces any gravity/damping calculated so far (in [priority] order), but keeps calculating the rest of the areas. */ REPLACE_COMBINE(4), ; @@ -678,111 +610,111 @@ public open class Area2D : CollisionObject2D() { public object MethodBindings { internal val setGravitySpaceOverrideModePtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "set_gravity_space_override_mode", 2879900038) + TypeManager.getMethodBindPtr("Area2D", "set_gravity_space_override_mode", 2_879_900_038) internal val getGravitySpaceOverrideModePtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "get_gravity_space_override_mode", 3990256304) + TypeManager.getMethodBindPtr("Area2D", "get_gravity_space_override_mode", 3_990_256_304) internal val setGravityIsPointPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "set_gravity_is_point", 2586408642) + TypeManager.getMethodBindPtr("Area2D", "set_gravity_is_point", 2_586_408_642) internal val isGravityAPointPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "is_gravity_a_point", 36873697) + TypeManager.getMethodBindPtr("Area2D", "is_gravity_a_point", 36_873_697) internal val setGravityPointUnitDistancePtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "set_gravity_point_unit_distance", 373806689) + TypeManager.getMethodBindPtr("Area2D", "set_gravity_point_unit_distance", 373_806_689) internal val getGravityPointUnitDistancePtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "get_gravity_point_unit_distance", 1740695150) + TypeManager.getMethodBindPtr("Area2D", "get_gravity_point_unit_distance", 1_740_695_150) internal val setGravityPointCenterPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "set_gravity_point_center", 743155724) + TypeManager.getMethodBindPtr("Area2D", "set_gravity_point_center", 743_155_724) internal val getGravityPointCenterPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "get_gravity_point_center", 3341600327) + TypeManager.getMethodBindPtr("Area2D", "get_gravity_point_center", 3_341_600_327) internal val setGravityDirectionPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "set_gravity_direction", 743155724) + TypeManager.getMethodBindPtr("Area2D", "set_gravity_direction", 743_155_724) internal val getGravityDirectionPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "get_gravity_direction", 3341600327) + TypeManager.getMethodBindPtr("Area2D", "get_gravity_direction", 3_341_600_327) internal val setGravityPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "set_gravity", 373806689) + TypeManager.getMethodBindPtr("Area2D", "set_gravity", 373_806_689) internal val getGravityPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "get_gravity", 1740695150) + TypeManager.getMethodBindPtr("Area2D", "get_gravity", 1_740_695_150) internal val setLinearDampSpaceOverrideModePtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "set_linear_damp_space_override_mode", 2879900038) + TypeManager.getMethodBindPtr("Area2D", "set_linear_damp_space_override_mode", 2_879_900_038) internal val getLinearDampSpaceOverrideModePtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "get_linear_damp_space_override_mode", 3990256304) + TypeManager.getMethodBindPtr("Area2D", "get_linear_damp_space_override_mode", 3_990_256_304) internal val setAngularDampSpaceOverrideModePtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "set_angular_damp_space_override_mode", 2879900038) + TypeManager.getMethodBindPtr("Area2D", "set_angular_damp_space_override_mode", 2_879_900_038) internal val getAngularDampSpaceOverrideModePtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "get_angular_damp_space_override_mode", 3990256304) + TypeManager.getMethodBindPtr("Area2D", "get_angular_damp_space_override_mode", 3_990_256_304) internal val setLinearDampPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "set_linear_damp", 373806689) + TypeManager.getMethodBindPtr("Area2D", "set_linear_damp", 373_806_689) internal val getLinearDampPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "get_linear_damp", 1740695150) + TypeManager.getMethodBindPtr("Area2D", "get_linear_damp", 1_740_695_150) internal val setAngularDampPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "set_angular_damp", 373806689) + TypeManager.getMethodBindPtr("Area2D", "set_angular_damp", 373_806_689) internal val getAngularDampPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "get_angular_damp", 1740695150) + TypeManager.getMethodBindPtr("Area2D", "get_angular_damp", 1_740_695_150) internal val setPriorityPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "set_priority", 1286410249) + TypeManager.getMethodBindPtr("Area2D", "set_priority", 1_286_410_249) internal val getPriorityPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "get_priority", 3905245786) + TypeManager.getMethodBindPtr("Area2D", "get_priority", 3_905_245_786) internal val setMonitoringPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "set_monitoring", 2586408642) + TypeManager.getMethodBindPtr("Area2D", "set_monitoring", 2_586_408_642) internal val isMonitoringPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "is_monitoring", 36873697) + TypeManager.getMethodBindPtr("Area2D", "is_monitoring", 36_873_697) internal val setMonitorablePtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "set_monitorable", 2586408642) + TypeManager.getMethodBindPtr("Area2D", "set_monitorable", 2_586_408_642) internal val isMonitorablePtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "is_monitorable", 36873697) + TypeManager.getMethodBindPtr("Area2D", "is_monitorable", 36_873_697) internal val getOverlappingBodiesPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "get_overlapping_bodies", 3995934104) + TypeManager.getMethodBindPtr("Area2D", "get_overlapping_bodies", 3_995_934_104) internal val getOverlappingAreasPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "get_overlapping_areas", 3995934104) + TypeManager.getMethodBindPtr("Area2D", "get_overlapping_areas", 3_995_934_104) internal val hasOverlappingBodiesPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "has_overlapping_bodies", 36873697) + TypeManager.getMethodBindPtr("Area2D", "has_overlapping_bodies", 36_873_697) internal val hasOverlappingAreasPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "has_overlapping_areas", 36873697) + TypeManager.getMethodBindPtr("Area2D", "has_overlapping_areas", 36_873_697) internal val overlapsBodyPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "overlaps_body", 3093956946) + TypeManager.getMethodBindPtr("Area2D", "overlaps_body", 3_093_956_946) internal val overlapsAreaPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "overlaps_area", 3093956946) + TypeManager.getMethodBindPtr("Area2D", "overlaps_area", 3_093_956_946) internal val setAudioBusNamePtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "set_audio_bus_name", 3304788590) + TypeManager.getMethodBindPtr("Area2D", "set_audio_bus_name", 3_304_788_590) internal val getAudioBusNamePtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "get_audio_bus_name", 2002593661) + TypeManager.getMethodBindPtr("Area2D", "get_audio_bus_name", 2_002_593_661) internal val setAudioBusOverridePtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "set_audio_bus_override", 2586408642) + TypeManager.getMethodBindPtr("Area2D", "set_audio_bus_override", 2_586_408_642) internal val isOverridingAudioBusPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area2D", "is_overriding_audio_bus", 36873697) + TypeManager.getMethodBindPtr("Area2D", "is_overriding_audio_bus", 36_873_697) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Area3D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Area3D.kt index 273e6ae610..957be670c2 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Area3D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Area3D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -41,34 +38,20 @@ import kotlin.Unit import kotlin.jvm.JvmName /** - * [Area3D] is a region of 3D space defined by one or multiple [CollisionShape3D] or - * [CollisionPolygon3D] child nodes. It detects when other [CollisionObject3D]s enter or exit it, and - * it also keeps track of which collision objects haven't exited it yet (i.e. which one are overlapping - * it). + * [Area3D] is a region of 3D space defined by one or multiple [CollisionShape3D] or [CollisionPolygon3D] child nodes. It detects when other [CollisionObject3D]s enter or exit it, and it also keeps track of which collision objects haven't exited it yet (i.e. which one are overlapping it). * - * This node can also locally alter or override physics parameters (gravity, damping) and route - * audio to custom audio buses. + * This node can also locally alter or override physics parameters (gravity, damping) and route audio to custom audio buses. * - * **Note:** Areas and bodies created with [PhysicsServer3D] might not interact as expected with - * [Area3D]s, and might not emit signals or track objects correctly. + * **Note:** Areas and bodies created with [PhysicsServer3D] might not interact as expected with [Area3D]s, and might not emit signals or track objects correctly. * - * **Warning:** Using a [ConcavePolygonShape3D] inside a [CollisionShape3D] child of this node - * (created e.g. by using the **Create Trimesh Collision Sibling** option in the **Mesh** menu that - * appears when selecting a [MeshInstance3D] node) may give unexpected results, since this collision - * shape is hollow. If this is not desired, it has to be split into multiple [ConvexPolygonShape3D]s or - * primitive shapes like [BoxShape3D], or in some cases it may be replaceable by a - * [CollisionPolygon3D]. + * **Warning:** Using a [ConcavePolygonShape3D] inside a [CollisionShape3D] child of this node (created e.g. by using the **Create Trimesh Collision Sibling** option in the **Mesh** menu that appears when selecting a [MeshInstance3D] node) may give unexpected results, since this collision shape is hollow. If this is not desired, it has to be split into multiple [ConvexPolygonShape3D]s or primitive shapes like [BoxShape3D], or in some cases it may be replaceable by a [CollisionPolygon3D]. */ @GodotBaseType public open class Area3D : CollisionObject3D() { /** - * Emitted when a [Shape3D] of the received [body] enters a shape of this area. [body] can be a - * [PhysicsBody3D] or a [GridMap]. [GridMap]s are detected if their [MeshLibrary] has collision - * shapes configured. Requires [monitoring] to be set to `true`. + * Emitted when a [Shape3D] of the received [body] enters a shape of this area. [body] can be a [PhysicsBody3D] or a [GridMap]. [GridMap]s are detected if their [MeshLibrary] has collision shapes configured. Requires [monitoring] to be set to `true`. * - * [localShapeIndex] and [bodyShapeIndex] contain indices of the interacting shapes from this area - * and the interacting body, respectively. [bodyRid] contains the [RID] of the body. These values can - * be used with the [PhysicsServer3D]. + * [localShapeIndex] and [bodyShapeIndex] contain indices of the interacting shapes from this area and the interacting body, respectively. [bodyRid] contains the [RID] of the body. These values can be used with the [PhysicsServer3D]. * * **Example:** Get the [CollisionShape3D] node from the shape index: * @@ -84,35 +67,26 @@ public open class Area3D : CollisionObject3D() { public val bodyShapeEntered: Signal4 by Signal4 /** - * Emitted when a [Shape3D] of the received [body] exits a shape of this area. [body] can be a - * [PhysicsBody3D] or a [GridMap]. [GridMap]s are detected if their [MeshLibrary] has collision - * shapes configured. Requires [monitoring] to be set to `true`. + * Emitted when a [Shape3D] of the received [body] exits a shape of this area. [body] can be a [PhysicsBody3D] or a [GridMap]. [GridMap]s are detected if their [MeshLibrary] has collision shapes configured. Requires [monitoring] to be set to `true`. * * See also [signal body_shape_entered]. */ public val bodyShapeExited: Signal4 by Signal4 /** - * Emitted when the received [body] enters this area. [body] can be a [PhysicsBody3D] or a - * [GridMap]. [GridMap]s are detected if their [MeshLibrary] has collision shapes configured. - * Requires [monitoring] to be set to `true`. + * Emitted when the received [body] enters this area. [body] can be a [PhysicsBody3D] or a [GridMap]. [GridMap]s are detected if their [MeshLibrary] has collision shapes configured. Requires [monitoring] to be set to `true`. */ public val bodyEntered: Signal1 by Signal1 /** - * Emitted when the received [body] exits this area. [body] can be a [PhysicsBody3D] or a - * [GridMap]. [GridMap]s are detected if their [MeshLibrary] has collision shapes configured. - * Requires [monitoring] to be set to `true`. + * Emitted when the received [body] exits this area. [body] can be a [PhysicsBody3D] or a [GridMap]. [GridMap]s are detected if their [MeshLibrary] has collision shapes configured. Requires [monitoring] to be set to `true`. */ public val bodyExited: Signal1 by Signal1 /** - * Emitted when a [Shape3D] of the received [area] enters a shape of this area. Requires - * [monitoring] to be set to `true`. + * Emitted when a [Shape3D] of the received [area] enters a shape of this area. Requires [monitoring] to be set to `true`. * - * [localShapeIndex] and [areaShapeIndex] contain indices of the interacting shapes from this area - * and the other area, respectively. [areaRid] contains the [RID] of the other area. These values can - * be used with the [PhysicsServer3D]. + * [localShapeIndex] and [areaShapeIndex] contain indices of the interacting shapes from this area and the other area, respectively. [areaRid] contains the [RID] of the other area. These values can be used with the [PhysicsServer3D]. * * **Example:** Get the [CollisionShape3D] node from the shape index: * @@ -128,8 +102,7 @@ public open class Area3D : CollisionObject3D() { public val areaShapeEntered: Signal4 by Signal4 /** - * Emitted when a [Shape3D] of the received [area] exits a shape of this area. Requires - * [monitoring] to be set to `true`. + * Emitted when a [Shape3D] of the received [area] exits a shape of this area. Requires [monitoring] to be set to `true`. * * See also [signal area_shape_entered]. */ @@ -168,8 +141,7 @@ public open class Area3D : CollisionObject3D() { } /** - * The area's priority. Higher priority areas are processed first. The [World3D]'s physics is - * always processed last, after all areas. + * The area's priority. Higher priority areas are processed first. The [World3D]'s physics is always processed last, after all areas. */ public final inline var priority: Int @JvmName("priorityProperty") @@ -180,8 +152,7 @@ public open class Area3D : CollisionObject3D() { } /** - * Override mode for gravity calculations within this area. See [SpaceOverride] for possible - * values. + * Override mode for gravity calculations within this area. See [SpaceOverride] for possible values. */ public final inline var gravitySpaceOverride: SpaceOverride @JvmName("gravitySpaceOverrideProperty") @@ -192,8 +163,7 @@ public open class Area3D : CollisionObject3D() { } /** - * If `true`, gravity is calculated from a point (set via [gravityPointCenter]). See also - * [gravitySpaceOverride]. + * If `true`, gravity is calculated from a point (set via [gravityPointCenter]). See also [gravitySpaceOverride]. */ public final inline var gravityPoint: Boolean @JvmName("gravityPointProperty") @@ -204,14 +174,9 @@ public open class Area3D : CollisionObject3D() { } /** - * The distance at which the gravity strength is equal to [gravity]. For example, on a planet 100 - * meters in radius with a surface gravity of 4.0 m/s², set the [gravity] to 4.0 and the unit - * distance to 100.0. The gravity will have falloff according to the inverse square law, so in the - * example, at 200 meters from the center the gravity will be 1.0 m/s² (twice the distance, 1/4th the - * gravity), at 50 meters it will be 16.0 m/s² (half the distance, 4x the gravity), and so on. + * The distance at which the gravity strength is equal to [gravity]. For example, on a planet 100 meters in radius with a surface gravity of 4.0 m/s², set the [gravity] to 4.0 and the unit distance to 100.0. The gravity will have falloff according to the inverse square law, so in the example, at 200 meters from the center the gravity will be 1.0 m/s² (twice the distance, 1/4th the gravity), at 50 meters it will be 16.0 m/s² (half the distance, 4x the gravity), and so on. * - * The above is true only when the unit distance is a positive number. When this is set to 0.0, - * the gravity will be constant regardless of distance. + * The above is true only when the unit distance is a positive number. When this is set to 0.0, the gravity will be constant regardless of distance. */ public final inline var gravityPointUnitDistance: Float @JvmName("gravityPointUnitDistanceProperty") @@ -225,11 +190,8 @@ public open class Area3D : CollisionObject3D() { * If gravity is a point (see [gravityPoint]), this will be the point of attraction. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var gravityPointCenter: Vector3 @@ -244,11 +206,8 @@ public open class Area3D : CollisionObject3D() { * The area's gravity vector (not normalized). * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var gravityDirection: Vector3 @@ -260,8 +219,7 @@ public open class Area3D : CollisionObject3D() { } /** - * The area's gravity intensity (in meters per second squared). This value multiplies the gravity - * direction. This is useful to alter the force of gravity without altering its direction. + * The area's gravity intensity (in meters per second squared). This value multiplies the gravity direction. This is useful to alter the force of gravity without altering its direction. */ public final inline var gravity: Float @JvmName("gravityProperty") @@ -272,8 +230,7 @@ public open class Area3D : CollisionObject3D() { } /** - * Override mode for linear damping calculations within this area. See [SpaceOverride] for - * possible values. + * Override mode for linear damping calculations within this area. See [SpaceOverride] for possible values. */ public final inline var linearDampSpaceOverride: SpaceOverride @JvmName("linearDampSpaceOverrideProperty") @@ -284,8 +241,7 @@ public open class Area3D : CollisionObject3D() { } /** - * The rate at which objects stop moving in this area. Represents the linear velocity lost per - * second. + * The rate at which objects stop moving in this area. Represents the linear velocity lost per second. * * See [ProjectSettings.physics/3d/defaultLinearDamp] for more details about damping. */ @@ -298,8 +254,7 @@ public open class Area3D : CollisionObject3D() { } /** - * Override mode for angular damping calculations within this area. See [SpaceOverride] for - * possible values. + * Override mode for angular damping calculations within this area. See [SpaceOverride] for possible values. */ public final inline var angularDampSpaceOverride: SpaceOverride @JvmName("angularDampSpaceOverrideProperty") @@ -310,8 +265,7 @@ public open class Area3D : CollisionObject3D() { } /** - * The rate at which objects stop spinning in this area. Represents the angular velocity lost per - * second. + * The rate at which objects stop spinning in this area. Represents the angular velocity lost per second. * * See [ProjectSettings.physics/3d/defaultAngularDamp] for more details about damping. */ @@ -326,8 +280,7 @@ public open class Area3D : CollisionObject3D() { /** * The magnitude of area-specific wind force. * - * **Note:** This wind force only applies to [SoftBody3D] nodes. Other physics bodies are - * currently not affected by wind. + * **Note:** This wind force only applies to [SoftBody3D] nodes. Other physics bodies are currently not affected by wind. */ public final inline var windForceMagnitude: Float @JvmName("windForceMagnitudeProperty") @@ -340,8 +293,7 @@ public open class Area3D : CollisionObject3D() { /** * The exponential rate at which wind force decreases with distance from its origin. * - * **Note:** This wind force only applies to [SoftBody3D] nodes. Other physics bodies are - * currently not affected by wind. + * **Note:** This wind force only applies to [SoftBody3D] nodes. Other physics bodies are currently not affected by wind. */ public final inline var windAttenuationFactor: Float @JvmName("windAttenuationFactorProperty") @@ -352,12 +304,9 @@ public open class Area3D : CollisionObject3D() { } /** - * The [Node3D] which is used to specify the direction and origin of an area-specific wind force. - * The direction is opposite to the z-axis of the [Node3D]'s local transform, and its origin is the - * origin of the [Node3D]'s local transform. + * The [Node3D] which is used to specify the direction and origin of an area-specific wind force. The direction is opposite to the z-axis of the [Node3D]'s local transform, and its origin is the origin of the [Node3D]'s local transform. * - * **Note:** This wind force only applies to [SoftBody3D] nodes. Other physics bodies are - * currently not affected by wind. + * **Note:** This wind force only applies to [SoftBody3D] nodes. Other physics bodies are currently not affected by wind. */ public final inline var windSourcePath: NodePath @JvmName("windSourcePathProperty") @@ -412,8 +361,7 @@ public open class Area3D : CollisionObject3D() { } /** - * The degree to which this area applies reverb to its associated audio. Ranges from `0` to `1` - * with `0.1` precision. + * The degree to which this area applies reverb to its associated audio. Ranges from `0` to `1` with `0.1` precision. */ public final inline var reverbBusAmount: Float @JvmName("reverbBusAmountProperty") @@ -424,8 +372,7 @@ public open class Area3D : CollisionObject3D() { } /** - * The degree to which this area's reverb is a uniform effect. Ranges from `0` to `1` with `0.1` - * precision. + * The degree to which this area's reverb is a uniform effect. Ranges from `0` to `1` with `0.1` precision. */ public final inline var reverbBusUniformity: Float @JvmName("reverbBusUniformityProperty") @@ -435,7 +382,7 @@ public open class Area3D : CollisionObject3D() { setReverbUniformity(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(39, scriptIndex) } @@ -453,8 +400,7 @@ public open class Area3D : CollisionObject3D() { * If gravity is a point (see [gravityPoint]), this will be the point of attraction. */ @CoreTypeHelper - public final fun gravityPointCenterMutate(block: Vector3.() -> Unit): Vector3 = - gravityPointCenter.apply { + public final fun gravityPointCenterMutate(block: Vector3.() -> Unit): Vector3 = gravityPointCenter.apply { block(this) gravityPointCenter = this } @@ -473,13 +419,12 @@ public open class Area3D : CollisionObject3D() { * The area's gravity vector (not normalized). */ @CoreTypeHelper - public final fun gravityDirectionMutate(block: Vector3.() -> Unit): Vector3 = - gravityDirection.apply { + public final fun gravityDirectionMutate(block: Vector3.() -> Unit): Vector3 = gravityDirection.apply { block(this) gravityDirection = this } - public final fun setGravitySpaceOverrideMode(spaceOverrideMode: SpaceOverride): Unit { + public final fun setGravitySpaceOverrideMode(spaceOverrideMode: SpaceOverride) { TransferContext.writeArguments(LONG to spaceOverrideMode.id) TransferContext.callMethod(ptr, MethodBindings.setGravitySpaceOverrideModePtr, NIL) } @@ -490,7 +435,7 @@ public open class Area3D : CollisionObject3D() { return SpaceOverride.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setGravityIsPoint(enable: Boolean): Unit { + public final fun setGravityIsPoint(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setGravityIsPointPtr, NIL) } @@ -501,7 +446,7 @@ public open class Area3D : CollisionObject3D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setGravityPointUnitDistance(distanceScale: Float): Unit { + public final fun setGravityPointUnitDistance(distanceScale: Float) { TransferContext.writeArguments(DOUBLE to distanceScale.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setGravityPointUnitDistancePtr, NIL) } @@ -512,7 +457,7 @@ public open class Area3D : CollisionObject3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setGravityPointCenter(center: Vector3): Unit { + public final fun setGravityPointCenter(center: Vector3) { TransferContext.writeArguments(VECTOR3 to center) TransferContext.callMethod(ptr, MethodBindings.setGravityPointCenterPtr, NIL) } @@ -523,7 +468,7 @@ public open class Area3D : CollisionObject3D() { return (TransferContext.readReturnValue(VECTOR3) as Vector3) } - public final fun setGravityDirection(direction: Vector3): Unit { + public final fun setGravityDirection(direction: Vector3) { TransferContext.writeArguments(VECTOR3 to direction) TransferContext.callMethod(ptr, MethodBindings.setGravityDirectionPtr, NIL) } @@ -534,7 +479,7 @@ public open class Area3D : CollisionObject3D() { return (TransferContext.readReturnValue(VECTOR3) as Vector3) } - public final fun setGravity(gravity: Float): Unit { + public final fun setGravity(gravity: Float) { TransferContext.writeArguments(DOUBLE to gravity.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setGravityPtr, NIL) } @@ -545,7 +490,7 @@ public open class Area3D : CollisionObject3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setLinearDampSpaceOverrideMode(spaceOverrideMode: SpaceOverride): Unit { + public final fun setLinearDampSpaceOverrideMode(spaceOverrideMode: SpaceOverride) { TransferContext.writeArguments(LONG to spaceOverrideMode.id) TransferContext.callMethod(ptr, MethodBindings.setLinearDampSpaceOverrideModePtr, NIL) } @@ -556,7 +501,7 @@ public open class Area3D : CollisionObject3D() { return SpaceOverride.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setAngularDampSpaceOverrideMode(spaceOverrideMode: SpaceOverride): Unit { + public final fun setAngularDampSpaceOverrideMode(spaceOverrideMode: SpaceOverride) { TransferContext.writeArguments(LONG to spaceOverrideMode.id) TransferContext.callMethod(ptr, MethodBindings.setAngularDampSpaceOverrideModePtr, NIL) } @@ -567,7 +512,7 @@ public open class Area3D : CollisionObject3D() { return SpaceOverride.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setAngularDamp(angularDamp: Float): Unit { + public final fun setAngularDamp(angularDamp: Float) { TransferContext.writeArguments(DOUBLE to angularDamp.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setAngularDampPtr, NIL) } @@ -578,7 +523,7 @@ public open class Area3D : CollisionObject3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setLinearDamp(linearDamp: Float): Unit { + public final fun setLinearDamp(linearDamp: Float) { TransferContext.writeArguments(DOUBLE to linearDamp.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setLinearDampPtr, NIL) } @@ -589,7 +534,7 @@ public open class Area3D : CollisionObject3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setPriority(priority: Int): Unit { + public final fun setPriority(priority: Int) { TransferContext.writeArguments(LONG to priority.toLong()) TransferContext.callMethod(ptr, MethodBindings.setPriorityPtr, NIL) } @@ -600,7 +545,7 @@ public open class Area3D : CollisionObject3D() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setWindForceMagnitude(windForceMagnitude: Float): Unit { + public final fun setWindForceMagnitude(windForceMagnitude: Float) { TransferContext.writeArguments(DOUBLE to windForceMagnitude.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setWindForceMagnitudePtr, NIL) } @@ -611,7 +556,7 @@ public open class Area3D : CollisionObject3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setWindAttenuationFactor(windAttenuationFactor: Float): Unit { + public final fun setWindAttenuationFactor(windAttenuationFactor: Float) { TransferContext.writeArguments(DOUBLE to windAttenuationFactor.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setWindAttenuationFactorPtr, NIL) } @@ -622,7 +567,7 @@ public open class Area3D : CollisionObject3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setWindSourcePath(windSourcePath: NodePath): Unit { + public final fun setWindSourcePath(windSourcePath: NodePath) { TransferContext.writeArguments(NODE_PATH to windSourcePath) TransferContext.callMethod(ptr, MethodBindings.setWindSourcePathPtr, NIL) } @@ -633,7 +578,7 @@ public open class Area3D : CollisionObject3D() { return (TransferContext.readReturnValue(NODE_PATH) as NodePath) } - public final fun setMonitorable(enable: Boolean): Unit { + public final fun setMonitorable(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setMonitorablePtr, NIL) } @@ -644,7 +589,7 @@ public open class Area3D : CollisionObject3D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setMonitoring(enable: Boolean): Unit { + public final fun setMonitoring(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setMonitoringPtr, NIL) } @@ -656,13 +601,9 @@ public open class Area3D : CollisionObject3D() { } /** - * Returns a list of intersecting [PhysicsBody3D]s and [GridMap]s. The overlapping body's - * [CollisionObject3D.collisionLayer] must be part of this area's [CollisionObject3D.collisionMask] - * in order to be detected. + * Returns a list of intersecting [PhysicsBody3D]s and [GridMap]s. The overlapping body's [CollisionObject3D.collisionLayer] must be part of this area's [CollisionObject3D.collisionMask] in order to be detected. * - * For performance reasons (collisions are all processed at the same time) this list is modified - * once during the physics step, not immediately after objects are moved. Consider using signals - * instead. + * For performance reasons (collisions are all processed at the same time) this list is modified once during the physics step, not immediately after objects are moved. Consider using signals instead. */ public final fun getOverlappingBodies(): VariantArray { TransferContext.writeArguments() @@ -671,13 +612,9 @@ public open class Area3D : CollisionObject3D() { } /** - * Returns a list of intersecting [Area3D]s. The overlapping area's - * [CollisionObject3D.collisionLayer] must be part of this area's [CollisionObject3D.collisionMask] - * in order to be detected. + * Returns a list of intersecting [Area3D]s. The overlapping area's [CollisionObject3D.collisionLayer] must be part of this area's [CollisionObject3D.collisionMask] in order to be detected. * - * For performance reasons (collisions are all processed at the same time) this list is modified - * once during the physics step, not immediately after objects are moved. Consider using signals - * instead. + * For performance reasons (collisions are all processed at the same time) this list is modified once during the physics step, not immediately after objects are moved. Consider using signals instead. */ public final fun getOverlappingAreas(): VariantArray { TransferContext.writeArguments() @@ -686,13 +623,9 @@ public open class Area3D : CollisionObject3D() { } /** - * Returns `true` if intersecting any [PhysicsBody3D]s or [GridMap]s, otherwise returns `false`. - * The overlapping body's [CollisionObject3D.collisionLayer] must be part of this area's - * [CollisionObject3D.collisionMask] in order to be detected. + * Returns `true` if intersecting any [PhysicsBody3D]s or [GridMap]s, otherwise returns `false`. The overlapping body's [CollisionObject3D.collisionLayer] must be part of this area's [CollisionObject3D.collisionMask] in order to be detected. * - * For performance reasons (collisions are all processed at the same time) the list of overlapping - * bodies is modified once during the physics step, not immediately after objects are moved. Consider - * using signals instead. + * For performance reasons (collisions are all processed at the same time) the list of overlapping bodies is modified once during the physics step, not immediately after objects are moved. Consider using signals instead. */ public final fun hasOverlappingBodies(): Boolean { TransferContext.writeArguments() @@ -701,13 +634,9 @@ public open class Area3D : CollisionObject3D() { } /** - * Returns `true` if intersecting any [Area3D]s, otherwise returns `false`. The overlapping area's - * [CollisionObject3D.collisionLayer] must be part of this area's [CollisionObject3D.collisionMask] - * in order to be detected. + * Returns `true` if intersecting any [Area3D]s, otherwise returns `false`. The overlapping area's [CollisionObject3D.collisionLayer] must be part of this area's [CollisionObject3D.collisionMask] in order to be detected. * - * For performance reasons (collisions are all processed at the same time) the list of overlapping - * areas is modified once during the physics step, not immediately after objects are moved. Consider - * using signals instead. + * For performance reasons (collisions are all processed at the same time) the list of overlapping areas is modified once during the physics step, not immediately after objects are moved. Consider using signals instead. */ public final fun hasOverlappingAreas(): Boolean { TransferContext.writeArguments() @@ -716,15 +645,11 @@ public open class Area3D : CollisionObject3D() { } /** - * Returns `true` if the given physics body intersects or overlaps this [Area3D], `false` - * otherwise. + * Returns `true` if the given physics body intersects or overlaps this [Area3D], `false` otherwise. * - * **Note:** The result of this test is not immediate after moving objects. For performance, list - * of overlaps is updated once per frame and before the physics step. Consider using signals instead. + * **Note:** The result of this test is not immediate after moving objects. For performance, list of overlaps is updated once per frame and before the physics step. Consider using signals instead. * - * The [body] argument can either be a [PhysicsBody3D] or a [GridMap] instance. While GridMaps are - * not physics body themselves, they register their tiles with collision shapes as a virtual physics - * body. + * The [body] argument can either be a [PhysicsBody3D] or a [GridMap] instance. While GridMaps are not physics body themselves, they register their tiles with collision shapes as a virtual physics body. */ public final fun overlapsBody(body: Node?): Boolean { TransferContext.writeArguments(OBJECT to body) @@ -735,8 +660,7 @@ public open class Area3D : CollisionObject3D() { /** * Returns `true` if the given [Area3D] intersects or overlaps this [Area3D], `false` otherwise. * - * **Note:** The result of this test is not immediate after moving objects. For performance, list - * of overlaps is updated once per frame and before the physics step. Consider using signals instead. + * **Note:** The result of this test is not immediate after moving objects. For performance, list of overlaps is updated once per frame and before the physics step. Consider using signals instead. */ public final fun overlapsArea(area: Node?): Boolean { TransferContext.writeArguments(OBJECT to area) @@ -744,7 +668,7 @@ public open class Area3D : CollisionObject3D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setAudioBusOverride(enable: Boolean): Unit { + public final fun setAudioBusOverride(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setAudioBusOverridePtr, NIL) } @@ -755,7 +679,7 @@ public open class Area3D : CollisionObject3D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setAudioBusName(name: StringName): Unit { + public final fun setAudioBusName(name: StringName) { TransferContext.writeArguments(STRING_NAME to name) TransferContext.callMethod(ptr, MethodBindings.setAudioBusNamePtr, NIL) } @@ -766,7 +690,7 @@ public open class Area3D : CollisionObject3D() { return (TransferContext.readReturnValue(STRING_NAME) as StringName) } - public final fun setUseReverbBus(enable: Boolean): Unit { + public final fun setUseReverbBus(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setUseReverbBusPtr, NIL) } @@ -777,7 +701,7 @@ public open class Area3D : CollisionObject3D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setReverbBusName(name: StringName): Unit { + public final fun setReverbBusName(name: StringName) { TransferContext.writeArguments(STRING_NAME to name) TransferContext.callMethod(ptr, MethodBindings.setReverbBusNamePtr, NIL) } @@ -788,7 +712,7 @@ public open class Area3D : CollisionObject3D() { return (TransferContext.readReturnValue(STRING_NAME) as StringName) } - public final fun setReverbAmount(amount: Float): Unit { + public final fun setReverbAmount(amount: Float) { TransferContext.writeArguments(DOUBLE to amount.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setReverbAmountPtr, NIL) } @@ -799,7 +723,7 @@ public open class Area3D : CollisionObject3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setReverbUniformity(amount: Float): Unit { + public final fun setReverbUniformity(amount: Float) { TransferContext.writeArguments(DOUBLE to amount.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setReverbUniformityPtr, NIL) } @@ -810,12 +734,11 @@ public open class Area3D : CollisionObject3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setWindSourcePath(windSourcePath: String) = - setWindSourcePath(windSourcePath.asCachedNodePath()) + public final fun setWindSourcePath(windSourcePath: String): Unit = setWindSourcePath(windSourcePath.asCachedNodePath()) - public final fun setAudioBusName(name: String) = setAudioBusName(name.asCachedStringName()) + public final fun setAudioBusName(name: String): Unit = setAudioBusName(name.asCachedStringName()) - public final fun setReverbBusName(name: String) = setReverbBusName(name.asCachedStringName()) + public final fun setReverbBusName(name: String): Unit = setReverbBusName(name.asCachedStringName()) public enum class SpaceOverride( id: Long, @@ -825,13 +748,11 @@ public open class Area3D : CollisionObject3D() { */ DISABLED(0), /** - * This area adds its gravity/damping values to whatever has been calculated so far (in - * [priority] order). + * This area adds its gravity/damping values to whatever has been calculated so far (in [priority] order). */ COMBINE(1), /** - * This area adds its gravity/damping values to whatever has been calculated so far (in - * [priority] order), ignoring any lower priority areas. + * This area adds its gravity/damping values to whatever has been calculated so far (in [priority] order), ignoring any lower priority areas. */ COMBINE_REPLACE(2), /** @@ -839,8 +760,7 @@ public open class Area3D : CollisionObject3D() { */ REPLACE(3), /** - * This area replaces any gravity/damping calculated so far (in [priority] order), but keeps - * calculating the rest of the areas. + * This area replaces any gravity/damping calculated so far (in [priority] order), but keeps calculating the rest of the areas. */ REPLACE_COMBINE(4), ; @@ -859,153 +779,153 @@ public open class Area3D : CollisionObject3D() { public object MethodBindings { internal val setGravitySpaceOverrideModePtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "set_gravity_space_override_mode", 2311433571) + TypeManager.getMethodBindPtr("Area3D", "set_gravity_space_override_mode", 2_311_433_571) internal val getGravitySpaceOverrideModePtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "get_gravity_space_override_mode", 958191869) + TypeManager.getMethodBindPtr("Area3D", "get_gravity_space_override_mode", 958_191_869) internal val setGravityIsPointPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "set_gravity_is_point", 2586408642) + TypeManager.getMethodBindPtr("Area3D", "set_gravity_is_point", 2_586_408_642) internal val isGravityAPointPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "is_gravity_a_point", 36873697) + TypeManager.getMethodBindPtr("Area3D", "is_gravity_a_point", 36_873_697) internal val setGravityPointUnitDistancePtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "set_gravity_point_unit_distance", 373806689) + TypeManager.getMethodBindPtr("Area3D", "set_gravity_point_unit_distance", 373_806_689) internal val getGravityPointUnitDistancePtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "get_gravity_point_unit_distance", 1740695150) + TypeManager.getMethodBindPtr("Area3D", "get_gravity_point_unit_distance", 1_740_695_150) internal val setGravityPointCenterPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "set_gravity_point_center", 3460891852) + TypeManager.getMethodBindPtr("Area3D", "set_gravity_point_center", 3_460_891_852) internal val getGravityPointCenterPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "get_gravity_point_center", 3360562783) + TypeManager.getMethodBindPtr("Area3D", "get_gravity_point_center", 3_360_562_783) internal val setGravityDirectionPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "set_gravity_direction", 3460891852) + TypeManager.getMethodBindPtr("Area3D", "set_gravity_direction", 3_460_891_852) internal val getGravityDirectionPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "get_gravity_direction", 3360562783) + TypeManager.getMethodBindPtr("Area3D", "get_gravity_direction", 3_360_562_783) internal val setGravityPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "set_gravity", 373806689) + TypeManager.getMethodBindPtr("Area3D", "set_gravity", 373_806_689) internal val getGravityPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "get_gravity", 1740695150) + TypeManager.getMethodBindPtr("Area3D", "get_gravity", 1_740_695_150) internal val setLinearDampSpaceOverrideModePtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "set_linear_damp_space_override_mode", 2311433571) + TypeManager.getMethodBindPtr("Area3D", "set_linear_damp_space_override_mode", 2_311_433_571) internal val getLinearDampSpaceOverrideModePtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "get_linear_damp_space_override_mode", 958191869) + TypeManager.getMethodBindPtr("Area3D", "get_linear_damp_space_override_mode", 958_191_869) internal val setAngularDampSpaceOverrideModePtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "set_angular_damp_space_override_mode", 2311433571) + TypeManager.getMethodBindPtr("Area3D", "set_angular_damp_space_override_mode", 2_311_433_571) internal val getAngularDampSpaceOverrideModePtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "get_angular_damp_space_override_mode", 958191869) + TypeManager.getMethodBindPtr("Area3D", "get_angular_damp_space_override_mode", 958_191_869) internal val setAngularDampPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "set_angular_damp", 373806689) + TypeManager.getMethodBindPtr("Area3D", "set_angular_damp", 373_806_689) internal val getAngularDampPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "get_angular_damp", 1740695150) + TypeManager.getMethodBindPtr("Area3D", "get_angular_damp", 1_740_695_150) internal val setLinearDampPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "set_linear_damp", 373806689) + TypeManager.getMethodBindPtr("Area3D", "set_linear_damp", 373_806_689) internal val getLinearDampPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "get_linear_damp", 1740695150) + TypeManager.getMethodBindPtr("Area3D", "get_linear_damp", 1_740_695_150) internal val setPriorityPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "set_priority", 1286410249) + TypeManager.getMethodBindPtr("Area3D", "set_priority", 1_286_410_249) internal val getPriorityPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "get_priority", 3905245786) + TypeManager.getMethodBindPtr("Area3D", "get_priority", 3_905_245_786) internal val setWindForceMagnitudePtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "set_wind_force_magnitude", 373806689) + TypeManager.getMethodBindPtr("Area3D", "set_wind_force_magnitude", 373_806_689) internal val getWindForceMagnitudePtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "get_wind_force_magnitude", 1740695150) + TypeManager.getMethodBindPtr("Area3D", "get_wind_force_magnitude", 1_740_695_150) internal val setWindAttenuationFactorPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "set_wind_attenuation_factor", 373806689) + TypeManager.getMethodBindPtr("Area3D", "set_wind_attenuation_factor", 373_806_689) internal val getWindAttenuationFactorPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "get_wind_attenuation_factor", 1740695150) + TypeManager.getMethodBindPtr("Area3D", "get_wind_attenuation_factor", 1_740_695_150) internal val setWindSourcePathPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "set_wind_source_path", 1348162250) + TypeManager.getMethodBindPtr("Area3D", "set_wind_source_path", 1_348_162_250) internal val getWindSourcePathPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "get_wind_source_path", 4075236667) + TypeManager.getMethodBindPtr("Area3D", "get_wind_source_path", 4_075_236_667) internal val setMonitorablePtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "set_monitorable", 2586408642) + TypeManager.getMethodBindPtr("Area3D", "set_monitorable", 2_586_408_642) internal val isMonitorablePtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "is_monitorable", 36873697) + TypeManager.getMethodBindPtr("Area3D", "is_monitorable", 36_873_697) internal val setMonitoringPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "set_monitoring", 2586408642) + TypeManager.getMethodBindPtr("Area3D", "set_monitoring", 2_586_408_642) internal val isMonitoringPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "is_monitoring", 36873697) + TypeManager.getMethodBindPtr("Area3D", "is_monitoring", 36_873_697) internal val getOverlappingBodiesPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "get_overlapping_bodies", 3995934104) + TypeManager.getMethodBindPtr("Area3D", "get_overlapping_bodies", 3_995_934_104) internal val getOverlappingAreasPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "get_overlapping_areas", 3995934104) + TypeManager.getMethodBindPtr("Area3D", "get_overlapping_areas", 3_995_934_104) internal val hasOverlappingBodiesPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "has_overlapping_bodies", 36873697) + TypeManager.getMethodBindPtr("Area3D", "has_overlapping_bodies", 36_873_697) internal val hasOverlappingAreasPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "has_overlapping_areas", 36873697) + TypeManager.getMethodBindPtr("Area3D", "has_overlapping_areas", 36_873_697) internal val overlapsBodyPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "overlaps_body", 3093956946) + TypeManager.getMethodBindPtr("Area3D", "overlaps_body", 3_093_956_946) internal val overlapsAreaPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "overlaps_area", 3093956946) + TypeManager.getMethodBindPtr("Area3D", "overlaps_area", 3_093_956_946) internal val setAudioBusOverridePtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "set_audio_bus_override", 2586408642) + TypeManager.getMethodBindPtr("Area3D", "set_audio_bus_override", 2_586_408_642) internal val isOverridingAudioBusPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "is_overriding_audio_bus", 36873697) + TypeManager.getMethodBindPtr("Area3D", "is_overriding_audio_bus", 36_873_697) internal val setAudioBusNamePtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "set_audio_bus_name", 3304788590) + TypeManager.getMethodBindPtr("Area3D", "set_audio_bus_name", 3_304_788_590) internal val getAudioBusNamePtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "get_audio_bus_name", 2002593661) + TypeManager.getMethodBindPtr("Area3D", "get_audio_bus_name", 2_002_593_661) internal val setUseReverbBusPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "set_use_reverb_bus", 2586408642) + TypeManager.getMethodBindPtr("Area3D", "set_use_reverb_bus", 2_586_408_642) internal val isUsingReverbBusPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "is_using_reverb_bus", 36873697) + TypeManager.getMethodBindPtr("Area3D", "is_using_reverb_bus", 36_873_697) internal val setReverbBusNamePtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "set_reverb_bus_name", 3304788590) + TypeManager.getMethodBindPtr("Area3D", "set_reverb_bus_name", 3_304_788_590) internal val getReverbBusNamePtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "get_reverb_bus_name", 2002593661) + TypeManager.getMethodBindPtr("Area3D", "get_reverb_bus_name", 2_002_593_661) internal val setReverbAmountPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "set_reverb_amount", 373806689) + TypeManager.getMethodBindPtr("Area3D", "set_reverb_amount", 373_806_689) internal val getReverbAmountPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "get_reverb_amount", 1740695150) + TypeManager.getMethodBindPtr("Area3D", "get_reverb_amount", 1_740_695_150) internal val setReverbUniformityPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "set_reverb_uniformity", 373806689) + TypeManager.getMethodBindPtr("Area3D", "set_reverb_uniformity", 373_806_689) internal val getReverbUniformityPtr: VoidPtr = - TypeManager.getMethodBindPtr("Area3D", "get_reverb_uniformity", 1740695150) + TypeManager.getMethodBindPtr("Area3D", "get_reverb_uniformity", 1_740_695_150) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ArrayMesh.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ArrayMesh.kt index bde12de478..c4260a9c03 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ArrayMesh.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ArrayMesh.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -12,7 +9,6 @@ import godot.`annotation`.GodotBaseType import godot.`internal`.memory.TransferContext import godot.`internal`.reflection.TypeManager import godot.common.interop.VoidPtr -import godot.core.AABB import godot.core.Dictionary import godot.core.Error import godot.core.PackedByteArray @@ -40,6 +36,8 @@ import kotlin.Suppress import kotlin.Unit import kotlin.jvm.JvmName import kotlin.jvm.JvmOverloads +import godot.core.AABB as CoreAABB +import godot.core.VariantParser.AABB as VariantParserAABB /** * The [ArrayMesh] is used to construct a [Mesh] by specifying the attributes as arrays. @@ -90,8 +88,7 @@ import kotlin.jvm.JvmOverloads * * See also [ImmediateMesh], [MeshDataTool] and [SurfaceTool] for procedural geometry generation. * - * **Note:** Godot uses clockwise [url=https://learnopengl.com/Advanced-OpenGL/Face-culling]winding - * order[/url] for front faces of triangle primitive modes. + * **Note:** Godot uses clockwise [url=https://learnopengl.com/Advanced-OpenGL/Face-culling]winding order[/url] for front faces of triangle primitive modes. */ @GodotBaseType public open class ArrayMesh : Mesh() { @@ -107,18 +104,14 @@ public open class ArrayMesh : Mesh() { } /** - * Overrides the [AABB] with one defined by user for use with frustum culling. Especially useful - * to avoid unexpected culling when using a shader to offset vertices. + * Overrides the [AABB] with one defined by user for use with frustum culling. Especially useful to avoid unexpected culling when using a shader to offset vertices. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy - public final inline var customAabb: AABB + public final inline var customAabb: CoreAABB @JvmName("customAabbProperty") get() = getCustomAabb() @JvmName("customAabbProperty") @@ -127,13 +120,9 @@ public open class ArrayMesh : Mesh() { } /** - * An optional mesh which can be used for rendering shadows and the depth prepass. Can be used to - * increase performance by supplying a mesh with fused vertices and only vertex position data - * (without normals, UVs, colors, etc.). + * An optional mesh which can be used for rendering shadows and the depth prepass. Can be used to increase performance by supplying a mesh with fused vertices and only vertex position data (without normals, UVs, colors, etc.). * - * **Note:** This mesh must have exactly the same vertex positions as the source mesh (including - * the source mesh's LODs, if present). If vertex positions differ, then the mesh will not draw - * correctly. + * **Note:** This mesh must have exactly the same vertex positions as the source mesh (including the source mesh's LODs, if present). If vertex positions differ, then the mesh will not draw correctly. */ public final inline var shadowMesh: ArrayMesh? @JvmName("shadowMeshProperty") @@ -143,7 +132,7 @@ public open class ArrayMesh : Mesh() { setShadowMesh(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(40, scriptIndex) } @@ -158,20 +147,18 @@ public open class ArrayMesh : Mesh() { * arraymesh.customAabb = myCoreType * `````` * - * Overrides the [AABB] with one defined by user for use with frustum culling. Especially useful - * to avoid unexpected culling when using a shader to offset vertices. + * Overrides the [AABB] with one defined by user for use with frustum culling. Especially useful to avoid unexpected culling when using a shader to offset vertices. */ @CoreTypeHelper - public final fun customAabbMutate(block: AABB.() -> Unit): AABB = customAabb.apply { + public final fun customAabbMutate(block: CoreAABB.() -> Unit): CoreAABB = customAabb.apply { block(this) customAabb = this } /** - * Adds name for a blend shape that will be added with [addSurfaceFromArrays]. Must be called - * before surface is added. + * Adds name for a blend shape that will be added with [addSurfaceFromArrays]. Must be called before surface is added. */ - public final fun addBlendShape(name: StringName): Unit { + public final fun addBlendShape(name: StringName) { TransferContext.writeArguments(STRING_NAME to name) TransferContext.callMethod(ptr, MethodBindings.addBlendShapePtr, NIL) } @@ -197,7 +184,7 @@ public open class ArrayMesh : Mesh() { /** * Sets the name of the blend shape at this index. */ - public final fun setBlendShapeName(index: Int, name: StringName): Unit { + public final fun setBlendShapeName(index: Int, name: StringName) { TransferContext.writeArguments(LONG to index.toLong(), STRING_NAME to name) TransferContext.callMethod(ptr, MethodBindings.setBlendShapeNamePtr, NIL) } @@ -205,12 +192,12 @@ public open class ArrayMesh : Mesh() { /** * Removes all blend shapes from this [ArrayMesh]. */ - public final fun clearBlendShapes(): Unit { + public final fun clearBlendShapes() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.clearBlendShapesPtr, NIL) } - public final fun setBlendShapeMode(mode: Mesh.BlendShapeMode): Unit { + public final fun setBlendShapeMode(mode: Mesh.BlendShapeMode) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setBlendShapeModePtr, NIL) } @@ -224,34 +211,15 @@ public open class ArrayMesh : Mesh() { /** * Creates a new surface. [Mesh.getSurfaceCount] will become the `surf_idx` for this new surface. * - * Surfaces are created to be rendered using a [primitive], which may be any of the values defined - * in [Mesh.PrimitiveType]. + * Surfaces are created to be rendered using a [primitive], which may be any of the values defined in [Mesh.PrimitiveType]. * - * The [arrays] argument is an array of arrays. Each of the [Mesh.ARRAY_MAX] elements contains an - * array with some of the mesh data for this surface as described by the corresponding member of - * [Mesh.ArrayType] or `null` if it is not used by the surface. For example, `arrays[0]` is the array - * of vertices. That first vertex sub-array is always required; the others are optional. Adding an - * index array puts this surface into "index mode" where the vertex and other arrays become the - * sources of data and the index array defines the vertex order. All sub-arrays must have the same - * length as the vertex array (or be an exact multiple of the vertex array's length, when multiple - * elements of a sub-array correspond to a single vertex) or be empty, except for [Mesh.ARRAY_INDEX] - * if it is used. + * The [arrays] argument is an array of arrays. Each of the [Mesh.ARRAY_MAX] elements contains an array with some of the mesh data for this surface as described by the corresponding member of [Mesh.ArrayType] or `null` if it is not used by the surface. For example, `arrays[0]` is the array of vertices. That first vertex sub-array is always required; the others are optional. Adding an index array puts this surface into "index mode" where the vertex and other arrays become the sources of data and the index array defines the vertex order. All sub-arrays must have the same length as the vertex array (or be an exact multiple of the vertex array's length, when multiple elements of a sub-array correspond to a single vertex) or be empty, except for [Mesh.ARRAY_INDEX] if it is used. * - * The [blendShapes] argument is an array of vertex data for each blend shape. Each element is an - * array of the same structure as [arrays], but [Mesh.ARRAY_VERTEX], [Mesh.ARRAY_NORMAL], and - * [Mesh.ARRAY_TANGENT] are set if and only if they are set in [arrays] and all other entries are - * `null`. + * The [blendShapes] argument is an array of vertex data for each blend shape. Each element is an array of the same structure as [arrays], but [Mesh.ARRAY_VERTEX], [Mesh.ARRAY_NORMAL], and [Mesh.ARRAY_TANGENT] are set if and only if they are set in [arrays] and all other entries are `null`. * - * The [lods] argument is a dictionary with [float] keys and [PackedInt32Array] values. Each entry - * in the dictionary represents an LOD level of the surface, where the value is the - * [Mesh.ARRAY_INDEX] array to use for the LOD level and the key is roughly proportional to the - * distance at which the LOD stats being used. I.e., increasing the key of an LOD also increases the - * distance that the objects has to be from the camera before the LOD is used. + * The [lods] argument is a dictionary with [float] keys and [PackedInt32Array] values. Each entry in the dictionary represents an LOD level of the surface, where the value is the [Mesh.ARRAY_INDEX] array to use for the LOD level and the key is roughly proportional to the distance at which the LOD stats being used. I.e., increasing the key of an LOD also increases the distance that the objects has to be from the camera before the LOD is used. * - * The [flags] argument is the bitwise OR of, as required: One value of [Mesh.ArrayCustomFormat] - * left shifted by `ARRAY_FORMAT_CUSTOMn_SHIFT` for each custom channel in use, - * [Mesh.ARRAY_FLAG_USE_DYNAMIC_UPDATE], [Mesh.ARRAY_FLAG_USE_8_BONE_WEIGHTS], or - * [Mesh.ARRAY_FLAG_USES_EMPTY_VERTEX_ARRAY]. + * The [flags] argument is the bitwise OR of, as required: One value of [Mesh.ArrayCustomFormat] left shifted by `ARRAY_FORMAT_CUSTOMn_SHIFT` for each custom channel in use, [Mesh.ARRAY_FLAG_USE_DYNAMIC_UPDATE], [Mesh.ARRAY_FLAG_USE_8_BONE_WEIGHTS], or [Mesh.ARRAY_FLAG_USES_EMPTY_VERTEX_ARRAY]. * * **Note:** When using indices, it is recommended to only use points, lines, or triangles. */ @@ -262,7 +230,7 @@ public open class ArrayMesh : Mesh() { blendShapes: VariantArray> = godot.core.variantArrayOf(), lods: Dictionary = Dictionary(), flags: Mesh.ArrayFormat = Mesh.ArrayFormat(0), - ): Unit { + ) { TransferContext.writeArguments(LONG to primitive.id, ARRAY to arrays, ARRAY to blendShapes, DICTIONARY to lods, LONG to flags.flag) TransferContext.callMethod(ptr, MethodBindings.addSurfaceFromArraysPtr, NIL) } @@ -270,16 +238,15 @@ public open class ArrayMesh : Mesh() { /** * Removes all surfaces from this [ArrayMesh]. */ - public final fun clearSurfaces(): Unit { + public final fun clearSurfaces() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.clearSurfacesPtr, NIL) } /** - * Removes the surface at the given index from the Mesh, shifting surfaces with higher index down - * by one. + * Removes the surface at the given index from the Mesh, shifting surfaces with higher index down by one. */ - public final fun surfaceRemove(surfIdx: Int): Unit { + public final fun surfaceRemove(surfIdx: Int) { TransferContext.writeArguments(LONG to surfIdx.toLong()) TransferContext.callMethod(ptr, MethodBindings.surfaceRemovePtr, NIL) } @@ -288,7 +255,7 @@ public open class ArrayMesh : Mesh() { surfIdx: Int, offset: Int, `data`: PackedByteArray, - ): Unit { + ) { TransferContext.writeArguments(LONG to surfIdx.toLong(), LONG to offset.toLong(), PACKED_BYTE_ARRAY to data) TransferContext.callMethod(ptr, MethodBindings.surfaceUpdateVertexRegionPtr, NIL) } @@ -297,7 +264,7 @@ public open class ArrayMesh : Mesh() { surfIdx: Int, offset: Int, `data`: PackedByteArray, - ): Unit { + ) { TransferContext.writeArguments(LONG to surfIdx.toLong(), LONG to offset.toLong(), PACKED_BYTE_ARRAY to data) TransferContext.callMethod(ptr, MethodBindings.surfaceUpdateAttributeRegionPtr, NIL) } @@ -306,14 +273,13 @@ public open class ArrayMesh : Mesh() { surfIdx: Int, offset: Int, `data`: PackedByteArray, - ): Unit { + ) { TransferContext.writeArguments(LONG to surfIdx.toLong(), LONG to offset.toLong(), PACKED_BYTE_ARRAY to data) TransferContext.callMethod(ptr, MethodBindings.surfaceUpdateSkinRegionPtr, NIL) } /** - * Returns the length in vertices of the vertex array in the requested surface (see - * [addSurfaceFromArrays]). + * Returns the length in vertices of the vertex array in the requested surface (see [addSurfaceFromArrays]). */ public final fun surfaceGetArrayLen(surfIdx: Int): Int { TransferContext.writeArguments(LONG to surfIdx.toLong()) @@ -322,8 +288,7 @@ public open class ArrayMesh : Mesh() { } /** - * Returns the length in indices of the index array in the requested surface (see - * [addSurfaceFromArrays]). + * Returns the length in indices of the index array in the requested surface (see [addSurfaceFromArrays]). */ public final fun surfaceGetArrayIndexLen(surfIdx: Int): Int { TransferContext.writeArguments(LONG to surfIdx.toLong()) @@ -350,8 +315,7 @@ public open class ArrayMesh : Mesh() { } /** - * Returns the index of the first surface with this name held within this [ArrayMesh]. If none are - * found, -1 is returned. + * Returns the index of the first surface with this name held within this [ArrayMesh]. If none are found, -1 is returned. */ public final fun surfaceFindByName(name: String): Int { TransferContext.writeArguments(STRING to name) @@ -362,7 +326,7 @@ public open class ArrayMesh : Mesh() { /** * Sets a name for a given surface. */ - public final fun surfaceSetName(surfIdx: Int, name: String): Unit { + public final fun surfaceSetName(surfIdx: Int, name: String) { TransferContext.writeArguments(LONG to surfIdx.toLong(), STRING to name) TransferContext.callMethod(ptr, MethodBindings.surfaceSetNamePtr, NIL) } @@ -379,7 +343,7 @@ public open class ArrayMesh : Mesh() { /** * Regenerates tangents for each of the [ArrayMesh]'s surfaces. */ - public final fun regenNormalMaps(): Unit { + public final fun regenNormalMaps() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.regenNormalMapsPtr, NIL) } @@ -393,18 +357,18 @@ public open class ArrayMesh : Mesh() { return Error.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setCustomAabb(aabb: AABB): Unit { - TransferContext.writeArguments(godot.core.VariantParser.AABB to aabb) + public final fun setCustomAabb(aabb: CoreAABB) { + TransferContext.writeArguments(VariantParserAABB to aabb) TransferContext.callMethod(ptr, MethodBindings.setCustomAabbPtr, NIL) } - public final fun getCustomAabb(): AABB { + public final fun getCustomAabb(): CoreAABB { TransferContext.writeArguments() - TransferContext.callMethod(ptr, MethodBindings.getCustomAabbPtr, godot.core.VariantParser.AABB) - return (TransferContext.readReturnValue(godot.core.VariantParser.AABB) as AABB) + TransferContext.callMethod(ptr, MethodBindings.getCustomAabbPtr, VariantParserAABB) + return (TransferContext.readReturnValue(VariantParserAABB) as CoreAABB) } - public final fun setShadowMesh(mesh: ArrayMesh?): Unit { + public final fun setShadowMesh(mesh: ArrayMesh?) { TransferContext.writeArguments(OBJECT to mesh) TransferContext.callMethod(ptr, MethodBindings.setShadowMeshPtr, NIL) } @@ -418,192 +382,190 @@ public open class ArrayMesh : Mesh() { /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _getSurfaceCount(): Int { + override fun _getSurfaceCount(): Int { throw NotImplementedError("ArrayMesh::_getSurfaceCount can't be called from the JVM.") } /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _surfaceGetArrayLen(index: Int): Int { + override fun _surfaceGetArrayLen(index: Int): Int { throw NotImplementedError("ArrayMesh::_surfaceGetArrayLen can't be called from the JVM.") } /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _surfaceGetArrayIndexLen(index: Int): Int { + override fun _surfaceGetArrayIndexLen(index: Int): Int { throw NotImplementedError("ArrayMesh::_surfaceGetArrayIndexLen can't be called from the JVM.") } /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _surfaceGetArrays(index: Int): VariantArray { + override fun _surfaceGetArrays(index: Int): VariantArray { throw NotImplementedError("ArrayMesh::_surfaceGetArrays can't be called from the JVM.") } /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _surfaceGetBlendShapeArrays(index: Int): VariantArray> { + override fun _surfaceGetBlendShapeArrays(index: Int): VariantArray> { throw NotImplementedError("ArrayMesh::_surfaceGetBlendShapeArrays can't be called from the JVM.") } /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _surfaceGetLods(index: Int): Dictionary { + override fun _surfaceGetLods(index: Int): Dictionary { throw NotImplementedError("ArrayMesh::_surfaceGetLods can't be called from the JVM.") } /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _surfaceGetFormat(index: Int): Long { + override fun _surfaceGetFormat(index: Int): Long { throw NotImplementedError("ArrayMesh::_surfaceGetFormat can't be called from the JVM.") } /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _surfaceGetPrimitiveType(index: Int): Long { + override fun _surfaceGetPrimitiveType(index: Int): Long { throw NotImplementedError("ArrayMesh::_surfaceGetPrimitiveType can't be called from the JVM.") } /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _surfaceSetMaterial(index: Int, material: Material?): Unit { + override fun _surfaceSetMaterial(index: Int, material: Material?) { throw NotImplementedError("ArrayMesh::_surfaceSetMaterial can't be called from the JVM.") } /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _surfaceGetMaterial(index: Int): Material? { + override fun _surfaceGetMaterial(index: Int): Material? { throw NotImplementedError("ArrayMesh::_surfaceGetMaterial can't be called from the JVM.") } /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _getBlendShapeCount(): Int { + override fun _getBlendShapeCount(): Int { throw NotImplementedError("ArrayMesh::_getBlendShapeCount can't be called from the JVM.") } /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _getBlendShapeName(index: Int): StringName { + override fun _getBlendShapeName(index: Int): StringName { throw NotImplementedError("ArrayMesh::_getBlendShapeName can't be called from the JVM.") } /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _setBlendShapeName(index: Int, name: StringName): Unit { + override fun _setBlendShapeName(index: Int, name: StringName) { throw NotImplementedError("ArrayMesh::_setBlendShapeName can't be called from the JVM.") } /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _getAabb(): AABB { + override fun _getAabb(): CoreAABB { throw NotImplementedError("ArrayMesh::_getAabb can't be called from the JVM.") } /** - * Adds name for a blend shape that will be added with [addSurfaceFromArrays]. Must be called - * before surface is added. + * Adds name for a blend shape that will be added with [addSurfaceFromArrays]. Must be called before surface is added. */ - public final fun addBlendShape(name: String) = addBlendShape(name.asCachedStringName()) + public final fun addBlendShape(name: String): Unit = addBlendShape(name.asCachedStringName()) /** * Sets the name of the blend shape at this index. */ - public final fun setBlendShapeName(index: Int, name: String) = - setBlendShapeName(index, name.asCachedStringName()) + public final fun setBlendShapeName(index: Int, name: String): Unit = setBlendShapeName(index, name.asCachedStringName()) public companion object public object MethodBindings { internal val addBlendShapePtr: VoidPtr = - TypeManager.getMethodBindPtr("ArrayMesh", "add_blend_shape", 3304788590) + TypeManager.getMethodBindPtr("ArrayMesh", "add_blend_shape", 3_304_788_590) internal val getBlendShapeCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("ArrayMesh", "get_blend_shape_count", 3905245786) + TypeManager.getMethodBindPtr("ArrayMesh", "get_blend_shape_count", 3_905_245_786) internal val getBlendShapeNamePtr: VoidPtr = - TypeManager.getMethodBindPtr("ArrayMesh", "get_blend_shape_name", 659327637) + TypeManager.getMethodBindPtr("ArrayMesh", "get_blend_shape_name", 659_327_637) internal val setBlendShapeNamePtr: VoidPtr = - TypeManager.getMethodBindPtr("ArrayMesh", "set_blend_shape_name", 3780747571) + TypeManager.getMethodBindPtr("ArrayMesh", "set_blend_shape_name", 3_780_747_571) internal val clearBlendShapesPtr: VoidPtr = - TypeManager.getMethodBindPtr("ArrayMesh", "clear_blend_shapes", 3218959716) + TypeManager.getMethodBindPtr("ArrayMesh", "clear_blend_shapes", 3_218_959_716) internal val setBlendShapeModePtr: VoidPtr = - TypeManager.getMethodBindPtr("ArrayMesh", "set_blend_shape_mode", 227983991) + TypeManager.getMethodBindPtr("ArrayMesh", "set_blend_shape_mode", 227_983_991) internal val getBlendShapeModePtr: VoidPtr = - TypeManager.getMethodBindPtr("ArrayMesh", "get_blend_shape_mode", 836485024) + TypeManager.getMethodBindPtr("ArrayMesh", "get_blend_shape_mode", 836_485_024) internal val addSurfaceFromArraysPtr: VoidPtr = - TypeManager.getMethodBindPtr("ArrayMesh", "add_surface_from_arrays", 1796411378) + TypeManager.getMethodBindPtr("ArrayMesh", "add_surface_from_arrays", 1_796_411_378) internal val clearSurfacesPtr: VoidPtr = - TypeManager.getMethodBindPtr("ArrayMesh", "clear_surfaces", 3218959716) + TypeManager.getMethodBindPtr("ArrayMesh", "clear_surfaces", 3_218_959_716) internal val surfaceRemovePtr: VoidPtr = - TypeManager.getMethodBindPtr("ArrayMesh", "surface_remove", 1286410249) + TypeManager.getMethodBindPtr("ArrayMesh", "surface_remove", 1_286_410_249) internal val surfaceUpdateVertexRegionPtr: VoidPtr = - TypeManager.getMethodBindPtr("ArrayMesh", "surface_update_vertex_region", 3837166854) + TypeManager.getMethodBindPtr("ArrayMesh", "surface_update_vertex_region", 3_837_166_854) internal val surfaceUpdateAttributeRegionPtr: VoidPtr = - TypeManager.getMethodBindPtr("ArrayMesh", "surface_update_attribute_region", 3837166854) + TypeManager.getMethodBindPtr("ArrayMesh", "surface_update_attribute_region", 3_837_166_854) internal val surfaceUpdateSkinRegionPtr: VoidPtr = - TypeManager.getMethodBindPtr("ArrayMesh", "surface_update_skin_region", 3837166854) + TypeManager.getMethodBindPtr("ArrayMesh", "surface_update_skin_region", 3_837_166_854) internal val surfaceGetArrayLenPtr: VoidPtr = - TypeManager.getMethodBindPtr("ArrayMesh", "surface_get_array_len", 923996154) + TypeManager.getMethodBindPtr("ArrayMesh", "surface_get_array_len", 923_996_154) internal val surfaceGetArrayIndexLenPtr: VoidPtr = - TypeManager.getMethodBindPtr("ArrayMesh", "surface_get_array_index_len", 923996154) + TypeManager.getMethodBindPtr("ArrayMesh", "surface_get_array_index_len", 923_996_154) internal val surfaceGetFormatPtr: VoidPtr = - TypeManager.getMethodBindPtr("ArrayMesh", "surface_get_format", 3718287884) + TypeManager.getMethodBindPtr("ArrayMesh", "surface_get_format", 3_718_287_884) internal val surfaceGetPrimitiveTypePtr: VoidPtr = - TypeManager.getMethodBindPtr("ArrayMesh", "surface_get_primitive_type", 4141943888) + TypeManager.getMethodBindPtr("ArrayMesh", "surface_get_primitive_type", 4_141_943_888) internal val surfaceFindByNamePtr: VoidPtr = - TypeManager.getMethodBindPtr("ArrayMesh", "surface_find_by_name", 1321353865) + TypeManager.getMethodBindPtr("ArrayMesh", "surface_find_by_name", 1_321_353_865) internal val surfaceSetNamePtr: VoidPtr = - TypeManager.getMethodBindPtr("ArrayMesh", "surface_set_name", 501894301) + TypeManager.getMethodBindPtr("ArrayMesh", "surface_set_name", 501_894_301) internal val surfaceGetNamePtr: VoidPtr = - TypeManager.getMethodBindPtr("ArrayMesh", "surface_get_name", 844755477) + TypeManager.getMethodBindPtr("ArrayMesh", "surface_get_name", 844_755_477) internal val regenNormalMapsPtr: VoidPtr = - TypeManager.getMethodBindPtr("ArrayMesh", "regen_normal_maps", 3218959716) + TypeManager.getMethodBindPtr("ArrayMesh", "regen_normal_maps", 3_218_959_716) internal val lightmapUnwrapPtr: VoidPtr = - TypeManager.getMethodBindPtr("ArrayMesh", "lightmap_unwrap", 1476641071) + TypeManager.getMethodBindPtr("ArrayMesh", "lightmap_unwrap", 1_476_641_071) internal val setCustomAabbPtr: VoidPtr = - TypeManager.getMethodBindPtr("ArrayMesh", "set_custom_aabb", 259215842) + TypeManager.getMethodBindPtr("ArrayMesh", "set_custom_aabb", 259_215_842) internal val getCustomAabbPtr: VoidPtr = - TypeManager.getMethodBindPtr("ArrayMesh", "get_custom_aabb", 1068685055) + TypeManager.getMethodBindPtr("ArrayMesh", "get_custom_aabb", 1_068_685_055) internal val setShadowMeshPtr: VoidPtr = - TypeManager.getMethodBindPtr("ArrayMesh", "set_shadow_mesh", 3377897901) + TypeManager.getMethodBindPtr("ArrayMesh", "set_shadow_mesh", 3_377_897_901) internal val getShadowMeshPtr: VoidPtr = - TypeManager.getMethodBindPtr("ArrayMesh", "get_shadow_mesh", 3206942465) + TypeManager.getMethodBindPtr("ArrayMesh", "get_shadow_mesh", 3_206_942_465) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ArrayOccluder3D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ArrayOccluder3D.kt index 2fc6f3aa56..b1ff42a8a7 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ArrayOccluder3D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ArrayOccluder3D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -24,8 +21,7 @@ import kotlin.Unit import kotlin.jvm.JvmName /** - * [ArrayOccluder3D] stores an arbitrary 3D polygon shape that can be used by the engine's occlusion - * culling system. This is analogous to [ArrayMesh], but for occluders. + * [ArrayOccluder3D] stores an arbitrary 3D polygon shape that can be used by the engine's occlusion culling system. This is analogous to [ArrayMesh], but for occluders. * * See [OccluderInstance3D]'s documentation for instructions on setting up occlusion culling. */ @@ -34,16 +30,11 @@ public open class ArrayOccluder3D : Occluder3D() { /** * The occluder's vertex positions in local 3D coordinates. * - * **Note:** The occluder is always updated after setting this value. If creating occluders - * procedurally, consider using [setArrays] instead to avoid updating the occluder twice when it's - * created. + * **Note:** The occluder is always updated after setting this value. If creating occluders procedurally, consider using [setArrays] instead to avoid updating the occluder twice when it's created. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var vertices: PackedVector3Array @@ -55,19 +46,13 @@ public open class ArrayOccluder3D : Occluder3D() { } /** - * The occluder's index position. Indices determine which points from the [vertices] array should - * be drawn, and in which order. + * The occluder's index position. Indices determine which points from the [vertices] array should be drawn, and in which order. * - * **Note:** The occluder is always updated after setting this value. If creating occluders - * procedurally, consider using [setArrays] instead to avoid updating the occluder twice when it's - * created. + * **Note:** The occluder is always updated after setting this value. If creating occluders procedurally, consider using [setArrays] instead to avoid updating the occluder twice when it's created. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var indices: PackedInt32Array @@ -78,7 +63,7 @@ public open class ArrayOccluder3D : Occluder3D() { setIndices(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(41, scriptIndex) } @@ -95,31 +80,24 @@ public open class ArrayOccluder3D : Occluder3D() { * * The occluder's vertex positions in local 3D coordinates. * - * **Note:** The occluder is always updated after setting this value. If creating occluders - * procedurally, consider using [setArrays] instead to avoid updating the occluder twice when it's - * created. + * **Note:** The occluder is always updated after setting this value. If creating occluders procedurally, consider using [setArrays] instead to avoid updating the occluder twice when it's created. */ @CoreTypeHelper - public final fun verticesMutate(block: PackedVector3Array.() -> Unit): PackedVector3Array = - vertices.apply { + public final fun verticesMutate(block: PackedVector3Array.() -> Unit): PackedVector3Array = vertices.apply { block(this) vertices = this } /** * This is a helper function for [vertices] to make dealing with local copies easier. - * Allow to directly modify each element of the local copy of the property and assign it back to - * the Object. + * Allow to directly modify each element of the local copy of the property and assign it back to the Object. * * The occluder's vertex positions in local 3D coordinates. * - * **Note:** The occluder is always updated after setting this value. If creating occluders - * procedurally, consider using [setArrays] instead to avoid updating the occluder twice when it's - * created. + * **Note:** The occluder is always updated after setting this value. If creating occluders procedurally, consider using [setArrays] instead to avoid updating the occluder twice when it's created. */ @CoreTypeHelper - public final fun verticesMutateEach(block: (index: Int, `value`: Vector3) -> Unit): - PackedVector3Array = vertices.apply { + public final fun verticesMutateEach(block: (index: Int, `value`: Vector3) -> Unit): PackedVector3Array = vertices.apply { this.forEachIndexed { index, value -> block(index, value) this[index] = value @@ -138,35 +116,26 @@ public open class ArrayOccluder3D : Occluder3D() { * arrayoccluder3d.indices = myCoreType * `````` * - * The occluder's index position. Indices determine which points from the [vertices] array should - * be drawn, and in which order. + * The occluder's index position. Indices determine which points from the [vertices] array should be drawn, and in which order. * - * **Note:** The occluder is always updated after setting this value. If creating occluders - * procedurally, consider using [setArrays] instead to avoid updating the occluder twice when it's - * created. + * **Note:** The occluder is always updated after setting this value. If creating occluders procedurally, consider using [setArrays] instead to avoid updating the occluder twice when it's created. */ @CoreTypeHelper - public final fun indicesMutate(block: PackedInt32Array.() -> Unit): PackedInt32Array = - indices.apply { + public final fun indicesMutate(block: PackedInt32Array.() -> Unit): PackedInt32Array = indices.apply { block(this) indices = this } /** * This is a helper function for [indices] to make dealing with local copies easier. - * Allow to directly modify each element of the local copy of the property and assign it back to - * the Object. + * Allow to directly modify each element of the local copy of the property and assign it back to the Object. * - * The occluder's index position. Indices determine which points from the [vertices] array should - * be drawn, and in which order. + * The occluder's index position. Indices determine which points from the [vertices] array should be drawn, and in which order. * - * **Note:** The occluder is always updated after setting this value. If creating occluders - * procedurally, consider using [setArrays] instead to avoid updating the occluder twice when it's - * created. + * **Note:** The occluder is always updated after setting this value. If creating occluders procedurally, consider using [setArrays] instead to avoid updating the occluder twice when it's created. */ @CoreTypeHelper - public final fun indicesMutateEach(block: (index: Int, `value`: Int) -> Unit): PackedInt32Array = - indices.apply { + public final fun indicesMutateEach(block: (index: Int, `value`: Int) -> Unit): PackedInt32Array = indices.apply { this.forEachIndexed { index, value -> block(index, value) this[index] = value @@ -175,20 +144,19 @@ public open class ArrayOccluder3D : Occluder3D() { } /** - * Sets [indices] and [vertices], while updating the final occluder only once after both values - * are set. + * Sets [indices] and [vertices], while updating the final occluder only once after both values are set. */ - public final fun setArrays(vertices: PackedVector3Array, indices: PackedInt32Array): Unit { + public final fun setArrays(vertices: PackedVector3Array, indices: PackedInt32Array) { TransferContext.writeArguments(PACKED_VECTOR3_ARRAY to vertices, PACKED_INT_32_ARRAY to indices) TransferContext.callMethod(ptr, MethodBindings.setArraysPtr, NIL) } - public final fun setVertices(vertices: PackedVector3Array): Unit { + public final fun setVertices(vertices: PackedVector3Array) { TransferContext.writeArguments(PACKED_VECTOR3_ARRAY to vertices) TransferContext.callMethod(ptr, MethodBindings.setVerticesPtr, NIL) } - public final fun setIndices(indices: PackedInt32Array): Unit { + public final fun setIndices(indices: PackedInt32Array) { TransferContext.writeArguments(PACKED_INT_32_ARRAY to indices) TransferContext.callMethod(ptr, MethodBindings.setIndicesPtr, NIL) } @@ -197,12 +165,12 @@ public open class ArrayOccluder3D : Occluder3D() { public object MethodBindings { internal val setArraysPtr: VoidPtr = - TypeManager.getMethodBindPtr("ArrayOccluder3D", "set_arrays", 3233972621) + TypeManager.getMethodBindPtr("ArrayOccluder3D", "set_arrays", 3_233_972_621) internal val setVerticesPtr: VoidPtr = - TypeManager.getMethodBindPtr("ArrayOccluder3D", "set_vertices", 334873810) + TypeManager.getMethodBindPtr("ArrayOccluder3D", "set_vertices", 334_873_810) internal val setIndicesPtr: VoidPtr = - TypeManager.getMethodBindPtr("ArrayOccluder3D", "set_indices", 3614634198) + TypeManager.getMethodBindPtr("ArrayOccluder3D", "set_indices", 3_614_634_198) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AspectRatioContainer.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AspectRatioContainer.kt index 532bf67128..2eddc18185 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AspectRatioContainer.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AspectRatioContainer.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -18,19 +15,15 @@ import kotlin.Float import kotlin.Int import kotlin.Long import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * A container type that arranges its child controls in a way that preserves their proportions - * automatically when the container is resized. Useful when a container has a dynamic size and the - * child nodes must adjust their sizes accordingly without losing their aspect ratios. + * A container type that arranges its child controls in a way that preserves their proportions automatically when the container is resized. Useful when a container has a dynamic size and the child nodes must adjust their sizes accordingly without losing their aspect ratios. */ @GodotBaseType public open class AspectRatioContainer : Container() { /** - * The aspect ratio to enforce on child controls. This is the width divided by the height. The - * ratio depends on the [stretchMode]. + * The aspect ratio to enforce on child controls. This is the width divided by the height. The ratio depends on the [stretchMode]. */ public final inline var ratio: Float @JvmName("ratioProperty") @@ -73,11 +66,11 @@ public open class AspectRatioContainer : Container() { setAlignmentVertical(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(42, scriptIndex) } - public final fun setRatio(ratio: Float): Unit { + public final fun setRatio(ratio: Float) { TransferContext.writeArguments(DOUBLE to ratio.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setRatioPtr, NIL) } @@ -88,7 +81,7 @@ public open class AspectRatioContainer : Container() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setStretchMode(stretchMode: StretchMode): Unit { + public final fun setStretchMode(stretchMode: StretchMode) { TransferContext.writeArguments(LONG to stretchMode.id) TransferContext.callMethod(ptr, MethodBindings.setStretchModePtr, NIL) } @@ -99,7 +92,7 @@ public open class AspectRatioContainer : Container() { return StretchMode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setAlignmentHorizontal(alignmentHorizontal: AlignmentMode): Unit { + public final fun setAlignmentHorizontal(alignmentHorizontal: AlignmentMode) { TransferContext.writeArguments(LONG to alignmentHorizontal.id) TransferContext.callMethod(ptr, MethodBindings.setAlignmentHorizontalPtr, NIL) } @@ -110,7 +103,7 @@ public open class AspectRatioContainer : Container() { return AlignmentMode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setAlignmentVertical(alignmentVertical: AlignmentMode): Unit { + public final fun setAlignmentVertical(alignmentVertical: AlignmentMode) { TransferContext.writeArguments(LONG to alignmentVertical.id) TransferContext.callMethod(ptr, MethodBindings.setAlignmentVerticalPtr, NIL) } @@ -133,17 +126,13 @@ public open class AspectRatioContainer : Container() { */ HEIGHT_CONTROLS_WIDTH(1), /** - * The bounding rectangle of child controls is automatically adjusted to fit inside the - * container while keeping the aspect ratio. + * The bounding rectangle of child controls is automatically adjusted to fit inside the container while keeping the aspect ratio. */ FIT(2), /** - * The width and height of child controls is automatically adjusted to make their bounding - * rectangle cover the entire area of the container while keeping the aspect ratio. + * The width and height of child controls is automatically adjusted to make their bounding rectangle cover the entire area of the container while keeping the aspect ratio. * - * When the bounding rectangle of child controls exceed the container's size and - * [Control.clipContents] is enabled, this allows to show only the container's area restricted by - * its own bounding rectangle. + * When the bounding rectangle of child controls exceed the container's size and [Control.clipContents] is enabled, this allows to show only the container's area restricted by its own bounding rectangle. */ COVER(3), ; @@ -189,27 +178,27 @@ public open class AspectRatioContainer : Container() { public object MethodBindings { internal val setRatioPtr: VoidPtr = - TypeManager.getMethodBindPtr("AspectRatioContainer", "set_ratio", 373806689) + TypeManager.getMethodBindPtr("AspectRatioContainer", "set_ratio", 373_806_689) internal val getRatioPtr: VoidPtr = - TypeManager.getMethodBindPtr("AspectRatioContainer", "get_ratio", 1740695150) + TypeManager.getMethodBindPtr("AspectRatioContainer", "get_ratio", 1_740_695_150) internal val setStretchModePtr: VoidPtr = - TypeManager.getMethodBindPtr("AspectRatioContainer", "set_stretch_mode", 1876743467) + TypeManager.getMethodBindPtr("AspectRatioContainer", "set_stretch_mode", 1_876_743_467) internal val getStretchModePtr: VoidPtr = - TypeManager.getMethodBindPtr("AspectRatioContainer", "get_stretch_mode", 3416449033) + TypeManager.getMethodBindPtr("AspectRatioContainer", "get_stretch_mode", 3_416_449_033) internal val setAlignmentHorizontalPtr: VoidPtr = - TypeManager.getMethodBindPtr("AspectRatioContainer", "set_alignment_horizontal", 2147829016) + TypeManager.getMethodBindPtr("AspectRatioContainer", "set_alignment_horizontal", 2_147_829_016) internal val getAlignmentHorizontalPtr: VoidPtr = - TypeManager.getMethodBindPtr("AspectRatioContainer", "get_alignment_horizontal", 3838875429) + TypeManager.getMethodBindPtr("AspectRatioContainer", "get_alignment_horizontal", 3_838_875_429) internal val setAlignmentVerticalPtr: VoidPtr = - TypeManager.getMethodBindPtr("AspectRatioContainer", "set_alignment_vertical", 2147829016) + TypeManager.getMethodBindPtr("AspectRatioContainer", "set_alignment_vertical", 2_147_829_016) internal val getAlignmentVerticalPtr: VoidPtr = - TypeManager.getMethodBindPtr("AspectRatioContainer", "get_alignment_vertical", 3838875429) + TypeManager.getMethodBindPtr("AspectRatioContainer", "get_alignment_vertical", 3_838_875_429) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AtlasTexture.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AtlasTexture.kt index 702672e5c0..82aa06715e 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AtlasTexture.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AtlasTexture.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -25,20 +22,16 @@ import kotlin.Unit import kotlin.jvm.JvmName /** - * [Texture2D] resource that draws only part of its [atlas] texture, as defined by the [region]. An - * additional [margin] can also be set, which is useful for small adjustments. + * [Texture2D] resource that draws only part of its [atlas] texture, as defined by the [region]. An additional [margin] can also be set, which is useful for small adjustments. * - * Multiple [AtlasTexture] resources can be cropped from the same [atlas]. Packing many smaller - * textures into a singular large texture helps to optimize video memory costs and render calls. + * Multiple [AtlasTexture] resources can be cropped from the same [atlas]. Packing many smaller textures into a singular large texture helps to optimize video memory costs and render calls. * - * **Note:** [AtlasTexture] cannot be used in an [AnimatedTexture], and will not tile properly in - * nodes such as [TextureRect] or [Sprite2D]. To tile an [AtlasTexture], modify its [region] instead. + * **Note:** [AtlasTexture] cannot be used in an [AnimatedTexture], and will not tile properly in nodes such as [TextureRect] or [Sprite2D]. To tile an [AtlasTexture], modify its [region] instead. */ @GodotBaseType public open class AtlasTexture : Texture2D() { /** - * The texture that contains the atlas. Can be any type inheriting from [Texture2D], including - * another [AtlasTexture]. + * The texture that contains the atlas. Can be any type inheriting from [Texture2D], including another [AtlasTexture]. */ public final inline var atlas: Texture2D? @JvmName("atlasProperty") @@ -49,15 +42,11 @@ public open class AtlasTexture : Texture2D() { } /** - * The region used to draw the [atlas]. If either dimension of the region's size is `0`, the value - * from [atlas] size will be used for that axis instead. + * The region used to draw the [atlas]. If either dimension of the region's size is `0`, the value from [atlas] size will be used for that axis instead. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var region: Rect2 @@ -69,16 +58,11 @@ public open class AtlasTexture : Texture2D() { } /** - * The margin around the [region]. Useful for small adjustments. If the [Rect2.size] of this - * property ("w" and "h" in the editor) is set, the drawn texture is resized to fit within the - * margin. + * The margin around the [region]. Useful for small adjustments. If the [Rect2.size] of this property ("w" and "h" in the editor) is set, the drawn texture is resized to fit within the margin. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var margin: Rect2 @@ -90,8 +74,7 @@ public open class AtlasTexture : Texture2D() { } /** - * If `true`, the area outside of the [region] is clipped to avoid bleeding of the surrounding - * texture pixels. + * If `true`, the area outside of the [region] is clipped to avoid bleeding of the surrounding texture pixels. */ public final inline var filterClip: Boolean @JvmName("filterClipProperty") @@ -101,7 +84,7 @@ public open class AtlasTexture : Texture2D() { setFilterClip(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(43, scriptIndex) } @@ -116,8 +99,7 @@ public open class AtlasTexture : Texture2D() { * atlastexture.region = myCoreType * `````` * - * The region used to draw the [atlas]. If either dimension of the region's size is `0`, the value - * from [atlas] size will be used for that axis instead. + * The region used to draw the [atlas]. If either dimension of the region's size is `0`, the value from [atlas] size will be used for that axis instead. */ @CoreTypeHelper public final fun regionMutate(block: Rect2.() -> Unit): Rect2 = region.apply { @@ -136,9 +118,7 @@ public open class AtlasTexture : Texture2D() { * atlastexture.margin = myCoreType * `````` * - * The margin around the [region]. Useful for small adjustments. If the [Rect2.size] of this - * property ("w" and "h" in the editor) is set, the drawn texture is resized to fit within the - * margin. + * The margin around the [region]. Useful for small adjustments. If the [Rect2.size] of this property ("w" and "h" in the editor) is set, the drawn texture is resized to fit within the margin. */ @CoreTypeHelper public final fun marginMutate(block: Rect2.() -> Unit): Rect2 = margin.apply { @@ -146,7 +126,7 @@ public open class AtlasTexture : Texture2D() { margin = this } - public final fun setAtlas(atlas: Texture2D?): Unit { + public final fun setAtlas(atlas: Texture2D?) { TransferContext.writeArguments(OBJECT to atlas) TransferContext.callMethod(ptr, MethodBindings.setAtlasPtr, NIL) } @@ -157,7 +137,7 @@ public open class AtlasTexture : Texture2D() { return (TransferContext.readReturnValue(OBJECT) as Texture2D?) } - public final fun setRegion(region: Rect2): Unit { + public final fun setRegion(region: Rect2) { TransferContext.writeArguments(RECT2 to region) TransferContext.callMethod(ptr, MethodBindings.setRegionPtr, NIL) } @@ -168,7 +148,7 @@ public open class AtlasTexture : Texture2D() { return (TransferContext.readReturnValue(RECT2) as Rect2) } - public final fun setMargin(margin: Rect2): Unit { + public final fun setMargin(margin: Rect2) { TransferContext.writeArguments(RECT2 to margin) TransferContext.callMethod(ptr, MethodBindings.setMarginPtr, NIL) } @@ -179,7 +159,7 @@ public open class AtlasTexture : Texture2D() { return (TransferContext.readReturnValue(RECT2) as Rect2) } - public final fun setFilterClip(enable: Boolean): Unit { + public final fun setFilterClip(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setFilterClipPtr, NIL) } @@ -193,14 +173,14 @@ public open class AtlasTexture : Texture2D() { /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _getWidth(): Int { + override fun _getWidth(): Int { throw NotImplementedError("AtlasTexture::_getWidth can't be called from the JVM.") } /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _getHeight(): Int { + override fun _getHeight(): Int { throw NotImplementedError("AtlasTexture::_getHeight can't be called from the JVM.") } @@ -208,27 +188,27 @@ public open class AtlasTexture : Texture2D() { public object MethodBindings { internal val setAtlasPtr: VoidPtr = - TypeManager.getMethodBindPtr("AtlasTexture", "set_atlas", 4051416890) + TypeManager.getMethodBindPtr("AtlasTexture", "set_atlas", 4_051_416_890) internal val getAtlasPtr: VoidPtr = - TypeManager.getMethodBindPtr("AtlasTexture", "get_atlas", 3635182373) + TypeManager.getMethodBindPtr("AtlasTexture", "get_atlas", 3_635_182_373) internal val setRegionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AtlasTexture", "set_region", 2046264180) + TypeManager.getMethodBindPtr("AtlasTexture", "set_region", 2_046_264_180) internal val getRegionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AtlasTexture", "get_region", 1639390495) + TypeManager.getMethodBindPtr("AtlasTexture", "get_region", 1_639_390_495) internal val setMarginPtr: VoidPtr = - TypeManager.getMethodBindPtr("AtlasTexture", "set_margin", 2046264180) + TypeManager.getMethodBindPtr("AtlasTexture", "set_margin", 2_046_264_180) internal val getMarginPtr: VoidPtr = - TypeManager.getMethodBindPtr("AtlasTexture", "get_margin", 1639390495) + TypeManager.getMethodBindPtr("AtlasTexture", "get_margin", 1_639_390_495) internal val setFilterClipPtr: VoidPtr = - TypeManager.getMethodBindPtr("AtlasTexture", "set_filter_clip", 2586408642) + TypeManager.getMethodBindPtr("AtlasTexture", "set_filter_clip", 2_586_408_642) internal val hasFilterClipPtr: VoidPtr = - TypeManager.getMethodBindPtr("AtlasTexture", "has_filter_clip", 36873697) + TypeManager.getMethodBindPtr("AtlasTexture", "has_filter_clip", 36_873_697) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioBusLayout.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioBusLayout.kt index 7d7128ecf2..fc26da4a82 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioBusLayout.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioBusLayout.kt @@ -1,23 +1,18 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api import godot.`annotation`.GodotBaseType import kotlin.Int import kotlin.Suppress -import kotlin.Unit /** - * Stores position, muting, solo, bypass, effects, effect position, volume, and the connections - * between buses. See [AudioServer] for usage. + * Stores position, muting, solo, bypass, effects, effect position, volume, and the connections between buses. See [AudioServer] for usage. */ @GodotBaseType public open class AudioBusLayout : Resource() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(44, scriptIndex) } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffect.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffect.kt index 82d8e2c0de..6993b0a9de 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffect.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffect.kt @@ -1,35 +1,25 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api import godot.`annotation`.GodotBaseType import kotlin.Int import kotlin.Suppress -import kotlin.Unit /** - * The base [Resource] for every audio effect. In the editor, an audio effect can be added to the - * current bus layout through the Audio panel. At run-time, it is also possible to manipulate audio - * effects through [AudioServer.addBusEffect], [AudioServer.removeBusEffect], and - * [AudioServer.getBusEffect]. + * The base [Resource] for every audio effect. In the editor, an audio effect can be added to the current bus layout through the Audio panel. At run-time, it is also possible to manipulate audio effects through [AudioServer.addBusEffect], [AudioServer.removeBusEffect], and [AudioServer.getBusEffect]. * - * When applied on a bus, an audio effect creates a corresponding [AudioEffectInstance]. The - * instance is directly responsible for manipulating the sound, based on the original audio effect's - * properties. + * When applied on a bus, an audio effect creates a corresponding [AudioEffectInstance]. The instance is directly responsible for manipulating the sound, based on the original audio effect's properties. */ @GodotBaseType public abstract class AudioEffect : Resource() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(45, scriptIndex) } /** - * Override this method to customize the [AudioEffectInstance] created when this effect is applied - * on a bus in the editor's Audio panel, or through [AudioServer.addBusEffect]. + * Override this method to customize the [AudioEffectInstance] created when this effect is applied on a bus in the editor's Audio panel, or through [AudioServer.addBusEffect]. * * ``` * extends AudioEffect @@ -43,9 +33,7 @@ public abstract class AudioEffect : Resource() { * return effect * ``` * - * **Note:** It is recommended to keep a reference to the original [AudioEffect] in the new - * instance. Depending on the implementation this allows the effect instance to listen for changes at - * run-time and be modified accordingly. + * **Note:** It is recommended to keep a reference to the original [AudioEffect] in the new instance. Depending on the implementation this allows the effect instance to listen for changes at run-time and be modified accordingly. */ public abstract fun _instantiate(): AudioEffectInstance? diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectAmplify.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectAmplify.kt index a8cddbf04e..28f563eeb5 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectAmplify.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectAmplify.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -17,7 +14,6 @@ import kotlin.Float import kotlin.Int import kotlin.NotImplementedError import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** @@ -26,8 +22,7 @@ import kotlin.jvm.JvmName @GodotBaseType public open class AudioEffectAmplify : AudioEffect() { /** - * Amount of amplification in decibels. Positive values make the sound louder, negative values - * make it quieter. Value can range from -80 to 24. + * Amount of amplification in decibels. Positive values make the sound louder, negative values make it quieter. Value can range from -80 to 24. */ public final inline var volumeDb: Float @JvmName("volumeDbProperty") @@ -40,9 +35,7 @@ public open class AudioEffectAmplify : AudioEffect() { /** * Amount of amplification as a linear value. * - * **Note:** This member modifies [volumeDb] for convenience. The returned value is equivalent to - * the result of [@GlobalScope.dbToLinear] on [volumeDb]. Setting this member is equivalent to - * setting [volumeDb] to the result of [@GlobalScope.linearToDb] on a value. + * **Note:** This member modifies [volumeDb] for convenience. The returned value is equivalent to the result of [@GlobalScope.dbToLinear] on [volumeDb]. Setting this member is equivalent to setting [volumeDb] to the result of [@GlobalScope.linearToDb] on a value. */ public final inline var volumeLinear: Float @JvmName("volumeLinearProperty") @@ -52,11 +45,11 @@ public open class AudioEffectAmplify : AudioEffect() { setVolumeLinear(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(46, scriptIndex) } - public final fun setVolumeDb(volume: Float): Unit { + public final fun setVolumeDb(volume: Float) { TransferContext.writeArguments(DOUBLE to volume.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setVolumeDbPtr, NIL) } @@ -67,7 +60,7 @@ public open class AudioEffectAmplify : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setVolumeLinear(volume: Float): Unit { + public final fun setVolumeLinear(volume: Float) { TransferContext.writeArguments(DOUBLE to volume.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setVolumeLinearPtr, NIL) } @@ -81,7 +74,7 @@ public open class AudioEffectAmplify : AudioEffect() { /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _instantiate(): AudioEffectInstance? { + override fun _instantiate(): AudioEffectInstance? { throw NotImplementedError("AudioEffectAmplify::_instantiate can't be called from the JVM.") } @@ -89,15 +82,15 @@ public open class AudioEffectAmplify : AudioEffect() { public object MethodBindings { internal val setVolumeDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectAmplify", "set_volume_db", 373806689) + TypeManager.getMethodBindPtr("AudioEffectAmplify", "set_volume_db", 373_806_689) internal val getVolumeDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectAmplify", "get_volume_db", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectAmplify", "get_volume_db", 1_740_695_150) internal val setVolumeLinearPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectAmplify", "set_volume_linear", 373806689) + TypeManager.getMethodBindPtr("AudioEffectAmplify", "set_volume_linear", 373_806_689) internal val getVolumeLinearPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectAmplify", "get_volume_linear", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectAmplify", "get_volume_linear", 1_740_695_150) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectBandLimitFilter.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectBandLimitFilter.kt index ecd42093ab..73f8b56c76 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectBandLimitFilter.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectBandLimitFilter.kt @@ -1,23 +1,18 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api import godot.`annotation`.GodotBaseType import kotlin.Int import kotlin.Suppress -import kotlin.Unit /** - * Limits the frequencies in a range around the [AudioEffectFilter.cutoffHz] and allows frequencies - * outside of this range to pass. + * Limits the frequencies in a range around the [AudioEffectFilter.cutoffHz] and allows frequencies outside of this range to pass. */ @GodotBaseType public open class AudioEffectBandLimitFilter : AudioEffectFilter() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(47, scriptIndex) } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectBandPassFilter.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectBandPassFilter.kt index 8fd1fa4805..2591653077 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectBandPassFilter.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectBandPassFilter.kt @@ -1,23 +1,18 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api import godot.`annotation`.GodotBaseType import kotlin.Int import kotlin.Suppress -import kotlin.Unit /** - * Attenuates the frequencies inside of a range around the [AudioEffectFilter.cutoffHz] and cuts - * frequencies outside of this band. + * Attenuates the frequencies inside of a range around the [AudioEffectFilter.cutoffHz] and cuts frequencies outside of this band. */ @GodotBaseType public open class AudioEffectBandPassFilter : AudioEffectFilter() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(48, scriptIndex) } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectCapture.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectCapture.kt index 7f0d8844f7..04cd9d6a7d 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectCapture.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectCapture.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -23,26 +20,19 @@ import kotlin.Int import kotlin.Long import kotlin.NotImplementedError import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * AudioEffectCapture is an AudioEffect which copies all audio frames from the attached audio effect - * bus into its internal ring buffer. + * AudioEffectCapture is an AudioEffect which copies all audio frames from the attached audio effect bus into its internal ring buffer. * - * Application code should consume these audio frames from this ring buffer using [getBuffer] and - * process it as needed, for example to capture data from an [AudioStreamMicrophone], implement - * application-defined effects, or to transmit audio over the network. When capturing audio data from a - * microphone, the format of the samples will be stereo 32-bit floating-point PCM. + * Application code should consume these audio frames from this ring buffer using [getBuffer] and process it as needed, for example to capture data from an [AudioStreamMicrophone], implement application-defined effects, or to transmit audio over the network. When capturing audio data from a microphone, the format of the samples will be stereo 32-bit floating-point PCM. * - * Unlike [AudioEffectRecord], this effect only returns the raw audio samples instead of encoding - * them into an [AudioStream]. + * Unlike [AudioEffectRecord], this effect only returns the raw audio samples instead of encoding them into an [AudioStream]. */ @GodotBaseType public open class AudioEffectCapture : AudioEffect() { /** - * Length of the internal ring buffer, in seconds. Setting the buffer length will have no effect - * if already initialized. + * Length of the internal ring buffer, in seconds. Setting the buffer length will have no effect if already initialized. */ public final inline var bufferLength: Float @JvmName("bufferLengthProperty") @@ -52,13 +42,12 @@ public open class AudioEffectCapture : AudioEffect() { setBufferLength(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(49, scriptIndex) } /** - * Returns `true` if at least [frames] audio frames are available to read in the internal ring - * buffer. + * Returns `true` if at least [frames] audio frames are available to read in the internal ring buffer. */ public final fun canGetBuffer(frames: Int): Boolean { TransferContext.writeArguments(LONG to frames.toLong()) @@ -69,11 +58,9 @@ public open class AudioEffectCapture : AudioEffect() { /** * Gets the next [frames] audio samples from the internal ring buffer. * - * Returns a [PackedVector2Array] containing exactly [frames] audio samples if available, or an - * empty [PackedVector2Array] if insufficient data was available. + * Returns a [PackedVector2Array] containing exactly [frames] audio samples if available, or an empty [PackedVector2Array] if insufficient data was available. * - * The samples are signed floating-point PCM between `-1` and `1`. You will have to scale them if - * you want to use them as 8 or 16-bit integer samples. (`v = 0x7fff * samples[0].x`) + * The samples are signed floating-point PCM between `-1` and `1`. You will have to scale them if you want to use them as 8 or 16-bit integer samples. (`v = 0x7fff * samples[0].x`) */ public final fun getBuffer(frames: Int): PackedVector2Array { TransferContext.writeArguments(LONG to frames.toLong()) @@ -84,15 +71,14 @@ public open class AudioEffectCapture : AudioEffect() { /** * Clears the internal ring buffer. * - * **Note:** Calling this during a capture can cause the loss of samples which causes popping in - * the playback. + * **Note:** Calling this during a capture can cause the loss of samples which causes popping in the playback. */ - public final fun clearBuffer(): Unit { + public final fun clearBuffer() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.clearBufferPtr, NIL) } - public final fun setBufferLength(bufferLengthSeconds: Float): Unit { + public final fun setBufferLength(bufferLengthSeconds: Float) { TransferContext.writeArguments(DOUBLE to bufferLengthSeconds.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setBufferLengthPtr, NIL) } @@ -142,7 +128,7 @@ public open class AudioEffectCapture : AudioEffect() { /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _instantiate(): AudioEffectInstance? { + override fun _instantiate(): AudioEffectInstance? { throw NotImplementedError("AudioEffectCapture::_instantiate can't be called from the JVM.") } @@ -150,30 +136,30 @@ public open class AudioEffectCapture : AudioEffect() { public object MethodBindings { internal val canGetBufferPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectCapture", "can_get_buffer", 1116898809) + TypeManager.getMethodBindPtr("AudioEffectCapture", "can_get_buffer", 1_116_898_809) internal val getBufferPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectCapture", "get_buffer", 2649534757) + TypeManager.getMethodBindPtr("AudioEffectCapture", "get_buffer", 2_649_534_757) internal val clearBufferPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectCapture", "clear_buffer", 3218959716) + TypeManager.getMethodBindPtr("AudioEffectCapture", "clear_buffer", 3_218_959_716) internal val setBufferLengthPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectCapture", "set_buffer_length", 373806689) + TypeManager.getMethodBindPtr("AudioEffectCapture", "set_buffer_length", 373_806_689) internal val getBufferLengthPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectCapture", "get_buffer_length", 191475506) + TypeManager.getMethodBindPtr("AudioEffectCapture", "get_buffer_length", 191_475_506) internal val getFramesAvailablePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectCapture", "get_frames_available", 3905245786) + TypeManager.getMethodBindPtr("AudioEffectCapture", "get_frames_available", 3_905_245_786) internal val getDiscardedFramesPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectCapture", "get_discarded_frames", 3905245786) + TypeManager.getMethodBindPtr("AudioEffectCapture", "get_discarded_frames", 3_905_245_786) internal val getBufferLengthFramesPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectCapture", "get_buffer_length_frames", 3905245786) + TypeManager.getMethodBindPtr("AudioEffectCapture", "get_buffer_length_frames", 3_905_245_786) internal val getPushedFramesPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectCapture", "get_pushed_frames", 3905245786) + TypeManager.getMethodBindPtr("AudioEffectCapture", "get_pushed_frames", 3_905_245_786) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectChorus.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectChorus.kt index 5cf612cbef..fd18d77f30 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectChorus.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectChorus.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -19,12 +16,10 @@ import kotlin.Int import kotlin.Long import kotlin.NotImplementedError import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * Adds a chorus audio effect. The effect applies a filter with voices to duplicate the audio source - * and manipulate it through the filter. + * Adds a chorus audio effect. The effect applies a filter with voices to duplicate the audio source and manipulate it through the filter. */ @GodotBaseType public open class AudioEffectChorus : AudioEffect() { @@ -61,11 +56,11 @@ public open class AudioEffectChorus : AudioEffect() { setWet(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(50, scriptIndex) } - public final fun setVoiceCount(voices: Int): Unit { + public final fun setVoiceCount(voices: Int) { TransferContext.writeArguments(LONG to voices.toLong()) TransferContext.callMethod(ptr, MethodBindings.setVoiceCountPtr, NIL) } @@ -76,7 +71,7 @@ public open class AudioEffectChorus : AudioEffect() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setVoiceDelayMs(voiceIdx: Int, delayMs: Float): Unit { + public final fun setVoiceDelayMs(voiceIdx: Int, delayMs: Float) { TransferContext.writeArguments(LONG to voiceIdx.toLong(), DOUBLE to delayMs.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setVoiceDelayMsPtr, NIL) } @@ -87,7 +82,7 @@ public open class AudioEffectChorus : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setVoiceRateHz(voiceIdx: Int, rateHz: Float): Unit { + public final fun setVoiceRateHz(voiceIdx: Int, rateHz: Float) { TransferContext.writeArguments(LONG to voiceIdx.toLong(), DOUBLE to rateHz.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setVoiceRateHzPtr, NIL) } @@ -98,7 +93,7 @@ public open class AudioEffectChorus : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setVoiceDepthMs(voiceIdx: Int, depthMs: Float): Unit { + public final fun setVoiceDepthMs(voiceIdx: Int, depthMs: Float) { TransferContext.writeArguments(LONG to voiceIdx.toLong(), DOUBLE to depthMs.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setVoiceDepthMsPtr, NIL) } @@ -109,7 +104,7 @@ public open class AudioEffectChorus : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setVoiceLevelDb(voiceIdx: Int, levelDb: Float): Unit { + public final fun setVoiceLevelDb(voiceIdx: Int, levelDb: Float) { TransferContext.writeArguments(LONG to voiceIdx.toLong(), DOUBLE to levelDb.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setVoiceLevelDbPtr, NIL) } @@ -120,7 +115,7 @@ public open class AudioEffectChorus : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setVoiceCutoffHz(voiceIdx: Int, cutoffHz: Float): Unit { + public final fun setVoiceCutoffHz(voiceIdx: Int, cutoffHz: Float) { TransferContext.writeArguments(LONG to voiceIdx.toLong(), DOUBLE to cutoffHz.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setVoiceCutoffHzPtr, NIL) } @@ -131,7 +126,7 @@ public open class AudioEffectChorus : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setVoicePan(voiceIdx: Int, pan: Float): Unit { + public final fun setVoicePan(voiceIdx: Int, pan: Float) { TransferContext.writeArguments(LONG to voiceIdx.toLong(), DOUBLE to pan.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setVoicePanPtr, NIL) } @@ -142,7 +137,7 @@ public open class AudioEffectChorus : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setWet(amount: Float): Unit { + public final fun setWet(amount: Float) { TransferContext.writeArguments(DOUBLE to amount.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setWetPtr, NIL) } @@ -153,7 +148,7 @@ public open class AudioEffectChorus : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setDry(amount: Float): Unit { + public final fun setDry(amount: Float) { TransferContext.writeArguments(DOUBLE to amount.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setDryPtr, NIL) } @@ -167,7 +162,7 @@ public open class AudioEffectChorus : AudioEffect() { /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _instantiate(): AudioEffectInstance? { + override fun _instantiate(): AudioEffectInstance? { throw NotImplementedError("AudioEffectChorus::_instantiate can't be called from the JVM.") } @@ -175,57 +170,57 @@ public open class AudioEffectChorus : AudioEffect() { public object MethodBindings { internal val setVoiceCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectChorus", "set_voice_count", 1286410249) + TypeManager.getMethodBindPtr("AudioEffectChorus", "set_voice_count", 1_286_410_249) internal val getVoiceCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectChorus", "get_voice_count", 3905245786) + TypeManager.getMethodBindPtr("AudioEffectChorus", "get_voice_count", 3_905_245_786) internal val setVoiceDelayMsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectChorus", "set_voice_delay_ms", 1602489585) + TypeManager.getMethodBindPtr("AudioEffectChorus", "set_voice_delay_ms", 1_602_489_585) internal val getVoiceDelayMsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectChorus", "get_voice_delay_ms", 2339986948) + TypeManager.getMethodBindPtr("AudioEffectChorus", "get_voice_delay_ms", 2_339_986_948) internal val setVoiceRateHzPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectChorus", "set_voice_rate_hz", 1602489585) + TypeManager.getMethodBindPtr("AudioEffectChorus", "set_voice_rate_hz", 1_602_489_585) internal val getVoiceRateHzPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectChorus", "get_voice_rate_hz", 2339986948) + TypeManager.getMethodBindPtr("AudioEffectChorus", "get_voice_rate_hz", 2_339_986_948) internal val setVoiceDepthMsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectChorus", "set_voice_depth_ms", 1602489585) + TypeManager.getMethodBindPtr("AudioEffectChorus", "set_voice_depth_ms", 1_602_489_585) internal val getVoiceDepthMsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectChorus", "get_voice_depth_ms", 2339986948) + TypeManager.getMethodBindPtr("AudioEffectChorus", "get_voice_depth_ms", 2_339_986_948) internal val setVoiceLevelDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectChorus", "set_voice_level_db", 1602489585) + TypeManager.getMethodBindPtr("AudioEffectChorus", "set_voice_level_db", 1_602_489_585) internal val getVoiceLevelDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectChorus", "get_voice_level_db", 2339986948) + TypeManager.getMethodBindPtr("AudioEffectChorus", "get_voice_level_db", 2_339_986_948) internal val setVoiceCutoffHzPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectChorus", "set_voice_cutoff_hz", 1602489585) + TypeManager.getMethodBindPtr("AudioEffectChorus", "set_voice_cutoff_hz", 1_602_489_585) internal val getVoiceCutoffHzPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectChorus", "get_voice_cutoff_hz", 2339986948) + TypeManager.getMethodBindPtr("AudioEffectChorus", "get_voice_cutoff_hz", 2_339_986_948) internal val setVoicePanPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectChorus", "set_voice_pan", 1602489585) + TypeManager.getMethodBindPtr("AudioEffectChorus", "set_voice_pan", 1_602_489_585) internal val getVoicePanPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectChorus", "get_voice_pan", 2339986948) + TypeManager.getMethodBindPtr("AudioEffectChorus", "get_voice_pan", 2_339_986_948) internal val setWetPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectChorus", "set_wet", 373806689) + TypeManager.getMethodBindPtr("AudioEffectChorus", "set_wet", 373_806_689) internal val getWetPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectChorus", "get_wet", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectChorus", "get_wet", 1_740_695_150) internal val setDryPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectChorus", "set_dry", 373806689) + TypeManager.getMethodBindPtr("AudioEffectChorus", "set_dry", 373_806_689) internal val getDryPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectChorus", "get_dry", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectChorus", "get_dry", 1_740_695_150) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectCompressor.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectCompressor.kt index 68a4d5eaee..77b90b94a8 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectCompressor.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectCompressor.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -25,20 +22,15 @@ import kotlin.Unit import kotlin.jvm.JvmName /** - * Dynamic range compressor reduces the level of the sound when the amplitude goes over a certain - * threshold in Decibels. One of the main uses of a compressor is to increase the dynamic range by - * clipping as little as possible (when sound goes over 0dB). + * Dynamic range compressor reduces the level of the sound when the amplitude goes over a certain threshold in Decibels. One of the main uses of a compressor is to increase the dynamic range by clipping as little as possible (when sound goes over 0dB). * * Compressor has many uses in the mix: * - * - In the Master bus to compress the whole output (although an [AudioEffectLimiter] is probably - * better). + * - In the Master bus to compress the whole output (although an [AudioEffectLimiter] is probably better). * * - In voice channels to ensure they sound as balanced as possible. * - * - Sidechained. This can reduce the sound level sidechained with another audio bus for threshold - * detection. This technique is common in video game mixing to the level of music and SFX while voices - * are being heard. + * - Sidechained. This can reduce the sound level sidechained with another audio bus for threshold detection. This technique is common in video game mixing to the level of music and SFX while voices are being heard. * * - Accentuates transients by using a wider attack, making effects sound more punchy. */ @@ -56,8 +48,7 @@ public open class AudioEffectCompressor : AudioEffect() { } /** - * Amount of compression applied to the audio once it passes the threshold level. The higher the - * ratio, the more the loud parts of the audio will be compressed. Value can range from 1 to 48. + * Amount of compression applied to the audio once it passes the threshold level. The higher the ratio, the more the loud parts of the audio will be compressed. Value can range from 1 to 48. */ public final inline var ratio: Float @JvmName("ratioProperty") @@ -79,8 +70,7 @@ public open class AudioEffectCompressor : AudioEffect() { } /** - * Compressor's reaction time when the signal exceeds the threshold, in microseconds. Value can - * range from 20 to 2000. + * Compressor's reaction time when the signal exceeds the threshold, in microseconds. Value can range from 20 to 2000. */ public final inline var attackUs: Float @JvmName("attackUsProperty") @@ -91,8 +81,7 @@ public open class AudioEffectCompressor : AudioEffect() { } /** - * Compressor's delay time to stop reducing the signal after the signal level falls below the - * threshold, in milliseconds. Value can range from 20 to 2000. + * Compressor's delay time to stop reducing the signal after the signal level falls below the threshold, in milliseconds. Value can range from 20 to 2000. */ public final inline var releaseMs: Float @JvmName("releaseMsProperty") @@ -103,8 +92,7 @@ public open class AudioEffectCompressor : AudioEffect() { } /** - * Balance between original signal and effect signal. Value can range from 0 (totally dry) to 1 - * (totally wet). + * Balance between original signal and effect signal. Value can range from 0 (totally dry) to 1 (totally wet). */ public final inline var mix: Float @JvmName("mixProperty") @@ -125,11 +113,11 @@ public open class AudioEffectCompressor : AudioEffect() { setSidechain(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(51, scriptIndex) } - public final fun setThreshold(threshold: Float): Unit { + public final fun setThreshold(threshold: Float) { TransferContext.writeArguments(DOUBLE to threshold.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setThresholdPtr, NIL) } @@ -140,7 +128,7 @@ public open class AudioEffectCompressor : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setRatio(ratio: Float): Unit { + public final fun setRatio(ratio: Float) { TransferContext.writeArguments(DOUBLE to ratio.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setRatioPtr, NIL) } @@ -151,7 +139,7 @@ public open class AudioEffectCompressor : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setGain(gain: Float): Unit { + public final fun setGain(gain: Float) { TransferContext.writeArguments(DOUBLE to gain.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setGainPtr, NIL) } @@ -162,7 +150,7 @@ public open class AudioEffectCompressor : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setAttackUs(attackUs: Float): Unit { + public final fun setAttackUs(attackUs: Float) { TransferContext.writeArguments(DOUBLE to attackUs.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setAttackUsPtr, NIL) } @@ -173,7 +161,7 @@ public open class AudioEffectCompressor : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setReleaseMs(releaseMs: Float): Unit { + public final fun setReleaseMs(releaseMs: Float) { TransferContext.writeArguments(DOUBLE to releaseMs.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setReleaseMsPtr, NIL) } @@ -184,7 +172,7 @@ public open class AudioEffectCompressor : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setMix(mix: Float): Unit { + public final fun setMix(mix: Float) { TransferContext.writeArguments(DOUBLE to mix.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setMixPtr, NIL) } @@ -195,7 +183,7 @@ public open class AudioEffectCompressor : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setSidechain(sidechain: StringName): Unit { + public final fun setSidechain(sidechain: StringName) { TransferContext.writeArguments(STRING_NAME to sidechain) TransferContext.callMethod(ptr, MethodBindings.setSidechainPtr, NIL) } @@ -209,55 +197,55 @@ public open class AudioEffectCompressor : AudioEffect() { /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _instantiate(): AudioEffectInstance? { + override fun _instantiate(): AudioEffectInstance? { throw NotImplementedError("AudioEffectCompressor::_instantiate can't be called from the JVM.") } - public final fun setSidechain(sidechain: String) = setSidechain(sidechain.asCachedStringName()) + public final fun setSidechain(sidechain: String): Unit = setSidechain(sidechain.asCachedStringName()) public companion object public object MethodBindings { internal val setThresholdPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectCompressor", "set_threshold", 373806689) + TypeManager.getMethodBindPtr("AudioEffectCompressor", "set_threshold", 373_806_689) internal val getThresholdPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectCompressor", "get_threshold", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectCompressor", "get_threshold", 1_740_695_150) internal val setRatioPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectCompressor", "set_ratio", 373806689) + TypeManager.getMethodBindPtr("AudioEffectCompressor", "set_ratio", 373_806_689) internal val getRatioPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectCompressor", "get_ratio", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectCompressor", "get_ratio", 1_740_695_150) internal val setGainPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectCompressor", "set_gain", 373806689) + TypeManager.getMethodBindPtr("AudioEffectCompressor", "set_gain", 373_806_689) internal val getGainPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectCompressor", "get_gain", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectCompressor", "get_gain", 1_740_695_150) internal val setAttackUsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectCompressor", "set_attack_us", 373806689) + TypeManager.getMethodBindPtr("AudioEffectCompressor", "set_attack_us", 373_806_689) internal val getAttackUsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectCompressor", "get_attack_us", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectCompressor", "get_attack_us", 1_740_695_150) internal val setReleaseMsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectCompressor", "set_release_ms", 373806689) + TypeManager.getMethodBindPtr("AudioEffectCompressor", "set_release_ms", 373_806_689) internal val getReleaseMsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectCompressor", "get_release_ms", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectCompressor", "get_release_ms", 1_740_695_150) internal val setMixPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectCompressor", "set_mix", 373806689) + TypeManager.getMethodBindPtr("AudioEffectCompressor", "set_mix", 373_806_689) internal val getMixPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectCompressor", "get_mix", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectCompressor", "get_mix", 1_740_695_150) internal val setSidechainPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectCompressor", "set_sidechain", 3304788590) + TypeManager.getMethodBindPtr("AudioEffectCompressor", "set_sidechain", 3_304_788_590) internal val getSidechainPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectCompressor", "get_sidechain", 2002593661) + TypeManager.getMethodBindPtr("AudioEffectCompressor", "get_sidechain", 2_002_593_661) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectDelay.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectDelay.kt index 4256f1c017..5d267fc071 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectDelay.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectDelay.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -19,19 +16,15 @@ import kotlin.Float import kotlin.Int import kotlin.NotImplementedError import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * Plays input signal back after a period of time. The delayed signal may be played back multiple - * times to create the sound of a repeating, decaying echo. Delay effects range from a subtle echo - * effect to a pronounced blending of previous sounds with new sounds. + * Plays input signal back after a period of time. The delayed signal may be played back multiple times to create the sound of a repeating, decaying echo. Delay effects range from a subtle echo effect to a pronounced blending of previous sounds with new sounds. */ @GodotBaseType public open class AudioEffectDelay : AudioEffect() { /** - * Output percent of original sound. At 0, only delayed sounds are output. Value can range from 0 - * to 1. + * Output percent of original sound. At 0, only delayed sounds are output. Value can range from 0 to 1. */ public final inline var dry: Float @JvmName("dryProperty") @@ -163,8 +156,7 @@ public open class AudioEffectDelay : AudioEffect() { } /** - * Low-pass filter for feedback, in Hz. Frequencies below this value are filtered out of the - * source signal. + * Low-pass filter for feedback, in Hz. Frequencies below this value are filtered out of the source signal. */ public final inline var feedbackLowpass: Float @JvmName("feedbackLowpassProperty") @@ -174,11 +166,11 @@ public open class AudioEffectDelay : AudioEffect() { setFeedbackLowpass(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(52, scriptIndex) } - public final fun setDry(amount: Float): Unit { + public final fun setDry(amount: Float) { TransferContext.writeArguments(DOUBLE to amount.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setDryPtr, NIL) } @@ -189,7 +181,7 @@ public open class AudioEffectDelay : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setTap1Active(amount: Boolean): Unit { + public final fun setTap1Active(amount: Boolean) { TransferContext.writeArguments(BOOL to amount) TransferContext.callMethod(ptr, MethodBindings.setTap1ActivePtr, NIL) } @@ -200,7 +192,7 @@ public open class AudioEffectDelay : AudioEffect() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setTap1DelayMs(amount: Float): Unit { + public final fun setTap1DelayMs(amount: Float) { TransferContext.writeArguments(DOUBLE to amount.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setTap1DelayMsPtr, NIL) } @@ -211,7 +203,7 @@ public open class AudioEffectDelay : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setTap1LevelDb(amount: Float): Unit { + public final fun setTap1LevelDb(amount: Float) { TransferContext.writeArguments(DOUBLE to amount.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setTap1LevelDbPtr, NIL) } @@ -222,7 +214,7 @@ public open class AudioEffectDelay : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setTap1Pan(amount: Float): Unit { + public final fun setTap1Pan(amount: Float) { TransferContext.writeArguments(DOUBLE to amount.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setTap1PanPtr, NIL) } @@ -233,7 +225,7 @@ public open class AudioEffectDelay : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setTap2Active(amount: Boolean): Unit { + public final fun setTap2Active(amount: Boolean) { TransferContext.writeArguments(BOOL to amount) TransferContext.callMethod(ptr, MethodBindings.setTap2ActivePtr, NIL) } @@ -244,7 +236,7 @@ public open class AudioEffectDelay : AudioEffect() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setTap2DelayMs(amount: Float): Unit { + public final fun setTap2DelayMs(amount: Float) { TransferContext.writeArguments(DOUBLE to amount.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setTap2DelayMsPtr, NIL) } @@ -255,7 +247,7 @@ public open class AudioEffectDelay : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setTap2LevelDb(amount: Float): Unit { + public final fun setTap2LevelDb(amount: Float) { TransferContext.writeArguments(DOUBLE to amount.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setTap2LevelDbPtr, NIL) } @@ -266,7 +258,7 @@ public open class AudioEffectDelay : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setTap2Pan(amount: Float): Unit { + public final fun setTap2Pan(amount: Float) { TransferContext.writeArguments(DOUBLE to amount.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setTap2PanPtr, NIL) } @@ -277,7 +269,7 @@ public open class AudioEffectDelay : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setFeedbackActive(amount: Boolean): Unit { + public final fun setFeedbackActive(amount: Boolean) { TransferContext.writeArguments(BOOL to amount) TransferContext.callMethod(ptr, MethodBindings.setFeedbackActivePtr, NIL) } @@ -288,7 +280,7 @@ public open class AudioEffectDelay : AudioEffect() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setFeedbackDelayMs(amount: Float): Unit { + public final fun setFeedbackDelayMs(amount: Float) { TransferContext.writeArguments(DOUBLE to amount.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setFeedbackDelayMsPtr, NIL) } @@ -299,7 +291,7 @@ public open class AudioEffectDelay : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setFeedbackLevelDb(amount: Float): Unit { + public final fun setFeedbackLevelDb(amount: Float) { TransferContext.writeArguments(DOUBLE to amount.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setFeedbackLevelDbPtr, NIL) } @@ -310,7 +302,7 @@ public open class AudioEffectDelay : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setFeedbackLowpass(amount: Float): Unit { + public final fun setFeedbackLowpass(amount: Float) { TransferContext.writeArguments(DOUBLE to amount.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setFeedbackLowpassPtr, NIL) } @@ -324,7 +316,7 @@ public open class AudioEffectDelay : AudioEffect() { /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _instantiate(): AudioEffectInstance? { + override fun _instantiate(): AudioEffectInstance? { throw NotImplementedError("AudioEffectDelay::_instantiate can't be called from the JVM.") } @@ -332,81 +324,81 @@ public open class AudioEffectDelay : AudioEffect() { public object MethodBindings { internal val setDryPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDelay", "set_dry", 373806689) + TypeManager.getMethodBindPtr("AudioEffectDelay", "set_dry", 373_806_689) internal val getDryPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDelay", "get_dry", 191475506) + TypeManager.getMethodBindPtr("AudioEffectDelay", "get_dry", 191_475_506) internal val setTap1ActivePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDelay", "set_tap1_active", 2586408642) + TypeManager.getMethodBindPtr("AudioEffectDelay", "set_tap1_active", 2_586_408_642) internal val isTap1ActivePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDelay", "is_tap1_active", 36873697) + TypeManager.getMethodBindPtr("AudioEffectDelay", "is_tap1_active", 36_873_697) internal val setTap1DelayMsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDelay", "set_tap1_delay_ms", 373806689) + TypeManager.getMethodBindPtr("AudioEffectDelay", "set_tap1_delay_ms", 373_806_689) internal val getTap1DelayMsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDelay", "get_tap1_delay_ms", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectDelay", "get_tap1_delay_ms", 1_740_695_150) internal val setTap1LevelDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDelay", "set_tap1_level_db", 373806689) + TypeManager.getMethodBindPtr("AudioEffectDelay", "set_tap1_level_db", 373_806_689) internal val getTap1LevelDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDelay", "get_tap1_level_db", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectDelay", "get_tap1_level_db", 1_740_695_150) internal val setTap1PanPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDelay", "set_tap1_pan", 373806689) + TypeManager.getMethodBindPtr("AudioEffectDelay", "set_tap1_pan", 373_806_689) internal val getTap1PanPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDelay", "get_tap1_pan", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectDelay", "get_tap1_pan", 1_740_695_150) internal val setTap2ActivePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDelay", "set_tap2_active", 2586408642) + TypeManager.getMethodBindPtr("AudioEffectDelay", "set_tap2_active", 2_586_408_642) internal val isTap2ActivePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDelay", "is_tap2_active", 36873697) + TypeManager.getMethodBindPtr("AudioEffectDelay", "is_tap2_active", 36_873_697) internal val setTap2DelayMsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDelay", "set_tap2_delay_ms", 373806689) + TypeManager.getMethodBindPtr("AudioEffectDelay", "set_tap2_delay_ms", 373_806_689) internal val getTap2DelayMsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDelay", "get_tap2_delay_ms", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectDelay", "get_tap2_delay_ms", 1_740_695_150) internal val setTap2LevelDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDelay", "set_tap2_level_db", 373806689) + TypeManager.getMethodBindPtr("AudioEffectDelay", "set_tap2_level_db", 373_806_689) internal val getTap2LevelDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDelay", "get_tap2_level_db", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectDelay", "get_tap2_level_db", 1_740_695_150) internal val setTap2PanPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDelay", "set_tap2_pan", 373806689) + TypeManager.getMethodBindPtr("AudioEffectDelay", "set_tap2_pan", 373_806_689) internal val getTap2PanPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDelay", "get_tap2_pan", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectDelay", "get_tap2_pan", 1_740_695_150) internal val setFeedbackActivePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDelay", "set_feedback_active", 2586408642) + TypeManager.getMethodBindPtr("AudioEffectDelay", "set_feedback_active", 2_586_408_642) internal val isFeedbackActivePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDelay", "is_feedback_active", 36873697) + TypeManager.getMethodBindPtr("AudioEffectDelay", "is_feedback_active", 36_873_697) internal val setFeedbackDelayMsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDelay", "set_feedback_delay_ms", 373806689) + TypeManager.getMethodBindPtr("AudioEffectDelay", "set_feedback_delay_ms", 373_806_689) internal val getFeedbackDelayMsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDelay", "get_feedback_delay_ms", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectDelay", "get_feedback_delay_ms", 1_740_695_150) internal val setFeedbackLevelDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDelay", "set_feedback_level_db", 373806689) + TypeManager.getMethodBindPtr("AudioEffectDelay", "set_feedback_level_db", 373_806_689) internal val getFeedbackLevelDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDelay", "get_feedback_level_db", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectDelay", "get_feedback_level_db", 1_740_695_150) internal val setFeedbackLowpassPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDelay", "set_feedback_lowpass", 373806689) + TypeManager.getMethodBindPtr("AudioEffectDelay", "set_feedback_lowpass", 373_806_689) internal val getFeedbackLowpassPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDelay", "get_feedback_lowpass", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectDelay", "get_feedback_lowpass", 1_740_695_150) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectDistortion.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectDistortion.kt index a1faaa2b0b..e2c9c5a2a9 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectDistortion.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectDistortion.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -19,15 +16,12 @@ import kotlin.Int import kotlin.Long import kotlin.NotImplementedError import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** * Different types are available: clip, tan, lo-fi (bit crushing), overdrive, or waveshape. * - * By distorting the waveform the frequency content changes, which will often make the sound - * "crunchy" or "abrasive". For games, it can simulate sound coming from some saturated device or - * speaker very efficiently. + * By distorting the waveform the frequency content changes, which will often make the sound "crunchy" or "abrasive". For games, it can simulate sound coming from some saturated device or speaker very efficiently. */ @GodotBaseType public open class AudioEffectDistortion : AudioEffect() { @@ -43,8 +37,7 @@ public open class AudioEffectDistortion : AudioEffect() { } /** - * Increases or decreases the volume before the effect, in decibels. Value can range from -60 to - * 60. + * Increases or decreases the volume before the effect, in decibels. Value can range from -60 to 60. */ public final inline var preGain: Float @JvmName("preGainProperty") @@ -55,8 +48,7 @@ public open class AudioEffectDistortion : AudioEffect() { } /** - * High-pass filter, in Hz. Frequencies higher than this value will not be affected by the - * distortion. Value can range from 1 to 20000. + * High-pass filter, in Hz. Frequencies higher than this value will not be affected by the distortion. Value can range from 1 to 20000. */ public final inline var keepHfHz: Float @JvmName("keepHfHzProperty") @@ -78,8 +70,7 @@ public open class AudioEffectDistortion : AudioEffect() { } /** - * Increases or decreases the volume after the effect, in decibels. Value can range from -80 to - * 24. + * Increases or decreases the volume after the effect, in decibels. Value can range from -80 to 24. */ public final inline var postGain: Float @JvmName("postGainProperty") @@ -89,11 +80,11 @@ public open class AudioEffectDistortion : AudioEffect() { setPostGain(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(53, scriptIndex) } - public final fun setMode(mode: Mode): Unit { + public final fun setMode(mode: Mode) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setModePtr, NIL) } @@ -104,7 +95,7 @@ public open class AudioEffectDistortion : AudioEffect() { return Mode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setPreGain(preGain: Float): Unit { + public final fun setPreGain(preGain: Float) { TransferContext.writeArguments(DOUBLE to preGain.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setPreGainPtr, NIL) } @@ -115,7 +106,7 @@ public open class AudioEffectDistortion : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setKeepHfHz(keepHfHz: Float): Unit { + public final fun setKeepHfHz(keepHfHz: Float) { TransferContext.writeArguments(DOUBLE to keepHfHz.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setKeepHfHzPtr, NIL) } @@ -126,7 +117,7 @@ public open class AudioEffectDistortion : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setDrive(drive: Float): Unit { + public final fun setDrive(drive: Float) { TransferContext.writeArguments(DOUBLE to drive.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setDrivePtr, NIL) } @@ -137,7 +128,7 @@ public open class AudioEffectDistortion : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setPostGain(postGain: Float): Unit { + public final fun setPostGain(postGain: Float) { TransferContext.writeArguments(DOUBLE to postGain.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setPostGainPtr, NIL) } @@ -151,7 +142,7 @@ public open class AudioEffectDistortion : AudioEffect() { /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _instantiate(): AudioEffectInstance? { + override fun _instantiate(): AudioEffectInstance? { throw NotImplementedError("AudioEffectDistortion::_instantiate can't be called from the JVM.") } @@ -164,18 +155,15 @@ public open class AudioEffectDistortion : AudioEffect() { CLIP(0), ATAN(1), /** - * Low-resolution digital distortion effect (bit depth reduction). You can use it to emulate the - * sound of early digital audio devices. + * Low-resolution digital distortion effect (bit depth reduction). You can use it to emulate the sound of early digital audio devices. */ LOFI(2), /** - * Emulates the warm distortion produced by a field effect transistor, which is commonly used in - * solid-state musical instrument amplifiers. The [drive] property has no effect in this mode. + * Emulates the warm distortion produced by a field effect transistor, which is commonly used in solid-state musical instrument amplifiers. The [drive] property has no effect in this mode. */ OVERDRIVE(3), /** - * Waveshaper distortions are used mainly by electronic musicians to achieve an extra-abrasive - * sound. + * Waveshaper distortions are used mainly by electronic musicians to achieve an extra-abrasive sound. */ WAVESHAPE(4), ; @@ -194,33 +182,33 @@ public open class AudioEffectDistortion : AudioEffect() { public object MethodBindings { internal val setModePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDistortion", "set_mode", 1314744793) + TypeManager.getMethodBindPtr("AudioEffectDistortion", "set_mode", 1_314_744_793) internal val getModePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDistortion", "get_mode", 809118343) + TypeManager.getMethodBindPtr("AudioEffectDistortion", "get_mode", 809_118_343) internal val setPreGainPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDistortion", "set_pre_gain", 373806689) + TypeManager.getMethodBindPtr("AudioEffectDistortion", "set_pre_gain", 373_806_689) internal val getPreGainPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDistortion", "get_pre_gain", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectDistortion", "get_pre_gain", 1_740_695_150) internal val setKeepHfHzPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDistortion", "set_keep_hf_hz", 373806689) + TypeManager.getMethodBindPtr("AudioEffectDistortion", "set_keep_hf_hz", 373_806_689) internal val getKeepHfHzPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDistortion", "get_keep_hf_hz", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectDistortion", "get_keep_hf_hz", 1_740_695_150) internal val setDrivePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDistortion", "set_drive", 373806689) + TypeManager.getMethodBindPtr("AudioEffectDistortion", "set_drive", 373_806_689) internal val getDrivePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDistortion", "get_drive", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectDistortion", "get_drive", 1_740_695_150) internal val setPostGainPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDistortion", "set_post_gain", 373806689) + TypeManager.getMethodBindPtr("AudioEffectDistortion", "set_post_gain", 373_806_689) internal val getPostGainPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectDistortion", "get_post_gain", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectDistortion", "get_post_gain", 1_740_695_150) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectEQ.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectEQ.kt index 61156f4b0b..ed8c7230bc 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectEQ.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectEQ.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -19,24 +16,20 @@ import kotlin.Int import kotlin.Long import kotlin.NotImplementedError import kotlin.Suppress -import kotlin.Unit /** - * AudioEffectEQ gives you control over frequencies. Use it to compensate for existing deficiencies - * in audio. AudioEffectEQs are useful on the Master bus to completely master a mix and give it more - * character. They are also useful when a game is run on a mobile device, to adjust the mix to that - * kind of speakers (it can be added but disabled when headphones are plugged). + * AudioEffectEQ gives you control over frequencies. Use it to compensate for existing deficiencies in audio. AudioEffectEQs are useful on the Master bus to completely master a mix and give it more character. They are also useful when a game is run on a mobile device, to adjust the mix to that kind of speakers (it can be added but disabled when headphones are plugged). */ @GodotBaseType public open class AudioEffectEQ : AudioEffect() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(54, scriptIndex) } /** * Sets band's gain at the specified index, in dB. */ - public final fun setBandGainDb(bandIdx: Int, volumeDb: Float): Unit { + public final fun setBandGainDb(bandIdx: Int, volumeDb: Float) { TransferContext.writeArguments(LONG to bandIdx.toLong(), DOUBLE to volumeDb.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setBandGainDbPtr, NIL) } @@ -62,7 +55,7 @@ public open class AudioEffectEQ : AudioEffect() { /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _instantiate(): AudioEffectInstance? { + override fun _instantiate(): AudioEffectInstance? { throw NotImplementedError("AudioEffectEQ::_instantiate can't be called from the JVM.") } @@ -70,12 +63,12 @@ public open class AudioEffectEQ : AudioEffect() { public object MethodBindings { internal val setBandGainDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectEQ", "set_band_gain_db", 1602489585) + TypeManager.getMethodBindPtr("AudioEffectEQ", "set_band_gain_db", 1_602_489_585) internal val getBandGainDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectEQ", "get_band_gain_db", 2339986948) + TypeManager.getMethodBindPtr("AudioEffectEQ", "get_band_gain_db", 2_339_986_948) internal val getBandCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectEQ", "get_band_count", 3905245786) + TypeManager.getMethodBindPtr("AudioEffectEQ", "get_band_count", 3_905_245_786) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectEQ10.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectEQ10.kt index b5363318c8..b212115c03 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectEQ10.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectEQ10.kt @@ -1,15 +1,11 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api import godot.`annotation`.GodotBaseType import kotlin.Int import kotlin.Suppress -import kotlin.Unit /** * Frequency bands: @@ -38,7 +34,7 @@ import kotlin.Unit */ @GodotBaseType public open class AudioEffectEQ10 : AudioEffectEQ() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(55, scriptIndex) } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectEQ21.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectEQ21.kt index c8cdb31e79..af9bc24265 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectEQ21.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectEQ21.kt @@ -1,15 +1,11 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api import godot.`annotation`.GodotBaseType import kotlin.Int import kotlin.Suppress -import kotlin.Unit /** * Frequency bands: @@ -60,7 +56,7 @@ import kotlin.Unit */ @GodotBaseType public open class AudioEffectEQ21 : AudioEffectEQ() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(56, scriptIndex) } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectEQ6.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectEQ6.kt index 0dd4c9a192..a89bb2b7bc 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectEQ6.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectEQ6.kt @@ -1,15 +1,11 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api import godot.`annotation`.GodotBaseType import kotlin.Int import kotlin.Suppress -import kotlin.Unit /** * Frequency bands: @@ -30,7 +26,7 @@ import kotlin.Unit */ @GodotBaseType public open class AudioEffectEQ6 : AudioEffectEQ() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(57, scriptIndex) } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectFilter.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectFilter.kt index 13b1d78d58..8d7bacde74 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectFilter.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectFilter.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -19,7 +16,6 @@ import kotlin.Int import kotlin.Long import kotlin.NotImplementedError import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** @@ -61,8 +57,7 @@ public open class AudioEffectFilter : AudioEffect() { } /** - * Steepness of the cutoff curve in dB per octave, also known as the order of the filter. Higher - * orders have a more aggressive cutoff. + * Steepness of the cutoff curve in dB per octave, also known as the order of the filter. Higher orders have a more aggressive cutoff. */ public final inline var db: FilterDB @JvmName("dbProperty") @@ -72,11 +67,11 @@ public open class AudioEffectFilter : AudioEffect() { setDb(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(58, scriptIndex) } - public final fun setCutoff(freq: Float): Unit { + public final fun setCutoff(freq: Float) { TransferContext.writeArguments(DOUBLE to freq.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setCutoffPtr, NIL) } @@ -87,7 +82,7 @@ public open class AudioEffectFilter : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setResonance(amount: Float): Unit { + public final fun setResonance(amount: Float) { TransferContext.writeArguments(DOUBLE to amount.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setResonancePtr, NIL) } @@ -98,7 +93,7 @@ public open class AudioEffectFilter : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setGain(amount: Float): Unit { + public final fun setGain(amount: Float) { TransferContext.writeArguments(DOUBLE to amount.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setGainPtr, NIL) } @@ -109,7 +104,7 @@ public open class AudioEffectFilter : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setDb(amount: FilterDB): Unit { + public final fun setDb(amount: FilterDB) { TransferContext.writeArguments(LONG to amount.id) TransferContext.callMethod(ptr, MethodBindings.setDbPtr, NIL) } @@ -123,7 +118,7 @@ public open class AudioEffectFilter : AudioEffect() { /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _instantiate(): AudioEffectInstance? { + override fun _instantiate(): AudioEffectInstance? { throw NotImplementedError("AudioEffectFilter::_instantiate can't be called from the JVM.") } @@ -162,27 +157,27 @@ public open class AudioEffectFilter : AudioEffect() { public object MethodBindings { internal val setCutoffPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectFilter", "set_cutoff", 373806689) + TypeManager.getMethodBindPtr("AudioEffectFilter", "set_cutoff", 373_806_689) internal val getCutoffPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectFilter", "get_cutoff", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectFilter", "get_cutoff", 1_740_695_150) internal val setResonancePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectFilter", "set_resonance", 373806689) + TypeManager.getMethodBindPtr("AudioEffectFilter", "set_resonance", 373_806_689) internal val getResonancePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectFilter", "get_resonance", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectFilter", "get_resonance", 1_740_695_150) internal val setGainPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectFilter", "set_gain", 373806689) + TypeManager.getMethodBindPtr("AudioEffectFilter", "set_gain", 373_806_689) internal val getGainPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectFilter", "get_gain", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectFilter", "get_gain", 1_740_695_150) internal val setDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectFilter", "set_db", 771740901) + TypeManager.getMethodBindPtr("AudioEffectFilter", "set_db", 771_740_901) internal val getDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectFilter", "get_db", 3981721890) + TypeManager.getMethodBindPtr("AudioEffectFilter", "get_db", 3_981_721_890) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectHardLimiter.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectHardLimiter.kt index 4486a8655c..06adbcda97 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectHardLimiter.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectHardLimiter.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -17,15 +14,10 @@ import kotlin.Float import kotlin.Int import kotlin.NotImplementedError import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * A limiter is an effect designed to disallow sound from going over a given dB threshold. Hard - * limiters predict volume peaks, and will smoothly apply gain reduction when a peak crosses the - * ceiling threshold to prevent clipping and distortion. It preserves the waveform and prevents it from - * crossing the ceiling threshold. Adding one in the Master bus is recommended as a safety measure to - * prevent sudden volume peaks from occurring, and to prevent distortion caused by clipping. + * A limiter is an effect designed to disallow sound from going over a given dB threshold. Hard limiters predict volume peaks, and will smoothly apply gain reduction when a peak crosses the ceiling threshold to prevent clipping and distortion. It preserves the waveform and prevents it from crossing the ceiling threshold. Adding one in the Master bus is recommended as a safety measure to prevent sudden volume peaks from occurring, and to prevent distortion caused by clipping. */ @GodotBaseType public open class AudioEffectHardLimiter : AudioEffect() { @@ -43,8 +35,7 @@ public open class AudioEffectHardLimiter : AudioEffect() { /** * The waveform's maximum allowed value, in decibels. This value can range from `-24.0` to `0.0`. * - * The default value of `-0.3` prevents potential inter-sample peaks (ISP) from crossing over 0 - * dB, which can cause slight distortion on some older hardware. + * The default value of `-0.3` prevents potential inter-sample peaks (ISP) from crossing over 0 dB, which can cause slight distortion on some older hardware. */ public final inline var ceilingDb: Float @JvmName("ceilingDbProperty") @@ -65,11 +56,11 @@ public open class AudioEffectHardLimiter : AudioEffect() { setRelease(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(59, scriptIndex) } - public final fun setCeilingDb(ceiling: Float): Unit { + public final fun setCeilingDb(ceiling: Float) { TransferContext.writeArguments(DOUBLE to ceiling.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setCeilingDbPtr, NIL) } @@ -80,7 +71,7 @@ public open class AudioEffectHardLimiter : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setPreGainDb(pPreGain: Float): Unit { + public final fun setPreGainDb(pPreGain: Float) { TransferContext.writeArguments(DOUBLE to pPreGain.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setPreGainDbPtr, NIL) } @@ -91,7 +82,7 @@ public open class AudioEffectHardLimiter : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setRelease(pRelease: Float): Unit { + public final fun setRelease(pRelease: Float) { TransferContext.writeArguments(DOUBLE to pRelease.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setReleasePtr, NIL) } @@ -105,7 +96,7 @@ public open class AudioEffectHardLimiter : AudioEffect() { /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _instantiate(): AudioEffectInstance? { + override fun _instantiate(): AudioEffectInstance? { throw NotImplementedError("AudioEffectHardLimiter::_instantiate can't be called from the JVM.") } @@ -113,21 +104,21 @@ public open class AudioEffectHardLimiter : AudioEffect() { public object MethodBindings { internal val setCeilingDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectHardLimiter", "set_ceiling_db", 373806689) + TypeManager.getMethodBindPtr("AudioEffectHardLimiter", "set_ceiling_db", 373_806_689) internal val getCeilingDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectHardLimiter", "get_ceiling_db", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectHardLimiter", "get_ceiling_db", 1_740_695_150) internal val setPreGainDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectHardLimiter", "set_pre_gain_db", 373806689) + TypeManager.getMethodBindPtr("AudioEffectHardLimiter", "set_pre_gain_db", 373_806_689) internal val getPreGainDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectHardLimiter", "get_pre_gain_db", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectHardLimiter", "get_pre_gain_db", 1_740_695_150) internal val setReleasePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectHardLimiter", "set_release", 373806689) + TypeManager.getMethodBindPtr("AudioEffectHardLimiter", "set_release", 373_806_689) internal val getReleasePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectHardLimiter", "get_release", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectHardLimiter", "get_release", 1_740_695_150) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectHighPassFilter.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectHighPassFilter.kt index 070a9b1086..f71f97619b 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectHighPassFilter.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectHighPassFilter.kt @@ -1,23 +1,18 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api import godot.`annotation`.GodotBaseType import kotlin.Int import kotlin.Suppress -import kotlin.Unit /** - * Cuts frequencies lower than the [AudioEffectFilter.cutoffHz] and allows higher frequencies to - * pass. + * Cuts frequencies lower than the [AudioEffectFilter.cutoffHz] and allows higher frequencies to pass. */ @GodotBaseType public open class AudioEffectHighPassFilter : AudioEffectFilter() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(60, scriptIndex) } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectHighShelfFilter.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectHighShelfFilter.kt index 1e11415425..f34b76c77f 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectHighShelfFilter.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectHighShelfFilter.kt @@ -1,22 +1,18 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api import godot.`annotation`.GodotBaseType import kotlin.Int import kotlin.Suppress -import kotlin.Unit /** * Reduces all frequencies above the [AudioEffectFilter.cutoffHz]. */ @GodotBaseType public open class AudioEffectHighShelfFilter : AudioEffectFilter() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(61, scriptIndex) } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectInstance.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectInstance.kt index 17362f9126..0682fd5233 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectInstance.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectInstance.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -11,25 +8,20 @@ import kotlin.Boolean import kotlin.Int import kotlin.NotImplementedError import kotlin.Suppress -import kotlin.Unit /** - * An audio effect instance manipulates the audio it receives for a given effect. This instance is - * automatically created by an [AudioEffect] when it is added to a bus, and should usually not be - * created directly. If necessary, it can be fetched at run-time with - * [AudioServer.getBusEffectInstance]. + * An audio effect instance manipulates the audio it receives for a given effect. This instance is automatically created by an [AudioEffect] when it is added to a bus, and should usually not be created directly. If necessary, it can be fetched at run-time with [AudioServer.getBusEffectInstance]. */ @GodotBaseType public abstract class AudioEffectInstance : RefCounted() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(62, scriptIndex) } /** * Override this method to customize the processing behavior of this effect instance. * - * Should return `true` to force the [AudioServer] to always call [_process], even if the bus has - * been muted or cannot otherwise be heard. + * Should return `true` to force the [AudioServer] to always call [_process], even if the bus has been muted or cannot otherwise be heard. */ public open fun _processSilence(): Boolean { throw NotImplementedError("AudioEffectInstance::_processSilence is not implemented.") diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectLimiter.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectLimiter.kt index 6391ca695d..54a4aa6619 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectLimiter.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectLimiter.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -17,16 +14,12 @@ import kotlin.Float import kotlin.Int import kotlin.NotImplementedError import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * A limiter is similar to a compressor, but it's less flexible and designed to disallow sound going - * over a given dB threshold. Adding one in the Master bus is always recommended to reduce the effects - * of clipping. + * A limiter is similar to a compressor, but it's less flexible and designed to disallow sound going over a given dB threshold. Adding one in the Master bus is always recommended to reduce the effects of clipping. * - * Soft clipping starts to reduce the peaks a little below the threshold level and progressively - * increases its effect as the input level increases such that the threshold is never exceeded. + * Soft clipping starts to reduce the peaks a little below the threshold level and progressively increases its effect as the input level increases such that the threshold is never exceeded. */ @GodotBaseType public open class AudioEffectLimiter : AudioEffect() { @@ -42,8 +35,7 @@ public open class AudioEffectLimiter : AudioEffect() { } /** - * Threshold from which the limiter begins to be active, in decibels. Value can range from -30 to - * 0. + * Threshold from which the limiter begins to be active, in decibels. Value can range from -30 to 0. */ public final inline var thresholdDb: Float @JvmName("thresholdDbProperty") @@ -72,11 +64,11 @@ public open class AudioEffectLimiter : AudioEffect() { setSoftClipRatio(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(63, scriptIndex) } - public final fun setCeilingDb(ceiling: Float): Unit { + public final fun setCeilingDb(ceiling: Float) { TransferContext.writeArguments(DOUBLE to ceiling.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setCeilingDbPtr, NIL) } @@ -87,7 +79,7 @@ public open class AudioEffectLimiter : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setThresholdDb(threshold: Float): Unit { + public final fun setThresholdDb(threshold: Float) { TransferContext.writeArguments(DOUBLE to threshold.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setThresholdDbPtr, NIL) } @@ -98,7 +90,7 @@ public open class AudioEffectLimiter : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setSoftClipDb(softClip: Float): Unit { + public final fun setSoftClipDb(softClip: Float) { TransferContext.writeArguments(DOUBLE to softClip.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setSoftClipDbPtr, NIL) } @@ -109,7 +101,7 @@ public open class AudioEffectLimiter : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setSoftClipRatio(softClip: Float): Unit { + public final fun setSoftClipRatio(softClip: Float) { TransferContext.writeArguments(DOUBLE to softClip.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setSoftClipRatioPtr, NIL) } @@ -123,7 +115,7 @@ public open class AudioEffectLimiter : AudioEffect() { /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _instantiate(): AudioEffectInstance? { + override fun _instantiate(): AudioEffectInstance? { throw NotImplementedError("AudioEffectLimiter::_instantiate can't be called from the JVM.") } @@ -131,27 +123,27 @@ public open class AudioEffectLimiter : AudioEffect() { public object MethodBindings { internal val setCeilingDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectLimiter", "set_ceiling_db", 373806689) + TypeManager.getMethodBindPtr("AudioEffectLimiter", "set_ceiling_db", 373_806_689) internal val getCeilingDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectLimiter", "get_ceiling_db", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectLimiter", "get_ceiling_db", 1_740_695_150) internal val setThresholdDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectLimiter", "set_threshold_db", 373806689) + TypeManager.getMethodBindPtr("AudioEffectLimiter", "set_threshold_db", 373_806_689) internal val getThresholdDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectLimiter", "get_threshold_db", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectLimiter", "get_threshold_db", 1_740_695_150) internal val setSoftClipDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectLimiter", "set_soft_clip_db", 373806689) + TypeManager.getMethodBindPtr("AudioEffectLimiter", "set_soft_clip_db", 373_806_689) internal val getSoftClipDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectLimiter", "get_soft_clip_db", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectLimiter", "get_soft_clip_db", 1_740_695_150) internal val setSoftClipRatioPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectLimiter", "set_soft_clip_ratio", 373806689) + TypeManager.getMethodBindPtr("AudioEffectLimiter", "set_soft_clip_ratio", 373_806_689) internal val getSoftClipRatioPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectLimiter", "get_soft_clip_ratio", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectLimiter", "get_soft_clip_ratio", 1_740_695_150) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectLowPassFilter.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectLowPassFilter.kt index 001623de9b..ef5309d062 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectLowPassFilter.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectLowPassFilter.kt @@ -1,23 +1,18 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api import godot.`annotation`.GodotBaseType import kotlin.Int import kotlin.Suppress -import kotlin.Unit /** - * Cuts frequencies higher than the [AudioEffectFilter.cutoffHz] and allows lower frequencies to - * pass. + * Cuts frequencies higher than the [AudioEffectFilter.cutoffHz] and allows lower frequencies to pass. */ @GodotBaseType public open class AudioEffectLowPassFilter : AudioEffectFilter() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(64, scriptIndex) } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectLowShelfFilter.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectLowShelfFilter.kt index caff506419..6c768b0196 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectLowShelfFilter.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectLowShelfFilter.kt @@ -1,22 +1,18 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api import godot.`annotation`.GodotBaseType import kotlin.Int import kotlin.Suppress -import kotlin.Unit /** * Reduces all frequencies below the [AudioEffectFilter.cutoffHz]. */ @GodotBaseType public open class AudioEffectLowShelfFilter : AudioEffectFilter() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(65, scriptIndex) } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectNotchFilter.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectNotchFilter.kt index 0f1d98d4c1..45153d91d7 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectNotchFilter.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectNotchFilter.kt @@ -1,23 +1,18 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api import godot.`annotation`.GodotBaseType import kotlin.Int import kotlin.Suppress -import kotlin.Unit /** - * Attenuates frequencies in a narrow band around the [AudioEffectFilter.cutoffHz] and cuts - * frequencies outside of this range. + * Attenuates frequencies in a narrow band around the [AudioEffectFilter.cutoffHz] and cuts frequencies outside of this range. */ @GodotBaseType public open class AudioEffectNotchFilter : AudioEffectFilter() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(66, scriptIndex) } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectPanner.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectPanner.kt index e5f3799cca..f48c0313af 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectPanner.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectPanner.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -17,7 +14,6 @@ import kotlin.Float import kotlin.Int import kotlin.NotImplementedError import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** @@ -36,11 +32,11 @@ public open class AudioEffectPanner : AudioEffect() { setPan(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(67, scriptIndex) } - public final fun setPan(cpanume: Float): Unit { + public final fun setPan(cpanume: Float) { TransferContext.writeArguments(DOUBLE to cpanume.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setPanPtr, NIL) } @@ -54,7 +50,7 @@ public open class AudioEffectPanner : AudioEffect() { /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _instantiate(): AudioEffectInstance? { + override fun _instantiate(): AudioEffectInstance? { throw NotImplementedError("AudioEffectPanner::_instantiate can't be called from the JVM.") } @@ -62,9 +58,9 @@ public open class AudioEffectPanner : AudioEffect() { public object MethodBindings { internal val setPanPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectPanner", "set_pan", 373806689) + TypeManager.getMethodBindPtr("AudioEffectPanner", "set_pan", 373_806_689) internal val getPanPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectPanner", "get_pan", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectPanner", "get_pan", 1_740_695_150) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectPhaser.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectPhaser.kt index e7e2a813bb..a127202f17 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectPhaser.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectPhaser.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -17,18 +14,15 @@ import kotlin.Float import kotlin.Int import kotlin.NotImplementedError import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * Combines phase-shifted signals with the original signal. The movement of the phase-shifted - * signals is controlled using a low-frequency oscillator. + * Combines phase-shifted signals with the original signal. The movement of the phase-shifted signals is controlled using a low-frequency oscillator. */ @GodotBaseType public open class AudioEffectPhaser : AudioEffect() { /** - * Determines the minimum frequency affected by the LFO modulations, in Hz. Value can range from - * 10 to 10000. + * Determines the minimum frequency affected by the LFO modulations, in Hz. Value can range from 10 to 10000. */ public final inline var rangeMinHz: Float @JvmName("rangeMinHzProperty") @@ -39,8 +33,7 @@ public open class AudioEffectPhaser : AudioEffect() { } /** - * Determines the maximum frequency affected by the LFO modulations, in Hz. Value can range from - * 10 to 10000. + * Determines the maximum frequency affected by the LFO modulations, in Hz. Value can range from 10 to 10000. */ public final inline var rangeMaxHz: Float @JvmName("rangeMaxHzProperty") @@ -73,8 +66,7 @@ public open class AudioEffectPhaser : AudioEffect() { } /** - * Governs how high the filter frequencies sweep. Low value will primarily affect bass - * frequencies. High value can sweep high into the treble. Value can range from 0.1 to 4. + * Governs how high the filter frequencies sweep. Low value will primarily affect bass frequencies. High value can sweep high into the treble. Value can range from 0.1 to 4. */ public final inline var depth: Float @JvmName("depthProperty") @@ -84,11 +76,11 @@ public open class AudioEffectPhaser : AudioEffect() { setDepth(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(68, scriptIndex) } - public final fun setRangeMinHz(hz: Float): Unit { + public final fun setRangeMinHz(hz: Float) { TransferContext.writeArguments(DOUBLE to hz.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setRangeMinHzPtr, NIL) } @@ -99,7 +91,7 @@ public open class AudioEffectPhaser : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setRangeMaxHz(hz: Float): Unit { + public final fun setRangeMaxHz(hz: Float) { TransferContext.writeArguments(DOUBLE to hz.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setRangeMaxHzPtr, NIL) } @@ -110,7 +102,7 @@ public open class AudioEffectPhaser : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setRateHz(hz: Float): Unit { + public final fun setRateHz(hz: Float) { TransferContext.writeArguments(DOUBLE to hz.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setRateHzPtr, NIL) } @@ -121,7 +113,7 @@ public open class AudioEffectPhaser : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setFeedback(fbk: Float): Unit { + public final fun setFeedback(fbk: Float) { TransferContext.writeArguments(DOUBLE to fbk.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setFeedbackPtr, NIL) } @@ -132,7 +124,7 @@ public open class AudioEffectPhaser : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setDepth(depth: Float): Unit { + public final fun setDepth(depth: Float) { TransferContext.writeArguments(DOUBLE to depth.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setDepthPtr, NIL) } @@ -146,7 +138,7 @@ public open class AudioEffectPhaser : AudioEffect() { /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _instantiate(): AudioEffectInstance? { + override fun _instantiate(): AudioEffectInstance? { throw NotImplementedError("AudioEffectPhaser::_instantiate can't be called from the JVM.") } @@ -154,33 +146,33 @@ public open class AudioEffectPhaser : AudioEffect() { public object MethodBindings { internal val setRangeMinHzPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectPhaser", "set_range_min_hz", 373806689) + TypeManager.getMethodBindPtr("AudioEffectPhaser", "set_range_min_hz", 373_806_689) internal val getRangeMinHzPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectPhaser", "get_range_min_hz", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectPhaser", "get_range_min_hz", 1_740_695_150) internal val setRangeMaxHzPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectPhaser", "set_range_max_hz", 373806689) + TypeManager.getMethodBindPtr("AudioEffectPhaser", "set_range_max_hz", 373_806_689) internal val getRangeMaxHzPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectPhaser", "get_range_max_hz", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectPhaser", "get_range_max_hz", 1_740_695_150) internal val setRateHzPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectPhaser", "set_rate_hz", 373806689) + TypeManager.getMethodBindPtr("AudioEffectPhaser", "set_rate_hz", 373_806_689) internal val getRateHzPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectPhaser", "get_rate_hz", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectPhaser", "get_rate_hz", 1_740_695_150) internal val setFeedbackPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectPhaser", "set_feedback", 373806689) + TypeManager.getMethodBindPtr("AudioEffectPhaser", "set_feedback", 373_806_689) internal val getFeedbackPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectPhaser", "get_feedback", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectPhaser", "get_feedback", 1_740_695_150) internal val setDepthPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectPhaser", "set_depth", 373806689) + TypeManager.getMethodBindPtr("AudioEffectPhaser", "set_depth", 373_806_689) internal val getDepthPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectPhaser", "get_depth", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectPhaser", "get_depth", 1_740_695_150) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectPitchShift.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectPitchShift.kt index ffd6a16cb0..292f826e45 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectPitchShift.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectPitchShift.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -19,19 +16,15 @@ import kotlin.Int import kotlin.Long import kotlin.NotImplementedError import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * Allows modulation of pitch independently of tempo. All frequencies can be increased/decreased - * with minimal effect on transients. + * Allows modulation of pitch independently of tempo. All frequencies can be increased/decreased with minimal effect on transients. */ @GodotBaseType public open class AudioEffectPitchShift : AudioEffect() { /** - * The pitch scale to use. `1.0` is the default pitch and plays sounds unaffected. [pitchScale] - * can range from `0.0` (infinitely low pitch, inaudible) to `16` (16 times higher than the initial - * pitch). + * The pitch scale to use. `1.0` is the default pitch and plays sounds unaffected. [pitchScale] can range from `0.0` (infinitely low pitch, inaudible) to `16` (16 times higher than the initial pitch). */ public final inline var pitchScale: Float @JvmName("pitchScaleProperty") @@ -42,8 +35,7 @@ public open class AudioEffectPitchShift : AudioEffect() { } /** - * The oversampling factor to use. Higher values result in better quality, but are more demanding - * on the CPU and may cause audio cracking if the CPU can't keep up. + * The oversampling factor to use. Higher values result in better quality, but are more demanding on the CPU and may cause audio cracking if the CPU can't keep up. */ public final inline var oversampling: Int @JvmName("oversamplingProperty") @@ -54,10 +46,7 @@ public open class AudioEffectPitchShift : AudioEffect() { } /** - * The size of the [url=https://en.wikipedia.org/wiki/Fast_Fourier_transform]Fast Fourier - * transform[/url] buffer. Higher values smooth out the effect over time, but have greater latency. - * The effects of this higher latency are especially noticeable on sounds that have sudden amplitude - * changes. + * The size of the [url=https://en.wikipedia.org/wiki/Fast_Fourier_transform]Fast Fourier transform[/url] buffer. Higher values smooth out the effect over time, but have greater latency. The effects of this higher latency are especially noticeable on sounds that have sudden amplitude changes. */ public final inline var fftSize: FFTSize @JvmName("fftSizeProperty") @@ -67,11 +56,11 @@ public open class AudioEffectPitchShift : AudioEffect() { setFftSize(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(69, scriptIndex) } - public final fun setPitchScale(rate: Float): Unit { + public final fun setPitchScale(rate: Float) { TransferContext.writeArguments(DOUBLE to rate.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setPitchScalePtr, NIL) } @@ -82,7 +71,7 @@ public open class AudioEffectPitchShift : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setOversampling(amount: Int): Unit { + public final fun setOversampling(amount: Int) { TransferContext.writeArguments(LONG to amount.toLong()) TransferContext.callMethod(ptr, MethodBindings.setOversamplingPtr, NIL) } @@ -93,7 +82,7 @@ public open class AudioEffectPitchShift : AudioEffect() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setFftSize(size: FFTSize): Unit { + public final fun setFftSize(size: FFTSize) { TransferContext.writeArguments(LONG to size.id) TransferContext.callMethod(ptr, MethodBindings.setFftSizePtr, NIL) } @@ -107,7 +96,7 @@ public open class AudioEffectPitchShift : AudioEffect() { /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _instantiate(): AudioEffectInstance? { + override fun _instantiate(): AudioEffectInstance? { throw NotImplementedError("AudioEffectPitchShift::_instantiate can't be called from the JVM.") } @@ -115,28 +104,23 @@ public open class AudioEffectPitchShift : AudioEffect() { id: Long, ) { /** - * Use a buffer of 256 samples for the Fast Fourier transform. Lowest latency, but least stable - * over time. + * Use a buffer of 256 samples for the Fast Fourier transform. Lowest latency, but least stable over time. */ FFT_SIZE_256(0), /** - * Use a buffer of 512 samples for the Fast Fourier transform. Low latency, but less stable over - * time. + * Use a buffer of 512 samples for the Fast Fourier transform. Low latency, but less stable over time. */ FFT_SIZE_512(1), /** - * Use a buffer of 1024 samples for the Fast Fourier transform. This is a compromise between - * latency and stability over time. + * Use a buffer of 1024 samples for the Fast Fourier transform. This is a compromise between latency and stability over time. */ FFT_SIZE_1024(2), /** - * Use a buffer of 2048 samples for the Fast Fourier transform. High latency, but stable over - * time. + * Use a buffer of 2048 samples for the Fast Fourier transform. High latency, but stable over time. */ FFT_SIZE_2048(3), /** - * Use a buffer of 4096 samples for the Fast Fourier transform. Highest latency, but most stable - * over time. + * Use a buffer of 4096 samples for the Fast Fourier transform. Highest latency, but most stable over time. */ FFT_SIZE_4096(4), /** @@ -159,21 +143,21 @@ public open class AudioEffectPitchShift : AudioEffect() { public object MethodBindings { internal val setPitchScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectPitchShift", "set_pitch_scale", 373806689) + TypeManager.getMethodBindPtr("AudioEffectPitchShift", "set_pitch_scale", 373_806_689) internal val getPitchScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectPitchShift", "get_pitch_scale", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectPitchShift", "get_pitch_scale", 1_740_695_150) internal val setOversamplingPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectPitchShift", "set_oversampling", 1286410249) + TypeManager.getMethodBindPtr("AudioEffectPitchShift", "set_oversampling", 1_286_410_249) internal val getOversamplingPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectPitchShift", "get_oversampling", 3905245786) + TypeManager.getMethodBindPtr("AudioEffectPitchShift", "get_oversampling", 3_905_245_786) internal val setFftSizePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectPitchShift", "set_fft_size", 2323518741) + TypeManager.getMethodBindPtr("AudioEffectPitchShift", "set_fft_size", 2_323_518_741) internal val getFftSizePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectPitchShift", "get_fft_size", 2361246789) + TypeManager.getMethodBindPtr("AudioEffectPitchShift", "get_fft_size", 2_361_246_789) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectRecord.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectRecord.kt index 3231c21ac7..0deefd7b58 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectRecord.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectRecord.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -19,27 +16,21 @@ import kotlin.Int import kotlin.Long import kotlin.NotImplementedError import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * Allows the user to record the sound from an audio bus into an [AudioStreamWAV]. When used on the - * "Master" audio bus, this includes all audio output by Godot. + * Allows the user to record the sound from an audio bus into an [AudioStreamWAV]. When used on the "Master" audio bus, this includes all audio output by Godot. * - * Unlike [AudioEffectCapture], this effect encodes the recording with the given format (8-bit, - * 16-bit, or compressed) instead of giving access to the raw audio samples. + * Unlike [AudioEffectCapture], this effect encodes the recording with the given format (8-bit, 16-bit, or compressed) instead of giving access to the raw audio samples. * * Can be used (with an [AudioStreamMicrophone]) to record from a microphone. * - * **Note:** [ProjectSettings.audio/driver/enableInput] must be `true` for audio input to work. See - * also that setting's description for caveats related to permissions and operating system privacy - * settings. + * **Note:** [ProjectSettings.audio/driver/enableInput] must be `true` for audio input to work. See also that setting's description for caveats related to permissions and operating system privacy settings. */ @GodotBaseType public open class AudioEffectRecord : AudioEffect() { /** - * Specifies the format in which the sample will be recorded. See [AudioStreamWAV.Format] for - * available formats. + * Specifies the format in which the sample will be recorded. See [AudioStreamWAV.Format] for available formats. */ public final inline var format: AudioStreamWAV.Format @JvmName("formatProperty") @@ -49,15 +40,14 @@ public open class AudioEffectRecord : AudioEffect() { setFormat(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(70, scriptIndex) } /** - * If `true`, the sound will be recorded. Note that restarting the recording will remove the - * previously recorded sample. + * If `true`, the sound will be recorded. Note that restarting the recording will remove the previously recorded sample. */ - public final fun setRecordingActive(record: Boolean): Unit { + public final fun setRecordingActive(record: Boolean) { TransferContext.writeArguments(BOOL to record) TransferContext.callMethod(ptr, MethodBindings.setRecordingActivePtr, NIL) } @@ -71,7 +61,7 @@ public open class AudioEffectRecord : AudioEffect() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setFormat(format: AudioStreamWAV.Format): Unit { + public final fun setFormat(format: AudioStreamWAV.Format) { TransferContext.writeArguments(LONG to format.id) TransferContext.callMethod(ptr, MethodBindings.setFormatPtr, NIL) } @@ -94,7 +84,7 @@ public open class AudioEffectRecord : AudioEffect() { /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _instantiate(): AudioEffectInstance? { + override fun _instantiate(): AudioEffectInstance? { throw NotImplementedError("AudioEffectRecord::_instantiate can't be called from the JVM.") } @@ -102,18 +92,18 @@ public open class AudioEffectRecord : AudioEffect() { public object MethodBindings { internal val setRecordingActivePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectRecord", "set_recording_active", 2586408642) + TypeManager.getMethodBindPtr("AudioEffectRecord", "set_recording_active", 2_586_408_642) internal val isRecordingActivePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectRecord", "is_recording_active", 36873697) + TypeManager.getMethodBindPtr("AudioEffectRecord", "is_recording_active", 36_873_697) internal val setFormatPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectRecord", "set_format", 60648488) + TypeManager.getMethodBindPtr("AudioEffectRecord", "set_format", 60_648_488) internal val getFormatPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectRecord", "get_format", 3151724922) + TypeManager.getMethodBindPtr("AudioEffectRecord", "get_format", 3_151_724_922) internal val getRecordingPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectRecord", "get_recording", 2964110865) + TypeManager.getMethodBindPtr("AudioEffectRecord", "get_recording", 2_964_110_865) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectReverb.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectReverb.kt index e1bd7611f0..8cb2f1f522 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectReverb.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectReverb.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -17,18 +14,15 @@ import kotlin.Float import kotlin.Int import kotlin.NotImplementedError import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * Simulates the sound of acoustic environments such as rooms, concert halls, caverns, or an open - * spaces. + * Simulates the sound of acoustic environments such as rooms, concert halls, caverns, or an open spaces. */ @GodotBaseType public open class AudioEffectReverb : AudioEffect() { /** - * Time between the original signal and the early reflections of the reverb signal, in - * milliseconds. + * Time between the original signal and the early reflections of the reverb signal, in milliseconds. */ public final inline var predelayMsec: Float @JvmName("predelayMsecProperty") @@ -72,8 +66,7 @@ public open class AudioEffectReverb : AudioEffect() { } /** - * Widens or narrows the stereo image of the reverb tail. 1 means fully widens. Value can range - * from 0 to 1. + * Widens or narrows the stereo image of the reverb tail. 1 means fully widens. Value can range from 0 to 1. */ public final inline var spread: Float @JvmName("spreadProperty") @@ -84,8 +77,7 @@ public open class AudioEffectReverb : AudioEffect() { } /** - * High-pass filter passes signals with a frequency higher than a certain cutoff frequency and - * attenuates signals with frequencies lower than the cutoff frequency. Value can range from 0 to 1. + * High-pass filter passes signals with a frequency higher than a certain cutoff frequency and attenuates signals with frequencies lower than the cutoff frequency. Value can range from 0 to 1. */ public final inline var hipass: Float @JvmName("hipassProperty") @@ -96,8 +88,7 @@ public open class AudioEffectReverb : AudioEffect() { } /** - * Output percent of original sound. At 0, only modified sound is outputted. Value can range from - * 0 to 1. + * Output percent of original sound. At 0, only modified sound is outputted. Value can range from 0 to 1. */ public final inline var dry: Float @JvmName("dryProperty") @@ -108,8 +99,7 @@ public open class AudioEffectReverb : AudioEffect() { } /** - * Output percent of modified sound. At 0, only original sound is outputted. Value can range from - * 0 to 1. + * Output percent of modified sound. At 0, only original sound is outputted. Value can range from 0 to 1. */ public final inline var wet: Float @JvmName("wetProperty") @@ -119,11 +109,11 @@ public open class AudioEffectReverb : AudioEffect() { setWet(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(71, scriptIndex) } - public final fun setPredelayMsec(msec: Float): Unit { + public final fun setPredelayMsec(msec: Float) { TransferContext.writeArguments(DOUBLE to msec.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setPredelayMsecPtr, NIL) } @@ -134,7 +124,7 @@ public open class AudioEffectReverb : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setPredelayFeedback(feedback: Float): Unit { + public final fun setPredelayFeedback(feedback: Float) { TransferContext.writeArguments(DOUBLE to feedback.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setPredelayFeedbackPtr, NIL) } @@ -145,7 +135,7 @@ public open class AudioEffectReverb : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setRoomSize(size: Float): Unit { + public final fun setRoomSize(size: Float) { TransferContext.writeArguments(DOUBLE to size.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setRoomSizePtr, NIL) } @@ -156,7 +146,7 @@ public open class AudioEffectReverb : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setDamping(amount: Float): Unit { + public final fun setDamping(amount: Float) { TransferContext.writeArguments(DOUBLE to amount.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setDampingPtr, NIL) } @@ -167,7 +157,7 @@ public open class AudioEffectReverb : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setSpread(amount: Float): Unit { + public final fun setSpread(amount: Float) { TransferContext.writeArguments(DOUBLE to amount.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setSpreadPtr, NIL) } @@ -178,7 +168,7 @@ public open class AudioEffectReverb : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setDry(amount: Float): Unit { + public final fun setDry(amount: Float) { TransferContext.writeArguments(DOUBLE to amount.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setDryPtr, NIL) } @@ -189,7 +179,7 @@ public open class AudioEffectReverb : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setWet(amount: Float): Unit { + public final fun setWet(amount: Float) { TransferContext.writeArguments(DOUBLE to amount.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setWetPtr, NIL) } @@ -200,7 +190,7 @@ public open class AudioEffectReverb : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setHpf(amount: Float): Unit { + public final fun setHpf(amount: Float) { TransferContext.writeArguments(DOUBLE to amount.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setHpfPtr, NIL) } @@ -214,7 +204,7 @@ public open class AudioEffectReverb : AudioEffect() { /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _instantiate(): AudioEffectInstance? { + override fun _instantiate(): AudioEffectInstance? { throw NotImplementedError("AudioEffectReverb::_instantiate can't be called from the JVM.") } @@ -222,51 +212,51 @@ public open class AudioEffectReverb : AudioEffect() { public object MethodBindings { internal val setPredelayMsecPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectReverb", "set_predelay_msec", 373806689) + TypeManager.getMethodBindPtr("AudioEffectReverb", "set_predelay_msec", 373_806_689) internal val getPredelayMsecPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectReverb", "get_predelay_msec", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectReverb", "get_predelay_msec", 1_740_695_150) internal val setPredelayFeedbackPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectReverb", "set_predelay_feedback", 373806689) + TypeManager.getMethodBindPtr("AudioEffectReverb", "set_predelay_feedback", 373_806_689) internal val getPredelayFeedbackPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectReverb", "get_predelay_feedback", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectReverb", "get_predelay_feedback", 1_740_695_150) internal val setRoomSizePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectReverb", "set_room_size", 373806689) + TypeManager.getMethodBindPtr("AudioEffectReverb", "set_room_size", 373_806_689) internal val getRoomSizePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectReverb", "get_room_size", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectReverb", "get_room_size", 1_740_695_150) internal val setDampingPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectReverb", "set_damping", 373806689) + TypeManager.getMethodBindPtr("AudioEffectReverb", "set_damping", 373_806_689) internal val getDampingPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectReverb", "get_damping", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectReverb", "get_damping", 1_740_695_150) internal val setSpreadPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectReverb", "set_spread", 373806689) + TypeManager.getMethodBindPtr("AudioEffectReverb", "set_spread", 373_806_689) internal val getSpreadPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectReverb", "get_spread", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectReverb", "get_spread", 1_740_695_150) internal val setDryPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectReverb", "set_dry", 373806689) + TypeManager.getMethodBindPtr("AudioEffectReverb", "set_dry", 373_806_689) internal val getDryPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectReverb", "get_dry", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectReverb", "get_dry", 1_740_695_150) internal val setWetPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectReverb", "set_wet", 373806689) + TypeManager.getMethodBindPtr("AudioEffectReverb", "set_wet", 373_806_689) internal val getWetPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectReverb", "get_wet", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectReverb", "get_wet", 1_740_695_150) internal val setHpfPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectReverb", "set_hpf", 373806689) + TypeManager.getMethodBindPtr("AudioEffectReverb", "set_hpf", 373_806_689) internal val getHpfPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectReverb", "get_hpf", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectReverb", "get_hpf", 1_740_695_150) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectSpectrumAnalyzer.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectSpectrumAnalyzer.kt index aa466adda8..98c70afcda 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectSpectrumAnalyzer.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectSpectrumAnalyzer.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -19,23 +16,19 @@ import kotlin.Int import kotlin.Long import kotlin.NotImplementedError import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * This audio effect does not affect sound output, but can be used for real-time audio - * visualizations. + * This audio effect does not affect sound output, but can be used for real-time audio visualizations. * - * This resource configures an [AudioEffectSpectrumAnalyzerInstance], which performs the actual - * analysis at runtime. An instance can be obtained with [AudioServer.getBusEffectInstance]. + * This resource configures an [AudioEffectSpectrumAnalyzerInstance], which performs the actual analysis at runtime. An instance can be obtained with [AudioServer.getBusEffectInstance]. * * See also [AudioStreamGenerator] for procedurally generating sounds. */ @GodotBaseType public open class AudioEffectSpectrumAnalyzer : AudioEffect() { /** - * The length of the buffer to keep (in seconds). Higher values keep data around for longer, but - * require more memory. + * The length of the buffer to keep (in seconds). Higher values keep data around for longer, but require more memory. */ public final inline var bufferLength: Float @JvmName("bufferLengthProperty") @@ -54,10 +47,7 @@ public open class AudioEffectSpectrumAnalyzer : AudioEffect() { } /** - * The size of the [url=https://en.wikipedia.org/wiki/Fast_Fourier_transform]Fast Fourier - * transform[/url] buffer. Higher values smooth out the spectrum analysis over time, but have greater - * latency. The effects of this higher latency are especially noticeable with sudden amplitude - * changes. + * The size of the [url=https://en.wikipedia.org/wiki/Fast_Fourier_transform]Fast Fourier transform[/url] buffer. Higher values smooth out the spectrum analysis over time, but have greater latency. The effects of this higher latency are especially noticeable with sudden amplitude changes. */ public final inline var fftSize: FFTSize @JvmName("fftSizeProperty") @@ -67,11 +57,11 @@ public open class AudioEffectSpectrumAnalyzer : AudioEffect() { setFftSize(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(72, scriptIndex) } - public final fun setBufferLength(seconds: Float): Unit { + public final fun setBufferLength(seconds: Float) { TransferContext.writeArguments(DOUBLE to seconds.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setBufferLengthPtr, NIL) } @@ -82,7 +72,7 @@ public open class AudioEffectSpectrumAnalyzer : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setTapBackPos(seconds: Float): Unit { + public final fun setTapBackPos(seconds: Float) { TransferContext.writeArguments(DOUBLE to seconds.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setTapBackPosPtr, NIL) } @@ -93,7 +83,7 @@ public open class AudioEffectSpectrumAnalyzer : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setFftSize(size: FFTSize): Unit { + public final fun setFftSize(size: FFTSize) { TransferContext.writeArguments(LONG to size.id) TransferContext.callMethod(ptr, MethodBindings.setFftSizePtr, NIL) } @@ -107,7 +97,7 @@ public open class AudioEffectSpectrumAnalyzer : AudioEffect() { /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _instantiate(): AudioEffectInstance? { + override fun _instantiate(): AudioEffectInstance? { throw NotImplementedError("AudioEffectSpectrumAnalyzer::_instantiate can't be called from the JVM.") } @@ -115,28 +105,23 @@ public open class AudioEffectSpectrumAnalyzer : AudioEffect() { id: Long, ) { /** - * Use a buffer of 256 samples for the Fast Fourier transform. Lowest latency, but least stable - * over time. + * Use a buffer of 256 samples for the Fast Fourier transform. Lowest latency, but least stable over time. */ FFT_SIZE_256(0), /** - * Use a buffer of 512 samples for the Fast Fourier transform. Low latency, but less stable over - * time. + * Use a buffer of 512 samples for the Fast Fourier transform. Low latency, but less stable over time. */ FFT_SIZE_512(1), /** - * Use a buffer of 1024 samples for the Fast Fourier transform. This is a compromise between - * latency and stability over time. + * Use a buffer of 1024 samples for the Fast Fourier transform. This is a compromise between latency and stability over time. */ FFT_SIZE_1024(2), /** - * Use a buffer of 2048 samples for the Fast Fourier transform. High latency, but stable over - * time. + * Use a buffer of 2048 samples for the Fast Fourier transform. High latency, but stable over time. */ FFT_SIZE_2048(3), /** - * Use a buffer of 4096 samples for the Fast Fourier transform. Highest latency, but most stable - * over time. + * Use a buffer of 4096 samples for the Fast Fourier transform. Highest latency, but most stable over time. */ FFT_SIZE_4096(4), /** @@ -159,21 +144,21 @@ public open class AudioEffectSpectrumAnalyzer : AudioEffect() { public object MethodBindings { internal val setBufferLengthPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectSpectrumAnalyzer", "set_buffer_length", 373806689) + TypeManager.getMethodBindPtr("AudioEffectSpectrumAnalyzer", "set_buffer_length", 373_806_689) internal val getBufferLengthPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectSpectrumAnalyzer", "get_buffer_length", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectSpectrumAnalyzer", "get_buffer_length", 1_740_695_150) internal val setTapBackPosPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectSpectrumAnalyzer", "set_tap_back_pos", 373806689) + TypeManager.getMethodBindPtr("AudioEffectSpectrumAnalyzer", "set_tap_back_pos", 373_806_689) internal val getTapBackPosPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectSpectrumAnalyzer", "get_tap_back_pos", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectSpectrumAnalyzer", "get_tap_back_pos", 1_740_695_150) internal val setFftSizePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectSpectrumAnalyzer", "set_fft_size", 1202879215) + TypeManager.getMethodBindPtr("AudioEffectSpectrumAnalyzer", "set_fft_size", 1_202_879_215) internal val getFftSizePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectSpectrumAnalyzer", "get_fft_size", 3925405343) + TypeManager.getMethodBindPtr("AudioEffectSpectrumAnalyzer", "get_fft_size", 3_925_405_343) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectSpectrumAnalyzerInstance.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectSpectrumAnalyzerInstance.kt index cb9aaed205..31f422431e 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectSpectrumAnalyzerInstance.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectSpectrumAnalyzerInstance.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -18,26 +15,21 @@ import kotlin.Float import kotlin.Int import kotlin.Long import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmOverloads /** - * The runtime part of an [AudioEffectSpectrumAnalyzer], which can be used to query the magnitude of - * a frequency range on its host bus. + * The runtime part of an [AudioEffectSpectrumAnalyzer], which can be used to query the magnitude of a frequency range on its host bus. * * An instance of this class can be obtained with [AudioServer.getBusEffectInstance]. */ @GodotBaseType -public open class AudioEffectSpectrumAnalyzerInstance internal constructor() : AudioEffectInstance() - { - public override fun new(scriptIndex: Int): Unit { +public open class AudioEffectSpectrumAnalyzerInstance internal constructor() : AudioEffectInstance() { + override fun new(scriptIndex: Int) { createNativeObject(73, scriptIndex) } /** - * Returns the magnitude of the frequencies from [fromHz] to [toHz] in linear energy as a Vector2. - * The `x` component of the return value represents the left stereo channel, and `y` represents the - * right channel. + * Returns the magnitude of the frequencies from [fromHz] to [toHz] in linear energy as a Vector2. The `x` component of the return value represents the left stereo channel, and `y` represents the right channel. * * [mode] determines how the frequency range will be processed. See [MagnitudeMode]. */ @@ -79,6 +71,6 @@ public open class AudioEffectSpectrumAnalyzerInstance internal constructor() : A public object MethodBindings { internal val getMagnitudeForFrequencyRangePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectSpectrumAnalyzerInstance", "get_magnitude_for_frequency_range", 797993915) + TypeManager.getMethodBindPtr("AudioEffectSpectrumAnalyzerInstance", "get_magnitude_for_frequency_range", 797_993_915) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectStereoEnhance.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectStereoEnhance.kt index fe5b83f4a7..3d76c3a93b 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectStereoEnhance.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioEffectStereoEnhance.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -17,7 +14,6 @@ import kotlin.Float import kotlin.Int import kotlin.NotImplementedError import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** @@ -26,8 +22,7 @@ import kotlin.jvm.JvmName @GodotBaseType public open class AudioEffectStereoEnhance : AudioEffect() { /** - * Amplifies the difference between stereo channels, increasing or decreasing existing panning. A - * value of 0.0 will downmix stereo to mono. Does not affect a mono signal. + * Amplifies the difference between stereo channels, increasing or decreasing existing panning. A value of 0.0 will downmix stereo to mono. Does not affect a mono signal. */ public final inline var panPullout: Float @JvmName("panPulloutProperty") @@ -38,8 +33,7 @@ public open class AudioEffectStereoEnhance : AudioEffect() { } /** - * Widens sound stage through phase shifting in conjunction with [surround]. Just delays the right - * channel if [surround] is 0. + * Widens sound stage through phase shifting in conjunction with [surround]. Just delays the right channel if [surround] is 0. */ public final inline var timePulloutMs: Float @JvmName("timePulloutMsProperty") @@ -50,8 +44,7 @@ public open class AudioEffectStereoEnhance : AudioEffect() { } /** - * Widens sound stage through phase shifting in conjunction with [timePulloutMs]. Just pans sound - * to the left channel if [timePulloutMs] is 0. + * Widens sound stage through phase shifting in conjunction with [timePulloutMs]. Just pans sound to the left channel if [timePulloutMs] is 0. */ public final inline var surround: Float @JvmName("surroundProperty") @@ -61,11 +54,11 @@ public open class AudioEffectStereoEnhance : AudioEffect() { setSurround(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(74, scriptIndex) } - public final fun setPanPullout(amount: Float): Unit { + public final fun setPanPullout(amount: Float) { TransferContext.writeArguments(DOUBLE to amount.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setPanPulloutPtr, NIL) } @@ -76,7 +69,7 @@ public open class AudioEffectStereoEnhance : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setTimePullout(amount: Float): Unit { + public final fun setTimePullout(amount: Float) { TransferContext.writeArguments(DOUBLE to amount.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setTimePulloutPtr, NIL) } @@ -87,7 +80,7 @@ public open class AudioEffectStereoEnhance : AudioEffect() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setSurround(amount: Float): Unit { + public final fun setSurround(amount: Float) { TransferContext.writeArguments(DOUBLE to amount.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setSurroundPtr, NIL) } @@ -101,7 +94,7 @@ public open class AudioEffectStereoEnhance : AudioEffect() { /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _instantiate(): AudioEffectInstance? { + override fun _instantiate(): AudioEffectInstance? { throw NotImplementedError("AudioEffectStereoEnhance::_instantiate can't be called from the JVM.") } @@ -109,21 +102,21 @@ public open class AudioEffectStereoEnhance : AudioEffect() { public object MethodBindings { internal val setPanPulloutPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectStereoEnhance", "set_pan_pullout", 373806689) + TypeManager.getMethodBindPtr("AudioEffectStereoEnhance", "set_pan_pullout", 373_806_689) internal val getPanPulloutPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectStereoEnhance", "get_pan_pullout", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectStereoEnhance", "get_pan_pullout", 1_740_695_150) internal val setTimePulloutPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectStereoEnhance", "set_time_pullout", 373806689) + TypeManager.getMethodBindPtr("AudioEffectStereoEnhance", "set_time_pullout", 373_806_689) internal val getTimePulloutPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectStereoEnhance", "get_time_pullout", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectStereoEnhance", "get_time_pullout", 1_740_695_150) internal val setSurroundPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectStereoEnhance", "set_surround", 373806689) + TypeManager.getMethodBindPtr("AudioEffectStereoEnhance", "set_surround", 373_806_689) internal val getSurroundPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioEffectStereoEnhance", "get_surround", 1740695150) + TypeManager.getMethodBindPtr("AudioEffectStereoEnhance", "get_surround", 1_740_695_150) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioListener2D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioListener2D.kt index 88ced2b6ed..9462dca297 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioListener2D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioListener2D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -15,29 +12,24 @@ import godot.core.VariantParser.NIL import kotlin.Boolean import kotlin.Int import kotlin.Suppress -import kotlin.Unit /** - * Once added to the scene tree and enabled using [makeCurrent], this node will override the - * location sounds are heard from. Only one [AudioListener2D] can be current. Using [makeCurrent] will - * disable the previous [AudioListener2D]. + * Once added to the scene tree and enabled using [makeCurrent], this node will override the location sounds are heard from. Only one [AudioListener2D] can be current. Using [makeCurrent] will disable the previous [AudioListener2D]. * - * If there is no active [AudioListener2D] in the current [Viewport], center of the screen will be - * used as a hearing point for the audio. [AudioListener2D] needs to be inside [SceneTree] to function. + * If there is no active [AudioListener2D] in the current [Viewport], center of the screen will be used as a hearing point for the audio. [AudioListener2D] needs to be inside [SceneTree] to function. */ @GodotBaseType public open class AudioListener2D : Node2D() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(75, scriptIndex) } /** - * Makes the [AudioListener2D] active, setting it as the hearing point for the sounds. If there is - * already another active [AudioListener2D], it will be disabled. + * Makes the [AudioListener2D] active, setting it as the hearing point for the sounds. If there is already another active [AudioListener2D], it will be disabled. * * This method will have no effect if the [AudioListener2D] is not added to [SceneTree]. */ - public final fun makeCurrent(): Unit { + public final fun makeCurrent() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.makeCurrentPtr, NIL) } @@ -45,7 +37,7 @@ public open class AudioListener2D : Node2D() { /** * Disables the [AudioListener2D]. If it's not set as current, this method will have no effect. */ - public final fun clearCurrent(): Unit { + public final fun clearCurrent() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.clearCurrentPtr, NIL) } @@ -63,12 +55,12 @@ public open class AudioListener2D : Node2D() { public object MethodBindings { internal val makeCurrentPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioListener2D", "make_current", 3218959716) + TypeManager.getMethodBindPtr("AudioListener2D", "make_current", 3_218_959_716) internal val clearCurrentPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioListener2D", "clear_current", 3218959716) + TypeManager.getMethodBindPtr("AudioListener2D", "clear_current", 3_218_959_716) internal val isCurrentPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioListener2D", "is_current", 36873697) + TypeManager.getMethodBindPtr("AudioListener2D", "is_current", 36_873_697) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioListener3D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioListener3D.kt index 6517f1b84d..ea5b22e52c 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioListener3D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioListener3D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -17,23 +14,20 @@ import godot.core.VariantParser.TRANSFORM3D import kotlin.Boolean import kotlin.Int import kotlin.Suppress -import kotlin.Unit /** - * Once added to the scene tree and enabled using [makeCurrent], this node will override the - * location sounds are heard from. This can be used to listen from a location different from the - * [Camera3D]. + * Once added to the scene tree and enabled using [makeCurrent], this node will override the location sounds are heard from. This can be used to listen from a location different from the [Camera3D]. */ @GodotBaseType public open class AudioListener3D : Node3D() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(76, scriptIndex) } /** * Enables the listener. This will override the current camera's listener. */ - public final fun makeCurrent(): Unit { + public final fun makeCurrent() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.makeCurrentPtr, NIL) } @@ -41,7 +35,7 @@ public open class AudioListener3D : Node3D() { /** * Disables the listener to use the current camera's listener instead. */ - public final fun clearCurrent(): Unit { + public final fun clearCurrent() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.clearCurrentPtr, NIL) } @@ -49,8 +43,7 @@ public open class AudioListener3D : Node3D() { /** * Returns `true` if the listener was made current using [makeCurrent], `false` otherwise. * - * **Note:** There may be more than one AudioListener3D marked as "current" in the scene tree, but - * only the one that was made current last will be used. + * **Note:** There may be more than one AudioListener3D marked as "current" in the scene tree, but only the one that was made current last will be used. */ public final fun isCurrent(): Boolean { TransferContext.writeArguments() @@ -71,15 +64,15 @@ public open class AudioListener3D : Node3D() { public object MethodBindings { internal val makeCurrentPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioListener3D", "make_current", 3218959716) + TypeManager.getMethodBindPtr("AudioListener3D", "make_current", 3_218_959_716) internal val clearCurrentPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioListener3D", "clear_current", 3218959716) + TypeManager.getMethodBindPtr("AudioListener3D", "clear_current", 3_218_959_716) internal val isCurrentPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioListener3D", "is_current", 36873697) + TypeManager.getMethodBindPtr("AudioListener3D", "is_current", 36_873_697) internal val getListenerTransformPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioListener3D", "get_listener_transform", 3229777777) + TypeManager.getMethodBindPtr("AudioListener3D", "get_listener_transform", 3_229_777_777) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioSample.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioSample.kt index ce2bd99201..ee3aab5f7b 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioSample.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioSample.kt @@ -1,22 +1,18 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api import godot.`annotation`.GodotBaseType import kotlin.Int import kotlin.Suppress -import kotlin.Unit /** * Base class for audio samples. */ @GodotBaseType public open class AudioSample : RefCounted() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(77, scriptIndex) } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioSamplePlayback.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioSamplePlayback.kt index 2be9b7b54c..c583bd5d5e 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioSamplePlayback.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioSamplePlayback.kt @@ -1,22 +1,18 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api import godot.`annotation`.GodotBaseType import kotlin.Int import kotlin.Suppress -import kotlin.Unit /** * Meta class for playing back audio samples. */ @GodotBaseType public open class AudioSamplePlayback : RefCounted() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(78, scriptIndex) } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioServer.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioServer.kt index 620ffed1be..05a990835a 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioServer.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioServer.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -36,8 +33,7 @@ import kotlin.jvm.JvmOverloads import kotlin.jvm.JvmStatic /** - * [AudioServer] is a low-level server interface for audio access. It is in charge of creating - * sample data (playable audio) as well as its playback via a voice interface. + * [AudioServer] is a low-level server interface for audio access. It is in charge of creating sample data (playable audio) as well as its playback via a voice interface. */ @GodotBaseType public object AudioServer : Object() { @@ -66,10 +62,7 @@ public object AudioServer : Object() { } /** - * Name of the current device for audio output (see [getOutputDeviceList]). On systems with - * multiple audio outputs (such as analog, USB and HDMI audio), this can be used to select the audio - * output device. The value `"Default"` will play audio on the system-wide default audio output. If - * an invalid device name is set, the value will be reverted back to `"Default"`. + * Name of the current device for audio output (see [getOutputDeviceList]). On systems with multiple audio outputs (such as analog, USB and HDMI audio), this can be used to select the audio output device. The value `"Default"` will play audio on the system-wide default audio output. If an invalid device name is set, the value will be reverted back to `"Default"`. */ @JvmStatic public final inline var outputDevice: String @@ -81,14 +74,9 @@ public object AudioServer : Object() { } /** - * Name of the current device for audio input (see [getInputDeviceList]). On systems with multiple - * audio inputs (such as analog, USB and HDMI audio), this can be used to select the audio input - * device. The value `"Default"` will record audio on the system-wide default audio input. If an - * invalid device name is set, the value will be reverted back to `"Default"`. + * Name of the current device for audio input (see [getInputDeviceList]). On systems with multiple audio inputs (such as analog, USB and HDMI audio), this can be used to select the audio input device. The value `"Default"` will record audio on the system-wide default audio input. If an invalid device name is set, the value will be reverted back to `"Default"`. * - * **Note:** [ProjectSettings.audio/driver/enableInput] must be `true` for audio input to work. - * See also that setting's description for caveats related to permissions and operating system - * privacy settings. + * **Note:** [ProjectSettings.audio/driver/enableInput] must be `true` for audio input to work. See also that setting's description for caveats related to permissions and operating system privacy settings. */ @JvmStatic public final inline var inputDevice: String @@ -100,9 +88,7 @@ public object AudioServer : Object() { } /** - * Scales the rate at which audio is played (i.e. setting it to `0.5` will make the audio be - * played at half its speed). See also [Engine.timeScale] to affect the general simulation speed, - * which is independent from [AudioServer.playbackSpeedScale]. + * Scales the rate at which audio is played (i.e. setting it to `0.5` will make the audio be played at half its speed). See also [Engine.timeScale] to affect the general simulation speed, which is independent from [AudioServer.playbackSpeedScale]. */ @JvmStatic public final inline var playbackSpeedScale: Float @@ -113,12 +99,12 @@ public object AudioServer : Object() { setPlaybackSpeedScale(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { getSingleton(0) } @JvmStatic - public final fun setBusCount(amount: Int): Unit { + public final fun setBusCount(amount: Int) { TransferContext.writeArguments(LONG to amount.toLong()) TransferContext.callMethod(ptr, MethodBindings.setBusCountPtr, NIL) } @@ -134,7 +120,7 @@ public object AudioServer : Object() { * Removes the bus at index [index]. */ @JvmStatic - public final fun removeBus(index: Int): Unit { + public final fun removeBus(index: Int) { TransferContext.writeArguments(LONG to index.toLong()) TransferContext.callMethod(ptr, MethodBindings.removeBusPtr, NIL) } @@ -144,7 +130,7 @@ public object AudioServer : Object() { */ @JvmOverloads @JvmStatic - public final fun addBus(atPosition: Int = -1): Unit { + public final fun addBus(atPosition: Int = -1) { TransferContext.writeArguments(LONG to atPosition.toLong()) TransferContext.callMethod(ptr, MethodBindings.addBusPtr, NIL) } @@ -153,7 +139,7 @@ public object AudioServer : Object() { * Moves the bus from index [index] to index [toIndex]. */ @JvmStatic - public final fun moveBus(index: Int, toIndex: Int): Unit { + public final fun moveBus(index: Int, toIndex: Int) { TransferContext.writeArguments(LONG to index.toLong(), LONG to toIndex.toLong()) TransferContext.callMethod(ptr, MethodBindings.moveBusPtr, NIL) } @@ -162,7 +148,7 @@ public object AudioServer : Object() { * Sets the name of the bus at index [busIdx] to [name]. */ @JvmStatic - public final fun setBusName(busIdx: Int, name: String): Unit { + public final fun setBusName(busIdx: Int, name: String) { TransferContext.writeArguments(LONG to busIdx.toLong(), STRING to name) TransferContext.callMethod(ptr, MethodBindings.setBusNamePtr, NIL) } @@ -178,8 +164,7 @@ public object AudioServer : Object() { } /** - * Returns the index of the bus with the name [busName]. Returns `-1` if no bus with the specified - * name exist. + * Returns the index of the bus with the name [busName]. Returns `-1` if no bus with the specified name exist. */ @JvmStatic public final fun getBusIndex(busName: StringName): Int { @@ -202,7 +187,7 @@ public object AudioServer : Object() { * Sets the volume in decibels of the bus at index [busIdx] to [volumeDb]. */ @JvmStatic - public final fun setBusVolumeDb(busIdx: Int, volumeDb: Float): Unit { + public final fun setBusVolumeDb(busIdx: Int, volumeDb: Float) { TransferContext.writeArguments(LONG to busIdx.toLong(), DOUBLE to volumeDb.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setBusVolumeDbPtr, NIL) } @@ -220,11 +205,10 @@ public object AudioServer : Object() { /** * Sets the volume as a linear value of the bus at index [busIdx] to [volumeLinear]. * - * **Note:** Using this method is equivalent to calling [setBusVolumeDb] with the result of - * [@GlobalScope.linearToDb] on a value. + * **Note:** Using this method is equivalent to calling [setBusVolumeDb] with the result of [@GlobalScope.linearToDb] on a value. */ @JvmStatic - public final fun setBusVolumeLinear(busIdx: Int, volumeLinear: Float): Unit { + public final fun setBusVolumeLinear(busIdx: Int, volumeLinear: Float) { TransferContext.writeArguments(LONG to busIdx.toLong(), DOUBLE to volumeLinear.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setBusVolumeLinearPtr, NIL) } @@ -232,8 +216,7 @@ public object AudioServer : Object() { /** * Returns the volume of the bus at index [busIdx] as a linear value. * - * **Note:** The returned value is equivalent to the result of [@GlobalScope.dbToLinear] on the - * result of [getBusVolumeDb]. + * **Note:** The returned value is equivalent to the result of [@GlobalScope.dbToLinear] on the result of [getBusVolumeDb]. */ @JvmStatic public final fun getBusVolumeLinear(busIdx: Int): Float { @@ -246,7 +229,7 @@ public object AudioServer : Object() { * Connects the output of the bus at [busIdx] to the bus named [send]. */ @JvmStatic - public final fun setBusSend(busIdx: Int, send: StringName): Unit { + public final fun setBusSend(busIdx: Int, send: StringName) { TransferContext.writeArguments(LONG to busIdx.toLong(), STRING_NAME to send) TransferContext.callMethod(ptr, MethodBindings.setBusSendPtr, NIL) } @@ -265,7 +248,7 @@ public object AudioServer : Object() { * If `true`, the bus at index [busIdx] is in solo mode. */ @JvmStatic - public final fun setBusSolo(busIdx: Int, enable: Boolean): Unit { + public final fun setBusSolo(busIdx: Int, enable: Boolean) { TransferContext.writeArguments(LONG to busIdx.toLong(), BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setBusSoloPtr, NIL) } @@ -284,7 +267,7 @@ public object AudioServer : Object() { * If `true`, the bus at index [busIdx] is muted. */ @JvmStatic - public final fun setBusMute(busIdx: Int, enable: Boolean): Unit { + public final fun setBusMute(busIdx: Int, enable: Boolean) { TransferContext.writeArguments(LONG to busIdx.toLong(), BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setBusMutePtr, NIL) } @@ -303,7 +286,7 @@ public object AudioServer : Object() { * If `true`, the bus at index [busIdx] is bypassing effects. */ @JvmStatic - public final fun setBusBypassEffects(busIdx: Int, enable: Boolean): Unit { + public final fun setBusBypassEffects(busIdx: Int, enable: Boolean) { TransferContext.writeArguments(LONG to busIdx.toLong(), BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setBusBypassEffectsPtr, NIL) } @@ -327,7 +310,7 @@ public object AudioServer : Object() { busIdx: Int, effect: AudioEffect?, atPosition: Int = -1, - ): Unit { + ) { TransferContext.writeArguments(LONG to busIdx.toLong(), OBJECT to effect, LONG to atPosition.toLong()) TransferContext.callMethod(ptr, MethodBindings.addBusEffectPtr, NIL) } @@ -336,7 +319,7 @@ public object AudioServer : Object() { * Removes the effect at index [effectIdx] from the bus at index [busIdx]. */ @JvmStatic - public final fun removeBusEffect(busIdx: Int, effectIdx: Int): Unit { + public final fun removeBusEffect(busIdx: Int, effectIdx: Int) { TransferContext.writeArguments(LONG to busIdx.toLong(), LONG to effectIdx.toLong()) TransferContext.callMethod(ptr, MethodBindings.removeBusEffectPtr, NIL) } @@ -362,8 +345,7 @@ public object AudioServer : Object() { } /** - * Returns the [AudioEffectInstance] assigned to the given bus and effect indices (and optionally - * channel). + * Returns the [AudioEffectInstance] assigned to the given bus and effect indices (and optionally channel). */ @JvmOverloads @JvmStatic @@ -385,7 +367,7 @@ public object AudioServer : Object() { busIdx: Int, effectIdx: Int, byEffectIdx: Int, - ): Unit { + ) { TransferContext.writeArguments(LONG to busIdx.toLong(), LONG to effectIdx.toLong(), LONG to byEffectIdx.toLong()) TransferContext.callMethod(ptr, MethodBindings.swapBusEffectsPtr, NIL) } @@ -398,7 +380,7 @@ public object AudioServer : Object() { busIdx: Int, effectIdx: Int, enabled: Boolean, - ): Unit { + ) { TransferContext.writeArguments(LONG to busIdx.toLong(), LONG to effectIdx.toLong(), BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setBusEffectEnabledPtr, NIL) } @@ -434,7 +416,7 @@ public object AudioServer : Object() { } @JvmStatic - public final fun setPlaybackSpeedScale(scale: Float): Unit { + public final fun setPlaybackSpeedScale(scale: Float) { TransferContext.writeArguments(DOUBLE to scale.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setPlaybackSpeedScalePtr, NIL) } @@ -452,7 +434,7 @@ public object AudioServer : Object() { * **Note:** Remember to unlock it afterwards. */ @JvmStatic - public final fun lock(): Unit { + public final fun lock() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.lockPtr, NIL) } @@ -461,7 +443,7 @@ public object AudioServer : Object() { * Unlocks the audio driver's main loop. (After locking it, you should always unlock it.) */ @JvmStatic - public final fun unlock(): Unit { + public final fun unlock() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.unlockPtr, NIL) } @@ -497,11 +479,7 @@ public object AudioServer : Object() { } /** - * Returns the name of the current audio driver. The default usually depends on the operating - * system, but may be overridden via the `--audio-driver` - * [url=$DOCS_URL/tutorials/editor/command_line_tutorial.html]command line argument[/url]. - * `--headless` also automatically sets the audio driver to `Dummy`. See also - * [ProjectSettings.audio/driver/driver]. + * Returns the name of the current audio driver. The default usually depends on the operating system, but may be overridden via the `--audio-driver` [url=$DOCS_URL/tutorials/editor/command_line_tutorial.html]command line argument[/url]. `--headless` also automatically sets the audio driver to `Dummy`. See also [ProjectSettings.audio/driver/driver]. */ @JvmStatic public final fun getDriverName(): String { @@ -528,7 +506,7 @@ public object AudioServer : Object() { } @JvmStatic - public final fun setOutputDevice(name: String): Unit { + public final fun setOutputDevice(name: String) { TransferContext.writeArguments(STRING to name) TransferContext.callMethod(ptr, MethodBindings.setOutputDevicePtr, NIL) } @@ -554,9 +532,7 @@ public object AudioServer : Object() { } /** - * Returns the audio driver's effective output latency. This is based on - * [ProjectSettings.audio/driver/outputLatency], but the exact returned value will differ depending - * on the operating system and audio driver. + * Returns the audio driver's effective output latency. This is based on [ProjectSettings.audio/driver/outputLatency], but the exact returned value will differ depending on the operating system and audio driver. * * **Note:** This can be expensive; it is not recommended to call [getOutputLatency] every frame. */ @@ -570,9 +546,7 @@ public object AudioServer : Object() { /** * Returns the names of all audio input devices detected on the system. * - * **Note:** [ProjectSettings.audio/driver/enableInput] must be `true` for audio input to work. - * See also that setting's description for caveats related to permissions and operating system - * privacy settings. + * **Note:** [ProjectSettings.audio/driver/enableInput] must be `true` for audio input to work. See also that setting's description for caveats related to permissions and operating system privacy settings. */ @JvmStatic public final fun getInputDeviceList(): PackedStringArray { @@ -589,7 +563,7 @@ public object AudioServer : Object() { } @JvmStatic - public final fun setInputDevice(name: String): Unit { + public final fun setInputDevice(name: String) { TransferContext.writeArguments(STRING to name) TransferContext.callMethod(ptr, MethodBindings.setInputDevicePtr, NIL) } @@ -598,7 +572,7 @@ public object AudioServer : Object() { * Overwrites the currently used [AudioBusLayout]. */ @JvmStatic - public final fun setBusLayout(busLayout: AudioBusLayout?): Unit { + public final fun setBusLayout(busLayout: AudioBusLayout?) { TransferContext.writeArguments(OBJECT to busLayout) TransferContext.callMethod(ptr, MethodBindings.setBusLayoutPtr, NIL) } @@ -614,24 +588,20 @@ public object AudioServer : Object() { } /** - * If set to `true`, all instances of [AudioStreamPlayback] will call - * [AudioStreamPlayback.TagUsedStreams] every mix step. + * If set to `true`, all instances of [AudioStreamPlayback] will call [AudioStreamPlayback.TagUsedStreams] every mix step. * - * **Note:** This is enabled by default in the editor, as it is used by editor plugins for the - * audio stream previews. + * **Note:** This is enabled by default in the editor, as it is used by editor plugins for the audio stream previews. */ @JvmStatic - public final fun setEnableTaggingUsedAudioStreams(enable: Boolean): Unit { + public final fun setEnableTaggingUsedAudioStreams(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setEnableTaggingUsedAudioStreamsPtr, NIL) } /** - * If `true`, the stream is registered as a sample. The engine will not have to register it before - * playing the sample. + * If `true`, the stream is registered as a sample. The engine will not have to register it before playing the sample. * - * If `false`, the stream will have to be registered before playing it. To prevent lag spikes, - * register the stream as sample with [registerStreamAsSample]. + * If `false`, the stream will have to be registered before playing it. To prevent lag spikes, register the stream as sample with [registerStreamAsSample]. */ @JvmStatic public final fun isStreamRegisteredAsSample(stream: AudioStream?): Boolean { @@ -643,19 +613,16 @@ public object AudioServer : Object() { /** * Forces the registration of a stream as a sample. * - * **Note:** Lag spikes may occur when calling this method, especially on single-threaded builds. - * It is suggested to call this method while loading assets, where the lag spike could be masked, - * instead of registering the sample right before it needs to be played. + * **Note:** Lag spikes may occur when calling this method, especially on single-threaded builds. It is suggested to call this method while loading assets, where the lag spike could be masked, instead of registering the sample right before it needs to be played. */ @JvmStatic - public final fun registerStreamAsSample(stream: AudioStream?): Unit { + public final fun registerStreamAsSample(stream: AudioStream?) { TransferContext.writeArguments(OBJECT to stream) TransferContext.callMethod(ptr, MethodBindings.registerStreamAsSamplePtr, NIL) } /** - * Returns the index of the bus with the name [busName]. Returns `-1` if no bus with the specified - * name exist. + * Returns the index of the bus with the name [busName]. Returns `-1` if no bus with the specified name exist. */ @JvmStatic public final fun getBusIndex(busName: String): Int = getBusIndex(busName.asCachedStringName()) @@ -664,8 +631,7 @@ public object AudioServer : Object() { * Connects the output of the bus at [busIdx] to the bus named [send]. */ @JvmStatic - public final fun setBusSend(busIdx: Int, send: String) = - setBusSend(busIdx, send.asCachedStringName()) + public final fun setBusSend(busIdx: Int, send: String): Unit = setBusSend(busIdx, send.asCachedStringName()) public enum class SpeakerMode( id: Long, @@ -702,8 +668,7 @@ public object AudioServer : Object() { id: Long, ) { /** - * The playback will be considered of the type declared at - * [ProjectSettings.audio/general/defaultPlaybackType]. + * The playback will be considered of the type declared at [ProjectSettings.audio/general/defaultPlaybackType]. */ DEFAULT(0), /** @@ -711,8 +676,7 @@ public object AudioServer : Object() { */ STREAM(1), /** - * Force the playback to be considered as a sample. This can provide lower latency and more - * stable playback (with less risk of audio crackling), at the cost of having less flexibility. + * Force the playback to be considered as a sample. This can provide lower latency and more stable playback (with less risk of audio crackling), at the cost of having less flexibility. * * **Note:** Only currently supported on the web platform. * @@ -737,161 +701,162 @@ public object AudioServer : Object() { public object MethodBindings { internal val setBusCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "set_bus_count", 1286410249) + TypeManager.getMethodBindPtr("AudioServer", "set_bus_count", 1_286_410_249) internal val getBusCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "get_bus_count", 3905245786) + TypeManager.getMethodBindPtr("AudioServer", "get_bus_count", 3_905_245_786) internal val removeBusPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "remove_bus", 1286410249) + TypeManager.getMethodBindPtr("AudioServer", "remove_bus", 1_286_410_249) internal val addBusPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "add_bus", 1025054187) + TypeManager.getMethodBindPtr("AudioServer", "add_bus", 1_025_054_187) internal val moveBusPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "move_bus", 3937882851) + TypeManager.getMethodBindPtr("AudioServer", "move_bus", 3_937_882_851) internal val setBusNamePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "set_bus_name", 501894301) + TypeManager.getMethodBindPtr("AudioServer", "set_bus_name", 501_894_301) internal val getBusNamePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "get_bus_name", 844755477) + TypeManager.getMethodBindPtr("AudioServer", "get_bus_name", 844_755_477) internal val getBusIndexPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "get_bus_index", 2458036349) + TypeManager.getMethodBindPtr("AudioServer", "get_bus_index", 2_458_036_349) internal val getBusChannelsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "get_bus_channels", 923996154) + TypeManager.getMethodBindPtr("AudioServer", "get_bus_channels", 923_996_154) internal val setBusVolumeDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "set_bus_volume_db", 1602489585) + TypeManager.getMethodBindPtr("AudioServer", "set_bus_volume_db", 1_602_489_585) internal val getBusVolumeDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "get_bus_volume_db", 2339986948) + TypeManager.getMethodBindPtr("AudioServer", "get_bus_volume_db", 2_339_986_948) internal val setBusVolumeLinearPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "set_bus_volume_linear", 1602489585) + TypeManager.getMethodBindPtr("AudioServer", "set_bus_volume_linear", 1_602_489_585) internal val getBusVolumeLinearPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "get_bus_volume_linear", 2339986948) + TypeManager.getMethodBindPtr("AudioServer", "get_bus_volume_linear", 2_339_986_948) internal val setBusSendPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "set_bus_send", 3780747571) + TypeManager.getMethodBindPtr("AudioServer", "set_bus_send", 3_780_747_571) internal val getBusSendPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "get_bus_send", 659327637) + TypeManager.getMethodBindPtr("AudioServer", "get_bus_send", 659_327_637) internal val setBusSoloPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "set_bus_solo", 300928843) + TypeManager.getMethodBindPtr("AudioServer", "set_bus_solo", 300_928_843) internal val isBusSoloPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "is_bus_solo", 1116898809) + TypeManager.getMethodBindPtr("AudioServer", "is_bus_solo", 1_116_898_809) internal val setBusMutePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "set_bus_mute", 300928843) + TypeManager.getMethodBindPtr("AudioServer", "set_bus_mute", 300_928_843) internal val isBusMutePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "is_bus_mute", 1116898809) + TypeManager.getMethodBindPtr("AudioServer", "is_bus_mute", 1_116_898_809) internal val setBusBypassEffectsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "set_bus_bypass_effects", 300928843) + TypeManager.getMethodBindPtr("AudioServer", "set_bus_bypass_effects", 300_928_843) internal val isBusBypassingEffectsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "is_bus_bypassing_effects", 1116898809) + TypeManager.getMethodBindPtr("AudioServer", "is_bus_bypassing_effects", 1_116_898_809) internal val addBusEffectPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "add_bus_effect", 4068819785) + TypeManager.getMethodBindPtr("AudioServer", "add_bus_effect", 4_068_819_785) internal val removeBusEffectPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "remove_bus_effect", 3937882851) + TypeManager.getMethodBindPtr("AudioServer", "remove_bus_effect", 3_937_882_851) internal val getBusEffectCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "get_bus_effect_count", 3744713108) + TypeManager.getMethodBindPtr("AudioServer", "get_bus_effect_count", 3_744_713_108) internal val getBusEffectPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "get_bus_effect", 726064442) + TypeManager.getMethodBindPtr("AudioServer", "get_bus_effect", 726_064_442) internal val getBusEffectInstancePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "get_bus_effect_instance", 1829771234) + TypeManager.getMethodBindPtr("AudioServer", "get_bus_effect_instance", 1_829_771_234) internal val swapBusEffectsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "swap_bus_effects", 1649997291) + TypeManager.getMethodBindPtr("AudioServer", "swap_bus_effects", 1_649_997_291) internal val setBusEffectEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "set_bus_effect_enabled", 1383440665) + TypeManager.getMethodBindPtr("AudioServer", "set_bus_effect_enabled", 1_383_440_665) internal val isBusEffectEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "is_bus_effect_enabled", 2522259332) + TypeManager.getMethodBindPtr("AudioServer", "is_bus_effect_enabled", 2_522_259_332) internal val getBusPeakVolumeLeftDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "get_bus_peak_volume_left_db", 3085491603) + TypeManager.getMethodBindPtr("AudioServer", "get_bus_peak_volume_left_db", 3_085_491_603) internal val getBusPeakVolumeRightDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "get_bus_peak_volume_right_db", 3085491603) + TypeManager.getMethodBindPtr("AudioServer", "get_bus_peak_volume_right_db", 3_085_491_603) internal val setPlaybackSpeedScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "set_playback_speed_scale", 373806689) + TypeManager.getMethodBindPtr("AudioServer", "set_playback_speed_scale", 373_806_689) internal val getPlaybackSpeedScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "get_playback_speed_scale", 1740695150) + TypeManager.getMethodBindPtr("AudioServer", "get_playback_speed_scale", 1_740_695_150) - internal val lockPtr: VoidPtr = TypeManager.getMethodBindPtr("AudioServer", "lock", 3218959716) + internal val lockPtr: VoidPtr = + TypeManager.getMethodBindPtr("AudioServer", "lock", 3_218_959_716) internal val unlockPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "unlock", 3218959716) + TypeManager.getMethodBindPtr("AudioServer", "unlock", 3_218_959_716) internal val getSpeakerModePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "get_speaker_mode", 2549190337) + TypeManager.getMethodBindPtr("AudioServer", "get_speaker_mode", 2_549_190_337) internal val getMixRatePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "get_mix_rate", 1740695150) + TypeManager.getMethodBindPtr("AudioServer", "get_mix_rate", 1_740_695_150) internal val getInputMixRatePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "get_input_mix_rate", 1740695150) + TypeManager.getMethodBindPtr("AudioServer", "get_input_mix_rate", 1_740_695_150) internal val getDriverNamePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "get_driver_name", 201670096) + TypeManager.getMethodBindPtr("AudioServer", "get_driver_name", 201_670_096) internal val getOutputDeviceListPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "get_output_device_list", 2981934095) + TypeManager.getMethodBindPtr("AudioServer", "get_output_device_list", 2_981_934_095) internal val getOutputDevicePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "get_output_device", 2841200299) + TypeManager.getMethodBindPtr("AudioServer", "get_output_device", 2_841_200_299) internal val setOutputDevicePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "set_output_device", 83702148) + TypeManager.getMethodBindPtr("AudioServer", "set_output_device", 83_702_148) internal val getTimeToNextMixPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "get_time_to_next_mix", 1740695150) + TypeManager.getMethodBindPtr("AudioServer", "get_time_to_next_mix", 1_740_695_150) internal val getTimeSinceLastMixPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "get_time_since_last_mix", 1740695150) + TypeManager.getMethodBindPtr("AudioServer", "get_time_since_last_mix", 1_740_695_150) internal val getOutputLatencyPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "get_output_latency", 1740695150) + TypeManager.getMethodBindPtr("AudioServer", "get_output_latency", 1_740_695_150) internal val getInputDeviceListPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "get_input_device_list", 2981934095) + TypeManager.getMethodBindPtr("AudioServer", "get_input_device_list", 2_981_934_095) internal val getInputDevicePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "get_input_device", 2841200299) + TypeManager.getMethodBindPtr("AudioServer", "get_input_device", 2_841_200_299) internal val setInputDevicePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "set_input_device", 83702148) + TypeManager.getMethodBindPtr("AudioServer", "set_input_device", 83_702_148) internal val setBusLayoutPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "set_bus_layout", 3319058824) + TypeManager.getMethodBindPtr("AudioServer", "set_bus_layout", 3_319_058_824) internal val generateBusLayoutPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "generate_bus_layout", 3769973890) + TypeManager.getMethodBindPtr("AudioServer", "generate_bus_layout", 3_769_973_890) internal val setEnableTaggingUsedAudioStreamsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "set_enable_tagging_used_audio_streams", 2586408642) + TypeManager.getMethodBindPtr("AudioServer", "set_enable_tagging_used_audio_streams", 2_586_408_642) internal val isStreamRegisteredAsSamplePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "is_stream_registered_as_sample", 500225754) + TypeManager.getMethodBindPtr("AudioServer", "is_stream_registered_as_sample", 500_225_754) internal val registerStreamAsSamplePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioServer", "register_stream_as_sample", 2210767741) + TypeManager.getMethodBindPtr("AudioServer", "register_stream_as_sample", 2_210_767_741) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStream.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStream.kt index 10b1374066..c3cc2dc91a 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStream.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStream.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -23,11 +20,9 @@ import kotlin.Int import kotlin.NotImplementedError import kotlin.String import kotlin.Suppress -import kotlin.Unit /** - * Base class for audio streams. Audio streams are used for sound effects and music playback, and - * support WAV (via [AudioStreamWAV]) and Ogg (via [AudioStreamOggVorbis]) file formats. + * Base class for audio streams. Audio streams are used for sound effects and music playback, and support WAV (via [AudioStreamWAV]) and Ogg (via [AudioStreamOggVorbis]) file formats. */ @GodotBaseType public open class AudioStream : Resource() { @@ -36,13 +31,12 @@ public open class AudioStream : Resource() { */ public val parameterListChanged: Signal0 by Signal0 - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(80, scriptIndex) } /** - * Override this method to customize the returned value of [instantiatePlayback]. Should return a - * new [AudioStreamPlayback] created when the stream is played (such as by an [AudioStreamPlayer]). + * Override this method to customize the returned value of [instantiatePlayback]. Should return a new [AudioStreamPlayback] created when the stream is played (such as by an [AudioStreamPlayer]). */ public open fun _instantiatePlayback(): AudioStreamPlayback? { throw NotImplementedError("AudioStream::_instantiatePlayback is not implemented.") @@ -56,47 +50,39 @@ public open class AudioStream : Resource() { } /** - * Override this method to customize the returned value of [getLength]. Should return the length - * of this audio stream, in seconds. + * Override this method to customize the returned value of [getLength]. Should return the length of this audio stream, in seconds. */ public open fun _getLength(): Double { throw NotImplementedError("AudioStream::_getLength is not implemented.") } /** - * Override this method to customize the returned value of [isMonophonic]. Should return `true` if - * this audio stream only supports one channel. + * Override this method to customize the returned value of [isMonophonic]. Should return `true` if this audio stream only supports one channel. */ public open fun _isMonophonic(): Boolean { throw NotImplementedError("AudioStream::_isMonophonic is not implemented.") } /** - * Overridable method. Should return the tempo of this audio stream, in beats per minute (BPM). - * Used by the engine to determine the position of every beat. + * Overridable method. Should return the tempo of this audio stream, in beats per minute (BPM). Used by the engine to determine the position of every beat. * - * Ideally, the returned value should be based off the stream's sample rate - * ([AudioStreamWAV.mixRate], for example). + * Ideally, the returned value should be based off the stream's sample rate ([AudioStreamWAV.mixRate], for example). */ public open fun _getBpm(): Double { throw NotImplementedError("AudioStream::_getBpm is not implemented.") } /** - * Overridable method. Should return the total number of beats of this audio stream. Used by the - * engine to determine the position of every beat. + * Overridable method. Should return the total number of beats of this audio stream. Used by the engine to determine the position of every beat. * - * Ideally, the returned value should be based off the stream's sample rate - * ([AudioStreamWAV.mixRate], for example). + * Ideally, the returned value should be based off the stream's sample rate ([AudioStreamWAV.mixRate], for example). */ public open fun _getBeatCount(): Int { throw NotImplementedError("AudioStream::_getBeatCount is not implemented.") } /** - * Return the controllable parameters of this stream. This array contains dictionaries with a - * property info description format (see [Object.getPropertyList]). Additionally, the default value - * for this parameter must be added tho each dictionary in "default_value" field. + * Return the controllable parameters of this stream. This array contains dictionaries with a property info description format (see [Object.getPropertyList]). Additionally, the default value for this parameter must be added tho each dictionary in "default_value" field. */ public open fun _getParameterList(): VariantArray> { throw NotImplementedError("AudioStream::_getParameterList is not implemented.") @@ -126,8 +112,7 @@ public open class AudioStream : Resource() { } /** - * Returns `true` if this audio stream only supports one channel (*monophony*), or `false` if the - * audio stream supports two or more channels (*polyphony*). + * Returns `true` if this audio stream only supports one channel (*monophony*), or `false` if the audio stream supports two or more channels (*polyphony*). */ public final fun isMonophonic(): Boolean { TransferContext.writeArguments() @@ -136,10 +121,7 @@ public open class AudioStream : Resource() { } /** - * Returns a newly created [AudioStreamPlayback] intended to play this audio stream. Useful for - * when you want to extend [_instantiatePlayback] but call [instantiatePlayback] from an internally - * held AudioStream subresource. An example of this can be found in the source code for - * `AudioStreamRandomPitch::instantiate_playback`. + * Returns a newly created [AudioStreamPlayback] intended to play this audio stream. Useful for when you want to extend [_instantiatePlayback] but call [instantiatePlayback] from an internally held AudioStream subresource. An example of this can be found in the source code for `AudioStreamRandomPitch::instantiate_playback`. */ public final fun instantiatePlayback(): AudioStreamPlayback? { TransferContext.writeArguments() @@ -148,8 +130,7 @@ public open class AudioStream : Resource() { } /** - * Returns if the current [AudioStream] can be used as a sample. Only static streams can be - * sampled. + * Returns if the current [AudioStream] can be used as a sample. Only static streams can be sampled. */ public final fun canBeSampled(): Boolean { TransferContext.writeArguments() @@ -179,21 +160,21 @@ public open class AudioStream : Resource() { public object MethodBindings { internal val getLengthPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStream", "get_length", 1740695150) + TypeManager.getMethodBindPtr("AudioStream", "get_length", 1_740_695_150) internal val isMonophonicPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStream", "is_monophonic", 36873697) + TypeManager.getMethodBindPtr("AudioStream", "is_monophonic", 36_873_697) internal val instantiatePlaybackPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStream", "instantiate_playback", 210135309) + TypeManager.getMethodBindPtr("AudioStream", "instantiate_playback", 210_135_309) internal val canBeSampledPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStream", "can_be_sampled", 36873697) + TypeManager.getMethodBindPtr("AudioStream", "can_be_sampled", 36_873_697) internal val generateSamplePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStream", "generate_sample", 2646048999) + TypeManager.getMethodBindPtr("AudioStream", "generate_sample", 2_646_048_999) internal val isMetaStreamPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStream", "is_meta_stream", 36873697) + TypeManager.getMethodBindPtr("AudioStream", "is_meta_stream", 36_873_697) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamGenerator.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamGenerator.kt index 39c0e2f2be..cda9fcb422 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamGenerator.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamGenerator.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -18,12 +15,10 @@ import kotlin.Float import kotlin.Int import kotlin.Long import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * [AudioStreamGenerator] is a type of audio stream that does not play back sounds on its own; - * instead, it expects a script to generate audio data for it. See also [AudioStreamGeneratorPlayback]. + * [AudioStreamGenerator] is a type of audio stream that does not play back sounds on its own; instead, it expects a script to generate audio data for it. See also [AudioStreamGeneratorPlayback]. * * Here's a sample on how to use it to generate a sine wave: * @@ -59,8 +54,7 @@ import kotlin.jvm.JvmName * * public override void _Ready() * { - * if (Player.Stream is AudioStreamGenerator generator) // Type as a generator to access - * MixRate. + * if (Player.Stream is AudioStreamGenerator generator) // Type as a generator to access MixRate. * { * _sampleHz = generator.MixRate; * Player.Play(); @@ -82,20 +76,16 @@ import kotlin.jvm.JvmName * } * ``` * - * In the example above, the "AudioStreamPlayer" node must use an [AudioStreamGenerator] as its - * stream. The `fill_buffer` function provides audio data for approximating a sine wave. + * In the example above, the "AudioStreamPlayer" node must use an [AudioStreamGenerator] as its stream. The `fill_buffer` function provides audio data for approximating a sine wave. * * See also [AudioEffectSpectrumAnalyzer] for performing real-time audio spectrum analysis. * - * **Note:** Due to performance constraints, this class is best used from C# or from a compiled - * language via GDExtension. If you still want to use this class from GDScript, consider using a lower - * [mixRate] such as 11,025 Hz or 22,050 Hz. + * **Note:** Due to performance constraints, this class is best used from C# or from a compiled language via GDExtension. If you still want to use this class from GDScript, consider using a lower [mixRate] such as 11,025 Hz or 22,050 Hz. */ @GodotBaseType public open class AudioStreamGenerator : AudioStream() { /** - * Mixing rate mode. If set to [MIX_RATE_CUSTOM], [mixRate] is used, otherwise current - * [AudioServer] mixing rate is used. + * Mixing rate mode. If set to [MIX_RATE_CUSTOM], [mixRate] is used, otherwise current [AudioServer] mixing rate is used. */ public final inline var mixRateMode: AudioStreamGeneratorMixRate @JvmName("mixRateModeProperty") @@ -106,24 +96,15 @@ public open class AudioStreamGenerator : AudioStream() { } /** - * The sample rate to use (in Hz). Higher values are more demanding for the CPU to generate, but - * result in better quality. + * The sample rate to use (in Hz). Higher values are more demanding for the CPU to generate, but result in better quality. * - * In games, common sample rates in use are `11025`, `16000`, `22050`, `32000`, `44100`, and - * `48000`. + * In games, common sample rates in use are `11025`, `16000`, `22050`, `32000`, `44100`, and `48000`. * - * According to the - * [url=https://en.wikipedia.org/wiki/Nyquist%E2%80%93Shannon_sampling_theorem]Nyquist-Shannon - * sampling theorem[/url], there is no quality difference to human hearing when going past 40,000 Hz - * (since most humans can only hear up to ~20,000 Hz, often less). If you are generating - * lower-pitched sounds such as voices, lower sample rates such as `32000` or `22050` may be usable - * with no loss in quality. + * According to the [url=https://en.wikipedia.org/wiki/Nyquist%E2%80%93Shannon_sampling_theorem]Nyquist-Shannon sampling theorem[/url], there is no quality difference to human hearing when going past 40,000 Hz (since most humans can only hear up to ~20,000 Hz, often less). If you are generating lower-pitched sounds such as voices, lower sample rates such as `32000` or `22050` may be usable with no loss in quality. * - * **Note:** [AudioStreamGenerator] is not automatically resampling input data, to produce - * expected result [mixRateMode] should match the sampling rate of input data. + * **Note:** [AudioStreamGenerator] is not automatically resampling input data, to produce expected result [mixRateMode] should match the sampling rate of input data. * - * **Note:** If you are using [AudioEffectCapture] as the source of your data, set [mixRateMode] - * to [MIX_RATE_INPUT] or [MIX_RATE_OUTPUT] to automatically match current [AudioServer] mixing rate. + * **Note:** If you are using [AudioEffectCapture] as the source of your data, set [mixRateMode] to [MIX_RATE_INPUT] or [MIX_RATE_OUTPUT] to automatically match current [AudioServer] mixing rate. */ public final inline var mixRate: Float @JvmName("mixRateProperty") @@ -134,9 +115,7 @@ public open class AudioStreamGenerator : AudioStream() { } /** - * The length of the buffer to generate (in seconds). Lower values result in less latency, but - * require the script to generate audio data faster, resulting in increased CPU usage and more risk - * for audio cracking if the CPU can't keep up. + * The length of the buffer to generate (in seconds). Lower values result in less latency, but require the script to generate audio data faster, resulting in increased CPU usage and more risk for audio cracking if the CPU can't keep up. */ public final inline var bufferLength: Float @JvmName("bufferLengthProperty") @@ -146,11 +125,11 @@ public open class AudioStreamGenerator : AudioStream() { setBufferLength(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(81, scriptIndex) } - public final fun setMixRate(hz: Float): Unit { + public final fun setMixRate(hz: Float) { TransferContext.writeArguments(DOUBLE to hz.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setMixRatePtr, NIL) } @@ -161,7 +140,7 @@ public open class AudioStreamGenerator : AudioStream() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setMixRateMode(mode: AudioStreamGeneratorMixRate): Unit { + public final fun setMixRateMode(mode: AudioStreamGeneratorMixRate) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setMixRateModePtr, NIL) } @@ -172,7 +151,7 @@ public open class AudioStreamGenerator : AudioStream() { return AudioStreamGeneratorMixRate.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setBufferLength(seconds: Float): Unit { + public final fun setBufferLength(seconds: Float) { TransferContext.writeArguments(DOUBLE to seconds.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setBufferLengthPtr, NIL) } @@ -210,8 +189,7 @@ public open class AudioStreamGenerator : AudioStream() { } public companion object { - public fun from(`value`: Long): AudioStreamGeneratorMixRate = - entries.single { it.id == `value` } + public fun from(`value`: Long): AudioStreamGeneratorMixRate = entries.single { it.id == `value` } } } @@ -219,21 +197,21 @@ public open class AudioStreamGenerator : AudioStream() { public object MethodBindings { internal val setMixRatePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamGenerator", "set_mix_rate", 373806689) + TypeManager.getMethodBindPtr("AudioStreamGenerator", "set_mix_rate", 373_806_689) internal val getMixRatePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamGenerator", "get_mix_rate", 1740695150) + TypeManager.getMethodBindPtr("AudioStreamGenerator", "get_mix_rate", 1_740_695_150) internal val setMixRateModePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamGenerator", "set_mix_rate_mode", 3354885803) + TypeManager.getMethodBindPtr("AudioStreamGenerator", "set_mix_rate_mode", 3_354_885_803) internal val getMixRateModePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamGenerator", "get_mix_rate_mode", 3537132591) + TypeManager.getMethodBindPtr("AudioStreamGenerator", "get_mix_rate_mode", 3_537_132_591) internal val setBufferLengthPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamGenerator", "set_buffer_length", 373806689) + TypeManager.getMethodBindPtr("AudioStreamGenerator", "set_buffer_length", 373_806_689) internal val getBufferLengthPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamGenerator", "get_buffer_length", 1740695150) + TypeManager.getMethodBindPtr("AudioStreamGenerator", "get_buffer_length", 1_740_695_150) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamGeneratorPlayback.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamGeneratorPlayback.kt index 0f9c849e8d..e177ad4859 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamGeneratorPlayback.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamGeneratorPlayback.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -23,23 +20,18 @@ import kotlin.Int import kotlin.Long import kotlin.NotImplementedError import kotlin.Suppress -import kotlin.Unit /** - * This class is meant to be used with [AudioStreamGenerator] to play back the generated audio in - * real-time. + * This class is meant to be used with [AudioStreamGenerator] to play back the generated audio in real-time. */ @GodotBaseType -public open class AudioStreamGeneratorPlayback internal constructor() : - AudioStreamPlaybackResampled() { - public override fun new(scriptIndex: Int): Unit { +public open class AudioStreamGeneratorPlayback internal constructor() : AudioStreamPlaybackResampled() { + override fun new(scriptIndex: Int) { createNativeObject(82, scriptIndex) } /** - * Pushes a single audio data frame to the buffer. This is usually less efficient than - * [pushBuffer] in C# and compiled languages via GDExtension, but [pushFrame] may be *more* efficient - * in GDScript. + * Pushes a single audio data frame to the buffer. This is usually less efficient than [pushBuffer] in C# and compiled languages via GDExtension, but [pushFrame] may be *more* efficient in GDScript. */ public final fun pushFrame(frame: Vector2): Boolean { TransferContext.writeArguments(VECTOR2 to frame) @@ -48,8 +40,7 @@ public open class AudioStreamGeneratorPlayback internal constructor() : } /** - * Returns `true` if a buffer of the size [amount] can be pushed to the audio sample data buffer - * without overflowing it, `false` otherwise. + * Returns `true` if a buffer of the size [amount] can be pushed to the audio sample data buffer without overflowing it, `false` otherwise. */ public final fun canPushBuffer(amount: Int): Boolean { TransferContext.writeArguments(LONG to amount.toLong()) @@ -58,9 +49,7 @@ public open class AudioStreamGeneratorPlayback internal constructor() : } /** - * Pushes several audio data frames to the buffer. This is usually more efficient than [pushFrame] - * in C# and compiled languages via GDExtension, but [pushBuffer] may be *less* efficient in - * GDScript. + * Pushes several audio data frames to the buffer. This is usually more efficient than [pushFrame] in C# and compiled languages via GDExtension, but [pushBuffer] may be *less* efficient in GDScript. */ public final fun pushBuffer(frames: PackedVector2Array): Boolean { TransferContext.writeArguments(PACKED_VECTOR2_ARRAY to frames) @@ -69,8 +58,7 @@ public open class AudioStreamGeneratorPlayback internal constructor() : } /** - * Returns the number of frames that can be pushed to the audio sample data buffer without - * overflowing it. If the result is `0`, the buffer is full. + * Returns the number of frames that can be pushed to the audio sample data buffer without overflowing it. If the result is `0`, the buffer is full. */ public final fun getFramesAvailable(): Int { TransferContext.writeArguments() @@ -79,8 +67,7 @@ public open class AudioStreamGeneratorPlayback internal constructor() : } /** - * Returns the number of times the playback skipped due to a buffer underrun in the audio sample - * data. This value is reset at the start of the playback. + * Returns the number of times the playback skipped due to a buffer underrun in the audio sample data. This value is reset at the start of the playback. */ public final fun getSkips(): Int { TransferContext.writeArguments() @@ -91,7 +78,7 @@ public open class AudioStreamGeneratorPlayback internal constructor() : /** * Clears the audio sample data buffer. */ - public final fun clearBuffer(): Unit { + public final fun clearBuffer() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.clearBufferPtr, NIL) } @@ -99,7 +86,7 @@ public open class AudioStreamGeneratorPlayback internal constructor() : /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _getStreamSamplingRate(): Float { + override fun _getStreamSamplingRate(): Float { throw NotImplementedError("AudioStreamGeneratorPlayback::_getStreamSamplingRate can't be called from the JVM.") } @@ -107,21 +94,21 @@ public open class AudioStreamGeneratorPlayback internal constructor() : public object MethodBindings { internal val pushFramePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamGeneratorPlayback", "push_frame", 3975407249) + TypeManager.getMethodBindPtr("AudioStreamGeneratorPlayback", "push_frame", 3_975_407_249) internal val canPushBufferPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamGeneratorPlayback", "can_push_buffer", 1116898809) + TypeManager.getMethodBindPtr("AudioStreamGeneratorPlayback", "can_push_buffer", 1_116_898_809) internal val pushBufferPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamGeneratorPlayback", "push_buffer", 1361156557) + TypeManager.getMethodBindPtr("AudioStreamGeneratorPlayback", "push_buffer", 1_361_156_557) internal val getFramesAvailablePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamGeneratorPlayback", "get_frames_available", 3905245786) + TypeManager.getMethodBindPtr("AudioStreamGeneratorPlayback", "get_frames_available", 3_905_245_786) internal val getSkipsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamGeneratorPlayback", "get_skips", 3905245786) + TypeManager.getMethodBindPtr("AudioStreamGeneratorPlayback", "get_skips", 3_905_245_786) internal val clearBufferPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamGeneratorPlayback", "clear_buffer", 3218959716) + TypeManager.getMethodBindPtr("AudioStreamGeneratorPlayback", "clear_buffer", 3_218_959_716) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamInteractive.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamInteractive.kt index a635afbfbe..1089fa9f5d 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamInteractive.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamInteractive.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -32,14 +29,9 @@ import kotlin.jvm.JvmName import kotlin.jvm.JvmOverloads /** - * This is an audio stream that can playback music interactively, combining clips and a transition - * table. Clips must be added first, and then the transition rules via the [addTransition]. - * Additionally, this stream exports a property parameter to control the playback via - * [AudioStreamPlayer], [AudioStreamPlayer2D], or [AudioStreamPlayer3D]. + * This is an audio stream that can playback music interactively, combining clips and a transition table. Clips must be added first, and then the transition rules via the [addTransition]. Additionally, this stream exports a property parameter to control the playback via [AudioStreamPlayer], [AudioStreamPlayer2D], or [AudioStreamPlayer3D]. * - * The way this is used is by filling a number of clips, then configuring the transition table. From - * there, clips are selected for playback and the music will smoothly go from the current to the new - * one while using the corresponding transition rule defined in the transition table. + * The way this is used is by filling a number of clips, then configuring the transition table. From there, clips are selected for playback and the music will smoothly go from the current to the new one while using the corresponding transition rule defined in the transition table. */ @GodotBaseType public open class AudioStreamInteractive : AudioStream() { @@ -65,11 +57,11 @@ public open class AudioStreamInteractive : AudioStream() { setInitialClip(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(83, scriptIndex) } - public final fun setClipCount(clipCount: Int): Unit { + public final fun setClipCount(clipCount: Int) { TransferContext.writeArguments(LONG to clipCount.toLong()) TransferContext.callMethod(ptr, MethodBindings.setClipCountPtr, NIL) } @@ -80,7 +72,7 @@ public open class AudioStreamInteractive : AudioStream() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setInitialClip(clipIndex: Int): Unit { + public final fun setInitialClip(clipIndex: Int) { TransferContext.writeArguments(LONG to clipIndex.toLong()) TransferContext.callMethod(ptr, MethodBindings.setInitialClipPtr, NIL) } @@ -94,7 +86,7 @@ public open class AudioStreamInteractive : AudioStream() { /** * Set the name of the current clip (for easier identification). */ - public final fun setClipName(clipIndex: Int, name: StringName): Unit { + public final fun setClipName(clipIndex: Int, name: StringName) { TransferContext.writeArguments(LONG to clipIndex.toLong(), STRING_NAME to name) TransferContext.callMethod(ptr, MethodBindings.setClipNamePtr, NIL) } @@ -111,7 +103,7 @@ public open class AudioStreamInteractive : AudioStream() { /** * Set the [AudioStream] associated with the current clip. */ - public final fun setClipStream(clipIndex: Int, stream: AudioStream?): Unit { + public final fun setClipStream(clipIndex: Int, stream: AudioStream?) { TransferContext.writeArguments(LONG to clipIndex.toLong(), OBJECT to stream) TransferContext.callMethod(ptr, MethodBindings.setClipStreamPtr, NIL) } @@ -128,7 +120,7 @@ public open class AudioStreamInteractive : AudioStream() { /** * Set whether a clip will auto-advance by changing the auto-advance mode. */ - public final fun setClipAutoAdvance(clipIndex: Int, mode: AutoAdvanceMode): Unit { + public final fun setClipAutoAdvance(clipIndex: Int, mode: AutoAdvanceMode) { TransferContext.writeArguments(LONG to clipIndex.toLong(), LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setClipAutoAdvancePtr, NIL) } @@ -143,10 +135,9 @@ public open class AudioStreamInteractive : AudioStream() { } /** - * Set the index of the next clip towards which this clip will auto advance to when finished. If - * the clip being played loops, then auto-advance will be ignored. + * Set the index of the next clip towards which this clip will auto advance to when finished. If the clip being played loops, then auto-advance will be ignored. */ - public final fun setClipAutoAdvanceNextClip(clipIndex: Int, autoAdvanceNextClip: Int): Unit { + public final fun setClipAutoAdvanceNextClip(clipIndex: Int, autoAdvanceNextClip: Int) { TransferContext.writeArguments(LONG to clipIndex.toLong(), LONG to autoAdvanceNextClip.toLong()) TransferContext.callMethod(ptr, MethodBindings.setClipAutoAdvanceNextClipPtr, NIL) } @@ -161,26 +152,21 @@ public open class AudioStreamInteractive : AudioStream() { } /** - * Add a transition between two clips. Provide the indices of the source and destination clips, or - * use the [CLIP_ANY] constant to indicate that transition happens to/from any clip to this one. + * Add a transition between two clips. Provide the indices of the source and destination clips, or use the [CLIP_ANY] constant to indicate that transition happens to/from any clip to this one. * - * * [fromTime] indicates the moment in the current clip the transition will begin after - * triggered. + * * [fromTime] indicates the moment in the current clip the transition will begin after triggered. * * * [toTime] indicates the time in the next clip that the playback will start from. * - * * [fadeMode] indicates how the fade will happen between clips. If unsure, just use - * [FADE_AUTOMATIC] which uses the most common type of fade for each situation. + * * [fadeMode] indicates how the fade will happen between clips. If unsure, just use [FADE_AUTOMATIC] which uses the most common type of fade for each situation. * * * [fadeBeats] indicates how many beats the fade will take. Using decimals is allowed. * - * * [useFillerClip] indicates that there will be a filler clip used between the source and - * destination clips. + * * [useFillerClip] indicates that there will be a filler clip used between the source and destination clips. * * * [fillerClip] the index of the filler clip. * - * * If [holdPrevious] is used, then this clip will be remembered. This can be used together with - * [AUTO_ADVANCE_RETURN_TO_HOLD] to return to this clip after another is done playing. + * * If [holdPrevious] is used, then this clip will be remembered. This can be used together with [AUTO_ADVANCE_RETURN_TO_HOLD] to return to this clip after another is done playing. */ @JvmOverloads public final fun addTransition( @@ -193,7 +179,7 @@ public open class AudioStreamInteractive : AudioStream() { useFillerClip: Boolean = false, fillerClip: Int = -1, holdPrevious: Boolean = false, - ): Unit { + ) { TransferContext.writeArguments(LONG to fromClip.toLong(), LONG to toClip.toLong(), LONG to fromTime.id, LONG to toTime.id, LONG to fadeMode.id, DOUBLE to fadeBeats.toDouble(), BOOL to useFillerClip, LONG to fillerClip.toLong(), BOOL to holdPrevious) TransferContext.callMethod(ptr, MethodBindings.addTransitionPtr, NIL) } @@ -208,10 +194,9 @@ public open class AudioStreamInteractive : AudioStream() { } /** - * Erase a transition by providing [fromClip] and [toClip] clip indices. [CLIP_ANY] can be used - * for either argument or both. + * Erase a transition by providing [fromClip] and [toClip] clip indices. [CLIP_ANY] can be used for either argument or both. */ - public final fun eraseTransition(fromClip: Int, toClip: Int): Unit { + public final fun eraseTransition(fromClip: Int, toClip: Int) { TransferContext.writeArguments(LONG to fromClip.toLong(), LONG to toClip.toLong()) TransferContext.callMethod(ptr, MethodBindings.eraseTransitionPtr, NIL) } @@ -291,8 +276,7 @@ public open class AudioStreamInteractive : AudioStream() { /** * Set the name of the current clip (for easier identification). */ - public final fun setClipName(clipIndex: Int, name: String) = - setClipName(clipIndex, name.asCachedStringName()) + public final fun setClipName(clipIndex: Int, name: String): Unit = setClipName(clipIndex, name.asCachedStringName()) public enum class TransitionFromTime( id: Long, @@ -329,8 +313,7 @@ public open class AudioStreamInteractive : AudioStream() { id: Long, ) { /** - * Transition to the same position in the destination clip. This is useful when both clips have - * exactly the same length and the music should fade between them. + * Transition to the same position in the destination clip. This is useful when both clips have exactly the same length and the music should fade between them. */ SAME_POSITION(0), /** @@ -353,8 +336,7 @@ public open class AudioStreamInteractive : AudioStream() { id: Long, ) { /** - * Do not use fade for the transition. This is useful when transitioning from a clip-end to - * clip-beginning, and each clip has their begin/end. + * Do not use fade for the transition. This is useful when transitioning from a clip-end to clip-beginning, and each clip has their begin/end. */ DISABLED(0), /** @@ -370,8 +352,7 @@ public open class AudioStreamInteractive : AudioStream() { */ CROSS(3), /** - * Use automatic fade logic depending on the transition from/to. It is recommended to use this - * by default. + * Use automatic fade logic depending on the transition from/to. It is recommended to use this by default. */ AUTOMATIC(4), ; @@ -398,8 +379,7 @@ public open class AudioStreamInteractive : AudioStream() { */ ENABLED(1), /** - * Enable auto-advance, but instead of specifying a clip, the playback will return to hold (see - * [addTransition]). + * Enable auto-advance, but instead of specifying a clip, the playback will return to hold (see [addTransition]). */ RETURN_TO_HOLD(2), ; @@ -416,80 +396,79 @@ public open class AudioStreamInteractive : AudioStream() { public companion object { /** - * This constant describes that any clip is valid for a specific transition as either source or - * destination. + * This constant describes that any clip is valid for a specific transition as either source or destination. */ public final const val CLIP_ANY: Long = -1 } public object MethodBindings { internal val setClipCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamInteractive", "set_clip_count", 1286410249) + TypeManager.getMethodBindPtr("AudioStreamInteractive", "set_clip_count", 1_286_410_249) internal val getClipCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamInteractive", "get_clip_count", 3905245786) + TypeManager.getMethodBindPtr("AudioStreamInteractive", "get_clip_count", 3_905_245_786) internal val setInitialClipPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamInteractive", "set_initial_clip", 1286410249) + TypeManager.getMethodBindPtr("AudioStreamInteractive", "set_initial_clip", 1_286_410_249) internal val getInitialClipPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamInteractive", "get_initial_clip", 3905245786) + TypeManager.getMethodBindPtr("AudioStreamInteractive", "get_initial_clip", 3_905_245_786) internal val setClipNamePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamInteractive", "set_clip_name", 3780747571) + TypeManager.getMethodBindPtr("AudioStreamInteractive", "set_clip_name", 3_780_747_571) internal val getClipNamePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamInteractive", "get_clip_name", 659327637) + TypeManager.getMethodBindPtr("AudioStreamInteractive", "get_clip_name", 659_327_637) internal val setClipStreamPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamInteractive", "set_clip_stream", 111075094) + TypeManager.getMethodBindPtr("AudioStreamInteractive", "set_clip_stream", 111_075_094) internal val getClipStreamPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamInteractive", "get_clip_stream", 2739380747) + TypeManager.getMethodBindPtr("AudioStreamInteractive", "get_clip_stream", 2_739_380_747) internal val setClipAutoAdvancePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamInteractive", "set_clip_auto_advance", 57217598) + TypeManager.getMethodBindPtr("AudioStreamInteractive", "set_clip_auto_advance", 57_217_598) internal val getClipAutoAdvancePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamInteractive", "get_clip_auto_advance", 1778634807) + TypeManager.getMethodBindPtr("AudioStreamInteractive", "get_clip_auto_advance", 1_778_634_807) internal val setClipAutoAdvanceNextClipPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamInteractive", "set_clip_auto_advance_next_clip", 3937882851) + TypeManager.getMethodBindPtr("AudioStreamInteractive", "set_clip_auto_advance_next_clip", 3_937_882_851) internal val getClipAutoAdvanceNextClipPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamInteractive", "get_clip_auto_advance_next_clip", 923996154) + TypeManager.getMethodBindPtr("AudioStreamInteractive", "get_clip_auto_advance_next_clip", 923_996_154) internal val addTransitionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamInteractive", "add_transition", 1630280552) + TypeManager.getMethodBindPtr("AudioStreamInteractive", "add_transition", 1_630_280_552) internal val hasTransitionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamInteractive", "has_transition", 2522259332) + TypeManager.getMethodBindPtr("AudioStreamInteractive", "has_transition", 2_522_259_332) internal val eraseTransitionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamInteractive", "erase_transition", 3937882851) + TypeManager.getMethodBindPtr("AudioStreamInteractive", "erase_transition", 3_937_882_851) internal val getTransitionListPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamInteractive", "get_transition_list", 1930428628) + TypeManager.getMethodBindPtr("AudioStreamInteractive", "get_transition_list", 1_930_428_628) internal val getTransitionFromTimePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamInteractive", "get_transition_from_time", 3453338158) + TypeManager.getMethodBindPtr("AudioStreamInteractive", "get_transition_from_time", 3_453_338_158) internal val getTransitionToTimePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamInteractive", "get_transition_to_time", 1369651373) + TypeManager.getMethodBindPtr("AudioStreamInteractive", "get_transition_to_time", 1_369_651_373) internal val getTransitionFadeModePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamInteractive", "get_transition_fade_mode", 4065396087) + TypeManager.getMethodBindPtr("AudioStreamInteractive", "get_transition_fade_mode", 4_065_396_087) internal val getTransitionFadeBeatsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamInteractive", "get_transition_fade_beats", 3085491603) + TypeManager.getMethodBindPtr("AudioStreamInteractive", "get_transition_fade_beats", 3_085_491_603) internal val isTransitionUsingFillerClipPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamInteractive", "is_transition_using_filler_clip", 2522259332) + TypeManager.getMethodBindPtr("AudioStreamInteractive", "is_transition_using_filler_clip", 2_522_259_332) internal val getTransitionFillerClipPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamInteractive", "get_transition_filler_clip", 3175239445) + TypeManager.getMethodBindPtr("AudioStreamInteractive", "get_transition_filler_clip", 3_175_239_445) internal val isTransitionHoldingPreviousPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamInteractive", "is_transition_holding_previous", 2522259332) + TypeManager.getMethodBindPtr("AudioStreamInteractive", "is_transition_holding_previous", 2_522_259_332) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamMP3.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamMP3.kt index dc99f9dd12..f4e52237d9 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamMP3.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamMP3.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -34,18 +31,14 @@ import kotlin.jvm.JvmStatic /** * MP3 audio stream driver. See [data] if you want to load an MP3 file at run-time. * - * **Note:** This class can optionally support legacy MP1 and MP2 formats, provided that the engine - * is compiled with the `minimp3_extra_formats=yes` SCons option. These extra formats are not enabled - * by default. + * **Note:** This class can optionally support legacy MP1 and MP2 formats, provided that the engine is compiled with the `minimp3_extra_formats=yes` SCons option. These extra formats are not enabled by default. */ @GodotBaseType public open class AudioStreamMP3 : AudioStream() { /** * Contains the audio data in bytes. * - * You can load a file without having to import it beforehand using the code snippet below. Keep - * in mind that this snippet loads the whole file into memory and may not be ideal for huge files - * (hundreds of megabytes or more). + * You can load a file without having to import it beforehand using the code snippet below. Keep in mind that this snippet loads the whole file into memory and may not be ideal for huge files (hundreds of megabytes or more). * * ```gdscript * //gdscript @@ -70,11 +63,8 @@ public open class AudioStreamMP3 : AudioStream() { * * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var `data`: PackedByteArray @@ -131,7 +121,7 @@ public open class AudioStreamMP3 : AudioStream() { setLoopOffset(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(84, scriptIndex) } @@ -148,9 +138,7 @@ public open class AudioStreamMP3 : AudioStream() { * * Contains the audio data in bytes. * - * You can load a file without having to import it beforehand using the code snippet below. Keep - * in mind that this snippet loads the whole file into memory and may not be ideal for huge files - * (hundreds of megabytes or more). + * You can load a file without having to import it beforehand using the code snippet below. Keep in mind that this snippet loads the whole file into memory and may not be ideal for huge files (hundreds of megabytes or more). * * ```gdscript * //gdscript @@ -180,14 +168,11 @@ public open class AudioStreamMP3 : AudioStream() { /** * This is a helper function for [data] to make dealing with local copies easier. - * Allow to directly modify each element of the local copy of the property and assign it back to - * the Object. + * Allow to directly modify each element of the local copy of the property and assign it back to the Object. * * Contains the audio data in bytes. * - * You can load a file without having to import it beforehand using the code snippet below. Keep - * in mind that this snippet loads the whole file into memory and may not be ideal for huge files - * (hundreds of megabytes or more). + * You can load a file without having to import it beforehand using the code snippet below. Keep in mind that this snippet loads the whole file into memory and may not be ideal for huge files (hundreds of megabytes or more). * * ```gdscript * //gdscript @@ -210,8 +195,7 @@ public open class AudioStreamMP3 : AudioStream() { * ``` */ @CoreTypeHelper - public final fun dataMutateEach(block: (index: Int, `value`: Byte) -> Unit): PackedByteArray = - data.apply { + public final fun dataMutateEach(block: (index: Int, `value`: Byte) -> Unit): PackedByteArray = data.apply { this.forEachIndexed { index, value -> block(index, value) this[index] = value @@ -219,7 +203,7 @@ public open class AudioStreamMP3 : AudioStream() { data = this } - public final fun setData(`data`: PackedByteArray): Unit { + public final fun setData(`data`: PackedByteArray) { TransferContext.writeArguments(PACKED_BYTE_ARRAY to data) TransferContext.callMethod(ptr, MethodBindings.setDataPtr, NIL) } @@ -230,7 +214,7 @@ public open class AudioStreamMP3 : AudioStream() { return (TransferContext.readReturnValue(PACKED_BYTE_ARRAY) as PackedByteArray) } - public final fun setLoop(enable: Boolean): Unit { + public final fun setLoop(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setLoopPtr, NIL) } @@ -241,7 +225,7 @@ public open class AudioStreamMP3 : AudioStream() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setLoopOffset(seconds: Double): Unit { + public final fun setLoopOffset(seconds: Double) { TransferContext.writeArguments(DOUBLE to seconds) TransferContext.callMethod(ptr, MethodBindings.setLoopOffsetPtr, NIL) } @@ -252,7 +236,7 @@ public open class AudioStreamMP3 : AudioStream() { return (TransferContext.readReturnValue(DOUBLE) as Double) } - public final fun setBpm(bpm: Double): Unit { + public final fun setBpm(bpm: Double) { TransferContext.writeArguments(DOUBLE to bpm) TransferContext.callMethod(ptr, MethodBindings.setBpmPtr, NIL) } @@ -263,7 +247,7 @@ public open class AudioStreamMP3 : AudioStream() { return (TransferContext.readReturnValue(DOUBLE) as Double) } - public final fun setBeatCount(count: Int): Unit { + public final fun setBeatCount(count: Int) { TransferContext.writeArguments(LONG to count.toLong()) TransferContext.callMethod(ptr, MethodBindings.setBeatCountPtr, NIL) } @@ -274,7 +258,7 @@ public open class AudioStreamMP3 : AudioStream() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setBarBeats(count: Int): Unit { + public final fun setBarBeats(count: Int) { TransferContext.writeArguments(LONG to count.toLong()) TransferContext.callMethod(ptr, MethodBindings.setBarBeatsPtr, NIL) } @@ -287,8 +271,7 @@ public open class AudioStreamMP3 : AudioStream() { public companion object { /** - * Creates a new [AudioStreamMP3] instance from the given buffer. The buffer must contain MP3 - * data. + * Creates a new [AudioStreamMP3] instance from the given buffer. The buffer must contain MP3 data. */ @JvmStatic public final fun loadFromBuffer(streamData: PackedByteArray): AudioStreamMP3? { @@ -298,8 +281,7 @@ public open class AudioStreamMP3 : AudioStream() { } /** - * Creates a new [AudioStreamMP3] instance from the given file path. The file must be in MP3 - * format. + * Creates a new [AudioStreamMP3] instance from the given file path. The file must be in MP3 format. */ @JvmStatic public final fun loadFromFile(path: String): AudioStreamMP3? { @@ -311,45 +293,45 @@ public open class AudioStreamMP3 : AudioStream() { public object MethodBindings { internal val loadFromBufferPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamMP3", "load_from_buffer", 1674970313) + TypeManager.getMethodBindPtr("AudioStreamMP3", "load_from_buffer", 1_674_970_313) internal val loadFromFilePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamMP3", "load_from_file", 4238362998) + TypeManager.getMethodBindPtr("AudioStreamMP3", "load_from_file", 4_238_362_998) internal val setDataPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamMP3", "set_data", 2971499966) + TypeManager.getMethodBindPtr("AudioStreamMP3", "set_data", 2_971_499_966) internal val getDataPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamMP3", "get_data", 2362200018) + TypeManager.getMethodBindPtr("AudioStreamMP3", "get_data", 2_362_200_018) internal val setLoopPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamMP3", "set_loop", 2586408642) + TypeManager.getMethodBindPtr("AudioStreamMP3", "set_loop", 2_586_408_642) internal val hasLoopPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamMP3", "has_loop", 36873697) + TypeManager.getMethodBindPtr("AudioStreamMP3", "has_loop", 36_873_697) internal val setLoopOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamMP3", "set_loop_offset", 373806689) + TypeManager.getMethodBindPtr("AudioStreamMP3", "set_loop_offset", 373_806_689) internal val getLoopOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamMP3", "get_loop_offset", 1740695150) + TypeManager.getMethodBindPtr("AudioStreamMP3", "get_loop_offset", 1_740_695_150) internal val setBpmPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamMP3", "set_bpm", 373806689) + TypeManager.getMethodBindPtr("AudioStreamMP3", "set_bpm", 373_806_689) internal val getBpmPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamMP3", "get_bpm", 1740695150) + TypeManager.getMethodBindPtr("AudioStreamMP3", "get_bpm", 1_740_695_150) internal val setBeatCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamMP3", "set_beat_count", 1286410249) + TypeManager.getMethodBindPtr("AudioStreamMP3", "set_beat_count", 1_286_410_249) internal val getBeatCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamMP3", "get_beat_count", 3905245786) + TypeManager.getMethodBindPtr("AudioStreamMP3", "get_beat_count", 3_905_245_786) internal val setBarBeatsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamMP3", "set_bar_beats", 1286410249) + TypeManager.getMethodBindPtr("AudioStreamMP3", "set_bar_beats", 1_286_410_249) internal val getBarBeatsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamMP3", "get_bar_beats", 3905245786) + TypeManager.getMethodBindPtr("AudioStreamMP3", "get_bar_beats", 3_905_245_786) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamMicrophone.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamMicrophone.kt index ef1a0b7262..a34dc64658 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamMicrophone.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamMicrophone.kt @@ -1,28 +1,20 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api import godot.`annotation`.GodotBaseType import kotlin.Int import kotlin.Suppress -import kotlin.Unit /** - * When used directly in an [AudioStreamPlayer] node, [AudioStreamMicrophone] plays back microphone - * input in real-time. This can be used in conjunction with [AudioEffectCapture] to process the data or - * save it. + * When used directly in an [AudioStreamPlayer] node, [AudioStreamMicrophone] plays back microphone input in real-time. This can be used in conjunction with [AudioEffectCapture] to process the data or save it. * - * **Note:** [ProjectSettings.audio/driver/enableInput] must be `true` for audio input to work. See - * also that setting's description for caveats related to permissions and operating system privacy - * settings. + * **Note:** [ProjectSettings.audio/driver/enableInput] must be `true` for audio input to work. See also that setting's description for caveats related to permissions and operating system privacy settings. */ @GodotBaseType public open class AudioStreamMicrophone : AudioStream() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(85, scriptIndex) } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamOggVorbis.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamOggVorbis.kt index 5bc4d2fd88..c752ce343a 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamOggVorbis.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamOggVorbis.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -24,15 +21,11 @@ import kotlin.Int import kotlin.Long import kotlin.String import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName import kotlin.jvm.JvmStatic /** - * The AudioStreamOggVorbis class is a specialized [AudioStream] for handling Ogg Vorbis file - * formats. It offers functionality for loading and playing back Ogg Vorbis files, as well as managing - * looping and other playback properties. This class is part of the audio stream system, which also - * supports WAV files through the [AudioStreamWAV] class. + * The AudioStreamOggVorbis class is a specialized [AudioStream] for handling Ogg Vorbis file formats. It offers functionality for loading and playing back Ogg Vorbis files, as well as managing looping and other playback properties. This class is part of the audio stream system, which also supports WAV files through the [AudioStreamWAV] class. */ @GodotBaseType public open class AudioStreamOggVorbis : AudioStream() { @@ -72,8 +65,7 @@ public open class AudioStreamOggVorbis : AudioStream() { } /** - * If `true`, the audio will play again from the specified [loopOffset] once it is done playing. - * Useful for ambient sounds and background music. + * If `true`, the audio will play again from the specified [loopOffset] once it is done playing. Useful for ambient sounds and background music. */ public final inline var loop: Boolean @JvmName("loopProperty") @@ -94,11 +86,11 @@ public open class AudioStreamOggVorbis : AudioStream() { setLoopOffset(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(86, scriptIndex) } - public final fun setPacketSequence(packetSequence: OggPacketSequence?): Unit { + public final fun setPacketSequence(packetSequence: OggPacketSequence?) { TransferContext.writeArguments(OBJECT to packetSequence) TransferContext.callMethod(ptr, MethodBindings.setPacketSequencePtr, NIL) } @@ -109,7 +101,7 @@ public open class AudioStreamOggVorbis : AudioStream() { return (TransferContext.readReturnValue(OBJECT) as OggPacketSequence?) } - public final fun setLoop(enable: Boolean): Unit { + public final fun setLoop(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setLoopPtr, NIL) } @@ -120,7 +112,7 @@ public open class AudioStreamOggVorbis : AudioStream() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setLoopOffset(seconds: Double): Unit { + public final fun setLoopOffset(seconds: Double) { TransferContext.writeArguments(DOUBLE to seconds) TransferContext.callMethod(ptr, MethodBindings.setLoopOffsetPtr, NIL) } @@ -131,7 +123,7 @@ public open class AudioStreamOggVorbis : AudioStream() { return (TransferContext.readReturnValue(DOUBLE) as Double) } - public final fun setBpm(bpm: Double): Unit { + public final fun setBpm(bpm: Double) { TransferContext.writeArguments(DOUBLE to bpm) TransferContext.callMethod(ptr, MethodBindings.setBpmPtr, NIL) } @@ -142,7 +134,7 @@ public open class AudioStreamOggVorbis : AudioStream() { return (TransferContext.readReturnValue(DOUBLE) as Double) } - public final fun setBeatCount(count: Int): Unit { + public final fun setBeatCount(count: Int) { TransferContext.writeArguments(LONG to count.toLong()) TransferContext.callMethod(ptr, MethodBindings.setBeatCountPtr, NIL) } @@ -153,7 +145,7 @@ public open class AudioStreamOggVorbis : AudioStream() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setBarBeats(count: Int): Unit { + public final fun setBarBeats(count: Int) { TransferContext.writeArguments(LONG to count.toLong()) TransferContext.callMethod(ptr, MethodBindings.setBarBeatsPtr, NIL) } @@ -166,8 +158,7 @@ public open class AudioStreamOggVorbis : AudioStream() { public companion object { /** - * Creates a new [AudioStreamOggVorbis] instance from the given buffer. The buffer must contain - * Ogg Vorbis data. + * Creates a new [AudioStreamOggVorbis] instance from the given buffer. The buffer must contain Ogg Vorbis data. */ @JvmStatic public final fun loadFromBuffer(streamData: PackedByteArray): AudioStreamOggVorbis? { @@ -177,8 +168,7 @@ public open class AudioStreamOggVorbis : AudioStream() { } /** - * Creates a new [AudioStreamOggVorbis] instance from the given file path. The file must be in - * Ogg Vorbis format. + * Creates a new [AudioStreamOggVorbis] instance from the given file path. The file must be in Ogg Vorbis format. */ @JvmStatic public final fun loadFromFile(path: String): AudioStreamOggVorbis? { @@ -190,45 +180,45 @@ public open class AudioStreamOggVorbis : AudioStream() { public object MethodBindings { internal val loadFromBufferPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamOggVorbis", "load_from_buffer", 354904730) + TypeManager.getMethodBindPtr("AudioStreamOggVorbis", "load_from_buffer", 354_904_730) internal val loadFromFilePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamOggVorbis", "load_from_file", 797568536) + TypeManager.getMethodBindPtr("AudioStreamOggVorbis", "load_from_file", 797_568_536) internal val setPacketSequencePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamOggVorbis", "set_packet_sequence", 438882457) + TypeManager.getMethodBindPtr("AudioStreamOggVorbis", "set_packet_sequence", 438_882_457) internal val getPacketSequencePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamOggVorbis", "get_packet_sequence", 2801636033) + TypeManager.getMethodBindPtr("AudioStreamOggVorbis", "get_packet_sequence", 2_801_636_033) internal val setLoopPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamOggVorbis", "set_loop", 2586408642) + TypeManager.getMethodBindPtr("AudioStreamOggVorbis", "set_loop", 2_586_408_642) internal val hasLoopPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamOggVorbis", "has_loop", 36873697) + TypeManager.getMethodBindPtr("AudioStreamOggVorbis", "has_loop", 36_873_697) internal val setLoopOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamOggVorbis", "set_loop_offset", 373806689) + TypeManager.getMethodBindPtr("AudioStreamOggVorbis", "set_loop_offset", 373_806_689) internal val getLoopOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamOggVorbis", "get_loop_offset", 1740695150) + TypeManager.getMethodBindPtr("AudioStreamOggVorbis", "get_loop_offset", 1_740_695_150) internal val setBpmPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamOggVorbis", "set_bpm", 373806689) + TypeManager.getMethodBindPtr("AudioStreamOggVorbis", "set_bpm", 373_806_689) internal val getBpmPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamOggVorbis", "get_bpm", 1740695150) + TypeManager.getMethodBindPtr("AudioStreamOggVorbis", "get_bpm", 1_740_695_150) internal val setBeatCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamOggVorbis", "set_beat_count", 1286410249) + TypeManager.getMethodBindPtr("AudioStreamOggVorbis", "set_beat_count", 1_286_410_249) internal val getBeatCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamOggVorbis", "get_beat_count", 3905245786) + TypeManager.getMethodBindPtr("AudioStreamOggVorbis", "get_beat_count", 3_905_245_786) internal val setBarBeatsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamOggVorbis", "set_bar_beats", 1286410249) + TypeManager.getMethodBindPtr("AudioStreamOggVorbis", "set_bar_beats", 1_286_410_249) internal val getBarBeatsPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamOggVorbis", "get_bar_beats", 3905245786) + TypeManager.getMethodBindPtr("AudioStreamOggVorbis", "get_bar_beats", 3_905_245_786) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlayback.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlayback.kt index a95c76030e..00c105ba41 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlayback.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlayback.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -26,46 +23,40 @@ import kotlin.Int import kotlin.Long import kotlin.NotImplementedError import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmOverloads /** - * Can play, loop, pause a scroll through audio. See [AudioStream] and [AudioStreamOggVorbis] for - * usage. + * Can play, loop, pause a scroll through audio. See [AudioStream] and [AudioStreamOggVorbis] for usage. */ @GodotBaseType public abstract class AudioStreamPlayback : RefCounted() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(87, scriptIndex) } /** - * Override this method to customize what happens when the playback starts at the given position, - * such as by calling [AudioStreamPlayer.play]. + * Override this method to customize what happens when the playback starts at the given position, such as by calling [AudioStreamPlayer.play]. */ - public open fun _start(fromPos: Double): Unit { + public open fun _start(fromPos: Double) { throw NotImplementedError("AudioStreamPlayback::_start is not implemented.") } /** - * Override this method to customize what happens when the playback is stopped, such as by calling - * [AudioStreamPlayer.stop]. + * Override this method to customize what happens when the playback is stopped, such as by calling [AudioStreamPlayer.stop]. */ - public open fun _stop(): Unit { + public open fun _stop() { throw NotImplementedError("AudioStreamPlayback::_stop is not implemented.") } /** - * Overridable method. Should return `true` if this playback is active and playing its audio - * stream. + * Overridable method. Should return `true` if this playback is active and playing its audio stream. */ public open fun _isPlaying(): Boolean { throw NotImplementedError("AudioStreamPlayback::_isPlaying is not implemented.") } /** - * Overridable method. Should return how many times this audio stream has looped. Most built-in - * playbacks always return `0`. + * Overridable method. Should return how many times this audio stream has looped. Most built-in playbacks always return `0`. */ public open fun _getLoopCount(): Int { throw NotImplementedError("AudioStreamPlayback::_getLoopCount is not implemented.") @@ -79,26 +70,23 @@ public abstract class AudioStreamPlayback : RefCounted() { } /** - * Override this method to customize what happens when seeking this audio stream at the given - * [position], such as by calling [AudioStreamPlayer.seek]. + * Override this method to customize what happens when seeking this audio stream at the given [position], such as by calling [AudioStreamPlayer.seek]. */ - public open fun _seek(position: Double): Unit { + public open fun _seek(position: Double) { throw NotImplementedError("AudioStreamPlayback::_seek is not implemented.") } /** - * Overridable method. Called whenever the audio stream is mixed if the playback is active and - * [AudioServer.setEnableTaggingUsedAudioStreams] has been set to `true`. Editor plugins may use this - * method to "tag" the current position along the audio stream and display it in a preview. + * Overridable method. Called whenever the audio stream is mixed if the playback is active and [AudioServer.setEnableTaggingUsedAudioStreams] has been set to `true`. Editor plugins may use this method to "tag" the current position along the audio stream and display it in a preview. */ - public open fun _tagUsedStreams(): Unit { + public open fun _tagUsedStreams() { throw NotImplementedError("AudioStreamPlayback::_tagUsedStreams is not implemented.") } /** * Set the current value of a playback parameter by name (see [AudioStream.GetParameterList]). */ - public open fun _setParameter(name: StringName, `value`: Any?): Unit { + public open fun _setParameter(name: StringName, `value`: Any?) { throw NotImplementedError("AudioStreamPlayback::_setParameter is not implemented.") } @@ -110,17 +98,15 @@ public abstract class AudioStreamPlayback : RefCounted() { } /** - * Associates [AudioSamplePlayback] to this [AudioStreamPlayback] for playing back the audio - * sample of this stream. + * Associates [AudioSamplePlayback] to this [AudioStreamPlayback] for playing back the audio sample of this stream. */ - public final fun setSamplePlayback(playbackSample: AudioSamplePlayback?): Unit { + public final fun setSamplePlayback(playbackSample: AudioSamplePlayback?) { TransferContext.writeArguments(OBJECT to playbackSample) TransferContext.callMethod(ptr, MethodBindings.setSamplePlaybackPtr, NIL) } /** - * Returns the [AudioSamplePlayback] associated with this [AudioStreamPlayback] for playing back - * the audio sample of this stream. + * Returns the [AudioSamplePlayback] associated with this [AudioStreamPlayback] for playing back the audio sample of this stream. */ public final fun getSamplePlayback(): AudioSamplePlayback? { TransferContext.writeArguments() @@ -129,14 +115,11 @@ public abstract class AudioStreamPlayback : RefCounted() { } /** - * Mixes up to [frames] of audio from the stream from the current position, at a rate of - * [rateScale], advancing the stream. + * Mixes up to [frames] of audio from the stream from the current position, at a rate of [rateScale], advancing the stream. * - * Returns a [PackedVector2Array] where each element holds the left and right channel volume - * levels of each frame. + * Returns a [PackedVector2Array] where each element holds the left and right channel volume levels of each frame. * - * **Note:** Can return fewer frames than requested, make sure to use the size of the return - * value. + * **Note:** Can return fewer frames than requested, make sure to use the size of the return value. */ public final fun mixAudio(rateScale: Float, frames: Int): PackedVector2Array { TransferContext.writeArguments(DOUBLE to rateScale.toDouble(), LONG to frames.toLong()) @@ -148,7 +131,7 @@ public abstract class AudioStreamPlayback : RefCounted() { * Starts the stream from the given [fromPos], in seconds. */ @JvmOverloads - public final fun start(fromPos: Double = 0.0): Unit { + public final fun start(fromPos: Double = 0.0) { TransferContext.writeArguments(DOUBLE to fromPos) TransferContext.callMethod(ptr, MethodBindings.startPtr, NIL) } @@ -157,7 +140,7 @@ public abstract class AudioStreamPlayback : RefCounted() { * Seeks the stream at the given [time], in seconds. */ @JvmOverloads - public final fun seek(time: Double = 0.0): Unit { + public final fun seek(time: Double = 0.0) { TransferContext.writeArguments(DOUBLE to time) TransferContext.callMethod(ptr, MethodBindings.seekPtr, NIL) } @@ -165,7 +148,7 @@ public abstract class AudioStreamPlayback : RefCounted() { /** * Stops the stream. */ - public final fun stop(): Unit { + public final fun stop() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.stopPtr, NIL) } @@ -201,30 +184,30 @@ public abstract class AudioStreamPlayback : RefCounted() { public object MethodBindings { internal val setSamplePlaybackPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayback", "set_sample_playback", 3195455091) + TypeManager.getMethodBindPtr("AudioStreamPlayback", "set_sample_playback", 3_195_455_091) internal val getSamplePlaybackPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayback", "get_sample_playback", 3482738536) + TypeManager.getMethodBindPtr("AudioStreamPlayback", "get_sample_playback", 3_482_738_536) internal val mixAudioPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayback", "mix_audio", 3341291446) + TypeManager.getMethodBindPtr("AudioStreamPlayback", "mix_audio", 3_341_291_446) internal val startPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayback", "start", 1958160172) + TypeManager.getMethodBindPtr("AudioStreamPlayback", "start", 1_958_160_172) internal val seekPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayback", "seek", 1958160172) + TypeManager.getMethodBindPtr("AudioStreamPlayback", "seek", 1_958_160_172) internal val stopPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayback", "stop", 3218959716) + TypeManager.getMethodBindPtr("AudioStreamPlayback", "stop", 3_218_959_716) internal val getLoopCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayback", "get_loop_count", 3905245786) + TypeManager.getMethodBindPtr("AudioStreamPlayback", "get_loop_count", 3_905_245_786) internal val getPlaybackPositionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayback", "get_playback_position", 1740695150) + TypeManager.getMethodBindPtr("AudioStreamPlayback", "get_playback_position", 1_740_695_150) internal val isPlayingPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayback", "is_playing", 36873697) + TypeManager.getMethodBindPtr("AudioStreamPlayback", "is_playing", 36_873_697) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlaybackInteractive.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlaybackInteractive.kt index 42997a73dd..292eb21f75 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlaybackInteractive.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlaybackInteractive.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -22,19 +19,18 @@ import kotlin.Suppress import kotlin.Unit /** - * Playback component of [AudioStreamInteractive]. Contains functions to change the currently played - * clip. + * Playback component of [AudioStreamInteractive]. Contains functions to change the currently played clip. */ @GodotBaseType public open class AudioStreamPlaybackInteractive internal constructor() : AudioStreamPlayback() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(88, scriptIndex) } /** * Switch to a clip (by name). */ - public final fun switchToClipByName(clipName: StringName): Unit { + public final fun switchToClipByName(clipName: StringName) { TransferContext.writeArguments(STRING_NAME to clipName) TransferContext.callMethod(ptr, MethodBindings.switchToClipByNamePtr, NIL) } @@ -42,14 +38,13 @@ public open class AudioStreamPlaybackInteractive internal constructor() : AudioS /** * Switch to a clip (by index). */ - public final fun switchToClip(clipIndex: Int): Unit { + public final fun switchToClip(clipIndex: Int) { TransferContext.writeArguments(LONG to clipIndex.toLong()) TransferContext.callMethod(ptr, MethodBindings.switchToClipPtr, NIL) } /** - * Return the index of the currently playing clip. You can use this to get the name of the - * currently playing clip with [AudioStreamInteractive.getClipName]. + * Return the index of the currently playing clip. You can use this to get the name of the currently playing clip with [AudioStreamInteractive.getClipName]. * * **Example:** Get the currently playing clip name from inside an [AudioStreamPlayer] node. * @@ -67,19 +62,18 @@ public open class AudioStreamPlaybackInteractive internal constructor() : AudioS /** * Switch to a clip (by name). */ - public final fun switchToClipByName(clipName: String) = - switchToClipByName(clipName.asCachedStringName()) + public final fun switchToClipByName(clipName: String): Unit = switchToClipByName(clipName.asCachedStringName()) public companion object public object MethodBindings { internal val switchToClipByNamePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlaybackInteractive", "switch_to_clip_by_name", 3304788590) + TypeManager.getMethodBindPtr("AudioStreamPlaybackInteractive", "switch_to_clip_by_name", 3_304_788_590) internal val switchToClipPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlaybackInteractive", "switch_to_clip", 1286410249) + TypeManager.getMethodBindPtr("AudioStreamPlaybackInteractive", "switch_to_clip", 1_286_410_249) internal val getCurrentClipIndexPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlaybackInteractive", "get_current_clip_index", 3905245786) + TypeManager.getMethodBindPtr("AudioStreamPlaybackInteractive", "get_current_clip_index", 3_905_245_786) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlaybackOggVorbis.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlaybackOggVorbis.kt index e54c32bf4c..dfc3137d3f 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlaybackOggVorbis.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlaybackOggVorbis.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -11,18 +8,17 @@ import kotlin.Float import kotlin.Int import kotlin.NotImplementedError import kotlin.Suppress -import kotlin.Unit @GodotBaseType public open class AudioStreamPlaybackOggVorbis : AudioStreamPlaybackResampled() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(89, scriptIndex) } /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _getStreamSamplingRate(): Float { + override fun _getStreamSamplingRate(): Float { throw NotImplementedError("AudioStreamPlaybackOggVorbis::_getStreamSamplingRate can't be called from the JVM.") } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlaybackPlaylist.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlaybackPlaylist.kt index 599c8d28c1..a51d221df3 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlaybackPlaylist.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlaybackPlaylist.kt @@ -1,19 +1,15 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api import godot.`annotation`.GodotBaseType import kotlin.Int import kotlin.Suppress -import kotlin.Unit @GodotBaseType public open class AudioStreamPlaybackPlaylist internal constructor() : AudioStreamPlayback() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(90, scriptIndex) } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlaybackPolyphonic.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlaybackPolyphonic.kt index a39b5bf847..5f26a24340 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlaybackPolyphonic.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlaybackPolyphonic.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -24,34 +21,25 @@ import kotlin.Int import kotlin.Long import kotlin.String import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmOverloads /** - * Playback instance for [AudioStreamPolyphonic]. After setting the `stream` property of - * [AudioStreamPlayer], [AudioStreamPlayer2D], or [AudioStreamPlayer3D], the playback instance can be - * obtained by calling [AudioStreamPlayer.getStreamPlayback], [AudioStreamPlayer2D.getStreamPlayback] - * or [AudioStreamPlayer3D.getStreamPlayback] methods. + * Playback instance for [AudioStreamPolyphonic]. After setting the `stream` property of [AudioStreamPlayer], [AudioStreamPlayer2D], or [AudioStreamPlayer3D], the playback instance can be obtained by calling [AudioStreamPlayer.getStreamPlayback], [AudioStreamPlayer2D.getStreamPlayback] or [AudioStreamPlayer3D.getStreamPlayback] methods. */ @GodotBaseType public open class AudioStreamPlaybackPolyphonic internal constructor() : AudioStreamPlayback() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(91, scriptIndex) } /** - * Play an [AudioStream] at a given offset, volume, pitch scale, playback type, and bus. Playback - * starts immediately. + * Play an [AudioStream] at a given offset, volume, pitch scale, playback type, and bus. Playback starts immediately. * - * The return value is a unique integer ID that is associated to this playback stream and which - * can be used to control it. + * The return value is a unique integer ID that is associated to this playback stream and which can be used to control it. * - * This ID becomes invalid when the stream ends (if it does not loop), when the - * [AudioStreamPlaybackPolyphonic] is stopped, or when [stopStream] is called. + * This ID becomes invalid when the stream ends (if it does not loop), when the [AudioStreamPlaybackPolyphonic] is stopped, or when [stopStream] is called. * - * This function returns [INVALID_ID] if the amount of streams currently playing equals - * [AudioStreamPolyphonic.polyphony]. If you need a higher amount of maximum polyphony, raise this - * value. + * This function returns [INVALID_ID] if the amount of streams currently playing equals [AudioStreamPolyphonic.polyphony]. If you need a higher amount of maximum polyphony, raise this value. */ @JvmOverloads public final fun playStream( @@ -68,10 +56,9 @@ public open class AudioStreamPlaybackPolyphonic internal constructor() : AudioSt } /** - * Change the stream volume (in db). The [stream] argument is an integer ID returned by - * [playStream]. + * Change the stream volume (in db). The [stream] argument is an integer ID returned by [playStream]. */ - public final fun setStreamVolume(stream: Long, volumeDb: Float): Unit { + public final fun setStreamVolume(stream: Long, volumeDb: Float) { TransferContext.writeArguments(LONG to stream, DOUBLE to volumeDb.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setStreamVolumePtr, NIL) } @@ -79,14 +66,13 @@ public open class AudioStreamPlaybackPolyphonic internal constructor() : AudioSt /** * Change the stream pitch scale. The [stream] argument is an integer ID returned by [playStream]. */ - public final fun setStreamPitchScale(stream: Long, pitchScale: Float): Unit { + public final fun setStreamPitchScale(stream: Long, pitchScale: Float) { TransferContext.writeArguments(LONG to stream, DOUBLE to pitchScale.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setStreamPitchScalePtr, NIL) } /** - * Returns `true` if the stream associated with the given integer ID is still playing. Check - * [playStream] for information on when this ID becomes invalid. + * Returns `true` if the stream associated with the given integer ID is still playing. Check [playStream] for information on when this ID becomes invalid. */ public final fun isStreamPlaying(stream: Long): Boolean { TransferContext.writeArguments(LONG to stream) @@ -95,27 +81,21 @@ public open class AudioStreamPlaybackPolyphonic internal constructor() : AudioSt } /** - * Stop a stream. The [stream] argument is an integer ID returned by [playStream], which becomes - * invalid after calling this function. + * Stop a stream. The [stream] argument is an integer ID returned by [playStream], which becomes invalid after calling this function. */ - public final fun stopStream(stream: Long): Unit { + public final fun stopStream(stream: Long) { TransferContext.writeArguments(LONG to stream) TransferContext.callMethod(ptr, MethodBindings.stopStreamPtr, NIL) } /** - * Play an [AudioStream] at a given offset, volume, pitch scale, playback type, and bus. Playback - * starts immediately. + * Play an [AudioStream] at a given offset, volume, pitch scale, playback type, and bus. Playback starts immediately. * - * The return value is a unique integer ID that is associated to this playback stream and which - * can be used to control it. + * The return value is a unique integer ID that is associated to this playback stream and which can be used to control it. * - * This ID becomes invalid when the stream ends (if it does not loop), when the - * [AudioStreamPlaybackPolyphonic] is stopped, or when [stopStream] is called. + * This ID becomes invalid when the stream ends (if it does not loop), when the [AudioStreamPlaybackPolyphonic] is stopped, or when [stopStream] is called. * - * This function returns [INVALID_ID] if the amount of streams currently playing equals - * [AudioStreamPolyphonic.polyphony]. If you need a higher amount of maximum polyphony, raise this - * value. + * This function returns [INVALID_ID] if the amount of streams currently playing equals [AudioStreamPolyphonic.polyphony]. If you need a higher amount of maximum polyphony, raise this value. */ @JvmOverloads public final fun playStream( @@ -125,8 +105,7 @@ public open class AudioStreamPlaybackPolyphonic internal constructor() : AudioSt pitchScale: Float = 1.0f, playbackType: AudioServer.PlaybackType = AudioServer.PlaybackType.DEFAULT, bus: String, - ): Long = - playStream(stream, fromOffset, volumeDb, pitchScale, playbackType, bus.asCachedStringName()) + ): Long = playStream(stream, fromOffset, volumeDb, pitchScale, playbackType, bus.asCachedStringName()) public companion object { /** @@ -137,18 +116,18 @@ public open class AudioStreamPlaybackPolyphonic internal constructor() : AudioSt public object MethodBindings { internal val playStreamPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlaybackPolyphonic", "play_stream", 1846744803) + TypeManager.getMethodBindPtr("AudioStreamPlaybackPolyphonic", "play_stream", 1_846_744_803) internal val setStreamVolumePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlaybackPolyphonic", "set_stream_volume", 1602489585) + TypeManager.getMethodBindPtr("AudioStreamPlaybackPolyphonic", "set_stream_volume", 1_602_489_585) internal val setStreamPitchScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlaybackPolyphonic", "set_stream_pitch_scale", 1602489585) + TypeManager.getMethodBindPtr("AudioStreamPlaybackPolyphonic", "set_stream_pitch_scale", 1_602_489_585) internal val isStreamPlayingPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlaybackPolyphonic", "is_stream_playing", 1116898809) + TypeManager.getMethodBindPtr("AudioStreamPlaybackPolyphonic", "is_stream_playing", 1_116_898_809) internal val stopStreamPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlaybackPolyphonic", "stop_stream", 1286410249) + TypeManager.getMethodBindPtr("AudioStreamPlaybackPolyphonic", "stop_stream", 1_286_410_249) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlaybackResampled.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlaybackResampled.kt index 8982f84c18..07f0a0ecdd 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlaybackResampled.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlaybackResampled.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -14,17 +11,16 @@ import godot.core.VariantParser.NIL import kotlin.Float import kotlin.Int import kotlin.Suppress -import kotlin.Unit @GodotBaseType public abstract class AudioStreamPlaybackResampled : AudioStreamPlayback() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(92, scriptIndex) } public abstract fun _getStreamSamplingRate(): Float - public final fun beginResample(): Unit { + public final fun beginResample() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.beginResamplePtr, NIL) } @@ -33,6 +29,6 @@ public abstract class AudioStreamPlaybackResampled : AudioStreamPlayback() { public object MethodBindings { internal val beginResamplePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlaybackResampled", "begin_resample", 3218959716) + TypeManager.getMethodBindPtr("AudioStreamPlaybackResampled", "begin_resample", 3_218_959_716) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlaybackSynchronized.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlaybackSynchronized.kt index dc1b5bdaf3..b06a442828 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlaybackSynchronized.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlaybackSynchronized.kt @@ -1,19 +1,15 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api import godot.`annotation`.GodotBaseType import kotlin.Int import kotlin.Suppress -import kotlin.Unit @GodotBaseType public open class AudioStreamPlaybackSynchronized internal constructor() : AudioStreamPlayback() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(93, scriptIndex) } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlayer.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlayer.kt index 9d34c525da..a209958fcd 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlayer.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlayer.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -31,26 +28,21 @@ import kotlin.jvm.JvmName import kotlin.jvm.JvmOverloads /** - * The [AudioStreamPlayer] node plays an audio stream non-positionally. It is ideal for user - * interfaces, menus, or background music. + * The [AudioStreamPlayer] node plays an audio stream non-positionally. It is ideal for user interfaces, menus, or background music. * - * To use this node, [stream] needs to be set to a valid [AudioStream] resource. Playing more than - * one sound at the same time is also supported, see [maxPolyphony]. + * To use this node, [stream] needs to be set to a valid [AudioStream] resource. Playing more than one sound at the same time is also supported, see [maxPolyphony]. * - * If you need to play audio at a specific position, use [AudioStreamPlayer2D] or - * [AudioStreamPlayer3D] instead. + * If you need to play audio at a specific position, use [AudioStreamPlayer2D] or [AudioStreamPlayer3D] instead. */ @GodotBaseType public open class AudioStreamPlayer : Node() { /** - * Emitted when a sound finishes playing without interruptions. This signal is *not* emitted when - * calling [stop], or when exiting the tree while sounds are playing. + * Emitted when a sound finishes playing without interruptions. This signal is *not* emitted when calling [stop], or when exiting the tree while sounds are playing. */ public val finished: Signal0 by Signal0 /** - * The [AudioStream] resource to be played. Setting this property stops all currently playing - * sounds. If left empty, the [AudioStreamPlayer] does not work. + * The [AudioStream] resource to be played. Setting this property stops all currently playing sounds. If left empty, the [AudioStreamPlayer] does not work. */ public final inline var stream: AudioStream? @JvmName("streamProperty") @@ -63,8 +55,7 @@ public open class AudioStreamPlayer : Node() { /** * Volume of sound, in decibels. This is an offset of the [stream]'s volume. * - * **Note:** To convert between decibel and linear energy (like most volume sliders do), use - * [volumeLinear], or [@GlobalScope.dbToLinear] and [@GlobalScope.linearToDb]. + * **Note:** To convert between decibel and linear energy (like most volume sliders do), use [volumeLinear], or [@GlobalScope.dbToLinear] and [@GlobalScope.linearToDb]. */ public final inline var volumeDb: Float @JvmName("volumeDbProperty") @@ -77,9 +68,7 @@ public open class AudioStreamPlayer : Node() { /** * Volume of sound, as a linear value. * - * **Note:** This member modifies [volumeDb] for convenience. The returned value is equivalent to - * the result of [@GlobalScope.dbToLinear] on [volumeDb]. Setting this member is equivalent to - * setting [volumeDb] to the result of [@GlobalScope.linearToDb] on a value. + * **Note:** This member modifies [volumeDb] for convenience. The returned value is equivalent to the result of [@GlobalScope.dbToLinear] on [volumeDb]. Setting this member is equivalent to setting [volumeDb] to the result of [@GlobalScope.linearToDb] on a value. */ public final inline var volumeLinear: Float @JvmName("volumeLinearProperty") @@ -90,8 +79,7 @@ public open class AudioStreamPlayer : Node() { } /** - * The audio's pitch and tempo, as a multiplier of the [stream]'s sample rate. A value of `2.0` - * doubles the audio's pitch, while a value of `0.5` halves the pitch. + * The audio's pitch and tempo, as a multiplier of the [stream]'s sample rate. A value of `2.0` doubles the audio's pitch, while a value of `0.5` halves the pitch. */ public final inline var pitchScale: Float @JvmName("pitchScaleProperty") @@ -102,8 +90,7 @@ public open class AudioStreamPlayer : Node() { } /** - * If `true`, this node is playing sounds. Setting this property has the same effect as [play] and - * [stop]. + * If `true`, this node is playing sounds. Setting this property has the same effect as [play] and [stop]. */ public final inline var playing: Boolean @JvmName("playingProperty") @@ -127,8 +114,7 @@ public open class AudioStreamPlayer : Node() { /** * If `true`, the sounds are paused. Setting [streamPaused] to `false` resumes all sounds. * - * **Note:** This property is automatically changed when exiting or entering the tree, or this - * node is paused (see [Node.processMode]). + * **Note:** This property is automatically changed when exiting or entering the tree, or this node is paused (see [Node.processMode]). */ public final inline var streamPaused: Boolean @JvmName("streamPausedProperty") @@ -139,8 +125,7 @@ public open class AudioStreamPlayer : Node() { } /** - * The mix target channels, as one of the [MixTarget] constants. Has no effect when two speakers - * or less are detected (see [AudioServer.SpeakerMode]). + * The mix target channels, as one of the [MixTarget] constants. Has no effect when two speakers or less are detected (see [AudioServer.SpeakerMode]). */ public final inline var mixTarget: MixTarget @JvmName("mixTargetProperty") @@ -151,8 +136,7 @@ public open class AudioStreamPlayer : Node() { } /** - * The maximum number of sounds this node can play at the same time. Calling [play] after this - * value is reached will cut off the oldest sounds. + * The maximum number of sounds this node can play at the same time. Calling [play] after this value is reached will cut off the oldest sounds. */ public final inline var maxPolyphony: Int @JvmName("maxPolyphonyProperty") @@ -165,8 +149,7 @@ public open class AudioStreamPlayer : Node() { /** * The target bus name. All sounds from this node will be playing on this bus. * - * **Note:** At runtime, if no bus with the given name exists, all sounds will fall back on - * `"Master"`. See also [AudioServer.getBusName]. + * **Note:** At runtime, if no bus with the given name exists, all sounds will fall back on `"Master"`. See also [AudioServer.getBusName]. */ public final inline var bus: StringName @JvmName("busProperty") @@ -177,8 +160,7 @@ public open class AudioStreamPlayer : Node() { } /** - * The playback type of the stream player. If set other than to the default value, it will force - * that playback type. + * The playback type of the stream player. If set other than to the default value, it will force that playback type. */ public final inline var playbackType: AudioServer.PlaybackType @JvmName("playbackTypeProperty") @@ -188,11 +170,11 @@ public open class AudioStreamPlayer : Node() { setPlaybackType(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(94, scriptIndex) } - public final fun setStream(stream: AudioStream?): Unit { + public final fun setStream(stream: AudioStream?) { TransferContext.writeArguments(OBJECT to stream) TransferContext.callMethod(ptr, MethodBindings.setStreamPtr, NIL) } @@ -203,7 +185,7 @@ public open class AudioStreamPlayer : Node() { return (TransferContext.readReturnValue(OBJECT) as AudioStream?) } - public final fun setVolumeDb(volumeDb: Float): Unit { + public final fun setVolumeDb(volumeDb: Float) { TransferContext.writeArguments(DOUBLE to volumeDb.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setVolumeDbPtr, NIL) } @@ -214,7 +196,7 @@ public open class AudioStreamPlayer : Node() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setVolumeLinear(volumeLinear: Float): Unit { + public final fun setVolumeLinear(volumeLinear: Float) { TransferContext.writeArguments(DOUBLE to volumeLinear.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setVolumeLinearPtr, NIL) } @@ -225,7 +207,7 @@ public open class AudioStreamPlayer : Node() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setPitchScale(pitchScale: Float): Unit { + public final fun setPitchScale(pitchScale: Float) { TransferContext.writeArguments(DOUBLE to pitchScale.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setPitchScalePtr, NIL) } @@ -240,16 +222,15 @@ public open class AudioStreamPlayer : Node() { * Plays a sound from the beginning, or the given [fromPosition] in seconds. */ @JvmOverloads - public final fun play(fromPosition: Float = 0.0f): Unit { + public final fun play(fromPosition: Float = 0.0f) { TransferContext.writeArguments(DOUBLE to fromPosition.toDouble()) TransferContext.callMethod(ptr, MethodBindings.playPtr, NIL) } /** - * Restarts all sounds to be played from the given [toPosition], in seconds. Does nothing if no - * sounds are playing. + * Restarts all sounds to be played from the given [toPosition], in seconds. Does nothing if no sounds are playing. */ - public final fun seek(toPosition: Float): Unit { + public final fun seek(toPosition: Float) { TransferContext.writeArguments(DOUBLE to toPosition.toDouble()) TransferContext.callMethod(ptr, MethodBindings.seekPtr, NIL) } @@ -257,7 +238,7 @@ public open class AudioStreamPlayer : Node() { /** * Stops all sounds from this node. */ - public final fun stop(): Unit { + public final fun stop() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.stopPtr, NIL) } @@ -269,15 +250,11 @@ public open class AudioStreamPlayer : Node() { } /** - * Returns the position in the [AudioStream] of the latest sound, in seconds. Returns `0.0` if no - * sounds are playing. + * Returns the position in the [AudioStream] of the latest sound, in seconds. Returns `0.0` if no sounds are playing. * - * **Note:** The position is not always accurate, as the [AudioServer] does not mix audio every - * processed frame. To get more accurate results, add [AudioServer.getTimeSinceLastMix] to the - * returned position. + * **Note:** The position is not always accurate, as the [AudioServer] does not mix audio every processed frame. To get more accurate results, add [AudioServer.getTimeSinceLastMix] to the returned position. * - * **Note:** This method always returns `0.0` if the [stream] is an [AudioStreamInteractive], - * since it can have multiple clips playing at once. + * **Note:** This method always returns `0.0` if the [stream] is an [AudioStreamInteractive], since it can have multiple clips playing at once. */ public final fun getPlaybackPosition(): Float { TransferContext.writeArguments() @@ -285,7 +262,7 @@ public open class AudioStreamPlayer : Node() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setBus(bus: StringName): Unit { + public final fun setBus(bus: StringName) { TransferContext.writeArguments(STRING_NAME to bus) TransferContext.callMethod(ptr, MethodBindings.setBusPtr, NIL) } @@ -296,7 +273,7 @@ public open class AudioStreamPlayer : Node() { return (TransferContext.readReturnValue(STRING_NAME) as StringName) } - public final fun setAutoplay(enable: Boolean): Unit { + public final fun setAutoplay(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setAutoplayPtr, NIL) } @@ -307,7 +284,7 @@ public open class AudioStreamPlayer : Node() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setMixTarget(mixTarget: MixTarget): Unit { + public final fun setMixTarget(mixTarget: MixTarget) { TransferContext.writeArguments(LONG to mixTarget.id) TransferContext.callMethod(ptr, MethodBindings.setMixTargetPtr, NIL) } @@ -318,12 +295,12 @@ public open class AudioStreamPlayer : Node() { return MixTarget.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setPlaying(enable: Boolean): Unit { + public final fun setPlaying(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setPlayingPtr, NIL) } - public final fun setStreamPaused(pause: Boolean): Unit { + public final fun setStreamPaused(pause: Boolean) { TransferContext.writeArguments(BOOL to pause) TransferContext.callMethod(ptr, MethodBindings.setStreamPausedPtr, NIL) } @@ -334,7 +311,7 @@ public open class AudioStreamPlayer : Node() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setMaxPolyphony(maxPolyphony: Int): Unit { + public final fun setMaxPolyphony(maxPolyphony: Int) { TransferContext.writeArguments(LONG to maxPolyphony.toLong()) TransferContext.callMethod(ptr, MethodBindings.setMaxPolyphonyPtr, NIL) } @@ -346,8 +323,7 @@ public open class AudioStreamPlayer : Node() { } /** - * Returns `true` if any sound is active, even if [streamPaused] is set to `true`. See also - * [playing] and [getStreamPlayback]. + * Returns `true` if any sound is active, even if [streamPaused] is set to `true`. See also [playing] and [getStreamPlayback]. */ public final fun hasStreamPlayback(): Boolean { TransferContext.writeArguments() @@ -356,8 +332,7 @@ public open class AudioStreamPlayer : Node() { } /** - * Returns the latest [AudioStreamPlayback] of this node, usually the most recently created by - * [play]. If no sounds are playing, this method fails and returns an empty playback. + * Returns the latest [AudioStreamPlayback] of this node, usually the most recently created by [play]. If no sounds are playing, this method fails and returns an empty playback. */ public final fun getStreamPlayback(): AudioStreamPlayback? { TransferContext.writeArguments() @@ -365,7 +340,7 @@ public open class AudioStreamPlayer : Node() { return (TransferContext.readReturnValue(OBJECT) as AudioStreamPlayback?) } - public final fun setPlaybackType(playbackType: AudioServer.PlaybackType): Unit { + public final fun setPlaybackType(playbackType: AudioServer.PlaybackType) { TransferContext.writeArguments(LONG to playbackType.id) TransferContext.callMethod(ptr, MethodBindings.setPlaybackTypePtr, NIL) } @@ -376,7 +351,7 @@ public open class AudioStreamPlayer : Node() { return AudioServer.PlaybackType.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setBus(bus: String) = setBus(bus.asCachedStringName()) + public final fun setBus(bus: String): Unit = setBus(bus.asCachedStringName()) public enum class MixTarget( id: Long, @@ -409,87 +384,87 @@ public open class AudioStreamPlayer : Node() { public object MethodBindings { internal val setStreamPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer", "set_stream", 2210767741) + TypeManager.getMethodBindPtr("AudioStreamPlayer", "set_stream", 2_210_767_741) internal val getStreamPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer", "get_stream", 160907539) + TypeManager.getMethodBindPtr("AudioStreamPlayer", "get_stream", 160_907_539) internal val setVolumeDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer", "set_volume_db", 373806689) + TypeManager.getMethodBindPtr("AudioStreamPlayer", "set_volume_db", 373_806_689) internal val getVolumeDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer", "get_volume_db", 1740695150) + TypeManager.getMethodBindPtr("AudioStreamPlayer", "get_volume_db", 1_740_695_150) internal val setVolumeLinearPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer", "set_volume_linear", 373806689) + TypeManager.getMethodBindPtr("AudioStreamPlayer", "set_volume_linear", 373_806_689) internal val getVolumeLinearPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer", "get_volume_linear", 1740695150) + TypeManager.getMethodBindPtr("AudioStreamPlayer", "get_volume_linear", 1_740_695_150) internal val setPitchScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer", "set_pitch_scale", 373806689) + TypeManager.getMethodBindPtr("AudioStreamPlayer", "set_pitch_scale", 373_806_689) internal val getPitchScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer", "get_pitch_scale", 1740695150) + TypeManager.getMethodBindPtr("AudioStreamPlayer", "get_pitch_scale", 1_740_695_150) internal val playPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer", "play", 1958160172) + TypeManager.getMethodBindPtr("AudioStreamPlayer", "play", 1_958_160_172) internal val seekPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer", "seek", 373806689) + TypeManager.getMethodBindPtr("AudioStreamPlayer", "seek", 373_806_689) internal val stopPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer", "stop", 3218959716) + TypeManager.getMethodBindPtr("AudioStreamPlayer", "stop", 3_218_959_716) internal val isPlayingPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer", "is_playing", 36873697) + TypeManager.getMethodBindPtr("AudioStreamPlayer", "is_playing", 36_873_697) internal val getPlaybackPositionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer", "get_playback_position", 191475506) + TypeManager.getMethodBindPtr("AudioStreamPlayer", "get_playback_position", 191_475_506) internal val setBusPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer", "set_bus", 3304788590) + TypeManager.getMethodBindPtr("AudioStreamPlayer", "set_bus", 3_304_788_590) internal val getBusPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer", "get_bus", 2002593661) + TypeManager.getMethodBindPtr("AudioStreamPlayer", "get_bus", 2_002_593_661) internal val setAutoplayPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer", "set_autoplay", 2586408642) + TypeManager.getMethodBindPtr("AudioStreamPlayer", "set_autoplay", 2_586_408_642) internal val isAutoplayEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer", "is_autoplay_enabled", 36873697) + TypeManager.getMethodBindPtr("AudioStreamPlayer", "is_autoplay_enabled", 36_873_697) internal val setMixTargetPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer", "set_mix_target", 2300306138) + TypeManager.getMethodBindPtr("AudioStreamPlayer", "set_mix_target", 2_300_306_138) internal val getMixTargetPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer", "get_mix_target", 172807476) + TypeManager.getMethodBindPtr("AudioStreamPlayer", "get_mix_target", 172_807_476) internal val setPlayingPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer", "set_playing", 2586408642) + TypeManager.getMethodBindPtr("AudioStreamPlayer", "set_playing", 2_586_408_642) internal val setStreamPausedPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer", "set_stream_paused", 2586408642) + TypeManager.getMethodBindPtr("AudioStreamPlayer", "set_stream_paused", 2_586_408_642) internal val getStreamPausedPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer", "get_stream_paused", 36873697) + TypeManager.getMethodBindPtr("AudioStreamPlayer", "get_stream_paused", 36_873_697) internal val setMaxPolyphonyPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer", "set_max_polyphony", 1286410249) + TypeManager.getMethodBindPtr("AudioStreamPlayer", "set_max_polyphony", 1_286_410_249) internal val getMaxPolyphonyPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer", "get_max_polyphony", 3905245786) + TypeManager.getMethodBindPtr("AudioStreamPlayer", "get_max_polyphony", 3_905_245_786) internal val hasStreamPlaybackPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer", "has_stream_playback", 2240911060) + TypeManager.getMethodBindPtr("AudioStreamPlayer", "has_stream_playback", 2_240_911_060) internal val getStreamPlaybackPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer", "get_stream_playback", 210135309) + TypeManager.getMethodBindPtr("AudioStreamPlayer", "get_stream_playback", 210_135_309) internal val setPlaybackTypePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer", "set_playback_type", 725473817) + TypeManager.getMethodBindPtr("AudioStreamPlayer", "set_playback_type", 725_473_817) internal val getPlaybackTypePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer", "get_playback_type", 4011264623) + TypeManager.getMethodBindPtr("AudioStreamPlayer", "get_playback_type", 4_011_264_623) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlayer2D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlayer2D.kt index c4d1bd6a65..5fb0325698 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlayer2D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlayer2D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -33,14 +30,11 @@ import kotlin.jvm.JvmOverloads /** * Plays audio that is attenuated with distance to the listener. * - * By default, audio is heard from the screen center. This can be changed by adding an - * [AudioListener2D] node to the scene and enabling it by calling [AudioListener2D.makeCurrent] on it. + * By default, audio is heard from the screen center. This can be changed by adding an [AudioListener2D] node to the scene and enabling it by calling [AudioListener2D.makeCurrent] on it. * * See also [AudioStreamPlayer] to play a sound non-positionally. * - * **Note:** Hiding an [AudioStreamPlayer2D] node does not disable its audio output. To temporarily - * disable an [AudioStreamPlayer2D]'s audio output, set [volumeDb] to a very low value like `-100` - * (which isn't audible to human hearing). + * **Note:** Hiding an [AudioStreamPlayer2D] node does not disable its audio output. To temporarily disable an [AudioStreamPlayer2D]'s audio output, set [volumeDb] to a very low value like `-100` (which isn't audible to human hearing). */ @GodotBaseType public open class AudioStreamPlayer2D : Node2D() { @@ -74,9 +68,7 @@ public open class AudioStreamPlayer2D : Node2D() { /** * Base volume before attenuation, as a linear value. * - * **Note:** This member modifies [volumeDb] for convenience. The returned value is equivalent to - * the result of [@GlobalScope.dbToLinear] on [volumeDb]. Setting this member is equivalent to - * setting [volumeDb] to the result of [@GlobalScope.linearToDb] on a value. + * **Note:** This member modifies [volumeDb] for convenience. The returned value is equivalent to the result of [@GlobalScope.dbToLinear] on [volumeDb]. Setting this member is equivalent to setting [volumeDb] to the result of [@GlobalScope.linearToDb] on a value. */ public final inline var volumeLinear: Float @JvmName("volumeLinearProperty") @@ -153,8 +145,7 @@ public open class AudioStreamPlayer2D : Node2D() { } /** - * The maximum number of sounds this node can play at the same time. Playing additional sounds - * after this value is reached will cut off the oldest sounds. + * The maximum number of sounds this node can play at the same time. Playing additional sounds after this value is reached will cut off the oldest sounds. */ public final inline var maxPolyphony: Int @JvmName("maxPolyphonyProperty") @@ -165,9 +156,7 @@ public open class AudioStreamPlayer2D : Node2D() { } /** - * Scales the panning strength for this node by multiplying the base - * [ProjectSettings.audio/general/2dPanningStrength] with this factor. Higher values will pan audio - * from left to right more dramatically than lower values. + * Scales the panning strength for this node by multiplying the base [ProjectSettings.audio/general/2dPanningStrength] with this factor. Higher values will pan audio from left to right more dramatically than lower values. */ public final inline var panningStrength: Float @JvmName("panningStrengthProperty") @@ -180,10 +169,7 @@ public open class AudioStreamPlayer2D : Node2D() { /** * Bus on which this audio is playing. * - * **Note:** When setting this property, keep in mind that no validation is performed to see if - * the given name matches an existing bus. This is because audio bus layouts might be loaded after - * this property is set. If this given name can't be resolved at runtime, it will fall back to - * `"Master"`. + * **Note:** When setting this property, keep in mind that no validation is performed to see if the given name matches an existing bus. This is because audio bus layouts might be loaded after this property is set. If this given name can't be resolved at runtime, it will fall back to `"Master"`. */ public final inline var bus: StringName @JvmName("busProperty") @@ -194,10 +180,7 @@ public open class AudioStreamPlayer2D : Node2D() { } /** - * Determines which [Area2D] layers affect the sound for reverb and audio bus effects. Areas can - * be used to redirect [AudioStream]s so that they play in a certain audio bus. An example of how you - * might use this is making a "water" area so that sounds played in the water are redirected through - * an audio bus to make them sound like they are being played underwater. + * Determines which [Area2D] layers affect the sound for reverb and audio bus effects. Areas can be used to redirect [AudioStream]s so that they play in a certain audio bus. An example of how you might use this is making a "water" area so that sounds played in the water are redirected through an audio bus to make them sound like they are being played underwater. */ public final inline var areaMask: Long @JvmName("areaMaskProperty") @@ -208,8 +191,7 @@ public open class AudioStreamPlayer2D : Node2D() { } /** - * The playback type of the stream player. If set other than to the default value, it will force - * that playback type. + * The playback type of the stream player. If set other than to the default value, it will force that playback type. */ public final inline var playbackType: AudioServer.PlaybackType @JvmName("playbackTypeProperty") @@ -219,11 +201,11 @@ public open class AudioStreamPlayer2D : Node2D() { setPlaybackType(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(95, scriptIndex) } - public final fun setStream(stream: AudioStream?): Unit { + public final fun setStream(stream: AudioStream?) { TransferContext.writeArguments(OBJECT to stream) TransferContext.callMethod(ptr, MethodBindings.setStreamPtr, NIL) } @@ -234,7 +216,7 @@ public open class AudioStreamPlayer2D : Node2D() { return (TransferContext.readReturnValue(OBJECT) as AudioStream?) } - public final fun setVolumeDb(volumeDb: Float): Unit { + public final fun setVolumeDb(volumeDb: Float) { TransferContext.writeArguments(DOUBLE to volumeDb.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setVolumeDbPtr, NIL) } @@ -245,7 +227,7 @@ public open class AudioStreamPlayer2D : Node2D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setVolumeLinear(volumeLinear: Float): Unit { + public final fun setVolumeLinear(volumeLinear: Float) { TransferContext.writeArguments(DOUBLE to volumeLinear.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setVolumeLinearPtr, NIL) } @@ -256,7 +238,7 @@ public open class AudioStreamPlayer2D : Node2D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setPitchScale(pitchScale: Float): Unit { + public final fun setPitchScale(pitchScale: Float) { TransferContext.writeArguments(DOUBLE to pitchScale.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setPitchScalePtr, NIL) } @@ -268,11 +250,10 @@ public open class AudioStreamPlayer2D : Node2D() { } /** - * Queues the audio to play on the next physics frame, from the given position [fromPosition], in - * seconds. + * Queues the audio to play on the next physics frame, from the given position [fromPosition], in seconds. */ @JvmOverloads - public final fun play(fromPosition: Float = 0.0f): Unit { + public final fun play(fromPosition: Float = 0.0f) { TransferContext.writeArguments(DOUBLE to fromPosition.toDouble()) TransferContext.callMethod(ptr, MethodBindings.playPtr, NIL) } @@ -280,7 +261,7 @@ public open class AudioStreamPlayer2D : Node2D() { /** * Sets the position from which audio will be played, in seconds. */ - public final fun seek(toPosition: Float): Unit { + public final fun seek(toPosition: Float) { TransferContext.writeArguments(DOUBLE to toPosition.toDouble()) TransferContext.callMethod(ptr, MethodBindings.seekPtr, NIL) } @@ -288,7 +269,7 @@ public open class AudioStreamPlayer2D : Node2D() { /** * Stops the audio. */ - public final fun stop(): Unit { + public final fun stop() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.stopPtr, NIL) } @@ -308,7 +289,7 @@ public open class AudioStreamPlayer2D : Node2D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setBus(bus: StringName): Unit { + public final fun setBus(bus: StringName) { TransferContext.writeArguments(STRING_NAME to bus) TransferContext.callMethod(ptr, MethodBindings.setBusPtr, NIL) } @@ -319,7 +300,7 @@ public open class AudioStreamPlayer2D : Node2D() { return (TransferContext.readReturnValue(STRING_NAME) as StringName) } - public final fun setAutoplay(enable: Boolean): Unit { + public final fun setAutoplay(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setAutoplayPtr, NIL) } @@ -330,12 +311,12 @@ public open class AudioStreamPlayer2D : Node2D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setPlaying(enable: Boolean): Unit { + public final fun setPlaying(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setPlayingPtr, NIL) } - public final fun setMaxDistance(pixels: Float): Unit { + public final fun setMaxDistance(pixels: Float) { TransferContext.writeArguments(DOUBLE to pixels.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setMaxDistancePtr, NIL) } @@ -346,7 +327,7 @@ public open class AudioStreamPlayer2D : Node2D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setAttenuation(curve: Float): Unit { + public final fun setAttenuation(curve: Float) { TransferContext.writeArguments(DOUBLE to curve.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setAttenuationPtr, NIL) } @@ -357,7 +338,7 @@ public open class AudioStreamPlayer2D : Node2D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setAreaMask(mask: Long): Unit { + public final fun setAreaMask(mask: Long) { TransferContext.writeArguments(LONG to mask) TransferContext.callMethod(ptr, MethodBindings.setAreaMaskPtr, NIL) } @@ -368,7 +349,7 @@ public open class AudioStreamPlayer2D : Node2D() { return (TransferContext.readReturnValue(LONG) as Long) } - public final fun setStreamPaused(pause: Boolean): Unit { + public final fun setStreamPaused(pause: Boolean) { TransferContext.writeArguments(BOOL to pause) TransferContext.callMethod(ptr, MethodBindings.setStreamPausedPtr, NIL) } @@ -379,7 +360,7 @@ public open class AudioStreamPlayer2D : Node2D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setMaxPolyphony(maxPolyphony: Int): Unit { + public final fun setMaxPolyphony(maxPolyphony: Int) { TransferContext.writeArguments(LONG to maxPolyphony.toLong()) TransferContext.callMethod(ptr, MethodBindings.setMaxPolyphonyPtr, NIL) } @@ -390,7 +371,7 @@ public open class AudioStreamPlayer2D : Node2D() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setPanningStrength(panningStrength: Float): Unit { + public final fun setPanningStrength(panningStrength: Float) { TransferContext.writeArguments(DOUBLE to panningStrength.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setPanningStrengthPtr, NIL) } @@ -419,7 +400,7 @@ public open class AudioStreamPlayer2D : Node2D() { return (TransferContext.readReturnValue(OBJECT) as AudioStreamPlayback?) } - public final fun setPlaybackType(playbackType: AudioServer.PlaybackType): Unit { + public final fun setPlaybackType(playbackType: AudioServer.PlaybackType) { TransferContext.writeArguments(LONG to playbackType.id) TransferContext.callMethod(ptr, MethodBindings.setPlaybackTypePtr, NIL) } @@ -430,111 +411,111 @@ public open class AudioStreamPlayer2D : Node2D() { return AudioServer.PlaybackType.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setBus(bus: String) = setBus(bus.asCachedStringName()) + public final fun setBus(bus: String): Unit = setBus(bus.asCachedStringName()) public companion object public object MethodBindings { internal val setStreamPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "set_stream", 2210767741) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "set_stream", 2_210_767_741) internal val getStreamPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "get_stream", 160907539) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "get_stream", 160_907_539) internal val setVolumeDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "set_volume_db", 373806689) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "set_volume_db", 373_806_689) internal val getVolumeDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "get_volume_db", 1740695150) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "get_volume_db", 1_740_695_150) internal val setVolumeLinearPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "set_volume_linear", 373806689) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "set_volume_linear", 373_806_689) internal val getVolumeLinearPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "get_volume_linear", 1740695150) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "get_volume_linear", 1_740_695_150) internal val setPitchScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "set_pitch_scale", 373806689) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "set_pitch_scale", 373_806_689) internal val getPitchScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "get_pitch_scale", 1740695150) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "get_pitch_scale", 1_740_695_150) internal val playPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "play", 1958160172) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "play", 1_958_160_172) internal val seekPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "seek", 373806689) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "seek", 373_806_689) internal val stopPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "stop", 3218959716) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "stop", 3_218_959_716) internal val isPlayingPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "is_playing", 36873697) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "is_playing", 36_873_697) internal val getPlaybackPositionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "get_playback_position", 191475506) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "get_playback_position", 191_475_506) internal val setBusPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "set_bus", 3304788590) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "set_bus", 3_304_788_590) internal val getBusPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "get_bus", 2002593661) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "get_bus", 2_002_593_661) internal val setAutoplayPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "set_autoplay", 2586408642) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "set_autoplay", 2_586_408_642) internal val isAutoplayEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "is_autoplay_enabled", 36873697) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "is_autoplay_enabled", 36_873_697) internal val setPlayingPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "set_playing", 2586408642) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "set_playing", 2_586_408_642) internal val setMaxDistancePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "set_max_distance", 373806689) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "set_max_distance", 373_806_689) internal val getMaxDistancePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "get_max_distance", 1740695150) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "get_max_distance", 1_740_695_150) internal val setAttenuationPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "set_attenuation", 373806689) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "set_attenuation", 373_806_689) internal val getAttenuationPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "get_attenuation", 1740695150) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "get_attenuation", 1_740_695_150) internal val setAreaMaskPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "set_area_mask", 1286410249) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "set_area_mask", 1_286_410_249) internal val getAreaMaskPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "get_area_mask", 3905245786) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "get_area_mask", 3_905_245_786) internal val setStreamPausedPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "set_stream_paused", 2586408642) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "set_stream_paused", 2_586_408_642) internal val getStreamPausedPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "get_stream_paused", 36873697) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "get_stream_paused", 36_873_697) internal val setMaxPolyphonyPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "set_max_polyphony", 1286410249) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "set_max_polyphony", 1_286_410_249) internal val getMaxPolyphonyPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "get_max_polyphony", 3905245786) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "get_max_polyphony", 3_905_245_786) internal val setPanningStrengthPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "set_panning_strength", 373806689) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "set_panning_strength", 373_806_689) internal val getPanningStrengthPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "get_panning_strength", 1740695150) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "get_panning_strength", 1_740_695_150) internal val hasStreamPlaybackPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "has_stream_playback", 2240911060) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "has_stream_playback", 2_240_911_060) internal val getStreamPlaybackPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "get_stream_playback", 210135309) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "get_stream_playback", 210_135_309) internal val setPlaybackTypePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "set_playback_type", 725473817) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "set_playback_type", 725_473_817) internal val getPlaybackTypePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "get_playback_type", 4011264623) + TypeManager.getMethodBindPtr("AudioStreamPlayer2D", "get_playback_type", 4_011_264_623) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlayer3D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlayer3D.kt index 4e81346b85..4b71469425 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlayer3D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlayer3D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -31,19 +28,13 @@ import kotlin.jvm.JvmName import kotlin.jvm.JvmOverloads /** - * Plays audio with positional sound effects, based on the relative position of the audio listener. - * Positional effects include distance attenuation, directionality, and the Doppler effect. For greater - * realism, a low-pass filter is applied to distant sounds. This can be disabled by setting - * [attenuationFilterCutoffHz] to `20500`. + * Plays audio with positional sound effects, based on the relative position of the audio listener. Positional effects include distance attenuation, directionality, and the Doppler effect. For greater realism, a low-pass filter is applied to distant sounds. This can be disabled by setting [attenuationFilterCutoffHz] to `20500`. * - * By default, audio is heard from the camera position. This can be changed by adding an - * [AudioListener3D] node to the scene and enabling it by calling [AudioListener3D.makeCurrent] on it. + * By default, audio is heard from the camera position. This can be changed by adding an [AudioListener3D] node to the scene and enabling it by calling [AudioListener3D.makeCurrent] on it. * * See also [AudioStreamPlayer] to play a sound non-positionally. * - * **Note:** Hiding an [AudioStreamPlayer3D] node does not disable its audio output. To temporarily - * disable an [AudioStreamPlayer3D]'s audio output, set [volumeDb] to a very low value like `-100` - * (which isn't audible to human hearing). + * **Note:** Hiding an [AudioStreamPlayer3D] node does not disable its audio output. To temporarily disable an [AudioStreamPlayer3D]'s audio output, set [volumeDb] to a very low value like `-100` (which isn't audible to human hearing). */ @GodotBaseType public open class AudioStreamPlayer3D : Node3D() { @@ -64,8 +55,7 @@ public open class AudioStreamPlayer3D : Node3D() { } /** - * Decides if audio should get quieter with distance linearly, quadratically, logarithmically, or - * not be affected by distance, effectively disabling attenuation. + * Decides if audio should get quieter with distance linearly, quadratically, logarithmically, or not be affected by distance, effectively disabling attenuation. */ public final inline var attenuationModel: AttenuationModel @JvmName("attenuationModelProperty") @@ -89,9 +79,7 @@ public open class AudioStreamPlayer3D : Node3D() { /** * The base sound level before attenuation, as a linear value. * - * **Note:** This member modifies [volumeDb] for convenience. The returned value is equivalent to - * the result of [@GlobalScope.dbToLinear] on [volumeDb]. Setting this member is equivalent to - * setting [volumeDb] to the result of [@GlobalScope.linearToDb] on a value. + * **Note:** This member modifies [volumeDb] for convenience. The returned value is equivalent to the result of [@GlobalScope.dbToLinear] on [volumeDb]. Setting this member is equivalent to setting [volumeDb] to the result of [@GlobalScope.linearToDb] on a value. */ public final inline var volumeLinear: Float @JvmName("volumeLinearProperty") @@ -102,8 +90,7 @@ public open class AudioStreamPlayer3D : Node3D() { } /** - * The factor for the attenuation effect. Higher values make the sound audible over a larger - * distance. + * The factor for the attenuation effect. Higher values make the sound audible over a larger distance. */ public final inline var unitSize: Float @JvmName("unitSizeProperty") @@ -169,11 +156,7 @@ public open class AudioStreamPlayer3D : Node3D() { } /** - * The distance past which the sound can no longer be heard at all. Only has an effect if set to a - * value greater than `0.0`. [maxDistance] works in tandem with [unitSize]. However, unlike - * [unitSize] whose behavior depends on the [attenuationModel], [maxDistance] always works in a - * linear fashion. This can be used to prevent the [AudioStreamPlayer3D] from requiring audio mixing - * when the listener is far away, which saves CPU resources. + * The distance past which the sound can no longer be heard at all. Only has an effect if set to a value greater than `0.0`. [maxDistance] works in tandem with [unitSize]. However, unlike [unitSize] whose behavior depends on the [attenuationModel], [maxDistance] always works in a linear fashion. This can be used to prevent the [AudioStreamPlayer3D] from requiring audio mixing when the listener is far away, which saves CPU resources. */ public final inline var maxDistance: Float @JvmName("maxDistanceProperty") @@ -184,8 +167,7 @@ public open class AudioStreamPlayer3D : Node3D() { } /** - * The maximum number of sounds this node can play at the same time. Playing additional sounds - * after this value is reached will cut off the oldest sounds. + * The maximum number of sounds this node can play at the same time. Playing additional sounds after this value is reached will cut off the oldest sounds. */ public final inline var maxPolyphony: Int @JvmName("maxPolyphonyProperty") @@ -196,9 +178,7 @@ public open class AudioStreamPlayer3D : Node3D() { } /** - * Scales the panning strength for this node by multiplying the base - * [ProjectSettings.audio/general/3dPanningStrength] with this factor. Higher values will pan audio - * from left to right more dramatically than lower values. + * Scales the panning strength for this node by multiplying the base [ProjectSettings.audio/general/3dPanningStrength] with this factor. Higher values will pan audio from left to right more dramatically than lower values. */ public final inline var panningStrength: Float @JvmName("panningStrengthProperty") @@ -211,10 +191,7 @@ public open class AudioStreamPlayer3D : Node3D() { /** * The bus on which this audio is playing. * - * **Note:** When setting this property, keep in mind that no validation is performed to see if - * the given name matches an existing bus. This is because audio bus layouts might be loaded after - * this property is set. If this given name can't be resolved at runtime, it will fall back to - * `"Master"`. + * **Note:** When setting this property, keep in mind that no validation is performed to see if the given name matches an existing bus. This is because audio bus layouts might be loaded after this property is set. If this given name can't be resolved at runtime, it will fall back to `"Master"`. */ public final inline var bus: StringName @JvmName("busProperty") @@ -225,10 +202,7 @@ public open class AudioStreamPlayer3D : Node3D() { } /** - * Determines which [Area3D] layers affect the sound for reverb and audio bus effects. Areas can - * be used to redirect [AudioStream]s so that they play in a certain audio bus. An example of how you - * might use this is making a "water" area so that sounds played in the water are redirected through - * an audio bus to make them sound like they are being played underwater. + * Determines which [Area3D] layers affect the sound for reverb and audio bus effects. Areas can be used to redirect [AudioStream]s so that they play in a certain audio bus. An example of how you might use this is making a "water" area so that sounds played in the water are redirected through an audio bus to make them sound like they are being played underwater. */ public final inline var areaMask: Long @JvmName("areaMaskProperty") @@ -239,8 +213,7 @@ public open class AudioStreamPlayer3D : Node3D() { } /** - * The playback type of the stream player. If set other than to the default value, it will force - * that playback type. + * The playback type of the stream player. If set other than to the default value, it will force that playback type. */ public final inline var playbackType: AudioServer.PlaybackType @JvmName("playbackTypeProperty") @@ -273,8 +246,7 @@ public open class AudioStreamPlayer3D : Node3D() { } /** - * Attenuation factor used if listener is outside of [emissionAngleDegrees] and - * [emissionAngleEnabled] is set, in decibels. + * Attenuation factor used if listener is outside of [emissionAngleDegrees] and [emissionAngleEnabled] is set, in decibels. */ public final inline var emissionAngleFilterAttenuationDb: Float @JvmName("emissionAngleFilterAttenuationDbProperty") @@ -285,9 +257,7 @@ public open class AudioStreamPlayer3D : Node3D() { } /** - * The cutoff frequency of the attenuation low-pass filter, in Hz. A sound above this frequency is - * attenuated more than a sound below this frequency. To disable this effect, set this to `20500` as - * this frequency is above the human hearing limit. + * The cutoff frequency of the attenuation low-pass filter, in Hz. A sound above this frequency is attenuated more than a sound below this frequency. To disable this effect, set this to `20500` as this frequency is above the human hearing limit. */ public final inline var attenuationFilterCutoffHz: Float @JvmName("attenuationFilterCutoffHzProperty") @@ -319,11 +289,11 @@ public open class AudioStreamPlayer3D : Node3D() { setDopplerTracking(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(96, scriptIndex) } - public final fun setStream(stream: AudioStream?): Unit { + public final fun setStream(stream: AudioStream?) { TransferContext.writeArguments(OBJECT to stream) TransferContext.callMethod(ptr, MethodBindings.setStreamPtr, NIL) } @@ -334,7 +304,7 @@ public open class AudioStreamPlayer3D : Node3D() { return (TransferContext.readReturnValue(OBJECT) as AudioStream?) } - public final fun setVolumeDb(volumeDb: Float): Unit { + public final fun setVolumeDb(volumeDb: Float) { TransferContext.writeArguments(DOUBLE to volumeDb.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setVolumeDbPtr, NIL) } @@ -345,7 +315,7 @@ public open class AudioStreamPlayer3D : Node3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setVolumeLinear(volumeLinear: Float): Unit { + public final fun setVolumeLinear(volumeLinear: Float) { TransferContext.writeArguments(DOUBLE to volumeLinear.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setVolumeLinearPtr, NIL) } @@ -356,7 +326,7 @@ public open class AudioStreamPlayer3D : Node3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setUnitSize(unitSize: Float): Unit { + public final fun setUnitSize(unitSize: Float) { TransferContext.writeArguments(DOUBLE to unitSize.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setUnitSizePtr, NIL) } @@ -367,7 +337,7 @@ public open class AudioStreamPlayer3D : Node3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setMaxDb(maxDb: Float): Unit { + public final fun setMaxDb(maxDb: Float) { TransferContext.writeArguments(DOUBLE to maxDb.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setMaxDbPtr, NIL) } @@ -378,7 +348,7 @@ public open class AudioStreamPlayer3D : Node3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setPitchScale(pitchScale: Float): Unit { + public final fun setPitchScale(pitchScale: Float) { TransferContext.writeArguments(DOUBLE to pitchScale.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setPitchScalePtr, NIL) } @@ -390,11 +360,10 @@ public open class AudioStreamPlayer3D : Node3D() { } /** - * Queues the audio to play on the next physics frame, from the given position [fromPosition], in - * seconds. + * Queues the audio to play on the next physics frame, from the given position [fromPosition], in seconds. */ @JvmOverloads - public final fun play(fromPosition: Float = 0.0f): Unit { + public final fun play(fromPosition: Float = 0.0f) { TransferContext.writeArguments(DOUBLE to fromPosition.toDouble()) TransferContext.callMethod(ptr, MethodBindings.playPtr, NIL) } @@ -402,7 +371,7 @@ public open class AudioStreamPlayer3D : Node3D() { /** * Sets the position from which audio will be played, in seconds. */ - public final fun seek(toPosition: Float): Unit { + public final fun seek(toPosition: Float) { TransferContext.writeArguments(DOUBLE to toPosition.toDouble()) TransferContext.callMethod(ptr, MethodBindings.seekPtr, NIL) } @@ -410,7 +379,7 @@ public open class AudioStreamPlayer3D : Node3D() { /** * Stops the audio. */ - public final fun stop(): Unit { + public final fun stop() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.stopPtr, NIL) } @@ -430,7 +399,7 @@ public open class AudioStreamPlayer3D : Node3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setBus(bus: StringName): Unit { + public final fun setBus(bus: StringName) { TransferContext.writeArguments(STRING_NAME to bus) TransferContext.callMethod(ptr, MethodBindings.setBusPtr, NIL) } @@ -441,7 +410,7 @@ public open class AudioStreamPlayer3D : Node3D() { return (TransferContext.readReturnValue(STRING_NAME) as StringName) } - public final fun setAutoplay(enable: Boolean): Unit { + public final fun setAutoplay(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setAutoplayPtr, NIL) } @@ -452,12 +421,12 @@ public open class AudioStreamPlayer3D : Node3D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setPlaying(enable: Boolean): Unit { + public final fun setPlaying(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setPlayingPtr, NIL) } - public final fun setMaxDistance(meters: Float): Unit { + public final fun setMaxDistance(meters: Float) { TransferContext.writeArguments(DOUBLE to meters.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setMaxDistancePtr, NIL) } @@ -468,7 +437,7 @@ public open class AudioStreamPlayer3D : Node3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setAreaMask(mask: Long): Unit { + public final fun setAreaMask(mask: Long) { TransferContext.writeArguments(LONG to mask) TransferContext.callMethod(ptr, MethodBindings.setAreaMaskPtr, NIL) } @@ -479,7 +448,7 @@ public open class AudioStreamPlayer3D : Node3D() { return (TransferContext.readReturnValue(LONG) as Long) } - public final fun setEmissionAngle(degrees: Float): Unit { + public final fun setEmissionAngle(degrees: Float) { TransferContext.writeArguments(DOUBLE to degrees.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setEmissionAnglePtr, NIL) } @@ -490,7 +459,7 @@ public open class AudioStreamPlayer3D : Node3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setEmissionAngleEnabled(enabled: Boolean): Unit { + public final fun setEmissionAngleEnabled(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setEmissionAngleEnabledPtr, NIL) } @@ -501,7 +470,7 @@ public open class AudioStreamPlayer3D : Node3D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setEmissionAngleFilterAttenuationDb(db: Float): Unit { + public final fun setEmissionAngleFilterAttenuationDb(db: Float) { TransferContext.writeArguments(DOUBLE to db.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setEmissionAngleFilterAttenuationDbPtr, NIL) } @@ -512,7 +481,7 @@ public open class AudioStreamPlayer3D : Node3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setAttenuationFilterCutoffHz(degrees: Float): Unit { + public final fun setAttenuationFilterCutoffHz(degrees: Float) { TransferContext.writeArguments(DOUBLE to degrees.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setAttenuationFilterCutoffHzPtr, NIL) } @@ -523,7 +492,7 @@ public open class AudioStreamPlayer3D : Node3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setAttenuationFilterDb(db: Float): Unit { + public final fun setAttenuationFilterDb(db: Float) { TransferContext.writeArguments(DOUBLE to db.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setAttenuationFilterDbPtr, NIL) } @@ -534,7 +503,7 @@ public open class AudioStreamPlayer3D : Node3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setAttenuationModel(model: AttenuationModel): Unit { + public final fun setAttenuationModel(model: AttenuationModel) { TransferContext.writeArguments(LONG to model.id) TransferContext.callMethod(ptr, MethodBindings.setAttenuationModelPtr, NIL) } @@ -545,7 +514,7 @@ public open class AudioStreamPlayer3D : Node3D() { return AttenuationModel.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setDopplerTracking(mode: DopplerTracking): Unit { + public final fun setDopplerTracking(mode: DopplerTracking) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setDopplerTrackingPtr, NIL) } @@ -556,7 +525,7 @@ public open class AudioStreamPlayer3D : Node3D() { return DopplerTracking.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setStreamPaused(pause: Boolean): Unit { + public final fun setStreamPaused(pause: Boolean) { TransferContext.writeArguments(BOOL to pause) TransferContext.callMethod(ptr, MethodBindings.setStreamPausedPtr, NIL) } @@ -567,7 +536,7 @@ public open class AudioStreamPlayer3D : Node3D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setMaxPolyphony(maxPolyphony: Int): Unit { + public final fun setMaxPolyphony(maxPolyphony: Int) { TransferContext.writeArguments(LONG to maxPolyphony.toLong()) TransferContext.callMethod(ptr, MethodBindings.setMaxPolyphonyPtr, NIL) } @@ -578,7 +547,7 @@ public open class AudioStreamPlayer3D : Node3D() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setPanningStrength(panningStrength: Float): Unit { + public final fun setPanningStrength(panningStrength: Float) { TransferContext.writeArguments(DOUBLE to panningStrength.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setPanningStrengthPtr, NIL) } @@ -607,7 +576,7 @@ public open class AudioStreamPlayer3D : Node3D() { return (TransferContext.readReturnValue(OBJECT) as AudioStreamPlayback?) } - public final fun setPlaybackType(playbackType: AudioServer.PlaybackType): Unit { + public final fun setPlaybackType(playbackType: AudioServer.PlaybackType) { TransferContext.writeArguments(LONG to playbackType.id) TransferContext.callMethod(ptr, MethodBindings.setPlaybackTypePtr, NIL) } @@ -618,7 +587,7 @@ public open class AudioStreamPlayer3D : Node3D() { return AudioServer.PlaybackType.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setBus(bus: String) = setBus(bus.asCachedStringName()) + public final fun setBus(bus: String): Unit = setBus(bus.asCachedStringName()) public enum class AttenuationModel( id: Long, @@ -636,9 +605,7 @@ public open class AudioStreamPlayer3D : Node3D() { */ LOGARITHMIC(2), /** - * No attenuation of loudness according to distance. The sound will still be heard positionally, - * unlike an [AudioStreamPlayer]. [ATTENUATION_DISABLED] can be combined with a [maxDistance] value - * greater than `0.0` to achieve linear attenuation clamped to a sphere of a defined size. + * No attenuation of loudness according to distance. The sound will still be heard positionally, unlike an [AudioStreamPlayer]. [ATTENUATION_DISABLED] can be combined with a [maxDistance] value greater than `0.0` to achieve linear attenuation clamped to a sphere of a defined size. */ DISABLED(3), ; @@ -665,8 +632,7 @@ public open class AudioStreamPlayer3D : Node3D() { */ IDLE_STEP(1), /** - * Executes doppler tracking during physics frames (see - * [Node.NOTIFICATION_INTERNAL_PHYSICS_PROCESS]). + * Executes doppler tracking during physics frames (see [Node.NOTIFICATION_INTERNAL_PHYSICS_PROCESS]). */ PHYSICS_STEP(2), ; @@ -685,153 +651,153 @@ public open class AudioStreamPlayer3D : Node3D() { public object MethodBindings { internal val setStreamPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_stream", 2210767741) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_stream", 2_210_767_741) internal val getStreamPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_stream", 160907539) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_stream", 160_907_539) internal val setVolumeDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_volume_db", 373806689) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_volume_db", 373_806_689) internal val getVolumeDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_volume_db", 1740695150) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_volume_db", 1_740_695_150) internal val setVolumeLinearPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_volume_linear", 373806689) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_volume_linear", 373_806_689) internal val getVolumeLinearPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_volume_linear", 1740695150) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_volume_linear", 1_740_695_150) internal val setUnitSizePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_unit_size", 373806689) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_unit_size", 373_806_689) internal val getUnitSizePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_unit_size", 1740695150) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_unit_size", 1_740_695_150) internal val setMaxDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_max_db", 373806689) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_max_db", 373_806_689) internal val getMaxDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_max_db", 1740695150) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_max_db", 1_740_695_150) internal val setPitchScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_pitch_scale", 373806689) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_pitch_scale", 373_806_689) internal val getPitchScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_pitch_scale", 1740695150) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_pitch_scale", 1_740_695_150) internal val playPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "play", 1958160172) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "play", 1_958_160_172) internal val seekPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "seek", 373806689) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "seek", 373_806_689) internal val stopPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "stop", 3218959716) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "stop", 3_218_959_716) internal val isPlayingPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "is_playing", 36873697) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "is_playing", 36_873_697) internal val getPlaybackPositionPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_playback_position", 191475506) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_playback_position", 191_475_506) internal val setBusPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_bus", 3304788590) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_bus", 3_304_788_590) internal val getBusPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_bus", 2002593661) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_bus", 2_002_593_661) internal val setAutoplayPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_autoplay", 2586408642) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_autoplay", 2_586_408_642) internal val isAutoplayEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "is_autoplay_enabled", 36873697) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "is_autoplay_enabled", 36_873_697) internal val setPlayingPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_playing", 2586408642) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_playing", 2_586_408_642) internal val setMaxDistancePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_max_distance", 373806689) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_max_distance", 373_806_689) internal val getMaxDistancePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_max_distance", 1740695150) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_max_distance", 1_740_695_150) internal val setAreaMaskPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_area_mask", 1286410249) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_area_mask", 1_286_410_249) internal val getAreaMaskPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_area_mask", 3905245786) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_area_mask", 3_905_245_786) internal val setEmissionAnglePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_emission_angle", 373806689) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_emission_angle", 373_806_689) internal val getEmissionAnglePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_emission_angle", 1740695150) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_emission_angle", 1_740_695_150) internal val setEmissionAngleEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_emission_angle_enabled", 2586408642) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_emission_angle_enabled", 2_586_408_642) internal val isEmissionAngleEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "is_emission_angle_enabled", 36873697) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "is_emission_angle_enabled", 36_873_697) internal val setEmissionAngleFilterAttenuationDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_emission_angle_filter_attenuation_db", 373806689) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_emission_angle_filter_attenuation_db", 373_806_689) internal val getEmissionAngleFilterAttenuationDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_emission_angle_filter_attenuation_db", 1740695150) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_emission_angle_filter_attenuation_db", 1_740_695_150) internal val setAttenuationFilterCutoffHzPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_attenuation_filter_cutoff_hz", 373806689) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_attenuation_filter_cutoff_hz", 373_806_689) internal val getAttenuationFilterCutoffHzPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_attenuation_filter_cutoff_hz", 1740695150) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_attenuation_filter_cutoff_hz", 1_740_695_150) internal val setAttenuationFilterDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_attenuation_filter_db", 373806689) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_attenuation_filter_db", 373_806_689) internal val getAttenuationFilterDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_attenuation_filter_db", 1740695150) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_attenuation_filter_db", 1_740_695_150) internal val setAttenuationModelPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_attenuation_model", 2988086229) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_attenuation_model", 2_988_086_229) internal val getAttenuationModelPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_attenuation_model", 3035106060) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_attenuation_model", 3_035_106_060) internal val setDopplerTrackingPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_doppler_tracking", 3968161450) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_doppler_tracking", 3_968_161_450) internal val getDopplerTrackingPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_doppler_tracking", 1702418664) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_doppler_tracking", 1_702_418_664) internal val setStreamPausedPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_stream_paused", 2586408642) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_stream_paused", 2_586_408_642) internal val getStreamPausedPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_stream_paused", 36873697) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_stream_paused", 36_873_697) internal val setMaxPolyphonyPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_max_polyphony", 1286410249) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_max_polyphony", 1_286_410_249) internal val getMaxPolyphonyPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_max_polyphony", 3905245786) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_max_polyphony", 3_905_245_786) internal val setPanningStrengthPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_panning_strength", 373806689) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_panning_strength", 373_806_689) internal val getPanningStrengthPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_panning_strength", 1740695150) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_panning_strength", 1_740_695_150) internal val hasStreamPlaybackPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "has_stream_playback", 2240911060) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "has_stream_playback", 2_240_911_060) internal val getStreamPlaybackPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_stream_playback", 210135309) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_stream_playback", 210_135_309) internal val setPlaybackTypePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_playback_type", 725473817) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "set_playback_type", 725_473_817) internal val getPlaybackTypePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_playback_type", 4011264623) + TypeManager.getMethodBindPtr("AudioStreamPlayer3D", "get_playback_type", 4_011_264_623) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlaylist.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlaylist.kt index 803ec1a865..c9b4832a6b 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlaylist.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPlaylist.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -21,7 +18,6 @@ import kotlin.Float import kotlin.Int import kotlin.Long import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName @GodotBaseType @@ -38,8 +34,7 @@ public open class AudioStreamPlaylist : AudioStream() { } /** - * If `true`, the playlist will loop, otherwise the playlist will end when the last stream is - * finished. + * If `true`, the playlist will loop, otherwise the playlist will end when the last stream is finished. */ public final inline var loop: Boolean @JvmName("loopProperty") @@ -50,8 +45,7 @@ public open class AudioStreamPlaylist : AudioStream() { } /** - * Fade time used when a stream ends, when going to the next one. Streams are expected to have an - * extra bit of audio after the end to help with fading. + * Fade time used when a stream ends, when going to the next one. Streams are expected to have an extra bit of audio after the end to help with fading. */ public final inline var fadeTime: Float @JvmName("fadeTimeProperty") @@ -584,11 +578,11 @@ public open class AudioStreamPlaylist : AudioStream() { setListStream(63, value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(97, scriptIndex) } - public final fun setStreamCount(streamCount: Int): Unit { + public final fun setStreamCount(streamCount: Int) { TransferContext.writeArguments(LONG to streamCount.toLong()) TransferContext.callMethod(ptr, MethodBindings.setStreamCountPtr, NIL) } @@ -611,7 +605,7 @@ public open class AudioStreamPlaylist : AudioStream() { /** * Sets the stream at playback position index. */ - public final fun setListStream(streamIndex: Int, audioStream: AudioStream?): Unit { + public final fun setListStream(streamIndex: Int, audioStream: AudioStream?) { TransferContext.writeArguments(LONG to streamIndex.toLong(), OBJECT to audioStream) TransferContext.callMethod(ptr, MethodBindings.setListStreamPtr, NIL) } @@ -625,7 +619,7 @@ public open class AudioStreamPlaylist : AudioStream() { return (TransferContext.readReturnValue(OBJECT) as AudioStream?) } - public final fun setShuffle(shuffle: Boolean): Unit { + public final fun setShuffle(shuffle: Boolean) { TransferContext.writeArguments(BOOL to shuffle) TransferContext.callMethod(ptr, MethodBindings.setShufflePtr, NIL) } @@ -636,7 +630,7 @@ public open class AudioStreamPlaylist : AudioStream() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setFadeTime(dec: Float): Unit { + public final fun setFadeTime(dec: Float) { TransferContext.writeArguments(DOUBLE to dec.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setFadeTimePtr, NIL) } @@ -647,7 +641,7 @@ public open class AudioStreamPlaylist : AudioStream() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setLoop(loop: Boolean): Unit { + public final fun setLoop(loop: Boolean) { TransferContext.writeArguments(BOOL to loop) TransferContext.callMethod(ptr, MethodBindings.setLoopPtr, NIL) } @@ -667,36 +661,36 @@ public open class AudioStreamPlaylist : AudioStream() { public object MethodBindings { internal val setStreamCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlaylist", "set_stream_count", 1286410249) + TypeManager.getMethodBindPtr("AudioStreamPlaylist", "set_stream_count", 1_286_410_249) internal val getStreamCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlaylist", "get_stream_count", 3905245786) + TypeManager.getMethodBindPtr("AudioStreamPlaylist", "get_stream_count", 3_905_245_786) internal val getBpmPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlaylist", "get_bpm", 1740695150) + TypeManager.getMethodBindPtr("AudioStreamPlaylist", "get_bpm", 1_740_695_150) internal val setListStreamPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlaylist", "set_list_stream", 111075094) + TypeManager.getMethodBindPtr("AudioStreamPlaylist", "set_list_stream", 111_075_094) internal val getListStreamPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlaylist", "get_list_stream", 2739380747) + TypeManager.getMethodBindPtr("AudioStreamPlaylist", "get_list_stream", 2_739_380_747) internal val setShufflePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlaylist", "set_shuffle", 2586408642) + TypeManager.getMethodBindPtr("AudioStreamPlaylist", "set_shuffle", 2_586_408_642) internal val getShufflePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlaylist", "get_shuffle", 36873697) + TypeManager.getMethodBindPtr("AudioStreamPlaylist", "get_shuffle", 36_873_697) internal val setFadeTimePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlaylist", "set_fade_time", 373806689) + TypeManager.getMethodBindPtr("AudioStreamPlaylist", "set_fade_time", 373_806_689) internal val getFadeTimePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlaylist", "get_fade_time", 1740695150) + TypeManager.getMethodBindPtr("AudioStreamPlaylist", "get_fade_time", 1_740_695_150) internal val setLoopPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlaylist", "set_loop", 2586408642) + TypeManager.getMethodBindPtr("AudioStreamPlaylist", "set_loop", 2_586_408_642) internal val hasLoopPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPlaylist", "has_loop", 36873697) + TypeManager.getMethodBindPtr("AudioStreamPlaylist", "has_loop", 36_873_697) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPolyphonic.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPolyphonic.kt index 878dc5a4ef..55fe9a9bf8 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPolyphonic.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamPolyphonic.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -15,18 +12,12 @@ import godot.core.VariantParser.NIL import kotlin.Int import kotlin.Long import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * AudioStream that lets the user play custom streams at any time from code, simultaneously using a - * single player. + * AudioStream that lets the user play custom streams at any time from code, simultaneously using a single player. * - * Playback control is done via the [AudioStreamPlaybackPolyphonic] instance set inside the player, - * which can be obtained via [AudioStreamPlayer.getStreamPlayback], - * [AudioStreamPlayer2D.getStreamPlayback] or [AudioStreamPlayer3D.getStreamPlayback] methods. - * Obtaining the playback instance is only valid after the `stream` property is set as an - * [AudioStreamPolyphonic] in those players. + * Playback control is done via the [AudioStreamPlaybackPolyphonic] instance set inside the player, which can be obtained via [AudioStreamPlayer.getStreamPlayback], [AudioStreamPlayer2D.getStreamPlayback] or [AudioStreamPlayer3D.getStreamPlayback] methods. Obtaining the playback instance is only valid after the `stream` property is set as an [AudioStreamPolyphonic] in those players. */ @GodotBaseType public open class AudioStreamPolyphonic : AudioStream() { @@ -41,11 +32,11 @@ public open class AudioStreamPolyphonic : AudioStream() { setPolyphony(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(98, scriptIndex) } - public final fun setPolyphony(voices: Int): Unit { + public final fun setPolyphony(voices: Int) { TransferContext.writeArguments(LONG to voices.toLong()) TransferContext.callMethod(ptr, MethodBindings.setPolyphonyPtr, NIL) } @@ -60,9 +51,9 @@ public open class AudioStreamPolyphonic : AudioStream() { public object MethodBindings { internal val setPolyphonyPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPolyphonic", "set_polyphony", 1286410249) + TypeManager.getMethodBindPtr("AudioStreamPolyphonic", "set_polyphony", 1_286_410_249) internal val getPolyphonyPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamPolyphonic", "get_polyphony", 3905245786) + TypeManager.getMethodBindPtr("AudioStreamPolyphonic", "get_polyphony", 3_905_245_786) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamRandomizer.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamRandomizer.kt index c59ce05df3..496fcfa430 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamRandomizer.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamRandomizer.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -19,13 +16,11 @@ import kotlin.Float import kotlin.Int import kotlin.Long import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName import kotlin.jvm.JvmOverloads /** - * Picks a random AudioStream from the pool, depending on the playback mode, and applies random - * pitch shifting and volume shifting during playback. + * Picks a random AudioStream from the pool, depending on the playback mode, and applies random pitch shifting and volume shifting during playback. */ @GodotBaseType public open class AudioStreamRandomizer : AudioStream() { @@ -73,20 +68,19 @@ public open class AudioStreamRandomizer : AudioStream() { setStreamsCount(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(99, scriptIndex) } /** - * Insert a stream at the specified index. If the index is less than zero, the insertion occurs at - * the end of the underlying pool. + * Insert a stream at the specified index. If the index is less than zero, the insertion occurs at the end of the underlying pool. */ @JvmOverloads public final fun addStream( index: Int, stream: AudioStream?, weight: Float = 1.0f, - ): Unit { + ) { TransferContext.writeArguments(LONG to index.toLong(), OBJECT to stream, DOUBLE to weight.toDouble()) TransferContext.callMethod(ptr, MethodBindings.addStreamPtr, NIL) } @@ -94,7 +88,7 @@ public open class AudioStreamRandomizer : AudioStream() { /** * Move a stream from one index to another. */ - public final fun moveStream(indexFrom: Int, indexTo: Int): Unit { + public final fun moveStream(indexFrom: Int, indexTo: Int) { TransferContext.writeArguments(LONG to indexFrom.toLong(), LONG to indexTo.toLong()) TransferContext.callMethod(ptr, MethodBindings.moveStreamPtr, NIL) } @@ -102,7 +96,7 @@ public open class AudioStreamRandomizer : AudioStream() { /** * Remove the stream at the specified index. */ - public final fun removeStream(index: Int): Unit { + public final fun removeStream(index: Int) { TransferContext.writeArguments(LONG to index.toLong()) TransferContext.callMethod(ptr, MethodBindings.removeStreamPtr, NIL) } @@ -110,7 +104,7 @@ public open class AudioStreamRandomizer : AudioStream() { /** * Set the AudioStream at the specified index. */ - public final fun setStream(index: Int, stream: AudioStream?): Unit { + public final fun setStream(index: Int, stream: AudioStream?) { TransferContext.writeArguments(LONG to index.toLong(), OBJECT to stream) TransferContext.callMethod(ptr, MethodBindings.setStreamPtr, NIL) } @@ -125,10 +119,9 @@ public open class AudioStreamRandomizer : AudioStream() { } /** - * Set the probability weight of the stream at the specified index. The higher this value, the - * more likely that the randomizer will choose this stream during random playback modes. + * Set the probability weight of the stream at the specified index. The higher this value, the more likely that the randomizer will choose this stream during random playback modes. */ - public final fun setStreamProbabilityWeight(index: Int, weight: Float): Unit { + public final fun setStreamProbabilityWeight(index: Int, weight: Float) { TransferContext.writeArguments(LONG to index.toLong(), DOUBLE to weight.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setStreamProbabilityWeightPtr, NIL) } @@ -142,7 +135,7 @@ public open class AudioStreamRandomizer : AudioStream() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setStreamsCount(count: Int): Unit { + public final fun setStreamsCount(count: Int) { TransferContext.writeArguments(LONG to count.toLong()) TransferContext.callMethod(ptr, MethodBindings.setStreamsCountPtr, NIL) } @@ -153,7 +146,7 @@ public open class AudioStreamRandomizer : AudioStream() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setRandomPitch(scale: Float): Unit { + public final fun setRandomPitch(scale: Float) { TransferContext.writeArguments(DOUBLE to scale.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setRandomPitchPtr, NIL) } @@ -164,7 +157,7 @@ public open class AudioStreamRandomizer : AudioStream() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setRandomVolumeOffsetDb(dbOffset: Float): Unit { + public final fun setRandomVolumeOffsetDb(dbOffset: Float) { TransferContext.writeArguments(DOUBLE to dbOffset.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setRandomVolumeOffsetDbPtr, NIL) } @@ -175,7 +168,7 @@ public open class AudioStreamRandomizer : AudioStream() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setPlaybackMode(mode: PlaybackMode): Unit { + public final fun setPlaybackMode(mode: PlaybackMode) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setPlaybackModePtr, NIL) } @@ -190,19 +183,15 @@ public open class AudioStreamRandomizer : AudioStream() { id: Long, ) { /** - * Pick a stream at random according to the probability weights chosen for each stream, but - * avoid playing the same stream twice in a row whenever possible. If only 1 sound is present in - * the pool, the same sound will always play, effectively allowing repeats to occur. + * Pick a stream at random according to the probability weights chosen for each stream, but avoid playing the same stream twice in a row whenever possible. If only 1 sound is present in the pool, the same sound will always play, effectively allowing repeats to occur. */ RANDOM_NO_REPEATS(0), /** - * Pick a stream at random according to the probability weights chosen for each stream. If only - * 1 sound is present in the pool, the same sound will always play. + * Pick a stream at random according to the probability weights chosen for each stream. If only 1 sound is present in the pool, the same sound will always play. */ RANDOM(1), /** - * Play streams in the order they appear in the stream pool. If only 1 sound is present in the - * pool, the same sound will always play. + * Play streams in the order they appear in the stream pool. If only 1 sound is present in the pool, the same sound will always play. */ SEQUENTIAL(2), ; @@ -221,48 +210,48 @@ public open class AudioStreamRandomizer : AudioStream() { public object MethodBindings { internal val addStreamPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamRandomizer", "add_stream", 1892018854) + TypeManager.getMethodBindPtr("AudioStreamRandomizer", "add_stream", 1_892_018_854) internal val moveStreamPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamRandomizer", "move_stream", 3937882851) + TypeManager.getMethodBindPtr("AudioStreamRandomizer", "move_stream", 3_937_882_851) internal val removeStreamPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamRandomizer", "remove_stream", 1286410249) + TypeManager.getMethodBindPtr("AudioStreamRandomizer", "remove_stream", 1_286_410_249) internal val setStreamPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamRandomizer", "set_stream", 111075094) + TypeManager.getMethodBindPtr("AudioStreamRandomizer", "set_stream", 111_075_094) internal val getStreamPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamRandomizer", "get_stream", 2739380747) + TypeManager.getMethodBindPtr("AudioStreamRandomizer", "get_stream", 2_739_380_747) internal val setStreamProbabilityWeightPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamRandomizer", "set_stream_probability_weight", 1602489585) + TypeManager.getMethodBindPtr("AudioStreamRandomizer", "set_stream_probability_weight", 1_602_489_585) internal val getStreamProbabilityWeightPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamRandomizer", "get_stream_probability_weight", 2339986948) + TypeManager.getMethodBindPtr("AudioStreamRandomizer", "get_stream_probability_weight", 2_339_986_948) internal val setStreamsCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamRandomizer", "set_streams_count", 1286410249) + TypeManager.getMethodBindPtr("AudioStreamRandomizer", "set_streams_count", 1_286_410_249) internal val getStreamsCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamRandomizer", "get_streams_count", 3905245786) + TypeManager.getMethodBindPtr("AudioStreamRandomizer", "get_streams_count", 3_905_245_786) internal val setRandomPitchPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamRandomizer", "set_random_pitch", 373806689) + TypeManager.getMethodBindPtr("AudioStreamRandomizer", "set_random_pitch", 373_806_689) internal val getRandomPitchPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamRandomizer", "get_random_pitch", 1740695150) + TypeManager.getMethodBindPtr("AudioStreamRandomizer", "get_random_pitch", 1_740_695_150) internal val setRandomVolumeOffsetDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamRandomizer", "set_random_volume_offset_db", 373806689) + TypeManager.getMethodBindPtr("AudioStreamRandomizer", "set_random_volume_offset_db", 373_806_689) internal val getRandomVolumeOffsetDbPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamRandomizer", "get_random_volume_offset_db", 1740695150) + TypeManager.getMethodBindPtr("AudioStreamRandomizer", "get_random_volume_offset_db", 1_740_695_150) internal val setPlaybackModePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamRandomizer", "set_playback_mode", 3950967023) + TypeManager.getMethodBindPtr("AudioStreamRandomizer", "set_playback_mode", 3_950_967_023) internal val getPlaybackModePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamRandomizer", "get_playback_mode", 3943055077) + TypeManager.getMethodBindPtr("AudioStreamRandomizer", "get_playback_mode", 3_943_055_077) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamSynchronized.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamSynchronized.kt index 8c2dc20acd..bb180dcd53 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamSynchronized.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamSynchronized.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -19,13 +16,10 @@ import kotlin.Float import kotlin.Int import kotlin.Long import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * This is a stream that can be fitted with sub-streams, which will be played in-sync. The streams - * begin at exactly the same time when play is pressed, and will end when the last of them ends. If one - * of the sub-streams loops, then playback will continue. + * This is a stream that can be fitted with sub-streams, which will be played in-sync. The streams begin at exactly the same time when play is pressed, and will end when the last of them ends. If one of the sub-streams loops, then playback will continue. */ @GodotBaseType public open class AudioStreamSynchronized : AudioStream() { @@ -40,11 +34,11 @@ public open class AudioStreamSynchronized : AudioStream() { setStreamCount(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(100, scriptIndex) } - public final fun setStreamCount(streamCount: Int): Unit { + public final fun setStreamCount(streamCount: Int) { TransferContext.writeArguments(LONG to streamCount.toLong()) TransferContext.callMethod(ptr, MethodBindings.setStreamCountPtr, NIL) } @@ -58,7 +52,7 @@ public open class AudioStreamSynchronized : AudioStream() { /** * Set one of the synchronized streams, by index. */ - public final fun setSyncStream(streamIndex: Int, audioStream: AudioStream?): Unit { + public final fun setSyncStream(streamIndex: Int, audioStream: AudioStream?) { TransferContext.writeArguments(LONG to streamIndex.toLong(), OBJECT to audioStream) TransferContext.callMethod(ptr, MethodBindings.setSyncStreamPtr, NIL) } @@ -75,7 +69,7 @@ public open class AudioStreamSynchronized : AudioStream() { /** * Set the volume of one of the synchronized streams, by index. */ - public final fun setSyncStreamVolume(streamIndex: Int, volumeDb: Float): Unit { + public final fun setSyncStreamVolume(streamIndex: Int, volumeDb: Float) { TransferContext.writeArguments(LONG to streamIndex.toLong(), DOUBLE to volumeDb.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setSyncStreamVolumePtr, NIL) } @@ -98,21 +92,21 @@ public open class AudioStreamSynchronized : AudioStream() { public object MethodBindings { internal val setStreamCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamSynchronized", "set_stream_count", 1286410249) + TypeManager.getMethodBindPtr("AudioStreamSynchronized", "set_stream_count", 1_286_410_249) internal val getStreamCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamSynchronized", "get_stream_count", 3905245786) + TypeManager.getMethodBindPtr("AudioStreamSynchronized", "get_stream_count", 3_905_245_786) internal val setSyncStreamPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamSynchronized", "set_sync_stream", 111075094) + TypeManager.getMethodBindPtr("AudioStreamSynchronized", "set_sync_stream", 111_075_094) internal val getSyncStreamPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamSynchronized", "get_sync_stream", 2739380747) + TypeManager.getMethodBindPtr("AudioStreamSynchronized", "get_sync_stream", 2_739_380_747) internal val setSyncStreamVolumePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamSynchronized", "set_sync_stream_volume", 1602489585) + TypeManager.getMethodBindPtr("AudioStreamSynchronized", "set_sync_stream_volume", 1_602_489_585) internal val getSyncStreamVolumePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamSynchronized", "get_sync_stream_volume", 2339986948) + TypeManager.getMethodBindPtr("AudioStreamSynchronized", "get_sync_stream_volume", 2_339_986_948) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamWAV.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamWAV.kt index bb089d2f89..459615df88 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamWAV.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/AudioStreamWAV.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -35,29 +32,22 @@ import kotlin.jvm.JvmOverloads import kotlin.jvm.JvmStatic /** - * AudioStreamWAV stores sound samples loaded from WAV files. To play the stored sound, use an - * [AudioStreamPlayer] (for non-positional audio) or [AudioStreamPlayer2D]/[AudioStreamPlayer3D] (for - * positional audio). The sound can be looped. + * AudioStreamWAV stores sound samples loaded from WAV files. To play the stored sound, use an [AudioStreamPlayer] (for non-positional audio) or [AudioStreamPlayer2D]/[AudioStreamPlayer3D] (for positional audio). The sound can be looped. * - * This class can also be used to store dynamically-generated PCM audio data. See also - * [AudioStreamGenerator] for procedural audio generation. + * This class can also be used to store dynamically-generated PCM audio data. See also [AudioStreamGenerator] for procedural audio generation. */ @GodotBaseType public open class AudioStreamWAV : AudioStream() { /** * Contains the audio data in bytes. * - * **Note:** If [format] is set to [FORMAT_8_BITS], this property expects signed 8-bit PCM data. - * To convert from unsigned 8-bit PCM, subtract 128 from each byte. + * **Note:** If [format] is set to [FORMAT_8_BITS], this property expects signed 8-bit PCM data. To convert from unsigned 8-bit PCM, subtract 128 from each byte. * * **Note:** If [format] is set to [FORMAT_QOA], this property expects data from a full QOA file. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var `data`: PackedByteArray @@ -113,18 +103,11 @@ public open class AudioStreamWAV : AudioStream() { } /** - * The sample rate for mixing this audio. Higher values require more storage space, but result in - * better quality. + * The sample rate for mixing this audio. Higher values require more storage space, but result in better quality. * - * In games, common sample rates in use are `11025`, `16000`, `22050`, `32000`, `44100`, and - * `48000`. + * In games, common sample rates in use are `11025`, `16000`, `22050`, `32000`, `44100`, and `48000`. * - * According to the - * [url=https://en.wikipedia.org/wiki/Nyquist%E2%80%93Shannon_sampling_theorem]Nyquist-Shannon - * sampling theorem[/url], there is no quality difference to human hearing when going past 40,000 Hz - * (since most humans can only hear up to ~20,000 Hz, often less). If you are using lower-pitched - * sounds such as voices, lower sample rates such as `32000` or `22050` may be usable with no loss in - * quality. + * According to the [url=https://en.wikipedia.org/wiki/Nyquist%E2%80%93Shannon_sampling_theorem]Nyquist-Shannon sampling theorem[/url], there is no quality difference to human hearing when going past 40,000 Hz (since most humans can only hear up to ~20,000 Hz, often less). If you are using lower-pitched sounds such as voices, lower sample rates such as `32000` or `22050` may be usable with no loss in quality. */ public final inline var mixRate: Int @JvmName("mixRateProperty") @@ -145,7 +128,7 @@ public open class AudioStreamWAV : AudioStream() { setStereo(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(101, scriptIndex) } @@ -162,8 +145,7 @@ public open class AudioStreamWAV : AudioStream() { * * Contains the audio data in bytes. * - * **Note:** If [format] is set to [FORMAT_8_BITS], this property expects signed 8-bit PCM data. - * To convert from unsigned 8-bit PCM, subtract 128 from each byte. + * **Note:** If [format] is set to [FORMAT_8_BITS], this property expects signed 8-bit PCM data. To convert from unsigned 8-bit PCM, subtract 128 from each byte. * * **Note:** If [format] is set to [FORMAT_QOA], this property expects data from a full QOA file. */ @@ -175,19 +157,16 @@ public open class AudioStreamWAV : AudioStream() { /** * This is a helper function for [data] to make dealing with local copies easier. - * Allow to directly modify each element of the local copy of the property and assign it back to - * the Object. + * Allow to directly modify each element of the local copy of the property and assign it back to the Object. * * Contains the audio data in bytes. * - * **Note:** If [format] is set to [FORMAT_8_BITS], this property expects signed 8-bit PCM data. - * To convert from unsigned 8-bit PCM, subtract 128 from each byte. + * **Note:** If [format] is set to [FORMAT_8_BITS], this property expects signed 8-bit PCM data. To convert from unsigned 8-bit PCM, subtract 128 from each byte. * * **Note:** If [format] is set to [FORMAT_QOA], this property expects data from a full QOA file. */ @CoreTypeHelper - public final fun dataMutateEach(block: (index: Int, `value`: Byte) -> Unit): PackedByteArray = - data.apply { + public final fun dataMutateEach(block: (index: Int, `value`: Byte) -> Unit): PackedByteArray = data.apply { this.forEachIndexed { index, value -> block(index, value) this[index] = value @@ -195,7 +174,7 @@ public open class AudioStreamWAV : AudioStream() { data = this } - public final fun setData(`data`: PackedByteArray): Unit { + public final fun setData(`data`: PackedByteArray) { TransferContext.writeArguments(PACKED_BYTE_ARRAY to data) TransferContext.callMethod(ptr, MethodBindings.setDataPtr, NIL) } @@ -206,7 +185,7 @@ public open class AudioStreamWAV : AudioStream() { return (TransferContext.readReturnValue(PACKED_BYTE_ARRAY) as PackedByteArray) } - public final fun setFormat(format: Format): Unit { + public final fun setFormat(format: Format) { TransferContext.writeArguments(LONG to format.id) TransferContext.callMethod(ptr, MethodBindings.setFormatPtr, NIL) } @@ -217,7 +196,7 @@ public open class AudioStreamWAV : AudioStream() { return Format.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setLoopMode(loopMode: LoopMode): Unit { + public final fun setLoopMode(loopMode: LoopMode) { TransferContext.writeArguments(LONG to loopMode.id) TransferContext.callMethod(ptr, MethodBindings.setLoopModePtr, NIL) } @@ -228,7 +207,7 @@ public open class AudioStreamWAV : AudioStream() { return LoopMode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setLoopBegin(loopBegin: Int): Unit { + public final fun setLoopBegin(loopBegin: Int) { TransferContext.writeArguments(LONG to loopBegin.toLong()) TransferContext.callMethod(ptr, MethodBindings.setLoopBeginPtr, NIL) } @@ -239,7 +218,7 @@ public open class AudioStreamWAV : AudioStream() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setLoopEnd(loopEnd: Int): Unit { + public final fun setLoopEnd(loopEnd: Int) { TransferContext.writeArguments(LONG to loopEnd.toLong()) TransferContext.callMethod(ptr, MethodBindings.setLoopEndPtr, NIL) } @@ -250,7 +229,7 @@ public open class AudioStreamWAV : AudioStream() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setMixRate(mixRate: Int): Unit { + public final fun setMixRate(mixRate: Int) { TransferContext.writeArguments(LONG to mixRate.toLong()) TransferContext.callMethod(ptr, MethodBindings.setMixRatePtr, NIL) } @@ -261,7 +240,7 @@ public open class AudioStreamWAV : AudioStream() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setStereo(stereo: Boolean): Unit { + public final fun setStereo(stereo: Boolean) { TransferContext.writeArguments(BOOL to stereo) TransferContext.callMethod(ptr, MethodBindings.setStereoPtr, NIL) } @@ -273,8 +252,7 @@ public open class AudioStreamWAV : AudioStream() { } /** - * Saves the AudioStreamWAV as a WAV file to [path]. Samples with IMA ADPCM or Quite OK Audio - * formats can't be saved. + * Saves the AudioStreamWAV as a WAV file to [path]. Samples with IMA ADPCM or Quite OK Audio formats can't be saved. * * **Note:** A `.wav` extension is automatically appended to [path] if it is missing. */ @@ -348,24 +326,20 @@ public open class AudioStreamWAV : AudioStream() { public companion object { /** - * Creates a new [AudioStreamWAV] instance from the given buffer. The buffer must contain WAV - * data. + * Creates a new [AudioStreamWAV] instance from the given buffer. The buffer must contain WAV data. * - * The keys and values of [options] match the properties of [ResourceImporterWAV]. The usage of - * [options] is identical to [AudioStreamWAV.loadFromFile]. + * The keys and values of [options] match the properties of [ResourceImporterWAV]. The usage of [options] is identical to [AudioStreamWAV.loadFromFile]. */ @JvmOverloads @JvmStatic - public final fun loadFromBuffer(streamData: PackedByteArray, options: Dictionary = - Dictionary()): AudioStreamWAV? { + public final fun loadFromBuffer(streamData: PackedByteArray, options: Dictionary = Dictionary()): AudioStreamWAV? { TransferContext.writeArguments(PACKED_BYTE_ARRAY to streamData, DICTIONARY to options) TransferContext.callMethod(0, MethodBindings.loadFromBufferPtr, OBJECT) return (TransferContext.readReturnValue(OBJECT) as AudioStreamWAV?) } /** - * Creates a new [AudioStreamWAV] instance from the given file path. The file must be in WAV - * format. + * Creates a new [AudioStreamWAV] instance from the given file path. The file must be in WAV format. * * The keys and values of [options] match the properties of [ResourceImporterWAV]. * @@ -388,8 +362,7 @@ public open class AudioStreamWAV : AudioStream() { */ @JvmOverloads @JvmStatic - public final fun loadFromFile(path: String, options: Dictionary = Dictionary()): - AudioStreamWAV? { + public final fun loadFromFile(path: String, options: Dictionary = Dictionary()): AudioStreamWAV? { TransferContext.writeArguments(STRING to path, DICTIONARY to options) TransferContext.callMethod(0, MethodBindings.loadFromFilePtr, OBJECT) return (TransferContext.readReturnValue(OBJECT) as AudioStreamWAV?) @@ -398,54 +371,54 @@ public open class AudioStreamWAV : AudioStream() { public object MethodBindings { internal val loadFromBufferPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamWAV", "load_from_buffer", 4266838938) + TypeManager.getMethodBindPtr("AudioStreamWAV", "load_from_buffer", 4_266_838_938) internal val loadFromFilePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamWAV", "load_from_file", 4015802384) + TypeManager.getMethodBindPtr("AudioStreamWAV", "load_from_file", 4_015_802_384) internal val setDataPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamWAV", "set_data", 2971499966) + TypeManager.getMethodBindPtr("AudioStreamWAV", "set_data", 2_971_499_966) internal val getDataPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamWAV", "get_data", 2362200018) + TypeManager.getMethodBindPtr("AudioStreamWAV", "get_data", 2_362_200_018) internal val setFormatPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamWAV", "set_format", 60648488) + TypeManager.getMethodBindPtr("AudioStreamWAV", "set_format", 60_648_488) internal val getFormatPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamWAV", "get_format", 3151724922) + TypeManager.getMethodBindPtr("AudioStreamWAV", "get_format", 3_151_724_922) internal val setLoopModePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamWAV", "set_loop_mode", 2444882972) + TypeManager.getMethodBindPtr("AudioStreamWAV", "set_loop_mode", 2_444_882_972) internal val getLoopModePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamWAV", "get_loop_mode", 393560655) + TypeManager.getMethodBindPtr("AudioStreamWAV", "get_loop_mode", 393_560_655) internal val setLoopBeginPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamWAV", "set_loop_begin", 1286410249) + TypeManager.getMethodBindPtr("AudioStreamWAV", "set_loop_begin", 1_286_410_249) internal val getLoopBeginPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamWAV", "get_loop_begin", 3905245786) + TypeManager.getMethodBindPtr("AudioStreamWAV", "get_loop_begin", 3_905_245_786) internal val setLoopEndPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamWAV", "set_loop_end", 1286410249) + TypeManager.getMethodBindPtr("AudioStreamWAV", "set_loop_end", 1_286_410_249) internal val getLoopEndPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamWAV", "get_loop_end", 3905245786) + TypeManager.getMethodBindPtr("AudioStreamWAV", "get_loop_end", 3_905_245_786) internal val setMixRatePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamWAV", "set_mix_rate", 1286410249) + TypeManager.getMethodBindPtr("AudioStreamWAV", "set_mix_rate", 1_286_410_249) internal val getMixRatePtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamWAV", "get_mix_rate", 3905245786) + TypeManager.getMethodBindPtr("AudioStreamWAV", "get_mix_rate", 3_905_245_786) internal val setStereoPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamWAV", "set_stereo", 2586408642) + TypeManager.getMethodBindPtr("AudioStreamWAV", "set_stereo", 2_586_408_642) internal val isStereoPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamWAV", "is_stereo", 36873697) + TypeManager.getMethodBindPtr("AudioStreamWAV", "is_stereo", 36_873_697) internal val saveToWavPtr: VoidPtr = - TypeManager.getMethodBindPtr("AudioStreamWAV", "save_to_wav", 166001499) + TypeManager.getMethodBindPtr("AudioStreamWAV", "save_to_wav", 166_001_499) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BackBufferCopy.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BackBufferCopy.kt index 1629f6dcb7..9f65a23b17 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BackBufferCopy.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BackBufferCopy.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -23,15 +20,9 @@ import kotlin.Unit import kotlin.jvm.JvmName /** - * Node for back-buffering the currently-displayed screen. The region defined in the - * [BackBufferCopy] node is buffered with the content of the screen it covers, or the entire screen - * according to the [copyMode]. It can be accessed in shader scripts using the screen texture (i.e. a - * uniform sampler with `hint_screen_texture`). + * Node for back-buffering the currently-displayed screen. The region defined in the [BackBufferCopy] node is buffered with the content of the screen it covers, or the entire screen according to the [copyMode]. It can be accessed in shader scripts using the screen texture (i.e. a uniform sampler with `hint_screen_texture`). * - * **Note:** Since this node inherits from [Node2D] (and not [Control]), anchors and margins won't - * apply to child [Control]-derived nodes. This can be problematic when resizing the window. To avoid - * this, add [Control]-derived nodes as *siblings* to the [BackBufferCopy] node instead of adding them - * as children. + * **Note:** Since this node inherits from [Node2D] (and not [Control]), anchors and margins won't apply to child [Control]-derived nodes. This can be problematic when resizing the window. To avoid this, add [Control]-derived nodes as *siblings* to the [BackBufferCopy] node instead of adding them as children. */ @GodotBaseType public open class BackBufferCopy : Node2D() { @@ -50,11 +41,8 @@ public open class BackBufferCopy : Node2D() { * The area covered by the [BackBufferCopy]. Only used if [copyMode] is [COPY_MODE_RECT]. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var rect: Rect2 @@ -65,7 +53,7 @@ public open class BackBufferCopy : Node2D() { setRect(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(102, scriptIndex) } @@ -88,7 +76,7 @@ public open class BackBufferCopy : Node2D() { rect = this } - public final fun setRect(rect: Rect2): Unit { + public final fun setRect(rect: Rect2) { TransferContext.writeArguments(RECT2 to rect) TransferContext.callMethod(ptr, MethodBindings.setRectPtr, NIL) } @@ -99,7 +87,7 @@ public open class BackBufferCopy : Node2D() { return (TransferContext.readReturnValue(RECT2) as Rect2) } - public final fun setCopyMode(copyMode: CopyMode): Unit { + public final fun setCopyMode(copyMode: CopyMode) { TransferContext.writeArguments(LONG to copyMode.id) TransferContext.callMethod(ptr, MethodBindings.setCopyModePtr, NIL) } @@ -114,8 +102,7 @@ public open class BackBufferCopy : Node2D() { id: Long, ) { /** - * Disables the buffering mode. This means the [BackBufferCopy] node will directly use the - * portion of screen it covers. + * Disables the buffering mode. This means the [BackBufferCopy] node will directly use the portion of screen it covers. */ DISABLED(0), /** @@ -142,15 +129,15 @@ public open class BackBufferCopy : Node2D() { public object MethodBindings { internal val setRectPtr: VoidPtr = - TypeManager.getMethodBindPtr("BackBufferCopy", "set_rect", 2046264180) + TypeManager.getMethodBindPtr("BackBufferCopy", "set_rect", 2_046_264_180) internal val getRectPtr: VoidPtr = - TypeManager.getMethodBindPtr("BackBufferCopy", "get_rect", 1639390495) + TypeManager.getMethodBindPtr("BackBufferCopy", "get_rect", 1_639_390_495) internal val setCopyModePtr: VoidPtr = - TypeManager.getMethodBindPtr("BackBufferCopy", "set_copy_mode", 1713538590) + TypeManager.getMethodBindPtr("BackBufferCopy", "set_copy_mode", 1_713_538_590) internal val getCopyModePtr: VoidPtr = - TypeManager.getMethodBindPtr("BackBufferCopy", "get_copy_mode", 3271169440) + TypeManager.getMethodBindPtr("BackBufferCopy", "get_copy_mode", 3_271_169_440) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BaseButton.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BaseButton.kt index 37188745a2..7fe40b1fdc 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BaseButton.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BaseButton.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -22,7 +19,6 @@ import kotlin.Int import kotlin.Long import kotlin.NotImplementedError import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** @@ -31,11 +27,9 @@ import kotlin.jvm.JvmName @GodotBaseType public open class BaseButton : Control() { /** - * Emitted when the button is toggled or pressed. This is on [signal button_down] if [actionMode] - * is [ACTION_MODE_BUTTON_PRESS] and on [signal button_up] otherwise. + * Emitted when the button is toggled or pressed. This is on [signal button_down] if [actionMode] is [ACTION_MODE_BUTTON_PRESS] and on [signal button_up] otherwise. * - * If you need to know the button's pressed state (and [toggleMode] is active), use [signal - * toggled] instead. + * If you need to know the button's pressed state (and [toggleMode] is active), use [signal toggled] instead. */ public val pressed: Signal0 by Signal0 @@ -50,8 +44,7 @@ public open class BaseButton : Control() { public val buttonDown: Signal0 by Signal0 /** - * Emitted when the button was just toggled between pressed and normal states (only if - * [toggleMode] is active). The new state is contained in the [toggledOn] argument. + * Emitted when the button was just toggled between pressed and normal states (only if [toggleMode] is active). The new state is contained in the [toggledOn] argument. */ public val toggled: Signal1 by Signal1 @@ -67,8 +60,7 @@ public open class BaseButton : Control() { } /** - * If `true`, the button is in toggle mode. Makes the button flip state between pressed and - * unpressed each time its area is clicked. + * If `true`, the button is in toggle mode. Makes the button flip state between pressed and unpressed each time its area is clicked. */ public final inline var toggleMode: Boolean @JvmName("toggleModeProperty") @@ -79,11 +71,9 @@ public open class BaseButton : Control() { } /** - * If `true`, the button's state is pressed. Means the button is pressed down or toggled (if - * [toggleMode] is active). Only works if [toggleMode] is `true`. + * If `true`, the button's state is pressed. Means the button is pressed down or toggled (if [toggleMode] is active). Only works if [toggleMode] is `true`. * - * **Note:** Changing the value of [buttonPressed] will result in [signal toggled] to be emitted. - * If you want to change the pressed state without emitting that signal, use [setPressedNoSignal]. + * **Note:** Changing the value of [buttonPressed] will result in [signal toggled] to be emitted. If you want to change the pressed state without emitting that signal, use [setPressedNoSignal]. */ public final inline var buttonPressed: Boolean @JvmName("buttonPressedProperty") @@ -107,8 +97,7 @@ public open class BaseButton : Control() { /** * Binary mask to choose which mouse buttons this button will respond to. * - * To allow both left-click and right-click, use `MOUSE_BUTTON_MASK_LEFT | - * MOUSE_BUTTON_MASK_RIGHT`. + * To allow both left-click and right-click, use `MOUSE_BUTTON_MASK_LEFT | MOUSE_BUTTON_MASK_RIGHT`. */ public final inline var buttonMask: MouseButtonMask @JvmName("buttonMaskProperty") @@ -119,11 +108,9 @@ public open class BaseButton : Control() { } /** - * If `true`, the button stays pressed when moving the cursor outside the button while pressing - * it. + * If `true`, the button stays pressed when moving the cursor outside the button while pressing it. * - * **Note:** This property only affects the button's visual appearance. Signals will be emitted at - * the same moment regardless of this property's value. + * **Note:** This property only affects the button's visual appearance. Signals will be emitted at the same moment regardless of this property's value. */ public final inline var keepPressedOutside: Boolean @JvmName("keepPressedOutsideProperty") @@ -158,8 +145,7 @@ public open class BaseButton : Control() { } /** - * If `true`, the button will highlight for a short amount of time when its shortcut is activated. - * If `false` and [toggleMode] is `false`, the shortcut will activate without any visual feedback. + * If `true`, the button will highlight for a short amount of time when its shortcut is activated. If `false` and [toggleMode] is `false`, the shortcut will activate without any visual feedback. */ public final inline var shortcutFeedback: Boolean @JvmName("shortcutFeedbackProperty") @@ -172,8 +158,7 @@ public open class BaseButton : Control() { /** * If `true`, the button will add information about its shortcut in the tooltip. * - * **Note:** This property does nothing when the tooltip control is customized using - * [Control.MakeCustomTooltip]. + * **Note:** This property does nothing when the tooltip control is customized using [Control.MakeCustomTooltip]. */ public final inline var shortcutInTooltip: Boolean @JvmName("shortcutInTooltipProperty") @@ -183,26 +168,25 @@ public open class BaseButton : Control() { setShortcutInTooltip(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(103, scriptIndex) } /** - * Called when the button is pressed. If you need to know the button's pressed state (and - * [toggleMode] is active), use [_toggled] instead. + * Called when the button is pressed. If you need to know the button's pressed state (and [toggleMode] is active), use [_toggled] instead. */ - public open fun _pressed(): Unit { + public open fun _pressed() { throw NotImplementedError("BaseButton::_pressed is not implemented.") } /** * Called when the button is toggled (only if [toggleMode] is active). */ - public open fun _toggled(toggledOn: Boolean): Unit { + public open fun _toggled(toggledOn: Boolean) { throw NotImplementedError("BaseButton::_toggled is not implemented.") } - public final fun setPressed(pressed: Boolean): Unit { + public final fun setPressed(pressed: Boolean) { TransferContext.writeArguments(BOOL to pressed) TransferContext.callMethod(ptr, MethodBindings.setPressedPtr, NIL) } @@ -214,13 +198,11 @@ public open class BaseButton : Control() { } /** - * Changes the [buttonPressed] state of the button, without emitting [signal toggled]. Use when - * you just want to change the state of the button without sending the pressed event (e.g. when - * initializing scene). Only works if [toggleMode] is `true`. + * Changes the [buttonPressed] state of the button, without emitting [signal toggled]. Use when you just want to change the state of the button without sending the pressed event (e.g. when initializing scene). Only works if [toggleMode] is `true`. * * **Note:** This method doesn't unpress other buttons in [buttonGroup]. */ - public final fun setPressedNoSignal(pressed: Boolean): Unit { + public final fun setPressedNoSignal(pressed: Boolean) { TransferContext.writeArguments(BOOL to pressed) TransferContext.callMethod(ptr, MethodBindings.setPressedNoSignalPtr, NIL) } @@ -234,7 +216,7 @@ public open class BaseButton : Control() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setToggleMode(enabled: Boolean): Unit { + public final fun setToggleMode(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setToggleModePtr, NIL) } @@ -245,7 +227,7 @@ public open class BaseButton : Control() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setShortcutInTooltip(enabled: Boolean): Unit { + public final fun setShortcutInTooltip(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setShortcutInTooltipPtr, NIL) } @@ -256,7 +238,7 @@ public open class BaseButton : Control() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setDisabled(disabled: Boolean): Unit { + public final fun setDisabled(disabled: Boolean) { TransferContext.writeArguments(BOOL to disabled) TransferContext.callMethod(ptr, MethodBindings.setDisabledPtr, NIL) } @@ -267,7 +249,7 @@ public open class BaseButton : Control() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setActionMode(mode: ActionMode): Unit { + public final fun setActionMode(mode: ActionMode) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setActionModePtr, NIL) } @@ -278,7 +260,7 @@ public open class BaseButton : Control() { return ActionMode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setButtonMask(mask: MouseButtonMask): Unit { + public final fun setButtonMask(mask: MouseButtonMask) { TransferContext.writeArguments(LONG to mask.flag) TransferContext.callMethod(ptr, MethodBindings.setButtonMaskPtr, NIL) } @@ -290,9 +272,7 @@ public open class BaseButton : Control() { } /** - * Returns the visual state used to draw the button. This is useful mainly when implementing your - * own draw code by either overriding _draw() or connecting to "draw" signal. The visual state of the - * button is defined by the [DrawMode] enum. + * Returns the visual state used to draw the button. This is useful mainly when implementing your own draw code by either overriding _draw() or connecting to "draw" signal. The visual state of the button is defined by the [DrawMode] enum. */ public final fun getDrawMode(): DrawMode { TransferContext.writeArguments() @@ -300,7 +280,7 @@ public open class BaseButton : Control() { return DrawMode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setKeepPressedOutside(enabled: Boolean): Unit { + public final fun setKeepPressedOutside(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setKeepPressedOutsidePtr, NIL) } @@ -311,7 +291,7 @@ public open class BaseButton : Control() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setShortcutFeedback(enabled: Boolean): Unit { + public final fun setShortcutFeedback(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setShortcutFeedbackPtr, NIL) } @@ -322,7 +302,7 @@ public open class BaseButton : Control() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setShortcut(shortcut: Shortcut?): Unit { + public final fun setShortcut(shortcut: Shortcut?) { TransferContext.writeArguments(OBJECT to shortcut) TransferContext.callMethod(ptr, MethodBindings.setShortcutPtr, NIL) } @@ -333,7 +313,7 @@ public open class BaseButton : Control() { return (TransferContext.readReturnValue(OBJECT) as Shortcut?) } - public final fun setButtonGroup(buttonGroup: ButtonGroup?): Unit { + public final fun setButtonGroup(buttonGroup: ButtonGroup?) { TransferContext.writeArguments(OBJECT to buttonGroup) TransferContext.callMethod(ptr, MethodBindings.setButtonGroupPtr, NIL) } @@ -406,72 +386,72 @@ public open class BaseButton : Control() { public object MethodBindings { internal val setPressedPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseButton", "set_pressed", 2586408642) + TypeManager.getMethodBindPtr("BaseButton", "set_pressed", 2_586_408_642) internal val isPressedPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseButton", "is_pressed", 36873697) + TypeManager.getMethodBindPtr("BaseButton", "is_pressed", 36_873_697) internal val setPressedNoSignalPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseButton", "set_pressed_no_signal", 2586408642) + TypeManager.getMethodBindPtr("BaseButton", "set_pressed_no_signal", 2_586_408_642) internal val isHoveredPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseButton", "is_hovered", 36873697) + TypeManager.getMethodBindPtr("BaseButton", "is_hovered", 36_873_697) internal val setToggleModePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseButton", "set_toggle_mode", 2586408642) + TypeManager.getMethodBindPtr("BaseButton", "set_toggle_mode", 2_586_408_642) internal val isToggleModePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseButton", "is_toggle_mode", 36873697) + TypeManager.getMethodBindPtr("BaseButton", "is_toggle_mode", 36_873_697) internal val setShortcutInTooltipPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseButton", "set_shortcut_in_tooltip", 2586408642) + TypeManager.getMethodBindPtr("BaseButton", "set_shortcut_in_tooltip", 2_586_408_642) internal val isShortcutInTooltipEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseButton", "is_shortcut_in_tooltip_enabled", 36873697) + TypeManager.getMethodBindPtr("BaseButton", "is_shortcut_in_tooltip_enabled", 36_873_697) internal val setDisabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseButton", "set_disabled", 2586408642) + TypeManager.getMethodBindPtr("BaseButton", "set_disabled", 2_586_408_642) internal val isDisabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseButton", "is_disabled", 36873697) + TypeManager.getMethodBindPtr("BaseButton", "is_disabled", 36_873_697) internal val setActionModePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseButton", "set_action_mode", 1985162088) + TypeManager.getMethodBindPtr("BaseButton", "set_action_mode", 1_985_162_088) internal val getActionModePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseButton", "get_action_mode", 2589712189) + TypeManager.getMethodBindPtr("BaseButton", "get_action_mode", 2_589_712_189) internal val setButtonMaskPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseButton", "set_button_mask", 3950145251) + TypeManager.getMethodBindPtr("BaseButton", "set_button_mask", 3_950_145_251) internal val getButtonMaskPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseButton", "get_button_mask", 2512161324) + TypeManager.getMethodBindPtr("BaseButton", "get_button_mask", 2_512_161_324) internal val getDrawModePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseButton", "get_draw_mode", 2492721305) + TypeManager.getMethodBindPtr("BaseButton", "get_draw_mode", 2_492_721_305) internal val setKeepPressedOutsidePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseButton", "set_keep_pressed_outside", 2586408642) + TypeManager.getMethodBindPtr("BaseButton", "set_keep_pressed_outside", 2_586_408_642) internal val isKeepPressedOutsidePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseButton", "is_keep_pressed_outside", 36873697) + TypeManager.getMethodBindPtr("BaseButton", "is_keep_pressed_outside", 36_873_697) internal val setShortcutFeedbackPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseButton", "set_shortcut_feedback", 2586408642) + TypeManager.getMethodBindPtr("BaseButton", "set_shortcut_feedback", 2_586_408_642) internal val isShortcutFeedbackPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseButton", "is_shortcut_feedback", 36873697) + TypeManager.getMethodBindPtr("BaseButton", "is_shortcut_feedback", 36_873_697) internal val setShortcutPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseButton", "set_shortcut", 857163497) + TypeManager.getMethodBindPtr("BaseButton", "set_shortcut", 857_163_497) internal val getShortcutPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseButton", "get_shortcut", 3415666916) + TypeManager.getMethodBindPtr("BaseButton", "get_shortcut", 3_415_666_916) internal val setButtonGroupPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseButton", "set_button_group", 1794463739) + TypeManager.getMethodBindPtr("BaseButton", "set_button_group", 1_794_463_739) internal val getButtonGroupPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseButton", "get_button_group", 281644053) + TypeManager.getMethodBindPtr("BaseButton", "get_button_group", 281_644_053) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BaseMaterial3D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BaseMaterial3D.kt index aaf040741c..99993535b9 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BaseMaterial3D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BaseMaterial3D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -33,15 +30,12 @@ import kotlin.Unit import kotlin.jvm.JvmName /** - * This class serves as a default material with a wide variety of rendering features and properties - * without the need to write shader code. See the tutorial below for details. + * This class serves as a default material with a wide variety of rendering features and properties without the need to write shader code. See the tutorial below for details. */ @GodotBaseType public open class BaseMaterial3D internal constructor() : Material() { /** - * The material's transparency mode. Some transparency modes will disable shadow casting. Any - * transparency mode other than [TRANSPARENCY_DISABLED] has a greater performance impact compared to - * opaque rendering. See also [blendMode]. + * The material's transparency mode. Some transparency modes will disable shadow casting. Any transparency mode other than [TRANSPARENCY_DISABLED] has a greater performance impact compared to opaque rendering. See also [blendMode]. */ public final inline var transparency: Transparency @JvmName("transparencyProperty") @@ -52,10 +46,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * Threshold at which the alpha scissor will discard values. Higher values will result in more - * pixels being discarded. If the material becomes too opaque at a distance, try increasing - * [alphaScissorThreshold]. If the material disappears at a distance, try decreasing - * [alphaScissorThreshold]. + * Threshold at which the alpha scissor will discard values. Higher values will result in more pixels being discarded. If the material becomes too opaque at a distance, try increasing [alphaScissorThreshold]. If the material disappears at a distance, try decreasing [alphaScissorThreshold]. */ public final inline var alphaScissorThreshold: Float @JvmName("alphaScissorThresholdProperty") @@ -101,8 +92,7 @@ public open class BaseMaterial3D internal constructor() : Material() { /** * The material's blend mode. * - * **Note:** Values other than `Mix` force the object into the transparent pipeline. See - * [BlendMode]. + * **Note:** Values other than `Mix` force the object into the transparent pipeline. See [BlendMode]. */ public final inline var blendMode: BlendMode @JvmName("blendModeProperty") @@ -113,8 +103,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * Determines which side of the triangle to cull depending on whether the triangle faces towards - * or away from the camera. See [CullMode]. + * Determines which side of the triangle to cull depending on whether the triangle faces towards or away from the camera. See [CullMode]. */ public final inline var cullMode: CullMode @JvmName("cullModeProperty") @@ -147,9 +136,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * Sets whether the shading takes place, per-pixel, per-vertex or unshaded. Per-vertex lighting is - * faster, making it the best choice for mobile applications, however it looks considerably worse - * than per-pixel. Unshaded rendering is the fastest, but disables all interactions with lights. + * Sets whether the shading takes place, per-pixel, per-vertex or unshaded. Per-vertex lighting is faster, making it the best choice for mobile applications, however it looks considerably worse than per-pixel. Unshaded rendering is the fastest, but disables all interactions with lights. */ public final inline var shadingMode: ShadingMode @JvmName("shadingModeProperty") @@ -173,9 +160,7 @@ public open class BaseMaterial3D internal constructor() : Material() { /** * The method for rendering the specular blob. See [SpecularMode]. * - * **Note:** [specularMode] only applies to the specular blob. It does not affect specular - * reflections from the sky, screen-space reflections, [VoxelGI], SDFGI or [ReflectionProbe]s. To - * disable reflections from these sources as well, set [metallicSpecular] to `0.0` instead. + * **Note:** [specularMode] only applies to the specular blob. It does not affect specular reflections from the sky, screen-space reflections, [VoxelGI], SDFGI or [ReflectionProbe]s. To disable reflections from these sources as well, set [metallicSpecular] to `0.0` instead. */ public final inline var specularMode: SpecularMode @JvmName("specularModeProperty") @@ -197,9 +182,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * If `true`, the object will not be affected by fog (neither volumetric nor depth fog). This is - * useful for unshaded or transparent materials (e.g. particles), which without this setting will be - * affected even if fully transparent. + * If `true`, the object will not be affected by fog (neither volumetric nor depth fog). This is useful for unshaded or transparent materials (e.g. particles), which without this setting will be affected even if fully transparent. */ public final inline var disableFog: Boolean @JvmName("disableFogProperty") @@ -221,12 +204,9 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * If `true`, vertex colors are considered to be stored in sRGB color space and are converted to - * linear color space during rendering. If `false`, vertex colors are considered to be stored in - * linear color space and are rendered as-is. See also [albedoTextureForceSrgb]. + * If `true`, vertex colors are considered to be stored in sRGB color space and are converted to linear color space during rendering. If `false`, vertex colors are considered to be stored in linear color space and are rendered as-is. See also [albedoTextureForceSrgb]. * - * **Note:** Only effective when using the Forward+ and Mobile rendering methods, not - * Compatibility. + * **Note:** Only effective when using the Forward+ and Mobile rendering methods, not Compatibility. */ public final inline var vertexColorIsSrgb: Boolean @JvmName("vertexColorIsSrgbProperty") @@ -239,16 +219,11 @@ public open class BaseMaterial3D internal constructor() : Material() { /** * The material's base color. * - * **Note:** If [detailEnabled] is `true` and a [detailAlbedo] texture is specified, [albedoColor] - * will *not* modulate the detail texture. This can be used to color partial areas of a material by - * not specifying an albedo texture and using a transparent [detailAlbedo] texture instead. + * **Note:** If [detailEnabled] is `true` and a [detailAlbedo] texture is specified, [albedoColor] will *not* modulate the detail texture. This can be used to color partial areas of a material by not specifying an albedo texture and using a transparent [detailAlbedo] texture instead. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var albedoColor: Color @@ -273,13 +248,9 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * If `true`, forces a conversion of the [albedoTexture] from sRGB color space to linear color - * space. See also [vertexColorIsSrgb]. + * If `true`, forces a conversion of the [albedoTexture] from sRGB color space to linear color space. See also [vertexColorIsSrgb]. * - * This should only be enabled when needed (typically when using a [ViewportTexture] as - * [albedoTexture]). If [albedoTextureForceSrgb] is `true` when it shouldn't be, the texture will - * appear to be too dark. If [albedoTextureForceSrgb] is `false` when it shouldn't be, the texture - * will appear to be too bright. + * This should only be enabled when needed (typically when using a [ViewportTexture] as [albedoTexture]). If [albedoTextureForceSrgb] is `true` when it shouldn't be, the texture will appear to be too dark. If [albedoTextureForceSrgb] is `false` when it shouldn't be, the texture will appear to be too bright. */ public final inline var albedoTextureForceSrgb: Boolean @JvmName("albedoTextureForceSrgbProperty") @@ -290,8 +261,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * Enables multichannel signed distance field rendering shader. Use [msdfPixelRange] and - * [msdfOutlineSize] to configure MSDF parameters. + * Enables multichannel signed distance field rendering shader. Use [msdfPixelRange] and [msdfOutlineSize] to configure MSDF parameters. */ public final inline var albedoTextureMsdf: Boolean @JvmName("albedoTextureMsdfProperty") @@ -302,10 +272,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * The Occlusion/Roughness/Metallic texture to use. This is a more efficient replacement of - * [aoTexture], [roughnessTexture] and [metallicTexture] in [ORMMaterial3D]. Ambient occlusion is - * stored in the red channel. Roughness map is stored in the green channel. Metallic map is stored in - * the blue channel. The alpha channel is ignored. + * The Occlusion/Roughness/Metallic texture to use. This is a more efficient replacement of [aoTexture], [roughnessTexture] and [metallicTexture] in [ORMMaterial3D]. Ambient occlusion is stored in the red channel. Roughness map is stored in the green channel. Metallic map is stored in the blue channel. The alpha channel is ignored. */ public final inline var ormTexture: Texture2D? @JvmName("ormTextureProperty") @@ -316,12 +283,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * A high value makes the material appear more like a metal. Non-metals use their albedo as the - * diffuse color and add diffuse to the specular reflection. With non-metals, the reflection appears - * on top of the albedo color. Metals use their albedo as a multiplier to the specular reflection and - * set the diffuse color to black resulting in a tinted reflection. Materials work better when fully - * metal or fully non-metal, values between `0` and `1` should only be used for blending between - * metal and non-metal sections. To alter the amount of reflection use [roughness]. + * A high value makes the material appear more like a metal. Non-metals use their albedo as the diffuse color and add diffuse to the specular reflection. With non-metals, the reflection appears on top of the albedo color. Metals use their albedo as a multiplier to the specular reflection and set the diffuse color to black resulting in a tinted reflection. Materials work better when fully metal or fully non-metal, values between `0` and `1` should only be used for blending between metal and non-metal sections. To alter the amount of reflection use [roughness]. */ public final inline var metallic: Float @JvmName("metallicProperty") @@ -332,14 +294,9 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * Adjusts the strength of specular reflections. Specular reflections are composed of scene - * reflections and the specular lobe which is the bright spot that is reflected from light sources. - * When set to `0.0`, no specular reflections will be visible. This differs from the - * [SPECULAR_DISABLED] [SpecularMode] as [SPECULAR_DISABLED] only applies to the specular lobe from - * the light source. + * Adjusts the strength of specular reflections. Specular reflections are composed of scene reflections and the specular lobe which is the bright spot that is reflected from light sources. When set to `0.0`, no specular reflections will be visible. This differs from the [SPECULAR_DISABLED] [SpecularMode] as [SPECULAR_DISABLED] only applies to the specular lobe from the light source. * - * **Note:** Unlike [metallic], this is not energy-conserving, so it should be left at `0.5` in - * most cases. See also [roughness]. + * **Note:** Unlike [metallic], this is not energy-conserving, so it should be left at `0.5` in most cases. See also [roughness]. */ public final inline var metallicSpecular: Float @JvmName("metallicSpecularProperty") @@ -361,10 +318,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * Specifies the channel of the [metallicTexture] in which the metallic information is stored. - * This is useful when you store the information for multiple effects in a single texture. For - * example if you stored metallic in the red channel, roughness in the blue, and ambient occlusion in - * the green you could reduce the number of textures you use. + * Specifies the channel of the [metallicTexture] in which the metallic information is stored. This is useful when you store the information for multiple effects in a single texture. For example if you stored metallic in the red channel, roughness in the blue, and ambient occlusion in the green you could reduce the number of textures you use. */ public final inline var metallicTextureChannel: TextureChannel @JvmName("metallicTextureChannelProperty") @@ -375,8 +329,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * Surface reflection. A value of `0` represents a perfect mirror while a value of `1` completely - * blurs the reflection. See also [metallic]. + * Surface reflection. A value of `0` represents a perfect mirror while a value of `1` completely blurs the reflection. See also [metallic]. */ public final inline var roughness: Float @JvmName("roughnessProperty") @@ -398,10 +351,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * Specifies the channel of the [roughnessTexture] in which the roughness information is stored. - * This is useful when you store the information for multiple effects in a single texture. For - * example if you stored metallic in the red channel, roughness in the blue, and ambient occlusion in - * the green you could reduce the number of textures you use. + * Specifies the channel of the [roughnessTexture] in which the roughness information is stored. This is useful when you store the information for multiple effects in a single texture. For example if you stored metallic in the red channel, roughness in the blue, and ambient occlusion in the green you could reduce the number of textures you use. */ public final inline var roughnessTextureChannel: TextureChannel @JvmName("roughnessTextureChannelProperty") @@ -412,9 +362,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * If `true`, the body emits light. Emitting light makes the object appear brighter. The object - * can also cast light on other objects if a [VoxelGI], SDFGI, or [LightmapGI] is used and this - * object is used in baked lighting. + * If `true`, the body emits light. Emitting light makes the object appear brighter. The object can also cast light on other objects if a [VoxelGI], SDFGI, or [LightmapGI] is used and this object is used in baked lighting. */ public final inline var emissionEnabled: Boolean @JvmName("emissionEnabledProperty") @@ -428,11 +376,8 @@ public open class BaseMaterial3D internal constructor() : Material() { * The emitted light's color. See [emissionEnabled]. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var emission: Color @@ -455,9 +400,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * Luminance of emitted light, measured in nits (candela per square meter). Only available when - * [ProjectSettings.rendering/lightsAndShadows/usePhysicalLightUnits] is enabled. The default is - * roughly equivalent to an indoor lightbulb. + * Luminance of emitted light, measured in nits (candela per square meter). Only available when [ProjectSettings.rendering/lightsAndShadows/usePhysicalLightUnits] is enabled. The default is roughly equivalent to an indoor lightbulb. */ public final inline var emissionIntensity: Float @JvmName("emissionIntensityProperty") @@ -468,8 +411,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * Sets how [emission] interacts with [emissionTexture]. Can either add or multiply. See - * [EmissionOperator] for options. + * Sets how [emission] interacts with [emissionTexture]. Can either add or multiply. See [EmissionOperator] for options. */ public final inline var emissionOperator: EmissionOperator @JvmName("emissionOperatorProperty") @@ -502,8 +444,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * If `true`, normal mapping is enabled. This has a slight performance cost, especially on mobile - * GPUs. + * If `true`, normal mapping is enabled. This has a slight performance cost, especially on mobile GPUs. */ public final inline var normalEnabled: Boolean @JvmName("normalEnabledProperty") @@ -525,22 +466,13 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * Texture used to specify the normal at a given pixel. The [normalTexture] only uses the red and - * green channels; the blue and alpha channels are ignored. The normal read from [normalTexture] is - * oriented around the surface normal provided by the [Mesh]. + * Texture used to specify the normal at a given pixel. The [normalTexture] only uses the red and green channels; the blue and alpha channels are ignored. The normal read from [normalTexture] is oriented around the surface normal provided by the [Mesh]. * - * **Note:** The mesh must have both normals and tangents defined in its vertex data. Otherwise, - * the normal map won't render correctly and will only appear to darken the whole surface. If - * creating geometry with [SurfaceTool], you can use [SurfaceTool.generateNormals] and - * [SurfaceTool.generateTangents] to automatically generate normals and tangents respectively. + * **Note:** The mesh must have both normals and tangents defined in its vertex data. Otherwise, the normal map won't render correctly and will only appear to darken the whole surface. If creating geometry with [SurfaceTool], you can use [SurfaceTool.generateNormals] and [SurfaceTool.generateTangents] to automatically generate normals and tangents respectively. * - * **Note:** Godot expects the normal map to use X+, Y+, and Z+ coordinates. See - * [url=http://wiki.polycount.com/wiki/Normal_Map_Technical_Details#Common_Swizzle_Coordinates]this - * page[/url] for a comparison of normal map coordinates expected by popular engines. + * **Note:** Godot expects the normal map to use X+, Y+, and Z+ coordinates. See [url=http://wiki.polycount.com/wiki/Normal_Map_Technical_Details#Common_Swizzle_Coordinates]this page[/url] for a comparison of normal map coordinates expected by popular engines. * - * **Note:** If [detailEnabled] is `true`, the [detailAlbedo] texture is drawn *below* the - * [normalTexture]. To display a normal map *above* the [detailAlbedo] texture, use [detailNormal] - * instead. + * **Note:** If [detailEnabled] is `true`, the [detailAlbedo] texture is drawn *below* the [normalTexture]. To display a normal map *above* the [detailAlbedo] texture, use [detailNormal] instead. */ public final inline var normalTexture: Texture2D? @JvmName("normalTextureProperty") @@ -551,11 +483,9 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * If `true`, rim effect is enabled. Rim lighting increases the brightness at glancing angles on - * an object. + * If `true`, rim effect is enabled. Rim lighting increases the brightness at glancing angles on an object. * - * **Note:** Rim lighting is not visible if the material's [shadingMode] is - * [SHADING_MODE_UNSHADED]. + * **Note:** Rim lighting is not visible if the material's [shadingMode] is [SHADING_MODE_UNSHADED]. */ public final inline var rimEnabled: Boolean @JvmName("rimEnabledProperty") @@ -577,8 +507,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * The amount of to blend light and albedo color when rendering rim effect. If `0` the light color - * is used, while `1` means albedo color is used. An intermediate value generally works best. + * The amount of to blend light and albedo color when rendering rim effect. If `0` the light color is used, while `1` means albedo color is used. An intermediate value generally works best. */ public final inline var rimTint: Float @JvmName("rimTintProperty") @@ -600,12 +529,9 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * If `true`, clearcoat rendering is enabled. Adds a secondary transparent pass to the lighting - * calculation resulting in an added specular blob. This makes materials appear as if they have a - * clear layer on them that can be either glossy or rough. + * If `true`, clearcoat rendering is enabled. Adds a secondary transparent pass to the lighting calculation resulting in an added specular blob. This makes materials appear as if they have a clear layer on them that can be either glossy or rough. * - * **Note:** Clearcoat rendering is not visible if the material's [shadingMode] is - * [SHADING_MODE_UNSHADED]. + * **Note:** Clearcoat rendering is not visible if the material's [shadingMode] is [SHADING_MODE_UNSHADED]. */ public final inline var clearcoatEnabled: Boolean @JvmName("clearcoatEnabledProperty") @@ -616,8 +542,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * Sets the strength of the clearcoat effect. Setting to `0` looks the same as disabling the - * clearcoat effect. + * Sets the strength of the clearcoat effect. Setting to `0` looks the same as disabling the clearcoat effect. */ public final inline var clearcoat: Float @JvmName("clearcoatProperty") @@ -628,8 +553,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * Sets the roughness of the clearcoat pass. A higher value results in a rougher clearcoat while a - * lower value results in a smoother clearcoat. + * Sets the roughness of the clearcoat pass. A higher value results in a rougher clearcoat while a lower value results in a smoother clearcoat. */ public final inline var clearcoatRoughness: Float @JvmName("clearcoatRoughnessProperty") @@ -640,8 +564,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * Texture that defines the strength of the clearcoat effect and the glossiness of the clearcoat. - * Strength is specified in the red channel while glossiness is specified in the green channel. + * Texture that defines the strength of the clearcoat effect and the glossiness of the clearcoat. Strength is specified in the red channel while glossiness is specified in the green channel. */ public final inline var clearcoatTexture: Texture2D? @JvmName("clearcoatTextureProperty") @@ -652,15 +575,11 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * If `true`, anisotropy is enabled. Anisotropy changes the shape of the specular blob and aligns - * it to tangent space. This is useful for brushed aluminum and hair reflections. + * If `true`, anisotropy is enabled. Anisotropy changes the shape of the specular blob and aligns it to tangent space. This is useful for brushed aluminum and hair reflections. * - * **Note:** Mesh tangents are needed for anisotropy to work. If the mesh does not contain - * tangents, the anisotropy effect will appear broken. + * **Note:** Mesh tangents are needed for anisotropy to work. If the mesh does not contain tangents, the anisotropy effect will appear broken. * - * **Note:** Material anisotropy should not to be confused with anisotropic texture filtering, - * which can be enabled by setting [textureFilter] to - * [TEXTURE_FILTER_LINEAR_WITH_MIPMAPS_ANISOTROPIC]. + * **Note:** Material anisotropy should not to be confused with anisotropic texture filtering, which can be enabled by setting [textureFilter] to [TEXTURE_FILTER_LINEAR_WITH_MIPMAPS_ANISOTROPIC]. */ public final inline var anisotropyEnabled: Boolean @JvmName("anisotropyEnabledProperty") @@ -671,8 +590,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * The strength of the anisotropy effect. This is multiplied by [anisotropyFlowmap]'s alpha - * channel if a texture is defined there and the texture contains an alpha channel. + * The strength of the anisotropy effect. This is multiplied by [anisotropyFlowmap]'s alpha channel if a texture is defined there and the texture contains an alpha channel. */ public final inline var anisotropy: Float @JvmName("anisotropyProperty") @@ -683,16 +601,9 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * Texture that offsets the tangent map for anisotropy calculations and optionally controls the - * anisotropy effect (if an alpha channel is present). The flowmap texture is expected to be a - * derivative map, with the red channel representing distortion on the X axis and green channel - * representing distortion on the Y axis. Values below 0.5 will result in negative distortion, - * whereas values above 0.5 will result in positive distortion. + * Texture that offsets the tangent map for anisotropy calculations and optionally controls the anisotropy effect (if an alpha channel is present). The flowmap texture is expected to be a derivative map, with the red channel representing distortion on the X axis and green channel representing distortion on the Y axis. Values below 0.5 will result in negative distortion, whereas values above 0.5 will result in positive distortion. * - * If present, the texture's alpha channel will be used to multiply the strength of the - * [anisotropy] effect. Fully opaque pixels will keep the anisotropy effect's original strength while - * fully transparent pixels will disable the anisotropy effect entirely. The flowmap texture's blue - * channel is ignored. + * If present, the texture's alpha channel will be used to multiply the strength of the [anisotropy] effect. Fully opaque pixels will keep the anisotropy effect's original strength while fully transparent pixels will disable the anisotropy effect entirely. The flowmap texture's blue channel is ignored. */ public final inline var anisotropyFlowmap: Texture2D? @JvmName("anisotropyFlowmapProperty") @@ -703,8 +614,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * If `true`, ambient occlusion is enabled. Ambient occlusion darkens areas based on the - * [aoTexture]. + * If `true`, ambient occlusion is enabled. Ambient occlusion darkens areas based on the [aoTexture]. */ public final inline var aoEnabled: Boolean @JvmName("aoEnabledProperty") @@ -715,10 +625,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * Amount that ambient occlusion affects lighting from lights. If `0`, ambient occlusion only - * affects ambient light. If `1`, ambient occlusion affects lights just as much as it affects ambient - * light. This can be used to impact the strength of the ambient occlusion effect, but typically - * looks unrealistic. + * Amount that ambient occlusion affects lighting from lights. If `0`, ambient occlusion only affects ambient light. If `1`, ambient occlusion affects lights just as much as it affects ambient light. This can be used to impact the strength of the ambient occlusion effect, but typically looks unrealistic. */ public final inline var aoLightAffect: Float @JvmName("aoLightAffectProperty") @@ -751,10 +658,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * Specifies the channel of the [aoTexture] in which the ambient occlusion information is stored. - * This is useful when you store the information for multiple effects in a single texture. For - * example if you stored metallic in the red channel, roughness in the blue, and ambient occlusion in - * the green you could reduce the number of textures you use. + * Specifies the channel of the [aoTexture] in which the ambient occlusion information is stored. This is useful when you store the information for multiple effects in a single texture. For example if you stored metallic in the red channel, roughness in the blue, and ambient occlusion in the green you could reduce the number of textures you use. */ public final inline var aoTextureChannel: TextureChannel @JvmName("aoTextureChannelProperty") @@ -765,12 +669,9 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * If `true`, height mapping is enabled (also called "parallax mapping" or "depth mapping"). See - * also [normalEnabled]. Height mapping is a demanding feature on the GPU, so it should only be used - * on materials where it makes a significant visual difference. + * If `true`, height mapping is enabled (also called "parallax mapping" or "depth mapping"). See also [normalEnabled]. Height mapping is a demanding feature on the GPU, so it should only be used on materials where it makes a significant visual difference. * - * **Note:** Height mapping is not supported if triplanar mapping is used on the same material. - * The value of [heightmapEnabled] will be ignored if [uv1Triplanar] is enabled. + * **Note:** Height mapping is not supported if triplanar mapping is used on the same material. The value of [heightmapEnabled] will be ignored if [uv1Triplanar] is enabled. */ public final inline var heightmapEnabled: Boolean @JvmName("heightmapEnabledProperty") @@ -781,18 +682,9 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * The heightmap scale to use for the parallax effect (see [heightmapEnabled]). The default value - * is tuned so that the highest point (value = 255) appears to be 5 cm higher than the lowest point - * (value = 0). Higher values result in a deeper appearance, but may result in artifacts appearing - * when looking at the material from oblique angles, especially when the camera moves. Negative - * values can be used to invert the parallax effect, but this is different from inverting the texture - * using [heightmapFlipTexture] as the material will also appear to be "closer" to the camera. In - * most cases, [heightmapScale] should be kept to a positive value. + * The heightmap scale to use for the parallax effect (see [heightmapEnabled]). The default value is tuned so that the highest point (value = 255) appears to be 5 cm higher than the lowest point (value = 0). Higher values result in a deeper appearance, but may result in artifacts appearing when looking at the material from oblique angles, especially when the camera moves. Negative values can be used to invert the parallax effect, but this is different from inverting the texture using [heightmapFlipTexture] as the material will also appear to be "closer" to the camera. In most cases, [heightmapScale] should be kept to a positive value. * - * **Note:** If the height map effect looks strange regardless of this value, try adjusting - * [heightmapFlipBinormal] and [heightmapFlipTangent]. See also [heightmapTexture] for - * recommendations on authoring heightmap textures, as the way the heightmap texture is authored - * affects how [heightmapScale] behaves. + * **Note:** If the height map effect looks strange regardless of this value, try adjusting [heightmapFlipBinormal] and [heightmapFlipTangent]. See also [heightmapTexture] for recommendations on authoring heightmap textures, as the way the heightmap texture is authored affects how [heightmapScale] behaves. */ public final inline var heightmapScale: Float @JvmName("heightmapScaleProperty") @@ -803,10 +695,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * If `true`, uses parallax occlusion mapping to represent depth in the material instead of simple - * offset mapping (see [heightmapEnabled]). This results in a more convincing depth effect, but is - * much more expensive on the GPU. Only enable this on materials where it makes a significant visual - * difference. + * If `true`, uses parallax occlusion mapping to represent depth in the material instead of simple offset mapping (see [heightmapEnabled]). This results in a more convincing depth effect, but is much more expensive on the GPU. Only enable this on materials where it makes a significant visual difference. */ public final inline var heightmapDeepParallax: Boolean @JvmName("heightmapDeepParallaxProperty") @@ -817,10 +706,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * The number of layers to use for parallax occlusion mapping when the camera is far away from the - * material. Higher values result in a more convincing depth effect, especially in materials that - * have steep height changes. Higher values have a significant cost on the GPU, so it should only be - * increased on materials where it makes a significant visual difference. + * The number of layers to use for parallax occlusion mapping when the camera is far away from the material. Higher values result in a more convincing depth effect, especially in materials that have steep height changes. Higher values have a significant cost on the GPU, so it should only be increased on materials where it makes a significant visual difference. * * **Note:** Only effective if [heightmapDeepParallax] is `true`. */ @@ -833,10 +719,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * The number of layers to use for parallax occlusion mapping when the camera is up close to the - * material. Higher values result in a more convincing depth effect, especially in materials that - * have steep height changes. Higher values have a significant cost on the GPU, so it should only be - * increased on materials where it makes a significant visual difference. + * The number of layers to use for parallax occlusion mapping when the camera is up close to the material. Higher values result in a more convincing depth effect, especially in materials that have steep height changes. Higher values have a significant cost on the GPU, so it should only be increased on materials where it makes a significant visual difference. * * **Note:** Only effective if [heightmapDeepParallax] is `true`. */ @@ -849,9 +732,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * If `true`, flips the mesh's tangent vectors when interpreting the height map. If the heightmap - * effect looks strange when the camera moves (even with a reasonable [heightmapScale]), try setting - * this to `true`. + * If `true`, flips the mesh's tangent vectors when interpreting the height map. If the heightmap effect looks strange when the camera moves (even with a reasonable [heightmapScale]), try setting this to `true`. */ public final inline var heightmapFlipTangent: Boolean @JvmName("heightmapFlipTangentProperty") @@ -862,9 +743,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * If `true`, flips the mesh's binormal vectors when interpreting the height map. If the heightmap - * effect looks strange when the camera moves (even with a reasonable [heightmapScale]), try setting - * this to `true`. + * If `true`, flips the mesh's binormal vectors when interpreting the height map. If the heightmap effect looks strange when the camera moves (even with a reasonable [heightmapScale]), try setting this to `true`. */ public final inline var heightmapFlipBinormal: Boolean @JvmName("heightmapFlipBinormalProperty") @@ -877,13 +756,9 @@ public open class BaseMaterial3D internal constructor() : Material() { /** * The texture to use as a height map. See also [heightmapEnabled]. * - * For best results, the texture should be normalized (with [heightmapScale] reduced to - * compensate). In [url=https://gimp.org]GIMP[/url], this can be done using **Colors > Auto > - * Equalize**. If the texture only uses a small part of its available range, the parallax effect may - * look strange, especially when the camera moves. + * For best results, the texture should be normalized (with [heightmapScale] reduced to compensate). In [url=https://gimp.org]GIMP[/url], this can be done using **Colors > Auto > Equalize**. If the texture only uses a small part of its available range, the parallax effect may look strange, especially when the camera moves. * - * **Note:** To reduce memory usage and improve loading times, you may be able to use a - * lower-resolution heightmap texture as most heightmaps are only comprised of low-frequency data. + * **Note:** To reduce memory usage and improve loading times, you may be able to use a lower-resolution heightmap texture as most heightmaps are only comprised of low-frequency data. */ public final inline var heightmapTexture: Texture2D? @JvmName("heightmapTextureProperty") @@ -894,12 +769,9 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * If `true`, interprets the height map texture as a depth map, with brighter values appearing to - * be "lower" in altitude compared to darker values. + * If `true`, interprets the height map texture as a depth map, with brighter values appearing to be "lower" in altitude compared to darker values. * - * This can be enabled for compatibility with some materials authored for Godot 3.x. This is not - * necessary if the Invert import option was used to invert the depth map in Godot 3.x, in which case - * [heightmapFlipTexture] should remain `false`. + * This can be enabled for compatibility with some materials authored for Godot 3.x. This is not necessary if the Invert import option was used to invert the depth map in Godot 3.x, in which case [heightmapFlipTexture] should remain `false`. */ public final inline var heightmapFlipTexture: Boolean @JvmName("heightmapFlipTextureProperty") @@ -910,9 +782,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * If `true`, subsurface scattering is enabled. Emulates light that penetrates an object's - * surface, is scattered, and then emerges. Subsurface scattering quality is controlled by - * [ProjectSettings.rendering/environment/subsurfaceScattering/subsurfaceScatteringQuality]. + * If `true`, subsurface scattering is enabled. Emulates light that penetrates an object's surface, is scattered, and then emerges. Subsurface scattering quality is controlled by [ProjectSettings.rendering/environment/subsurfaceScattering/subsurfaceScatteringQuality]. */ public final inline var subsurfScatterEnabled: Boolean @JvmName("subsurfScatterEnabledProperty") @@ -923,9 +793,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * The strength of the subsurface scattering effect. The depth of the effect is also controlled by - * [ProjectSettings.rendering/environment/subsurfaceScattering/subsurfaceScatteringScale], which is - * set globally. + * The strength of the subsurface scattering effect. The depth of the effect is also controlled by [ProjectSettings.rendering/environment/subsurfaceScattering/subsurfaceScatteringScale], which is set globally. */ public final inline var subsurfScatterStrength: Float @JvmName("subsurfScatterStrengthProperty") @@ -936,8 +804,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * If `true`, subsurface scattering will use a special mode optimized for the color and density of - * human skin, such as boosting the intensity of the red channel in subsurface scattering. + * If `true`, subsurface scattering will use a special mode optimized for the color and density of human skin, such as boosting the intensity of the red channel in subsurface scattering. */ public final inline var subsurfScatterSkinMode: Boolean @JvmName("subsurfScatterSkinModeProperty") @@ -948,8 +815,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * Texture used to control the subsurface scattering strength. Stored in the red texture channel. - * Multiplied by [subsurfScatterStrength]. + * Texture used to control the subsurface scattering strength. Stored in the red texture channel. Multiplied by [subsurfScatterStrength]. */ public final inline var subsurfScatterTexture: Texture2D? @JvmName("subsurfScatterTextureProperty") @@ -960,8 +826,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * If `true`, enables subsurface scattering transmittance. Only effective if - * [subsurfScatterEnabled] is `true`. See also [backlightEnabled]. + * If `true`, enables subsurface scattering transmittance. Only effective if [subsurfScatterEnabled] is `true`. See also [backlightEnabled]. */ public final inline var subsurfScatterTransmittanceEnabled: Boolean @JvmName("subsurfScatterTransmittanceEnabledProperty") @@ -972,15 +837,11 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * The color to multiply the subsurface scattering transmittance effect with. Ignored if - * [subsurfScatterSkinMode] is `true`. + * The color to multiply the subsurface scattering transmittance effect with. Ignored if [subsurfScatterSkinMode] is `true`. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var subsurfScatterTransmittanceColor: Color @@ -992,8 +853,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * The texture to use for multiplying the intensity of the subsurface scattering transmittance - * intensity. See also [subsurfScatterTexture]. Ignored if [subsurfScatterSkinMode] is `true`. + * The texture to use for multiplying the intensity of the subsurface scattering transmittance intensity. See also [subsurfScatterTexture]. Ignored if [subsurfScatterSkinMode] is `true`. */ public final inline var subsurfScatterTransmittanceTexture: Texture2D? @JvmName("subsurfScatterTransmittanceTextureProperty") @@ -1040,11 +900,8 @@ public open class BaseMaterial3D internal constructor() : Material() { * The color used by the backlight effect. Represents the light passing through an object. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var backlight: Color @@ -1067,11 +924,9 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * If `true`, the refraction effect is enabled. Distorts transparency based on light from behind - * the object. + * If `true`, the refraction effect is enabled. Distorts transparency based on light from behind the object. * - * **Note:** Refraction is implemented using the screen texture. Only opaque materials will appear - * in the refraction, since transparent materials do not appear in the screen texture. + * **Note:** Refraction is implemented using the screen texture. Only opaque materials will appear in the refraction, since transparent materials do not appear in the screen texture. */ public final inline var refractionEnabled: Boolean @JvmName("refractionEnabledProperty") @@ -1093,8 +948,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * Texture that controls the strength of the refraction per-pixel. Multiplied by - * [refractionScale]. + * Texture that controls the strength of the refraction per-pixel. Multiplied by [refractionScale]. */ public final inline var refractionTexture: Texture2D? @JvmName("refractionTextureProperty") @@ -1105,10 +959,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * Specifies the channel of the [refractionTexture] in which the refraction information is stored. - * This is useful when you store the information for multiple effects in a single texture. For - * example if you stored refraction in the red channel, roughness in the blue, and ambient occlusion - * in the green you could reduce the number of textures you use. + * Specifies the channel of the [refractionTexture] in which the refraction information is stored. This is useful when you store the information for multiple effects in a single texture. For example if you stored refraction in the red channel, roughness in the blue, and ambient occlusion in the green you could reduce the number of textures you use. */ public final inline var refractionTextureChannel: TextureChannel @JvmName("refractionTextureChannelProperty") @@ -1119,9 +970,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * If `true`, enables the detail overlay. Detail is a second texture that gets mixed over the - * surface of the object based on [detailMask] and [detailAlbedo]'s alpha channel. This can be used - * to add variation to objects, or to blend between two different albedo/normal textures. + * If `true`, enables the detail overlay. Detail is a second texture that gets mixed over the surface of the object based on [detailMask] and [detailAlbedo]'s alpha channel. This can be used to add variation to objects, or to blend between two different albedo/normal textures. */ public final inline var detailEnabled: Boolean @JvmName("detailEnabledProperty") @@ -1132,8 +981,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * Texture used to specify how the detail textures get blended with the base textures. - * [detailMask] can be used together with [detailAlbedo]'s alpha channel (if any). + * Texture used to specify how the detail textures get blended with the base textures. [detailMask] can be used together with [detailAlbedo]'s alpha channel (if any). */ public final inline var detailMask: Texture2D? @JvmName("detailMaskProperty") @@ -1144,8 +992,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * Specifies how the [detailAlbedo] should blend with the current `ALBEDO`. See [BlendMode] for - * options. + * Specifies how the [detailAlbedo] should blend with the current `ALBEDO`. See [BlendMode] for options. */ public final inline var detailBlendMode: BlendMode @JvmName("detailBlendModeProperty") @@ -1167,9 +1014,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * Texture that specifies the color of the detail overlay. [detailAlbedo]'s alpha channel is used - * as a mask, even when the material is opaque. To use a dedicated texture as a mask, see - * [detailMask]. + * Texture that specifies the color of the detail overlay. [detailAlbedo]'s alpha channel is used as a mask, even when the material is opaque. To use a dedicated texture as a mask, see [detailMask]. * * **Note:** [detailAlbedo] is *not* modulated by [albedoColor]. */ @@ -1182,13 +1027,9 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * Texture that specifies the per-pixel normal of the detail overlay. The [detailNormal] texture - * only uses the red and green channels; the blue and alpha channels are ignored. The normal read - * from [detailNormal] is oriented around the surface normal provided by the [Mesh]. + * Texture that specifies the per-pixel normal of the detail overlay. The [detailNormal] texture only uses the red and green channels; the blue and alpha channels are ignored. The normal read from [detailNormal] is oriented around the surface normal provided by the [Mesh]. * - * **Note:** Godot expects the normal map to use X+, Y+, and Z+ coordinates. See - * [url=http://wiki.polycount.com/wiki/Normal_Map_Technical_Details#Common_Swizzle_Coordinates]this - * page[/url] for a comparison of normal map coordinates expected by popular engines. + * **Note:** Godot expects the normal map to use X+, Y+, and Z+ coordinates. See [url=http://wiki.polycount.com/wiki/Normal_Map_Technical_Details#Common_Swizzle_Coordinates]this page[/url] for a comparison of normal map coordinates expected by popular engines. */ public final inline var detailNormal: Texture2D? @JvmName("detailNormalProperty") @@ -1199,15 +1040,11 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * How much to scale the `UV` coordinates. This is multiplied by `UV` in the vertex function. The - * Z component is used when [uv1Triplanar] is enabled, but it is not used anywhere else. + * How much to scale the `UV` coordinates. This is multiplied by `UV` in the vertex function. The Z component is used when [uv1Triplanar] is enabled, but it is not used anywhere else. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var uv1Scale: Vector3 @@ -1219,16 +1056,11 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * How much to offset the `UV` coordinates. This amount will be added to `UV` in the vertex - * function. This can be used to offset a texture. The Z component is used when [uv1Triplanar] is - * enabled, but it is not used anywhere else. + * How much to offset the `UV` coordinates. This amount will be added to `UV` in the vertex function. This can be used to offset a texture. The Z component is used when [uv1Triplanar] is enabled, but it is not used anywhere else. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var uv1Offset: Vector3 @@ -1240,14 +1072,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * If `true`, instead of using `UV` textures will use a triplanar texture lookup to determine how - * to apply textures. Triplanar uses the orientation of the object's surface to blend between texture - * coordinates. It reads from the source texture 3 times, once for each axis and then blends between - * the results based on how closely the pixel aligns with each axis. This is often used for natural - * features to get a realistic blend of materials. Because triplanar texturing requires many more - * texture reads per-pixel it is much slower than normal UV texturing. Additionally, because it is - * blending the texture between the three axes, it is unsuitable when you are trying to achieve crisp - * texturing. + * If `true`, instead of using `UV` textures will use a triplanar texture lookup to determine how to apply textures. Triplanar uses the orientation of the object's surface to blend between texture coordinates. It reads from the source texture 3 times, once for each axis and then blends between the results based on how closely the pixel aligns with each axis. This is often used for natural features to get a realistic blend of materials. Because triplanar texturing requires many more texture reads per-pixel it is much slower than normal UV texturing. Additionally, because it is blending the texture between the three axes, it is unsuitable when you are trying to achieve crisp texturing. */ public final inline var uv1Triplanar: Boolean @JvmName("uv1TriplanarProperty") @@ -1258,11 +1083,9 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * A lower number blends the texture more softly while a higher number blends the texture more - * sharply. + * A lower number blends the texture more softly while a higher number blends the texture more sharply. * - * **Note:** [uv1TriplanarSharpness] is clamped between `0.0` and `150.0` (inclusive) as values - * outside that range can look broken depending on the mesh. + * **Note:** [uv1TriplanarSharpness] is clamped between `0.0` and `150.0` (inclusive) as values outside that range can look broken depending on the mesh. */ public final inline var uv1TriplanarSharpness: Float @JvmName("uv1TriplanarSharpnessProperty") @@ -1273,8 +1096,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * If `true`, triplanar mapping for `UV` is calculated in world space rather than object local - * space. See also [uv1Triplanar]. + * If `true`, triplanar mapping for `UV` is calculated in world space rather than object local space. See also [uv1Triplanar]. */ public final inline var uv1WorldTriplanar: Boolean @JvmName("uv1WorldTriplanarProperty") @@ -1285,15 +1107,11 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * How much to scale the `UV2` coordinates. This is multiplied by `UV2` in the vertex function. - * The Z component is used when [uv2Triplanar] is enabled, but it is not used anywhere else. + * How much to scale the `UV2` coordinates. This is multiplied by `UV2` in the vertex function. The Z component is used when [uv2Triplanar] is enabled, but it is not used anywhere else. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var uv2Scale: Vector3 @@ -1305,16 +1123,11 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * How much to offset the `UV2` coordinates. This amount will be added to `UV2` in the vertex - * function. This can be used to offset a texture. The Z component is used when [uv2Triplanar] is - * enabled, but it is not used anywhere else. + * How much to offset the `UV2` coordinates. This amount will be added to `UV2` in the vertex function. This can be used to offset a texture. The Z component is used when [uv2Triplanar] is enabled, but it is not used anywhere else. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var uv2Offset: Vector3 @@ -1326,14 +1139,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * If `true`, instead of using `UV2` textures will use a triplanar texture lookup to determine how - * to apply textures. Triplanar uses the orientation of the object's surface to blend between texture - * coordinates. It reads from the source texture 3 times, once for each axis and then blends between - * the results based on how closely the pixel aligns with each axis. This is often used for natural - * features to get a realistic blend of materials. Because triplanar texturing requires many more - * texture reads per-pixel it is much slower than normal UV texturing. Additionally, because it is - * blending the texture between the three axes, it is unsuitable when you are trying to achieve crisp - * texturing. + * If `true`, instead of using `UV2` textures will use a triplanar texture lookup to determine how to apply textures. Triplanar uses the orientation of the object's surface to blend between texture coordinates. It reads from the source texture 3 times, once for each axis and then blends between the results based on how closely the pixel aligns with each axis. This is often used for natural features to get a realistic blend of materials. Because triplanar texturing requires many more texture reads per-pixel it is much slower than normal UV texturing. Additionally, because it is blending the texture between the three axes, it is unsuitable when you are trying to achieve crisp texturing. */ public final inline var uv2Triplanar: Boolean @JvmName("uv2TriplanarProperty") @@ -1344,11 +1150,9 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * A lower number blends the texture more softly while a higher number blends the texture more - * sharply. + * A lower number blends the texture more softly while a higher number blends the texture more sharply. * - * **Note:** [uv2TriplanarSharpness] is clamped between `0.0` and `150.0` (inclusive) as values - * outside that range can look broken depending on the mesh. + * **Note:** [uv2TriplanarSharpness] is clamped between `0.0` and `150.0` (inclusive) as values outside that range can look broken depending on the mesh. */ public final inline var uv2TriplanarSharpness: Float @JvmName("uv2TriplanarSharpnessProperty") @@ -1359,8 +1163,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * If `true`, triplanar mapping for `UV2` is calculated in world space rather than object local - * space. See also [uv2Triplanar]. + * If `true`, triplanar mapping for `UV2` is calculated in world space rather than object local space. See also [uv2Triplanar]. */ public final inline var uv2WorldTriplanar: Boolean @JvmName("uv2WorldTriplanarProperty") @@ -1373,10 +1176,7 @@ public open class BaseMaterial3D internal constructor() : Material() { /** * Filter flags for the texture. See [TextureFilter] for options. * - * **Note:** [heightmapTexture] is always sampled with linear filtering, even if nearest-neighbor - * filtering is selected here. This is to ensure the heightmap effect looks as intended. If you need - * sharper height transitions between pixels, resize the heightmap texture in an image editor with - * nearest-neighbor filtering. + * **Note:** [heightmapTexture] is always sampled with linear filtering, even if nearest-neighbor filtering is selected here. This is to ensure the heightmap effect looks as intended. If you need sharper height transitions between pixels, resize the heightmap texture in an image editor with nearest-neighbor filtering. */ public final inline var textureFilter: TextureFilter @JvmName("textureFilterProperty") @@ -1409,9 +1209,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * If `true`, enables the "shadow to opacity" render mode where lighting modifies the alpha so - * shadowed areas are opaque and non-shadowed areas are transparent. Useful for overlaying shadows - * onto a camera feed in AR. + * If `true`, enables the "shadow to opacity" render mode where lighting modifies the alpha so shadowed areas are opaque and non-shadowed areas are transparent. Useful for overlaying shadows onto a camera feed in AR. */ public final inline var shadowToOpacity: Boolean @JvmName("shadowToOpacityProperty") @@ -1424,9 +1222,7 @@ public open class BaseMaterial3D internal constructor() : Material() { /** * Controls how the object faces the camera. See [BillboardMode]. * - * **Note:** Billboard mode is not suitable for VR because the left-right vector of the camera is - * not horizontal when the screen is attached to your head instead of on the table. See - * [url=https://github.com/godotengine/godot/issues/41567]GitHub issue #41567[/url] for details. + * **Note:** Billboard mode is not suitable for VR because the left-right vector of the camera is not horizontal when the screen is attached to your head instead of on the table. See [url=https://github.com/godotengine/godot/issues/41567]GitHub issue #41567[/url] for details. */ public final inline var billboardMode: BillboardMode @JvmName("billboardModeProperty") @@ -1437,8 +1233,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * If `true`, the shader will keep the scale set for the mesh. Otherwise, the scale is lost when - * billboarding. Only applies when [billboardMode] is not [BILLBOARD_DISABLED]. + * If `true`, the shader will keep the scale set for the mesh. Otherwise, the scale is lost when billboarding. Only applies when [billboardMode] is not [BILLBOARD_DISABLED]. */ public final inline var billboardKeepScale: Boolean @JvmName("billboardKeepScaleProperty") @@ -1449,8 +1244,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * The number of horizontal frames in the particle sprite sheet. Only enabled when using - * [BILLBOARD_PARTICLES]. See [billboardMode]. + * The number of horizontal frames in the particle sprite sheet. Only enabled when using [BILLBOARD_PARTICLES]. See [billboardMode]. */ public final inline var particlesAnimHFrames: Int @JvmName("particlesAnimHFramesProperty") @@ -1461,8 +1255,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * The number of vertical frames in the particle sprite sheet. Only enabled when using - * [BILLBOARD_PARTICLES]. See [billboardMode]. + * The number of vertical frames in the particle sprite sheet. Only enabled when using [BILLBOARD_PARTICLES]. See [billboardMode]. */ public final inline var particlesAnimVFrames: Int @JvmName("particlesAnimVFramesProperty") @@ -1473,8 +1266,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * If `true`, particle animations are looped. Only enabled when using [BILLBOARD_PARTICLES]. See - * [billboardMode]. + * If `true`, particle animations are looped. Only enabled when using [BILLBOARD_PARTICLES]. See [billboardMode]. */ public final inline var particlesAnimLoop: Boolean @JvmName("particlesAnimLoopProperty") @@ -1485,14 +1277,9 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * If `true`, enables the vertex grow setting. This can be used to create mesh-based outlines - * using a second material pass and its [cullMode] set to [CULL_FRONT]. See also [growAmount]. + * If `true`, enables the vertex grow setting. This can be used to create mesh-based outlines using a second material pass and its [cullMode] set to [CULL_FRONT]. See also [growAmount]. * - * **Note:** Vertex growth cannot create new vertices, which means that visible gaps may occur in - * sharp corners. This can be alleviated by designing the mesh to use smooth normals exclusively - * using [url=http://wiki.polycount.com/wiki/Face_weighted_normals]face weighted normals[/url] in the - * 3D authoring software. In this case, grow will be able to join every outline together, just like - * in the original mesh. + * **Note:** Vertex growth cannot create new vertices, which means that visible gaps may occur in sharp corners. This can be alleviated by designing the mesh to use smooth normals exclusively using [url=http://wiki.polycount.com/wiki/Face_weighted_normals]face weighted normals[/url] in the 3D authoring software. In this case, grow will be able to join every outline together, just like in the original mesh. */ public final inline var grow: Boolean @JvmName("growProperty") @@ -1527,8 +1314,7 @@ public open class BaseMaterial3D internal constructor() : Material() { /** * If `true`, render point size can be changed. * - * **Note:** This is only effective for objects whose geometry is point-based rather than - * triangle-based. See also [pointSize]. + * **Note:** This is only effective for objects whose geometry is point-based rather than triangle-based. See also [pointSize]. */ public final inline var usePointSize: Boolean @JvmName("usePointSizeProperty") @@ -1550,10 +1336,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * If `true`, enables parts of the shader required for [GPUParticles3D] trails to function. This - * also requires using a mesh with appropriate skinning, such as [RibbonTrailMesh] or - * [TubeTrailMesh]. Enabling this feature outside of materials used in [GPUParticles3D] meshes will - * break material rendering. + * If `true`, enables parts of the shader required for [GPUParticles3D] trails to function. This also requires using a mesh with appropriate skinning, such as [RibbonTrailMesh] or [TubeTrailMesh]. Enabling this feature outside of materials used in [GPUParticles3D] meshes will break material rendering. */ public final inline var useParticleTrails: Boolean @JvmName("useParticleTrailsProperty") @@ -1564,8 +1347,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * If `true`, the proximity fade effect is enabled. The proximity fade effect fades out each pixel - * based on its distance to another object. + * If `true`, the proximity fade effect is enabled. The proximity fade effect fades out each pixel based on its distance to another object. */ public final inline var proximityFadeEnabled: Boolean @JvmName("proximityFadeEnabledProperty") @@ -1576,8 +1358,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * Distance over which the fade effect takes place. The larger the distance the longer it takes - * for an object to fade. + * Distance over which the fade effect takes place. The larger the distance the longer it takes for an object to fade. */ public final inline var proximityFadeDistance: Float @JvmName("proximityFadeDistanceProperty") @@ -1588,8 +1369,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * The width of the range around the shape between the minimum and maximum representable signed - * distance. + * The width of the range around the shape between the minimum and maximum representable signed distance. */ public final inline var msdfPixelRange: Float @JvmName("msdfPixelRangeProperty") @@ -1622,12 +1402,9 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * Distance at which the object starts to become visible. If the object is less than this distance - * away, it will be invisible. + * Distance at which the object starts to become visible. If the object is less than this distance away, it will be invisible. * - * **Note:** If [distanceFadeMinDistance] is greater than [distanceFadeMaxDistance], the behavior - * will be reversed. The object will start to fade away at [distanceFadeMaxDistance] and will fully - * disappear once it reaches [distanceFadeMinDistance]. + * **Note:** If [distanceFadeMinDistance] is greater than [distanceFadeMaxDistance], the behavior will be reversed. The object will start to fade away at [distanceFadeMaxDistance] and will fully disappear once it reaches [distanceFadeMinDistance]. */ public final inline var distanceFadeMinDistance: Float @JvmName("distanceFadeMinDistanceProperty") @@ -1640,9 +1417,7 @@ public open class BaseMaterial3D internal constructor() : Material() { /** * Distance at which the object appears fully opaque. * - * **Note:** If [distanceFadeMaxDistance] is less than [distanceFadeMinDistance], the behavior - * will be reversed. The object will start to fade away at [distanceFadeMaxDistance] and will fully - * disappear once it reaches [distanceFadeMinDistance]. + * **Note:** If [distanceFadeMaxDistance] is less than [distanceFadeMinDistance], the behavior will be reversed. The object will start to fade away at [distanceFadeMaxDistance] and will fully disappear once it reaches [distanceFadeMinDistance]. */ public final inline var distanceFadeMaxDistance: Float @JvmName("distanceFadeMaxDistanceProperty") @@ -1652,7 +1427,7 @@ public open class BaseMaterial3D internal constructor() : Material() { setDistanceFadeMaxDistance(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(104, scriptIndex) } @@ -1669,9 +1444,7 @@ public open class BaseMaterial3D internal constructor() : Material() { * * The material's base color. * - * **Note:** If [detailEnabled] is `true` and a [detailAlbedo] texture is specified, [albedoColor] - * will *not* modulate the detail texture. This can be used to color partial areas of a material by - * not specifying an albedo texture and using a transparent [detailAlbedo] texture instead. + * **Note:** If [detailEnabled] is `true` and a [detailAlbedo] texture is specified, [albedoColor] will *not* modulate the detail texture. This can be used to color partial areas of a material by not specifying an albedo texture and using a transparent [detailAlbedo] texture instead. */ @CoreTypeHelper public final fun albedoColorMutate(block: Color.() -> Unit): Color = albedoColor.apply { @@ -1699,8 +1472,7 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * This is a helper function for [subsurfScatterTransmittanceColor] to make dealing with local - * copies easier. + * This is a helper function for [subsurfScatterTransmittanceColor] to make dealing with local copies easier. * Allow to directly modify the local copy of the property and assign it back to the Object. * * Prefer that over writing: @@ -1710,12 +1482,10 @@ public open class BaseMaterial3D internal constructor() : Material() { * basematerial3d.subsurfScatterTransmittanceColor = myCoreType * `````` * - * The color to multiply the subsurface scattering transmittance effect with. Ignored if - * [subsurfScatterSkinMode] is `true`. + * The color to multiply the subsurface scattering transmittance effect with. Ignored if [subsurfScatterSkinMode] is `true`. */ @CoreTypeHelper - public final fun subsurfScatterTransmittanceColorMutate(block: Color.() -> Unit): Color = - subsurfScatterTransmittanceColor.apply { + public final fun subsurfScatterTransmittanceColorMutate(block: Color.() -> Unit): Color = subsurfScatterTransmittanceColor.apply { block(this) subsurfScatterTransmittanceColor = this } @@ -1750,8 +1520,7 @@ public open class BaseMaterial3D internal constructor() : Material() { * basematerial3d.uv1Scale = myCoreType * `````` * - * How much to scale the `UV` coordinates. This is multiplied by `UV` in the vertex function. The - * Z component is used when [uv1Triplanar] is enabled, but it is not used anywhere else. + * How much to scale the `UV` coordinates. This is multiplied by `UV` in the vertex function. The Z component is used when [uv1Triplanar] is enabled, but it is not used anywhere else. */ @CoreTypeHelper public final fun uv1ScaleMutate(block: Vector3.() -> Unit): Vector3 = uv1Scale.apply { @@ -1770,9 +1539,7 @@ public open class BaseMaterial3D internal constructor() : Material() { * basematerial3d.uv1Offset = myCoreType * `````` * - * How much to offset the `UV` coordinates. This amount will be added to `UV` in the vertex - * function. This can be used to offset a texture. The Z component is used when [uv1Triplanar] is - * enabled, but it is not used anywhere else. + * How much to offset the `UV` coordinates. This amount will be added to `UV` in the vertex function. This can be used to offset a texture. The Z component is used when [uv1Triplanar] is enabled, but it is not used anywhere else. */ @CoreTypeHelper public final fun uv1OffsetMutate(block: Vector3.() -> Unit): Vector3 = uv1Offset.apply { @@ -1791,8 +1558,7 @@ public open class BaseMaterial3D internal constructor() : Material() { * basematerial3d.uv2Scale = myCoreType * `````` * - * How much to scale the `UV2` coordinates. This is multiplied by `UV2` in the vertex function. - * The Z component is used when [uv2Triplanar] is enabled, but it is not used anywhere else. + * How much to scale the `UV2` coordinates. This is multiplied by `UV2` in the vertex function. The Z component is used when [uv2Triplanar] is enabled, but it is not used anywhere else. */ @CoreTypeHelper public final fun uv2ScaleMutate(block: Vector3.() -> Unit): Vector3 = uv2Scale.apply { @@ -1811,9 +1577,7 @@ public open class BaseMaterial3D internal constructor() : Material() { * basematerial3d.uv2Offset = myCoreType * `````` * - * How much to offset the `UV2` coordinates. This amount will be added to `UV2` in the vertex - * function. This can be used to offset a texture. The Z component is used when [uv2Triplanar] is - * enabled, but it is not used anywhere else. + * How much to offset the `UV2` coordinates. This amount will be added to `UV2` in the vertex function. This can be used to offset a texture. The Z component is used when [uv2Triplanar] is enabled, but it is not used anywhere else. */ @CoreTypeHelper public final fun uv2OffsetMutate(block: Vector3.() -> Unit): Vector3 = uv2Offset.apply { @@ -1821,7 +1585,7 @@ public open class BaseMaterial3D internal constructor() : Material() { uv2Offset = this } - public final fun setAlbedo(albedo: Color): Unit { + public final fun setAlbedo(albedo: Color) { TransferContext.writeArguments(COLOR to albedo) TransferContext.callMethod(ptr, MethodBindings.setAlbedoPtr, NIL) } @@ -1832,7 +1596,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(COLOR) as Color) } - public final fun setTransparency(transparency: Transparency): Unit { + public final fun setTransparency(transparency: Transparency) { TransferContext.writeArguments(LONG to transparency.id) TransferContext.callMethod(ptr, MethodBindings.setTransparencyPtr, NIL) } @@ -1843,7 +1607,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return Transparency.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setAlphaAntialiasing(alphaAa: AlphaAntiAliasing): Unit { + public final fun setAlphaAntialiasing(alphaAa: AlphaAntiAliasing) { TransferContext.writeArguments(LONG to alphaAa.id) TransferContext.callMethod(ptr, MethodBindings.setAlphaAntialiasingPtr, NIL) } @@ -1854,7 +1618,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return AlphaAntiAliasing.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setAlphaAntialiasingEdge(edge: Float): Unit { + public final fun setAlphaAntialiasingEdge(edge: Float) { TransferContext.writeArguments(DOUBLE to edge.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setAlphaAntialiasingEdgePtr, NIL) } @@ -1865,7 +1629,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setShadingMode(shadingMode: ShadingMode): Unit { + public final fun setShadingMode(shadingMode: ShadingMode) { TransferContext.writeArguments(LONG to shadingMode.id) TransferContext.callMethod(ptr, MethodBindings.setShadingModePtr, NIL) } @@ -1876,7 +1640,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return ShadingMode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setSpecular(specular: Float): Unit { + public final fun setSpecular(specular: Float) { TransferContext.writeArguments(DOUBLE to specular.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setSpecularPtr, NIL) } @@ -1887,7 +1651,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setMetallic(metallic: Float): Unit { + public final fun setMetallic(metallic: Float) { TransferContext.writeArguments(DOUBLE to metallic.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setMetallicPtr, NIL) } @@ -1898,7 +1662,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setRoughness(roughness: Float): Unit { + public final fun setRoughness(roughness: Float) { TransferContext.writeArguments(DOUBLE to roughness.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setRoughnessPtr, NIL) } @@ -1909,7 +1673,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setEmission(emission: Color): Unit { + public final fun setEmission(emission: Color) { TransferContext.writeArguments(COLOR to emission) TransferContext.callMethod(ptr, MethodBindings.setEmissionPtr, NIL) } @@ -1920,7 +1684,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(COLOR) as Color) } - public final fun setEmissionEnergyMultiplier(emissionEnergyMultiplier: Float): Unit { + public final fun setEmissionEnergyMultiplier(emissionEnergyMultiplier: Float) { TransferContext.writeArguments(DOUBLE to emissionEnergyMultiplier.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setEmissionEnergyMultiplierPtr, NIL) } @@ -1931,7 +1695,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setEmissionIntensity(emissionEnergyMultiplier: Float): Unit { + public final fun setEmissionIntensity(emissionEnergyMultiplier: Float) { TransferContext.writeArguments(DOUBLE to emissionEnergyMultiplier.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setEmissionIntensityPtr, NIL) } @@ -1942,7 +1706,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setNormalScale(normalScale: Float): Unit { + public final fun setNormalScale(normalScale: Float) { TransferContext.writeArguments(DOUBLE to normalScale.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setNormalScalePtr, NIL) } @@ -1953,7 +1717,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setRim(rim: Float): Unit { + public final fun setRim(rim: Float) { TransferContext.writeArguments(DOUBLE to rim.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setRimPtr, NIL) } @@ -1964,7 +1728,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setRimTint(rimTint: Float): Unit { + public final fun setRimTint(rimTint: Float) { TransferContext.writeArguments(DOUBLE to rimTint.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setRimTintPtr, NIL) } @@ -1975,7 +1739,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setClearcoat(clearcoat: Float): Unit { + public final fun setClearcoat(clearcoat: Float) { TransferContext.writeArguments(DOUBLE to clearcoat.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setClearcoatPtr, NIL) } @@ -1986,7 +1750,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setClearcoatRoughness(clearcoatRoughness: Float): Unit { + public final fun setClearcoatRoughness(clearcoatRoughness: Float) { TransferContext.writeArguments(DOUBLE to clearcoatRoughness.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setClearcoatRoughnessPtr, NIL) } @@ -1997,7 +1761,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setAnisotropy(anisotropy: Float): Unit { + public final fun setAnisotropy(anisotropy: Float) { TransferContext.writeArguments(DOUBLE to anisotropy.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setAnisotropyPtr, NIL) } @@ -2008,7 +1772,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setHeightmapScale(heightmapScale: Float): Unit { + public final fun setHeightmapScale(heightmapScale: Float) { TransferContext.writeArguments(DOUBLE to heightmapScale.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setHeightmapScalePtr, NIL) } @@ -2019,7 +1783,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setSubsurfaceScatteringStrength(strength: Float): Unit { + public final fun setSubsurfaceScatteringStrength(strength: Float) { TransferContext.writeArguments(DOUBLE to strength.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setSubsurfaceScatteringStrengthPtr, NIL) } @@ -2030,7 +1794,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setTransmittanceColor(color: Color): Unit { + public final fun setTransmittanceColor(color: Color) { TransferContext.writeArguments(COLOR to color) TransferContext.callMethod(ptr, MethodBindings.setTransmittanceColorPtr, NIL) } @@ -2041,7 +1805,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(COLOR) as Color) } - public final fun setTransmittanceDepth(depth: Float): Unit { + public final fun setTransmittanceDepth(depth: Float) { TransferContext.writeArguments(DOUBLE to depth.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setTransmittanceDepthPtr, NIL) } @@ -2052,7 +1816,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setTransmittanceBoost(boost: Float): Unit { + public final fun setTransmittanceBoost(boost: Float) { TransferContext.writeArguments(DOUBLE to boost.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setTransmittanceBoostPtr, NIL) } @@ -2063,7 +1827,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setBacklight(backlight: Color): Unit { + public final fun setBacklight(backlight: Color) { TransferContext.writeArguments(COLOR to backlight) TransferContext.callMethod(ptr, MethodBindings.setBacklightPtr, NIL) } @@ -2074,7 +1838,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(COLOR) as Color) } - public final fun setRefraction(refraction: Float): Unit { + public final fun setRefraction(refraction: Float) { TransferContext.writeArguments(DOUBLE to refraction.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setRefractionPtr, NIL) } @@ -2085,7 +1849,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setPointSize(pointSize: Float): Unit { + public final fun setPointSize(pointSize: Float) { TransferContext.writeArguments(DOUBLE to pointSize.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setPointSizePtr, NIL) } @@ -2096,7 +1860,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setDetailUv(detailUv: DetailUV): Unit { + public final fun setDetailUv(detailUv: DetailUV) { TransferContext.writeArguments(LONG to detailUv.id) TransferContext.callMethod(ptr, MethodBindings.setDetailUvPtr, NIL) } @@ -2107,7 +1871,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return DetailUV.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setBlendMode(blendMode: BlendMode): Unit { + public final fun setBlendMode(blendMode: BlendMode) { TransferContext.writeArguments(LONG to blendMode.id) TransferContext.callMethod(ptr, MethodBindings.setBlendModePtr, NIL) } @@ -2118,7 +1882,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return BlendMode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setDepthDrawMode(depthDrawMode: DepthDrawMode): Unit { + public final fun setDepthDrawMode(depthDrawMode: DepthDrawMode) { TransferContext.writeArguments(LONG to depthDrawMode.id) TransferContext.callMethod(ptr, MethodBindings.setDepthDrawModePtr, NIL) } @@ -2129,7 +1893,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return DepthDrawMode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setCullMode(cullMode: CullMode): Unit { + public final fun setCullMode(cullMode: CullMode) { TransferContext.writeArguments(LONG to cullMode.id) TransferContext.callMethod(ptr, MethodBindings.setCullModePtr, NIL) } @@ -2140,7 +1904,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return CullMode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setDiffuseMode(diffuseMode: DiffuseMode): Unit { + public final fun setDiffuseMode(diffuseMode: DiffuseMode) { TransferContext.writeArguments(LONG to diffuseMode.id) TransferContext.callMethod(ptr, MethodBindings.setDiffuseModePtr, NIL) } @@ -2151,7 +1915,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return DiffuseMode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setSpecularMode(specularMode: SpecularMode): Unit { + public final fun setSpecularMode(specularMode: SpecularMode) { TransferContext.writeArguments(LONG to specularMode.id) TransferContext.callMethod(ptr, MethodBindings.setSpecularModePtr, NIL) } @@ -2163,12 +1927,9 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * If `true`, enables the specified flag. Flags are optional behavior that can be turned on and - * off. Only one flag can be enabled at a time with this function, the flag enumerators cannot be - * bit-masked together to enable or disable multiple flags at once. Flags can also be enabled by - * setting the corresponding member to `true`. See [Flags] enumerator for options. + * If `true`, enables the specified flag. Flags are optional behavior that can be turned on and off. Only one flag can be enabled at a time with this function, the flag enumerators cannot be bit-masked together to enable or disable multiple flags at once. Flags can also be enabled by setting the corresponding member to `true`. See [Flags] enumerator for options. */ - public final fun setFlag(flag: Flags, enable: Boolean): Unit { + public final fun setFlag(flag: Flags, enable: Boolean) { TransferContext.writeArguments(LONG to flag.id, BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setFlagPtr, NIL) } @@ -2182,7 +1943,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setTextureFilter(mode: TextureFilter): Unit { + public final fun setTextureFilter(mode: TextureFilter) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setTextureFilterPtr, NIL) } @@ -2194,12 +1955,9 @@ public open class BaseMaterial3D internal constructor() : Material() { } /** - * If `true`, enables the specified [Feature]. Many features that are available in - * [BaseMaterial3D]s need to be enabled before use. This way the cost for using the feature is only - * incurred when specified. Features can also be enabled by setting the corresponding member to - * `true`. + * If `true`, enables the specified [Feature]. Many features that are available in [BaseMaterial3D]s need to be enabled before use. This way the cost for using the feature is only incurred when specified. Features can also be enabled by setting the corresponding member to `true`. */ - public final fun setFeature(feature: Feature, enable: Boolean): Unit { + public final fun setFeature(feature: Feature, enable: Boolean) { TransferContext.writeArguments(LONG to feature.id, BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setFeaturePtr, NIL) } @@ -2216,7 +1974,7 @@ public open class BaseMaterial3D internal constructor() : Material() { /** * Sets the texture for the slot specified by [param]. See [TextureParam] for available slots. */ - public final fun setTexture(`param`: TextureParam, texture: Texture2D?): Unit { + public final fun setTexture(`param`: TextureParam, texture: Texture2D?) { TransferContext.writeArguments(LONG to param.id, OBJECT to texture) TransferContext.callMethod(ptr, MethodBindings.setTexturePtr, NIL) } @@ -2230,7 +1988,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(OBJECT) as Texture2D?) } - public final fun setDetailBlendMode(detailBlendMode: BlendMode): Unit { + public final fun setDetailBlendMode(detailBlendMode: BlendMode) { TransferContext.writeArguments(LONG to detailBlendMode.id) TransferContext.callMethod(ptr, MethodBindings.setDetailBlendModePtr, NIL) } @@ -2241,7 +1999,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return BlendMode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setUv1Scale(scale: Vector3): Unit { + public final fun setUv1Scale(scale: Vector3) { TransferContext.writeArguments(VECTOR3 to scale) TransferContext.callMethod(ptr, MethodBindings.setUv1ScalePtr, NIL) } @@ -2252,7 +2010,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(VECTOR3) as Vector3) } - public final fun setUv1Offset(offset: Vector3): Unit { + public final fun setUv1Offset(offset: Vector3) { TransferContext.writeArguments(VECTOR3 to offset) TransferContext.callMethod(ptr, MethodBindings.setUv1OffsetPtr, NIL) } @@ -2263,7 +2021,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(VECTOR3) as Vector3) } - public final fun setUv1TriplanarBlendSharpness(sharpness: Float): Unit { + public final fun setUv1TriplanarBlendSharpness(sharpness: Float) { TransferContext.writeArguments(DOUBLE to sharpness.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setUv1TriplanarBlendSharpnessPtr, NIL) } @@ -2274,7 +2032,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setUv2Scale(scale: Vector3): Unit { + public final fun setUv2Scale(scale: Vector3) { TransferContext.writeArguments(VECTOR3 to scale) TransferContext.callMethod(ptr, MethodBindings.setUv2ScalePtr, NIL) } @@ -2285,7 +2043,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(VECTOR3) as Vector3) } - public final fun setUv2Offset(offset: Vector3): Unit { + public final fun setUv2Offset(offset: Vector3) { TransferContext.writeArguments(VECTOR3 to offset) TransferContext.callMethod(ptr, MethodBindings.setUv2OffsetPtr, NIL) } @@ -2296,7 +2054,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(VECTOR3) as Vector3) } - public final fun setUv2TriplanarBlendSharpness(sharpness: Float): Unit { + public final fun setUv2TriplanarBlendSharpness(sharpness: Float) { TransferContext.writeArguments(DOUBLE to sharpness.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setUv2TriplanarBlendSharpnessPtr, NIL) } @@ -2307,7 +2065,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setBillboardMode(mode: BillboardMode): Unit { + public final fun setBillboardMode(mode: BillboardMode) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setBillboardModePtr, NIL) } @@ -2318,7 +2076,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return BillboardMode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setParticlesAnimHFrames(frames: Int): Unit { + public final fun setParticlesAnimHFrames(frames: Int) { TransferContext.writeArguments(LONG to frames.toLong()) TransferContext.callMethod(ptr, MethodBindings.setParticlesAnimHFramesPtr, NIL) } @@ -2329,7 +2087,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setParticlesAnimVFrames(frames: Int): Unit { + public final fun setParticlesAnimVFrames(frames: Int) { TransferContext.writeArguments(LONG to frames.toLong()) TransferContext.callMethod(ptr, MethodBindings.setParticlesAnimVFramesPtr, NIL) } @@ -2340,7 +2098,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setParticlesAnimLoop(loop: Boolean): Unit { + public final fun setParticlesAnimLoop(loop: Boolean) { TransferContext.writeArguments(BOOL to loop) TransferContext.callMethod(ptr, MethodBindings.setParticlesAnimLoopPtr, NIL) } @@ -2351,7 +2109,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setHeightmapDeepParallax(enable: Boolean): Unit { + public final fun setHeightmapDeepParallax(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setHeightmapDeepParallaxPtr, NIL) } @@ -2362,7 +2120,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setHeightmapDeepParallaxMinLayers(layer: Int): Unit { + public final fun setHeightmapDeepParallaxMinLayers(layer: Int) { TransferContext.writeArguments(LONG to layer.toLong()) TransferContext.callMethod(ptr, MethodBindings.setHeightmapDeepParallaxMinLayersPtr, NIL) } @@ -2373,7 +2131,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setHeightmapDeepParallaxMaxLayers(layer: Int): Unit { + public final fun setHeightmapDeepParallaxMaxLayers(layer: Int) { TransferContext.writeArguments(LONG to layer.toLong()) TransferContext.callMethod(ptr, MethodBindings.setHeightmapDeepParallaxMaxLayersPtr, NIL) } @@ -2384,7 +2142,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setHeightmapDeepParallaxFlipTangent(flip: Boolean): Unit { + public final fun setHeightmapDeepParallaxFlipTangent(flip: Boolean) { TransferContext.writeArguments(BOOL to flip) TransferContext.callMethod(ptr, MethodBindings.setHeightmapDeepParallaxFlipTangentPtr, NIL) } @@ -2395,7 +2153,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setHeightmapDeepParallaxFlipBinormal(flip: Boolean): Unit { + public final fun setHeightmapDeepParallaxFlipBinormal(flip: Boolean) { TransferContext.writeArguments(BOOL to flip) TransferContext.callMethod(ptr, MethodBindings.setHeightmapDeepParallaxFlipBinormalPtr, NIL) } @@ -2406,7 +2164,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setGrow(amount: Float): Unit { + public final fun setGrow(amount: Float) { TransferContext.writeArguments(DOUBLE to amount.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setGrowPtr, NIL) } @@ -2417,7 +2175,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setEmissionOperator(`operator`: EmissionOperator): Unit { + public final fun setEmissionOperator(`operator`: EmissionOperator) { TransferContext.writeArguments(LONG to `operator`.id) TransferContext.callMethod(ptr, MethodBindings.setEmissionOperatorPtr, NIL) } @@ -2428,7 +2186,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return EmissionOperator.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setAoLightAffect(amount: Float): Unit { + public final fun setAoLightAffect(amount: Float) { TransferContext.writeArguments(DOUBLE to amount.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setAoLightAffectPtr, NIL) } @@ -2439,7 +2197,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setAlphaScissorThreshold(threshold: Float): Unit { + public final fun setAlphaScissorThreshold(threshold: Float) { TransferContext.writeArguments(DOUBLE to threshold.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setAlphaScissorThresholdPtr, NIL) } @@ -2450,7 +2208,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setAlphaHashScale(threshold: Float): Unit { + public final fun setAlphaHashScale(threshold: Float) { TransferContext.writeArguments(DOUBLE to threshold.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setAlphaHashScalePtr, NIL) } @@ -2461,7 +2219,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setGrowEnabled(enable: Boolean): Unit { + public final fun setGrowEnabled(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setGrowEnabledPtr, NIL) } @@ -2472,7 +2230,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setMetallicTextureChannel(channel: TextureChannel): Unit { + public final fun setMetallicTextureChannel(channel: TextureChannel) { TransferContext.writeArguments(LONG to channel.id) TransferContext.callMethod(ptr, MethodBindings.setMetallicTextureChannelPtr, NIL) } @@ -2483,7 +2241,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return TextureChannel.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setRoughnessTextureChannel(channel: TextureChannel): Unit { + public final fun setRoughnessTextureChannel(channel: TextureChannel) { TransferContext.writeArguments(LONG to channel.id) TransferContext.callMethod(ptr, MethodBindings.setRoughnessTextureChannelPtr, NIL) } @@ -2494,7 +2252,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return TextureChannel.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setAoTextureChannel(channel: TextureChannel): Unit { + public final fun setAoTextureChannel(channel: TextureChannel) { TransferContext.writeArguments(LONG to channel.id) TransferContext.callMethod(ptr, MethodBindings.setAoTextureChannelPtr, NIL) } @@ -2505,7 +2263,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return TextureChannel.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setRefractionTextureChannel(channel: TextureChannel): Unit { + public final fun setRefractionTextureChannel(channel: TextureChannel) { TransferContext.writeArguments(LONG to channel.id) TransferContext.callMethod(ptr, MethodBindings.setRefractionTextureChannelPtr, NIL) } @@ -2516,7 +2274,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return TextureChannel.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setProximityFadeEnabled(enabled: Boolean): Unit { + public final fun setProximityFadeEnabled(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setProximityFadeEnabledPtr, NIL) } @@ -2527,7 +2285,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setProximityFadeDistance(distance: Float): Unit { + public final fun setProximityFadeDistance(distance: Float) { TransferContext.writeArguments(DOUBLE to distance.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setProximityFadeDistancePtr, NIL) } @@ -2538,7 +2296,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setMsdfPixelRange(range: Float): Unit { + public final fun setMsdfPixelRange(range: Float) { TransferContext.writeArguments(DOUBLE to range.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setMsdfPixelRangePtr, NIL) } @@ -2549,7 +2307,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setMsdfOutlineSize(size: Float): Unit { + public final fun setMsdfOutlineSize(size: Float) { TransferContext.writeArguments(DOUBLE to size.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setMsdfOutlineSizePtr, NIL) } @@ -2560,7 +2318,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setDistanceFade(mode: DistanceFadeMode): Unit { + public final fun setDistanceFade(mode: DistanceFadeMode) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setDistanceFadePtr, NIL) } @@ -2571,7 +2329,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return DistanceFadeMode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setDistanceFadeMaxDistance(distance: Float): Unit { + public final fun setDistanceFadeMaxDistance(distance: Float) { TransferContext.writeArguments(DOUBLE to distance.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setDistanceFadeMaxDistancePtr, NIL) } @@ -2582,7 +2340,7 @@ public open class BaseMaterial3D internal constructor() : Material() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setDistanceFadeMinDistance(distance: Float): Unit { + public final fun setDistanceFadeMinDistance(distance: Float) { TransferContext.writeArguments(DOUBLE to distance.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setDistanceFadeMinDistancePtr, NIL) } @@ -2596,14 +2354,14 @@ public open class BaseMaterial3D internal constructor() : Material() { /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _getShaderRid(): RID { + override fun _getShaderRid(): RID { throw NotImplementedError("BaseMaterial3D::_getShaderRid can't be called from the JVM.") } /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _getShaderMode(): Shader.Mode { + override fun _getShaderMode(): Shader.Mode { throw NotImplementedError("BaseMaterial3D::_getShaderMode can't be called from the JVM.") } @@ -2702,47 +2460,27 @@ public open class BaseMaterial3D internal constructor() : Material() { id: Long, ) { /** - * The texture filter reads from the nearest pixel only. This makes the texture look pixelated - * from up close, and grainy from a distance (due to mipmaps not being sampled). + * The texture filter reads from the nearest pixel only. This makes the texture look pixelated from up close, and grainy from a distance (due to mipmaps not being sampled). */ NEAREST(0), /** - * The texture filter blends between the nearest 4 pixels. This makes the texture look smooth - * from up close, and grainy from a distance (due to mipmaps not being sampled). + * The texture filter blends between the nearest 4 pixels. This makes the texture look smooth from up close, and grainy from a distance (due to mipmaps not being sampled). */ LINEAR(1), /** - * The texture filter reads from the nearest pixel and blends between the nearest 2 mipmaps (or - * uses the nearest mipmap if - * [ProjectSettings.rendering/textures/defaultFilters/useNearestMipmapFilter] is `true`). This - * makes the texture look pixelated from up close, and smooth from a distance. + * The texture filter reads from the nearest pixel and blends between the nearest 2 mipmaps (or uses the nearest mipmap if [ProjectSettings.rendering/textures/defaultFilters/useNearestMipmapFilter] is `true`). This makes the texture look pixelated from up close, and smooth from a distance. */ NEAREST_WITH_MIPMAPS(2), /** - * The texture filter blends between the nearest 4 pixels and between the nearest 2 mipmaps (or - * uses the nearest mipmap if - * [ProjectSettings.rendering/textures/defaultFilters/useNearestMipmapFilter] is `true`). This - * makes the texture look smooth from up close, and smooth from a distance. + * The texture filter blends between the nearest 4 pixels and between the nearest 2 mipmaps (or uses the nearest mipmap if [ProjectSettings.rendering/textures/defaultFilters/useNearestMipmapFilter] is `true`). This makes the texture look smooth from up close, and smooth from a distance. */ LINEAR_WITH_MIPMAPS(3), /** - * The texture filter reads from the nearest pixel and blends between 2 mipmaps (or uses the - * nearest mipmap if [ProjectSettings.rendering/textures/defaultFilters/useNearestMipmapFilter] is - * `true`) based on the angle between the surface and the camera view. This makes the texture look - * pixelated from up close, and smooth from a distance. Anisotropic filtering improves texture - * quality on surfaces that are almost in line with the camera, but is slightly slower. The - * anisotropic filtering level can be changed by adjusting - * [ProjectSettings.rendering/textures/defaultFilters/anisotropicFilteringLevel]. + * The texture filter reads from the nearest pixel and blends between 2 mipmaps (or uses the nearest mipmap if [ProjectSettings.rendering/textures/defaultFilters/useNearestMipmapFilter] is `true`) based on the angle between the surface and the camera view. This makes the texture look pixelated from up close, and smooth from a distance. Anisotropic filtering improves texture quality on surfaces that are almost in line with the camera, but is slightly slower. The anisotropic filtering level can be changed by adjusting [ProjectSettings.rendering/textures/defaultFilters/anisotropicFilteringLevel]. */ NEAREST_WITH_MIPMAPS_ANISOTROPIC(4), /** - * The texture filter blends between the nearest 4 pixels and blends between 2 mipmaps (or uses - * the nearest mipmap if [ProjectSettings.rendering/textures/defaultFilters/useNearestMipmapFilter] - * is `true`) based on the angle between the surface and the camera view. This makes the texture - * look smooth from up close, and smooth from a distance. Anisotropic filtering improves texture - * quality on surfaces that are almost in line with the camera, but is slightly slower. The - * anisotropic filtering level can be changed by adjusting - * [ProjectSettings.rendering/textures/defaultFilters/anisotropicFilteringLevel]. + * The texture filter blends between the nearest 4 pixels and blends between 2 mipmaps (or uses the nearest mipmap if [ProjectSettings.rendering/textures/defaultFilters/useNearestMipmapFilter] is `true`) based on the angle between the surface and the camera view. This makes the texture look smooth from up close, and smooth from a distance. Anisotropic filtering improves texture quality on surfaces that are almost in line with the camera, but is slightly slower. The anisotropic filtering level can be changed by adjusting [ProjectSettings.rendering/textures/defaultFilters/anisotropicFilteringLevel]. */ LINEAR_WITH_MIPMAPS_ANISOTROPIC(5), /** @@ -2792,26 +2530,19 @@ public open class BaseMaterial3D internal constructor() : Material() { */ DISABLED(0), /** - * The material will use the texture's alpha values for transparency. This is the slowest to - * render, and disables shadow casting. + * The material will use the texture's alpha values for transparency. This is the slowest to render, and disables shadow casting. */ ALPHA(1), /** - * The material will cut off all values below a threshold, the rest will remain opaque. The - * opaque portions will be rendered in the depth prepass. This is faster to render than alpha - * blending, but slower than opaque rendering. This also supports casting shadows. + * The material will cut off all values below a threshold, the rest will remain opaque. The opaque portions will be rendered in the depth prepass. This is faster to render than alpha blending, but slower than opaque rendering. This also supports casting shadows. */ ALPHA_SCISSOR(2), /** - * The material will cut off all values below a spatially-deterministic threshold, the rest will - * remain opaque. This is faster to render than alpha blending, but slower than opaque rendering. - * This also supports casting shadows. Alpha hashing is suited for hair rendering. + * The material will cut off all values below a spatially-deterministic threshold, the rest will remain opaque. This is faster to render than alpha blending, but slower than opaque rendering. This also supports casting shadows. Alpha hashing is suited for hair rendering. */ ALPHA_HASH(3), /** - * The material will use the texture's alpha value for transparency, but will discard fragments - * with an alpha of less than 0.99 during the depth prepass and fragments with an alpha less than - * 0.1 during the shadow pass. This also supports casting shadows. + * The material will use the texture's alpha value for transparency, but will discard fragments with an alpha of less than 0.99 during the depth prepass and fragments with an alpha less than 0.1 during the shadow pass. This also supports casting shadows. */ ALPHA_DEPTH_PRE_PASS(4), /** @@ -2834,8 +2565,7 @@ public open class BaseMaterial3D internal constructor() : Material() { id: Long, ) { /** - * The object will not receive shadows. This is the fastest to render, but it disables all - * interactions with lights. + * The object will not receive shadows. This is the fastest to render, but it disables all interactions with lights. */ UNSHADED(0), /** @@ -2843,8 +2573,7 @@ public open class BaseMaterial3D internal constructor() : Material() { */ PER_PIXEL(1), /** - * The object will be shaded per vertex. Useful when you want cheaper shaders and do not care - * about visual quality. + * The object will be shaded per vertex. Useful when you want cheaper shaders and do not care about visual quality. */ PER_VERTEX(2), /** @@ -2934,8 +2663,7 @@ public open class BaseMaterial3D internal constructor() : Material() { id: Long, ) { /** - * Default blend mode. The color of the object is blended over the background based on the - * object's alpha value. + * Default blend mode. The color of the object is blended over the background based on the object's alpha value. */ MIX(0), /** @@ -2951,11 +2679,7 @@ public open class BaseMaterial3D internal constructor() : Material() { */ MUL(3), /** - * The color of the object is added to the background and the alpha channel is used to mask out - * the background. This is effectively a hybrid of the blend mix and add modes, useful for effects - * like fire where you want the flame to add but the smoke to mix. By default, this works with - * unshaded materials using premultiplied textures. For shaded materials, use the - * `PREMUL_ALPHA_FACTOR` built-in so that lighting can be modulated as well. + * The color of the object is added to the background and the alpha channel is used to mask out the background. This is effectively a hybrid of the blend mix and add modes, useful for effects like fire where you want the flame to add but the smoke to mix. By default, this works with unshaded materials using premultiplied textures. For shaded materials, use the `PREMUL_ALPHA_FACTOR` built-in so that lighting can be modulated as well. */ PREMULT_ALPHA(4), ; @@ -2978,13 +2702,11 @@ public open class BaseMaterial3D internal constructor() : Material() { */ ANTIALIASING_OFF(0), /** - * Enables AlphaToCoverage. Alpha values in the material are passed to the AntiAliasing sample - * mask. + * Enables AlphaToCoverage. Alpha values in the material are passed to the AntiAliasing sample mask. */ ANTIALIASING_ALPHA_TO_COVERAGE(1), /** - * Enables AlphaToCoverage and forces all non-zero alpha values to `1`. Alpha values in the - * material are passed to the AntiAliasing sample mask. + * Enables AlphaToCoverage and forces all non-zero alpha values to `1`. Alpha values in the material are passed to the AntiAliasing sample mask. */ ANTIALIASING_ALPHA_TO_COVERAGE_AND_TO_ONE(2), ; @@ -3003,21 +2725,17 @@ public open class BaseMaterial3D internal constructor() : Material() { id: Long, ) { /** - * Default depth draw mode. Depth is drawn only for opaque objects during the opaque prepass (if - * any) and during the opaque pass. + * Default depth draw mode. Depth is drawn only for opaque objects during the opaque prepass (if any) and during the opaque pass. */ OPAQUE_ONLY(0), /** - * Objects will write to depth during the opaque and the transparent passes. Transparent objects - * that are close to the camera may obscure other transparent objects behind them. + * Objects will write to depth during the opaque and the transparent passes. Transparent objects that are close to the camera may obscure other transparent objects behind them. * - * **Note:** This does not influence whether transparent objects are included in the depth - * prepass or not. For that, see [Transparency]. + * **Note:** This does not influence whether transparent objects are included in the depth prepass or not. For that, see [Transparency]. */ ALWAYS(1), /** - * Objects will not write their depth to the depth buffer, even during the depth prepass (if - * enabled). + * Objects will not write their depth to the depth buffer, even during the depth prepass (if enabled). */ DISABLED(2), ; @@ -3036,15 +2754,11 @@ public open class BaseMaterial3D internal constructor() : Material() { id: Long, ) { /** - * Default cull mode. The back of the object is culled when not visible. Back face triangles - * will be culled when facing the camera. This results in only the front side of triangles being - * drawn. For closed-surface meshes, this means that only the exterior of the mesh will be visible. + * Default cull mode. The back of the object is culled when not visible. Back face triangles will be culled when facing the camera. This results in only the front side of triangles being drawn. For closed-surface meshes, this means that only the exterior of the mesh will be visible. */ BACK(0), /** - * Front face triangles will be culled when facing the camera. This results in only the back - * side of triangles being drawn. For closed-surface meshes, this means that the interior of the - * mesh will be drawn instead of the exterior. + * Front face triangles will be culled when facing the camera. This results in only the back side of triangles being drawn. For closed-surface meshes, this means that the interior of the mesh will be drawn instead of the exterior. */ FRONT(1), /** @@ -3067,9 +2781,7 @@ public open class BaseMaterial3D internal constructor() : Material() { id: Long, ) { /** - * Disables the depth test, so this object is drawn on top of all others drawn before it. This - * puts the object in the transparent draw pass where it is sorted based on distance to camera. - * Objects drawn after it in the draw order may cover it. This also disables writing to depth. + * Disables the depth test, so this object is drawn on top of all others drawn before it. This puts the object in the transparent draw pass where it is sorted based on distance to camera. Objects drawn after it in the draw order may cover it. This also disables writing to depth. */ DISABLE_DEPTH_TEST(0), /** @@ -3077,15 +2789,13 @@ public open class BaseMaterial3D internal constructor() : Material() { */ ALBEDO_FROM_VERTEX_COLOR(1), /** - * Vertex colors are considered to be stored in sRGB color space and are converted to linear - * color space during rendering. See also [vertexColorIsSrgb]. + * Vertex colors are considered to be stored in sRGB color space and are converted to linear color space during rendering. See also [vertexColorIsSrgb]. * * **Note:** Only effective when using the Forward+ and Mobile rendering methods. */ SRGB_VERTEX_COLOR(2), /** - * Uses point size to alter the size of primitive points. Also changes the albedo texture lookup - * to use `POINT_COORD` instead of `UV`. + * Uses point size to alter the size of primitive points. Also changes the albedo texture lookup to use `POINT_COORD` instead of `UV`. */ USE_POINT_SIZE(3), /** @@ -3093,8 +2803,7 @@ public open class BaseMaterial3D internal constructor() : Material() { */ FIXED_SIZE(4), /** - * Shader will keep the scale set for the mesh. Otherwise the scale is lost when billboarding. - * Only applies when [billboardMode] is [BILLBOARD_ENABLED]. + * Shader will keep the scale set for the mesh. Otherwise the scale is lost when billboarding. Only applies when [billboardMode] is [BILLBOARD_ENABLED]. */ BILLBOARD_KEEP_SCALE(5), /** @@ -3122,8 +2831,7 @@ public open class BaseMaterial3D internal constructor() : Material() { */ EMISSION_ON_UV2(11), /** - * Forces the shader to convert albedo from sRGB space to linear space. See also - * [albedoTextureForceSrgb]. + * Forces the shader to convert albedo from sRGB space to linear space. See also [albedoTextureForceSrgb]. */ ALBEDO_TEXTURE_FORCE_SRGB(12), /** @@ -3139,9 +2847,7 @@ public open class BaseMaterial3D internal constructor() : Material() { */ USE_SHADOW_TO_OPACITY(15), /** - * Enables the texture to repeat when UV coordinates are outside the 0-1 range. If using one of - * the linear filtering modes, this can result in artifacts at the edges of a texture when the - * sampler filters across the edges of the texture. + * Enables the texture to repeat when UV coordinates are outside the 0-1 range. If using one of the linear filtering modes, this can result in artifacts at the edges of a texture when the sampler filters across the edges of the texture. */ USE_TEXTURE_REPEAT(16), /** @@ -3149,15 +2855,11 @@ public open class BaseMaterial3D internal constructor() : Material() { */ INVERT_HEIGHTMAP(17), /** - * Enables the skin mode for subsurface scattering which is used to improve the look of - * subsurface scattering when used for human skin. + * Enables the skin mode for subsurface scattering which is used to improve the look of subsurface scattering when used for human skin. */ SUBSURFACE_MODE_SKIN(18), /** - * Enables parts of the shader required for [GPUParticles3D] trails to function. This also - * requires using a mesh with appropriate skinning, such as [RibbonTrailMesh] or [TubeTrailMesh]. - * Enabling this feature outside of materials used in [GPUParticles3D] meshes will break material - * rendering. + * Enables parts of the shader required for [GPUParticles3D] trails to function. This also requires using a mesh with appropriate skinning, such as [RibbonTrailMesh] or [TubeTrailMesh]. Enabling this feature outside of materials used in [GPUParticles3D] meshes will break material rendering. */ PARTICLE_TRAILS_MODE(19), /** @@ -3258,11 +2960,9 @@ public open class BaseMaterial3D internal constructor() : Material() { */ FIXED_Y(2), /** - * Used for particle systems when assigned to [GPUParticles3D] and [CPUParticles3D] nodes - * (flipbook animation). Enables `particles_anim_*` properties. + * Used for particle systems when assigned to [GPUParticles3D] and [CPUParticles3D] nodes (flipbook animation). Enables `particles_anim_*` properties. * - * The [ParticleProcessMaterial.animSpeedMin] or [CPUParticles3D.animSpeedMin] should also be - * set to a value bigger than zero for the animation to play. + * The [ParticleProcessMaterial.animSpeedMin] or [CPUParticles3D.animSpeedMin] should also be set to a value bigger than zero for the animation to play. */ PARTICLES(3), ; @@ -3297,8 +2997,7 @@ public open class BaseMaterial3D internal constructor() : Material() { */ ALPHA(3), /** - * Used to read from the linear (non-perceptual) average of the red, green and blue channels of - * a texture. + * Used to read from the linear (non-perceptual) average of the red, green and blue channels of a texture. */ GRAYSCALE(4), ; @@ -3344,21 +3043,15 @@ public open class BaseMaterial3D internal constructor() : Material() { */ DISABLED(0), /** - * Smoothly fades the object out based on each pixel's distance from the camera using the alpha - * channel. + * Smoothly fades the object out based on each pixel's distance from the camera using the alpha channel. */ PIXEL_ALPHA(1), /** - * Smoothly fades the object out based on each pixel's distance from the camera using a - * dithering approach. Dithering discards pixels based on a set pattern to smoothly fade without - * enabling transparency. On certain hardware, this can be faster than [DISTANCE_FADE_PIXEL_ALPHA]. + * Smoothly fades the object out based on each pixel's distance from the camera using a dithering approach. Dithering discards pixels based on a set pattern to smoothly fade without enabling transparency. On certain hardware, this can be faster than [DISTANCE_FADE_PIXEL_ALPHA]. */ PIXEL_DITHER(2), /** - * Smoothly fades the object out based on the object's distance from the camera using a - * dithering approach. Dithering discards pixels based on a set pattern to smoothly fade without - * enabling transparency. On certain hardware, this can be faster than [DISTANCE_FADE_PIXEL_ALPHA] - * and [DISTANCE_FADE_PIXEL_DITHER]. + * Smoothly fades the object out based on the object's distance from the camera using a dithering approach. Dithering discards pixels based on a set pattern to smoothly fade without enabling transparency. On certain hardware, this can be faster than [DISTANCE_FADE_PIXEL_ALPHA] and [DISTANCE_FADE_PIXEL_DITHER]. */ OBJECT_DITHER(3), ; @@ -3377,411 +3070,411 @@ public open class BaseMaterial3D internal constructor() : Material() { public object MethodBindings { internal val setAlbedoPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_albedo", 2920490490) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_albedo", 2_920_490_490) internal val getAlbedoPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_albedo", 3444240500) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_albedo", 3_444_240_500) internal val setTransparencyPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_transparency", 3435651667) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_transparency", 3_435_651_667) internal val getTransparencyPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_transparency", 990903061) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_transparency", 990_903_061) internal val setAlphaAntialiasingPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_alpha_antialiasing", 3212649852) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_alpha_antialiasing", 3_212_649_852) internal val getAlphaAntialiasingPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_alpha_antialiasing", 2889939400) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_alpha_antialiasing", 2_889_939_400) internal val setAlphaAntialiasingEdgePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_alpha_antialiasing_edge", 373806689) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_alpha_antialiasing_edge", 373_806_689) internal val getAlphaAntialiasingEdgePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_alpha_antialiasing_edge", 1740695150) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_alpha_antialiasing_edge", 1_740_695_150) internal val setShadingModePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_shading_mode", 3368750322) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_shading_mode", 3_368_750_322) internal val getShadingModePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_shading_mode", 2132070559) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_shading_mode", 2_132_070_559) internal val setSpecularPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_specular", 373806689) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_specular", 373_806_689) internal val getSpecularPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_specular", 1740695150) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_specular", 1_740_695_150) internal val setMetallicPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_metallic", 373806689) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_metallic", 373_806_689) internal val getMetallicPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_metallic", 1740695150) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_metallic", 1_740_695_150) internal val setRoughnessPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_roughness", 373806689) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_roughness", 373_806_689) internal val getRoughnessPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_roughness", 1740695150) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_roughness", 1_740_695_150) internal val setEmissionPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_emission", 2920490490) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_emission", 2_920_490_490) internal val getEmissionPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_emission", 3444240500) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_emission", 3_444_240_500) internal val setEmissionEnergyMultiplierPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_emission_energy_multiplier", 373806689) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_emission_energy_multiplier", 373_806_689) internal val getEmissionEnergyMultiplierPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_emission_energy_multiplier", 1740695150) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_emission_energy_multiplier", 1_740_695_150) internal val setEmissionIntensityPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_emission_intensity", 373806689) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_emission_intensity", 373_806_689) internal val getEmissionIntensityPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_emission_intensity", 1740695150) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_emission_intensity", 1_740_695_150) internal val setNormalScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_normal_scale", 373806689) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_normal_scale", 373_806_689) internal val getNormalScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_normal_scale", 1740695150) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_normal_scale", 1_740_695_150) internal val setRimPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_rim", 373806689) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_rim", 373_806_689) internal val getRimPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_rim", 1740695150) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_rim", 1_740_695_150) internal val setRimTintPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_rim_tint", 373806689) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_rim_tint", 373_806_689) internal val getRimTintPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_rim_tint", 1740695150) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_rim_tint", 1_740_695_150) internal val setClearcoatPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_clearcoat", 373806689) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_clearcoat", 373_806_689) internal val getClearcoatPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_clearcoat", 1740695150) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_clearcoat", 1_740_695_150) internal val setClearcoatRoughnessPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_clearcoat_roughness", 373806689) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_clearcoat_roughness", 373_806_689) internal val getClearcoatRoughnessPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_clearcoat_roughness", 1740695150) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_clearcoat_roughness", 1_740_695_150) internal val setAnisotropyPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_anisotropy", 373806689) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_anisotropy", 373_806_689) internal val getAnisotropyPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_anisotropy", 1740695150) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_anisotropy", 1_740_695_150) internal val setHeightmapScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_heightmap_scale", 373806689) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_heightmap_scale", 373_806_689) internal val getHeightmapScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_heightmap_scale", 1740695150) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_heightmap_scale", 1_740_695_150) internal val setSubsurfaceScatteringStrengthPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_subsurface_scattering_strength", 373806689) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_subsurface_scattering_strength", 373_806_689) internal val getSubsurfaceScatteringStrengthPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_subsurface_scattering_strength", 1740695150) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_subsurface_scattering_strength", 1_740_695_150) internal val setTransmittanceColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_transmittance_color", 2920490490) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_transmittance_color", 2_920_490_490) internal val getTransmittanceColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_transmittance_color", 3444240500) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_transmittance_color", 3_444_240_500) internal val setTransmittanceDepthPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_transmittance_depth", 373806689) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_transmittance_depth", 373_806_689) internal val getTransmittanceDepthPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_transmittance_depth", 1740695150) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_transmittance_depth", 1_740_695_150) internal val setTransmittanceBoostPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_transmittance_boost", 373806689) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_transmittance_boost", 373_806_689) internal val getTransmittanceBoostPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_transmittance_boost", 1740695150) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_transmittance_boost", 1_740_695_150) internal val setBacklightPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_backlight", 2920490490) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_backlight", 2_920_490_490) internal val getBacklightPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_backlight", 3444240500) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_backlight", 3_444_240_500) internal val setRefractionPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_refraction", 373806689) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_refraction", 373_806_689) internal val getRefractionPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_refraction", 1740695150) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_refraction", 1_740_695_150) internal val setPointSizePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_point_size", 373806689) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_point_size", 373_806_689) internal val getPointSizePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_point_size", 1740695150) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_point_size", 1_740_695_150) internal val setDetailUvPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_detail_uv", 456801921) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_detail_uv", 456_801_921) internal val getDetailUvPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_detail_uv", 2306920512) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_detail_uv", 2_306_920_512) internal val setBlendModePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_blend_mode", 2830186259) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_blend_mode", 2_830_186_259) internal val getBlendModePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_blend_mode", 4022690962) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_blend_mode", 4_022_690_962) internal val setDepthDrawModePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_depth_draw_mode", 1456584748) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_depth_draw_mode", 1_456_584_748) internal val getDepthDrawModePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_depth_draw_mode", 2578197639) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_depth_draw_mode", 2_578_197_639) internal val setCullModePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_cull_mode", 2338909218) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_cull_mode", 2_338_909_218) internal val getCullModePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_cull_mode", 1941499586) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_cull_mode", 1_941_499_586) internal val setDiffuseModePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_diffuse_mode", 1045299638) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_diffuse_mode", 1_045_299_638) internal val getDiffuseModePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_diffuse_mode", 3973617136) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_diffuse_mode", 3_973_617_136) internal val setSpecularModePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_specular_mode", 584737147) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_specular_mode", 584_737_147) internal val getSpecularModePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_specular_mode", 2569953298) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_specular_mode", 2_569_953_298) internal val setFlagPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_flag", 3070159527) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_flag", 3_070_159_527) internal val getFlagPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_flag", 1286410065) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_flag", 1_286_410_065) internal val setTextureFilterPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_texture_filter", 22904437) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_texture_filter", 22_904_437) internal val getTextureFilterPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_texture_filter", 3289213076) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_texture_filter", 3_289_213_076) internal val setFeaturePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_feature", 2819288693) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_feature", 2_819_288_693) internal val getFeaturePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_feature", 1965241794) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_feature", 1_965_241_794) internal val setTexturePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_texture", 464208135) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_texture", 464_208_135) internal val getTexturePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_texture", 329605813) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_texture", 329_605_813) internal val setDetailBlendModePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_detail_blend_mode", 2830186259) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_detail_blend_mode", 2_830_186_259) internal val getDetailBlendModePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_detail_blend_mode", 4022690962) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_detail_blend_mode", 4_022_690_962) internal val setUv1ScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_uv1_scale", 3460891852) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_uv1_scale", 3_460_891_852) internal val getUv1ScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_uv1_scale", 3360562783) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_uv1_scale", 3_360_562_783) internal val setUv1OffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_uv1_offset", 3460891852) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_uv1_offset", 3_460_891_852) internal val getUv1OffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_uv1_offset", 3360562783) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_uv1_offset", 3_360_562_783) internal val setUv1TriplanarBlendSharpnessPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_uv1_triplanar_blend_sharpness", 373806689) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_uv1_triplanar_blend_sharpness", 373_806_689) internal val getUv1TriplanarBlendSharpnessPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_uv1_triplanar_blend_sharpness", 1740695150) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_uv1_triplanar_blend_sharpness", 1_740_695_150) internal val setUv2ScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_uv2_scale", 3460891852) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_uv2_scale", 3_460_891_852) internal val getUv2ScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_uv2_scale", 3360562783) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_uv2_scale", 3_360_562_783) internal val setUv2OffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_uv2_offset", 3460891852) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_uv2_offset", 3_460_891_852) internal val getUv2OffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_uv2_offset", 3360562783) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_uv2_offset", 3_360_562_783) internal val setUv2TriplanarBlendSharpnessPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_uv2_triplanar_blend_sharpness", 373806689) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_uv2_triplanar_blend_sharpness", 373_806_689) internal val getUv2TriplanarBlendSharpnessPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_uv2_triplanar_blend_sharpness", 1740695150) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_uv2_triplanar_blend_sharpness", 1_740_695_150) internal val setBillboardModePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_billboard_mode", 4202036497) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_billboard_mode", 4_202_036_497) internal val getBillboardModePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_billboard_mode", 1283840139) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_billboard_mode", 1_283_840_139) internal val setParticlesAnimHFramesPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_particles_anim_h_frames", 1286410249) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_particles_anim_h_frames", 1_286_410_249) internal val getParticlesAnimHFramesPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_particles_anim_h_frames", 3905245786) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_particles_anim_h_frames", 3_905_245_786) internal val setParticlesAnimVFramesPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_particles_anim_v_frames", 1286410249) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_particles_anim_v_frames", 1_286_410_249) internal val getParticlesAnimVFramesPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_particles_anim_v_frames", 3905245786) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_particles_anim_v_frames", 3_905_245_786) internal val setParticlesAnimLoopPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_particles_anim_loop", 2586408642) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_particles_anim_loop", 2_586_408_642) internal val getParticlesAnimLoopPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_particles_anim_loop", 36873697) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_particles_anim_loop", 36_873_697) internal val setHeightmapDeepParallaxPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_heightmap_deep_parallax", 2586408642) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_heightmap_deep_parallax", 2_586_408_642) internal val isHeightmapDeepParallaxEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "is_heightmap_deep_parallax_enabled", 36873697) + TypeManager.getMethodBindPtr("BaseMaterial3D", "is_heightmap_deep_parallax_enabled", 36_873_697) internal val setHeightmapDeepParallaxMinLayersPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_heightmap_deep_parallax_min_layers", 1286410249) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_heightmap_deep_parallax_min_layers", 1_286_410_249) internal val getHeightmapDeepParallaxMinLayersPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_heightmap_deep_parallax_min_layers", 3905245786) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_heightmap_deep_parallax_min_layers", 3_905_245_786) internal val setHeightmapDeepParallaxMaxLayersPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_heightmap_deep_parallax_max_layers", 1286410249) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_heightmap_deep_parallax_max_layers", 1_286_410_249) internal val getHeightmapDeepParallaxMaxLayersPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_heightmap_deep_parallax_max_layers", 3905245786) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_heightmap_deep_parallax_max_layers", 3_905_245_786) internal val setHeightmapDeepParallaxFlipTangentPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_heightmap_deep_parallax_flip_tangent", 2586408642) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_heightmap_deep_parallax_flip_tangent", 2_586_408_642) internal val getHeightmapDeepParallaxFlipTangentPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_heightmap_deep_parallax_flip_tangent", 36873697) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_heightmap_deep_parallax_flip_tangent", 36_873_697) internal val setHeightmapDeepParallaxFlipBinormalPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_heightmap_deep_parallax_flip_binormal", 2586408642) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_heightmap_deep_parallax_flip_binormal", 2_586_408_642) internal val getHeightmapDeepParallaxFlipBinormalPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_heightmap_deep_parallax_flip_binormal", 36873697) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_heightmap_deep_parallax_flip_binormal", 36_873_697) internal val setGrowPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_grow", 373806689) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_grow", 373_806_689) internal val getGrowPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_grow", 1740695150) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_grow", 1_740_695_150) internal val setEmissionOperatorPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_emission_operator", 3825128922) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_emission_operator", 3_825_128_922) internal val getEmissionOperatorPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_emission_operator", 974205018) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_emission_operator", 974_205_018) internal val setAoLightAffectPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_ao_light_affect", 373806689) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_ao_light_affect", 373_806_689) internal val getAoLightAffectPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_ao_light_affect", 1740695150) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_ao_light_affect", 1_740_695_150) internal val setAlphaScissorThresholdPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_alpha_scissor_threshold", 373806689) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_alpha_scissor_threshold", 373_806_689) internal val getAlphaScissorThresholdPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_alpha_scissor_threshold", 1740695150) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_alpha_scissor_threshold", 1_740_695_150) internal val setAlphaHashScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_alpha_hash_scale", 373806689) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_alpha_hash_scale", 373_806_689) internal val getAlphaHashScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_alpha_hash_scale", 1740695150) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_alpha_hash_scale", 1_740_695_150) internal val setGrowEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_grow_enabled", 2586408642) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_grow_enabled", 2_586_408_642) internal val isGrowEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "is_grow_enabled", 36873697) + TypeManager.getMethodBindPtr("BaseMaterial3D", "is_grow_enabled", 36_873_697) internal val setMetallicTextureChannelPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_metallic_texture_channel", 744167988) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_metallic_texture_channel", 744_167_988) internal val getMetallicTextureChannelPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_metallic_texture_channel", 568133867) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_metallic_texture_channel", 568_133_867) internal val setRoughnessTextureChannelPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_roughness_texture_channel", 744167988) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_roughness_texture_channel", 744_167_988) internal val getRoughnessTextureChannelPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_roughness_texture_channel", 568133867) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_roughness_texture_channel", 568_133_867) internal val setAoTextureChannelPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_ao_texture_channel", 744167988) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_ao_texture_channel", 744_167_988) internal val getAoTextureChannelPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_ao_texture_channel", 568133867) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_ao_texture_channel", 568_133_867) internal val setRefractionTextureChannelPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_refraction_texture_channel", 744167988) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_refraction_texture_channel", 744_167_988) internal val getRefractionTextureChannelPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_refraction_texture_channel", 568133867) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_refraction_texture_channel", 568_133_867) internal val setProximityFadeEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_proximity_fade_enabled", 2586408642) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_proximity_fade_enabled", 2_586_408_642) internal val isProximityFadeEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "is_proximity_fade_enabled", 36873697) + TypeManager.getMethodBindPtr("BaseMaterial3D", "is_proximity_fade_enabled", 36_873_697) internal val setProximityFadeDistancePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_proximity_fade_distance", 373806689) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_proximity_fade_distance", 373_806_689) internal val getProximityFadeDistancePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_proximity_fade_distance", 1740695150) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_proximity_fade_distance", 1_740_695_150) internal val setMsdfPixelRangePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_msdf_pixel_range", 373806689) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_msdf_pixel_range", 373_806_689) internal val getMsdfPixelRangePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_msdf_pixel_range", 1740695150) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_msdf_pixel_range", 1_740_695_150) internal val setMsdfOutlineSizePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_msdf_outline_size", 373806689) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_msdf_outline_size", 373_806_689) internal val getMsdfOutlineSizePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_msdf_outline_size", 1740695150) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_msdf_outline_size", 1_740_695_150) internal val setDistanceFadePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_distance_fade", 1379478617) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_distance_fade", 1_379_478_617) internal val getDistanceFadePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_distance_fade", 2694575734) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_distance_fade", 2_694_575_734) internal val setDistanceFadeMaxDistancePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_distance_fade_max_distance", 373806689) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_distance_fade_max_distance", 373_806_689) internal val getDistanceFadeMaxDistancePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_distance_fade_max_distance", 1740695150) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_distance_fade_max_distance", 1_740_695_150) internal val setDistanceFadeMinDistancePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "set_distance_fade_min_distance", 373806689) + TypeManager.getMethodBindPtr("BaseMaterial3D", "set_distance_fade_min_distance", 373_806_689) internal val getDistanceFadeMinDistancePtr: VoidPtr = - TypeManager.getMethodBindPtr("BaseMaterial3D", "get_distance_fade_min_distance", 1740695150) + TypeManager.getMethodBindPtr("BaseMaterial3D", "get_distance_fade_min_distance", 1_740_695_150) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BitMap.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BitMap.kt index 3e2d281b4b..54a093ce47 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BitMap.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BitMap.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -27,34 +24,30 @@ import kotlin.Float import kotlin.Int import kotlin.Long import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmOverloads /** - * A two-dimensional array of boolean values, can be used to efficiently store a binary matrix - * (every matrix element takes only one bit) and query the values using natural cartesian coordinates. + * A two-dimensional array of boolean values, can be used to efficiently store a binary matrix (every matrix element takes only one bit) and query the values using natural cartesian coordinates. */ @GodotBaseType public open class BitMap : Resource() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(105, scriptIndex) } /** * Creates a bitmap with the specified size, filled with `false`. */ - public final fun create(size: Vector2i): Unit { + public final fun create(size: Vector2i) { TransferContext.writeArguments(VECTOR2I to size) TransferContext.callMethod(ptr, MethodBindings.createPtr, NIL) } /** - * Creates a bitmap that matches the given image dimensions, every element of the bitmap is set to - * `false` if the alpha value of the image at that position is equal to [threshold] or less, and - * `true` in other case. + * Creates a bitmap that matches the given image dimensions, every element of the bitmap is set to `false` if the alpha value of the image at that position is equal to [threshold] or less, and `true` in other case. */ @JvmOverloads - public final fun createFromImageAlpha(image: Image?, threshold: Float = 0.1f): Unit { + public final fun createFromImageAlpha(image: Image?, threshold: Float = 0.1f) { TransferContext.writeArguments(OBJECT to image, DOUBLE to threshold.toDouble()) TransferContext.callMethod(ptr, MethodBindings.createFromImageAlphaPtr, NIL) } @@ -62,7 +55,7 @@ public open class BitMap : Resource() { /** * Sets the bitmap's element at the specified position, to the specified value. */ - public final fun setBitv(position: Vector2i, bit: Boolean): Unit { + public final fun setBitv(position: Vector2i, bit: Boolean) { TransferContext.writeArguments(VECTOR2I to position, BOOL to bit) TransferContext.callMethod(ptr, MethodBindings.setBitvPtr, NIL) } @@ -74,7 +67,7 @@ public open class BitMap : Resource() { x: Int, y: Int, bit: Boolean, - ): Unit { + ) { TransferContext.writeArguments(LONG to x.toLong(), LONG to y.toLong(), BOOL to bit) TransferContext.callMethod(ptr, MethodBindings.setBitPtr, NIL) } @@ -100,7 +93,7 @@ public open class BitMap : Resource() { /** * Sets a rectangular portion of the bitmap to the specified value. */ - public final fun setBitRect(rect: Rect2i, bit: Boolean): Unit { + public final fun setBitRect(rect: Rect2i, bit: Boolean) { TransferContext.writeArguments(RECT2I to rect, BOOL to bit) TransferContext.callMethod(ptr, MethodBindings.setBitRectPtr, NIL) } @@ -126,26 +119,21 @@ public open class BitMap : Resource() { /** * Resizes the image to [newSize]. */ - public final fun resize(newSize: Vector2i): Unit { + public final fun resize(newSize: Vector2i) { TransferContext.writeArguments(VECTOR2I to newSize) TransferContext.callMethod(ptr, MethodBindings.resizePtr, NIL) } /** - * Applies morphological dilation or erosion to the bitmap. If [pixels] is positive, dilation is - * applied to the bitmap. If [pixels] is negative, erosion is applied to the bitmap. [rect] defines - * the area where the morphological operation is applied. Pixels located outside the [rect] are - * unaffected by [growMask]. + * Applies morphological dilation or erosion to the bitmap. If [pixels] is positive, dilation is applied to the bitmap. If [pixels] is negative, erosion is applied to the bitmap. [rect] defines the area where the morphological operation is applied. Pixels located outside the [rect] are unaffected by [growMask]. */ - public final fun growMask(pixels: Int, rect: Rect2i): Unit { + public final fun growMask(pixels: Int, rect: Rect2i) { TransferContext.writeArguments(LONG to pixels.toLong(), RECT2I to rect) TransferContext.callMethod(ptr, MethodBindings.growMaskPtr, NIL) } /** - * Returns an image of the same size as the bitmap and with a [Image.Format] of type - * [Image.FORMAT_L8]. `true` bits of the bitmap are being converted into white pixels, and `false` - * bits into black. + * Returns an image of the same size as the bitmap and with a [Image.Format] of type [Image.FORMAT_L8]. `true` bits of the bitmap are being converted into white pixels, and `false` bits into black. */ public final fun convertToImage(): Image? { TransferContext.writeArguments() @@ -154,9 +142,7 @@ public open class BitMap : Resource() { } /** - * Creates an [Array] of polygons covering a rectangular portion of the bitmap. It uses a marching - * squares algorithm, followed by Ramer-Douglas-Peucker (RDP) reduction of the number of vertices. - * Each polygon is described as a [PackedVector2Array] of its vertices. + * Creates an [Array] of polygons covering a rectangular portion of the bitmap. It uses a marching squares algorithm, followed by Ramer-Douglas-Peucker (RDP) reduction of the number of vertices. Each polygon is described as a [PackedVector2Array] of its vertices. * * To get polygons covering the whole bitmap, pass: * @@ -164,12 +150,10 @@ public open class BitMap : Resource() { * Rect2(Vector2(), get_size()) * ``` * - * [epsilon] is passed to RDP to control how accurately the polygons cover the bitmap: a lower - * [epsilon] corresponds to more points in the polygons. + * [epsilon] is passed to RDP to control how accurately the polygons cover the bitmap: a lower [epsilon] corresponds to more points in the polygons. */ @JvmOverloads - public final fun opaqueToPolygons(rect: Rect2i, epsilon: Float = 2.0f): - VariantArray { + public final fun opaqueToPolygons(rect: Rect2i, epsilon: Float = 2.0f): VariantArray { TransferContext.writeArguments(RECT2I to rect, DOUBLE to epsilon.toDouble()) TransferContext.callMethod(ptr, MethodBindings.opaqueToPolygonsPtr, ARRAY) return (TransferContext.readReturnValue(ARRAY) as VariantArray) @@ -178,39 +162,43 @@ public open class BitMap : Resource() { public companion object public object MethodBindings { - internal val createPtr: VoidPtr = TypeManager.getMethodBindPtr("BitMap", "create", 1130785943) + internal val createPtr: VoidPtr = + TypeManager.getMethodBindPtr("BitMap", "create", 1_130_785_943) internal val createFromImageAlphaPtr: VoidPtr = - TypeManager.getMethodBindPtr("BitMap", "create_from_image_alpha", 106271684) + TypeManager.getMethodBindPtr("BitMap", "create_from_image_alpha", 106_271_684) internal val setBitvPtr: VoidPtr = - TypeManager.getMethodBindPtr("BitMap", "set_bitv", 4153096796) + TypeManager.getMethodBindPtr("BitMap", "set_bitv", 4_153_096_796) - internal val setBitPtr: VoidPtr = TypeManager.getMethodBindPtr("BitMap", "set_bit", 1383440665) + internal val setBitPtr: VoidPtr = + TypeManager.getMethodBindPtr("BitMap", "set_bit", 1_383_440_665) internal val getBitvPtr: VoidPtr = - TypeManager.getMethodBindPtr("BitMap", "get_bitv", 3900751641) + TypeManager.getMethodBindPtr("BitMap", "get_bitv", 3_900_751_641) - internal val getBitPtr: VoidPtr = TypeManager.getMethodBindPtr("BitMap", "get_bit", 2522259332) + internal val getBitPtr: VoidPtr = + TypeManager.getMethodBindPtr("BitMap", "get_bit", 2_522_259_332) internal val setBitRectPtr: VoidPtr = - TypeManager.getMethodBindPtr("BitMap", "set_bit_rect", 472162941) + TypeManager.getMethodBindPtr("BitMap", "set_bit_rect", 472_162_941) internal val getTrueBitCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("BitMap", "get_true_bit_count", 3905245786) + TypeManager.getMethodBindPtr("BitMap", "get_true_bit_count", 3_905_245_786) internal val getSizePtr: VoidPtr = - TypeManager.getMethodBindPtr("BitMap", "get_size", 3690982128) + TypeManager.getMethodBindPtr("BitMap", "get_size", 3_690_982_128) - internal val resizePtr: VoidPtr = TypeManager.getMethodBindPtr("BitMap", "resize", 1130785943) + internal val resizePtr: VoidPtr = + TypeManager.getMethodBindPtr("BitMap", "resize", 1_130_785_943) internal val growMaskPtr: VoidPtr = - TypeManager.getMethodBindPtr("BitMap", "grow_mask", 3317281434) + TypeManager.getMethodBindPtr("BitMap", "grow_mask", 3_317_281_434) internal val convertToImagePtr: VoidPtr = - TypeManager.getMethodBindPtr("BitMap", "convert_to_image", 4190603485) + TypeManager.getMethodBindPtr("BitMap", "convert_to_image", 4_190_603_485) internal val opaqueToPolygonsPtr: VoidPtr = - TypeManager.getMethodBindPtr("BitMap", "opaque_to_polygons", 48478126) + TypeManager.getMethodBindPtr("BitMap", "opaque_to_polygons", 48_478_126) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Bone2D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Bone2D.kt index 7f2ee6f890..021725faa7 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Bone2D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Bone2D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -28,30 +25,22 @@ import kotlin.Unit import kotlin.jvm.JvmName /** - * A hierarchy of [Bone2D]s can be bound to a [Skeleton2D] to control and animate other [Node2D] - * nodes. + * A hierarchy of [Bone2D]s can be bound to a [Skeleton2D] to control and animate other [Node2D] nodes. * - * You can use [Bone2D] and [Skeleton2D] nodes to animate 2D meshes created with the [Polygon2D] UV - * editor. + * You can use [Bone2D] and [Skeleton2D] nodes to animate 2D meshes created with the [Polygon2D] UV editor. * - * Each bone has a [rest] transform that you can reset to with [applyRest]. These rest poses are - * relative to the bone's parent. + * Each bone has a [rest] transform that you can reset to with [applyRest]. These rest poses are relative to the bone's parent. * - * If in the editor, you can set the rest pose of an entire skeleton using a menu option, from the - * code, you need to iterate over the bones to set their individual rest poses. + * If in the editor, you can set the rest pose of an entire skeleton using a menu option, from the code, you need to iterate over the bones to set their individual rest poses. */ @GodotBaseType public open class Bone2D : Node2D() { /** - * Rest transform of the bone. You can reset the node's transforms to this value using - * [applyRest]. + * Rest transform of the bone. You can reset the node's transforms to this value using [applyRest]. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var rest: Transform2D @@ -62,7 +51,7 @@ public open class Bone2D : Node2D() { setRest(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(106, scriptIndex) } @@ -77,8 +66,7 @@ public open class Bone2D : Node2D() { * bone2d.rest = myCoreType * `````` * - * Rest transform of the bone. You can reset the node's transforms to this value using - * [applyRest]. + * Rest transform of the bone. You can reset the node's transforms to this value using [applyRest]. */ @CoreTypeHelper public final fun restMutate(block: Transform2D.() -> Unit): Transform2D = rest.apply { @@ -86,7 +74,7 @@ public open class Bone2D : Node2D() { rest = this } - public final fun setRest(rest: Transform2D): Unit { + public final fun setRest(rest: Transform2D) { TransferContext.writeArguments(TRANSFORM2D to rest) TransferContext.callMethod(ptr, MethodBindings.setRestPtr, NIL) } @@ -100,14 +88,13 @@ public open class Bone2D : Node2D() { /** * Resets the bone to the rest pose. This is equivalent to setting [Node2D.transform] to [rest]. */ - public final fun applyRest(): Unit { + public final fun applyRest() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.applyRestPtr, NIL) } /** - * Returns the node's [rest] [Transform2D] if it doesn't have a parent, or its rest pose relative - * to its parent. + * Returns the node's [rest] [Transform2D] if it doesn't have a parent, or its rest pose relative to its parent. */ public final fun getSkeletonRest(): Transform2D { TransferContext.writeArguments() @@ -125,19 +112,15 @@ public open class Bone2D : Node2D() { } /** - * When set to `true`, the [Bone2D] node will attempt to automatically calculate the bone angle - * and length using the first child [Bone2D] node, if one exists. If none exist, the [Bone2D] cannot - * automatically calculate these values and will print a warning. + * When set to `true`, the [Bone2D] node will attempt to automatically calculate the bone angle and length using the first child [Bone2D] node, if one exists. If none exist, the [Bone2D] cannot automatically calculate these values and will print a warning. */ - public final fun setAutocalculateLengthAndAngle(autoCalculate: Boolean): Unit { + public final fun setAutocalculateLengthAndAngle(autoCalculate: Boolean) { TransferContext.writeArguments(BOOL to autoCalculate) TransferContext.callMethod(ptr, MethodBindings.setAutocalculateLengthAndAnglePtr, NIL) } /** - * Returns whether this [Bone2D] is going to autocalculate its length and bone angle using its - * first [Bone2D] child node, if one exists. If there are no [Bone2D] children, then it cannot - * autocalculate these values and will print a warning. + * Returns whether this [Bone2D] is going to autocalculate its length and bone angle using its first [Bone2D] child node, if one exists. If there are no [Bone2D] children, then it cannot autocalculate these values and will print a warning. */ public final fun getAutocalculateLengthAndAngle(): Boolean { TransferContext.writeArguments() @@ -148,7 +131,7 @@ public open class Bone2D : Node2D() { /** * Sets the length of the bone in the [Bone2D]. */ - public final fun setLength(length: Float): Unit { + public final fun setLength(length: Float) { TransferContext.writeArguments(DOUBLE to length.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setLengthPtr, NIL) } @@ -163,13 +146,11 @@ public open class Bone2D : Node2D() { } /** - * Sets the bone angle for the [Bone2D]. This is typically set to the rotation from the [Bone2D] - * to a child [Bone2D] node. + * Sets the bone angle for the [Bone2D]. This is typically set to the rotation from the [Bone2D] to a child [Bone2D] node. * - * **Note:** This is different from the [Bone2D]'s rotation. The bone's angle is the rotation of - * the bone shown by the gizmo, which is unaffected by the [Bone2D]'s [Node2D.transform]. + * **Note:** This is different from the [Bone2D]'s rotation. The bone's angle is the rotation of the bone shown by the gizmo, which is unaffected by the [Bone2D]'s [Node2D.transform]. */ - public final fun setBoneAngle(angle: Float): Unit { + public final fun setBoneAngle(angle: Float) { TransferContext.writeArguments(DOUBLE to angle.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setBoneAnglePtr, NIL) } @@ -177,8 +158,7 @@ public open class Bone2D : Node2D() { /** * Returns the angle of the bone in the [Bone2D]. * - * **Note:** This is different from the [Bone2D]'s rotation. The bone's angle is the rotation of - * the bone shown by the gizmo, which is unaffected by the [Bone2D]'s [Node2D.transform]. + * **Note:** This is different from the [Bone2D]'s rotation. The bone's angle is the rotation of the bone shown by the gizmo, which is unaffected by the [Bone2D]'s [Node2D.transform]. */ public final fun getBoneAngle(): Float { TransferContext.writeArguments() @@ -190,36 +170,36 @@ public open class Bone2D : Node2D() { public object MethodBindings { internal val setRestPtr: VoidPtr = - TypeManager.getMethodBindPtr("Bone2D", "set_rest", 2761652528) + TypeManager.getMethodBindPtr("Bone2D", "set_rest", 2_761_652_528) internal val getRestPtr: VoidPtr = - TypeManager.getMethodBindPtr("Bone2D", "get_rest", 3814499831) + TypeManager.getMethodBindPtr("Bone2D", "get_rest", 3_814_499_831) internal val applyRestPtr: VoidPtr = - TypeManager.getMethodBindPtr("Bone2D", "apply_rest", 3218959716) + TypeManager.getMethodBindPtr("Bone2D", "apply_rest", 3_218_959_716) internal val getSkeletonRestPtr: VoidPtr = - TypeManager.getMethodBindPtr("Bone2D", "get_skeleton_rest", 3814499831) + TypeManager.getMethodBindPtr("Bone2D", "get_skeleton_rest", 3_814_499_831) internal val getIndexInSkeletonPtr: VoidPtr = - TypeManager.getMethodBindPtr("Bone2D", "get_index_in_skeleton", 3905245786) + TypeManager.getMethodBindPtr("Bone2D", "get_index_in_skeleton", 3_905_245_786) internal val setAutocalculateLengthAndAnglePtr: VoidPtr = - TypeManager.getMethodBindPtr("Bone2D", "set_autocalculate_length_and_angle", 2586408642) + TypeManager.getMethodBindPtr("Bone2D", "set_autocalculate_length_and_angle", 2_586_408_642) internal val getAutocalculateLengthAndAnglePtr: VoidPtr = - TypeManager.getMethodBindPtr("Bone2D", "get_autocalculate_length_and_angle", 36873697) + TypeManager.getMethodBindPtr("Bone2D", "get_autocalculate_length_and_angle", 36_873_697) internal val setLengthPtr: VoidPtr = - TypeManager.getMethodBindPtr("Bone2D", "set_length", 373806689) + TypeManager.getMethodBindPtr("Bone2D", "set_length", 373_806_689) internal val getLengthPtr: VoidPtr = - TypeManager.getMethodBindPtr("Bone2D", "get_length", 1740695150) + TypeManager.getMethodBindPtr("Bone2D", "get_length", 1_740_695_150) internal val setBoneAnglePtr: VoidPtr = - TypeManager.getMethodBindPtr("Bone2D", "set_bone_angle", 373806689) + TypeManager.getMethodBindPtr("Bone2D", "set_bone_angle", 373_806_689) internal val getBoneAnglePtr: VoidPtr = - TypeManager.getMethodBindPtr("Bone2D", "get_bone_angle", 1740695150) + TypeManager.getMethodBindPtr("Bone2D", "get_bone_angle", 1_740_695_150) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BoneAttachment3D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BoneAttachment3D.kt index 865c838e6c..0e60bf9db7 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BoneAttachment3D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BoneAttachment3D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -27,9 +24,7 @@ import kotlin.Unit import kotlin.jvm.JvmName /** - * This node selects a bone in a [Skeleton3D] and attaches to it. This means that the - * [BoneAttachment3D] node will either dynamically copy or override the 3D transform of the selected - * bone. + * This node selects a bone in a [Skeleton3D] and attaches to it. This means that the [BoneAttachment3D] node will either dynamically copy or override the 3D transform of the selected bone. */ @GodotBaseType public open class BoneAttachment3D : Node3D() { @@ -56,13 +51,9 @@ public open class BoneAttachment3D : Node3D() { } /** - * Whether the BoneAttachment3D node will override the bone pose of the bone it is attached to. - * When set to `true`, the BoneAttachment3D node can change the pose of the bone. When set to - * `false`, the BoneAttachment3D will always be set to the bone's transform. + * Whether the BoneAttachment3D node will override the bone pose of the bone it is attached to. When set to `true`, the BoneAttachment3D node can change the pose of the bone. When set to `false`, the BoneAttachment3D will always be set to the bone's transform. * - * **Note:** This override performs interruptively in the skeleton update process using signals - * due to the old design. It may cause unintended behavior when used at the same time with - * [SkeletonModifier3D]. + * **Note:** This override performs interruptively in the skeleton update process using signals due to the old design. It may cause unintended behavior when used at the same time with [SkeletonModifier3D]. */ public final inline var overridePose: Boolean @JvmName("overridePoseProperty") @@ -72,7 +63,7 @@ public open class BoneAttachment3D : Node3D() { setOverridePose(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(107, scriptIndex) } @@ -85,7 +76,7 @@ public open class BoneAttachment3D : Node3D() { return (TransferContext.readReturnValue(OBJECT) as Skeleton3D?) } - public final fun setBoneName(boneName: String): Unit { + public final fun setBoneName(boneName: String) { TransferContext.writeArguments(STRING to boneName) TransferContext.callMethod(ptr, MethodBindings.setBoneNamePtr, NIL) } @@ -96,7 +87,7 @@ public open class BoneAttachment3D : Node3D() { return (TransferContext.readReturnValue(STRING) as String) } - public final fun setBoneIdx(boneIdx: Int): Unit { + public final fun setBoneIdx(boneIdx: Int) { TransferContext.writeArguments(LONG to boneIdx.toLong()) TransferContext.callMethod(ptr, MethodBindings.setBoneIdxPtr, NIL) } @@ -108,16 +99,14 @@ public open class BoneAttachment3D : Node3D() { } /** - * A function that is called automatically when the [Skeleton3D] is updated. This function is - * where the [BoneAttachment3D] node updates its position so it is correctly bound when it is *not* - * set to override the bone pose. + * A function that is called automatically when the [Skeleton3D] is updated. This function is where the [BoneAttachment3D] node updates its position so it is correctly bound when it is *not* set to override the bone pose. */ - public final fun onSkeletonUpdate(): Unit { + public final fun onSkeletonUpdate() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.onSkeletonUpdatePtr, NIL) } - public final fun setOverridePose(overridePose: Boolean): Unit { + public final fun setOverridePose(overridePose: Boolean) { TransferContext.writeArguments(BOOL to overridePose) TransferContext.callMethod(ptr, MethodBindings.setOverridePosePtr, NIL) } @@ -129,18 +118,15 @@ public open class BoneAttachment3D : Node3D() { } /** - * Sets whether the BoneAttachment3D node will use an external [Skeleton3D] node rather than - * attempting to use its parent node as the [Skeleton3D]. When set to `true`, the BoneAttachment3D - * node will use the external [Skeleton3D] node set in [setExternalSkeleton]. + * Sets whether the BoneAttachment3D node will use an external [Skeleton3D] node rather than attempting to use its parent node as the [Skeleton3D]. When set to `true`, the BoneAttachment3D node will use the external [Skeleton3D] node set in [setExternalSkeleton]. */ - public final fun setUseExternalSkeleton(useExternalSkeleton: Boolean): Unit { + public final fun setUseExternalSkeleton(useExternalSkeleton: Boolean) { TransferContext.writeArguments(BOOL to useExternalSkeleton) TransferContext.callMethod(ptr, MethodBindings.setUseExternalSkeletonPtr, NIL) } /** - * Returns whether the BoneAttachment3D node is using an external [Skeleton3D] rather than - * attempting to use its parent node as the [Skeleton3D]. + * Returns whether the BoneAttachment3D node is using an external [Skeleton3D] rather than attempting to use its parent node as the [Skeleton3D]. */ public final fun getUseExternalSkeleton(): Boolean { TransferContext.writeArguments() @@ -149,10 +135,9 @@ public open class BoneAttachment3D : Node3D() { } /** - * Sets the [NodePath] to the external skeleton that the BoneAttachment3D node should use. See - * [setUseExternalSkeleton] to enable the external [Skeleton3D] node. + * Sets the [NodePath] to the external skeleton that the BoneAttachment3D node should use. See [setUseExternalSkeleton] to enable the external [Skeleton3D] node. */ - public final fun setExternalSkeleton(externalSkeleton: NodePath): Unit { + public final fun setExternalSkeleton(externalSkeleton: NodePath) { TransferContext.writeArguments(NODE_PATH to externalSkeleton) TransferContext.callMethod(ptr, MethodBindings.setExternalSkeletonPtr, NIL) } @@ -167,49 +152,47 @@ public open class BoneAttachment3D : Node3D() { } /** - * Sets the [NodePath] to the external skeleton that the BoneAttachment3D node should use. See - * [setUseExternalSkeleton] to enable the external [Skeleton3D] node. + * Sets the [NodePath] to the external skeleton that the BoneAttachment3D node should use. See [setUseExternalSkeleton] to enable the external [Skeleton3D] node. */ - public final fun setExternalSkeleton(externalSkeleton: String) = - setExternalSkeleton(externalSkeleton.asCachedNodePath()) + public final fun setExternalSkeleton(externalSkeleton: String): Unit = setExternalSkeleton(externalSkeleton.asCachedNodePath()) public companion object public object MethodBindings { internal val getSkeletonPtr: VoidPtr = - TypeManager.getMethodBindPtr("BoneAttachment3D", "get_skeleton", 1814733083) + TypeManager.getMethodBindPtr("BoneAttachment3D", "get_skeleton", 1_814_733_083) internal val setBoneNamePtr: VoidPtr = - TypeManager.getMethodBindPtr("BoneAttachment3D", "set_bone_name", 83702148) + TypeManager.getMethodBindPtr("BoneAttachment3D", "set_bone_name", 83_702_148) internal val getBoneNamePtr: VoidPtr = - TypeManager.getMethodBindPtr("BoneAttachment3D", "get_bone_name", 201670096) + TypeManager.getMethodBindPtr("BoneAttachment3D", "get_bone_name", 201_670_096) internal val setBoneIdxPtr: VoidPtr = - TypeManager.getMethodBindPtr("BoneAttachment3D", "set_bone_idx", 1286410249) + TypeManager.getMethodBindPtr("BoneAttachment3D", "set_bone_idx", 1_286_410_249) internal val getBoneIdxPtr: VoidPtr = - TypeManager.getMethodBindPtr("BoneAttachment3D", "get_bone_idx", 3905245786) + TypeManager.getMethodBindPtr("BoneAttachment3D", "get_bone_idx", 3_905_245_786) internal val onSkeletonUpdatePtr: VoidPtr = - TypeManager.getMethodBindPtr("BoneAttachment3D", "on_skeleton_update", 3218959716) + TypeManager.getMethodBindPtr("BoneAttachment3D", "on_skeleton_update", 3_218_959_716) internal val setOverridePosePtr: VoidPtr = - TypeManager.getMethodBindPtr("BoneAttachment3D", "set_override_pose", 2586408642) + TypeManager.getMethodBindPtr("BoneAttachment3D", "set_override_pose", 2_586_408_642) internal val getOverridePosePtr: VoidPtr = - TypeManager.getMethodBindPtr("BoneAttachment3D", "get_override_pose", 36873697) + TypeManager.getMethodBindPtr("BoneAttachment3D", "get_override_pose", 36_873_697) internal val setUseExternalSkeletonPtr: VoidPtr = - TypeManager.getMethodBindPtr("BoneAttachment3D", "set_use_external_skeleton", 2586408642) + TypeManager.getMethodBindPtr("BoneAttachment3D", "set_use_external_skeleton", 2_586_408_642) internal val getUseExternalSkeletonPtr: VoidPtr = - TypeManager.getMethodBindPtr("BoneAttachment3D", "get_use_external_skeleton", 36873697) + TypeManager.getMethodBindPtr("BoneAttachment3D", "get_use_external_skeleton", 36_873_697) internal val setExternalSkeletonPtr: VoidPtr = - TypeManager.getMethodBindPtr("BoneAttachment3D", "set_external_skeleton", 1348162250) + TypeManager.getMethodBindPtr("BoneAttachment3D", "set_external_skeleton", 1_348_162_250) internal val getExternalSkeletonPtr: VoidPtr = - TypeManager.getMethodBindPtr("BoneAttachment3D", "get_external_skeleton", 4075236667) + TypeManager.getMethodBindPtr("BoneAttachment3D", "get_external_skeleton", 4_075_236_667) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BoneMap.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BoneMap.kt index 1a69fe5754..6e33cb3db4 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BoneMap.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BoneMap.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -23,23 +20,19 @@ import kotlin.Unit import kotlin.jvm.JvmName /** - * This class contains a dictionary that uses a list of bone names in [SkeletonProfile] as key - * names. + * This class contains a dictionary that uses a list of bone names in [SkeletonProfile] as key names. * - * By assigning the actual [Skeleton3D] bone name as the key value, it maps the [Skeleton3D] to the - * [SkeletonProfile]. + * By assigning the actual [Skeleton3D] bone name as the key value, it maps the [Skeleton3D] to the [SkeletonProfile]. */ @GodotBaseType public open class BoneMap : Resource() { /** - * This signal is emitted when change the key value in the [BoneMap]. This is used to validate - * mapping and to update [BoneMap] editor. + * This signal is emitted when change the key value in the [BoneMap]. This is used to validate mapping and to update [BoneMap] editor. */ public val boneMapUpdated: Signal0 by Signal0 /** - * This signal is emitted when change the value in profile or change the reference of profile. - * This is used to update key names in the [BoneMap] and to redraw the [BoneMap] editor. + * This signal is emitted when change the value in profile or change the reference of profile. This is used to update key names in the [BoneMap] and to redraw the [BoneMap] editor. */ public val profileUpdated: Signal0 by Signal0 @@ -54,7 +47,7 @@ public open class BoneMap : Resource() { setProfile(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(108, scriptIndex) } @@ -64,7 +57,7 @@ public open class BoneMap : Resource() { return (TransferContext.readReturnValue(OBJECT) as SkeletonProfile?) } - public final fun setProfile(profile: SkeletonProfile?): Unit { + public final fun setProfile(profile: SkeletonProfile?) { TransferContext.writeArguments(OBJECT to profile) TransferContext.callMethod(ptr, MethodBindings.setProfilePtr, NIL) } @@ -85,15 +78,13 @@ public open class BoneMap : Resource() { * * In the retargeting process, the setting bone name is the bone name of the source skeleton. */ - public final fun setSkeletonBoneName(profileBoneName: StringName, skeletonBoneName: StringName): - Unit { + public final fun setSkeletonBoneName(profileBoneName: StringName, skeletonBoneName: StringName) { TransferContext.writeArguments(STRING_NAME to profileBoneName, STRING_NAME to skeletonBoneName) TransferContext.callMethod(ptr, MethodBindings.setSkeletonBoneNamePtr, NIL) } /** - * Returns a profile bone name having [skeletonBoneName]. If not found, an empty [StringName] will - * be returned. + * Returns a profile bone name having [skeletonBoneName]. If not found, an empty [StringName] will be returned. * * In the retargeting process, the returned bone name is the bone name of the target skeleton. */ @@ -108,42 +99,38 @@ public open class BoneMap : Resource() { * * In the retargeting process, the returned bone name is the bone name of the source skeleton. */ - public final fun getSkeletonBoneName(profileBoneName: String): StringName = - getSkeletonBoneName(profileBoneName.asCachedStringName()) + public final fun getSkeletonBoneName(profileBoneName: String): StringName = getSkeletonBoneName(profileBoneName.asCachedStringName()) /** * Maps a skeleton bone name to [profileBoneName]. * * In the retargeting process, the setting bone name is the bone name of the source skeleton. */ - public final fun setSkeletonBoneName(profileBoneName: String, skeletonBoneName: String) = - setSkeletonBoneName(profileBoneName.asCachedStringName(), skeletonBoneName.asCachedStringName()) + public final fun setSkeletonBoneName(profileBoneName: String, skeletonBoneName: String): Unit = setSkeletonBoneName(profileBoneName.asCachedStringName(), skeletonBoneName.asCachedStringName()) /** - * Returns a profile bone name having [skeletonBoneName]. If not found, an empty [StringName] will - * be returned. + * Returns a profile bone name having [skeletonBoneName]. If not found, an empty [StringName] will be returned. * * In the retargeting process, the returned bone name is the bone name of the target skeleton. */ - public final fun findProfileBoneName(skeletonBoneName: String): StringName = - findProfileBoneName(skeletonBoneName.asCachedStringName()) + public final fun findProfileBoneName(skeletonBoneName: String): StringName = findProfileBoneName(skeletonBoneName.asCachedStringName()) public companion object public object MethodBindings { internal val getProfilePtr: VoidPtr = - TypeManager.getMethodBindPtr("BoneMap", "get_profile", 4291782652) + TypeManager.getMethodBindPtr("BoneMap", "get_profile", 4_291_782_652) internal val setProfilePtr: VoidPtr = - TypeManager.getMethodBindPtr("BoneMap", "set_profile", 3870374136) + TypeManager.getMethodBindPtr("BoneMap", "set_profile", 3_870_374_136) internal val getSkeletonBoneNamePtr: VoidPtr = - TypeManager.getMethodBindPtr("BoneMap", "get_skeleton_bone_name", 1965194235) + TypeManager.getMethodBindPtr("BoneMap", "get_skeleton_bone_name", 1_965_194_235) internal val setSkeletonBoneNamePtr: VoidPtr = - TypeManager.getMethodBindPtr("BoneMap", "set_skeleton_bone_name", 3740211285) + TypeManager.getMethodBindPtr("BoneMap", "set_skeleton_bone_name", 3_740_211_285) internal val findProfileBoneNamePtr: VoidPtr = - TypeManager.getMethodBindPtr("BoneMap", "find_profile_bone_name", 1965194235) + TypeManager.getMethodBindPtr("BoneMap", "find_profile_bone_name", 1_965_194_235) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BoxContainer.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BoxContainer.kt index c1a36dfbb2..854dad9ff4 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BoxContainer.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BoxContainer.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -18,18 +15,15 @@ import kotlin.Boolean import kotlin.Int import kotlin.Long import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * A container that arranges its child controls horizontally or vertically, rearranging them - * automatically when their minimum size changes. + * A container that arranges its child controls horizontally or vertically, rearranging them automatically when their minimum size changes. */ @GodotBaseType public open class BoxContainer : Container() { /** - * The alignment of the container's children (must be one of [ALIGNMENT_BEGIN], - * [ALIGNMENT_CENTER], or [ALIGNMENT_END]). + * The alignment of the container's children (must be one of [ALIGNMENT_BEGIN], [ALIGNMENT_CENTER], or [ALIGNMENT_END]). */ public final inline var alignment: AlignmentMode @JvmName("alignmentProperty") @@ -52,13 +46,12 @@ public open class BoxContainer : Container() { setVertical(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(109, scriptIndex) } /** - * Adds a [Control] node to the box as a spacer. If [begin] is `true`, it will insert the - * [Control] node in front of all other children. + * Adds a [Control] node to the box as a spacer. If [begin] is `true`, it will insert the [Control] node in front of all other children. */ public final fun addSpacer(begin: Boolean): Control? { TransferContext.writeArguments(BOOL to begin) @@ -66,7 +59,7 @@ public open class BoxContainer : Container() { return (TransferContext.readReturnValue(OBJECT) as Control?) } - public final fun setAlignment(alignment: AlignmentMode): Unit { + public final fun setAlignment(alignment: AlignmentMode) { TransferContext.writeArguments(LONG to alignment.id) TransferContext.callMethod(ptr, MethodBindings.setAlignmentPtr, NIL) } @@ -77,7 +70,7 @@ public open class BoxContainer : Container() { return AlignmentMode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setVertical(vertical: Boolean): Unit { + public final fun setVertical(vertical: Boolean) { TransferContext.writeArguments(BOOL to vertical) TransferContext.callMethod(ptr, MethodBindings.setVerticalPtr, NIL) } @@ -92,8 +85,7 @@ public open class BoxContainer : Container() { id: Long, ) { /** - * The child controls will be arranged at the beginning of the container, i.e. top if - * orientation is vertical, left if orientation is horizontal (right for RTL layout). + * The child controls will be arranged at the beginning of the container, i.e. top if orientation is vertical, left if orientation is horizontal (right for RTL layout). */ BEGIN(0), /** @@ -101,8 +93,7 @@ public open class BoxContainer : Container() { */ CENTER(1), /** - * The child controls will be arranged at the end of the container, i.e. bottom if orientation - * is vertical, right if orientation is horizontal (left for RTL layout). + * The child controls will be arranged at the end of the container, i.e. bottom if orientation is vertical, right if orientation is horizontal (left for RTL layout). */ END(2), ; @@ -121,18 +112,18 @@ public open class BoxContainer : Container() { public object MethodBindings { internal val addSpacerPtr: VoidPtr = - TypeManager.getMethodBindPtr("BoxContainer", "add_spacer", 1326660695) + TypeManager.getMethodBindPtr("BoxContainer", "add_spacer", 1_326_660_695) internal val setAlignmentPtr: VoidPtr = - TypeManager.getMethodBindPtr("BoxContainer", "set_alignment", 2456745134) + TypeManager.getMethodBindPtr("BoxContainer", "set_alignment", 2_456_745_134) internal val getAlignmentPtr: VoidPtr = - TypeManager.getMethodBindPtr("BoxContainer", "get_alignment", 1915476527) + TypeManager.getMethodBindPtr("BoxContainer", "get_alignment", 1_915_476_527) internal val setVerticalPtr: VoidPtr = - TypeManager.getMethodBindPtr("BoxContainer", "set_vertical", 2586408642) + TypeManager.getMethodBindPtr("BoxContainer", "set_vertical", 2_586_408_642) internal val isVerticalPtr: VoidPtr = - TypeManager.getMethodBindPtr("BoxContainer", "is_vertical", 36873697) + TypeManager.getMethodBindPtr("BoxContainer", "is_vertical", 36_873_697) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BoxMesh.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BoxMesh.kt index e042feefde..9291b9b630 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BoxMesh.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BoxMesh.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -25,13 +22,9 @@ import kotlin.jvm.JvmName /** * Generate an axis-aligned box [PrimitiveMesh]. * - * The box's UV layout is arranged in a 3×2 layout that allows texturing each face individually. To - * apply the same texture on all faces, change the material's UV property to `Vector3(3, 2, 1)`. This - * is equivalent to adding `UV *= vec2(3.0, 2.0)` in a vertex shader. + * The box's UV layout is arranged in a 3×2 layout that allows texturing each face individually. To apply the same texture on all faces, change the material's UV property to `Vector3(3, 2, 1)`. This is equivalent to adding `UV *= vec2(3.0, 2.0)` in a vertex shader. * - * **Note:** When using a large textured [BoxMesh] (e.g. as a floor), you may stumble upon UV - * jittering issues depending on the camera angle. To solve this, increase [subdivideDepth], - * [subdivideHeight] and [subdivideWidth] until you no longer notice UV jittering. + * **Note:** When using a large textured [BoxMesh] (e.g. as a floor), you may stumble upon UV jittering issues depending on the camera angle. To solve this, increase [subdivideDepth], [subdivideHeight] and [subdivideWidth] until you no longer notice UV jittering. */ @GodotBaseType public open class BoxMesh : PrimitiveMesh() { @@ -39,11 +32,8 @@ public open class BoxMesh : PrimitiveMesh() { * The box's width, height and depth. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var size: Vector3 @@ -87,7 +77,7 @@ public open class BoxMesh : PrimitiveMesh() { setSubdivideDepth(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(110, scriptIndex) } @@ -110,7 +100,7 @@ public open class BoxMesh : PrimitiveMesh() { size = this } - public final fun setSize(size: Vector3): Unit { + public final fun setSize(size: Vector3) { TransferContext.writeArguments(VECTOR3 to size) TransferContext.callMethod(ptr, MethodBindings.setSizePtr, NIL) } @@ -121,7 +111,7 @@ public open class BoxMesh : PrimitiveMesh() { return (TransferContext.readReturnValue(VECTOR3) as Vector3) } - public final fun setSubdivideWidth(subdivide: Int): Unit { + public final fun setSubdivideWidth(subdivide: Int) { TransferContext.writeArguments(LONG to subdivide.toLong()) TransferContext.callMethod(ptr, MethodBindings.setSubdivideWidthPtr, NIL) } @@ -132,7 +122,7 @@ public open class BoxMesh : PrimitiveMesh() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setSubdivideHeight(divisions: Int): Unit { + public final fun setSubdivideHeight(divisions: Int) { TransferContext.writeArguments(LONG to divisions.toLong()) TransferContext.callMethod(ptr, MethodBindings.setSubdivideHeightPtr, NIL) } @@ -143,7 +133,7 @@ public open class BoxMesh : PrimitiveMesh() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setSubdivideDepth(divisions: Int): Unit { + public final fun setSubdivideDepth(divisions: Int) { TransferContext.writeArguments(LONG to divisions.toLong()) TransferContext.callMethod(ptr, MethodBindings.setSubdivideDepthPtr, NIL) } @@ -158,27 +148,27 @@ public open class BoxMesh : PrimitiveMesh() { public object MethodBindings { internal val setSizePtr: VoidPtr = - TypeManager.getMethodBindPtr("BoxMesh", "set_size", 3460891852) + TypeManager.getMethodBindPtr("BoxMesh", "set_size", 3_460_891_852) internal val getSizePtr: VoidPtr = - TypeManager.getMethodBindPtr("BoxMesh", "get_size", 3360562783) + TypeManager.getMethodBindPtr("BoxMesh", "get_size", 3_360_562_783) internal val setSubdivideWidthPtr: VoidPtr = - TypeManager.getMethodBindPtr("BoxMesh", "set_subdivide_width", 1286410249) + TypeManager.getMethodBindPtr("BoxMesh", "set_subdivide_width", 1_286_410_249) internal val getSubdivideWidthPtr: VoidPtr = - TypeManager.getMethodBindPtr("BoxMesh", "get_subdivide_width", 3905245786) + TypeManager.getMethodBindPtr("BoxMesh", "get_subdivide_width", 3_905_245_786) internal val setSubdivideHeightPtr: VoidPtr = - TypeManager.getMethodBindPtr("BoxMesh", "set_subdivide_height", 1286410249) + TypeManager.getMethodBindPtr("BoxMesh", "set_subdivide_height", 1_286_410_249) internal val getSubdivideHeightPtr: VoidPtr = - TypeManager.getMethodBindPtr("BoxMesh", "get_subdivide_height", 3905245786) + TypeManager.getMethodBindPtr("BoxMesh", "get_subdivide_height", 3_905_245_786) internal val setSubdivideDepthPtr: VoidPtr = - TypeManager.getMethodBindPtr("BoxMesh", "set_subdivide_depth", 1286410249) + TypeManager.getMethodBindPtr("BoxMesh", "set_subdivide_depth", 1_286_410_249) internal val getSubdivideDepthPtr: VoidPtr = - TypeManager.getMethodBindPtr("BoxMesh", "get_subdivide_depth", 3905245786) + TypeManager.getMethodBindPtr("BoxMesh", "get_subdivide_depth", 3_905_245_786) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BoxOccluder3D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BoxOccluder3D.kt index 0631cc7c2e..a5907ef6df 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BoxOccluder3D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BoxOccluder3D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -31,11 +28,8 @@ public open class BoxOccluder3D : Occluder3D() { * The box's size in 3D units. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var size: Vector3 @@ -46,7 +40,7 @@ public open class BoxOccluder3D : Occluder3D() { setSize(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(111, scriptIndex) } @@ -69,7 +63,7 @@ public open class BoxOccluder3D : Occluder3D() { size = this } - public final fun setSize(size: Vector3): Unit { + public final fun setSize(size: Vector3) { TransferContext.writeArguments(VECTOR3 to size) TransferContext.callMethod(ptr, MethodBindings.setSizePtr, NIL) } @@ -84,9 +78,9 @@ public open class BoxOccluder3D : Occluder3D() { public object MethodBindings { internal val setSizePtr: VoidPtr = - TypeManager.getMethodBindPtr("BoxOccluder3D", "set_size", 3460891852) + TypeManager.getMethodBindPtr("BoxOccluder3D", "set_size", 3_460_891_852) internal val getSizePtr: VoidPtr = - TypeManager.getMethodBindPtr("BoxOccluder3D", "get_size", 3360562783) + TypeManager.getMethodBindPtr("BoxOccluder3D", "get_size", 3_360_562_783) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BoxShape3D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BoxShape3D.kt index 8bb82554a7..ebd2d40f97 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BoxShape3D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/BoxShape3D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -21,11 +18,9 @@ import kotlin.Unit import kotlin.jvm.JvmName /** - * A 3D box shape, intended for use in physics. Usually used to provide a shape for a - * [CollisionShape3D]. + * A 3D box shape, intended for use in physics. Usually used to provide a shape for a [CollisionShape3D]. * - * **Performance:** [BoxShape3D] is fast to check collisions against. It is faster than - * [CapsuleShape3D] and [CylinderShape3D], but slower than [SphereShape3D]. + * **Performance:** [BoxShape3D] is fast to check collisions against. It is faster than [CapsuleShape3D] and [CylinderShape3D], but slower than [SphereShape3D]. */ @GodotBaseType public open class BoxShape3D : Shape3D() { @@ -33,11 +28,8 @@ public open class BoxShape3D : Shape3D() { * The box's width, height and depth. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var size: Vector3 @@ -48,7 +40,7 @@ public open class BoxShape3D : Shape3D() { setSize(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(112, scriptIndex) } @@ -71,7 +63,7 @@ public open class BoxShape3D : Shape3D() { size = this } - public final fun setSize(size: Vector3): Unit { + public final fun setSize(size: Vector3) { TransferContext.writeArguments(VECTOR3 to size) TransferContext.callMethod(ptr, MethodBindings.setSizePtr, NIL) } @@ -86,9 +78,9 @@ public open class BoxShape3D : Shape3D() { public object MethodBindings { internal val setSizePtr: VoidPtr = - TypeManager.getMethodBindPtr("BoxShape3D", "set_size", 3460891852) + TypeManager.getMethodBindPtr("BoxShape3D", "set_size", 3_460_891_852) internal val getSizePtr: VoidPtr = - TypeManager.getMethodBindPtr("BoxShape3D", "get_size", 3360562783) + TypeManager.getMethodBindPtr("BoxShape3D", "get_size", 3_360_562_783) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Button.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Button.kt index be8ddd807b..11490cbc43 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Button.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Button.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -22,12 +19,10 @@ import kotlin.Int import kotlin.Long import kotlin.String import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * [Button] is the standard themed button. It can contain text and an icon, and it will display them - * according to the current [Theme]. + * [Button] is the standard themed button. It can contain text and an icon, and it will display them according to the current [Theme]. * * **Example:** Create a button and connect a method that will be called when the button is pressed: * @@ -61,9 +56,7 @@ import kotlin.jvm.JvmName * * See also [BaseButton] which contains common properties and methods associated with this node. * - * **Note:** Buttons do not detect touch input and therefore don't support multitouch, since mouse - * emulation can only press one button at a given time. Use [TouchScreenButton] for buttons that - * trigger gameplay movement or actions. + * **Note:** Buttons do not detect touch input and therefore don't support multitouch, since mouse emulation can only press one button at a given time. Use [TouchScreenButton] for buttons that trigger gameplay movement or actions. */ @GodotBaseType public open class Button : BaseButton() { @@ -81,8 +74,7 @@ public open class Button : BaseButton() { /** * Button's icon, if text is present the icon will be placed before the text. * - * To edit margin and spacing of the icon, use [theme_item h_separation] theme property and - * `content_margin_*` properties of the used [StyleBox]es. + * To edit margin and spacing of the icon, use [theme_item h_separation] theme property and `content_margin_*` properties of the used [StyleBox]es. */ public final inline var icon: Texture2D? @JvmName("iconProperty") @@ -115,8 +107,7 @@ public open class Button : BaseButton() { } /** - * Sets the clipping behavior when the text exceeds the node's bounding rectangle. See - * [TextServer.OverrunBehavior] for a description of all modes. + * Sets the clipping behavior when the text exceeds the node's bounding rectangle. See [TextServer.OverrunBehavior] for a description of all modes. */ public final inline var textOverrunBehavior: TextServer.OverrunBehavior @JvmName("textOverrunBehaviorProperty") @@ -127,8 +118,7 @@ public open class Button : BaseButton() { } /** - * If set to something other than [TextServer.AUTOWRAP_OFF], the text gets wrapped inside the - * node's bounding rectangle. + * If set to something other than [TextServer.AUTOWRAP_OFF], the text gets wrapped inside the node's bounding rectangle. */ public final inline var autowrapMode: TextServer.AutowrapMode @JvmName("autowrapModeProperty") @@ -139,9 +129,7 @@ public open class Button : BaseButton() { } /** - * If `true`, text that is too large to fit the button is clipped horizontally. If `false`, the - * button will always be wide enough to hold the text. The text is not vertically clipped, and the - * button's height is not affected by this property. + * If `true`, text that is too large to fit the button is clipped horizontally. If `false`, the button will always be wide enough to hold the text. The text is not vertically clipped, and the button's height is not affected by this property. */ public final inline var clipText: Boolean @JvmName("clipTextProperty") @@ -152,9 +140,7 @@ public open class Button : BaseButton() { } /** - * Specifies if the icon should be aligned horizontally to the left, right, or center of a button. - * Uses the same [HorizontalAlignment] constants as the text alignment. If centered horizontally and - * vertically, text will draw on top of the icon. + * Specifies if the icon should be aligned horizontally to the left, right, or center of a button. Uses the same [HorizontalAlignment] constants as the text alignment. If centered horizontally and vertically, text will draw on top of the icon. */ public final inline var iconAlignment: HorizontalAlignment @JvmName("iconAlignmentProperty") @@ -165,9 +151,7 @@ public open class Button : BaseButton() { } /** - * Specifies if the icon should be aligned vertically to the top, bottom, or center of a button. - * Uses the same [VerticalAlignment] constants as the text alignment. If centered horizontally and - * vertically, text will draw on top of the icon. + * Specifies if the icon should be aligned vertically to the top, bottom, or center of a button. Uses the same [VerticalAlignment] constants as the text alignment. If centered horizontally and vertically, text will draw on top of the icon. */ public final inline var verticalIconAlignment: VerticalAlignment @JvmName("verticalIconAlignmentProperty") @@ -178,8 +162,7 @@ public open class Button : BaseButton() { } /** - * When enabled, the button's icon will expand/shrink to fit the button's size while keeping its - * aspect. See also [theme_item icon_max_width]. + * When enabled, the button's icon will expand/shrink to fit the button's size while keeping its aspect. See also [theme_item icon_max_width]. */ public final inline var expandIcon: Boolean @JvmName("expandIconProperty") @@ -201,8 +184,7 @@ public open class Button : BaseButton() { } /** - * Language code used for line-breaking and text shaping algorithms, if left empty current locale - * is used instead. + * Language code used for line-breaking and text shaping algorithms, if left empty current locale is used instead. */ public final inline var language: String @JvmName("languageProperty") @@ -212,11 +194,11 @@ public open class Button : BaseButton() { setLanguage(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(113, scriptIndex) } - public final fun setText(text: String): Unit { + public final fun setText(text: String) { TransferContext.writeArguments(STRING to text) TransferContext.callMethod(ptr, MethodBindings.setTextPtr, NIL) } @@ -227,7 +209,7 @@ public open class Button : BaseButton() { return (TransferContext.readReturnValue(STRING) as String) } - public final fun setTextOverrunBehavior(overrunBehavior: TextServer.OverrunBehavior): Unit { + public final fun setTextOverrunBehavior(overrunBehavior: TextServer.OverrunBehavior) { TransferContext.writeArguments(LONG to overrunBehavior.id) TransferContext.callMethod(ptr, MethodBindings.setTextOverrunBehaviorPtr, NIL) } @@ -238,7 +220,7 @@ public open class Button : BaseButton() { return TextServer.OverrunBehavior.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setAutowrapMode(autowrapMode: TextServer.AutowrapMode): Unit { + public final fun setAutowrapMode(autowrapMode: TextServer.AutowrapMode) { TransferContext.writeArguments(LONG to autowrapMode.id) TransferContext.callMethod(ptr, MethodBindings.setAutowrapModePtr, NIL) } @@ -249,7 +231,7 @@ public open class Button : BaseButton() { return TextServer.AutowrapMode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setTextDirection(direction: Control.TextDirection): Unit { + public final fun setTextDirection(direction: Control.TextDirection) { TransferContext.writeArguments(LONG to direction.id) TransferContext.callMethod(ptr, MethodBindings.setTextDirectionPtr, NIL) } @@ -260,7 +242,7 @@ public open class Button : BaseButton() { return Control.TextDirection.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setLanguage(language: String): Unit { + public final fun setLanguage(language: String) { TransferContext.writeArguments(STRING to language) TransferContext.callMethod(ptr, MethodBindings.setLanguagePtr, NIL) } @@ -271,7 +253,7 @@ public open class Button : BaseButton() { return (TransferContext.readReturnValue(STRING) as String) } - public final fun setButtonIcon(texture: Texture2D?): Unit { + public final fun setButtonIcon(texture: Texture2D?) { TransferContext.writeArguments(OBJECT to texture) TransferContext.callMethod(ptr, MethodBindings.setButtonIconPtr, NIL) } @@ -282,7 +264,7 @@ public open class Button : BaseButton() { return (TransferContext.readReturnValue(OBJECT) as Texture2D?) } - public final fun setFlat(enabled: Boolean): Unit { + public final fun setFlat(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setFlatPtr, NIL) } @@ -293,7 +275,7 @@ public open class Button : BaseButton() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setClipText(enabled: Boolean): Unit { + public final fun setClipText(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setClipTextPtr, NIL) } @@ -304,7 +286,7 @@ public open class Button : BaseButton() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setTextAlignment(alignment: HorizontalAlignment): Unit { + public final fun setTextAlignment(alignment: HorizontalAlignment) { TransferContext.writeArguments(LONG to alignment.id) TransferContext.callMethod(ptr, MethodBindings.setTextAlignmentPtr, NIL) } @@ -315,7 +297,7 @@ public open class Button : BaseButton() { return HorizontalAlignment.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setIconAlignment(iconAlignment: HorizontalAlignment): Unit { + public final fun setIconAlignment(iconAlignment: HorizontalAlignment) { TransferContext.writeArguments(LONG to iconAlignment.id) TransferContext.callMethod(ptr, MethodBindings.setIconAlignmentPtr, NIL) } @@ -326,7 +308,7 @@ public open class Button : BaseButton() { return HorizontalAlignment.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setVerticalIconAlignment(verticalIconAlignment: VerticalAlignment): Unit { + public final fun setVerticalIconAlignment(verticalIconAlignment: VerticalAlignment) { TransferContext.writeArguments(LONG to verticalIconAlignment.id) TransferContext.callMethod(ptr, MethodBindings.setVerticalIconAlignmentPtr, NIL) } @@ -337,7 +319,7 @@ public open class Button : BaseButton() { return VerticalAlignment.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setExpandIcon(enabled: Boolean): Unit { + public final fun setExpandIcon(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setExpandIconPtr, NIL) } @@ -351,73 +333,75 @@ public open class Button : BaseButton() { public companion object public object MethodBindings { - internal val setTextPtr: VoidPtr = TypeManager.getMethodBindPtr("Button", "set_text", 83702148) + internal val setTextPtr: VoidPtr = + TypeManager.getMethodBindPtr("Button", "set_text", 83_702_148) - internal val getTextPtr: VoidPtr = TypeManager.getMethodBindPtr("Button", "get_text", 201670096) + internal val getTextPtr: VoidPtr = + TypeManager.getMethodBindPtr("Button", "get_text", 201_670_096) internal val setTextOverrunBehaviorPtr: VoidPtr = - TypeManager.getMethodBindPtr("Button", "set_text_overrun_behavior", 1008890932) + TypeManager.getMethodBindPtr("Button", "set_text_overrun_behavior", 1_008_890_932) internal val getTextOverrunBehaviorPtr: VoidPtr = - TypeManager.getMethodBindPtr("Button", "get_text_overrun_behavior", 3779142101) + TypeManager.getMethodBindPtr("Button", "get_text_overrun_behavior", 3_779_142_101) internal val setAutowrapModePtr: VoidPtr = - TypeManager.getMethodBindPtr("Button", "set_autowrap_mode", 3289138044) + TypeManager.getMethodBindPtr("Button", "set_autowrap_mode", 3_289_138_044) internal val getAutowrapModePtr: VoidPtr = - TypeManager.getMethodBindPtr("Button", "get_autowrap_mode", 1549071663) + TypeManager.getMethodBindPtr("Button", "get_autowrap_mode", 1_549_071_663) internal val setTextDirectionPtr: VoidPtr = - TypeManager.getMethodBindPtr("Button", "set_text_direction", 119160795) + TypeManager.getMethodBindPtr("Button", "set_text_direction", 119_160_795) internal val getTextDirectionPtr: VoidPtr = - TypeManager.getMethodBindPtr("Button", "get_text_direction", 797257663) + TypeManager.getMethodBindPtr("Button", "get_text_direction", 797_257_663) internal val setLanguagePtr: VoidPtr = - TypeManager.getMethodBindPtr("Button", "set_language", 83702148) + TypeManager.getMethodBindPtr("Button", "set_language", 83_702_148) internal val getLanguagePtr: VoidPtr = - TypeManager.getMethodBindPtr("Button", "get_language", 201670096) + TypeManager.getMethodBindPtr("Button", "get_language", 201_670_096) internal val setButtonIconPtr: VoidPtr = - TypeManager.getMethodBindPtr("Button", "set_button_icon", 4051416890) + TypeManager.getMethodBindPtr("Button", "set_button_icon", 4_051_416_890) internal val getButtonIconPtr: VoidPtr = - TypeManager.getMethodBindPtr("Button", "get_button_icon", 3635182373) + TypeManager.getMethodBindPtr("Button", "get_button_icon", 3_635_182_373) internal val setFlatPtr: VoidPtr = - TypeManager.getMethodBindPtr("Button", "set_flat", 2586408642) + TypeManager.getMethodBindPtr("Button", "set_flat", 2_586_408_642) - internal val isFlatPtr: VoidPtr = TypeManager.getMethodBindPtr("Button", "is_flat", 36873697) + internal val isFlatPtr: VoidPtr = TypeManager.getMethodBindPtr("Button", "is_flat", 36_873_697) internal val setClipTextPtr: VoidPtr = - TypeManager.getMethodBindPtr("Button", "set_clip_text", 2586408642) + TypeManager.getMethodBindPtr("Button", "set_clip_text", 2_586_408_642) internal val getClipTextPtr: VoidPtr = - TypeManager.getMethodBindPtr("Button", "get_clip_text", 36873697) + TypeManager.getMethodBindPtr("Button", "get_clip_text", 36_873_697) internal val setTextAlignmentPtr: VoidPtr = - TypeManager.getMethodBindPtr("Button", "set_text_alignment", 2312603777) + TypeManager.getMethodBindPtr("Button", "set_text_alignment", 2_312_603_777) internal val getTextAlignmentPtr: VoidPtr = - TypeManager.getMethodBindPtr("Button", "get_text_alignment", 341400642) + TypeManager.getMethodBindPtr("Button", "get_text_alignment", 341_400_642) internal val setIconAlignmentPtr: VoidPtr = - TypeManager.getMethodBindPtr("Button", "set_icon_alignment", 2312603777) + TypeManager.getMethodBindPtr("Button", "set_icon_alignment", 2_312_603_777) internal val getIconAlignmentPtr: VoidPtr = - TypeManager.getMethodBindPtr("Button", "get_icon_alignment", 341400642) + TypeManager.getMethodBindPtr("Button", "get_icon_alignment", 341_400_642) internal val setVerticalIconAlignmentPtr: VoidPtr = - TypeManager.getMethodBindPtr("Button", "set_vertical_icon_alignment", 1796458609) + TypeManager.getMethodBindPtr("Button", "set_vertical_icon_alignment", 1_796_458_609) internal val getVerticalIconAlignmentPtr: VoidPtr = - TypeManager.getMethodBindPtr("Button", "get_vertical_icon_alignment", 3274884059) + TypeManager.getMethodBindPtr("Button", "get_vertical_icon_alignment", 3_274_884_059) internal val setExpandIconPtr: VoidPtr = - TypeManager.getMethodBindPtr("Button", "set_expand_icon", 2586408642) + TypeManager.getMethodBindPtr("Button", "set_expand_icon", 2_586_408_642) internal val isExpandIconPtr: VoidPtr = - TypeManager.getMethodBindPtr("Button", "is_expand_icon", 36873697) + TypeManager.getMethodBindPtr("Button", "is_expand_icon", 36_873_697) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ButtonGroup.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ButtonGroup.kt index d75187a183..521b39a548 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ButtonGroup.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ButtonGroup.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -19,13 +16,10 @@ import godot.core.VariantParser.OBJECT import kotlin.Boolean import kotlin.Int import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * A group of [BaseButton]-derived buttons. The buttons in a [ButtonGroup] are treated like radio - * buttons: No more than one button can be pressed at a time. Some types of buttons (such as - * [CheckBox]) may have a special appearance in this state. + * A group of [BaseButton]-derived buttons. The buttons in a [ButtonGroup] are treated like radio buttons: No more than one button can be pressed at a time. Some types of buttons (such as [CheckBox]) may have a special appearance in this state. * * Every member of a [ButtonGroup] should have [BaseButton.toggleMode] set to `true`. */ @@ -47,7 +41,7 @@ public open class ButtonGroup : Resource() { setAllowUnpress(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(114, scriptIndex) } @@ -61,8 +55,7 @@ public open class ButtonGroup : Resource() { } /** - * Returns an [Array] of [Button]s who have this as their [ButtonGroup] (see - * [BaseButton.buttonGroup]). + * Returns an [Array] of [Button]s who have this as their [ButtonGroup] (see [BaseButton.buttonGroup]). */ public final fun getButtons(): VariantArray { TransferContext.writeArguments() @@ -70,7 +63,7 @@ public open class ButtonGroup : Resource() { return (TransferContext.readReturnValue(ARRAY) as VariantArray) } - public final fun setAllowUnpress(enabled: Boolean): Unit { + public final fun setAllowUnpress(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setAllowUnpressPtr, NIL) } @@ -85,15 +78,15 @@ public open class ButtonGroup : Resource() { public object MethodBindings { internal val getPressedButtonPtr: VoidPtr = - TypeManager.getMethodBindPtr("ButtonGroup", "get_pressed_button", 3886434893) + TypeManager.getMethodBindPtr("ButtonGroup", "get_pressed_button", 3_886_434_893) internal val getButtonsPtr: VoidPtr = - TypeManager.getMethodBindPtr("ButtonGroup", "get_buttons", 2915620761) + TypeManager.getMethodBindPtr("ButtonGroup", "get_buttons", 2_915_620_761) internal val setAllowUnpressPtr: VoidPtr = - TypeManager.getMethodBindPtr("ButtonGroup", "set_allow_unpress", 2586408642) + TypeManager.getMethodBindPtr("ButtonGroup", "set_allow_unpress", 2_586_408_642) internal val isAllowUnpressPtr: VoidPtr = - TypeManager.getMethodBindPtr("ButtonGroup", "is_allow_unpress", 2240911060) + TypeManager.getMethodBindPtr("ButtonGroup", "is_allow_unpress", 2_240_911_060) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CPUParticles2D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CPUParticles2D.kt index 5e6e2742f3..58be850f70 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CPUParticles2D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CPUParticles2D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -39,22 +36,17 @@ import kotlin.jvm.JvmOverloads /** * CPU-based 2D particle node used to create a variety of particle systems and effects. * - * See also [GPUParticles2D], which provides the same functionality with hardware acceleration, but - * may not run on older devices. + * See also [GPUParticles2D], which provides the same functionality with hardware acceleration, but may not run on older devices. */ @GodotBaseType public open class CPUParticles2D : Node2D() { /** - * Emitted when all active particles have finished processing. When [oneShot] is disabled, - * particles will process continuously, so this is never emitted. + * Emitted when all active particles have finished processing. When [oneShot] is disabled, particles will process continuously, so this is never emitted. */ public val finished: Signal0 by Signal0 /** - * If `true`, particles are being emitted. [emitting] can be used to start and stop particles from - * emitting. However, if [oneShot] is `true` setting [emitting] to `true` will not restart the - * emission cycle until after all active particles finish processing. You can use the [signal - * finished] signal to be notified once all active particles finish processing. + * If `true`, particles are being emitted. [emitting] can be used to start and stop particles from emitting. However, if [oneShot] is `true` setting [emitting] to `true` will not restart the emission cycle until after all active particles finish processing. You can use the [signal finished] signal to be notified once all active particles finish processing. */ public final inline var emitting: Boolean @JvmName("emittingProperty") @@ -98,8 +90,7 @@ public open class CPUParticles2D : Node2D() { } /** - * If `true`, only one emission cycle occurs. If set `true` during a cycle, emission will stop at - * the cycle's end. + * If `true`, only one emission cycle occurs. If set `true` during a cycle, emission will stop at the cycle's end. */ public final inline var oneShot: Boolean @JvmName("oneShotProperty") @@ -121,8 +112,7 @@ public open class CPUParticles2D : Node2D() { } /** - * Particle system's running speed scaling ratio. A value of `0` can be used to pause the - * particles. + * Particle system's running speed scaling ratio. A value of `0` can be used to pause the particles. */ public final inline var speedScale: Double @JvmName("speedScaleProperty") @@ -133,8 +123,7 @@ public open class CPUParticles2D : Node2D() { } /** - * How rapidly particles in an emission cycle are emitted. If greater than `0`, there will be a - * gap in emissions before the next cycle begins. + * How rapidly particles in an emission cycle are emitted. If greater than `0`, there will be a gap in emissions before the next cycle begins. */ public final inline var explosiveness: Float @JvmName("explosivenessProperty") @@ -156,9 +145,7 @@ public open class CPUParticles2D : Node2D() { } /** - * If `true`, particles will use the same seed for every simulation using the seed defined in - * [seed]. This is useful for situations where the visual outcome should be consistent across - * replays, for example when using Movie Maker mode. + * If `true`, particles will use the same seed for every simulation using the seed defined in [seed]. This is useful for situations where the visual outcome should be consistent across replays, for example when using Movie Maker mode. */ public final inline var useFixedSeed: Boolean @JvmName("useFixedSeedProperty") @@ -191,9 +178,7 @@ public open class CPUParticles2D : Node2D() { } /** - * The particle system's frame rate is fixed to a value. For example, changing the value to 2 will - * make the particles render at 2 frames per second. Note this does not slow down the simulation of - * the particle system itself. + * The particle system's frame rate is fixed to a value. For example, changing the value to 2 will make the particles render at 2 frames per second. Note this does not slow down the simulation of the particle system itself. */ public final inline var fixedFps: Int @JvmName("fixedFpsProperty") @@ -204,8 +189,7 @@ public open class CPUParticles2D : Node2D() { } /** - * If `true`, results in fractional delta calculation which has a smoother particles display - * effect. + * If `true`, results in fractional delta calculation which has a smoother particles display effect. */ public final inline var fractDelta: Boolean @JvmName("fractDeltaProperty") @@ -216,10 +200,7 @@ public open class CPUParticles2D : Node2D() { } /** - * If `true`, particles use the parent node's coordinate space (known as local coordinates). This - * will cause particles to move and rotate along the [CPUParticles2D] node (and its parents) when it - * is moved or rotated. If `false`, particles use global coordinates; they will not move or rotate - * along the [CPUParticles2D] node (and its parents) when it is moved or rotated. + * If `true`, particles use the parent node's coordinate space (known as local coordinates). This will cause particles to move and rotate along the [CPUParticles2D] node (and its parents) when it is moved or rotated. If `false`, particles use global coordinates; they will not move or rotate along the [CPUParticles2D] node (and its parents) when it is moved or rotated. */ public final inline var localCoords: Boolean @JvmName("localCoordsProperty") @@ -266,11 +247,8 @@ public open class CPUParticles2D : Node2D() { * The rectangle's extents if [emissionShape] is set to [EMISSION_SHAPE_RECTANGLE]. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var emissionRectExtents: Vector2 @@ -282,15 +260,11 @@ public open class CPUParticles2D : Node2D() { } /** - * Sets the initial positions to spawn particles when using [EMISSION_SHAPE_POINTS] or - * [EMISSION_SHAPE_DIRECTED_POINTS]. + * Sets the initial positions to spawn particles when using [EMISSION_SHAPE_POINTS] or [EMISSION_SHAPE_DIRECTED_POINTS]. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var emissionPoints: PackedVector2Array @@ -302,15 +276,11 @@ public open class CPUParticles2D : Node2D() { } /** - * Sets the direction the particles will be emitted in when using - * [EMISSION_SHAPE_DIRECTED_POINTS]. + * Sets the direction the particles will be emitted in when using [EMISSION_SHAPE_DIRECTED_POINTS]. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var emissionNormals: PackedVector2Array @@ -322,8 +292,7 @@ public open class CPUParticles2D : Node2D() { } /** - * Sets the [Color]s to modulate particles by when using [EMISSION_SHAPE_POINTS] or - * [EMISSION_SHAPE_DIRECTED_POINTS]. + * Sets the [Color]s to modulate particles by when using [EMISSION_SHAPE_POINTS] or [EMISSION_SHAPE_DIRECTED_POINTS]. */ public final inline var emissionColors: PackedColorArray @JvmName("emissionColorsProperty") @@ -348,11 +317,8 @@ public open class CPUParticles2D : Node2D() { * Unit vector specifying the particles' emission direction. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var direction: Vector2 @@ -378,11 +344,8 @@ public open class CPUParticles2D : Node2D() { * Gravity applied to every particle. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var gravity: Vector2 @@ -405,8 +368,7 @@ public open class CPUParticles2D : Node2D() { } /** - * Maximum initial velocity magnitude for each particle. Direction comes from [direction] and - * [spread]. + * Maximum initial velocity magnitude for each particle. Direction comes from [direction] and [spread]. */ public final inline var initialVelocityMax: Float @JvmName("initialVelocityMaxProperty") @@ -428,8 +390,7 @@ public open class CPUParticles2D : Node2D() { } /** - * Maximum initial angular velocity (rotation speed) applied to each particle in *degrees* per - * second. + * Maximum initial angular velocity (rotation speed) applied to each particle in *degrees* per second. */ public final inline var angularVelocityMax: Float @JvmName("angularVelocityMaxProperty") @@ -462,8 +423,7 @@ public open class CPUParticles2D : Node2D() { } /** - * Maximum orbital velocity applied to each particle. Makes the particles circle around origin. - * Specified in number of full rotations around origin per second. + * Maximum orbital velocity applied to each particle. Makes the particles circle around origin. Specified in number of full rotations around origin per second. */ public final inline var orbitVelocityMax: Float @JvmName("orbitVelocityMaxProperty") @@ -529,8 +489,7 @@ public open class CPUParticles2D : Node2D() { } /** - * Maximum radial acceleration applied to each particle. Makes particle accelerate away from the - * origin or towards it if negative. + * Maximum radial acceleration applied to each particle. Makes particle accelerate away from the origin or towards it if negative. */ public final inline var radialAccelMax: Float @JvmName("radialAccelMaxProperty") @@ -563,8 +522,7 @@ public open class CPUParticles2D : Node2D() { } /** - * Maximum tangential acceleration applied to each particle. Tangential acceleration is - * perpendicular to the particle's velocity giving the particles a swirling motion. + * Maximum tangential acceleration applied to each particle. Tangential acceleration is perpendicular to the particle's velocity giving the particles a swirling motion. */ public final inline var tangentialAccelMax: Float @JvmName("tangentialAccelMaxProperty") @@ -597,8 +555,7 @@ public open class CPUParticles2D : Node2D() { } /** - * The maximum rate at which particles lose velocity. For example value of `100` means that the - * particle will go from `100` velocity to `0` in `1` second. + * The maximum rate at which particles lose velocity. For example value of `100` means that the particle will go from `100` velocity to `0` in `1` second. */ public final inline var dampingMax: Float @JvmName("dampingMaxProperty") @@ -686,8 +643,7 @@ public open class CPUParticles2D : Node2D() { } /** - * If `true`, the scale curve will be split into x and y components. See [scaleCurveX] and - * [scaleCurveY]. + * If `true`, the scale curve will be split into x and y components. See [scaleCurveX] and [scaleCurveY]. */ public final inline var splitScale: Boolean @JvmName("splitScaleProperty") @@ -727,11 +683,8 @@ public open class CPUParticles2D : Node2D() { * Each particle's initial color. If [texture] is defined, it will be multiplied by this color. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var color: Color @@ -743,8 +696,7 @@ public open class CPUParticles2D : Node2D() { } /** - * Each particle's color will vary along this [Gradient] over its lifetime (multiplied with - * [color]). + * Each particle's color will vary along this [Gradient] over its lifetime (multiplied with [color]). */ public final inline var colorRamp: Gradient? @JvmName("colorRampProperty") @@ -810,11 +762,9 @@ public open class CPUParticles2D : Node2D() { } /** - * Maximum particle animation speed. Animation speed of `1` means that the particles will make - * full `0` to `1` offset cycle during lifetime, `2` means `2` cycles etc. + * Maximum particle animation speed. Animation speed of `1` means that the particles will make full `0` to `1` offset cycle during lifetime, `2` means `2` cycles etc. * - * With animation speed greater than `1`, remember to enable - * [CanvasItemMaterial.particlesAnimLoop] property if you want the animation to repeat. + * With animation speed greater than `1`, remember to enable [CanvasItemMaterial.particlesAnimLoop] property if you want the animation to repeat. */ public final inline var animSpeedMax: Float @JvmName("animSpeedMaxProperty") @@ -847,8 +797,7 @@ public open class CPUParticles2D : Node2D() { } /** - * Maximum animation offset that corresponds to frame index in the texture. `0` is the first - * frame, `1` is the last one. See [CanvasItemMaterial.particlesAnimation]. + * Maximum animation offset that corresponds to frame index in the texture. `0` is the first frame, `1` is the last one. See [CanvasItemMaterial.particlesAnimation]. */ public final inline var animOffsetMax: Float @JvmName("animOffsetMaxProperty") @@ -869,7 +818,7 @@ public open class CPUParticles2D : Node2D() { setParamCurve(CPUParticles2D.Parameter.ANIM_OFFSET, value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(115, scriptIndex) } @@ -887,8 +836,7 @@ public open class CPUParticles2D : Node2D() { * The rectangle's extents if [emissionShape] is set to [EMISSION_SHAPE_RECTANGLE]. */ @CoreTypeHelper - public final fun emissionRectExtentsMutate(block: Vector2.() -> Unit): Vector2 = - emissionRectExtents.apply { + public final fun emissionRectExtentsMutate(block: Vector2.() -> Unit): Vector2 = emissionRectExtents.apply { block(this) emissionRectExtents = this } @@ -904,27 +852,22 @@ public open class CPUParticles2D : Node2D() { * cpuparticles2d.emissionPoints = myCoreType * `````` * - * Sets the initial positions to spawn particles when using [EMISSION_SHAPE_POINTS] or - * [EMISSION_SHAPE_DIRECTED_POINTS]. + * Sets the initial positions to spawn particles when using [EMISSION_SHAPE_POINTS] or [EMISSION_SHAPE_DIRECTED_POINTS]. */ @CoreTypeHelper - public final fun emissionPointsMutate(block: PackedVector2Array.() -> Unit): PackedVector2Array = - emissionPoints.apply { + public final fun emissionPointsMutate(block: PackedVector2Array.() -> Unit): PackedVector2Array = emissionPoints.apply { block(this) emissionPoints = this } /** * This is a helper function for [emissionPoints] to make dealing with local copies easier. - * Allow to directly modify each element of the local copy of the property and assign it back to - * the Object. + * Allow to directly modify each element of the local copy of the property and assign it back to the Object. * - * Sets the initial positions to spawn particles when using [EMISSION_SHAPE_POINTS] or - * [EMISSION_SHAPE_DIRECTED_POINTS]. + * Sets the initial positions to spawn particles when using [EMISSION_SHAPE_POINTS] or [EMISSION_SHAPE_DIRECTED_POINTS]. */ @CoreTypeHelper - public final fun emissionPointsMutateEach(block: (index: Int, `value`: Vector2) -> Unit): - PackedVector2Array = emissionPoints.apply { + public final fun emissionPointsMutateEach(block: (index: Int, `value`: Vector2) -> Unit): PackedVector2Array = emissionPoints.apply { this.forEachIndexed { index, value -> block(index, value) this[index] = value @@ -943,27 +886,22 @@ public open class CPUParticles2D : Node2D() { * cpuparticles2d.emissionNormals = myCoreType * `````` * - * Sets the direction the particles will be emitted in when using - * [EMISSION_SHAPE_DIRECTED_POINTS]. + * Sets the direction the particles will be emitted in when using [EMISSION_SHAPE_DIRECTED_POINTS]. */ @CoreTypeHelper - public final fun emissionNormalsMutate(block: PackedVector2Array.() -> Unit): PackedVector2Array = - emissionNormals.apply { + public final fun emissionNormalsMutate(block: PackedVector2Array.() -> Unit): PackedVector2Array = emissionNormals.apply { block(this) emissionNormals = this } /** * This is a helper function for [emissionNormals] to make dealing with local copies easier. - * Allow to directly modify each element of the local copy of the property and assign it back to - * the Object. + * Allow to directly modify each element of the local copy of the property and assign it back to the Object. * - * Sets the direction the particles will be emitted in when using - * [EMISSION_SHAPE_DIRECTED_POINTS]. + * Sets the direction the particles will be emitted in when using [EMISSION_SHAPE_DIRECTED_POINTS]. */ @CoreTypeHelper - public final fun emissionNormalsMutateEach(block: (index: Int, `value`: Vector2) -> Unit): - PackedVector2Array = emissionNormals.apply { + public final fun emissionNormalsMutateEach(block: (index: Int, `value`: Vector2) -> Unit): PackedVector2Array = emissionNormals.apply { this.forEachIndexed { index, value -> block(index, value) this[index] = value @@ -1028,62 +966,62 @@ public open class CPUParticles2D : Node2D() { color = this } - public final fun setEmitting(emitting: Boolean): Unit { + public final fun setEmitting(emitting: Boolean) { TransferContext.writeArguments(BOOL to emitting) TransferContext.callMethod(ptr, MethodBindings.setEmittingPtr, NIL) } - public final fun setAmount(amount: Int): Unit { + public final fun setAmount(amount: Int) { TransferContext.writeArguments(LONG to amount.toLong()) TransferContext.callMethod(ptr, MethodBindings.setAmountPtr, NIL) } - public final fun setLifetime(secs: Double): Unit { + public final fun setLifetime(secs: Double) { TransferContext.writeArguments(DOUBLE to secs) TransferContext.callMethod(ptr, MethodBindings.setLifetimePtr, NIL) } - public final fun setOneShot(enable: Boolean): Unit { + public final fun setOneShot(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setOneShotPtr, NIL) } - public final fun setPreProcessTime(secs: Double): Unit { + public final fun setPreProcessTime(secs: Double) { TransferContext.writeArguments(DOUBLE to secs) TransferContext.callMethod(ptr, MethodBindings.setPreProcessTimePtr, NIL) } - public final fun setExplosivenessRatio(ratio: Float): Unit { + public final fun setExplosivenessRatio(ratio: Float) { TransferContext.writeArguments(DOUBLE to ratio.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setExplosivenessRatioPtr, NIL) } - public final fun setRandomnessRatio(ratio: Float): Unit { + public final fun setRandomnessRatio(ratio: Float) { TransferContext.writeArguments(DOUBLE to ratio.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setRandomnessRatioPtr, NIL) } - public final fun setLifetimeRandomness(random: Double): Unit { + public final fun setLifetimeRandomness(random: Double) { TransferContext.writeArguments(DOUBLE to random) TransferContext.callMethod(ptr, MethodBindings.setLifetimeRandomnessPtr, NIL) } - public final fun setUseLocalCoordinates(enable: Boolean): Unit { + public final fun setUseLocalCoordinates(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setUseLocalCoordinatesPtr, NIL) } - public final fun setFixedFps(fps: Int): Unit { + public final fun setFixedFps(fps: Int) { TransferContext.writeArguments(LONG to fps.toLong()) TransferContext.callMethod(ptr, MethodBindings.setFixedFpsPtr, NIL) } - public final fun setFractionalDelta(enable: Boolean): Unit { + public final fun setFractionalDelta(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setFractionalDeltaPtr, NIL) } - public final fun setSpeedScale(scale: Double): Unit { + public final fun setSpeedScale(scale: Double) { TransferContext.writeArguments(DOUBLE to scale) TransferContext.callMethod(ptr, MethodBindings.setSpeedScalePtr, NIL) } @@ -1091,10 +1029,9 @@ public open class CPUParticles2D : Node2D() { /** * Requests the particles to process for extra process time during a single frame. * - * Useful for particle playback, if used in combination with [useFixedSeed] or by calling - * [restart] with parameter `keep_seed` set to `true`. + * Useful for particle playback, if used in combination with [useFixedSeed] or by calling [restart] with parameter `keep_seed` set to `true`. */ - public final fun requestParticlesProcess(processTime: Float): Unit { + public final fun requestParticlesProcess(processTime: Float) { TransferContext.writeArguments(DOUBLE to processTime.toDouble()) TransferContext.callMethod(ptr, MethodBindings.requestParticlesProcessPtr, NIL) } @@ -1171,7 +1108,7 @@ public open class CPUParticles2D : Node2D() { return (TransferContext.readReturnValue(DOUBLE) as Double) } - public final fun setUseFixedSeed(useFixedSeed: Boolean): Unit { + public final fun setUseFixedSeed(useFixedSeed: Boolean) { TransferContext.writeArguments(BOOL to useFixedSeed) TransferContext.callMethod(ptr, MethodBindings.setUseFixedSeedPtr, NIL) } @@ -1182,7 +1119,7 @@ public open class CPUParticles2D : Node2D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setSeed(seed: Long): Unit { + public final fun setSeed(seed: Long) { TransferContext.writeArguments(LONG to seed) TransferContext.callMethod(ptr, MethodBindings.setSeedPtr, NIL) } @@ -1193,7 +1130,7 @@ public open class CPUParticles2D : Node2D() { return (TransferContext.readReturnValue(LONG) as Long) } - public final fun setDrawOrder(order: DrawOrder): Unit { + public final fun setDrawOrder(order: DrawOrder) { TransferContext.writeArguments(LONG to order.id) TransferContext.callMethod(ptr, MethodBindings.setDrawOrderPtr, NIL) } @@ -1204,7 +1141,7 @@ public open class CPUParticles2D : Node2D() { return DrawOrder.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setTexture(texture: Texture2D?): Unit { + public final fun setTexture(texture: Texture2D?) { TransferContext.writeArguments(OBJECT to texture) TransferContext.callMethod(ptr, MethodBindings.setTexturePtr, NIL) } @@ -1218,16 +1155,15 @@ public open class CPUParticles2D : Node2D() { /** * Restarts the particle emitter. * - * If [keepSeed] is `true`, the current random seed will be preserved. Useful for seeking and - * playback. + * If [keepSeed] is `true`, the current random seed will be preserved. Useful for seeking and playback. */ @JvmOverloads - public final fun restart(keepSeed: Boolean = false): Unit { + public final fun restart(keepSeed: Boolean = false) { TransferContext.writeArguments(BOOL to keepSeed) TransferContext.callMethod(ptr, MethodBindings.restartPtr, NIL) } - public final fun setDirection(direction: Vector2): Unit { + public final fun setDirection(direction: Vector2) { TransferContext.writeArguments(VECTOR2 to direction) TransferContext.callMethod(ptr, MethodBindings.setDirectionPtr, NIL) } @@ -1238,7 +1174,7 @@ public open class CPUParticles2D : Node2D() { return (TransferContext.readReturnValue(VECTOR2) as Vector2) } - public final fun setSpread(spread: Float): Unit { + public final fun setSpread(spread: Float) { TransferContext.writeArguments(DOUBLE to spread.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setSpreadPtr, NIL) } @@ -1252,7 +1188,7 @@ public open class CPUParticles2D : Node2D() { /** * Sets the minimum value for the given parameter. */ - public final fun setParamMin(`param`: Parameter, `value`: Float): Unit { + public final fun setParamMin(`param`: Parameter, `value`: Float) { TransferContext.writeArguments(LONG to param.id, DOUBLE to value.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setParamMinPtr, NIL) } @@ -1269,7 +1205,7 @@ public open class CPUParticles2D : Node2D() { /** * Sets the maximum value for the given parameter. */ - public final fun setParamMax(`param`: Parameter, `value`: Float): Unit { + public final fun setParamMax(`param`: Parameter, `value`: Float) { TransferContext.writeArguments(LONG to param.id, DOUBLE to value.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setParamMaxPtr, NIL) } @@ -1286,7 +1222,7 @@ public open class CPUParticles2D : Node2D() { /** * Sets the [Curve] of the parameter specified by [Parameter]. Should be a unit [Curve]. */ - public final fun setParamCurve(`param`: Parameter, curve: Curve?): Unit { + public final fun setParamCurve(`param`: Parameter, curve: Curve?) { TransferContext.writeArguments(LONG to param.id, OBJECT to curve) TransferContext.callMethod(ptr, MethodBindings.setParamCurvePtr, NIL) } @@ -1300,7 +1236,7 @@ public open class CPUParticles2D : Node2D() { return (TransferContext.readReturnValue(OBJECT) as Curve?) } - public final fun setColor(color: Color): Unit { + public final fun setColor(color: Color) { TransferContext.writeArguments(COLOR to color) TransferContext.callMethod(ptr, MethodBindings.setColorPtr, NIL) } @@ -1311,7 +1247,7 @@ public open class CPUParticles2D : Node2D() { return (TransferContext.readReturnValue(COLOR) as Color) } - public final fun setColorRamp(ramp: Gradient?): Unit { + public final fun setColorRamp(ramp: Gradient?) { TransferContext.writeArguments(OBJECT to ramp) TransferContext.callMethod(ptr, MethodBindings.setColorRampPtr, NIL) } @@ -1322,7 +1258,7 @@ public open class CPUParticles2D : Node2D() { return (TransferContext.readReturnValue(OBJECT) as Gradient?) } - public final fun setColorInitialRamp(ramp: Gradient?): Unit { + public final fun setColorInitialRamp(ramp: Gradient?) { TransferContext.writeArguments(OBJECT to ramp) TransferContext.callMethod(ptr, MethodBindings.setColorInitialRampPtr, NIL) } @@ -1336,7 +1272,7 @@ public open class CPUParticles2D : Node2D() { /** * Enables or disables the given flag (see [ParticleFlags] for options). */ - public final fun setParticleFlag(particleFlag: ParticleFlags, enable: Boolean): Unit { + public final fun setParticleFlag(particleFlag: ParticleFlags, enable: Boolean) { TransferContext.writeArguments(LONG to particleFlag.id, BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setParticleFlagPtr, NIL) } @@ -1350,7 +1286,7 @@ public open class CPUParticles2D : Node2D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setEmissionShape(shape: EmissionShape): Unit { + public final fun setEmissionShape(shape: EmissionShape) { TransferContext.writeArguments(LONG to shape.id) TransferContext.callMethod(ptr, MethodBindings.setEmissionShapePtr, NIL) } @@ -1361,7 +1297,7 @@ public open class CPUParticles2D : Node2D() { return EmissionShape.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setEmissionSphereRadius(radius: Float): Unit { + public final fun setEmissionSphereRadius(radius: Float) { TransferContext.writeArguments(DOUBLE to radius.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setEmissionSphereRadiusPtr, NIL) } @@ -1372,7 +1308,7 @@ public open class CPUParticles2D : Node2D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setEmissionRectExtents(extents: Vector2): Unit { + public final fun setEmissionRectExtents(extents: Vector2) { TransferContext.writeArguments(VECTOR2 to extents) TransferContext.callMethod(ptr, MethodBindings.setEmissionRectExtentsPtr, NIL) } @@ -1383,7 +1319,7 @@ public open class CPUParticles2D : Node2D() { return (TransferContext.readReturnValue(VECTOR2) as Vector2) } - public final fun setEmissionPoints(array: PackedVector2Array): Unit { + public final fun setEmissionPoints(array: PackedVector2Array) { TransferContext.writeArguments(PACKED_VECTOR2_ARRAY to array) TransferContext.callMethod(ptr, MethodBindings.setEmissionPointsPtr, NIL) } @@ -1394,7 +1330,7 @@ public open class CPUParticles2D : Node2D() { return (TransferContext.readReturnValue(PACKED_VECTOR2_ARRAY) as PackedVector2Array) } - public final fun setEmissionNormals(array: PackedVector2Array): Unit { + public final fun setEmissionNormals(array: PackedVector2Array) { TransferContext.writeArguments(PACKED_VECTOR2_ARRAY to array) TransferContext.callMethod(ptr, MethodBindings.setEmissionNormalsPtr, NIL) } @@ -1405,7 +1341,7 @@ public open class CPUParticles2D : Node2D() { return (TransferContext.readReturnValue(PACKED_VECTOR2_ARRAY) as PackedVector2Array) } - public final fun setEmissionColors(array: PackedColorArray): Unit { + public final fun setEmissionColors(array: PackedColorArray) { TransferContext.writeArguments(PACKED_COLOR_ARRAY to array) TransferContext.callMethod(ptr, MethodBindings.setEmissionColorsPtr, NIL) } @@ -1422,7 +1358,7 @@ public open class CPUParticles2D : Node2D() { return (TransferContext.readReturnValue(VECTOR2) as Vector2) } - public final fun setGravity(accelVec: Vector2): Unit { + public final fun setGravity(accelVec: Vector2) { TransferContext.writeArguments(VECTOR2 to accelVec) TransferContext.callMethod(ptr, MethodBindings.setGravityPtr, NIL) } @@ -1433,7 +1369,7 @@ public open class CPUParticles2D : Node2D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setSplitScale(splitScale: Boolean): Unit { + public final fun setSplitScale(splitScale: Boolean) { TransferContext.writeArguments(BOOL to splitScale) TransferContext.callMethod(ptr, MethodBindings.setSplitScalePtr, NIL) } @@ -1444,7 +1380,7 @@ public open class CPUParticles2D : Node2D() { return (TransferContext.readReturnValue(OBJECT) as Curve?) } - public final fun setScaleCurveX(scaleCurve: Curve?): Unit { + public final fun setScaleCurveX(scaleCurve: Curve?) { TransferContext.writeArguments(OBJECT to scaleCurve) TransferContext.callMethod(ptr, MethodBindings.setScaleCurveXPtr, NIL) } @@ -1455,16 +1391,15 @@ public open class CPUParticles2D : Node2D() { return (TransferContext.readReturnValue(OBJECT) as Curve?) } - public final fun setScaleCurveY(scaleCurve: Curve?): Unit { + public final fun setScaleCurveY(scaleCurve: Curve?) { TransferContext.writeArguments(OBJECT to scaleCurve) TransferContext.callMethod(ptr, MethodBindings.setScaleCurveYPtr, NIL) } /** - * Sets this node's properties to match a given [GPUParticles2D] node with an assigned - * [ParticleProcessMaterial]. + * Sets this node's properties to match a given [GPUParticles2D] node with an assigned [ParticleProcessMaterial]. */ - public final fun convertFromParticles(particles: Node?): Unit { + public final fun convertFromParticles(particles: Node?) { TransferContext.writeArguments(OBJECT to particles) TransferContext.callMethod(ptr, MethodBindings.convertFromParticlesPtr, NIL) } @@ -1477,8 +1412,7 @@ public open class CPUParticles2D : Node2D() { */ INDEX(0), /** - * Particles are drawn in order of remaining lifetime. In other words, the particle with the - * highest lifetime is drawn at the front. + * Particles are drawn in order of remaining lifetime. In other words, the particle with the highest lifetime is drawn at the front. */ LIFETIME(1), ; @@ -1497,33 +1431,27 @@ public open class CPUParticles2D : Node2D() { id: Long, ) { /** - * Use with [setParamMin], [setParamMax], and [setParamCurve] to set initial velocity - * properties. + * Use with [setParamMin], [setParamMax], and [setParamCurve] to set initial velocity properties. */ INITIAL_LINEAR_VELOCITY(0), /** - * Use with [setParamMin], [setParamMax], and [setParamCurve] to set angular velocity - * properties. + * Use with [setParamMin], [setParamMax], and [setParamCurve] to set angular velocity properties. */ ANGULAR_VELOCITY(1), /** - * Use with [setParamMin], [setParamMax], and [setParamCurve] to set orbital velocity - * properties. + * Use with [setParamMin], [setParamMax], and [setParamCurve] to set orbital velocity properties. */ ORBIT_VELOCITY(2), /** - * Use with [setParamMin], [setParamMax], and [setParamCurve] to set linear acceleration - * properties. + * Use with [setParamMin], [setParamMax], and [setParamCurve] to set linear acceleration properties. */ LINEAR_ACCEL(3), /** - * Use with [setParamMin], [setParamMax], and [setParamCurve] to set radial acceleration - * properties. + * Use with [setParamMin], [setParamMax], and [setParamCurve] to set radial acceleration properties. */ RADIAL_ACCEL(4), /** - * Use with [setParamMin], [setParamMax], and [setParamCurve] to set tangential acceleration - * properties. + * Use with [setParamMin], [setParamMax], and [setParamCurve] to set tangential acceleration properties. */ TANGENTIAL_ACCEL(5), /** @@ -1547,8 +1475,7 @@ public open class CPUParticles2D : Node2D() { */ ANIM_SPEED(10), /** - * Use with [setParamMin], [setParamMax], and [setParamCurve] to set animation offset - * properties. + * Use with [setParamMin], [setParamMax], and [setParamCurve] to set animation offset properties. */ ANIM_OFFSET(11), /** @@ -1618,14 +1545,11 @@ public open class CPUParticles2D : Node2D() { */ RECTANGLE(3), /** - * Particles will be emitted at a position chosen randomly among [emissionPoints]. Particle - * color will be modulated by [emissionColors]. + * Particles will be emitted at a position chosen randomly among [emissionPoints]. Particle color will be modulated by [emissionColors]. */ POINTS(4), /** - * Particles will be emitted at a position chosen randomly among [emissionPoints]. Particle - * velocity and rotation will be set based on [emissionNormals]. Particle color will be modulated - * by [emissionColors]. + * Particles will be emitted at a position chosen randomly among [emissionPoints]. Particle velocity and rotation will be set based on [emissionNormals]. Particle color will be modulated by [emissionColors]. */ DIRECTED_POINTS(5), /** @@ -1648,222 +1572,222 @@ public open class CPUParticles2D : Node2D() { public object MethodBindings { internal val setEmittingPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_emitting", 2586408642) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_emitting", 2_586_408_642) internal val setAmountPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_amount", 1286410249) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_amount", 1_286_410_249) internal val setLifetimePtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_lifetime", 373806689) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_lifetime", 373_806_689) internal val setOneShotPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_one_shot", 2586408642) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_one_shot", 2_586_408_642) internal val setPreProcessTimePtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_pre_process_time", 373806689) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_pre_process_time", 373_806_689) internal val setExplosivenessRatioPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_explosiveness_ratio", 373806689) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_explosiveness_ratio", 373_806_689) internal val setRandomnessRatioPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_randomness_ratio", 373806689) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_randomness_ratio", 373_806_689) internal val setLifetimeRandomnessPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_lifetime_randomness", 373806689) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_lifetime_randomness", 373_806_689) internal val setUseLocalCoordinatesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_use_local_coordinates", 2586408642) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_use_local_coordinates", 2_586_408_642) internal val setFixedFpsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_fixed_fps", 1286410249) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_fixed_fps", 1_286_410_249) internal val setFractionalDeltaPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_fractional_delta", 2586408642) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_fractional_delta", 2_586_408_642) internal val setSpeedScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_speed_scale", 373806689) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_speed_scale", 373_806_689) internal val requestParticlesProcessPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "request_particles_process", 373806689) + TypeManager.getMethodBindPtr("CPUParticles2D", "request_particles_process", 373_806_689) internal val isEmittingPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "is_emitting", 36873697) + TypeManager.getMethodBindPtr("CPUParticles2D", "is_emitting", 36_873_697) internal val getAmountPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_amount", 3905245786) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_amount", 3_905_245_786) internal val getLifetimePtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_lifetime", 1740695150) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_lifetime", 1_740_695_150) internal val getOneShotPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_one_shot", 36873697) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_one_shot", 36_873_697) internal val getPreProcessTimePtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_pre_process_time", 1740695150) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_pre_process_time", 1_740_695_150) internal val getExplosivenessRatioPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_explosiveness_ratio", 1740695150) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_explosiveness_ratio", 1_740_695_150) internal val getRandomnessRatioPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_randomness_ratio", 1740695150) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_randomness_ratio", 1_740_695_150) internal val getLifetimeRandomnessPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_lifetime_randomness", 1740695150) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_lifetime_randomness", 1_740_695_150) internal val getUseLocalCoordinatesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_use_local_coordinates", 36873697) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_use_local_coordinates", 36_873_697) internal val getFixedFpsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_fixed_fps", 3905245786) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_fixed_fps", 3_905_245_786) internal val getFractionalDeltaPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_fractional_delta", 36873697) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_fractional_delta", 36_873_697) internal val getSpeedScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_speed_scale", 1740695150) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_speed_scale", 1_740_695_150) internal val setUseFixedSeedPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_use_fixed_seed", 2586408642) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_use_fixed_seed", 2_586_408_642) internal val getUseFixedSeedPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_use_fixed_seed", 36873697) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_use_fixed_seed", 36_873_697) internal val setSeedPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_seed", 1286410249) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_seed", 1_286_410_249) internal val getSeedPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_seed", 3905245786) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_seed", 3_905_245_786) internal val setDrawOrderPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_draw_order", 4183193490) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_draw_order", 4_183_193_490) internal val getDrawOrderPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_draw_order", 1668655735) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_draw_order", 1_668_655_735) internal val setTexturePtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_texture", 4051416890) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_texture", 4_051_416_890) internal val getTexturePtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_texture", 3635182373) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_texture", 3_635_182_373) internal val restartPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "restart", 107499316) + TypeManager.getMethodBindPtr("CPUParticles2D", "restart", 107_499_316) internal val setDirectionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_direction", 743155724) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_direction", 743_155_724) internal val getDirectionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_direction", 3341600327) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_direction", 3_341_600_327) internal val setSpreadPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_spread", 373806689) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_spread", 373_806_689) internal val getSpreadPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_spread", 1740695150) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_spread", 1_740_695_150) internal val setParamMinPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_param_min", 3320615296) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_param_min", 3_320_615_296) internal val getParamMinPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_param_min", 2038050600) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_param_min", 2_038_050_600) internal val setParamMaxPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_param_max", 3320615296) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_param_max", 3_320_615_296) internal val getParamMaxPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_param_max", 2038050600) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_param_max", 2_038_050_600) internal val setParamCurvePtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_param_curve", 2959350143) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_param_curve", 2_959_350_143) internal val getParamCurvePtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_param_curve", 2603158474) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_param_curve", 2_603_158_474) internal val setColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_color", 2920490490) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_color", 2_920_490_490) internal val getColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_color", 3444240500) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_color", 3_444_240_500) internal val setColorRampPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_color_ramp", 2756054477) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_color_ramp", 2_756_054_477) internal val getColorRampPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_color_ramp", 132272999) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_color_ramp", 132_272_999) internal val setColorInitialRampPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_color_initial_ramp", 2756054477) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_color_initial_ramp", 2_756_054_477) internal val getColorInitialRampPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_color_initial_ramp", 132272999) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_color_initial_ramp", 132_272_999) internal val setParticleFlagPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_particle_flag", 4178137949) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_particle_flag", 4_178_137_949) internal val getParticleFlagPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_particle_flag", 2829976507) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_particle_flag", 2_829_976_507) internal val setEmissionShapePtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_emission_shape", 393763892) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_emission_shape", 393_763_892) internal val getEmissionShapePtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_emission_shape", 1740246024) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_emission_shape", 1_740_246_024) internal val setEmissionSphereRadiusPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_emission_sphere_radius", 373806689) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_emission_sphere_radius", 373_806_689) internal val getEmissionSphereRadiusPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_emission_sphere_radius", 1740695150) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_emission_sphere_radius", 1_740_695_150) internal val setEmissionRectExtentsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_emission_rect_extents", 743155724) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_emission_rect_extents", 743_155_724) internal val getEmissionRectExtentsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_emission_rect_extents", 3341600327) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_emission_rect_extents", 3_341_600_327) internal val setEmissionPointsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_emission_points", 1509147220) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_emission_points", 1_509_147_220) internal val getEmissionPointsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_emission_points", 2961356807) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_emission_points", 2_961_356_807) internal val setEmissionNormalsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_emission_normals", 1509147220) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_emission_normals", 1_509_147_220) internal val getEmissionNormalsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_emission_normals", 2961356807) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_emission_normals", 2_961_356_807) internal val setEmissionColorsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_emission_colors", 3546319833) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_emission_colors", 3_546_319_833) internal val getEmissionColorsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_emission_colors", 1392750486) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_emission_colors", 1_392_750_486) internal val getGravityPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_gravity", 3341600327) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_gravity", 3_341_600_327) internal val setGravityPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_gravity", 743155724) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_gravity", 743_155_724) internal val getSplitScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_split_scale", 2240911060) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_split_scale", 2_240_911_060) internal val setSplitScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_split_scale", 2586408642) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_split_scale", 2_586_408_642) internal val getScaleCurveXPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_scale_curve_x", 2460114913) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_scale_curve_x", 2_460_114_913) internal val setScaleCurveXPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_scale_curve_x", 270443179) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_scale_curve_x", 270_443_179) internal val getScaleCurveYPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "get_scale_curve_y", 2460114913) + TypeManager.getMethodBindPtr("CPUParticles2D", "get_scale_curve_y", 2_460_114_913) internal val setScaleCurveYPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "set_scale_curve_y", 270443179) + TypeManager.getMethodBindPtr("CPUParticles2D", "set_scale_curve_y", 270_443_179) internal val convertFromParticlesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles2D", "convert_from_particles", 1078189570) + TypeManager.getMethodBindPtr("CPUParticles2D", "convert_from_particles", 1_078_189_570) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CPUParticles3D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CPUParticles3D.kt index b3d9cf5a0e..9aefe2ebe3 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CPUParticles3D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CPUParticles3D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -12,7 +9,6 @@ import godot.`annotation`.GodotBaseType import godot.`internal`.memory.TransferContext import godot.`internal`.reflection.TypeManager import godot.common.interop.VoidPtr -import godot.core.AABB import godot.core.Color import godot.core.PackedColorArray import godot.core.PackedVector3Array @@ -36,26 +32,23 @@ import kotlin.Suppress import kotlin.Unit import kotlin.jvm.JvmName import kotlin.jvm.JvmOverloads +import godot.core.AABB as CoreAABB +import godot.core.VariantParser.AABB as VariantParserAABB /** * CPU-based 3D particle node used to create a variety of particle systems and effects. * - * See also [GPUParticles3D], which provides the same functionality with hardware acceleration, but - * may not run on older devices. + * See also [GPUParticles3D], which provides the same functionality with hardware acceleration, but may not run on older devices. */ @GodotBaseType public open class CPUParticles3D : GeometryInstance3D() { /** - * Emitted when all active particles have finished processing. When [oneShot] is disabled, - * particles will process continuously, so this is never emitted. + * Emitted when all active particles have finished processing. When [oneShot] is disabled, particles will process continuously, so this is never emitted. */ public val finished: Signal0 by Signal0 /** - * If `true`, particles are being emitted. [emitting] can be used to start and stop particles from - * emitting. However, if [oneShot] is `true` setting [emitting] to `true` will not restart the - * emission cycle until after all active particles finish processing. You can use the [signal - * finished] signal to be notified once all active particles finish processing. + * If `true`, particles are being emitted. [emitting] can be used to start and stop particles from emitting. However, if [oneShot] is `true` setting [emitting] to `true` will not restart the emission cycle until after all active particles finish processing. You can use the [signal finished] signal to be notified once all active particles finish processing. */ public final inline var emitting: Boolean @JvmName("emittingProperty") @@ -88,8 +81,7 @@ public open class CPUParticles3D : GeometryInstance3D() { } /** - * If `true`, only one emission cycle occurs. If set `true` during a cycle, emission will stop at - * the cycle's end. + * If `true`, only one emission cycle occurs. If set `true` during a cycle, emission will stop at the cycle's end. */ public final inline var oneShot: Boolean @JvmName("oneShotProperty") @@ -111,8 +103,7 @@ public open class CPUParticles3D : GeometryInstance3D() { } /** - * Particle system's running speed scaling ratio. A value of `0` can be used to pause the - * particles. + * Particle system's running speed scaling ratio. A value of `0` can be used to pause the particles. */ public final inline var speedScale: Double @JvmName("speedScaleProperty") @@ -123,8 +114,7 @@ public open class CPUParticles3D : GeometryInstance3D() { } /** - * How rapidly particles in an emission cycle are emitted. If greater than `0`, there will be a - * gap in emissions before the next cycle begins. + * How rapidly particles in an emission cycle are emitted. If greater than `0`, there will be a gap in emissions before the next cycle begins. */ public final inline var explosiveness: Float @JvmName("explosivenessProperty") @@ -146,9 +136,7 @@ public open class CPUParticles3D : GeometryInstance3D() { } /** - * If `true`, particles will use the same seed for every simulation using the seed defined in - * [seed]. This is useful for situations where the visual outcome should be consistent across - * replays, for example when using Movie Maker mode. + * If `true`, particles will use the same seed for every simulation using the seed defined in [seed]. This is useful for situations where the visual outcome should be consistent across replays, for example when using Movie Maker mode. */ public final inline var useFixedSeed: Boolean @JvmName("useFixedSeedProperty") @@ -181,9 +169,7 @@ public open class CPUParticles3D : GeometryInstance3D() { } /** - * The particle system's frame rate is fixed to a value. For example, changing the value to 2 will - * make the particles render at 2 frames per second. Note this does not slow down the particle system - * itself. + * The particle system's frame rate is fixed to a value. For example, changing the value to 2 will make the particles render at 2 frames per second. Note this does not slow down the particle system itself. */ public final inline var fixedFps: Int @JvmName("fixedFpsProperty") @@ -194,8 +180,7 @@ public open class CPUParticles3D : GeometryInstance3D() { } /** - * If `true`, results in fractional delta calculation which has a smoother particles display - * effect. + * If `true`, results in fractional delta calculation which has a smoother particles display effect. */ public final inline var fractDelta: Boolean @JvmName("fractDeltaProperty") @@ -206,21 +191,16 @@ public open class CPUParticles3D : GeometryInstance3D() { } /** - * The [AABB] that determines the node's region which needs to be visible on screen for the - * particle system to be active. + * The [AABB] that determines the node's region which needs to be visible on screen for the particle system to be active. * - * Grow the box if particles suddenly appear/disappear when the node enters/exits the screen. The - * [AABB] can be grown via code or with the **Particles → Generate AABB** editor tool. + * Grow the box if particles suddenly appear/disappear when the node enters/exits the screen. The [AABB] can be grown via code or with the **Particles → Generate AABB** editor tool. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy - public final inline var visibilityAabb: AABB + public final inline var visibilityAabb: CoreAABB @JvmName("visibilityAabbProperty") get() = getVisibilityAabb() @JvmName("visibilityAabbProperty") @@ -229,10 +209,7 @@ public open class CPUParticles3D : GeometryInstance3D() { } /** - * If `true`, particles use the parent node's coordinate space (known as local coordinates). This - * will cause particles to move and rotate along the [CPUParticles3D] node (and its parents) when it - * is moved or rotated. If `false`, particles use global coordinates; they will not move or rotate - * along the [CPUParticles3D] node (and its parents) when it is moved or rotated. + * If `true`, particles use the parent node's coordinate space (known as local coordinates). This will cause particles to move and rotate along the [CPUParticles3D] node (and its parents) when it is moved or rotated. If `false`, particles use global coordinates; they will not move or rotate along the [CPUParticles3D] node (and its parents) when it is moved or rotated. */ public final inline var localCoords: Boolean @JvmName("localCoordsProperty") @@ -290,11 +267,8 @@ public open class CPUParticles3D : GeometryInstance3D() { * The rectangle's extents if [emissionShape] is set to [EMISSION_SHAPE_BOX]. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var emissionBoxExtents: Vector3 @@ -306,15 +280,11 @@ public open class CPUParticles3D : GeometryInstance3D() { } /** - * Sets the initial positions to spawn particles when using [EMISSION_SHAPE_POINTS] or - * [EMISSION_SHAPE_DIRECTED_POINTS]. + * Sets the initial positions to spawn particles when using [EMISSION_SHAPE_POINTS] or [EMISSION_SHAPE_DIRECTED_POINTS]. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var emissionPoints: PackedVector3Array @@ -326,15 +296,11 @@ public open class CPUParticles3D : GeometryInstance3D() { } /** - * Sets the direction the particles will be emitted in when using - * [EMISSION_SHAPE_DIRECTED_POINTS]. + * Sets the direction the particles will be emitted in when using [EMISSION_SHAPE_DIRECTED_POINTS]. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var emissionNormals: PackedVector3Array @@ -346,13 +312,9 @@ public open class CPUParticles3D : GeometryInstance3D() { } /** - * Sets the [Color]s to modulate particles by when using [EMISSION_SHAPE_POINTS] or - * [EMISSION_SHAPE_DIRECTED_POINTS]. + * Sets the [Color]s to modulate particles by when using [EMISSION_SHAPE_POINTS] or [EMISSION_SHAPE_DIRECTED_POINTS]. * - * **Note:** [emissionColors] multiplies the particle mesh's vertex colors. To have a visible - * effect on a [BaseMaterial3D], [BaseMaterial3D.vertexColorUseAsAlbedo] *must* be `true`. For a - * [ShaderMaterial], `ALBEDO *= COLOR.rgb;` must be inserted in the shader's `fragment()` function. - * Otherwise, [emissionColors] will have no visible effect. + * **Note:** [emissionColors] multiplies the particle mesh's vertex colors. To have a visible effect on a [BaseMaterial3D], [BaseMaterial3D.vertexColorUseAsAlbedo] *must* be `true`. For a [ShaderMaterial], `ALBEDO *= COLOR.rgb;` must be inserted in the shader's `fragment()` function. Otherwise, [emissionColors] will have no visible effect. */ public final inline var emissionColors: PackedColorArray @JvmName("emissionColorsProperty") @@ -366,11 +328,8 @@ public open class CPUParticles3D : GeometryInstance3D() { * The axis of the ring when using the emitter [EMISSION_SHAPE_RING]. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var emissionRingAxis: Vector3 @@ -415,12 +374,9 @@ public open class CPUParticles3D : GeometryInstance3D() { } /** - * The angle of the cone when using the emitter [EMISSION_SHAPE_RING]. The default angle of 90 - * degrees results in a ring, while an angle of 0 degrees results in a cone. Intermediate values will - * result in a ring where one end is larger than the other. + * The angle of the cone when using the emitter [EMISSION_SHAPE_RING]. The default angle of 90 degrees results in a ring, while an angle of 0 degrees results in a cone. Intermediate values will result in a ring where one end is larger than the other. * - * **Note:** Depending on [emissionRingHeight], the angle may be clamped if the ring's end is - * reached to form a perfect cone. + * **Note:** Depending on [emissionRingHeight], the angle may be clamped if the ring's end is reached to form a perfect cone. */ public final inline var emissionRingConeAngle: Float @JvmName("emissionRingConeAngleProperty") @@ -467,11 +423,8 @@ public open class CPUParticles3D : GeometryInstance3D() { * Unit vector specifying the particles' emission direction. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var direction: Vector3 @@ -483,8 +436,7 @@ public open class CPUParticles3D : GeometryInstance3D() { } /** - * Each particle's initial direction range from `+spread` to `-spread` degrees. Applied to X/Z - * plane and Y/Z planes. + * Each particle's initial direction range from `+spread` to `-spread` degrees. Applied to X/Z plane and Y/Z planes. */ public final inline var spread: Float @JvmName("spreadProperty") @@ -509,11 +461,8 @@ public open class CPUParticles3D : GeometryInstance3D() { * Gravity applied to every particle. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var gravity: Vector3 @@ -547,8 +496,7 @@ public open class CPUParticles3D : GeometryInstance3D() { } /** - * Minimum initial angular velocity (rotation speed) applied to each particle in *degrees* per - * second. + * Minimum initial angular velocity (rotation speed) applied to each particle in *degrees* per second. */ public final inline var angularVelocityMin: Float @JvmName("angularVelocityMinProperty") @@ -559,8 +507,7 @@ public open class CPUParticles3D : GeometryInstance3D() { } /** - * Maximum initial angular velocity (rotation speed) applied to each particle in *degrees* per - * second. + * Maximum initial angular velocity (rotation speed) applied to each particle in *degrees* per second. */ public final inline var angularVelocityMax: Float @JvmName("angularVelocityMaxProperty") @@ -571,8 +518,7 @@ public open class CPUParticles3D : GeometryInstance3D() { } /** - * Each particle's angular velocity (rotation speed) will vary along this [Curve] over its - * lifetime. Should be a unit [Curve]. + * Each particle's angular velocity (rotation speed) will vary along this [Curve] over its lifetime. Should be a unit [Curve]. */ public final inline var angularVelocityCurve: Curve? @JvmName("angularVelocityCurveProperty") @@ -860,17 +806,11 @@ public open class CPUParticles3D : GeometryInstance3D() { /** * Each particle's initial color. * - * **Note:** [color] multiplies the particle mesh's vertex colors. To have a visible effect on a - * [BaseMaterial3D], [BaseMaterial3D.vertexColorUseAsAlbedo] *must* be `true`. For a - * [ShaderMaterial], `ALBEDO *= COLOR.rgb;` must be inserted in the shader's `fragment()` function. - * Otherwise, [color] will have no visible effect. + * **Note:** [color] multiplies the particle mesh's vertex colors. To have a visible effect on a [BaseMaterial3D], [BaseMaterial3D.vertexColorUseAsAlbedo] *must* be `true`. For a [ShaderMaterial], `ALBEDO *= COLOR.rgb;` must be inserted in the shader's `fragment()` function. Otherwise, [color] will have no visible effect. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var color: Color @@ -882,13 +822,9 @@ public open class CPUParticles3D : GeometryInstance3D() { } /** - * Each particle's color will vary along this [Gradient] over its lifetime (multiplied with - * [color]). + * Each particle's color will vary along this [Gradient] over its lifetime (multiplied with [color]). * - * **Note:** [colorRamp] multiplies the particle mesh's vertex colors. To have a visible effect on - * a [BaseMaterial3D], [BaseMaterial3D.vertexColorUseAsAlbedo] *must* be `true`. For a - * [ShaderMaterial], `ALBEDO *= COLOR.rgb;` must be inserted in the shader's `fragment()` function. - * Otherwise, [colorRamp] will have no visible effect. + * **Note:** [colorRamp] multiplies the particle mesh's vertex colors. To have a visible effect on a [BaseMaterial3D], [BaseMaterial3D.vertexColorUseAsAlbedo] *must* be `true`. For a [ShaderMaterial], `ALBEDO *= COLOR.rgb;` must be inserted in the shader's `fragment()` function. Otherwise, [colorRamp] will have no visible effect. */ public final inline var colorRamp: Gradient? @JvmName("colorRampProperty") @@ -901,10 +837,7 @@ public open class CPUParticles3D : GeometryInstance3D() { /** * Each particle's initial color will vary along this [Gradient] (multiplied with [color]). * - * **Note:** [colorInitialRamp] multiplies the particle mesh's vertex colors. To have a visible - * effect on a [BaseMaterial3D], [BaseMaterial3D.vertexColorUseAsAlbedo] *must* be `true`. For a - * [ShaderMaterial], `ALBEDO *= COLOR.rgb;` must be inserted in the shader's `fragment()` function. - * Otherwise, [colorInitialRamp] will have no visible effect. + * **Note:** [colorInitialRamp] multiplies the particle mesh's vertex colors. To have a visible effect on a [BaseMaterial3D], [BaseMaterial3D.vertexColorUseAsAlbedo] *must* be `true`. For a [ShaderMaterial], `ALBEDO *= COLOR.rgb;` must be inserted in the shader's `fragment()` function. Otherwise, [colorInitialRamp] will have no visible effect. */ public final inline var colorInitialRamp: Gradient? @JvmName("colorInitialRampProperty") @@ -1013,7 +946,7 @@ public open class CPUParticles3D : GeometryInstance3D() { setParamCurve(CPUParticles3D.Parameter.ANIM_OFFSET, value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(116, scriptIndex) } @@ -1028,14 +961,12 @@ public open class CPUParticles3D : GeometryInstance3D() { * cpuparticles3d.visibilityAabb = myCoreType * `````` * - * The [AABB] that determines the node's region which needs to be visible on screen for the - * particle system to be active. + * The [AABB] that determines the node's region which needs to be visible on screen for the particle system to be active. * - * Grow the box if particles suddenly appear/disappear when the node enters/exits the screen. The - * [AABB] can be grown via code or with the **Particles → Generate AABB** editor tool. + * Grow the box if particles suddenly appear/disappear when the node enters/exits the screen. The [AABB] can be grown via code or with the **Particles → Generate AABB** editor tool. */ @CoreTypeHelper - public final fun visibilityAabbMutate(block: AABB.() -> Unit): AABB = visibilityAabb.apply { + public final fun visibilityAabbMutate(block: CoreAABB.() -> Unit): CoreAABB = visibilityAabb.apply { block(this) visibilityAabb = this } @@ -1054,8 +985,7 @@ public open class CPUParticles3D : GeometryInstance3D() { * The rectangle's extents if [emissionShape] is set to [EMISSION_SHAPE_BOX]. */ @CoreTypeHelper - public final fun emissionBoxExtentsMutate(block: Vector3.() -> Unit): Vector3 = - emissionBoxExtents.apply { + public final fun emissionBoxExtentsMutate(block: Vector3.() -> Unit): Vector3 = emissionBoxExtents.apply { block(this) emissionBoxExtents = this } @@ -1071,27 +1001,22 @@ public open class CPUParticles3D : GeometryInstance3D() { * cpuparticles3d.emissionPoints = myCoreType * `````` * - * Sets the initial positions to spawn particles when using [EMISSION_SHAPE_POINTS] or - * [EMISSION_SHAPE_DIRECTED_POINTS]. + * Sets the initial positions to spawn particles when using [EMISSION_SHAPE_POINTS] or [EMISSION_SHAPE_DIRECTED_POINTS]. */ @CoreTypeHelper - public final fun emissionPointsMutate(block: PackedVector3Array.() -> Unit): PackedVector3Array = - emissionPoints.apply { + public final fun emissionPointsMutate(block: PackedVector3Array.() -> Unit): PackedVector3Array = emissionPoints.apply { block(this) emissionPoints = this } /** * This is a helper function for [emissionPoints] to make dealing with local copies easier. - * Allow to directly modify each element of the local copy of the property and assign it back to - * the Object. + * Allow to directly modify each element of the local copy of the property and assign it back to the Object. * - * Sets the initial positions to spawn particles when using [EMISSION_SHAPE_POINTS] or - * [EMISSION_SHAPE_DIRECTED_POINTS]. + * Sets the initial positions to spawn particles when using [EMISSION_SHAPE_POINTS] or [EMISSION_SHAPE_DIRECTED_POINTS]. */ @CoreTypeHelper - public final fun emissionPointsMutateEach(block: (index: Int, `value`: Vector3) -> Unit): - PackedVector3Array = emissionPoints.apply { + public final fun emissionPointsMutateEach(block: (index: Int, `value`: Vector3) -> Unit): PackedVector3Array = emissionPoints.apply { this.forEachIndexed { index, value -> block(index, value) this[index] = value @@ -1110,27 +1035,22 @@ public open class CPUParticles3D : GeometryInstance3D() { * cpuparticles3d.emissionNormals = myCoreType * `````` * - * Sets the direction the particles will be emitted in when using - * [EMISSION_SHAPE_DIRECTED_POINTS]. + * Sets the direction the particles will be emitted in when using [EMISSION_SHAPE_DIRECTED_POINTS]. */ @CoreTypeHelper - public final fun emissionNormalsMutate(block: PackedVector3Array.() -> Unit): PackedVector3Array = - emissionNormals.apply { + public final fun emissionNormalsMutate(block: PackedVector3Array.() -> Unit): PackedVector3Array = emissionNormals.apply { block(this) emissionNormals = this } /** * This is a helper function for [emissionNormals] to make dealing with local copies easier. - * Allow to directly modify each element of the local copy of the property and assign it back to - * the Object. + * Allow to directly modify each element of the local copy of the property and assign it back to the Object. * - * Sets the direction the particles will be emitted in when using - * [EMISSION_SHAPE_DIRECTED_POINTS]. + * Sets the direction the particles will be emitted in when using [EMISSION_SHAPE_DIRECTED_POINTS]. */ @CoreTypeHelper - public final fun emissionNormalsMutateEach(block: (index: Int, `value`: Vector3) -> Unit): - PackedVector3Array = emissionNormals.apply { + public final fun emissionNormalsMutateEach(block: (index: Int, `value`: Vector3) -> Unit): PackedVector3Array = emissionNormals.apply { this.forEachIndexed { index, value -> block(index, value) this[index] = value @@ -1152,8 +1072,7 @@ public open class CPUParticles3D : GeometryInstance3D() { * The axis of the ring when using the emitter [EMISSION_SHAPE_RING]. */ @CoreTypeHelper - public final fun emissionRingAxisMutate(block: Vector3.() -> Unit): Vector3 = - emissionRingAxis.apply { + public final fun emissionRingAxisMutate(block: Vector3.() -> Unit): Vector3 = emissionRingAxis.apply { block(this) emissionRingAxis = this } @@ -1209,10 +1128,7 @@ public open class CPUParticles3D : GeometryInstance3D() { * * Each particle's initial color. * - * **Note:** [color] multiplies the particle mesh's vertex colors. To have a visible effect on a - * [BaseMaterial3D], [BaseMaterial3D.vertexColorUseAsAlbedo] *must* be `true`. For a - * [ShaderMaterial], `ALBEDO *= COLOR.rgb;` must be inserted in the shader's `fragment()` function. - * Otherwise, [color] will have no visible effect. + * **Note:** [color] multiplies the particle mesh's vertex colors. To have a visible effect on a [BaseMaterial3D], [BaseMaterial3D.vertexColorUseAsAlbedo] *must* be `true`. For a [ShaderMaterial], `ALBEDO *= COLOR.rgb;` must be inserted in the shader's `fragment()` function. Otherwise, [color] will have no visible effect. */ @CoreTypeHelper public final fun colorMutate(block: Color.() -> Unit): Color = color.apply { @@ -1220,67 +1136,67 @@ public open class CPUParticles3D : GeometryInstance3D() { color = this } - public final fun setEmitting(emitting: Boolean): Unit { + public final fun setEmitting(emitting: Boolean) { TransferContext.writeArguments(BOOL to emitting) TransferContext.callMethod(ptr, MethodBindings.setEmittingPtr, NIL) } - public final fun setAmount(amount: Int): Unit { + public final fun setAmount(amount: Int) { TransferContext.writeArguments(LONG to amount.toLong()) TransferContext.callMethod(ptr, MethodBindings.setAmountPtr, NIL) } - public final fun setLifetime(secs: Double): Unit { + public final fun setLifetime(secs: Double) { TransferContext.writeArguments(DOUBLE to secs) TransferContext.callMethod(ptr, MethodBindings.setLifetimePtr, NIL) } - public final fun setOneShot(enable: Boolean): Unit { + public final fun setOneShot(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setOneShotPtr, NIL) } - public final fun setPreProcessTime(secs: Double): Unit { + public final fun setPreProcessTime(secs: Double) { TransferContext.writeArguments(DOUBLE to secs) TransferContext.callMethod(ptr, MethodBindings.setPreProcessTimePtr, NIL) } - public final fun setExplosivenessRatio(ratio: Float): Unit { + public final fun setExplosivenessRatio(ratio: Float) { TransferContext.writeArguments(DOUBLE to ratio.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setExplosivenessRatioPtr, NIL) } - public final fun setRandomnessRatio(ratio: Float): Unit { + public final fun setRandomnessRatio(ratio: Float) { TransferContext.writeArguments(DOUBLE to ratio.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setRandomnessRatioPtr, NIL) } - public final fun setVisibilityAabb(aabb: AABB): Unit { - TransferContext.writeArguments(godot.core.VariantParser.AABB to aabb) + public final fun setVisibilityAabb(aabb: CoreAABB) { + TransferContext.writeArguments(VariantParserAABB to aabb) TransferContext.callMethod(ptr, MethodBindings.setVisibilityAabbPtr, NIL) } - public final fun setLifetimeRandomness(random: Double): Unit { + public final fun setLifetimeRandomness(random: Double) { TransferContext.writeArguments(DOUBLE to random) TransferContext.callMethod(ptr, MethodBindings.setLifetimeRandomnessPtr, NIL) } - public final fun setUseLocalCoordinates(enable: Boolean): Unit { + public final fun setUseLocalCoordinates(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setUseLocalCoordinatesPtr, NIL) } - public final fun setFixedFps(fps: Int): Unit { + public final fun setFixedFps(fps: Int) { TransferContext.writeArguments(LONG to fps.toLong()) TransferContext.callMethod(ptr, MethodBindings.setFixedFpsPtr, NIL) } - public final fun setFractionalDelta(enable: Boolean): Unit { + public final fun setFractionalDelta(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setFractionalDeltaPtr, NIL) } - public final fun setSpeedScale(scale: Double): Unit { + public final fun setSpeedScale(scale: Double) { TransferContext.writeArguments(DOUBLE to scale) TransferContext.callMethod(ptr, MethodBindings.setSpeedScalePtr, NIL) } @@ -1327,11 +1243,10 @@ public open class CPUParticles3D : GeometryInstance3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun getVisibilityAabb(): AABB { + public final fun getVisibilityAabb(): CoreAABB { TransferContext.writeArguments() - TransferContext.callMethod(ptr, MethodBindings.getVisibilityAabbPtr, - godot.core.VariantParser.AABB) - return (TransferContext.readReturnValue(godot.core.VariantParser.AABB) as AABB) + TransferContext.callMethod(ptr, MethodBindings.getVisibilityAabbPtr, VariantParserAABB) + return (TransferContext.readReturnValue(VariantParserAABB) as CoreAABB) } public final fun getLifetimeRandomness(): Double { @@ -1364,7 +1279,7 @@ public open class CPUParticles3D : GeometryInstance3D() { return (TransferContext.readReturnValue(DOUBLE) as Double) } - public final fun setDrawOrder(order: DrawOrder): Unit { + public final fun setDrawOrder(order: DrawOrder) { TransferContext.writeArguments(LONG to order.id) TransferContext.callMethod(ptr, MethodBindings.setDrawOrderPtr, NIL) } @@ -1375,7 +1290,7 @@ public open class CPUParticles3D : GeometryInstance3D() { return DrawOrder.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setMesh(mesh: Mesh?): Unit { + public final fun setMesh(mesh: Mesh?) { TransferContext.writeArguments(OBJECT to mesh) TransferContext.callMethod(ptr, MethodBindings.setMeshPtr, NIL) } @@ -1386,7 +1301,7 @@ public open class CPUParticles3D : GeometryInstance3D() { return (TransferContext.readReturnValue(OBJECT) as Mesh?) } - public final fun setUseFixedSeed(useFixedSeed: Boolean): Unit { + public final fun setUseFixedSeed(useFixedSeed: Boolean) { TransferContext.writeArguments(BOOL to useFixedSeed) TransferContext.callMethod(ptr, MethodBindings.setUseFixedSeedPtr, NIL) } @@ -1397,7 +1312,7 @@ public open class CPUParticles3D : GeometryInstance3D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setSeed(seed: Long): Unit { + public final fun setSeed(seed: Long) { TransferContext.writeArguments(LONG to seed) TransferContext.callMethod(ptr, MethodBindings.setSeedPtr, NIL) } @@ -1411,11 +1326,10 @@ public open class CPUParticles3D : GeometryInstance3D() { /** * Restarts the particle emitter. * - * If [keepSeed] is `true`, the current random seed will be preserved. Useful for seeking and - * playback. + * If [keepSeed] is `true`, the current random seed will be preserved. Useful for seeking and playback. */ @JvmOverloads - public final fun restart(keepSeed: Boolean = false): Unit { + public final fun restart(keepSeed: Boolean = false) { TransferContext.writeArguments(BOOL to keepSeed) TransferContext.callMethod(ptr, MethodBindings.restartPtr, NIL) } @@ -1423,25 +1337,23 @@ public open class CPUParticles3D : GeometryInstance3D() { /** * Requests the particles to process for extra process time during a single frame. * - * Useful for particle playback, if used in combination with [useFixedSeed] or by calling - * [restart] with parameter `keep_seed` set to `true`. + * Useful for particle playback, if used in combination with [useFixedSeed] or by calling [restart] with parameter `keep_seed` set to `true`. */ - public final fun requestParticlesProcess(processTime: Float): Unit { + public final fun requestParticlesProcess(processTime: Float) { TransferContext.writeArguments(DOUBLE to processTime.toDouble()) TransferContext.callMethod(ptr, MethodBindings.requestParticlesProcessPtr, NIL) } /** - * Returns the axis-aligned bounding box that contains all the particles that are active in the - * current frame. + * Returns the axis-aligned bounding box that contains all the particles that are active in the current frame. */ - public final fun captureAabb(): AABB { + public final fun captureAabb(): CoreAABB { TransferContext.writeArguments() - TransferContext.callMethod(ptr, MethodBindings.captureAabbPtr, godot.core.VariantParser.AABB) - return (TransferContext.readReturnValue(godot.core.VariantParser.AABB) as AABB) + TransferContext.callMethod(ptr, MethodBindings.captureAabbPtr, VariantParserAABB) + return (TransferContext.readReturnValue(VariantParserAABB) as CoreAABB) } - public final fun setDirection(direction: Vector3): Unit { + public final fun setDirection(direction: Vector3) { TransferContext.writeArguments(VECTOR3 to direction) TransferContext.callMethod(ptr, MethodBindings.setDirectionPtr, NIL) } @@ -1452,7 +1364,7 @@ public open class CPUParticles3D : GeometryInstance3D() { return (TransferContext.readReturnValue(VECTOR3) as Vector3) } - public final fun setSpread(degrees: Float): Unit { + public final fun setSpread(degrees: Float) { TransferContext.writeArguments(DOUBLE to degrees.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setSpreadPtr, NIL) } @@ -1463,7 +1375,7 @@ public open class CPUParticles3D : GeometryInstance3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setFlatness(amount: Float): Unit { + public final fun setFlatness(amount: Float) { TransferContext.writeArguments(DOUBLE to amount.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setFlatnessPtr, NIL) } @@ -1477,7 +1389,7 @@ public open class CPUParticles3D : GeometryInstance3D() { /** * Sets the minimum value for the given parameter. */ - public final fun setParamMin(`param`: Parameter, `value`: Float): Unit { + public final fun setParamMin(`param`: Parameter, `value`: Float) { TransferContext.writeArguments(LONG to param.id, DOUBLE to value.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setParamMinPtr, NIL) } @@ -1494,7 +1406,7 @@ public open class CPUParticles3D : GeometryInstance3D() { /** * Sets the maximum value for the given parameter. */ - public final fun setParamMax(`param`: Parameter, `value`: Float): Unit { + public final fun setParamMax(`param`: Parameter, `value`: Float) { TransferContext.writeArguments(LONG to param.id, DOUBLE to value.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setParamMaxPtr, NIL) } @@ -1511,7 +1423,7 @@ public open class CPUParticles3D : GeometryInstance3D() { /** * Sets the [Curve] of the parameter specified by [Parameter]. Should be a unit [Curve]. */ - public final fun setParamCurve(`param`: Parameter, curve: Curve?): Unit { + public final fun setParamCurve(`param`: Parameter, curve: Curve?) { TransferContext.writeArguments(LONG to param.id, OBJECT to curve) TransferContext.callMethod(ptr, MethodBindings.setParamCurvePtr, NIL) } @@ -1525,7 +1437,7 @@ public open class CPUParticles3D : GeometryInstance3D() { return (TransferContext.readReturnValue(OBJECT) as Curve?) } - public final fun setColor(color: Color): Unit { + public final fun setColor(color: Color) { TransferContext.writeArguments(COLOR to color) TransferContext.callMethod(ptr, MethodBindings.setColorPtr, NIL) } @@ -1536,7 +1448,7 @@ public open class CPUParticles3D : GeometryInstance3D() { return (TransferContext.readReturnValue(COLOR) as Color) } - public final fun setColorRamp(ramp: Gradient?): Unit { + public final fun setColorRamp(ramp: Gradient?) { TransferContext.writeArguments(OBJECT to ramp) TransferContext.callMethod(ptr, MethodBindings.setColorRampPtr, NIL) } @@ -1547,7 +1459,7 @@ public open class CPUParticles3D : GeometryInstance3D() { return (TransferContext.readReturnValue(OBJECT) as Gradient?) } - public final fun setColorInitialRamp(ramp: Gradient?): Unit { + public final fun setColorInitialRamp(ramp: Gradient?) { TransferContext.writeArguments(OBJECT to ramp) TransferContext.callMethod(ptr, MethodBindings.setColorInitialRampPtr, NIL) } @@ -1561,7 +1473,7 @@ public open class CPUParticles3D : GeometryInstance3D() { /** * Enables or disables the given particle flag (see [ParticleFlags] for options). */ - public final fun setParticleFlag(particleFlag: ParticleFlags, enable: Boolean): Unit { + public final fun setParticleFlag(particleFlag: ParticleFlags, enable: Boolean) { TransferContext.writeArguments(LONG to particleFlag.id, BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setParticleFlagPtr, NIL) } @@ -1575,7 +1487,7 @@ public open class CPUParticles3D : GeometryInstance3D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setEmissionShape(shape: EmissionShape): Unit { + public final fun setEmissionShape(shape: EmissionShape) { TransferContext.writeArguments(LONG to shape.id) TransferContext.callMethod(ptr, MethodBindings.setEmissionShapePtr, NIL) } @@ -1586,7 +1498,7 @@ public open class CPUParticles3D : GeometryInstance3D() { return EmissionShape.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setEmissionSphereRadius(radius: Float): Unit { + public final fun setEmissionSphereRadius(radius: Float) { TransferContext.writeArguments(DOUBLE to radius.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setEmissionSphereRadiusPtr, NIL) } @@ -1597,7 +1509,7 @@ public open class CPUParticles3D : GeometryInstance3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setEmissionBoxExtents(extents: Vector3): Unit { + public final fun setEmissionBoxExtents(extents: Vector3) { TransferContext.writeArguments(VECTOR3 to extents) TransferContext.callMethod(ptr, MethodBindings.setEmissionBoxExtentsPtr, NIL) } @@ -1608,7 +1520,7 @@ public open class CPUParticles3D : GeometryInstance3D() { return (TransferContext.readReturnValue(VECTOR3) as Vector3) } - public final fun setEmissionPoints(array: PackedVector3Array): Unit { + public final fun setEmissionPoints(array: PackedVector3Array) { TransferContext.writeArguments(PACKED_VECTOR3_ARRAY to array) TransferContext.callMethod(ptr, MethodBindings.setEmissionPointsPtr, NIL) } @@ -1619,7 +1531,7 @@ public open class CPUParticles3D : GeometryInstance3D() { return (TransferContext.readReturnValue(PACKED_VECTOR3_ARRAY) as PackedVector3Array) } - public final fun setEmissionNormals(array: PackedVector3Array): Unit { + public final fun setEmissionNormals(array: PackedVector3Array) { TransferContext.writeArguments(PACKED_VECTOR3_ARRAY to array) TransferContext.callMethod(ptr, MethodBindings.setEmissionNormalsPtr, NIL) } @@ -1630,7 +1542,7 @@ public open class CPUParticles3D : GeometryInstance3D() { return (TransferContext.readReturnValue(PACKED_VECTOR3_ARRAY) as PackedVector3Array) } - public final fun setEmissionColors(array: PackedColorArray): Unit { + public final fun setEmissionColors(array: PackedColorArray) { TransferContext.writeArguments(PACKED_COLOR_ARRAY to array) TransferContext.callMethod(ptr, MethodBindings.setEmissionColorsPtr, NIL) } @@ -1641,7 +1553,7 @@ public open class CPUParticles3D : GeometryInstance3D() { return (TransferContext.readReturnValue(PACKED_COLOR_ARRAY) as PackedColorArray) } - public final fun setEmissionRingAxis(axis: Vector3): Unit { + public final fun setEmissionRingAxis(axis: Vector3) { TransferContext.writeArguments(VECTOR3 to axis) TransferContext.callMethod(ptr, MethodBindings.setEmissionRingAxisPtr, NIL) } @@ -1652,7 +1564,7 @@ public open class CPUParticles3D : GeometryInstance3D() { return (TransferContext.readReturnValue(VECTOR3) as Vector3) } - public final fun setEmissionRingHeight(height: Float): Unit { + public final fun setEmissionRingHeight(height: Float) { TransferContext.writeArguments(DOUBLE to height.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setEmissionRingHeightPtr, NIL) } @@ -1663,7 +1575,7 @@ public open class CPUParticles3D : GeometryInstance3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setEmissionRingRadius(radius: Float): Unit { + public final fun setEmissionRingRadius(radius: Float) { TransferContext.writeArguments(DOUBLE to radius.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setEmissionRingRadiusPtr, NIL) } @@ -1674,7 +1586,7 @@ public open class CPUParticles3D : GeometryInstance3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setEmissionRingInnerRadius(innerRadius: Float): Unit { + public final fun setEmissionRingInnerRadius(innerRadius: Float) { TransferContext.writeArguments(DOUBLE to innerRadius.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setEmissionRingInnerRadiusPtr, NIL) } @@ -1685,7 +1597,7 @@ public open class CPUParticles3D : GeometryInstance3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setEmissionRingConeAngle(coneAngle: Float): Unit { + public final fun setEmissionRingConeAngle(coneAngle: Float) { TransferContext.writeArguments(DOUBLE to coneAngle.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setEmissionRingConeAnglePtr, NIL) } @@ -1702,7 +1614,7 @@ public open class CPUParticles3D : GeometryInstance3D() { return (TransferContext.readReturnValue(VECTOR3) as Vector3) } - public final fun setGravity(accelVec: Vector3): Unit { + public final fun setGravity(accelVec: Vector3) { TransferContext.writeArguments(VECTOR3 to accelVec) TransferContext.callMethod(ptr, MethodBindings.setGravityPtr, NIL) } @@ -1713,7 +1625,7 @@ public open class CPUParticles3D : GeometryInstance3D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setSplitScale(splitScale: Boolean): Unit { + public final fun setSplitScale(splitScale: Boolean) { TransferContext.writeArguments(BOOL to splitScale) TransferContext.callMethod(ptr, MethodBindings.setSplitScalePtr, NIL) } @@ -1724,7 +1636,7 @@ public open class CPUParticles3D : GeometryInstance3D() { return (TransferContext.readReturnValue(OBJECT) as Curve?) } - public final fun setScaleCurveX(scaleCurve: Curve?): Unit { + public final fun setScaleCurveX(scaleCurve: Curve?) { TransferContext.writeArguments(OBJECT to scaleCurve) TransferContext.callMethod(ptr, MethodBindings.setScaleCurveXPtr, NIL) } @@ -1735,7 +1647,7 @@ public open class CPUParticles3D : GeometryInstance3D() { return (TransferContext.readReturnValue(OBJECT) as Curve?) } - public final fun setScaleCurveY(scaleCurve: Curve?): Unit { + public final fun setScaleCurveY(scaleCurve: Curve?) { TransferContext.writeArguments(OBJECT to scaleCurve) TransferContext.callMethod(ptr, MethodBindings.setScaleCurveYPtr, NIL) } @@ -1746,16 +1658,15 @@ public open class CPUParticles3D : GeometryInstance3D() { return (TransferContext.readReturnValue(OBJECT) as Curve?) } - public final fun setScaleCurveZ(scaleCurve: Curve?): Unit { + public final fun setScaleCurveZ(scaleCurve: Curve?) { TransferContext.writeArguments(OBJECT to scaleCurve) TransferContext.callMethod(ptr, MethodBindings.setScaleCurveZPtr, NIL) } /** - * Sets this node's properties to match a given [GPUParticles3D] node with an assigned - * [ParticleProcessMaterial]. + * Sets this node's properties to match a given [GPUParticles3D] node with an assigned [ParticleProcessMaterial]. */ - public final fun convertFromParticles(particles: Node?): Unit { + public final fun convertFromParticles(particles: Node?) { TransferContext.writeArguments(OBJECT to particles) TransferContext.callMethod(ptr, MethodBindings.convertFromParticlesPtr, NIL) } @@ -1768,8 +1679,7 @@ public open class CPUParticles3D : GeometryInstance3D() { */ INDEX(0), /** - * Particles are drawn in order of remaining lifetime. In other words, the particle with the - * highest lifetime is drawn at the front. + * Particles are drawn in order of remaining lifetime. In other words, the particle with the highest lifetime is drawn at the front. */ LIFETIME(1), /** @@ -1792,33 +1702,27 @@ public open class CPUParticles3D : GeometryInstance3D() { id: Long, ) { /** - * Use with [setParamMin], [setParamMax], and [setParamCurve] to set initial velocity - * properties. + * Use with [setParamMin], [setParamMax], and [setParamCurve] to set initial velocity properties. */ INITIAL_LINEAR_VELOCITY(0), /** - * Use with [setParamMin], [setParamMax], and [setParamCurve] to set angular velocity - * properties. + * Use with [setParamMin], [setParamMax], and [setParamCurve] to set angular velocity properties. */ ANGULAR_VELOCITY(1), /** - * Use with [setParamMin], [setParamMax], and [setParamCurve] to set orbital velocity - * properties. + * Use with [setParamMin], [setParamMax], and [setParamCurve] to set orbital velocity properties. */ ORBIT_VELOCITY(2), /** - * Use with [setParamMin], [setParamMax], and [setParamCurve] to set linear acceleration - * properties. + * Use with [setParamMin], [setParamMax], and [setParamCurve] to set linear acceleration properties. */ LINEAR_ACCEL(3), /** - * Use with [setParamMin], [setParamMax], and [setParamCurve] to set radial acceleration - * properties. + * Use with [setParamMin], [setParamMax], and [setParamCurve] to set radial acceleration properties. */ RADIAL_ACCEL(4), /** - * Use with [setParamMin], [setParamMax], and [setParamCurve] to set tangential acceleration - * properties. + * Use with [setParamMin], [setParamMax], and [setParamCurve] to set tangential acceleration properties. */ TANGENTIAL_ACCEL(5), /** @@ -1842,8 +1746,7 @@ public open class CPUParticles3D : GeometryInstance3D() { */ ANIM_SPEED(10), /** - * Use with [setParamMin], [setParamMax], and [setParamCurve] to set animation offset - * properties. + * Use with [setParamMin], [setParamMax], and [setParamCurve] to set animation offset properties. */ ANIM_OFFSET(11), /** @@ -1913,14 +1816,11 @@ public open class CPUParticles3D : GeometryInstance3D() { */ BOX(3), /** - * Particles will be emitted at a position chosen randomly among [emissionPoints]. Particle - * color will be modulated by [emissionColors]. + * Particles will be emitted at a position chosen randomly among [emissionPoints]. Particle color will be modulated by [emissionColors]. */ POINTS(4), /** - * Particles will be emitted at a position chosen randomly among [emissionPoints]. Particle - * velocity and rotation will be set based on [emissionNormals]. Particle color will be modulated - * by [emissionColors]. + * Particles will be emitted at a position chosen randomly among [emissionPoints]. Particle velocity and rotation will be set based on [emissionNormals]. Particle color will be modulated by [emissionColors]. */ DIRECTED_POINTS(5), /** @@ -1947,273 +1847,273 @@ public open class CPUParticles3D : GeometryInstance3D() { public object MethodBindings { internal val setEmittingPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_emitting", 2586408642) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_emitting", 2_586_408_642) internal val setAmountPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_amount", 1286410249) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_amount", 1_286_410_249) internal val setLifetimePtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_lifetime", 373806689) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_lifetime", 373_806_689) internal val setOneShotPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_one_shot", 2586408642) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_one_shot", 2_586_408_642) internal val setPreProcessTimePtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_pre_process_time", 373806689) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_pre_process_time", 373_806_689) internal val setExplosivenessRatioPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_explosiveness_ratio", 373806689) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_explosiveness_ratio", 373_806_689) internal val setRandomnessRatioPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_randomness_ratio", 373806689) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_randomness_ratio", 373_806_689) internal val setVisibilityAabbPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_visibility_aabb", 259215842) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_visibility_aabb", 259_215_842) internal val setLifetimeRandomnessPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_lifetime_randomness", 373806689) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_lifetime_randomness", 373_806_689) internal val setUseLocalCoordinatesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_use_local_coordinates", 2586408642) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_use_local_coordinates", 2_586_408_642) internal val setFixedFpsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_fixed_fps", 1286410249) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_fixed_fps", 1_286_410_249) internal val setFractionalDeltaPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_fractional_delta", 2586408642) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_fractional_delta", 2_586_408_642) internal val setSpeedScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_speed_scale", 373806689) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_speed_scale", 373_806_689) internal val isEmittingPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "is_emitting", 36873697) + TypeManager.getMethodBindPtr("CPUParticles3D", "is_emitting", 36_873_697) internal val getAmountPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_amount", 3905245786) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_amount", 3_905_245_786) internal val getLifetimePtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_lifetime", 1740695150) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_lifetime", 1_740_695_150) internal val getOneShotPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_one_shot", 36873697) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_one_shot", 36_873_697) internal val getPreProcessTimePtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_pre_process_time", 1740695150) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_pre_process_time", 1_740_695_150) internal val getExplosivenessRatioPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_explosiveness_ratio", 1740695150) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_explosiveness_ratio", 1_740_695_150) internal val getRandomnessRatioPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_randomness_ratio", 1740695150) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_randomness_ratio", 1_740_695_150) internal val getVisibilityAabbPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_visibility_aabb", 1068685055) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_visibility_aabb", 1_068_685_055) internal val getLifetimeRandomnessPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_lifetime_randomness", 1740695150) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_lifetime_randomness", 1_740_695_150) internal val getUseLocalCoordinatesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_use_local_coordinates", 36873697) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_use_local_coordinates", 36_873_697) internal val getFixedFpsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_fixed_fps", 3905245786) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_fixed_fps", 3_905_245_786) internal val getFractionalDeltaPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_fractional_delta", 36873697) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_fractional_delta", 36_873_697) internal val getSpeedScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_speed_scale", 1740695150) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_speed_scale", 1_740_695_150) internal val setDrawOrderPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_draw_order", 1427401774) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_draw_order", 1_427_401_774) internal val getDrawOrderPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_draw_order", 1321900776) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_draw_order", 1_321_900_776) internal val setMeshPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_mesh", 194775623) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_mesh", 194_775_623) internal val getMeshPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_mesh", 1808005922) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_mesh", 1_808_005_922) internal val setUseFixedSeedPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_use_fixed_seed", 2586408642) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_use_fixed_seed", 2_586_408_642) internal val getUseFixedSeedPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_use_fixed_seed", 36873697) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_use_fixed_seed", 36_873_697) internal val setSeedPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_seed", 1286410249) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_seed", 1_286_410_249) internal val getSeedPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_seed", 3905245786) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_seed", 3_905_245_786) internal val restartPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "restart", 107499316) + TypeManager.getMethodBindPtr("CPUParticles3D", "restart", 107_499_316) internal val requestParticlesProcessPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "request_particles_process", 373806689) + TypeManager.getMethodBindPtr("CPUParticles3D", "request_particles_process", 373_806_689) internal val captureAabbPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "capture_aabb", 1068685055) + TypeManager.getMethodBindPtr("CPUParticles3D", "capture_aabb", 1_068_685_055) internal val setDirectionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_direction", 3460891852) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_direction", 3_460_891_852) internal val getDirectionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_direction", 3360562783) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_direction", 3_360_562_783) internal val setSpreadPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_spread", 373806689) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_spread", 373_806_689) internal val getSpreadPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_spread", 1740695150) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_spread", 1_740_695_150) internal val setFlatnessPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_flatness", 373806689) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_flatness", 373_806_689) internal val getFlatnessPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_flatness", 1740695150) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_flatness", 1_740_695_150) internal val setParamMinPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_param_min", 557936109) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_param_min", 557_936_109) internal val getParamMinPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_param_min", 597646162) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_param_min", 597_646_162) internal val setParamMaxPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_param_max", 557936109) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_param_max", 557_936_109) internal val getParamMaxPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_param_max", 597646162) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_param_max", 597_646_162) internal val setParamCurvePtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_param_curve", 4044142537) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_param_curve", 4_044_142_537) internal val getParamCurvePtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_param_curve", 4132790277) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_param_curve", 4_132_790_277) internal val setColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_color", 2920490490) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_color", 2_920_490_490) internal val getColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_color", 3444240500) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_color", 3_444_240_500) internal val setColorRampPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_color_ramp", 2756054477) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_color_ramp", 2_756_054_477) internal val getColorRampPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_color_ramp", 132272999) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_color_ramp", 132_272_999) internal val setColorInitialRampPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_color_initial_ramp", 2756054477) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_color_initial_ramp", 2_756_054_477) internal val getColorInitialRampPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_color_initial_ramp", 132272999) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_color_initial_ramp", 132_272_999) internal val setParticleFlagPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_particle_flag", 3515406498) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_particle_flag", 3_515_406_498) internal val getParticleFlagPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_particle_flag", 2845201987) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_particle_flag", 2_845_201_987) internal val setEmissionShapePtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_emission_shape", 491823814) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_emission_shape", 491_823_814) internal val getEmissionShapePtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_emission_shape", 2961454842) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_emission_shape", 2_961_454_842) internal val setEmissionSphereRadiusPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_emission_sphere_radius", 373806689) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_emission_sphere_radius", 373_806_689) internal val getEmissionSphereRadiusPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_emission_sphere_radius", 1740695150) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_emission_sphere_radius", 1_740_695_150) internal val setEmissionBoxExtentsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_emission_box_extents", 3460891852) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_emission_box_extents", 3_460_891_852) internal val getEmissionBoxExtentsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_emission_box_extents", 3360562783) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_emission_box_extents", 3_360_562_783) internal val setEmissionPointsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_emission_points", 334873810) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_emission_points", 334_873_810) internal val getEmissionPointsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_emission_points", 497664490) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_emission_points", 497_664_490) internal val setEmissionNormalsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_emission_normals", 334873810) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_emission_normals", 334_873_810) internal val getEmissionNormalsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_emission_normals", 497664490) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_emission_normals", 497_664_490) internal val setEmissionColorsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_emission_colors", 3546319833) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_emission_colors", 3_546_319_833) internal val getEmissionColorsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_emission_colors", 1392750486) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_emission_colors", 1_392_750_486) internal val setEmissionRingAxisPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_emission_ring_axis", 3460891852) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_emission_ring_axis", 3_460_891_852) internal val getEmissionRingAxisPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_emission_ring_axis", 3360562783) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_emission_ring_axis", 3_360_562_783) internal val setEmissionRingHeightPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_emission_ring_height", 373806689) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_emission_ring_height", 373_806_689) internal val getEmissionRingHeightPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_emission_ring_height", 1740695150) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_emission_ring_height", 1_740_695_150) internal val setEmissionRingRadiusPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_emission_ring_radius", 373806689) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_emission_ring_radius", 373_806_689) internal val getEmissionRingRadiusPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_emission_ring_radius", 1740695150) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_emission_ring_radius", 1_740_695_150) internal val setEmissionRingInnerRadiusPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_emission_ring_inner_radius", 373806689) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_emission_ring_inner_radius", 373_806_689) internal val getEmissionRingInnerRadiusPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_emission_ring_inner_radius", 1740695150) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_emission_ring_inner_radius", 1_740_695_150) internal val setEmissionRingConeAnglePtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_emission_ring_cone_angle", 373806689) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_emission_ring_cone_angle", 373_806_689) internal val getEmissionRingConeAnglePtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_emission_ring_cone_angle", 1740695150) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_emission_ring_cone_angle", 1_740_695_150) internal val getGravityPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_gravity", 3360562783) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_gravity", 3_360_562_783) internal val setGravityPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_gravity", 3460891852) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_gravity", 3_460_891_852) internal val getSplitScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_split_scale", 2240911060) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_split_scale", 2_240_911_060) internal val setSplitScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_split_scale", 2586408642) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_split_scale", 2_586_408_642) internal val getScaleCurveXPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_scale_curve_x", 2460114913) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_scale_curve_x", 2_460_114_913) internal val setScaleCurveXPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_scale_curve_x", 270443179) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_scale_curve_x", 270_443_179) internal val getScaleCurveYPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_scale_curve_y", 2460114913) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_scale_curve_y", 2_460_114_913) internal val setScaleCurveYPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_scale_curve_y", 270443179) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_scale_curve_y", 270_443_179) internal val getScaleCurveZPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "get_scale_curve_z", 2460114913) + TypeManager.getMethodBindPtr("CPUParticles3D", "get_scale_curve_z", 2_460_114_913) internal val setScaleCurveZPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "set_scale_curve_z", 270443179) + TypeManager.getMethodBindPtr("CPUParticles3D", "set_scale_curve_z", 270_443_179) internal val convertFromParticlesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CPUParticles3D", "convert_from_particles", 1078189570) + TypeManager.getMethodBindPtr("CPUParticles3D", "convert_from_particles", 1_078_189_570) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGBox3D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGBox3D.kt index 7654b0d15b..210c254092 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGBox3D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGBox3D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -24,10 +21,7 @@ import kotlin.jvm.JvmName /** * This node allows you to create a box for use with the CSG system. * - * **Note:** CSG nodes are intended to be used for level prototyping. Creating CSG nodes has a - * significant CPU cost compared to creating a [MeshInstance3D] with a [PrimitiveMesh]. Moving a CSG - * node within another CSG node also has a significant CPU cost, so it should be avoided during - * gameplay. + * **Note:** CSG nodes are intended to be used for level prototyping. Creating CSG nodes has a significant CPU cost compared to creating a [MeshInstance3D] with a [PrimitiveMesh]. Moving a CSG node within another CSG node also has a significant CPU cost, so it should be avoided during gameplay. */ @GodotBaseType public open class CSGBox3D : CSGPrimitive3D() { @@ -35,11 +29,8 @@ public open class CSGBox3D : CSGPrimitive3D() { * The box's width, height and depth. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var size: Vector3 @@ -61,7 +52,7 @@ public open class CSGBox3D : CSGPrimitive3D() { setMaterial(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(117, scriptIndex) } @@ -84,7 +75,7 @@ public open class CSGBox3D : CSGPrimitive3D() { size = this } - public final fun setSize(size: Vector3): Unit { + public final fun setSize(size: Vector3) { TransferContext.writeArguments(VECTOR3 to size) TransferContext.callMethod(ptr, MethodBindings.setSizePtr, NIL) } @@ -95,7 +86,7 @@ public open class CSGBox3D : CSGPrimitive3D() { return (TransferContext.readReturnValue(VECTOR3) as Vector3) } - public final fun setMaterial(material: Material?): Unit { + public final fun setMaterial(material: Material?) { TransferContext.writeArguments(OBJECT to material) TransferContext.callMethod(ptr, MethodBindings.setMaterialPtr, NIL) } @@ -110,15 +101,15 @@ public open class CSGBox3D : CSGPrimitive3D() { public object MethodBindings { internal val setSizePtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGBox3D", "set_size", 3460891852) + TypeManager.getMethodBindPtr("CSGBox3D", "set_size", 3_460_891_852) internal val getSizePtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGBox3D", "get_size", 3360562783) + TypeManager.getMethodBindPtr("CSGBox3D", "get_size", 3_360_562_783) internal val setMaterialPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGBox3D", "set_material", 2757459619) + TypeManager.getMethodBindPtr("CSGBox3D", "set_material", 2_757_459_619) internal val getMaterialPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGBox3D", "get_material", 5934680) + TypeManager.getMethodBindPtr("CSGBox3D", "get_material", 5_934_680) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGCombiner3D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGCombiner3D.kt index 6d56c07ffd..814c60b4e4 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGCombiner3D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGCombiner3D.kt @@ -1,32 +1,20 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api import godot.`annotation`.GodotBaseType import kotlin.Int import kotlin.Suppress -import kotlin.Unit /** - * For complex arrangements of shapes, it is sometimes needed to add structure to your CSG nodes. - * The CSGCombiner3D node allows you to create this structure. The node encapsulates the result of the - * CSG operations of its children. In this way, it is possible to do operations on one set of shapes - * that are children of one CSGCombiner3D node, and a set of separate operations on a second set of - * shapes that are children of a second CSGCombiner3D node, and then do an operation that takes the two - * end results as its input to create the final shape. + * For complex arrangements of shapes, it is sometimes needed to add structure to your CSG nodes. The CSGCombiner3D node allows you to create this structure. The node encapsulates the result of the CSG operations of its children. In this way, it is possible to do operations on one set of shapes that are children of one CSGCombiner3D node, and a set of separate operations on a second set of shapes that are children of a second CSGCombiner3D node, and then do an operation that takes the two end results as its input to create the final shape. * - * **Note:** CSG nodes are intended to be used for level prototyping. Creating CSG nodes has a - * significant CPU cost compared to creating a [MeshInstance3D] with a [PrimitiveMesh]. Moving a CSG - * node within another CSG node also has a significant CPU cost, so it should be avoided during - * gameplay. + * **Note:** CSG nodes are intended to be used for level prototyping. Creating CSG nodes has a significant CPU cost compared to creating a [MeshInstance3D] with a [PrimitiveMesh]. Moving a CSG node within another CSG node also has a significant CPU cost, so it should be avoided during gameplay. */ @GodotBaseType public open class CSGCombiner3D : CSGShape3D() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(118, scriptIndex) } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGCylinder3D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGCylinder3D.kt index 8c8c54a547..299ca772ec 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGCylinder3D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGCylinder3D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -21,16 +18,12 @@ import kotlin.Float import kotlin.Int import kotlin.Long import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** * This node allows you to create a cylinder (or cone) for use with the CSG system. * - * **Note:** CSG nodes are intended to be used for level prototyping. Creating CSG nodes has a - * significant CPU cost compared to creating a [MeshInstance3D] with a [PrimitiveMesh]. Moving a CSG - * node within another CSG node also has a significant CPU cost, so it should be avoided during - * gameplay. + * **Note:** CSG nodes are intended to be used for level prototyping. Creating CSG nodes has a significant CPU cost compared to creating a [MeshInstance3D] with a [PrimitiveMesh]. Moving a CSG node within another CSG node also has a significant CPU cost, so it should be avoided during gameplay. */ @GodotBaseType public open class CSGCylinder3D : CSGPrimitive3D() { @@ -57,8 +50,7 @@ public open class CSGCylinder3D : CSGPrimitive3D() { } /** - * The number of sides of the cylinder, the higher this number the more detail there will be in - * the cylinder. + * The number of sides of the cylinder, the higher this number the more detail there will be in the cylinder. */ public final inline var sides: Int @JvmName("sidesProperty") @@ -80,8 +72,7 @@ public open class CSGCylinder3D : CSGPrimitive3D() { } /** - * If `true` the normals of the cylinder are set to give a smooth effect making the cylinder seem - * rounded. If `false` the cylinder will have a flat shaded look. + * If `true` the normals of the cylinder are set to give a smooth effect making the cylinder seem rounded. If `false` the cylinder will have a flat shaded look. */ public final inline var smoothFaces: Boolean @JvmName("smoothFacesProperty") @@ -102,11 +93,11 @@ public open class CSGCylinder3D : CSGPrimitive3D() { setMaterial(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(119, scriptIndex) } - public final fun setRadius(radius: Float): Unit { + public final fun setRadius(radius: Float) { TransferContext.writeArguments(DOUBLE to radius.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setRadiusPtr, NIL) } @@ -117,7 +108,7 @@ public open class CSGCylinder3D : CSGPrimitive3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setHeight(height: Float): Unit { + public final fun setHeight(height: Float) { TransferContext.writeArguments(DOUBLE to height.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setHeightPtr, NIL) } @@ -128,7 +119,7 @@ public open class CSGCylinder3D : CSGPrimitive3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setSides(sides: Int): Unit { + public final fun setSides(sides: Int) { TransferContext.writeArguments(LONG to sides.toLong()) TransferContext.callMethod(ptr, MethodBindings.setSidesPtr, NIL) } @@ -139,7 +130,7 @@ public open class CSGCylinder3D : CSGPrimitive3D() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setCone(cone: Boolean): Unit { + public final fun setCone(cone: Boolean) { TransferContext.writeArguments(BOOL to cone) TransferContext.callMethod(ptr, MethodBindings.setConePtr, NIL) } @@ -150,7 +141,7 @@ public open class CSGCylinder3D : CSGPrimitive3D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setMaterial(material: Material?): Unit { + public final fun setMaterial(material: Material?) { TransferContext.writeArguments(OBJECT to material) TransferContext.callMethod(ptr, MethodBindings.setMaterialPtr, NIL) } @@ -161,7 +152,7 @@ public open class CSGCylinder3D : CSGPrimitive3D() { return (TransferContext.readReturnValue(OBJECT) as Material?) } - public final fun setSmoothFaces(smoothFaces: Boolean): Unit { + public final fun setSmoothFaces(smoothFaces: Boolean) { TransferContext.writeArguments(BOOL to smoothFaces) TransferContext.callMethod(ptr, MethodBindings.setSmoothFacesPtr, NIL) } @@ -176,39 +167,39 @@ public open class CSGCylinder3D : CSGPrimitive3D() { public object MethodBindings { internal val setRadiusPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGCylinder3D", "set_radius", 373806689) + TypeManager.getMethodBindPtr("CSGCylinder3D", "set_radius", 373_806_689) internal val getRadiusPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGCylinder3D", "get_radius", 1740695150) + TypeManager.getMethodBindPtr("CSGCylinder3D", "get_radius", 1_740_695_150) internal val setHeightPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGCylinder3D", "set_height", 373806689) + TypeManager.getMethodBindPtr("CSGCylinder3D", "set_height", 373_806_689) internal val getHeightPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGCylinder3D", "get_height", 1740695150) + TypeManager.getMethodBindPtr("CSGCylinder3D", "get_height", 1_740_695_150) internal val setSidesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGCylinder3D", "set_sides", 1286410249) + TypeManager.getMethodBindPtr("CSGCylinder3D", "set_sides", 1_286_410_249) internal val getSidesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGCylinder3D", "get_sides", 3905245786) + TypeManager.getMethodBindPtr("CSGCylinder3D", "get_sides", 3_905_245_786) internal val setConePtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGCylinder3D", "set_cone", 2586408642) + TypeManager.getMethodBindPtr("CSGCylinder3D", "set_cone", 2_586_408_642) internal val isConePtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGCylinder3D", "is_cone", 36873697) + TypeManager.getMethodBindPtr("CSGCylinder3D", "is_cone", 36_873_697) internal val setMaterialPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGCylinder3D", "set_material", 2757459619) + TypeManager.getMethodBindPtr("CSGCylinder3D", "set_material", 2_757_459_619) internal val getMaterialPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGCylinder3D", "get_material", 5934680) + TypeManager.getMethodBindPtr("CSGCylinder3D", "get_material", 5_934_680) internal val setSmoothFacesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGCylinder3D", "set_smooth_faces", 2586408642) + TypeManager.getMethodBindPtr("CSGCylinder3D", "set_smooth_faces", 2_586_408_642) internal val getSmoothFacesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGCylinder3D", "get_smooth_faces", 36873697) + TypeManager.getMethodBindPtr("CSGCylinder3D", "get_smooth_faces", 36_873_697) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGMesh3D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGMesh3D.kt index 671f69e571..786a684797 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGMesh3D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGMesh3D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -14,37 +11,23 @@ import godot.core.VariantParser.NIL import godot.core.VariantParser.OBJECT import kotlin.Int import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * This CSG node allows you to use any mesh resource as a CSG shape, provided it is *manifold*. A - * manifold shape is closed, does not self-intersect, does not contain internal faces and has no edges - * that connect to more than two faces. See also [CSGPolygon3D] for drawing 2D extruded polygons to be - * used as CSG nodes. + * This CSG node allows you to use any mesh resource as a CSG shape, provided it is *manifold*. A manifold shape is closed, does not self-intersect, does not contain internal faces and has no edges that connect to more than two faces. See also [CSGPolygon3D] for drawing 2D extruded polygons to be used as CSG nodes. * - * **Note:** CSG nodes are intended to be used for level prototyping. Creating CSG nodes has a - * significant CPU cost compared to creating a [MeshInstance3D] with a [PrimitiveMesh]. Moving a CSG - * node within another CSG node also has a significant CPU cost, so it should be avoided during - * gameplay. + * **Note:** CSG nodes are intended to be used for level prototyping. Creating CSG nodes has a significant CPU cost compared to creating a [MeshInstance3D] with a [PrimitiveMesh]. Moving a CSG node within another CSG node also has a significant CPU cost, so it should be avoided during gameplay. */ @GodotBaseType public open class CSGMesh3D : CSGPrimitive3D() { /** * The [Mesh] resource to use as a CSG shape. * - * **Note:** Some [Mesh] types such as [PlaneMesh], [PointMesh], [QuadMesh], and [RibbonTrailMesh] - * are excluded from the type hint for this property, as these primitives are non-*manifold* and thus - * not compatible with the CSG algorithm. + * **Note:** Some [Mesh] types such as [PlaneMesh], [PointMesh], [QuadMesh], and [RibbonTrailMesh] are excluded from the type hint for this property, as these primitives are non-*manifold* and thus not compatible with the CSG algorithm. * - * **Note:** When using an [ArrayMesh], all vertex attributes except [Mesh.ARRAY_VERTEX], - * [Mesh.ARRAY_NORMAL] and [Mesh.ARRAY_TEX_UV] are left unused. Only [Mesh.ARRAY_VERTEX] and - * [Mesh.ARRAY_TEX_UV] will be passed to the GPU. + * **Note:** When using an [ArrayMesh], all vertex attributes except [Mesh.ARRAY_VERTEX], [Mesh.ARRAY_NORMAL] and [Mesh.ARRAY_TEX_UV] are left unused. Only [Mesh.ARRAY_VERTEX] and [Mesh.ARRAY_TEX_UV] will be passed to the GPU. * - * [Mesh.ARRAY_NORMAL] is only used to determine which faces require the use of flat shading. By - * default, CSGMesh will ignore the mesh's vertex normals, recalculate them for each vertex and use a - * smooth shader. If a flat shader is required for a face, ensure that all vertex normals of the face - * are approximately equal. + * [Mesh.ARRAY_NORMAL] is only used to determine which faces require the use of flat shading. By default, CSGMesh will ignore the mesh's vertex normals, recalculate them for each vertex and use a smooth shader. If a flat shader is required for a face, ensure that all vertex normals of the face are approximately equal. */ public final inline var mesh: Mesh? @JvmName("meshProperty") @@ -65,11 +48,11 @@ public open class CSGMesh3D : CSGPrimitive3D() { setMaterial(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(120, scriptIndex) } - public final fun setMesh(mesh: Mesh?): Unit { + public final fun setMesh(mesh: Mesh?) { TransferContext.writeArguments(OBJECT to mesh) TransferContext.callMethod(ptr, MethodBindings.setMeshPtr, NIL) } @@ -80,7 +63,7 @@ public open class CSGMesh3D : CSGPrimitive3D() { return (TransferContext.readReturnValue(OBJECT) as Mesh?) } - public final fun setMaterial(material: Material?): Unit { + public final fun setMaterial(material: Material?) { TransferContext.writeArguments(OBJECT to material) TransferContext.callMethod(ptr, MethodBindings.setMaterialPtr, NIL) } @@ -95,15 +78,15 @@ public open class CSGMesh3D : CSGPrimitive3D() { public object MethodBindings { internal val setMeshPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGMesh3D", "set_mesh", 194775623) + TypeManager.getMethodBindPtr("CSGMesh3D", "set_mesh", 194_775_623) internal val getMeshPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGMesh3D", "get_mesh", 4081188045) + TypeManager.getMethodBindPtr("CSGMesh3D", "get_mesh", 4_081_188_045) internal val setMaterialPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGMesh3D", "set_material", 2757459619) + TypeManager.getMethodBindPtr("CSGMesh3D", "set_material", 2_757_459_619) internal val getMaterialPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGMesh3D", "get_material", 5934680) + TypeManager.getMethodBindPtr("CSGMesh3D", "get_material", 5_934_680) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGPolygon3D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGPolygon3D.kt index ef662c262c..e3474a8083 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGPolygon3D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGPolygon3D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -34,29 +31,20 @@ import kotlin.Unit import kotlin.jvm.JvmName /** - * An array of 2D points is extruded to quickly and easily create a variety of 3D meshes. See also - * [CSGMesh3D] for using 3D meshes as CSG nodes. + * An array of 2D points is extruded to quickly and easily create a variety of 3D meshes. See also [CSGMesh3D] for using 3D meshes as CSG nodes. * - * **Note:** CSG nodes are intended to be used for level prototyping. Creating CSG nodes has a - * significant CPU cost compared to creating a [MeshInstance3D] with a [PrimitiveMesh]. Moving a CSG - * node within another CSG node also has a significant CPU cost, so it should be avoided during - * gameplay. + * **Note:** CSG nodes are intended to be used for level prototyping. Creating CSG nodes has a significant CPU cost compared to creating a [MeshInstance3D] with a [PrimitiveMesh]. Moving a CSG node within another CSG node also has a significant CPU cost, so it should be avoided during gameplay. */ @GodotBaseType public open class CSGPolygon3D : CSGPrimitive3D() { /** - * The point array that defines the 2D polygon that is extruded. This can be a convex or concave - * polygon with 3 or more points. The polygon must *not* have any intersecting edges. Otherwise, - * triangulation will fail and no mesh will be generated. + * The point array that defines the 2D polygon that is extruded. This can be a convex or concave polygon with 3 or more points. The polygon must *not* have any intersecting edges. Otherwise, triangulation will fail and no mesh will be generated. * * **Note:** If only 1 or 2 points are defined in [polygon], no mesh will be generated. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var polygon: PackedVector2Array @@ -90,8 +78,7 @@ public open class CSGPolygon3D : CSGPrimitive3D() { } /** - * When [mode] is [MODE_SPIN], the total number of degrees the [polygon] is rotated when - * extruding. + * When [mode] is [MODE_SPIN], the total number of degrees the [polygon] is rotated when extruding. */ public final inline var spinDegrees: Float @JvmName("spinDegreesProperty") @@ -124,8 +111,7 @@ public open class CSGPolygon3D : CSGPrimitive3D() { } /** - * When [mode] is [MODE_PATH], this will determine if the interval should be by distance - * ([PATH_INTERVAL_DISTANCE]) or subdivision fractions ([PATH_INTERVAL_SUBDIVIDE]). + * When [mode] is [MODE_PATH], this will determine if the interval should be by distance ([PATH_INTERVAL_DISTANCE]) or subdivision fractions ([PATH_INTERVAL_SUBDIVIDE]). */ public final inline var pathIntervalType: PathIntervalType @JvmName("pathIntervalTypeProperty") @@ -147,8 +133,7 @@ public open class CSGPolygon3D : CSGPrimitive3D() { } /** - * When [mode] is [MODE_PATH], extrusions that are less than this angle, will be merged together - * to reduce polygon count. + * When [mode] is [MODE_PATH], extrusions that are less than this angle, will be merged together to reduce polygon count. */ public final inline var pathSimplifyAngle: Float @JvmName("pathSimplifyAngleProperty") @@ -159,8 +144,7 @@ public open class CSGPolygon3D : CSGPrimitive3D() { } /** - * When [mode] is [MODE_PATH], the path rotation method used to rotate the [polygon] as it is - * extruded. + * When [mode] is [MODE_PATH], the path rotation method used to rotate the [polygon] as it is extruded. */ public final inline var pathRotation: PathRotation @JvmName("pathRotationProperty") @@ -171,9 +155,7 @@ public open class CSGPolygon3D : CSGPrimitive3D() { } /** - * When [mode] is [MODE_PATH], if `true` the polygon will be rotated according to the proper - * tangent of the path at the sampled points. If `false` an approximation is used, which decreases in - * accuracy as the number of subdivisions decreases. + * When [mode] is [MODE_PATH], if `true` the polygon will be rotated according to the proper tangent of the path at the sampled points. If `false` an approximation is used, which decreases in accuracy as the number of subdivisions decreases. */ public final inline var pathRotationAccurate: Boolean @JvmName("pathRotationAccurateProperty") @@ -184,8 +166,7 @@ public open class CSGPolygon3D : CSGPrimitive3D() { } /** - * When [mode] is [MODE_PATH], if `true` the [Transform3D] of the [CSGPolygon3D] is used as the - * starting point for the extrusions, not the [Transform3D] of the [pathNode]. + * When [mode] is [MODE_PATH], if `true` the [Transform3D] of the [CSGPolygon3D] is used as the starting point for the extrusions, not the [Transform3D] of the [pathNode]. */ public final inline var pathLocal: Boolean @JvmName("pathLocalProperty") @@ -196,9 +177,7 @@ public open class CSGPolygon3D : CSGPrimitive3D() { } /** - * When [mode] is [MODE_PATH], by default, the top half of the [material] is stretched along the - * entire length of the extruded shape. If `false` the top half of the material is repeated every - * step of the extrusion. + * When [mode] is [MODE_PATH], by default, the top half of the [material] is stretched along the entire length of the extruded shape. If `false` the top half of the material is repeated every step of the extrusion. */ public final inline var pathContinuousU: Boolean @JvmName("pathContinuousUProperty") @@ -209,9 +188,7 @@ public open class CSGPolygon3D : CSGPrimitive3D() { } /** - * When [mode] is [MODE_PATH], this is the distance along the path, in meters, the texture - * coordinates will tile. When set to 0, texture coordinates will match geometry exactly with no - * tiling. + * When [mode] is [MODE_PATH], this is the distance along the path, in meters, the texture coordinates will tile. When set to 0, texture coordinates will match geometry exactly with no tiling. */ public final inline var pathUDistance: Float @JvmName("pathUDistanceProperty") @@ -222,8 +199,7 @@ public open class CSGPolygon3D : CSGPrimitive3D() { } /** - * When [mode] is [MODE_PATH], if `true` the ends of the path are joined, by adding an extrusion - * between the last and first points of the path. + * When [mode] is [MODE_PATH], if `true` the ends of the path are joined, by adding an extrusion between the last and first points of the path. */ public final inline var pathJoined: Boolean @JvmName("pathJoinedProperty") @@ -245,9 +221,7 @@ public open class CSGPolygon3D : CSGPrimitive3D() { } /** - * Material to use for the resulting mesh. The UV maps the top half of the material to the - * extruded shape (U along the length of the extrusions and V around the outline of the [polygon]), - * the bottom-left quarter to the front end face, and the bottom-right quarter to the back end face. + * Material to use for the resulting mesh. The UV maps the top half of the material to the extruded shape (U along the length of the extrusions and V around the outline of the [polygon]), the bottom-left quarter to the front end face, and the bottom-right quarter to the back end face. */ public final inline var material: Material? @JvmName("materialProperty") @@ -257,7 +231,7 @@ public open class CSGPolygon3D : CSGPrimitive3D() { setMaterial(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(121, scriptIndex) } @@ -272,33 +246,26 @@ public open class CSGPolygon3D : CSGPrimitive3D() { * csgpolygon3d.polygon = myCoreType * `````` * - * The point array that defines the 2D polygon that is extruded. This can be a convex or concave - * polygon with 3 or more points. The polygon must *not* have any intersecting edges. Otherwise, - * triangulation will fail and no mesh will be generated. + * The point array that defines the 2D polygon that is extruded. This can be a convex or concave polygon with 3 or more points. The polygon must *not* have any intersecting edges. Otherwise, triangulation will fail and no mesh will be generated. * * **Note:** If only 1 or 2 points are defined in [polygon], no mesh will be generated. */ @CoreTypeHelper - public final fun polygonMutate(block: PackedVector2Array.() -> Unit): PackedVector2Array = - polygon.apply { + public final fun polygonMutate(block: PackedVector2Array.() -> Unit): PackedVector2Array = polygon.apply { block(this) polygon = this } /** * This is a helper function for [polygon] to make dealing with local copies easier. - * Allow to directly modify each element of the local copy of the property and assign it back to - * the Object. + * Allow to directly modify each element of the local copy of the property and assign it back to the Object. * - * The point array that defines the 2D polygon that is extruded. This can be a convex or concave - * polygon with 3 or more points. The polygon must *not* have any intersecting edges. Otherwise, - * triangulation will fail and no mesh will be generated. + * The point array that defines the 2D polygon that is extruded. This can be a convex or concave polygon with 3 or more points. The polygon must *not* have any intersecting edges. Otherwise, triangulation will fail and no mesh will be generated. * * **Note:** If only 1 or 2 points are defined in [polygon], no mesh will be generated. */ @CoreTypeHelper - public final fun polygonMutateEach(block: (index: Int, `value`: Vector2) -> Unit): - PackedVector2Array = polygon.apply { + public final fun polygonMutateEach(block: (index: Int, `value`: Vector2) -> Unit): PackedVector2Array = polygon.apply { this.forEachIndexed { index, value -> block(index, value) this[index] = value @@ -306,7 +273,7 @@ public open class CSGPolygon3D : CSGPrimitive3D() { polygon = this } - public final fun setPolygon(polygon: PackedVector2Array): Unit { + public final fun setPolygon(polygon: PackedVector2Array) { TransferContext.writeArguments(PACKED_VECTOR2_ARRAY to polygon) TransferContext.callMethod(ptr, MethodBindings.setPolygonPtr, NIL) } @@ -317,7 +284,7 @@ public open class CSGPolygon3D : CSGPrimitive3D() { return (TransferContext.readReturnValue(PACKED_VECTOR2_ARRAY) as PackedVector2Array) } - public final fun setMode(mode: Mode): Unit { + public final fun setMode(mode: Mode) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setModePtr, NIL) } @@ -328,7 +295,7 @@ public open class CSGPolygon3D : CSGPrimitive3D() { return Mode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setDepth(depth: Float): Unit { + public final fun setDepth(depth: Float) { TransferContext.writeArguments(DOUBLE to depth.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setDepthPtr, NIL) } @@ -339,7 +306,7 @@ public open class CSGPolygon3D : CSGPrimitive3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setSpinDegrees(degrees: Float): Unit { + public final fun setSpinDegrees(degrees: Float) { TransferContext.writeArguments(DOUBLE to degrees.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setSpinDegreesPtr, NIL) } @@ -350,7 +317,7 @@ public open class CSGPolygon3D : CSGPrimitive3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setSpinSides(spinSides: Int): Unit { + public final fun setSpinSides(spinSides: Int) { TransferContext.writeArguments(LONG to spinSides.toLong()) TransferContext.callMethod(ptr, MethodBindings.setSpinSidesPtr, NIL) } @@ -361,7 +328,7 @@ public open class CSGPolygon3D : CSGPrimitive3D() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setPathNode(path: NodePath): Unit { + public final fun setPathNode(path: NodePath) { TransferContext.writeArguments(NODE_PATH to path) TransferContext.callMethod(ptr, MethodBindings.setPathNodePtr, NIL) } @@ -372,7 +339,7 @@ public open class CSGPolygon3D : CSGPrimitive3D() { return (TransferContext.readReturnValue(NODE_PATH) as NodePath) } - public final fun setPathIntervalType(intervalType: PathIntervalType): Unit { + public final fun setPathIntervalType(intervalType: PathIntervalType) { TransferContext.writeArguments(LONG to intervalType.id) TransferContext.callMethod(ptr, MethodBindings.setPathIntervalTypePtr, NIL) } @@ -383,7 +350,7 @@ public open class CSGPolygon3D : CSGPrimitive3D() { return PathIntervalType.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setPathInterval(interval: Float): Unit { + public final fun setPathInterval(interval: Float) { TransferContext.writeArguments(DOUBLE to interval.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setPathIntervalPtr, NIL) } @@ -394,7 +361,7 @@ public open class CSGPolygon3D : CSGPrimitive3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setPathSimplifyAngle(degrees: Float): Unit { + public final fun setPathSimplifyAngle(degrees: Float) { TransferContext.writeArguments(DOUBLE to degrees.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setPathSimplifyAnglePtr, NIL) } @@ -405,7 +372,7 @@ public open class CSGPolygon3D : CSGPrimitive3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setPathRotation(pathRotation: PathRotation): Unit { + public final fun setPathRotation(pathRotation: PathRotation) { TransferContext.writeArguments(LONG to pathRotation.id) TransferContext.callMethod(ptr, MethodBindings.setPathRotationPtr, NIL) } @@ -416,7 +383,7 @@ public open class CSGPolygon3D : CSGPrimitive3D() { return PathRotation.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setPathRotationAccurate(enable: Boolean): Unit { + public final fun setPathRotationAccurate(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setPathRotationAccuratePtr, NIL) } @@ -427,7 +394,7 @@ public open class CSGPolygon3D : CSGPrimitive3D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setPathLocal(enable: Boolean): Unit { + public final fun setPathLocal(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setPathLocalPtr, NIL) } @@ -438,7 +405,7 @@ public open class CSGPolygon3D : CSGPrimitive3D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setPathContinuousU(enable: Boolean): Unit { + public final fun setPathContinuousU(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setPathContinuousUPtr, NIL) } @@ -449,7 +416,7 @@ public open class CSGPolygon3D : CSGPrimitive3D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setPathUDistance(distance: Float): Unit { + public final fun setPathUDistance(distance: Float) { TransferContext.writeArguments(DOUBLE to distance.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setPathUDistancePtr, NIL) } @@ -460,7 +427,7 @@ public open class CSGPolygon3D : CSGPrimitive3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setPathJoined(enable: Boolean): Unit { + public final fun setPathJoined(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setPathJoinedPtr, NIL) } @@ -471,7 +438,7 @@ public open class CSGPolygon3D : CSGPrimitive3D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setMaterial(material: Material?): Unit { + public final fun setMaterial(material: Material?) { TransferContext.writeArguments(OBJECT to material) TransferContext.callMethod(ptr, MethodBindings.setMaterialPtr, NIL) } @@ -482,7 +449,7 @@ public open class CSGPolygon3D : CSGPrimitive3D() { return (TransferContext.readReturnValue(OBJECT) as Material?) } - public final fun setSmoothFaces(smoothFaces: Boolean): Unit { + public final fun setSmoothFaces(smoothFaces: Boolean) { TransferContext.writeArguments(BOOL to smoothFaces) TransferContext.callMethod(ptr, MethodBindings.setSmoothFacesPtr, NIL) } @@ -493,7 +460,7 @@ public open class CSGPolygon3D : CSGPrimitive3D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setPathNode(path: String) = setPathNode(path.asCachedNodePath()) + public final fun setPathNode(path: String): Unit = setPathNode(path.asCachedNodePath()) public enum class Mode( id: Long, @@ -557,8 +524,7 @@ public open class CSGPolygon3D : CSGPrimitive3D() { id: Long, ) { /** - * When [mode] is set to [MODE_PATH], [pathInterval] will determine the distance, in meters, - * each interval of the path will extrude. + * When [mode] is set to [MODE_PATH], [pathInterval] will determine the distance, in meters, each interval of the path will extrude. */ DISTANCE(0), /** @@ -581,105 +547,105 @@ public open class CSGPolygon3D : CSGPrimitive3D() { public object MethodBindings { internal val setPolygonPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "set_polygon", 1509147220) + TypeManager.getMethodBindPtr("CSGPolygon3D", "set_polygon", 1_509_147_220) internal val getPolygonPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "get_polygon", 2961356807) + TypeManager.getMethodBindPtr("CSGPolygon3D", "get_polygon", 2_961_356_807) internal val setModePtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "set_mode", 3158377035) + TypeManager.getMethodBindPtr("CSGPolygon3D", "set_mode", 3_158_377_035) internal val getModePtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "get_mode", 1201612222) + TypeManager.getMethodBindPtr("CSGPolygon3D", "get_mode", 1_201_612_222) internal val setDepthPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "set_depth", 373806689) + TypeManager.getMethodBindPtr("CSGPolygon3D", "set_depth", 373_806_689) internal val getDepthPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "get_depth", 1740695150) + TypeManager.getMethodBindPtr("CSGPolygon3D", "get_depth", 1_740_695_150) internal val setSpinDegreesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "set_spin_degrees", 373806689) + TypeManager.getMethodBindPtr("CSGPolygon3D", "set_spin_degrees", 373_806_689) internal val getSpinDegreesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "get_spin_degrees", 1740695150) + TypeManager.getMethodBindPtr("CSGPolygon3D", "get_spin_degrees", 1_740_695_150) internal val setSpinSidesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "set_spin_sides", 1286410249) + TypeManager.getMethodBindPtr("CSGPolygon3D", "set_spin_sides", 1_286_410_249) internal val getSpinSidesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "get_spin_sides", 3905245786) + TypeManager.getMethodBindPtr("CSGPolygon3D", "get_spin_sides", 3_905_245_786) internal val setPathNodePtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "set_path_node", 1348162250) + TypeManager.getMethodBindPtr("CSGPolygon3D", "set_path_node", 1_348_162_250) internal val getPathNodePtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "get_path_node", 4075236667) + TypeManager.getMethodBindPtr("CSGPolygon3D", "get_path_node", 4_075_236_667) internal val setPathIntervalTypePtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "set_path_interval_type", 3744240707) + TypeManager.getMethodBindPtr("CSGPolygon3D", "set_path_interval_type", 3_744_240_707) internal val getPathIntervalTypePtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "get_path_interval_type", 3434618397) + TypeManager.getMethodBindPtr("CSGPolygon3D", "get_path_interval_type", 3_434_618_397) internal val setPathIntervalPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "set_path_interval", 373806689) + TypeManager.getMethodBindPtr("CSGPolygon3D", "set_path_interval", 373_806_689) internal val getPathIntervalPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "get_path_interval", 1740695150) + TypeManager.getMethodBindPtr("CSGPolygon3D", "get_path_interval", 1_740_695_150) internal val setPathSimplifyAnglePtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "set_path_simplify_angle", 373806689) + TypeManager.getMethodBindPtr("CSGPolygon3D", "set_path_simplify_angle", 373_806_689) internal val getPathSimplifyAnglePtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "get_path_simplify_angle", 1740695150) + TypeManager.getMethodBindPtr("CSGPolygon3D", "get_path_simplify_angle", 1_740_695_150) internal val setPathRotationPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "set_path_rotation", 1412947288) + TypeManager.getMethodBindPtr("CSGPolygon3D", "set_path_rotation", 1_412_947_288) internal val getPathRotationPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "get_path_rotation", 647219346) + TypeManager.getMethodBindPtr("CSGPolygon3D", "get_path_rotation", 647_219_346) internal val setPathRotationAccuratePtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "set_path_rotation_accurate", 2586408642) + TypeManager.getMethodBindPtr("CSGPolygon3D", "set_path_rotation_accurate", 2_586_408_642) internal val getPathRotationAccuratePtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "get_path_rotation_accurate", 36873697) + TypeManager.getMethodBindPtr("CSGPolygon3D", "get_path_rotation_accurate", 36_873_697) internal val setPathLocalPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "set_path_local", 2586408642) + TypeManager.getMethodBindPtr("CSGPolygon3D", "set_path_local", 2_586_408_642) internal val isPathLocalPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "is_path_local", 36873697) + TypeManager.getMethodBindPtr("CSGPolygon3D", "is_path_local", 36_873_697) internal val setPathContinuousUPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "set_path_continuous_u", 2586408642) + TypeManager.getMethodBindPtr("CSGPolygon3D", "set_path_continuous_u", 2_586_408_642) internal val isPathContinuousUPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "is_path_continuous_u", 36873697) + TypeManager.getMethodBindPtr("CSGPolygon3D", "is_path_continuous_u", 36_873_697) internal val setPathUDistancePtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "set_path_u_distance", 373806689) + TypeManager.getMethodBindPtr("CSGPolygon3D", "set_path_u_distance", 373_806_689) internal val getPathUDistancePtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "get_path_u_distance", 1740695150) + TypeManager.getMethodBindPtr("CSGPolygon3D", "get_path_u_distance", 1_740_695_150) internal val setPathJoinedPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "set_path_joined", 2586408642) + TypeManager.getMethodBindPtr("CSGPolygon3D", "set_path_joined", 2_586_408_642) internal val isPathJoinedPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "is_path_joined", 36873697) + TypeManager.getMethodBindPtr("CSGPolygon3D", "is_path_joined", 36_873_697) internal val setMaterialPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "set_material", 2757459619) + TypeManager.getMethodBindPtr("CSGPolygon3D", "set_material", 2_757_459_619) internal val getMaterialPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "get_material", 5934680) + TypeManager.getMethodBindPtr("CSGPolygon3D", "get_material", 5_934_680) internal val setSmoothFacesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "set_smooth_faces", 2586408642) + TypeManager.getMethodBindPtr("CSGPolygon3D", "set_smooth_faces", 2_586_408_642) internal val getSmoothFacesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPolygon3D", "get_smooth_faces", 36873697) + TypeManager.getMethodBindPtr("CSGPolygon3D", "get_smooth_faces", 36_873_697) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGPrimitive3D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGPrimitive3D.kt index 6dd022c698..aa29f9ae5c 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGPrimitive3D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGPrimitive3D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -15,24 +12,17 @@ import godot.core.VariantParser.NIL import kotlin.Boolean import kotlin.Int import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * Parent class for various CSG primitives. It contains code and functionality that is common - * between them. It cannot be used directly. Instead use one of the various classes that inherit from - * it. + * Parent class for various CSG primitives. It contains code and functionality that is common between them. It cannot be used directly. Instead use one of the various classes that inherit from it. * - * **Note:** CSG nodes are intended to be used for level prototyping. Creating CSG nodes has a - * significant CPU cost compared to creating a [MeshInstance3D] with a [PrimitiveMesh]. Moving a CSG - * node within another CSG node also has a significant CPU cost, so it should be avoided during - * gameplay. + * **Note:** CSG nodes are intended to be used for level prototyping. Creating CSG nodes has a significant CPU cost compared to creating a [MeshInstance3D] with a [PrimitiveMesh]. Moving a CSG node within another CSG node also has a significant CPU cost, so it should be avoided during gameplay. */ @GodotBaseType public open class CSGPrimitive3D internal constructor() : CSGShape3D() { /** - * If set, the order of the vertices in each triangle are reversed resulting in the backside of - * the mesh being drawn. + * If set, the order of the vertices in each triangle are reversed resulting in the backside of the mesh being drawn. */ public final inline var flipFaces: Boolean @JvmName("flipFacesProperty") @@ -42,11 +32,11 @@ public open class CSGPrimitive3D internal constructor() : CSGShape3D() { setFlipFaces(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(122, scriptIndex) } - public final fun setFlipFaces(flipFaces: Boolean): Unit { + public final fun setFlipFaces(flipFaces: Boolean) { TransferContext.writeArguments(BOOL to flipFaces) TransferContext.callMethod(ptr, MethodBindings.setFlipFacesPtr, NIL) } @@ -61,9 +51,9 @@ public open class CSGPrimitive3D internal constructor() : CSGShape3D() { public object MethodBindings { internal val setFlipFacesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPrimitive3D", "set_flip_faces", 2586408642) + TypeManager.getMethodBindPtr("CSGPrimitive3D", "set_flip_faces", 2_586_408_642) internal val getFlipFacesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGPrimitive3D", "get_flip_faces", 2240911060) + TypeManager.getMethodBindPtr("CSGPrimitive3D", "get_flip_faces", 2_240_911_060) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGShape3D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGShape3D.kt index 63d191d4ad..fb425a51c8 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGShape3D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGShape3D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -24,31 +21,25 @@ import kotlin.Float import kotlin.Int import kotlin.Long import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** * This is the CSG base class that provides CSG operation support to the various CSG nodes in Godot. * - * **Performance:** CSG nodes are only intended for prototyping as they have a significant CPU - * performance cost. + * **Performance:** CSG nodes are only intended for prototyping as they have a significant CPU performance cost. * * Consider baking final CSG operation results into static geometry that replaces the CSG nodes. * - * Individual CSG root node results can be baked to nodes with static resources with the editor menu - * that appears when a CSG root node is selected. + * Individual CSG root node results can be baked to nodes with static resources with the editor menu that appears when a CSG root node is selected. * - * Individual CSG root nodes can also be baked to static resources with scripts by calling - * [bakeStaticMesh] for the visual mesh or [bakeCollisionShape] for the physics collision. + * Individual CSG root nodes can also be baked to static resources with scripts by calling [bakeStaticMesh] for the visual mesh or [bakeCollisionShape] for the physics collision. * - * Entire scenes of CSG nodes can be baked to static geometry and exported with the editor gltf - * scene exporter. + * Entire scenes of CSG nodes can be baked to static geometry and exported with the editor gltf scene exporter. */ @GodotBaseType public open class CSGShape3D internal constructor() : GeometryInstance3D() { /** - * The operation that is performed on this shape. This is ignored for the first CSG child node as - * the operation is between this node and the previous child of this nodes parent. + * The operation that is performed on this shape. This is ignored for the first CSG child node as the operation is between this node and the previous child of this nodes parent. */ public final inline var operation: Operation @JvmName("operationProperty") @@ -70,8 +61,7 @@ public open class CSGShape3D internal constructor() : GeometryInstance3D() { } /** - * Calculate tangents for the CSG shape which allows the use of normal maps. This is only applied - * on the root shape, this setting is ignored on any child. + * Calculate tangents for the CSG shape which allows the use of normal maps. This is only applied on the root shape, this setting is ignored on any child. */ public final inline var calculateTangents: Boolean @JvmName("calculateTangentsProperty") @@ -82,9 +72,7 @@ public open class CSGShape3D internal constructor() : GeometryInstance3D() { } /** - * Adds a collision shape to the physics engine for our CSG shape. This will always act like a - * static body. Note that the collision shape is still active even if the CSG shape itself is hidden. - * See also [collisionMask] and [collisionPriority]. + * Adds a collision shape to the physics engine for our CSG shape. This will always act like a static body. Note that the collision shape is still active even if the CSG shape itself is hidden. See also [collisionMask] and [collisionPriority]. */ public final inline var useCollision: Boolean @JvmName("useCollisionProperty") @@ -97,14 +85,9 @@ public open class CSGShape3D internal constructor() : GeometryInstance3D() { /** * The physics layers this area is in. * - * Collidable objects can exist in any of 32 different layers. These layers work like a tagging - * system, and are not visual. A collidable can use these layers to select with which objects it can - * collide, using the collision_mask property. + * Collidable objects can exist in any of 32 different layers. These layers work like a tagging system, and are not visual. A collidable can use these layers to select with which objects it can collide, using the collision_mask property. * - * A contact is detected if object A is in any of the layers that object B scans, or object B is - * in any layer scanned by object A. See - * [url=$DOCS_URL/tutorials/physics/physics_introduction.html#collision-layers-and-masks]Collision - * layers and masks[/url] in the documentation for more information. + * A contact is detected if object A is in any of the layers that object B scans, or object B is in any layer scanned by object A. See [url=$DOCS_URL/tutorials/physics/physics_introduction.html#collision-layers-and-masks]Collision layers and masks[/url] in the documentation for more information. */ public final inline var collisionLayer: Long @JvmName("collisionLayerProperty") @@ -115,10 +98,7 @@ public open class CSGShape3D internal constructor() : GeometryInstance3D() { } /** - * The physics layers this CSG shape scans for collisions. Only effective if [useCollision] is - * `true`. See - * [url=$DOCS_URL/tutorials/physics/physics_introduction.html#collision-layers-and-masks]Collision - * layers and masks[/url] in the documentation for more information. + * The physics layers this CSG shape scans for collisions. Only effective if [useCollision] is `true`. See [url=$DOCS_URL/tutorials/physics/physics_introduction.html#collision-layers-and-masks]Collision layers and masks[/url] in the documentation for more information. */ public final inline var collisionMask: Long @JvmName("collisionMaskProperty") @@ -129,10 +109,7 @@ public open class CSGShape3D internal constructor() : GeometryInstance3D() { } /** - * The priority used to solve colliding when occurring penetration. Only effective if - * [useCollision] is `true`. The higher the priority is, the lower the penetration into the object - * will be. This can for example be used to prevent the player from breaking through the boundaries - * of a level. + * The priority used to solve colliding when occurring penetration. Only effective if [useCollision] is `true`. The higher the priority is, the lower the penetration into the object will be. This can for example be used to prevent the player from breaking through the boundaries of a level. */ public final inline var collisionPriority: Float @JvmName("collisionPriorityProperty") @@ -142,7 +119,7 @@ public open class CSGShape3D internal constructor() : GeometryInstance3D() { setCollisionPriority(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(123, scriptIndex) } @@ -155,7 +132,7 @@ public open class CSGShape3D internal constructor() : GeometryInstance3D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setOperation(operation: Operation): Unit { + public final fun setOperation(operation: Operation) { TransferContext.writeArguments(LONG to operation.id) TransferContext.callMethod(ptr, MethodBindings.setOperationPtr, NIL) } @@ -166,7 +143,7 @@ public open class CSGShape3D internal constructor() : GeometryInstance3D() { return Operation.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setSnap(snap: Float): Unit { + public final fun setSnap(snap: Float) { TransferContext.writeArguments(DOUBLE to snap.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setSnapPtr, NIL) } @@ -177,7 +154,7 @@ public open class CSGShape3D internal constructor() : GeometryInstance3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setUseCollision(operation: Boolean): Unit { + public final fun setUseCollision(operation: Boolean) { TransferContext.writeArguments(BOOL to operation) TransferContext.callMethod(ptr, MethodBindings.setUseCollisionPtr, NIL) } @@ -188,7 +165,7 @@ public open class CSGShape3D internal constructor() : GeometryInstance3D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setCollisionLayer(layer: Long): Unit { + public final fun setCollisionLayer(layer: Long) { TransferContext.writeArguments(LONG to layer) TransferContext.callMethod(ptr, MethodBindings.setCollisionLayerPtr, NIL) } @@ -199,7 +176,7 @@ public open class CSGShape3D internal constructor() : GeometryInstance3D() { return (TransferContext.readReturnValue(LONG) as Long) } - public final fun setCollisionMask(mask: Long): Unit { + public final fun setCollisionMask(mask: Long) { TransferContext.writeArguments(LONG to mask) TransferContext.callMethod(ptr, MethodBindings.setCollisionMaskPtr, NIL) } @@ -211,17 +188,15 @@ public open class CSGShape3D internal constructor() : GeometryInstance3D() { } /** - * Based on [value], enables or disables the specified layer in the [collisionMask], given a - * [layerNumber] between 1 and 32. + * Based on [value], enables or disables the specified layer in the [collisionMask], given a [layerNumber] between 1 and 32. */ - public final fun setCollisionMaskValue(layerNumber: Int, `value`: Boolean): Unit { + public final fun setCollisionMaskValue(layerNumber: Int, `value`: Boolean) { TransferContext.writeArguments(LONG to layerNumber.toLong(), BOOL to value) TransferContext.callMethod(ptr, MethodBindings.setCollisionMaskValuePtr, NIL) } /** - * Returns whether or not the specified layer of the [collisionMask] is enabled, given a - * [layerNumber] between 1 and 32. + * Returns whether or not the specified layer of the [collisionMask] is enabled, given a [layerNumber] between 1 and 32. */ public final fun getCollisionMaskValue(layerNumber: Int): Boolean { TransferContext.writeArguments(LONG to layerNumber.toLong()) @@ -230,17 +205,15 @@ public open class CSGShape3D internal constructor() : GeometryInstance3D() { } /** - * Based on [value], enables or disables the specified layer in the [collisionLayer], given a - * [layerNumber] between 1 and 32. + * Based on [value], enables or disables the specified layer in the [collisionLayer], given a [layerNumber] between 1 and 32. */ - public final fun setCollisionLayerValue(layerNumber: Int, `value`: Boolean): Unit { + public final fun setCollisionLayerValue(layerNumber: Int, `value`: Boolean) { TransferContext.writeArguments(LONG to layerNumber.toLong(), BOOL to value) TransferContext.callMethod(ptr, MethodBindings.setCollisionLayerValuePtr, NIL) } /** - * Returns whether or not the specified layer of the [collisionLayer] is enabled, given a - * [layerNumber] between 1 and 32. + * Returns whether or not the specified layer of the [collisionLayer] is enabled, given a [layerNumber] between 1 and 32. */ public final fun getCollisionLayerValue(layerNumber: Int): Boolean { TransferContext.writeArguments(LONG to layerNumber.toLong()) @@ -248,7 +221,7 @@ public open class CSGShape3D internal constructor() : GeometryInstance3D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setCollisionPriority(priority: Float): Unit { + public final fun setCollisionPriority(priority: Float) { TransferContext.writeArguments(DOUBLE to priority.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setCollisionPriorityPtr, NIL) } @@ -259,7 +232,7 @@ public open class CSGShape3D internal constructor() : GeometryInstance3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setCalculateTangents(enabled: Boolean): Unit { + public final fun setCalculateTangents(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setCalculateTangentsPtr, NIL) } @@ -271,8 +244,7 @@ public open class CSGShape3D internal constructor() : GeometryInstance3D() { } /** - * Returns an [Array] with two elements, the first is the [Transform3D] of this node and the - * second is the root [Mesh] of this node. Only works when this node is the root shape. + * Returns an [Array] with two elements, the first is the [Transform3D] of this node and the second is the root [Mesh] of this node. Only works when this node is the root shape. */ public final fun getMeshes(): VariantArray { TransferContext.writeArguments() @@ -281,9 +253,7 @@ public open class CSGShape3D internal constructor() : GeometryInstance3D() { } /** - * Returns a baked static [ArrayMesh] of this node's CSG operation result. Materials from involved - * CSG nodes are added as extra mesh surfaces. Returns an empty mesh if the node is not a CSG root - * node or has no valid geometry. + * Returns a baked static [ArrayMesh] of this node's CSG operation result. Materials from involved CSG nodes are added as extra mesh surfaces. Returns an empty mesh if the node is not a CSG root node or has no valid geometry. */ public final fun bakeStaticMesh(): ArrayMesh? { TransferContext.writeArguments() @@ -292,12 +262,9 @@ public open class CSGShape3D internal constructor() : GeometryInstance3D() { } /** - * Returns a baked physics [ConcavePolygonShape3D] of this node's CSG operation result. Returns an - * empty shape if the node is not a CSG root node or has no valid geometry. + * Returns a baked physics [ConcavePolygonShape3D] of this node's CSG operation result. Returns an empty shape if the node is not a CSG root node or has no valid geometry. * - * **Performance:** If the CSG operation results in a very detailed geometry with many faces - * physics performance will be very slow. Concave shapes should in general only be used for static - * level geometry and not with dynamic objects that are moving. + * **Performance:** If the CSG operation results in a very detailed geometry with many faces physics performance will be very slow. Concave shapes should in general only be used for static level geometry and not with dynamic objects that are moving. */ public final fun bakeCollisionShape(): ConcavePolygonShape3D? { TransferContext.writeArguments() @@ -336,69 +303,69 @@ public open class CSGShape3D internal constructor() : GeometryInstance3D() { public object MethodBindings { internal val isRootShapePtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGShape3D", "is_root_shape", 36873697) + TypeManager.getMethodBindPtr("CSGShape3D", "is_root_shape", 36_873_697) internal val setOperationPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGShape3D", "set_operation", 811425055) + TypeManager.getMethodBindPtr("CSGShape3D", "set_operation", 811_425_055) internal val getOperationPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGShape3D", "get_operation", 2662425879) + TypeManager.getMethodBindPtr("CSGShape3D", "get_operation", 2_662_425_879) internal val setSnapPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGShape3D", "set_snap", 373806689) + TypeManager.getMethodBindPtr("CSGShape3D", "set_snap", 373_806_689) internal val getSnapPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGShape3D", "get_snap", 1740695150) + TypeManager.getMethodBindPtr("CSGShape3D", "get_snap", 1_740_695_150) internal val setUseCollisionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGShape3D", "set_use_collision", 2586408642) + TypeManager.getMethodBindPtr("CSGShape3D", "set_use_collision", 2_586_408_642) internal val isUsingCollisionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGShape3D", "is_using_collision", 36873697) + TypeManager.getMethodBindPtr("CSGShape3D", "is_using_collision", 36_873_697) internal val setCollisionLayerPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGShape3D", "set_collision_layer", 1286410249) + TypeManager.getMethodBindPtr("CSGShape3D", "set_collision_layer", 1_286_410_249) internal val getCollisionLayerPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGShape3D", "get_collision_layer", 3905245786) + TypeManager.getMethodBindPtr("CSGShape3D", "get_collision_layer", 3_905_245_786) internal val setCollisionMaskPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGShape3D", "set_collision_mask", 1286410249) + TypeManager.getMethodBindPtr("CSGShape3D", "set_collision_mask", 1_286_410_249) internal val getCollisionMaskPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGShape3D", "get_collision_mask", 3905245786) + TypeManager.getMethodBindPtr("CSGShape3D", "get_collision_mask", 3_905_245_786) internal val setCollisionMaskValuePtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGShape3D", "set_collision_mask_value", 300928843) + TypeManager.getMethodBindPtr("CSGShape3D", "set_collision_mask_value", 300_928_843) internal val getCollisionMaskValuePtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGShape3D", "get_collision_mask_value", 1116898809) + TypeManager.getMethodBindPtr("CSGShape3D", "get_collision_mask_value", 1_116_898_809) internal val setCollisionLayerValuePtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGShape3D", "set_collision_layer_value", 300928843) + TypeManager.getMethodBindPtr("CSGShape3D", "set_collision_layer_value", 300_928_843) internal val getCollisionLayerValuePtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGShape3D", "get_collision_layer_value", 1116898809) + TypeManager.getMethodBindPtr("CSGShape3D", "get_collision_layer_value", 1_116_898_809) internal val setCollisionPriorityPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGShape3D", "set_collision_priority", 373806689) + TypeManager.getMethodBindPtr("CSGShape3D", "set_collision_priority", 373_806_689) internal val getCollisionPriorityPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGShape3D", "get_collision_priority", 1740695150) + TypeManager.getMethodBindPtr("CSGShape3D", "get_collision_priority", 1_740_695_150) internal val setCalculateTangentsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGShape3D", "set_calculate_tangents", 2586408642) + TypeManager.getMethodBindPtr("CSGShape3D", "set_calculate_tangents", 2_586_408_642) internal val isCalculatingTangentsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGShape3D", "is_calculating_tangents", 36873697) + TypeManager.getMethodBindPtr("CSGShape3D", "is_calculating_tangents", 36_873_697) internal val getMeshesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGShape3D", "get_meshes", 3995934104) + TypeManager.getMethodBindPtr("CSGShape3D", "get_meshes", 3_995_934_104) internal val bakeStaticMeshPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGShape3D", "bake_static_mesh", 1605880883) + TypeManager.getMethodBindPtr("CSGShape3D", "bake_static_mesh", 1_605_880_883) internal val bakeCollisionShapePtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGShape3D", "bake_collision_shape", 36102322) + TypeManager.getMethodBindPtr("CSGShape3D", "bake_collision_shape", 36_102_322) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGSphere3D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGSphere3D.kt index d6183a44de..39125b98eb 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGSphere3D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGSphere3D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -21,16 +18,12 @@ import kotlin.Float import kotlin.Int import kotlin.Long import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** * This node allows you to create a sphere for use with the CSG system. * - * **Note:** CSG nodes are intended to be used for level prototyping. Creating CSG nodes has a - * significant CPU cost compared to creating a [MeshInstance3D] with a [PrimitiveMesh]. Moving a CSG - * node within another CSG node also has a significant CPU cost, so it should be avoided during - * gameplay. + * **Note:** CSG nodes are intended to be used for level prototyping. Creating CSG nodes has a significant CPU cost compared to creating a [MeshInstance3D] with a [PrimitiveMesh]. Moving a CSG node within another CSG node also has a significant CPU cost, so it should be avoided during gameplay. */ @GodotBaseType public open class CSGSphere3D : CSGPrimitive3D() { @@ -68,8 +61,7 @@ public open class CSGSphere3D : CSGPrimitive3D() { } /** - * If `true` the normals of the sphere are set to give a smooth effect making the sphere seem - * rounded. If `false` the sphere will have a flat shaded look. + * If `true` the normals of the sphere are set to give a smooth effect making the sphere seem rounded. If `false` the sphere will have a flat shaded look. */ public final inline var smoothFaces: Boolean @JvmName("smoothFacesProperty") @@ -90,11 +82,11 @@ public open class CSGSphere3D : CSGPrimitive3D() { setMaterial(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(124, scriptIndex) } - public final fun setRadius(radius: Float): Unit { + public final fun setRadius(radius: Float) { TransferContext.writeArguments(DOUBLE to radius.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setRadiusPtr, NIL) } @@ -105,7 +97,7 @@ public open class CSGSphere3D : CSGPrimitive3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setRadialSegments(radialSegments: Int): Unit { + public final fun setRadialSegments(radialSegments: Int) { TransferContext.writeArguments(LONG to radialSegments.toLong()) TransferContext.callMethod(ptr, MethodBindings.setRadialSegmentsPtr, NIL) } @@ -116,7 +108,7 @@ public open class CSGSphere3D : CSGPrimitive3D() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setRings(rings: Int): Unit { + public final fun setRings(rings: Int) { TransferContext.writeArguments(LONG to rings.toLong()) TransferContext.callMethod(ptr, MethodBindings.setRingsPtr, NIL) } @@ -127,7 +119,7 @@ public open class CSGSphere3D : CSGPrimitive3D() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setSmoothFaces(smoothFaces: Boolean): Unit { + public final fun setSmoothFaces(smoothFaces: Boolean) { TransferContext.writeArguments(BOOL to smoothFaces) TransferContext.callMethod(ptr, MethodBindings.setSmoothFacesPtr, NIL) } @@ -138,7 +130,7 @@ public open class CSGSphere3D : CSGPrimitive3D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setMaterial(material: Material?): Unit { + public final fun setMaterial(material: Material?) { TransferContext.writeArguments(OBJECT to material) TransferContext.callMethod(ptr, MethodBindings.setMaterialPtr, NIL) } @@ -153,33 +145,33 @@ public open class CSGSphere3D : CSGPrimitive3D() { public object MethodBindings { internal val setRadiusPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGSphere3D", "set_radius", 373806689) + TypeManager.getMethodBindPtr("CSGSphere3D", "set_radius", 373_806_689) internal val getRadiusPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGSphere3D", "get_radius", 1740695150) + TypeManager.getMethodBindPtr("CSGSphere3D", "get_radius", 1_740_695_150) internal val setRadialSegmentsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGSphere3D", "set_radial_segments", 1286410249) + TypeManager.getMethodBindPtr("CSGSphere3D", "set_radial_segments", 1_286_410_249) internal val getRadialSegmentsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGSphere3D", "get_radial_segments", 3905245786) + TypeManager.getMethodBindPtr("CSGSphere3D", "get_radial_segments", 3_905_245_786) internal val setRingsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGSphere3D", "set_rings", 1286410249) + TypeManager.getMethodBindPtr("CSGSphere3D", "set_rings", 1_286_410_249) internal val getRingsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGSphere3D", "get_rings", 3905245786) + TypeManager.getMethodBindPtr("CSGSphere3D", "get_rings", 3_905_245_786) internal val setSmoothFacesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGSphere3D", "set_smooth_faces", 2586408642) + TypeManager.getMethodBindPtr("CSGSphere3D", "set_smooth_faces", 2_586_408_642) internal val getSmoothFacesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGSphere3D", "get_smooth_faces", 36873697) + TypeManager.getMethodBindPtr("CSGSphere3D", "get_smooth_faces", 36_873_697) internal val setMaterialPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGSphere3D", "set_material", 2757459619) + TypeManager.getMethodBindPtr("CSGSphere3D", "set_material", 2_757_459_619) internal val getMaterialPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGSphere3D", "get_material", 5934680) + TypeManager.getMethodBindPtr("CSGSphere3D", "get_material", 5_934_680) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGTorus3D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGTorus3D.kt index 1294cc0474..6b427417e7 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGTorus3D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CSGTorus3D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -21,16 +18,12 @@ import kotlin.Float import kotlin.Int import kotlin.Long import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** * This node allows you to create a torus for use with the CSG system. * - * **Note:** CSG nodes are intended to be used for level prototyping. Creating CSG nodes has a - * significant CPU cost compared to creating a [MeshInstance3D] with a [PrimitiveMesh]. Moving a CSG - * node within another CSG node also has a significant CPU cost, so it should be avoided during - * gameplay. + * **Note:** CSG nodes are intended to be used for level prototyping. Creating CSG nodes has a significant CPU cost compared to creating a [MeshInstance3D] with a [PrimitiveMesh]. Moving a CSG node within another CSG node also has a significant CPU cost, so it should be avoided during gameplay. */ @GodotBaseType public open class CSGTorus3D : CSGPrimitive3D() { @@ -79,8 +72,7 @@ public open class CSGTorus3D : CSGPrimitive3D() { } /** - * If `true` the normals of the torus are set to give a smooth effect making the torus seem - * rounded. If `false` the torus will have a flat shaded look. + * If `true` the normals of the torus are set to give a smooth effect making the torus seem rounded. If `false` the torus will have a flat shaded look. */ public final inline var smoothFaces: Boolean @JvmName("smoothFacesProperty") @@ -101,11 +93,11 @@ public open class CSGTorus3D : CSGPrimitive3D() { setMaterial(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(125, scriptIndex) } - public final fun setInnerRadius(radius: Float): Unit { + public final fun setInnerRadius(radius: Float) { TransferContext.writeArguments(DOUBLE to radius.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setInnerRadiusPtr, NIL) } @@ -116,7 +108,7 @@ public open class CSGTorus3D : CSGPrimitive3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setOuterRadius(radius: Float): Unit { + public final fun setOuterRadius(radius: Float) { TransferContext.writeArguments(DOUBLE to radius.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setOuterRadiusPtr, NIL) } @@ -127,7 +119,7 @@ public open class CSGTorus3D : CSGPrimitive3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setSides(sides: Int): Unit { + public final fun setSides(sides: Int) { TransferContext.writeArguments(LONG to sides.toLong()) TransferContext.callMethod(ptr, MethodBindings.setSidesPtr, NIL) } @@ -138,7 +130,7 @@ public open class CSGTorus3D : CSGPrimitive3D() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setRingSides(sides: Int): Unit { + public final fun setRingSides(sides: Int) { TransferContext.writeArguments(LONG to sides.toLong()) TransferContext.callMethod(ptr, MethodBindings.setRingSidesPtr, NIL) } @@ -149,7 +141,7 @@ public open class CSGTorus3D : CSGPrimitive3D() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setMaterial(material: Material?): Unit { + public final fun setMaterial(material: Material?) { TransferContext.writeArguments(OBJECT to material) TransferContext.callMethod(ptr, MethodBindings.setMaterialPtr, NIL) } @@ -160,7 +152,7 @@ public open class CSGTorus3D : CSGPrimitive3D() { return (TransferContext.readReturnValue(OBJECT) as Material?) } - public final fun setSmoothFaces(smoothFaces: Boolean): Unit { + public final fun setSmoothFaces(smoothFaces: Boolean) { TransferContext.writeArguments(BOOL to smoothFaces) TransferContext.callMethod(ptr, MethodBindings.setSmoothFacesPtr, NIL) } @@ -175,39 +167,39 @@ public open class CSGTorus3D : CSGPrimitive3D() { public object MethodBindings { internal val setInnerRadiusPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGTorus3D", "set_inner_radius", 373806689) + TypeManager.getMethodBindPtr("CSGTorus3D", "set_inner_radius", 373_806_689) internal val getInnerRadiusPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGTorus3D", "get_inner_radius", 1740695150) + TypeManager.getMethodBindPtr("CSGTorus3D", "get_inner_radius", 1_740_695_150) internal val setOuterRadiusPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGTorus3D", "set_outer_radius", 373806689) + TypeManager.getMethodBindPtr("CSGTorus3D", "set_outer_radius", 373_806_689) internal val getOuterRadiusPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGTorus3D", "get_outer_radius", 1740695150) + TypeManager.getMethodBindPtr("CSGTorus3D", "get_outer_radius", 1_740_695_150) internal val setSidesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGTorus3D", "set_sides", 1286410249) + TypeManager.getMethodBindPtr("CSGTorus3D", "set_sides", 1_286_410_249) internal val getSidesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGTorus3D", "get_sides", 3905245786) + TypeManager.getMethodBindPtr("CSGTorus3D", "get_sides", 3_905_245_786) internal val setRingSidesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGTorus3D", "set_ring_sides", 1286410249) + TypeManager.getMethodBindPtr("CSGTorus3D", "set_ring_sides", 1_286_410_249) internal val getRingSidesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGTorus3D", "get_ring_sides", 3905245786) + TypeManager.getMethodBindPtr("CSGTorus3D", "get_ring_sides", 3_905_245_786) internal val setMaterialPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGTorus3D", "set_material", 2757459619) + TypeManager.getMethodBindPtr("CSGTorus3D", "set_material", 2_757_459_619) internal val getMaterialPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGTorus3D", "get_material", 5934680) + TypeManager.getMethodBindPtr("CSGTorus3D", "get_material", 5_934_680) internal val setSmoothFacesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGTorus3D", "set_smooth_faces", 2586408642) + TypeManager.getMethodBindPtr("CSGTorus3D", "set_smooth_faces", 2_586_408_642) internal val getSmoothFacesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CSGTorus3D", "get_smooth_faces", 36873697) + TypeManager.getMethodBindPtr("CSGTorus3D", "get_smooth_faces", 36_873_697) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CallbackTweener.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CallbackTweener.kt index 2460d1f1af..650b1ddb41 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CallbackTweener.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CallbackTweener.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -15,20 +12,17 @@ import godot.core.VariantParser.OBJECT import kotlin.Double import kotlin.Int import kotlin.Suppress -import kotlin.Unit /** - * [CallbackTweener] is used to call a method in a tweening sequence. See [Tween.tweenCallback] for - * more usage information. + * [CallbackTweener] is used to call a method in a tweening sequence. See [Tween.tweenCallback] for more usage information. * * The tweener will finish automatically if the callback's target object is freed. * - * **Note:** [Tween.tweenCallback] is the only correct way to create [CallbackTweener]. Any - * [CallbackTweener] created manually will not function correctly. + * **Note:** [Tween.tweenCallback] is the only correct way to create [CallbackTweener]. Any [CallbackTweener] created manually will not function correctly. */ @GodotBaseType public open class CallbackTweener : Tweener() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(126, scriptIndex) } @@ -52,6 +46,6 @@ public open class CallbackTweener : Tweener() { public object MethodBindings { internal val setDelayPtr: VoidPtr = - TypeManager.getMethodBindPtr("CallbackTweener", "set_delay", 3008182292) + TypeManager.getMethodBindPtr("CallbackTweener", "set_delay", 3_008_182_292) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Camera2D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Camera2D.kt index 4e3df26ce7..7745f920e5 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Camera2D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Camera2D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -30,36 +27,22 @@ import kotlin.Unit import kotlin.jvm.JvmName /** - * Camera node for 2D scenes. It forces the screen (current layer) to scroll following this node. - * This makes it easier (and faster) to program scrollable scenes than manually changing the position - * of [CanvasItem]-based nodes. + * Camera node for 2D scenes. It forces the screen (current layer) to scroll following this node. This makes it easier (and faster) to program scrollable scenes than manually changing the position of [CanvasItem]-based nodes. * - * Cameras register themselves in the nearest [Viewport] node (when ascending the tree). Only one - * camera can be active per viewport. If no viewport is available ascending the tree, the camera will - * register in the global viewport. + * Cameras register themselves in the nearest [Viewport] node (when ascending the tree). Only one camera can be active per viewport. If no viewport is available ascending the tree, the camera will register in the global viewport. * - * This node is intended to be a simple helper to get things going quickly, but more functionality - * may be desired to change how the camera works. To make your own custom camera node, inherit it from - * [Node2D] and change the transform of the canvas by setting [Viewport.canvasTransform] in [Viewport] - * (you can obtain the current [Viewport] by using [Node.getViewport]). + * This node is intended to be a simple helper to get things going quickly, but more functionality may be desired to change how the camera works. To make your own custom camera node, inherit it from [Node2D] and change the transform of the canvas by setting [Viewport.canvasTransform] in [Viewport] (you can obtain the current [Viewport] by using [Node.getViewport]). * - * Note that the [Camera2D] node's `position` doesn't represent the actual position of the screen, - * which may differ due to applied smoothing or limits. You can use [getScreenCenterPosition] to get - * the real position. + * Note that the [Camera2D] node's `position` doesn't represent the actual position of the screen, which may differ due to applied smoothing or limits. You can use [getScreenCenterPosition] to get the real position. */ @GodotBaseType public open class Camera2D : Node2D() { /** - * The camera's relative offset. Useful for looking around or camera shake animations. The - * offsetted camera can go past the limits defined in [limitTop], [limitBottom], [limitLeft] and - * [limitRight]. + * The camera's relative offset. Useful for looking around or camera shake animations. The offsetted camera can go past the limits defined in [limitTop], [limitBottom], [limitLeft] and [limitRight]. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var offset: Vector2 @@ -82,8 +65,7 @@ public open class Camera2D : Node2D() { } /** - * If `true`, the camera's rendered view is not affected by its [Node2D.rotation] and - * [Node2D.globalRotation]. + * If `true`, the camera's rendered view is not affected by its [Node2D.rotation] and [Node2D.globalRotation]. */ public final inline var ignoreRotation: Boolean @JvmName("ignoreRotationProperty") @@ -94,12 +76,9 @@ public open class Camera2D : Node2D() { } /** - * Controls whether the camera can be active or not. If `true`, the [Camera2D] will become the - * main camera when it enters the scene tree and there is no active camera currently (see - * [Viewport.getCamera2d]). + * Controls whether the camera can be active or not. If `true`, the [Camera2D] will become the main camera when it enters the scene tree and there is no active camera currently (see [Viewport.getCamera2d]). * - * When the camera is currently active and [enabled] is set to `false`, the next enabled - * [Camera2D] in the scene tree will become active. + * When the camera is currently active and [enabled] is set to `false`, the next enabled [Camera2D] in the scene tree will become active. */ public final inline var enabled: Boolean @JvmName("enabledProperty") @@ -110,24 +89,13 @@ public open class Camera2D : Node2D() { } /** - * The camera's zoom. A zoom of `Vector(2, 2)` doubles the size seen in the viewport. A zoom of - * `Vector(0.5, 0.5)` halves the size seen in the viewport. + * The camera's zoom. A zoom of `Vector(2, 2)` doubles the size seen in the viewport. A zoom of `Vector(0.5, 0.5)` halves the size seen in the viewport. * - * **Note:** [FontFile.oversampling] does *not* take [Camera2D] zoom into account. This means that - * zooming in/out will cause bitmap fonts and rasterized (non-MSDF) dynamic fonts to appear blurry or - * pixelated unless the font is part of a [CanvasLayer] that makes it ignore camera zoom. To ensure - * text remains crisp regardless of zoom, you can enable MSDF font rendering by enabling - * [ProjectSettings.gui/theme/defaultFontMultichannelSignedDistanceField] (applies to the default - * project font only), or enabling **Multichannel Signed Distance Field** in the import options of a - * DynamicFont for custom fonts. On system fonts, [SystemFont.multichannelSignedDistanceField] can be - * enabled in the inspector. + * **Note:** [FontFile.oversampling] does *not* take [Camera2D] zoom into account. This means that zooming in/out will cause bitmap fonts and rasterized (non-MSDF) dynamic fonts to appear blurry or pixelated unless the font is part of a [CanvasLayer] that makes it ignore camera zoom. To ensure text remains crisp regardless of zoom, you can enable MSDF font rendering by enabling [ProjectSettings.gui/theme/defaultFontMultichannelSignedDistanceField] (applies to the default project font only), or enabling **Multichannel Signed Distance Field** in the import options of a DynamicFont for custom fonts. On system fonts, [SystemFont.multichannelSignedDistanceField] can be enabled in the inspector. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var zoom: Vector2 @@ -139,8 +107,7 @@ public open class Camera2D : Node2D() { } /** - * The custom [Viewport] node attached to the [Camera2D]. If `null` or not a [Viewport], uses the - * default viewport instead. + * The custom [Viewport] node attached to the [Camera2D]. If `null` or not a [Viewport], uses the default viewport instead. */ public final inline var customViewport: Node? @JvmName("customViewportProperty") @@ -162,8 +129,7 @@ public open class Camera2D : Node2D() { } /** - * Left scroll limit in pixels. The camera stops moving when reaching this value, but [offset] can - * push the view past the limit. + * Left scroll limit in pixels. The camera stops moving when reaching this value, but [offset] can push the view past the limit. */ public final inline var limitLeft: Int @JvmName("limitLeftProperty") @@ -174,8 +140,7 @@ public open class Camera2D : Node2D() { } /** - * Top scroll limit in pixels. The camera stops moving when reaching this value, but [offset] can - * push the view past the limit. + * Top scroll limit in pixels. The camera stops moving when reaching this value, but [offset] can push the view past the limit. */ public final inline var limitTop: Int @JvmName("limitTopProperty") @@ -186,8 +151,7 @@ public open class Camera2D : Node2D() { } /** - * Right scroll limit in pixels. The camera stops moving when reaching this value, but [offset] - * can push the view past the limit. + * Right scroll limit in pixels. The camera stops moving when reaching this value, but [offset] can push the view past the limit. */ public final inline var limitRight: Int @JvmName("limitRightProperty") @@ -198,8 +162,7 @@ public open class Camera2D : Node2D() { } /** - * Bottom scroll limit in pixels. The camera stops moving when reaching this value, but [offset] - * can push the view past the limit. + * Bottom scroll limit in pixels. The camera stops moving when reaching this value, but [offset] can push the view past the limit. */ public final inline var limitBottom: Int @JvmName("limitBottomProperty") @@ -214,8 +177,7 @@ public open class Camera2D : Node2D() { * * This property has no effect if [positionSmoothingEnabled] is `false`. * - * **Note:** To immediately update the camera's position to be within limits without smoothing, - * even with this setting enabled, invoke [resetSmoothing]. + * **Note:** To immediately update the camera's position to be within limits without smoothing, even with this setting enabled, invoke [resetSmoothing]. */ public final inline var limitSmoothed: Boolean @JvmName("limitSmoothedProperty") @@ -226,8 +188,7 @@ public open class Camera2D : Node2D() { } /** - * If `true`, the camera's view smoothly moves towards its target position at - * [positionSmoothingSpeed]. + * If `true`, the camera's view smoothly moves towards its target position at [positionSmoothingSpeed]. */ public final inline var positionSmoothingEnabled: Boolean @JvmName("positionSmoothingEnabledProperty") @@ -238,8 +199,7 @@ public open class Camera2D : Node2D() { } /** - * Speed in pixels per second of the camera's smoothing effect when [positionSmoothingEnabled] is - * `true`. + * Speed in pixels per second of the camera's smoothing effect when [positionSmoothingEnabled] is `true`. */ public final inline var positionSmoothingSpeed: Float @JvmName("positionSmoothingSpeedProperty") @@ -250,8 +210,7 @@ public open class Camera2D : Node2D() { } /** - * If `true`, the camera's view smoothly rotates, via asymptotic smoothing, to align with its - * target rotation at [rotationSmoothingSpeed]. + * If `true`, the camera's view smoothly rotates, via asymptotic smoothing, to align with its target rotation at [rotationSmoothingSpeed]. * * **Note:** This property has no effect if [ignoreRotation] is `true`. */ @@ -264,8 +223,7 @@ public open class Camera2D : Node2D() { } /** - * The angular, asymptotic speed of the camera's rotation smoothing effect when - * [rotationSmoothingEnabled] is `true`. + * The angular, asymptotic speed of the camera's rotation smoothing effect when [rotationSmoothingEnabled] is `true`. */ public final inline var rotationSmoothingSpeed: Float @JvmName("rotationSmoothingSpeedProperty") @@ -276,8 +234,7 @@ public open class Camera2D : Node2D() { } /** - * If `true`, the camera only moves when reaching the horizontal (left and right) drag margins. If - * `false`, the camera moves horizontally regardless of margins. + * If `true`, the camera only moves when reaching the horizontal (left and right) drag margins. If `false`, the camera moves horizontally regardless of margins. */ public final inline var dragHorizontalEnabled: Boolean @JvmName("dragHorizontalEnabledProperty") @@ -288,8 +245,7 @@ public open class Camera2D : Node2D() { } /** - * If `true`, the camera only moves when reaching the vertical (top and bottom) drag margins. If - * `false`, the camera moves vertically regardless of the drag margins. + * If `true`, the camera only moves when reaching the vertical (top and bottom) drag margins. If `false`, the camera moves vertically regardless of the drag margins. */ public final inline var dragVerticalEnabled: Boolean @JvmName("dragVerticalEnabledProperty") @@ -300,12 +256,9 @@ public open class Camera2D : Node2D() { } /** - * The relative horizontal drag offset of the camera between the right (`-1`) and left (`1`) drag - * margins. + * The relative horizontal drag offset of the camera between the right (`-1`) and left (`1`) drag margins. * - * **Note:** Used to set the initial horizontal drag offset; determine the current offset; or - * force the current offset. It's not automatically updated when [dragHorizontalEnabled] is `true` or - * the drag margins are changed. + * **Note:** Used to set the initial horizontal drag offset; determine the current offset; or force the current offset. It's not automatically updated when [dragHorizontalEnabled] is `true` or the drag margins are changed. */ public final inline var dragHorizontalOffset: Float @JvmName("dragHorizontalOffsetProperty") @@ -316,12 +269,9 @@ public open class Camera2D : Node2D() { } /** - * The relative vertical drag offset of the camera between the bottom (`-1`) and top (`1`) drag - * margins. + * The relative vertical drag offset of the camera between the bottom (`-1`) and top (`1`) drag margins. * - * **Note:** Used to set the initial vertical drag offset; determine the current offset; or force - * the current offset. It's not automatically updated when [dragVerticalEnabled] is `true` or the - * drag margins are changed. + * **Note:** Used to set the initial vertical drag offset; determine the current offset; or force the current offset. It's not automatically updated when [dragVerticalEnabled] is `true` or the drag margins are changed. */ public final inline var dragVerticalOffset: Float @JvmName("dragVerticalOffsetProperty") @@ -332,8 +282,7 @@ public open class Camera2D : Node2D() { } /** - * Left margin needed to drag the camera. A value of `1` makes the camera move only when reaching - * the left edge of the screen. + * Left margin needed to drag the camera. A value of `1` makes the camera move only when reaching the left edge of the screen. */ public final inline var dragLeftMargin: Float @JvmName("dragLeftMarginProperty") @@ -344,8 +293,7 @@ public open class Camera2D : Node2D() { } /** - * Top margin needed to drag the camera. A value of `1` makes the camera move only when reaching - * the top edge of the screen. + * Top margin needed to drag the camera. A value of `1` makes the camera move only when reaching the top edge of the screen. */ public final inline var dragTopMargin: Float @JvmName("dragTopMarginProperty") @@ -356,8 +304,7 @@ public open class Camera2D : Node2D() { } /** - * Right margin needed to drag the camera. A value of `1` makes the camera move only when reaching - * the right edge of the screen. + * Right margin needed to drag the camera. A value of `1` makes the camera move only when reaching the right edge of the screen. */ public final inline var dragRightMargin: Float @JvmName("dragRightMarginProperty") @@ -368,8 +315,7 @@ public open class Camera2D : Node2D() { } /** - * Bottom margin needed to drag the camera. A value of `1` makes the camera move only when - * reaching the bottom edge of the screen. + * Bottom margin needed to drag the camera. A value of `1` makes the camera move only when reaching the bottom edge of the screen. */ public final inline var dragBottomMargin: Float @JvmName("dragBottomMarginProperty") @@ -412,7 +358,7 @@ public open class Camera2D : Node2D() { setMarginDrawingEnabled(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(127, scriptIndex) } @@ -427,9 +373,7 @@ public open class Camera2D : Node2D() { * camera2d.offset = myCoreType * `````` * - * The camera's relative offset. Useful for looking around or camera shake animations. The - * offsetted camera can go past the limits defined in [limitTop], [limitBottom], [limitLeft] and - * [limitRight]. + * The camera's relative offset. Useful for looking around or camera shake animations. The offsetted camera can go past the limits defined in [limitTop], [limitBottom], [limitLeft] and [limitRight]. */ @CoreTypeHelper public final fun offsetMutate(block: Vector2.() -> Unit): Vector2 = offset.apply { @@ -448,17 +392,9 @@ public open class Camera2D : Node2D() { * camera2d.zoom = myCoreType * `````` * - * The camera's zoom. A zoom of `Vector(2, 2)` doubles the size seen in the viewport. A zoom of - * `Vector(0.5, 0.5)` halves the size seen in the viewport. + * The camera's zoom. A zoom of `Vector(2, 2)` doubles the size seen in the viewport. A zoom of `Vector(0.5, 0.5)` halves the size seen in the viewport. * - * **Note:** [FontFile.oversampling] does *not* take [Camera2D] zoom into account. This means that - * zooming in/out will cause bitmap fonts and rasterized (non-MSDF) dynamic fonts to appear blurry or - * pixelated unless the font is part of a [CanvasLayer] that makes it ignore camera zoom. To ensure - * text remains crisp regardless of zoom, you can enable MSDF font rendering by enabling - * [ProjectSettings.gui/theme/defaultFontMultichannelSignedDistanceField] (applies to the default - * project font only), or enabling **Multichannel Signed Distance Field** in the import options of a - * DynamicFont for custom fonts. On system fonts, [SystemFont.multichannelSignedDistanceField] can be - * enabled in the inspector. + * **Note:** [FontFile.oversampling] does *not* take [Camera2D] zoom into account. This means that zooming in/out will cause bitmap fonts and rasterized (non-MSDF) dynamic fonts to appear blurry or pixelated unless the font is part of a [CanvasLayer] that makes it ignore camera zoom. To ensure text remains crisp regardless of zoom, you can enable MSDF font rendering by enabling [ProjectSettings.gui/theme/defaultFontMultichannelSignedDistanceField] (applies to the default project font only), or enabling **Multichannel Signed Distance Field** in the import options of a DynamicFont for custom fonts. On system fonts, [SystemFont.multichannelSignedDistanceField] can be enabled in the inspector. */ @CoreTypeHelper public final fun zoomMutate(block: Vector2.() -> Unit): Vector2 = zoom.apply { @@ -466,7 +402,7 @@ public open class Camera2D : Node2D() { zoom = this } - public final fun setOffset(offset: Vector2): Unit { + public final fun setOffset(offset: Vector2) { TransferContext.writeArguments(VECTOR2 to offset) TransferContext.callMethod(ptr, MethodBindings.setOffsetPtr, NIL) } @@ -477,7 +413,7 @@ public open class Camera2D : Node2D() { return (TransferContext.readReturnValue(VECTOR2) as Vector2) } - public final fun setAnchorMode(anchorMode: AnchorMode): Unit { + public final fun setAnchorMode(anchorMode: AnchorMode) { TransferContext.writeArguments(LONG to anchorMode.id) TransferContext.callMethod(ptr, MethodBindings.setAnchorModePtr, NIL) } @@ -488,7 +424,7 @@ public open class Camera2D : Node2D() { return AnchorMode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setIgnoreRotation(ignore: Boolean): Unit { + public final fun setIgnoreRotation(ignore: Boolean) { TransferContext.writeArguments(BOOL to ignore) TransferContext.callMethod(ptr, MethodBindings.setIgnoreRotationPtr, NIL) } @@ -499,7 +435,7 @@ public open class Camera2D : Node2D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setProcessCallback(mode: Camera2DProcessCallback): Unit { + public final fun setProcessCallback(mode: Camera2DProcessCallback) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setProcessCallbackPtr, NIL) } @@ -510,7 +446,7 @@ public open class Camera2D : Node2D() { return Camera2DProcessCallback.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setEnabled(enabled: Boolean): Unit { + public final fun setEnabled(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setEnabledPtr, NIL) } @@ -524,7 +460,7 @@ public open class Camera2D : Node2D() { /** * Forces this [Camera2D] to become the current active one. [enabled] must be `true`. */ - public final fun makeCurrent(): Unit { + public final fun makeCurrent() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.makeCurrentPtr, NIL) } @@ -539,17 +475,15 @@ public open class Camera2D : Node2D() { } /** - * Sets the camera limit for the specified [Side]. See also [limitBottom], [limitTop], - * [limitLeft], and [limitRight]. + * Sets the camera limit for the specified [Side]. See also [limitBottom], [limitTop], [limitLeft], and [limitRight]. */ - public final fun setLimit(margin: Side, limit: Int): Unit { + public final fun setLimit(margin: Side, limit: Int) { TransferContext.writeArguments(LONG to margin.id, LONG to limit.toLong()) TransferContext.callMethod(ptr, MethodBindings.setLimitPtr, NIL) } /** - * Returns the camera limit for the specified [Side]. See also [limitBottom], [limitTop], - * [limitLeft], and [limitRight]. + * Returns the camera limit for the specified [Side]. See also [limitBottom], [limitTop], [limitLeft], and [limitRight]. */ public final fun getLimit(margin: Side): Int { TransferContext.writeArguments(LONG to margin.id) @@ -557,7 +491,7 @@ public open class Camera2D : Node2D() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setLimitSmoothingEnabled(limitSmoothingEnabled: Boolean): Unit { + public final fun setLimitSmoothingEnabled(limitSmoothingEnabled: Boolean) { TransferContext.writeArguments(BOOL to limitSmoothingEnabled) TransferContext.callMethod(ptr, MethodBindings.setLimitSmoothingEnabledPtr, NIL) } @@ -568,7 +502,7 @@ public open class Camera2D : Node2D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setDragVerticalEnabled(enabled: Boolean): Unit { + public final fun setDragVerticalEnabled(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setDragVerticalEnabledPtr, NIL) } @@ -579,7 +513,7 @@ public open class Camera2D : Node2D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setDragHorizontalEnabled(enabled: Boolean): Unit { + public final fun setDragHorizontalEnabled(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setDragHorizontalEnabledPtr, NIL) } @@ -590,7 +524,7 @@ public open class Camera2D : Node2D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setDragVerticalOffset(offset: Float): Unit { + public final fun setDragVerticalOffset(offset: Float) { TransferContext.writeArguments(DOUBLE to offset.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setDragVerticalOffsetPtr, NIL) } @@ -601,7 +535,7 @@ public open class Camera2D : Node2D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setDragHorizontalOffset(offset: Float): Unit { + public final fun setDragHorizontalOffset(offset: Float) { TransferContext.writeArguments(DOUBLE to offset.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setDragHorizontalOffsetPtr, NIL) } @@ -613,17 +547,15 @@ public open class Camera2D : Node2D() { } /** - * Sets the specified [Side]'s margin. See also [dragBottomMargin], [dragTopMargin], - * [dragLeftMargin], and [dragRightMargin]. + * Sets the specified [Side]'s margin. See also [dragBottomMargin], [dragTopMargin], [dragLeftMargin], and [dragRightMargin]. */ - public final fun setDragMargin(margin: Side, dragMargin: Float): Unit { + public final fun setDragMargin(margin: Side, dragMargin: Float) { TransferContext.writeArguments(LONG to margin.id, DOUBLE to dragMargin.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setDragMarginPtr, NIL) } /** - * Returns the specified [Side]'s margin. See also [dragBottomMargin], [dragTopMargin], - * [dragLeftMargin], and [dragRightMargin]. + * Returns the specified [Side]'s margin. See also [dragBottomMargin], [dragTopMargin], [dragLeftMargin], and [dragRightMargin]. */ public final fun getDragMargin(margin: Side): Float { TransferContext.writeArguments(LONG to margin.id) @@ -634,9 +566,7 @@ public open class Camera2D : Node2D() { /** * Returns this camera's target position, in global coordinates. * - * **Note:** The returned value is not the same as [Node2D.globalPosition], as it is affected by - * the drag properties. It is also not the same as the current position if [positionSmoothingEnabled] - * is `true` (see [getScreenCenterPosition]). + * **Note:** The returned value is not the same as [Node2D.globalPosition], as it is affected by the drag properties. It is also not the same as the current position if [positionSmoothingEnabled] is `true` (see [getScreenCenterPosition]). */ public final fun getTargetPosition(): Vector2 { TransferContext.writeArguments() @@ -655,7 +585,7 @@ public open class Camera2D : Node2D() { return (TransferContext.readReturnValue(VECTOR2) as Vector2) } - public final fun setZoom(zoom: Vector2): Unit { + public final fun setZoom(zoom: Vector2) { TransferContext.writeArguments(VECTOR2 to zoom) TransferContext.callMethod(ptr, MethodBindings.setZoomPtr, NIL) } @@ -666,7 +596,7 @@ public open class Camera2D : Node2D() { return (TransferContext.readReturnValue(VECTOR2) as Vector2) } - public final fun setCustomViewport(viewport: Node?): Unit { + public final fun setCustomViewport(viewport: Node?) { TransferContext.writeArguments(OBJECT to viewport) TransferContext.callMethod(ptr, MethodBindings.setCustomViewportPtr, NIL) } @@ -677,7 +607,7 @@ public open class Camera2D : Node2D() { return (TransferContext.readReturnValue(OBJECT) as Node?) } - public final fun setPositionSmoothingSpeed(positionSmoothingSpeed: Float): Unit { + public final fun setPositionSmoothingSpeed(positionSmoothingSpeed: Float) { TransferContext.writeArguments(DOUBLE to positionSmoothingSpeed.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setPositionSmoothingSpeedPtr, NIL) } @@ -688,7 +618,7 @@ public open class Camera2D : Node2D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setPositionSmoothingEnabled(positionSmoothingSpeed: Boolean): Unit { + public final fun setPositionSmoothingEnabled(positionSmoothingSpeed: Boolean) { TransferContext.writeArguments(BOOL to positionSmoothingSpeed) TransferContext.callMethod(ptr, MethodBindings.setPositionSmoothingEnabledPtr, NIL) } @@ -699,7 +629,7 @@ public open class Camera2D : Node2D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setRotationSmoothingEnabled(enabled: Boolean): Unit { + public final fun setRotationSmoothingEnabled(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setRotationSmoothingEnabledPtr, NIL) } @@ -710,7 +640,7 @@ public open class Camera2D : Node2D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setRotationSmoothingSpeed(speed: Float): Unit { + public final fun setRotationSmoothingSpeed(speed: Float) { TransferContext.writeArguments(DOUBLE to speed.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setRotationSmoothingSpeedPtr, NIL) } @@ -724,7 +654,7 @@ public open class Camera2D : Node2D() { /** * Forces the camera to update scroll immediately. */ - public final fun forceUpdateScroll(): Unit { + public final fun forceUpdateScroll() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.forceUpdateScrollPtr, NIL) } @@ -734,7 +664,7 @@ public open class Camera2D : Node2D() { * * This method has no effect if [positionSmoothingEnabled] is `false`. */ - public final fun resetSmoothing(): Unit { + public final fun resetSmoothing() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.resetSmoothingPtr, NIL) } @@ -742,12 +672,12 @@ public open class Camera2D : Node2D() { /** * Aligns the camera to the tracked node. */ - public final fun align(): Unit { + public final fun align() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.alignPtr, NIL) } - public final fun setScreenDrawingEnabled(screenDrawingEnabled: Boolean): Unit { + public final fun setScreenDrawingEnabled(screenDrawingEnabled: Boolean) { TransferContext.writeArguments(BOOL to screenDrawingEnabled) TransferContext.callMethod(ptr, MethodBindings.setScreenDrawingEnabledPtr, NIL) } @@ -758,7 +688,7 @@ public open class Camera2D : Node2D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setLimitDrawingEnabled(limitDrawingEnabled: Boolean): Unit { + public final fun setLimitDrawingEnabled(limitDrawingEnabled: Boolean) { TransferContext.writeArguments(BOOL to limitDrawingEnabled) TransferContext.callMethod(ptr, MethodBindings.setLimitDrawingEnabledPtr, NIL) } @@ -769,7 +699,7 @@ public open class Camera2D : Node2D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setMarginDrawingEnabled(marginDrawingEnabled: Boolean): Unit { + public final fun setMarginDrawingEnabled(marginDrawingEnabled: Boolean) { TransferContext.writeArguments(BOOL to marginDrawingEnabled) TransferContext.callMethod(ptr, MethodBindings.setMarginDrawingEnabledPtr, NIL) } @@ -830,149 +760,150 @@ public open class Camera2D : Node2D() { public object MethodBindings { internal val setOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "set_offset", 743155724) + TypeManager.getMethodBindPtr("Camera2D", "set_offset", 743_155_724) internal val getOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "get_offset", 3341600327) + TypeManager.getMethodBindPtr("Camera2D", "get_offset", 3_341_600_327) internal val setAnchorModePtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "set_anchor_mode", 2050398218) + TypeManager.getMethodBindPtr("Camera2D", "set_anchor_mode", 2_050_398_218) internal val getAnchorModePtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "get_anchor_mode", 155978067) + TypeManager.getMethodBindPtr("Camera2D", "get_anchor_mode", 155_978_067) internal val setIgnoreRotationPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "set_ignore_rotation", 2586408642) + TypeManager.getMethodBindPtr("Camera2D", "set_ignore_rotation", 2_586_408_642) internal val isIgnoringRotationPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "is_ignoring_rotation", 36873697) + TypeManager.getMethodBindPtr("Camera2D", "is_ignoring_rotation", 36_873_697) internal val setProcessCallbackPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "set_process_callback", 4201947462) + TypeManager.getMethodBindPtr("Camera2D", "set_process_callback", 4_201_947_462) internal val getProcessCallbackPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "get_process_callback", 2325344499) + TypeManager.getMethodBindPtr("Camera2D", "get_process_callback", 2_325_344_499) internal val setEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "set_enabled", 2586408642) + TypeManager.getMethodBindPtr("Camera2D", "set_enabled", 2_586_408_642) internal val isEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "is_enabled", 36873697) + TypeManager.getMethodBindPtr("Camera2D", "is_enabled", 36_873_697) internal val makeCurrentPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "make_current", 3218959716) + TypeManager.getMethodBindPtr("Camera2D", "make_current", 3_218_959_716) internal val isCurrentPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "is_current", 36873697) + TypeManager.getMethodBindPtr("Camera2D", "is_current", 36_873_697) internal val setLimitPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "set_limit", 437707142) + TypeManager.getMethodBindPtr("Camera2D", "set_limit", 437_707_142) internal val getLimitPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "get_limit", 1983885014) + TypeManager.getMethodBindPtr("Camera2D", "get_limit", 1_983_885_014) internal val setLimitSmoothingEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "set_limit_smoothing_enabled", 2586408642) + TypeManager.getMethodBindPtr("Camera2D", "set_limit_smoothing_enabled", 2_586_408_642) internal val isLimitSmoothingEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "is_limit_smoothing_enabled", 36873697) + TypeManager.getMethodBindPtr("Camera2D", "is_limit_smoothing_enabled", 36_873_697) internal val setDragVerticalEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "set_drag_vertical_enabled", 2586408642) + TypeManager.getMethodBindPtr("Camera2D", "set_drag_vertical_enabled", 2_586_408_642) internal val isDragVerticalEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "is_drag_vertical_enabled", 36873697) + TypeManager.getMethodBindPtr("Camera2D", "is_drag_vertical_enabled", 36_873_697) internal val setDragHorizontalEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "set_drag_horizontal_enabled", 2586408642) + TypeManager.getMethodBindPtr("Camera2D", "set_drag_horizontal_enabled", 2_586_408_642) internal val isDragHorizontalEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "is_drag_horizontal_enabled", 36873697) + TypeManager.getMethodBindPtr("Camera2D", "is_drag_horizontal_enabled", 36_873_697) internal val setDragVerticalOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "set_drag_vertical_offset", 373806689) + TypeManager.getMethodBindPtr("Camera2D", "set_drag_vertical_offset", 373_806_689) internal val getDragVerticalOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "get_drag_vertical_offset", 1740695150) + TypeManager.getMethodBindPtr("Camera2D", "get_drag_vertical_offset", 1_740_695_150) internal val setDragHorizontalOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "set_drag_horizontal_offset", 373806689) + TypeManager.getMethodBindPtr("Camera2D", "set_drag_horizontal_offset", 373_806_689) internal val getDragHorizontalOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "get_drag_horizontal_offset", 1740695150) + TypeManager.getMethodBindPtr("Camera2D", "get_drag_horizontal_offset", 1_740_695_150) internal val setDragMarginPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "set_drag_margin", 4290182280) + TypeManager.getMethodBindPtr("Camera2D", "set_drag_margin", 4_290_182_280) internal val getDragMarginPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "get_drag_margin", 2869120046) + TypeManager.getMethodBindPtr("Camera2D", "get_drag_margin", 2_869_120_046) internal val getTargetPositionPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "get_target_position", 3341600327) + TypeManager.getMethodBindPtr("Camera2D", "get_target_position", 3_341_600_327) internal val getScreenCenterPositionPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "get_screen_center_position", 3341600327) + TypeManager.getMethodBindPtr("Camera2D", "get_screen_center_position", 3_341_600_327) internal val setZoomPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "set_zoom", 743155724) + TypeManager.getMethodBindPtr("Camera2D", "set_zoom", 743_155_724) internal val getZoomPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "get_zoom", 3341600327) + TypeManager.getMethodBindPtr("Camera2D", "get_zoom", 3_341_600_327) internal val setCustomViewportPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "set_custom_viewport", 1078189570) + TypeManager.getMethodBindPtr("Camera2D", "set_custom_viewport", 1_078_189_570) internal val getCustomViewportPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "get_custom_viewport", 3160264692) + TypeManager.getMethodBindPtr("Camera2D", "get_custom_viewport", 3_160_264_692) internal val setPositionSmoothingSpeedPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "set_position_smoothing_speed", 373806689) + TypeManager.getMethodBindPtr("Camera2D", "set_position_smoothing_speed", 373_806_689) internal val getPositionSmoothingSpeedPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "get_position_smoothing_speed", 1740695150) + TypeManager.getMethodBindPtr("Camera2D", "get_position_smoothing_speed", 1_740_695_150) internal val setPositionSmoothingEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "set_position_smoothing_enabled", 2586408642) + TypeManager.getMethodBindPtr("Camera2D", "set_position_smoothing_enabled", 2_586_408_642) internal val isPositionSmoothingEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "is_position_smoothing_enabled", 36873697) + TypeManager.getMethodBindPtr("Camera2D", "is_position_smoothing_enabled", 36_873_697) internal val setRotationSmoothingEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "set_rotation_smoothing_enabled", 2586408642) + TypeManager.getMethodBindPtr("Camera2D", "set_rotation_smoothing_enabled", 2_586_408_642) internal val isRotationSmoothingEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "is_rotation_smoothing_enabled", 36873697) + TypeManager.getMethodBindPtr("Camera2D", "is_rotation_smoothing_enabled", 36_873_697) internal val setRotationSmoothingSpeedPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "set_rotation_smoothing_speed", 373806689) + TypeManager.getMethodBindPtr("Camera2D", "set_rotation_smoothing_speed", 373_806_689) internal val getRotationSmoothingSpeedPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "get_rotation_smoothing_speed", 1740695150) + TypeManager.getMethodBindPtr("Camera2D", "get_rotation_smoothing_speed", 1_740_695_150) internal val forceUpdateScrollPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "force_update_scroll", 3218959716) + TypeManager.getMethodBindPtr("Camera2D", "force_update_scroll", 3_218_959_716) internal val resetSmoothingPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "reset_smoothing", 3218959716) + TypeManager.getMethodBindPtr("Camera2D", "reset_smoothing", 3_218_959_716) - internal val alignPtr: VoidPtr = TypeManager.getMethodBindPtr("Camera2D", "align", 3218959716) + internal val alignPtr: VoidPtr = + TypeManager.getMethodBindPtr("Camera2D", "align", 3_218_959_716) internal val setScreenDrawingEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "set_screen_drawing_enabled", 2586408642) + TypeManager.getMethodBindPtr("Camera2D", "set_screen_drawing_enabled", 2_586_408_642) internal val isScreenDrawingEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "is_screen_drawing_enabled", 36873697) + TypeManager.getMethodBindPtr("Camera2D", "is_screen_drawing_enabled", 36_873_697) internal val setLimitDrawingEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "set_limit_drawing_enabled", 2586408642) + TypeManager.getMethodBindPtr("Camera2D", "set_limit_drawing_enabled", 2_586_408_642) internal val isLimitDrawingEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "is_limit_drawing_enabled", 36873697) + TypeManager.getMethodBindPtr("Camera2D", "is_limit_drawing_enabled", 36_873_697) internal val setMarginDrawingEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "set_margin_drawing_enabled", 2586408642) + TypeManager.getMethodBindPtr("Camera2D", "set_margin_drawing_enabled", 2_586_408_642) internal val isMarginDrawingEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera2D", "is_margin_drawing_enabled", 36873697) + TypeManager.getMethodBindPtr("Camera2D", "is_margin_drawing_enabled", 36_873_697) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Camera3D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Camera3D.kt index ef20a62639..36a29a659c 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Camera3D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Camera3D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -41,11 +38,7 @@ import kotlin.jvm.JvmName import kotlin.jvm.JvmOverloads /** - * [Camera3D] is a special node that displays what is visible from its current location. Cameras - * register themselves in the nearest [Viewport] node (when ascending the tree). Only one camera can be - * active per viewport. If no viewport is available ascending the tree, the camera will register in the - * global viewport. In other words, a camera just provides 3D display capabilities to a [Viewport], - * and, without one, a scene registered in that [Viewport] (or higher viewports) can't be displayed. + * [Camera3D] is a special node that displays what is visible from its current location. Cameras register themselves in the nearest [Viewport] node (when ascending the tree). Only one camera can be active per viewport. If no viewport is available ascending the tree, the camera will register in the global viewport. In other words, a camera just provides 3D display capabilities to a [Viewport], and, without one, a scene registered in that [Viewport] (or higher viewports) can't be displayed. */ @GodotBaseType public open class Camera3D : Node3D() { @@ -61,21 +54,13 @@ public open class Camera3D : Node3D() { } /** - * The culling mask that describes which [VisualInstance3D.layers] are rendered by this camera. By - * default, all 20 user-visible layers are rendered. + * The culling mask that describes which [VisualInstance3D.layers] are rendered by this camera. By default, all 20 user-visible layers are rendered. * - * **Note:** Since the [cullMask] allows for 32 layers to be stored in total, there are an - * additional 12 layers that are only used internally by the engine and aren't exposed in the editor. - * Setting [cullMask] using a script allows you to toggle those reserved layers, which can be useful - * for editor plugins. + * **Note:** Since the [cullMask] allows for 32 layers to be stored in total, there are an additional 12 layers that are only used internally by the engine and aren't exposed in the editor. Setting [cullMask] using a script allows you to toggle those reserved layers, which can be useful for editor plugins. * * To adjust [cullMask] more easily using a script, use [getCullMaskValue] and [setCullMaskValue]. * - * **Note:** [VoxelGI], SDFGI and [LightmapGI] will always take all layers into account to - * determine what contributes to global illumination. If this is an issue, set - * [GeometryInstance3D.giMode] to [GeometryInstance3D.GI_MODE_DISABLED] for meshes and - * [Light3D.lightBakeMode] to [Light3D.BAKE_DISABLED] for lights to exclude them from global - * illumination. + * **Note:** [VoxelGI], SDFGI and [LightmapGI] will always take all layers into account to determine what contributes to global illumination. If this is an issue, set [GeometryInstance3D.giMode] to [GeometryInstance3D.GI_MODE_DISABLED] for meshes and [Light3D.lightBakeMode] to [Light3D.BAKE_DISABLED] for lights to exclude them from global illumination. */ public final inline var cullMask: Long @JvmName("cullMaskProperty") @@ -141,9 +126,7 @@ public open class Camera3D : Node3D() { } /** - * If not [DOPPLER_TRACKING_DISABLED], this camera will simulate the - * [url=https://en.wikipedia.org/wiki/Doppler_effect]Doppler effect[/url] for objects changed in - * particular `_process` methods. See [DopplerTracking] for possible values. + * If not [DOPPLER_TRACKING_DISABLED], this camera will simulate the [url=https://en.wikipedia.org/wiki/Doppler_effect]Doppler effect[/url] for objects changed in particular `_process` methods. See [DopplerTracking] for possible values. */ public final inline var dopplerTracking: DopplerTracking @JvmName("dopplerTrackingProperty") @@ -154,8 +137,7 @@ public open class Camera3D : Node3D() { } /** - * The camera's projection mode. In [PROJECTION_PERSPECTIVE] mode, objects' Z distance from the - * camera's local space scales their perceived size. + * The camera's projection mode. In [PROJECTION_PERSPECTIVE] mode, objects' Z distance from the camera's local space scales their perceived size. */ public final inline var projection: ProjectionType @JvmName("projectionProperty") @@ -168,9 +150,7 @@ public open class Camera3D : Node3D() { /** * If `true`, the ancestor [Viewport] is currently using this camera. * - * If multiple cameras are in the scene, one will always be made current. For example, if two - * [Camera3D] nodes are present in the scene and only one is current, setting one camera's [current] - * to `false` will cause the other camera to be made current. + * If multiple cameras are in the scene, one will always be made current. For example, if two [Camera3D] nodes are present in the scene and only one is current, setting one camera's [current] to `false` will cause the other camera to be made current. */ public final inline var current: Boolean @JvmName("currentProperty") @@ -181,11 +161,9 @@ public open class Camera3D : Node3D() { } /** - * The camera's field of view angle (in degrees). Only applicable in perspective mode. Since - * [keepAspect] locks one axis, [fov] sets the other axis' field of view angle. + * The camera's field of view angle (in degrees). Only applicable in perspective mode. Since [keepAspect] locks one axis, [fov] sets the other axis' field of view angle. * - * For reference, the default vertical field of view value (`75.0`) is equivalent to a horizontal - * FOV of: + * For reference, the default vertical field of view value (`75.0`) is equivalent to a horizontal FOV of: * * - ~91.31 degrees in a 4:3 viewport * @@ -204,8 +182,7 @@ public open class Camera3D : Node3D() { } /** - * The camera's size in meters measured as the diameter of the width or height, depending on - * [keepAspect]. Only applicable in orthogonal and frustum modes. + * The camera's size in meters measured as the diameter of the width or height, depending on [keepAspect]. Only applicable in orthogonal and frustum modes. */ public final inline var size: Float @JvmName("sizeProperty") @@ -216,17 +193,13 @@ public open class Camera3D : Node3D() { } /** - * The camera's frustum offset. This can be changed from the default to create "tilted frustum" - * effects such as [url=https://zdoom.org/wiki/Y-shearing]Y-shearing[/url]. + * The camera's frustum offset. This can be changed from the default to create "tilted frustum" effects such as [url=https://zdoom.org/wiki/Y-shearing]Y-shearing[/url]. * * **Note:** Only effective if [projection] is [PROJECTION_FRUSTUM]. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var frustumOffset: Vector2 @@ -238,9 +211,7 @@ public open class Camera3D : Node3D() { } /** - * The distance to the near culling boundary for this camera relative to its local Z axis. Lower - * values allow the camera to see objects more up close to its origin, at the cost of lower precision - * across the *entire* range. Values lower than the default can lead to increased Z-fighting. + * The distance to the near culling boundary for this camera relative to its local Z axis. Lower values allow the camera to see objects more up close to its origin, at the cost of lower precision across the *entire* range. Values lower than the default can lead to increased Z-fighting. */ public final inline var near: Float @JvmName("nearProperty") @@ -251,9 +222,7 @@ public open class Camera3D : Node3D() { } /** - * The distance to the far culling boundary for this camera relative to its local Z axis. Higher - * values allow the camera to see further away, while decreasing [far] can improve performance if it - * results in objects being partially or fully culled. + * The distance to the far culling boundary for this camera relative to its local Z axis. Higher values allow the camera to see further away, while decreasing [far] can improve performance if it results in objects being partially or fully culled. */ public final inline var far: Float @JvmName("farProperty") @@ -263,7 +232,7 @@ public open class Camera3D : Node3D() { setFar(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(128, scriptIndex) } @@ -278,8 +247,7 @@ public open class Camera3D : Node3D() { * camera3d.frustumOffset = myCoreType * `````` * - * The camera's frustum offset. This can be changed from the default to create "tilted frustum" - * effects such as [url=https://zdoom.org/wiki/Y-shearing]Y-shearing[/url]. + * The camera's frustum offset. This can be changed from the default to create "tilted frustum" effects such as [url=https://zdoom.org/wiki/Y-shearing]Y-shearing[/url]. * * **Note:** Only effective if [projection] is [PROJECTION_FRUSTUM]. */ @@ -290,9 +258,7 @@ public open class Camera3D : Node3D() { } /** - * Returns a normal vector in world space, that is the result of projecting a point on the - * [Viewport] rectangle by the inverse camera projection. This is useful for casting rays in the form - * of (origin, normal) for object intersection or picking. + * Returns a normal vector in world space, that is the result of projecting a point on the [Viewport] rectangle by the inverse camera projection. This is useful for casting rays in the form of (origin, normal) for object intersection or picking. */ public final fun projectRayNormal(screenPoint: Vector2): Vector3 { TransferContext.writeArguments(VECTOR2 to screenPoint) @@ -301,8 +267,7 @@ public open class Camera3D : Node3D() { } /** - * Returns a normal vector from the screen point location directed along the camera. Orthogonal - * cameras are normalized. Perspective cameras account for perspective, screen width/height, etc. + * Returns a normal vector from the screen point location directed along the camera. Orthogonal cameras are normalized. Perspective cameras account for perspective, screen width/height, etc. */ public final fun projectLocalRayNormal(screenPoint: Vector2): Vector3 { TransferContext.writeArguments(VECTOR2 to screenPoint) @@ -311,9 +276,7 @@ public open class Camera3D : Node3D() { } /** - * Returns a 3D position in world space, that is the result of projecting a point on the - * [Viewport] rectangle by the inverse camera projection. This is useful for casting rays in the form - * of (origin, normal) for object intersection or picking. + * Returns a 3D position in world space, that is the result of projecting a point on the [Viewport] rectangle by the inverse camera projection. This is useful for casting rays in the form of (origin, normal) for object intersection or picking. */ public final fun projectRayOrigin(screenPoint: Vector2): Vector3 { TransferContext.writeArguments(VECTOR2 to screenPoint) @@ -322,17 +285,14 @@ public open class Camera3D : Node3D() { } /** - * Returns the 2D coordinate in the [Viewport] rectangle that maps to the given 3D point in world - * space. + * Returns the 2D coordinate in the [Viewport] rectangle that maps to the given 3D point in world space. * - * **Note:** When using this to position GUI elements over a 3D viewport, use [isPositionBehind] - * to prevent them from appearing if the 3D point is behind the camera: + * **Note:** When using this to position GUI elements over a 3D viewport, use [isPositionBehind] to prevent them from appearing if the 3D point is behind the camera: * * ``` * # This code block is part of a script that inherits from Node3D. * # `control` is a reference to a node inheriting from Control. - * control.visible = not - * get_viewport().get_camera_3d().is_position_behind(global_transform.origin) + * control.visible = not get_viewport().get_camera_3d().is_position_behind(global_transform.origin) * control.position = get_viewport().get_camera_3d().unproject_position(global_transform.origin) * ``` */ @@ -343,10 +303,7 @@ public open class Camera3D : Node3D() { } /** - * Returns `true` if the given position is behind the camera (the blue part of the linked - * diagram). - * [url=https://raw.githubusercontent.com/godotengine/godot-docs/master/img/camera3d_position_frustum.png]See - * this diagram[/url] for an overview of position query methods. + * Returns `true` if the given position is behind the camera (the blue part of the linked diagram). [url=https://raw.githubusercontent.com/godotengine/godot-docs/master/img/camera3d_position_frustum.png]See this diagram[/url] for an overview of position query methods. * * **Note:** A position which returns `false` may still be outside the camera's field of view. */ @@ -357,8 +314,7 @@ public open class Camera3D : Node3D() { } /** - * Returns the 3D point in world space that maps to the given 2D coordinate in the [Viewport] - * rectangle on a plane that is the given [zDepth] distance into the scene away from the camera. + * Returns the 3D point in world space that maps to the given 2D coordinate in the [Viewport] rectangle on a plane that is the given [zDepth] distance into the scene away from the camera. */ public final fun projectPosition(screenPoint: Vector2, zDepth: Float): Vector3 { TransferContext.writeArguments(VECTOR2 to screenPoint, DOUBLE to zDepth.toDouble()) @@ -367,68 +323,60 @@ public open class Camera3D : Node3D() { } /** - * Sets the camera projection to perspective mode (see [PROJECTION_PERSPECTIVE]), by specifying a - * [fov] (field of view) angle in degrees, and the [zNear] and [zFar] clip planes in world space - * units. + * Sets the camera projection to perspective mode (see [PROJECTION_PERSPECTIVE]), by specifying a [fov] (field of view) angle in degrees, and the [zNear] and [zFar] clip planes in world space units. */ public final fun setPerspective( fov: Float, zNear: Float, zFar: Float, - ): Unit { + ) { TransferContext.writeArguments(DOUBLE to fov.toDouble(), DOUBLE to zNear.toDouble(), DOUBLE to zFar.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setPerspectivePtr, NIL) } /** - * Sets the camera projection to orthogonal mode (see [PROJECTION_ORTHOGONAL]), by specifying a - * [size], and the [zNear] and [zFar] clip planes in world space units. (As a hint, 2D games often - * use this projection, with values specified in pixels.) + * Sets the camera projection to orthogonal mode (see [PROJECTION_ORTHOGONAL]), by specifying a [size], and the [zNear] and [zFar] clip planes in world space units. (As a hint, 2D games often use this projection, with values specified in pixels.) */ public final fun setOrthogonal( size: Float, zNear: Float, zFar: Float, - ): Unit { + ) { TransferContext.writeArguments(DOUBLE to size.toDouble(), DOUBLE to zNear.toDouble(), DOUBLE to zFar.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setOrthogonalPtr, NIL) } /** - * Sets the camera projection to frustum mode (see [PROJECTION_FRUSTUM]), by specifying a [size], - * an [offset], and the [zNear] and [zFar] clip planes in world space units. See also - * [frustumOffset]. + * Sets the camera projection to frustum mode (see [PROJECTION_FRUSTUM]), by specifying a [size], an [offset], and the [zNear] and [zFar] clip planes in world space units. See also [frustumOffset]. */ public final fun setFrustum( size: Float, offset: Vector2, zNear: Float, zFar: Float, - ): Unit { + ) { TransferContext.writeArguments(DOUBLE to size.toDouble(), VECTOR2 to offset, DOUBLE to zNear.toDouble(), DOUBLE to zFar.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setFrustumPtr, NIL) } /** - * Makes this camera the current camera for the [Viewport] (see class description). If the camera - * node is outside the scene tree, it will attempt to become current once it's added. + * Makes this camera the current camera for the [Viewport] (see class description). If the camera node is outside the scene tree, it will attempt to become current once it's added. */ - public final fun makeCurrent(): Unit { + public final fun makeCurrent() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.makeCurrentPtr, NIL) } /** - * If this is the current camera, remove it from being current. If [enableNext] is `true`, request - * to make the next camera current, if any. + * If this is the current camera, remove it from being current. If [enableNext] is `true`, request to make the next camera current, if any. */ @JvmOverloads - public final fun clearCurrent(enableNext: Boolean = true): Unit { + public final fun clearCurrent(enableNext: Boolean = true) { TransferContext.writeArguments(BOOL to enableNext) TransferContext.callMethod(ptr, MethodBindings.clearCurrentPtr, NIL) } - public final fun setCurrent(enabled: Boolean): Unit { + public final fun setCurrent(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setCurrentPtr, NIL) } @@ -440,9 +388,7 @@ public open class Camera3D : Node3D() { } /** - * Returns the transform of the camera plus the vertical ([vOffset]) and horizontal ([hOffset]) - * offsets; and any other adjustments made to the position and orientation of the camera by - * subclassed cameras such as [XRCamera3D]. + * Returns the transform of the camera plus the vertical ([vOffset]) and horizontal ([hOffset]) offsets; and any other adjustments made to the position and orientation of the camera by subclassed cameras such as [XRCamera3D]. */ public final fun getCameraTransform(): Transform3D { TransferContext.writeArguments() @@ -451,8 +397,7 @@ public open class Camera3D : Node3D() { } /** - * Returns the projection matrix that this camera uses to render to its associated viewport. The - * camera must be part of the scene tree to function. + * Returns the projection matrix that this camera uses to render to its associated viewport. The camera must be part of the scene tree to function. */ public final fun getCameraProjection(): Projection { TransferContext.writeArguments() @@ -490,27 +435,27 @@ public open class Camera3D : Node3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setFov(fov: Float): Unit { + public final fun setFov(fov: Float) { TransferContext.writeArguments(DOUBLE to fov.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setFovPtr, NIL) } - public final fun setFrustumOffset(offset: Vector2): Unit { + public final fun setFrustumOffset(offset: Vector2) { TransferContext.writeArguments(VECTOR2 to offset) TransferContext.callMethod(ptr, MethodBindings.setFrustumOffsetPtr, NIL) } - public final fun setSize(size: Float): Unit { + public final fun setSize(size: Float) { TransferContext.writeArguments(DOUBLE to size.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setSizePtr, NIL) } - public final fun setFar(far: Float): Unit { + public final fun setFar(far: Float) { TransferContext.writeArguments(DOUBLE to far.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setFarPtr, NIL) } - public final fun setNear(near: Float): Unit { + public final fun setNear(near: Float) { TransferContext.writeArguments(DOUBLE to near.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setNearPtr, NIL) } @@ -521,12 +466,12 @@ public open class Camera3D : Node3D() { return ProjectionType.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setProjection(mode: ProjectionType): Unit { + public final fun setProjection(mode: ProjectionType) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setProjectionPtr, NIL) } - public final fun setHOffset(offset: Float): Unit { + public final fun setHOffset(offset: Float) { TransferContext.writeArguments(DOUBLE to offset.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setHOffsetPtr, NIL) } @@ -537,7 +482,7 @@ public open class Camera3D : Node3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setVOffset(offset: Float): Unit { + public final fun setVOffset(offset: Float) { TransferContext.writeArguments(DOUBLE to offset.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setVOffsetPtr, NIL) } @@ -548,7 +493,7 @@ public open class Camera3D : Node3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setCullMask(mask: Long): Unit { + public final fun setCullMask(mask: Long) { TransferContext.writeArguments(LONG to mask) TransferContext.callMethod(ptr, MethodBindings.setCullMaskPtr, NIL) } @@ -559,7 +504,7 @@ public open class Camera3D : Node3D() { return (TransferContext.readReturnValue(LONG) as Long) } - public final fun setEnvironment(env: Environment?): Unit { + public final fun setEnvironment(env: Environment?) { TransferContext.writeArguments(OBJECT to env) TransferContext.callMethod(ptr, MethodBindings.setEnvironmentPtr, NIL) } @@ -570,7 +515,7 @@ public open class Camera3D : Node3D() { return (TransferContext.readReturnValue(OBJECT) as Environment?) } - public final fun setAttributes(env: CameraAttributes?): Unit { + public final fun setAttributes(env: CameraAttributes?) { TransferContext.writeArguments(OBJECT to env) TransferContext.callMethod(ptr, MethodBindings.setAttributesPtr, NIL) } @@ -581,7 +526,7 @@ public open class Camera3D : Node3D() { return (TransferContext.readReturnValue(OBJECT) as CameraAttributes?) } - public final fun setCompositor(compositor: Compositor?): Unit { + public final fun setCompositor(compositor: Compositor?) { TransferContext.writeArguments(OBJECT to compositor) TransferContext.callMethod(ptr, MethodBindings.setCompositorPtr, NIL) } @@ -592,7 +537,7 @@ public open class Camera3D : Node3D() { return (TransferContext.readReturnValue(OBJECT) as Compositor?) } - public final fun setKeepAspectMode(mode: KeepAspect): Unit { + public final fun setKeepAspectMode(mode: KeepAspect) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setKeepAspectModePtr, NIL) } @@ -603,7 +548,7 @@ public open class Camera3D : Node3D() { return KeepAspect.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setDopplerTracking(mode: DopplerTracking): Unit { + public final fun setDopplerTracking(mode: DopplerTracking) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setDopplerTrackingPtr, NIL) } @@ -615,8 +560,7 @@ public open class Camera3D : Node3D() { } /** - * Returns the camera's frustum planes in world space units as an array of [Plane]s in the - * following order: near, far, left, top, right, bottom. Not to be confused with [frustumOffset]. + * Returns the camera's frustum planes in world space units as an array of [Plane]s in the following order: near, far, left, top, right, bottom. Not to be confused with [frustumOffset]. */ public final fun getFrustum(): VariantArray { TransferContext.writeArguments() @@ -625,10 +569,7 @@ public open class Camera3D : Node3D() { } /** - * Returns `true` if the given position is inside the camera's frustum (the green part of the - * linked diagram). - * [url=https://raw.githubusercontent.com/godotengine/godot-docs/master/img/camera3d_position_frustum.png]See - * this diagram[/url] for an overview of position query methods. + * Returns `true` if the given position is inside the camera's frustum (the green part of the linked diagram). [url=https://raw.githubusercontent.com/godotengine/godot-docs/master/img/camera3d_position_frustum.png]See this diagram[/url] for an overview of position query methods. */ public final fun isPositionInFrustum(worldPoint: Vector3): Boolean { TransferContext.writeArguments(VECTOR3 to worldPoint) @@ -646,8 +587,7 @@ public open class Camera3D : Node3D() { } /** - * Returns the RID of a pyramid shape encompassing the camera's view frustum, ignoring the - * camera's near plane. The tip of the pyramid represents the position of the camera. + * Returns the RID of a pyramid shape encompassing the camera's view frustum, ignoring the camera's near plane. The tip of the pyramid represents the position of the camera. */ public final fun getPyramidShapeRid(): RID { TransferContext.writeArguments() @@ -656,17 +596,15 @@ public open class Camera3D : Node3D() { } /** - * Based on [value], enables or disables the specified layer in the [cullMask], given a - * [layerNumber] between 1 and 20. + * Based on [value], enables or disables the specified layer in the [cullMask], given a [layerNumber] between 1 and 20. */ - public final fun setCullMaskValue(layerNumber: Int, `value`: Boolean): Unit { + public final fun setCullMaskValue(layerNumber: Int, `value`: Boolean) { TransferContext.writeArguments(LONG to layerNumber.toLong(), BOOL to value) TransferContext.callMethod(ptr, MethodBindings.setCullMaskValuePtr, NIL) } /** - * Returns whether or not the specified layer of the [cullMask] is enabled, given a [layerNumber] - * between 1 and 20. + * Returns whether or not the specified layer of the [cullMask] is enabled, given a [layerNumber] between 1 and 20. */ public final fun getCullMaskValue(layerNumber: Int): Boolean { TransferContext.writeArguments(LONG to layerNumber.toLong()) @@ -682,13 +620,11 @@ public open class Camera3D : Node3D() { */ PERSPECTIVE(0), /** - * Orthogonal projection, also known as orthographic projection. Objects remain the same size on - * the screen no matter how far away they are. + * Orthogonal projection, also known as orthographic projection. Objects remain the same size on the screen no matter how far away they are. */ ORTHOGONAL(1), /** - * Frustum projection. This mode allows adjusting [frustumOffset] to create "tilted frustum" - * effects. + * Frustum projection. This mode allows adjusting [frustumOffset] to create "tilted frustum" effects. */ FRUSTUM(2), ; @@ -707,15 +643,11 @@ public open class Camera3D : Node3D() { id: Long, ) { /** - * Preserves the horizontal aspect ratio; also known as Vert- scaling. This is usually the best - * option for projects running in portrait mode, as taller aspect ratios will benefit from a wider - * vertical FOV. + * Preserves the horizontal aspect ratio; also known as Vert- scaling. This is usually the best option for projects running in portrait mode, as taller aspect ratios will benefit from a wider vertical FOV. */ WIDTH(0), /** - * Preserves the vertical aspect ratio; also known as Hor+ scaling. This is usually the best - * option for projects running in landscape mode, as wider aspect ratios will automatically benefit - * from a wider horizontal FOV. + * Preserves the vertical aspect ratio; also known as Hor+ scaling. This is usually the best option for projects running in landscape mode, as wider aspect ratios will automatically benefit from a wider horizontal FOV. */ HEIGHT(1), ; @@ -734,22 +666,15 @@ public open class Camera3D : Node3D() { id: Long, ) { /** - * Disables [url=https://en.wikipedia.org/wiki/Doppler_effect]Doppler effect[/url] simulation - * (default). + * Disables [url=https://en.wikipedia.org/wiki/Doppler_effect]Doppler effect[/url] simulation (default). */ DISABLED(0), /** - * Simulate [url=https://en.wikipedia.org/wiki/Doppler_effect]Doppler effect[/url] by tracking - * positions of objects that are changed in `_process`. Changes in the relative velocity of this - * camera compared to those objects affect how audio is perceived (changing the audio's - * [AudioStreamPlayer3D.pitchScale]). + * Simulate [url=https://en.wikipedia.org/wiki/Doppler_effect]Doppler effect[/url] by tracking positions of objects that are changed in `_process`. Changes in the relative velocity of this camera compared to those objects affect how audio is perceived (changing the audio's [AudioStreamPlayer3D.pitchScale]). */ IDLE_STEP(1), /** - * Simulate [url=https://en.wikipedia.org/wiki/Doppler_effect]Doppler effect[/url] by tracking - * positions of objects that are changed in `_physics_process`. Changes in the relative velocity of - * this camera compared to those objects affect how audio is perceived (changing the audio's - * [AudioStreamPlayer3D.pitchScale]). + * Simulate [url=https://en.wikipedia.org/wiki/Doppler_effect]Doppler effect[/url] by tracking positions of objects that are changed in `_physics_process`. Changes in the relative velocity of this camera compared to those objects affect how audio is perceived (changing the audio's [AudioStreamPlayer3D.pitchScale]). */ PHYSICS_STEP(2), ; @@ -768,148 +693,150 @@ public open class Camera3D : Node3D() { public object MethodBindings { internal val projectRayNormalPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "project_ray_normal", 1718073306) + TypeManager.getMethodBindPtr("Camera3D", "project_ray_normal", 1_718_073_306) internal val projectLocalRayNormalPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "project_local_ray_normal", 1718073306) + TypeManager.getMethodBindPtr("Camera3D", "project_local_ray_normal", 1_718_073_306) internal val projectRayOriginPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "project_ray_origin", 1718073306) + TypeManager.getMethodBindPtr("Camera3D", "project_ray_origin", 1_718_073_306) internal val unprojectPositionPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "unproject_position", 3758901831) + TypeManager.getMethodBindPtr("Camera3D", "unproject_position", 3_758_901_831) internal val isPositionBehindPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "is_position_behind", 3108956480) + TypeManager.getMethodBindPtr("Camera3D", "is_position_behind", 3_108_956_480) internal val projectPositionPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "project_position", 2171975744) + TypeManager.getMethodBindPtr("Camera3D", "project_position", 2_171_975_744) internal val setPerspectivePtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "set_perspective", 2385087082) + TypeManager.getMethodBindPtr("Camera3D", "set_perspective", 2_385_087_082) internal val setOrthogonalPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "set_orthogonal", 2385087082) + TypeManager.getMethodBindPtr("Camera3D", "set_orthogonal", 2_385_087_082) internal val setFrustumPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "set_frustum", 354890663) + TypeManager.getMethodBindPtr("Camera3D", "set_frustum", 354_890_663) internal val makeCurrentPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "make_current", 3218959716) + TypeManager.getMethodBindPtr("Camera3D", "make_current", 3_218_959_716) internal val clearCurrentPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "clear_current", 3216645846) + TypeManager.getMethodBindPtr("Camera3D", "clear_current", 3_216_645_846) internal val setCurrentPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "set_current", 2586408642) + TypeManager.getMethodBindPtr("Camera3D", "set_current", 2_586_408_642) internal val isCurrentPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "is_current", 36873697) + TypeManager.getMethodBindPtr("Camera3D", "is_current", 36_873_697) internal val getCameraTransformPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "get_camera_transform", 3229777777) + TypeManager.getMethodBindPtr("Camera3D", "get_camera_transform", 3_229_777_777) internal val getCameraProjectionPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "get_camera_projection", 2910717950) + TypeManager.getMethodBindPtr("Camera3D", "get_camera_projection", 2_910_717_950) internal val getFovPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "get_fov", 1740695150) + TypeManager.getMethodBindPtr("Camera3D", "get_fov", 1_740_695_150) internal val getFrustumOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "get_frustum_offset", 3341600327) + TypeManager.getMethodBindPtr("Camera3D", "get_frustum_offset", 3_341_600_327) internal val getSizePtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "get_size", 1740695150) + TypeManager.getMethodBindPtr("Camera3D", "get_size", 1_740_695_150) internal val getFarPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "get_far", 1740695150) + TypeManager.getMethodBindPtr("Camera3D", "get_far", 1_740_695_150) internal val getNearPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "get_near", 1740695150) + TypeManager.getMethodBindPtr("Camera3D", "get_near", 1_740_695_150) - internal val setFovPtr: VoidPtr = TypeManager.getMethodBindPtr("Camera3D", "set_fov", 373806689) + internal val setFovPtr: VoidPtr = + TypeManager.getMethodBindPtr("Camera3D", "set_fov", 373_806_689) internal val setFrustumOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "set_frustum_offset", 743155724) + TypeManager.getMethodBindPtr("Camera3D", "set_frustum_offset", 743_155_724) internal val setSizePtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "set_size", 373806689) + TypeManager.getMethodBindPtr("Camera3D", "set_size", 373_806_689) - internal val setFarPtr: VoidPtr = TypeManager.getMethodBindPtr("Camera3D", "set_far", 373806689) + internal val setFarPtr: VoidPtr = + TypeManager.getMethodBindPtr("Camera3D", "set_far", 373_806_689) internal val setNearPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "set_near", 373806689) + TypeManager.getMethodBindPtr("Camera3D", "set_near", 373_806_689) internal val getProjectionPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "get_projection", 2624185235) + TypeManager.getMethodBindPtr("Camera3D", "get_projection", 2_624_185_235) internal val setProjectionPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "set_projection", 4218540108) + TypeManager.getMethodBindPtr("Camera3D", "set_projection", 4_218_540_108) internal val setHOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "set_h_offset", 373806689) + TypeManager.getMethodBindPtr("Camera3D", "set_h_offset", 373_806_689) internal val getHOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "get_h_offset", 1740695150) + TypeManager.getMethodBindPtr("Camera3D", "get_h_offset", 1_740_695_150) internal val setVOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "set_v_offset", 373806689) + TypeManager.getMethodBindPtr("Camera3D", "set_v_offset", 373_806_689) internal val getVOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "get_v_offset", 1740695150) + TypeManager.getMethodBindPtr("Camera3D", "get_v_offset", 1_740_695_150) internal val setCullMaskPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "set_cull_mask", 1286410249) + TypeManager.getMethodBindPtr("Camera3D", "set_cull_mask", 1_286_410_249) internal val getCullMaskPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "get_cull_mask", 3905245786) + TypeManager.getMethodBindPtr("Camera3D", "get_cull_mask", 3_905_245_786) internal val setEnvironmentPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "set_environment", 4143518816) + TypeManager.getMethodBindPtr("Camera3D", "set_environment", 4_143_518_816) internal val getEnvironmentPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "get_environment", 3082064660) + TypeManager.getMethodBindPtr("Camera3D", "get_environment", 3_082_064_660) internal val setAttributesPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "set_attributes", 2817810567) + TypeManager.getMethodBindPtr("Camera3D", "set_attributes", 2_817_810_567) internal val getAttributesPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "get_attributes", 3921283215) + TypeManager.getMethodBindPtr("Camera3D", "get_attributes", 3_921_283_215) internal val setCompositorPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "set_compositor", 1586754307) + TypeManager.getMethodBindPtr("Camera3D", "set_compositor", 1_586_754_307) internal val getCompositorPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "get_compositor", 3647707413) + TypeManager.getMethodBindPtr("Camera3D", "get_compositor", 3_647_707_413) internal val setKeepAspectModePtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "set_keep_aspect_mode", 1740651252) + TypeManager.getMethodBindPtr("Camera3D", "set_keep_aspect_mode", 1_740_651_252) internal val getKeepAspectModePtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "get_keep_aspect_mode", 2790278316) + TypeManager.getMethodBindPtr("Camera3D", "get_keep_aspect_mode", 2_790_278_316) internal val setDopplerTrackingPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "set_doppler_tracking", 3109431270) + TypeManager.getMethodBindPtr("Camera3D", "set_doppler_tracking", 3_109_431_270) internal val getDopplerTrackingPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "get_doppler_tracking", 1584483649) + TypeManager.getMethodBindPtr("Camera3D", "get_doppler_tracking", 1_584_483_649) internal val getFrustumPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "get_frustum", 3995934104) + TypeManager.getMethodBindPtr("Camera3D", "get_frustum", 3_995_934_104) internal val isPositionInFrustumPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "is_position_in_frustum", 3108956480) + TypeManager.getMethodBindPtr("Camera3D", "is_position_in_frustum", 3_108_956_480) internal val getCameraRidPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "get_camera_rid", 2944877500) + TypeManager.getMethodBindPtr("Camera3D", "get_camera_rid", 2_944_877_500) internal val getPyramidShapeRidPtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "get_pyramid_shape_rid", 529393457) + TypeManager.getMethodBindPtr("Camera3D", "get_pyramid_shape_rid", 529_393_457) internal val setCullMaskValuePtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "set_cull_mask_value", 300928843) + TypeManager.getMethodBindPtr("Camera3D", "set_cull_mask_value", 300_928_843) internal val getCullMaskValuePtr: VoidPtr = - TypeManager.getMethodBindPtr("Camera3D", "get_cull_mask_value", 1116898809) + TypeManager.getMethodBindPtr("Camera3D", "get_cull_mask_value", 1_116_898_809) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CameraAttributes.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CameraAttributes.kt index 5e88cb1738..8a6aeb63ec 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CameraAttributes.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CameraAttributes.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -18,33 +15,25 @@ import kotlin.Double import kotlin.Float import kotlin.Int import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** * Controls camera-specific attributes such as depth of field and exposure override. * - * When used in a [WorldEnvironment] it provides default settings for exposure, auto-exposure, and - * depth of field that will be used by all cameras without their own [CameraAttributes], including the - * editor camera. When used in a [Camera3D] it will override any [CameraAttributes] set in the - * [WorldEnvironment]. When used in [VoxelGI] or [LightmapGI], only the exposure settings will be used. + * When used in a [WorldEnvironment] it provides default settings for exposure, auto-exposure, and depth of field that will be used by all cameras without their own [CameraAttributes], including the editor camera. When used in a [Camera3D] it will override any [CameraAttributes] set in the [WorldEnvironment]. When used in [VoxelGI] or [LightmapGI], only the exposure settings will be used. * * See also [Environment] for general 3D environment settings. * - * This is a pure virtual class that is inherited by [CameraAttributesPhysical] and - * [CameraAttributesPractical]. + * This is a pure virtual class that is inherited by [CameraAttributesPhysical] and [CameraAttributesPractical]. */ @GodotBaseType public open class CameraAttributes : Resource() { /** - * Sensitivity of camera sensors, measured in ISO. A higher sensitivity results in a brighter - * image. + * Sensitivity of camera sensors, measured in ISO. A higher sensitivity results in a brighter image. * - * If [autoExposureEnabled] is `true`, this can be used as a method of exposure compensation, - * doubling the value will increase the exposure value (measured in EV100) by 1 stop. + * If [autoExposureEnabled] is `true`, this can be used as a method of exposure compensation, doubling the value will increase the exposure value (measured in EV100) by 1 stop. * - * **Note:** Only available when - * [ProjectSettings.rendering/lightsAndShadows/usePhysicalLightUnits] is enabled. + * **Note:** Only available when [ProjectSettings.rendering/lightsAndShadows/usePhysicalLightUnits] is enabled. */ public final inline var exposureSensitivity: Float @JvmName("exposureSensitivityProperty") @@ -66,9 +55,7 @@ public open class CameraAttributes : Resource() { } /** - * If `true`, enables the tonemapping auto exposure mode of the scene renderer. If `true`, the - * renderer will automatically determine the exposure setting to adapt to the scene's illumination - * and the observed light. + * If `true`, enables the tonemapping auto exposure mode of the scene renderer. If `true`, the renderer will automatically determine the exposure setting to adapt to the scene's illumination and the observed light. */ public final inline var autoExposureEnabled: Boolean @JvmName("autoExposureEnabledProperty") @@ -90,8 +77,7 @@ public open class CameraAttributes : Resource() { } /** - * The speed of the auto exposure effect. Affects the time needed for the camera to perform auto - * exposure. + * The speed of the auto exposure effect. Affects the time needed for the camera to perform auto exposure. */ public final inline var autoExposureSpeed: Float @JvmName("autoExposureSpeedProperty") @@ -101,11 +87,11 @@ public open class CameraAttributes : Resource() { setAutoExposureSpeed(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(129, scriptIndex) } - public final fun setExposureMultiplier(multiplier: Float): Unit { + public final fun setExposureMultiplier(multiplier: Float) { TransferContext.writeArguments(DOUBLE to multiplier.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setExposureMultiplierPtr, NIL) } @@ -116,7 +102,7 @@ public open class CameraAttributes : Resource() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setExposureSensitivity(sensitivity: Float): Unit { + public final fun setExposureSensitivity(sensitivity: Float) { TransferContext.writeArguments(DOUBLE to sensitivity.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setExposureSensitivityPtr, NIL) } @@ -127,7 +113,7 @@ public open class CameraAttributes : Resource() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setAutoExposureEnabled(enabled: Boolean): Unit { + public final fun setAutoExposureEnabled(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setAutoExposureEnabledPtr, NIL) } @@ -138,7 +124,7 @@ public open class CameraAttributes : Resource() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setAutoExposureSpeed(exposureSpeed: Float): Unit { + public final fun setAutoExposureSpeed(exposureSpeed: Float) { TransferContext.writeArguments(DOUBLE to exposureSpeed.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setAutoExposureSpeedPtr, NIL) } @@ -149,7 +135,7 @@ public open class CameraAttributes : Resource() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setAutoExposureScale(exposureGrey: Float): Unit { + public final fun setAutoExposureScale(exposureGrey: Float) { TransferContext.writeArguments(DOUBLE to exposureGrey.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setAutoExposureScalePtr, NIL) } @@ -164,33 +150,33 @@ public open class CameraAttributes : Resource() { public object MethodBindings { internal val setExposureMultiplierPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributes", "set_exposure_multiplier", 373806689) + TypeManager.getMethodBindPtr("CameraAttributes", "set_exposure_multiplier", 373_806_689) internal val getExposureMultiplierPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributes", "get_exposure_multiplier", 1740695150) + TypeManager.getMethodBindPtr("CameraAttributes", "get_exposure_multiplier", 1_740_695_150) internal val setExposureSensitivityPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributes", "set_exposure_sensitivity", 373806689) + TypeManager.getMethodBindPtr("CameraAttributes", "set_exposure_sensitivity", 373_806_689) internal val getExposureSensitivityPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributes", "get_exposure_sensitivity", 1740695150) + TypeManager.getMethodBindPtr("CameraAttributes", "get_exposure_sensitivity", 1_740_695_150) internal val setAutoExposureEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributes", "set_auto_exposure_enabled", 2586408642) + TypeManager.getMethodBindPtr("CameraAttributes", "set_auto_exposure_enabled", 2_586_408_642) internal val isAutoExposureEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributes", "is_auto_exposure_enabled", 36873697) + TypeManager.getMethodBindPtr("CameraAttributes", "is_auto_exposure_enabled", 36_873_697) internal val setAutoExposureSpeedPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributes", "set_auto_exposure_speed", 373806689) + TypeManager.getMethodBindPtr("CameraAttributes", "set_auto_exposure_speed", 373_806_689) internal val getAutoExposureSpeedPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributes", "get_auto_exposure_speed", 1740695150) + TypeManager.getMethodBindPtr("CameraAttributes", "get_auto_exposure_speed", 1_740_695_150) internal val setAutoExposureScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributes", "set_auto_exposure_scale", 373806689) + TypeManager.getMethodBindPtr("CameraAttributes", "set_auto_exposure_scale", 373_806_689) internal val getAutoExposureScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributes", "get_auto_exposure_scale", 1740695150) + TypeManager.getMethodBindPtr("CameraAttributes", "get_auto_exposure_scale", 1_740_695_150) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CameraAttributesPhysical.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CameraAttributesPhysical.kt index 96d7117092..9f0f41f5e9 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CameraAttributesPhysical.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CameraAttributesPhysical.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -16,31 +13,21 @@ import kotlin.Double import kotlin.Float import kotlin.Int import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * [CameraAttributesPhysical] is used to set rendering settings based on a physically-based camera's - * settings. It is responsible for exposure, auto-exposure, and depth of field. + * [CameraAttributesPhysical] is used to set rendering settings based on a physically-based camera's settings. It is responsible for exposure, auto-exposure, and depth of field. * - * When used in a [WorldEnvironment] it provides default settings for exposure, auto-exposure, and - * depth of field that will be used by all cameras without their own [CameraAttributes], including the - * editor camera. When used in a [Camera3D] it will override any [CameraAttributes] set in the - * [WorldEnvironment] and will override the [Camera3D]s [Camera3D.far], [Camera3D.near], - * [Camera3D.fov], and [Camera3D.keepAspect] properties. When used in [VoxelGI] or [LightmapGI], only - * the exposure settings will be used. + * When used in a [WorldEnvironment] it provides default settings for exposure, auto-exposure, and depth of field that will be used by all cameras without their own [CameraAttributes], including the editor camera. When used in a [Camera3D] it will override any [CameraAttributes] set in the [WorldEnvironment] and will override the [Camera3D]s [Camera3D.far], [Camera3D.near], [Camera3D.fov], and [Camera3D.keepAspect] properties. When used in [VoxelGI] or [LightmapGI], only the exposure settings will be used. * - * The default settings are intended for use in an outdoor environment, tips for settings for use in - * an indoor environment can be found in each setting's documentation. + * The default settings are intended for use in an outdoor environment, tips for settings for use in an indoor environment can be found in each setting's documentation. * - * **Note:** Depth of field blur is only supported in the Forward+ and Mobile rendering methods, not - * Compatibility. + * **Note:** Depth of field blur is only supported in the Forward+ and Mobile rendering methods, not Compatibility. */ @GodotBaseType public open class CameraAttributesPhysical : CameraAttributes() { /** - * Distance from camera of object that will be in focus, measured in meters. Internally this will - * be clamped to be at least 1 millimeter larger than [frustumFocalLength]. + * Distance from camera of object that will be in focus, measured in meters. Internally this will be clamped to be at least 1 millimeter larger than [frustumFocalLength]. */ public final inline var frustumFocusDistance: Float @JvmName("frustumFocusDistanceProperty") @@ -51,12 +38,7 @@ public open class CameraAttributesPhysical : CameraAttributes() { } /** - * Distance between camera lens and camera aperture, measured in millimeters. Controls field of - * view and depth of field. A larger focal length will result in a smaller field of view and a - * narrower depth of field meaning fewer objects will be in focus. A smaller focal length will result - * in a wider field of view and a larger depth of field meaning more objects will be in focus. When - * attached to a [Camera3D] as its [Camera3D.attributes], it will override the [Camera3D.fov] - * property and the [Camera3D.keepAspect] property. + * Distance between camera lens and camera aperture, measured in millimeters. Controls field of view and depth of field. A larger focal length will result in a smaller field of view and a narrower depth of field meaning fewer objects will be in focus. A smaller focal length will result in a wider field of view and a larger depth of field meaning more objects will be in focus. When attached to a [Camera3D] as its [Camera3D.attributes], it will override the [Camera3D.fov] property and the [Camera3D.keepAspect] property. */ public final inline var frustumFocalLength: Float @JvmName("frustumFocalLengthProperty") @@ -67,9 +49,7 @@ public open class CameraAttributesPhysical : CameraAttributes() { } /** - * Override value for [Camera3D.near]. Used internally when calculating depth of field. When - * attached to a [Camera3D] as its [Camera3D.attributes], it will override the [Camera3D.near] - * property. + * Override value for [Camera3D.near]. Used internally when calculating depth of field. When attached to a [Camera3D] as its [Camera3D.attributes], it will override the [Camera3D.near] property. */ public final inline var frustumNear: Float @JvmName("frustumNearProperty") @@ -80,9 +60,7 @@ public open class CameraAttributesPhysical : CameraAttributes() { } /** - * Override value for [Camera3D.far]. Used internally when calculating depth of field. When - * attached to a [Camera3D] as its [Camera3D.attributes], it will override the [Camera3D.far] - * property. + * Override value for [Camera3D.far]. Used internally when calculating depth of field. When attached to a [Camera3D] as its [Camera3D.attributes], it will override the [Camera3D.far] property. */ public final inline var frustumFar: Float @JvmName("frustumFarProperty") @@ -93,15 +71,9 @@ public open class CameraAttributesPhysical : CameraAttributes() { } /** - * Size of the aperture of the camera, measured in f-stops. An f-stop is a unitless ratio between - * the focal length of the camera and the diameter of the aperture. A high aperture setting will - * result in a smaller aperture which leads to a dimmer image and sharper focus. A low aperture - * results in a wide aperture which lets in more light resulting in a brighter, less-focused image. - * Default is appropriate for outdoors at daytime (i.e. for use with a default [DirectionalLight3D]), - * for indoor lighting, a value between 2 and 4 is more appropriate. + * Size of the aperture of the camera, measured in f-stops. An f-stop is a unitless ratio between the focal length of the camera and the diameter of the aperture. A high aperture setting will result in a smaller aperture which leads to a dimmer image and sharper focus. A low aperture results in a wide aperture which lets in more light resulting in a brighter, less-focused image. Default is appropriate for outdoors at daytime (i.e. for use with a default [DirectionalLight3D]), for indoor lighting, a value between 2 and 4 is more appropriate. * - * Only available when [ProjectSettings.rendering/lightsAndShadows/usePhysicalLightUnits] is - * enabled. + * Only available when [ProjectSettings.rendering/lightsAndShadows/usePhysicalLightUnits] is enabled. */ public final inline var exposureAperture: Float @JvmName("exposureApertureProperty") @@ -112,12 +84,9 @@ public open class CameraAttributesPhysical : CameraAttributes() { } /** - * Time for shutter to open and close, evaluated as `1 / shutter_speed` seconds. A higher value - * will allow less light (leading to a darker image), while a lower value will allow more light - * (leading to a brighter image). + * Time for shutter to open and close, evaluated as `1 / shutter_speed` seconds. A higher value will allow less light (leading to a darker image), while a lower value will allow more light (leading to a brighter image). * - * Only available when [ProjectSettings.rendering/lightsAndShadows/usePhysicalLightUnits] is - * enabled. + * Only available when [ProjectSettings.rendering/lightsAndShadows/usePhysicalLightUnits] is enabled. */ public final inline var exposureShutterSpeed: Float @JvmName("exposureShutterSpeedProperty") @@ -128,10 +97,7 @@ public open class CameraAttributesPhysical : CameraAttributes() { } /** - * The minimum luminance (in EV100) used when calculating auto exposure. When calculating scene - * average luminance, color values will be clamped to at least this value. This limits the - * auto-exposure from exposing above a certain brightness, resulting in a cut off point where the - * scene will remain dark. + * The minimum luminance (in EV100) used when calculating auto exposure. When calculating scene average luminance, color values will be clamped to at least this value. This limits the auto-exposure from exposing above a certain brightness, resulting in a cut off point where the scene will remain dark. */ public final inline var autoExposureMinExposureValue: Float @JvmName("autoExposureMinExposureValueProperty") @@ -142,10 +108,7 @@ public open class CameraAttributesPhysical : CameraAttributes() { } /** - * The maximum luminance (in EV100) used when calculating auto exposure. When calculating scene - * average luminance, color values will be clamped to at least this value. This limits the - * auto-exposure from exposing below a certain brightness, resulting in a cut off point where the - * scene will remain bright. + * The maximum luminance (in EV100) used when calculating auto exposure. When calculating scene average luminance, color values will be clamped to at least this value. This limits the auto-exposure from exposing below a certain brightness, resulting in a cut off point where the scene will remain bright. */ public final inline var autoExposureMaxExposureValue: Float @JvmName("autoExposureMaxExposureValueProperty") @@ -155,11 +118,11 @@ public open class CameraAttributesPhysical : CameraAttributes() { setAutoExposureMaxExposureValue(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(130, scriptIndex) } - public final fun setAperture(aperture: Float): Unit { + public final fun setAperture(aperture: Float) { TransferContext.writeArguments(DOUBLE to aperture.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setAperturePtr, NIL) } @@ -170,7 +133,7 @@ public open class CameraAttributesPhysical : CameraAttributes() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setShutterSpeed(shutterSpeed: Float): Unit { + public final fun setShutterSpeed(shutterSpeed: Float) { TransferContext.writeArguments(DOUBLE to shutterSpeed.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setShutterSpeedPtr, NIL) } @@ -181,7 +144,7 @@ public open class CameraAttributesPhysical : CameraAttributes() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setFocalLength(focalLength: Float): Unit { + public final fun setFocalLength(focalLength: Float) { TransferContext.writeArguments(DOUBLE to focalLength.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setFocalLengthPtr, NIL) } @@ -192,7 +155,7 @@ public open class CameraAttributesPhysical : CameraAttributes() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setFocusDistance(focusDistance: Float): Unit { + public final fun setFocusDistance(focusDistance: Float) { TransferContext.writeArguments(DOUBLE to focusDistance.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setFocusDistancePtr, NIL) } @@ -203,7 +166,7 @@ public open class CameraAttributesPhysical : CameraAttributes() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setNear(near: Float): Unit { + public final fun setNear(near: Float) { TransferContext.writeArguments(DOUBLE to near.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setNearPtr, NIL) } @@ -214,7 +177,7 @@ public open class CameraAttributesPhysical : CameraAttributes() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setFar(far: Float): Unit { + public final fun setFar(far: Float) { TransferContext.writeArguments(DOUBLE to far.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setFarPtr, NIL) } @@ -226,8 +189,7 @@ public open class CameraAttributesPhysical : CameraAttributes() { } /** - * Returns the vertical field of view that corresponds to the [frustumFocalLength]. This value is - * calculated internally whenever [frustumFocalLength] is changed. + * Returns the vertical field of view that corresponds to the [frustumFocalLength]. This value is calculated internally whenever [frustumFocalLength] is changed. */ public final fun getFov(): Float { TransferContext.writeArguments() @@ -235,7 +197,7 @@ public open class CameraAttributesPhysical : CameraAttributes() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setAutoExposureMaxExposureValue(exposureValueMax: Float): Unit { + public final fun setAutoExposureMaxExposureValue(exposureValueMax: Float) { TransferContext.writeArguments(DOUBLE to exposureValueMax.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setAutoExposureMaxExposureValuePtr, NIL) } @@ -246,7 +208,7 @@ public open class CameraAttributesPhysical : CameraAttributes() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setAutoExposureMinExposureValue(exposureValueMin: Float): Unit { + public final fun setAutoExposureMinExposureValue(exposureValueMin: Float) { TransferContext.writeArguments(DOUBLE to exposureValueMin.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setAutoExposureMinExposureValuePtr, NIL) } @@ -261,54 +223,54 @@ public open class CameraAttributesPhysical : CameraAttributes() { public object MethodBindings { internal val setAperturePtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPhysical", "set_aperture", 373806689) + TypeManager.getMethodBindPtr("CameraAttributesPhysical", "set_aperture", 373_806_689) internal val getAperturePtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPhysical", "get_aperture", 1740695150) + TypeManager.getMethodBindPtr("CameraAttributesPhysical", "get_aperture", 1_740_695_150) internal val setShutterSpeedPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPhysical", "set_shutter_speed", 373806689) + TypeManager.getMethodBindPtr("CameraAttributesPhysical", "set_shutter_speed", 373_806_689) internal val getShutterSpeedPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPhysical", "get_shutter_speed", 1740695150) + TypeManager.getMethodBindPtr("CameraAttributesPhysical", "get_shutter_speed", 1_740_695_150) internal val setFocalLengthPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPhysical", "set_focal_length", 373806689) + TypeManager.getMethodBindPtr("CameraAttributesPhysical", "set_focal_length", 373_806_689) internal val getFocalLengthPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPhysical", "get_focal_length", 1740695150) + TypeManager.getMethodBindPtr("CameraAttributesPhysical", "get_focal_length", 1_740_695_150) internal val setFocusDistancePtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPhysical", "set_focus_distance", 373806689) + TypeManager.getMethodBindPtr("CameraAttributesPhysical", "set_focus_distance", 373_806_689) internal val getFocusDistancePtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPhysical", "get_focus_distance", 1740695150) + TypeManager.getMethodBindPtr("CameraAttributesPhysical", "get_focus_distance", 1_740_695_150) internal val setNearPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPhysical", "set_near", 373806689) + TypeManager.getMethodBindPtr("CameraAttributesPhysical", "set_near", 373_806_689) internal val getNearPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPhysical", "get_near", 1740695150) + TypeManager.getMethodBindPtr("CameraAttributesPhysical", "get_near", 1_740_695_150) internal val setFarPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPhysical", "set_far", 373806689) + TypeManager.getMethodBindPtr("CameraAttributesPhysical", "set_far", 373_806_689) internal val getFarPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPhysical", "get_far", 1740695150) + TypeManager.getMethodBindPtr("CameraAttributesPhysical", "get_far", 1_740_695_150) internal val getFovPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPhysical", "get_fov", 1740695150) + TypeManager.getMethodBindPtr("CameraAttributesPhysical", "get_fov", 1_740_695_150) internal val setAutoExposureMaxExposureValuePtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPhysical", "set_auto_exposure_max_exposure_value", 373806689) + TypeManager.getMethodBindPtr("CameraAttributesPhysical", "set_auto_exposure_max_exposure_value", 373_806_689) internal val getAutoExposureMaxExposureValuePtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPhysical", "get_auto_exposure_max_exposure_value", 1740695150) + TypeManager.getMethodBindPtr("CameraAttributesPhysical", "get_auto_exposure_max_exposure_value", 1_740_695_150) internal val setAutoExposureMinExposureValuePtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPhysical", "set_auto_exposure_min_exposure_value", 373806689) + TypeManager.getMethodBindPtr("CameraAttributesPhysical", "set_auto_exposure_min_exposure_value", 373_806_689) internal val getAutoExposureMinExposureValuePtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPhysical", "get_auto_exposure_min_exposure_value", 1740695150) + TypeManager.getMethodBindPtr("CameraAttributesPhysical", "get_auto_exposure_min_exposure_value", 1_740_695_150) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CameraAttributesPractical.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CameraAttributesPractical.kt index 19b8a44bba..cc206127b6 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CameraAttributesPractical.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CameraAttributesPractical.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -18,25 +15,19 @@ import kotlin.Double import kotlin.Float import kotlin.Int import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** * Controls camera-specific attributes such as auto-exposure, depth of field, and exposure override. * - * When used in a [WorldEnvironment] it provides default settings for exposure, auto-exposure, and - * depth of field that will be used by all cameras without their own [CameraAttributes], including the - * editor camera. When used in a [Camera3D] it will override any [CameraAttributes] set in the - * [WorldEnvironment]. When used in [VoxelGI] or [LightmapGI], only the exposure settings will be used. + * When used in a [WorldEnvironment] it provides default settings for exposure, auto-exposure, and depth of field that will be used by all cameras without their own [CameraAttributes], including the editor camera. When used in a [Camera3D] it will override any [CameraAttributes] set in the [WorldEnvironment]. When used in [VoxelGI] or [LightmapGI], only the exposure settings will be used. */ @GodotBaseType public open class CameraAttributesPractical : CameraAttributes() { /** - * Enables depth of field blur for objects further than [dofBlurFarDistance]. Strength of blur is - * controlled by [dofBlurAmount] and modulated by [dofBlurFarTransition]. + * Enables depth of field blur for objects further than [dofBlurFarDistance]. Strength of blur is controlled by [dofBlurAmount] and modulated by [dofBlurFarTransition]. * - * **Note:** Depth of field blur is only supported in the Forward+ and Mobile rendering methods, - * not Compatibility. + * **Note:** Depth of field blur is only supported in the Forward+ and Mobile rendering methods, not Compatibility. */ public final inline var dofBlurFarEnabled: Boolean @JvmName("dofBlurFarEnabledProperty") @@ -47,8 +38,7 @@ public open class CameraAttributesPractical : CameraAttributes() { } /** - * Objects further from the [Camera3D] by this amount will be blurred by the depth of field - * effect. Measured in meters. + * Objects further from the [Camera3D] by this amount will be blurred by the depth of field effect. Measured in meters. */ public final inline var dofBlurFarDistance: Float @JvmName("dofBlurFarDistanceProperty") @@ -59,10 +49,7 @@ public open class CameraAttributesPractical : CameraAttributes() { } /** - * When positive, distance over which (starting from [dofBlurFarDistance]) blur effect will scale - * from 0 to [dofBlurAmount]. When negative, uses physically-based scaling so depth of field effect - * will scale from 0 at [dofBlurFarDistance] and will increase in a physically accurate way as - * objects get further from the [Camera3D]. + * When positive, distance over which (starting from [dofBlurFarDistance]) blur effect will scale from 0 to [dofBlurAmount]. When negative, uses physically-based scaling so depth of field effect will scale from 0 at [dofBlurFarDistance] and will increase in a physically accurate way as objects get further from the [Camera3D]. */ public final inline var dofBlurFarTransition: Float @JvmName("dofBlurFarTransitionProperty") @@ -73,11 +60,9 @@ public open class CameraAttributesPractical : CameraAttributes() { } /** - * Enables depth of field blur for objects closer than [dofBlurNearDistance]. Strength of blur is - * controlled by [dofBlurAmount] and modulated by [dofBlurNearTransition]. + * Enables depth of field blur for objects closer than [dofBlurNearDistance]. Strength of blur is controlled by [dofBlurAmount] and modulated by [dofBlurNearTransition]. * - * **Note:** Depth of field blur is only supported in the Forward+ and Mobile rendering methods, - * not Compatibility. + * **Note:** Depth of field blur is only supported in the Forward+ and Mobile rendering methods, not Compatibility. */ public final inline var dofBlurNearEnabled: Boolean @JvmName("dofBlurNearEnabledProperty") @@ -88,8 +73,7 @@ public open class CameraAttributesPractical : CameraAttributes() { } /** - * Objects closer from the [Camera3D] by this amount will be blurred by the depth of field effect. - * Measured in meters. + * Objects closer from the [Camera3D] by this amount will be blurred by the depth of field effect. Measured in meters. */ public final inline var dofBlurNearDistance: Float @JvmName("dofBlurNearDistanceProperty") @@ -100,10 +84,7 @@ public open class CameraAttributesPractical : CameraAttributes() { } /** - * When positive, distance over which blur effect will scale from 0 to [dofBlurAmount], ending at - * [dofBlurNearDistance]. When negative, uses physically-based scaling so depth of field effect will - * scale from 0 at [dofBlurNearDistance] and will increase in a physically accurate way as objects - * get closer to the [Camera3D]. + * When positive, distance over which blur effect will scale from 0 to [dofBlurAmount], ending at [dofBlurNearDistance]. When negative, uses physically-based scaling so depth of field effect will scale from 0 at [dofBlurNearDistance] and will increase in a physically accurate way as objects get closer to the [Camera3D]. */ public final inline var dofBlurNearTransition: Float @JvmName("dofBlurNearTransitionProperty") @@ -114,9 +95,7 @@ public open class CameraAttributesPractical : CameraAttributes() { } /** - * Sets the maximum amount of blur. When using physically-based blur amounts, will instead act as - * a multiplier. High values lead to an increased amount of blurriness, but can be much more - * expensive to calculate. It is best to keep this as low as possible for a given art style. + * Sets the maximum amount of blur. When using physically-based blur amounts, will instead act as a multiplier. High values lead to an increased amount of blurriness, but can be much more expensive to calculate. It is best to keep this as low as possible for a given art style. */ public final inline var dofBlurAmount: Float @JvmName("dofBlurAmountProperty") @@ -127,10 +106,7 @@ public open class CameraAttributesPractical : CameraAttributes() { } /** - * The minimum sensitivity (in ISO) used when calculating auto exposure. When calculating scene - * average luminance, color values will be clamped to at least this value. This limits the - * auto-exposure from exposing above a certain brightness, resulting in a cut off point where the - * scene will remain dark. + * The minimum sensitivity (in ISO) used when calculating auto exposure. When calculating scene average luminance, color values will be clamped to at least this value. This limits the auto-exposure from exposing above a certain brightness, resulting in a cut off point where the scene will remain dark. */ public final inline var autoExposureMinSensitivity: Float @JvmName("autoExposureMinSensitivityProperty") @@ -141,10 +117,7 @@ public open class CameraAttributesPractical : CameraAttributes() { } /** - * The maximum sensitivity (in ISO) used when calculating auto exposure. When calculating scene - * average luminance, color values will be clamped to at least this value. This limits the - * auto-exposure from exposing below a certain brightness, resulting in a cut off point where the - * scene will remain bright. + * The maximum sensitivity (in ISO) used when calculating auto exposure. When calculating scene average luminance, color values will be clamped to at least this value. This limits the auto-exposure from exposing below a certain brightness, resulting in a cut off point where the scene will remain bright. */ public final inline var autoExposureMaxSensitivity: Float @JvmName("autoExposureMaxSensitivityProperty") @@ -154,11 +127,11 @@ public open class CameraAttributesPractical : CameraAttributes() { setAutoExposureMaxSensitivity(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(131, scriptIndex) } - public final fun setDofBlurFarEnabled(enabled: Boolean): Unit { + public final fun setDofBlurFarEnabled(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setDofBlurFarEnabledPtr, NIL) } @@ -169,7 +142,7 @@ public open class CameraAttributesPractical : CameraAttributes() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setDofBlurFarDistance(distance: Float): Unit { + public final fun setDofBlurFarDistance(distance: Float) { TransferContext.writeArguments(DOUBLE to distance.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setDofBlurFarDistancePtr, NIL) } @@ -180,7 +153,7 @@ public open class CameraAttributesPractical : CameraAttributes() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setDofBlurFarTransition(distance: Float): Unit { + public final fun setDofBlurFarTransition(distance: Float) { TransferContext.writeArguments(DOUBLE to distance.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setDofBlurFarTransitionPtr, NIL) } @@ -191,7 +164,7 @@ public open class CameraAttributesPractical : CameraAttributes() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setDofBlurNearEnabled(enabled: Boolean): Unit { + public final fun setDofBlurNearEnabled(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setDofBlurNearEnabledPtr, NIL) } @@ -202,7 +175,7 @@ public open class CameraAttributesPractical : CameraAttributes() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setDofBlurNearDistance(distance: Float): Unit { + public final fun setDofBlurNearDistance(distance: Float) { TransferContext.writeArguments(DOUBLE to distance.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setDofBlurNearDistancePtr, NIL) } @@ -213,7 +186,7 @@ public open class CameraAttributesPractical : CameraAttributes() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setDofBlurNearTransition(distance: Float): Unit { + public final fun setDofBlurNearTransition(distance: Float) { TransferContext.writeArguments(DOUBLE to distance.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setDofBlurNearTransitionPtr, NIL) } @@ -224,7 +197,7 @@ public open class CameraAttributesPractical : CameraAttributes() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setDofBlurAmount(amount: Float): Unit { + public final fun setDofBlurAmount(amount: Float) { TransferContext.writeArguments(DOUBLE to amount.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setDofBlurAmountPtr, NIL) } @@ -235,7 +208,7 @@ public open class CameraAttributesPractical : CameraAttributes() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setAutoExposureMaxSensitivity(maxSensitivity: Float): Unit { + public final fun setAutoExposureMaxSensitivity(maxSensitivity: Float) { TransferContext.writeArguments(DOUBLE to maxSensitivity.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setAutoExposureMaxSensitivityPtr, NIL) } @@ -246,7 +219,7 @@ public open class CameraAttributesPractical : CameraAttributes() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setAutoExposureMinSensitivity(minSensitivity: Float): Unit { + public final fun setAutoExposureMinSensitivity(minSensitivity: Float) { TransferContext.writeArguments(DOUBLE to minSensitivity.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setAutoExposureMinSensitivityPtr, NIL) } @@ -261,57 +234,57 @@ public open class CameraAttributesPractical : CameraAttributes() { public object MethodBindings { internal val setDofBlurFarEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPractical", "set_dof_blur_far_enabled", 2586408642) + TypeManager.getMethodBindPtr("CameraAttributesPractical", "set_dof_blur_far_enabled", 2_586_408_642) internal val isDofBlurFarEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPractical", "is_dof_blur_far_enabled", 36873697) + TypeManager.getMethodBindPtr("CameraAttributesPractical", "is_dof_blur_far_enabled", 36_873_697) internal val setDofBlurFarDistancePtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPractical", "set_dof_blur_far_distance", 373806689) + TypeManager.getMethodBindPtr("CameraAttributesPractical", "set_dof_blur_far_distance", 373_806_689) internal val getDofBlurFarDistancePtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPractical", "get_dof_blur_far_distance", 1740695150) + TypeManager.getMethodBindPtr("CameraAttributesPractical", "get_dof_blur_far_distance", 1_740_695_150) internal val setDofBlurFarTransitionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPractical", "set_dof_blur_far_transition", 373806689) + TypeManager.getMethodBindPtr("CameraAttributesPractical", "set_dof_blur_far_transition", 373_806_689) internal val getDofBlurFarTransitionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPractical", "get_dof_blur_far_transition", 1740695150) + TypeManager.getMethodBindPtr("CameraAttributesPractical", "get_dof_blur_far_transition", 1_740_695_150) internal val setDofBlurNearEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPractical", "set_dof_blur_near_enabled", 2586408642) + TypeManager.getMethodBindPtr("CameraAttributesPractical", "set_dof_blur_near_enabled", 2_586_408_642) internal val isDofBlurNearEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPractical", "is_dof_blur_near_enabled", 36873697) + TypeManager.getMethodBindPtr("CameraAttributesPractical", "is_dof_blur_near_enabled", 36_873_697) internal val setDofBlurNearDistancePtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPractical", "set_dof_blur_near_distance", 373806689) + TypeManager.getMethodBindPtr("CameraAttributesPractical", "set_dof_blur_near_distance", 373_806_689) internal val getDofBlurNearDistancePtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPractical", "get_dof_blur_near_distance", 1740695150) + TypeManager.getMethodBindPtr("CameraAttributesPractical", "get_dof_blur_near_distance", 1_740_695_150) internal val setDofBlurNearTransitionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPractical", "set_dof_blur_near_transition", 373806689) + TypeManager.getMethodBindPtr("CameraAttributesPractical", "set_dof_blur_near_transition", 373_806_689) internal val getDofBlurNearTransitionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPractical", "get_dof_blur_near_transition", 1740695150) + TypeManager.getMethodBindPtr("CameraAttributesPractical", "get_dof_blur_near_transition", 1_740_695_150) internal val setDofBlurAmountPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPractical", "set_dof_blur_amount", 373806689) + TypeManager.getMethodBindPtr("CameraAttributesPractical", "set_dof_blur_amount", 373_806_689) internal val getDofBlurAmountPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPractical", "get_dof_blur_amount", 1740695150) + TypeManager.getMethodBindPtr("CameraAttributesPractical", "get_dof_blur_amount", 1_740_695_150) internal val setAutoExposureMaxSensitivityPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPractical", "set_auto_exposure_max_sensitivity", 373806689) + TypeManager.getMethodBindPtr("CameraAttributesPractical", "set_auto_exposure_max_sensitivity", 373_806_689) internal val getAutoExposureMaxSensitivityPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPractical", "get_auto_exposure_max_sensitivity", 1740695150) + TypeManager.getMethodBindPtr("CameraAttributesPractical", "get_auto_exposure_max_sensitivity", 1_740_695_150) internal val setAutoExposureMinSensitivityPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPractical", "set_auto_exposure_min_sensitivity", 373806689) + TypeManager.getMethodBindPtr("CameraAttributesPractical", "set_auto_exposure_min_sensitivity", 373_806_689) internal val getAutoExposureMinSensitivityPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraAttributesPractical", "get_auto_exposure_min_sensitivity", 1740695150) + TypeManager.getMethodBindPtr("CameraAttributesPractical", "get_auto_exposure_min_sensitivity", 1_740_695_150) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CameraFeed.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CameraFeed.kt index 483b77c0b4..52b22b8fb0 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CameraFeed.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CameraFeed.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -35,16 +32,11 @@ import kotlin.Unit import kotlin.jvm.JvmName /** - * A camera feed gives you access to a single physical camera attached to your device. When enabled, - * Godot will start capturing frames from the camera which can then be used. See also [CameraServer]. + * A camera feed gives you access to a single physical camera attached to your device. When enabled, Godot will start capturing frames from the camera which can then be used. See also [CameraServer]. * - * **Note:** Many cameras will return YCbCr images which are split into two textures and need to be - * combined in a shader. Godot does this automatically for you if you set the environment to show the - * camera image in the background. + * **Note:** Many cameras will return YCbCr images which are split into two textures and need to be combined in a shader. Godot does this automatically for you if you set the environment to show the camera image in the background. * - * **Note:** This class is currently only implemented on Linux, macOS, and iOS. On other platforms - * no [CameraFeed]s will be available. To get a [CameraFeed] on iOS, the camera plugin from - * [url=https://github.com/godotengine/godot-ios-plugins]godot-ios-plugins[/url] is required. + * **Note:** This class is currently only implemented on Linux, macOS, and iOS. On other platforms no [CameraFeed]s will be available. To get a [CameraFeed] on iOS, the camera plugin from [url=https://github.com/godotengine/godot-ios-plugins]godot-ios-plugins[/url] is required. */ @GodotBaseType public open class CameraFeed : RefCounted() { @@ -73,11 +65,8 @@ public open class CameraFeed : RefCounted() { * The transform applied to the camera's image. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var feedTransform: Transform2D @@ -95,7 +84,7 @@ public open class CameraFeed : RefCounted() { @JvmName("formatsProperty") get() = getFormats() - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(132, scriptIndex) } @@ -113,8 +102,7 @@ public open class CameraFeed : RefCounted() { * The transform applied to the camera's image. */ @CoreTypeHelper - public final fun feedTransformMutate(block: Transform2D.() -> Unit): Transform2D = - feedTransform.apply { + public final fun feedTransformMutate(block: Transform2D.() -> Unit): Transform2D = feedTransform.apply { block(this) feedTransform = this } @@ -129,7 +117,7 @@ public open class CameraFeed : RefCounted() { /** * Called when the camera feed is deactivated. */ - public open fun _deactivateFeed(): Unit { + public open fun _deactivateFeed() { throw NotImplementedError("CameraFeed::_deactivateFeed is not implemented.") } @@ -148,7 +136,7 @@ public open class CameraFeed : RefCounted() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setActive(active: Boolean): Unit { + public final fun setActive(active: Boolean) { TransferContext.writeArguments(BOOL to active) TransferContext.callMethod(ptr, MethodBindings.setActivePtr, NIL) } @@ -165,7 +153,7 @@ public open class CameraFeed : RefCounted() { /** * Sets the camera's name. */ - public final fun setName(name: String): Unit { + public final fun setName(name: String) { TransferContext.writeArguments(STRING to name) TransferContext.callMethod(ptr, MethodBindings.setNamePtr, NIL) } @@ -182,7 +170,7 @@ public open class CameraFeed : RefCounted() { /** * Sets the position of this camera. */ - public final fun setPosition(position: FeedPosition): Unit { + public final fun setPosition(position: FeedPosition) { TransferContext.writeArguments(LONG to position.id) TransferContext.callMethod(ptr, MethodBindings.setPositionPtr, NIL) } @@ -193,7 +181,7 @@ public open class CameraFeed : RefCounted() { return (TransferContext.readReturnValue(TRANSFORM2D) as Transform2D) } - public final fun setTransform(transform: Transform2D): Unit { + public final fun setTransform(transform: Transform2D) { TransferContext.writeArguments(TRANSFORM2D to transform) TransferContext.callMethod(ptr, MethodBindings.setTransformPtr, NIL) } @@ -201,7 +189,7 @@ public open class CameraFeed : RefCounted() { /** * Sets RGB image for this feed. */ - public final fun setRgbImage(rgbImage: Image?): Unit { + public final fun setRgbImage(rgbImage: Image?) { TransferContext.writeArguments(OBJECT to rgbImage) TransferContext.callMethod(ptr, MethodBindings.setRgbImagePtr, NIL) } @@ -209,7 +197,7 @@ public open class CameraFeed : RefCounted() { /** * Sets YCbCr image for this feed. */ - public final fun setYcbcrImage(ycbcrImage: Image?): Unit { + public final fun setYcbcrImage(ycbcrImage: Image?) { TransferContext.writeArguments(OBJECT to ycbcrImage) TransferContext.callMethod(ptr, MethodBindings.setYcbcrImagePtr, NIL) } @@ -217,14 +205,13 @@ public open class CameraFeed : RefCounted() { /** * Sets the feed as external feed provided by another library. */ - public final fun setExternal(width: Int, height: Int): Unit { + public final fun setExternal(width: Int, height: Int) { TransferContext.writeArguments(LONG to width.toLong(), LONG to height.toLong()) TransferContext.callMethod(ptr, MethodBindings.setExternalPtr, NIL) } /** - * Returns the texture backend ID (usable by some external libraries that need a handle to a - * texture to write data). + * Returns the texture backend ID (usable by some external libraries that need a handle to a texture to write data). */ public final fun getTextureTexId(feedImageType: CameraServer.FeedImage): Long { TransferContext.writeArguments(LONG to feedImageType.id) @@ -248,9 +235,7 @@ public open class CameraFeed : RefCounted() { } /** - * Sets the feed format parameters for the given index in the [formats] array. Returns `true` on - * success. By default YUYV encoded stream is transformed to FEED_RGB. YUYV encoded stream output - * format can be changed with [parameters].output value: + * Sets the feed format parameters for the given index in the [formats] array. Returns `true` on success. By default YUYV encoded stream is transformed to FEED_RGB. YUYV encoded stream output format can be changed with [parameters].output value: * * `separate` will result in FEED_YCBCR_SEP * @@ -330,51 +315,51 @@ public open class CameraFeed : RefCounted() { public object MethodBindings { internal val getIdPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraFeed", "get_id", 3905245786) + TypeManager.getMethodBindPtr("CameraFeed", "get_id", 3_905_245_786) internal val isActivePtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraFeed", "is_active", 36873697) + TypeManager.getMethodBindPtr("CameraFeed", "is_active", 36_873_697) internal val setActivePtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraFeed", "set_active", 2586408642) + TypeManager.getMethodBindPtr("CameraFeed", "set_active", 2_586_408_642) internal val getNamePtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraFeed", "get_name", 201670096) + TypeManager.getMethodBindPtr("CameraFeed", "get_name", 201_670_096) internal val setNamePtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraFeed", "set_name", 83702148) + TypeManager.getMethodBindPtr("CameraFeed", "set_name", 83_702_148) internal val getPositionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraFeed", "get_position", 2711679033) + TypeManager.getMethodBindPtr("CameraFeed", "get_position", 2_711_679_033) internal val setPositionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraFeed", "set_position", 611162623) + TypeManager.getMethodBindPtr("CameraFeed", "set_position", 611_162_623) internal val getTransformPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraFeed", "get_transform", 3814499831) + TypeManager.getMethodBindPtr("CameraFeed", "get_transform", 3_814_499_831) internal val setTransformPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraFeed", "set_transform", 2761652528) + TypeManager.getMethodBindPtr("CameraFeed", "set_transform", 2_761_652_528) internal val setRgbImagePtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraFeed", "set_rgb_image", 532598488) + TypeManager.getMethodBindPtr("CameraFeed", "set_rgb_image", 532_598_488) internal val setYcbcrImagePtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraFeed", "set_ycbcr_image", 532598488) + TypeManager.getMethodBindPtr("CameraFeed", "set_ycbcr_image", 532_598_488) internal val setExternalPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraFeed", "set_external", 3937882851) + TypeManager.getMethodBindPtr("CameraFeed", "set_external", 3_937_882_851) internal val getTextureTexIdPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraFeed", "get_texture_tex_id", 1135699418) + TypeManager.getMethodBindPtr("CameraFeed", "get_texture_tex_id", 1_135_699_418) internal val getDatatypePtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraFeed", "get_datatype", 1477782850) + TypeManager.getMethodBindPtr("CameraFeed", "get_datatype", 1_477_782_850) internal val getFormatsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraFeed", "get_formats", 3995934104) + TypeManager.getMethodBindPtr("CameraFeed", "get_formats", 3_995_934_104) internal val setFormatPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraFeed", "set_format", 31872775) + TypeManager.getMethodBindPtr("CameraFeed", "set_format", 31_872_775) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CameraServer.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CameraServer.kt index 2e3c84cc15..4979a448ed 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CameraServer.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CameraServer.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -19,18 +16,14 @@ import godot.core.VariantParser.OBJECT import kotlin.Int import kotlin.Long import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmStatic /** - * The [CameraServer] keeps track of different cameras accessible in Godot. These are external - * cameras such as webcams or the cameras on your phone. + * The [CameraServer] keeps track of different cameras accessible in Godot. These are external cameras such as webcams or the cameras on your phone. * * It is notably used to provide AR modules with a video feed from the camera. * - * **Note:** This class is currently only implemented on Linux, macOS, and iOS. On other platforms - * no [CameraFeed]s will be available. To get a [CameraFeed] on iOS, the camera plugin from - * [url=https://github.com/godotengine/godot-ios-plugins]godot-ios-plugins[/url] is required. + * **Note:** This class is currently only implemented on Linux, macOS, and iOS. On other platforms no [CameraFeed]s will be available. To get a [CameraFeed] on iOS, the camera plugin from [url=https://github.com/godotengine/godot-ios-plugins]godot-ios-plugins[/url] is required. */ @GodotBaseType public object CameraServer : Object() { @@ -46,7 +39,7 @@ public object CameraServer : Object() { @JvmStatic public val cameraFeedRemoved: Signal1 by Signal1 - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { getSingleton(1) } @@ -84,7 +77,7 @@ public object CameraServer : Object() { * Adds the camera [feed] to the camera server. */ @JvmStatic - public final fun addFeed(feed: CameraFeed?): Unit { + public final fun addFeed(feed: CameraFeed?) { TransferContext.writeArguments(OBJECT to feed) TransferContext.callMethod(ptr, MethodBindings.addFeedPtr, NIL) } @@ -93,7 +86,7 @@ public object CameraServer : Object() { * Removes the specified camera [feed]. */ @JvmStatic - public final fun removeFeed(feed: CameraFeed?): Unit { + public final fun removeFeed(feed: CameraFeed?) { TransferContext.writeArguments(OBJECT to feed) TransferContext.callMethod(ptr, MethodBindings.removeFeedPtr, NIL) } @@ -131,18 +124,18 @@ public object CameraServer : Object() { public object MethodBindings { internal val getFeedPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraServer", "get_feed", 361927068) + TypeManager.getMethodBindPtr("CameraServer", "get_feed", 361_927_068) internal val getFeedCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraServer", "get_feed_count", 2455072627) + TypeManager.getMethodBindPtr("CameraServer", "get_feed_count", 2_455_072_627) internal val feedsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraServer", "feeds", 2915620761) + TypeManager.getMethodBindPtr("CameraServer", "feeds", 2_915_620_761) internal val addFeedPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraServer", "add_feed", 3204782488) + TypeManager.getMethodBindPtr("CameraServer", "add_feed", 3_204_782_488) internal val removeFeedPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraServer", "remove_feed", 3204782488) + TypeManager.getMethodBindPtr("CameraServer", "remove_feed", 3_204_782_488) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CameraTexture.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CameraTexture.kt index 556342eea1..e8b501b25b 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CameraTexture.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CameraTexture.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -18,7 +15,6 @@ import kotlin.Int import kotlin.Long import kotlin.NotImplementedError import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** @@ -40,8 +36,7 @@ public open class CameraTexture : Texture2D() { } /** - * Which image within the [CameraFeed] we want access to, important if the camera image is split - * in a Y and CbCr component. + * Which image within the [CameraFeed] we want access to, important if the camera image is split in a Y and CbCr component. */ public final inline var whichFeed: CameraServer.FeedImage @JvmName("whichFeedProperty") @@ -62,11 +57,11 @@ public open class CameraTexture : Texture2D() { setCameraActive(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(134, scriptIndex) } - public final fun setCameraFeedId(feedId: Int): Unit { + public final fun setCameraFeedId(feedId: Int) { TransferContext.writeArguments(LONG to feedId.toLong()) TransferContext.callMethod(ptr, MethodBindings.setCameraFeedIdPtr, NIL) } @@ -77,7 +72,7 @@ public open class CameraTexture : Texture2D() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setWhichFeed(whichFeed: CameraServer.FeedImage): Unit { + public final fun setWhichFeed(whichFeed: CameraServer.FeedImage) { TransferContext.writeArguments(LONG to whichFeed.id) TransferContext.callMethod(ptr, MethodBindings.setWhichFeedPtr, NIL) } @@ -88,7 +83,7 @@ public open class CameraTexture : Texture2D() { return CameraServer.FeedImage.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setCameraActive(active: Boolean): Unit { + public final fun setCameraActive(active: Boolean) { TransferContext.writeArguments(BOOL to active) TransferContext.callMethod(ptr, MethodBindings.setCameraActivePtr, NIL) } @@ -102,14 +97,14 @@ public open class CameraTexture : Texture2D() { /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _getWidth(): Int { + override fun _getWidth(): Int { throw NotImplementedError("CameraTexture::_getWidth can't be called from the JVM.") } /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _getHeight(): Int { + override fun _getHeight(): Int { throw NotImplementedError("CameraTexture::_getHeight can't be called from the JVM.") } @@ -117,21 +112,21 @@ public open class CameraTexture : Texture2D() { public object MethodBindings { internal val setCameraFeedIdPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraTexture", "set_camera_feed_id", 1286410249) + TypeManager.getMethodBindPtr("CameraTexture", "set_camera_feed_id", 1_286_410_249) internal val getCameraFeedIdPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraTexture", "get_camera_feed_id", 3905245786) + TypeManager.getMethodBindPtr("CameraTexture", "get_camera_feed_id", 3_905_245_786) internal val setWhichFeedPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraTexture", "set_which_feed", 1595299230) + TypeManager.getMethodBindPtr("CameraTexture", "set_which_feed", 1_595_299_230) internal val getWhichFeedPtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraTexture", "get_which_feed", 91039457) + TypeManager.getMethodBindPtr("CameraTexture", "get_which_feed", 91_039_457) internal val setCameraActivePtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraTexture", "set_camera_active", 2586408642) + TypeManager.getMethodBindPtr("CameraTexture", "set_camera_active", 2_586_408_642) internal val getCameraActivePtr: VoidPtr = - TypeManager.getMethodBindPtr("CameraTexture", "get_camera_active", 36873697) + TypeManager.getMethodBindPtr("CameraTexture", "get_camera_active", 36_873_697) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CanvasGroup.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CanvasGroup.kt index 983486c9e2..6c25c9ce4e 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CanvasGroup.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CanvasGroup.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -18,17 +15,12 @@ import kotlin.Double import kotlin.Float import kotlin.Int import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * Child [CanvasItem] nodes of a [CanvasGroup] are drawn as a single object. It allows to e.g. draw - * overlapping translucent 2D nodes without blending (set [CanvasItem.selfModulate] property of - * [CanvasGroup] to achieve this effect). + * Child [CanvasItem] nodes of a [CanvasGroup] are drawn as a single object. It allows to e.g. draw overlapping translucent 2D nodes without blending (set [CanvasItem.selfModulate] property of [CanvasGroup] to achieve this effect). * - * **Note:** The [CanvasGroup] uses a custom shader to read from the backbuffer to draw its - * children. Assigning a [Material] to the [CanvasGroup] overrides the builtin shader. To duplicate the - * behavior of the builtin shader in a custom [Shader] use the following: + * **Note:** The [CanvasGroup] uses a custom shader to read from the backbuffer to draw its children. Assigning a [Material] to the [CanvasGroup] overrides the builtin shader. To duplicate the behavior of the builtin shader in a custom [Shader] use the following: * * ``` * shader_type canvas_item; @@ -47,18 +39,12 @@ import kotlin.jvm.JvmName * } * ``` * - * **Note:** Since [CanvasGroup] and [CanvasItem.clipChildren] both utilize the backbuffer, children - * of a [CanvasGroup] who have their [CanvasItem.clipChildren] set to anything other than - * [CanvasItem.CLIP_CHILDREN_DISABLED] will not function correctly. + * **Note:** Since [CanvasGroup] and [CanvasItem.clipChildren] both utilize the backbuffer, children of a [CanvasGroup] who have their [CanvasItem.clipChildren] set to anything other than [CanvasItem.CLIP_CHILDREN_DISABLED] will not function correctly. */ @GodotBaseType public open class CanvasGroup : Node2D() { /** - * Sets the size of a margin used to expand the drawable rect of this [CanvasGroup]. The size of - * the [CanvasGroup] is determined by fitting a rect around its children then expanding that rect by - * [fitMargin]. This increases both the backbuffer area used and the area covered by the - * [CanvasGroup] both of which can reduce performance. This should be kept as small as possible and - * should only be expanded when an increased size is needed (e.g. for custom shader effects). + * Sets the size of a margin used to expand the drawable rect of this [CanvasGroup]. The size of the [CanvasGroup] is determined by fitting a rect around its children then expanding that rect by [fitMargin]. This increases both the backbuffer area used and the area covered by the [CanvasGroup] both of which can reduce performance. This should be kept as small as possible and should only be expanded when an increased size is needed (e.g. for custom shader effects). */ public final inline var fitMargin: Float @JvmName("fitMarginProperty") @@ -69,12 +55,7 @@ public open class CanvasGroup : Node2D() { } /** - * Sets the size of the margin used to expand the clearing rect of this [CanvasGroup]. This - * expands the area of the backbuffer that will be used by the [CanvasGroup]. A smaller margin will - * reduce the area of the backbuffer used which can increase performance, however if [useMipmaps] is - * enabled, a small margin may result in mipmap errors at the edge of the [CanvasGroup]. Accordingly, - * this should be left as small as possible, but should be increased if artifacts appear along the - * edges of the canvas group. + * Sets the size of the margin used to expand the clearing rect of this [CanvasGroup]. This expands the area of the backbuffer that will be used by the [CanvasGroup]. A smaller margin will reduce the area of the backbuffer used which can increase performance, however if [useMipmaps] is enabled, a small margin may result in mipmap errors at the edge of the [CanvasGroup]. Accordingly, this should be left as small as possible, but should be increased if artifacts appear along the edges of the canvas group. */ public final inline var clearMargin: Float @JvmName("clearMarginProperty") @@ -85,9 +66,7 @@ public open class CanvasGroup : Node2D() { } /** - * If `true`, calculates mipmaps for the backbuffer before drawing the [CanvasGroup] so that - * mipmaps can be used in a custom [ShaderMaterial] attached to the [CanvasGroup]. Generating mipmaps - * has a performance cost so this should not be enabled unless required. + * If `true`, calculates mipmaps for the backbuffer before drawing the [CanvasGroup] so that mipmaps can be used in a custom [ShaderMaterial] attached to the [CanvasGroup]. Generating mipmaps has a performance cost so this should not be enabled unless required. */ public final inline var useMipmaps: Boolean @JvmName("useMipmapsProperty") @@ -97,11 +76,11 @@ public open class CanvasGroup : Node2D() { setUseMipmaps(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(135, scriptIndex) } - public final fun setFitMargin(fitMargin: Float): Unit { + public final fun setFitMargin(fitMargin: Float) { TransferContext.writeArguments(DOUBLE to fitMargin.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setFitMarginPtr, NIL) } @@ -112,7 +91,7 @@ public open class CanvasGroup : Node2D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setClearMargin(clearMargin: Float): Unit { + public final fun setClearMargin(clearMargin: Float) { TransferContext.writeArguments(DOUBLE to clearMargin.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setClearMarginPtr, NIL) } @@ -123,7 +102,7 @@ public open class CanvasGroup : Node2D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setUseMipmaps(useMipmaps: Boolean): Unit { + public final fun setUseMipmaps(useMipmaps: Boolean) { TransferContext.writeArguments(BOOL to useMipmaps) TransferContext.callMethod(ptr, MethodBindings.setUseMipmapsPtr, NIL) } @@ -138,21 +117,21 @@ public open class CanvasGroup : Node2D() { public object MethodBindings { internal val setFitMarginPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasGroup", "set_fit_margin", 373806689) + TypeManager.getMethodBindPtr("CanvasGroup", "set_fit_margin", 373_806_689) internal val getFitMarginPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasGroup", "get_fit_margin", 1740695150) + TypeManager.getMethodBindPtr("CanvasGroup", "get_fit_margin", 1_740_695_150) internal val setClearMarginPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasGroup", "set_clear_margin", 373806689) + TypeManager.getMethodBindPtr("CanvasGroup", "set_clear_margin", 373_806_689) internal val getClearMarginPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasGroup", "get_clear_margin", 1740695150) + TypeManager.getMethodBindPtr("CanvasGroup", "get_clear_margin", 1_740_695_150) internal val setUseMipmapsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasGroup", "set_use_mipmaps", 2586408642) + TypeManager.getMethodBindPtr("CanvasGroup", "set_use_mipmaps", 2_586_408_642) internal val isUsingMipmapsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasGroup", "is_using_mipmaps", 36873697) + TypeManager.getMethodBindPtr("CanvasGroup", "is_using_mipmaps", 36_873_697) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CanvasItem.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CanvasItem.kt index efe469e6cd..e23ebbc993 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CanvasItem.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CanvasItem.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -52,66 +49,44 @@ import kotlin.jvm.JvmName import kotlin.jvm.JvmOverloads /** - * Abstract base class for everything in 2D space. Canvas items are laid out in a tree; children - * inherit and extend their parent's transform. [CanvasItem] is extended by [Control] for GUI-related - * nodes, and by [Node2D] for 2D game objects. + * Abstract base class for everything in 2D space. Canvas items are laid out in a tree; children inherit and extend their parent's transform. [CanvasItem] is extended by [Control] for GUI-related nodes, and by [Node2D] for 2D game objects. * - * Any [CanvasItem] can draw. For this, [queueRedraw] is called by the engine, then - * [NOTIFICATION_DRAW] will be received on idle time to request a redraw. Because of this, canvas items - * don't need to be redrawn on every frame, improving the performance significantly. Several functions - * for drawing on the [CanvasItem] are provided (see `draw_*` functions). However, they can only be - * used inside [_draw], its corresponding [Object.Notification] or methods connected to the [signal - * draw] signal. + * Any [CanvasItem] can draw. For this, [queueRedraw] is called by the engine, then [NOTIFICATION_DRAW] will be received on idle time to request a redraw. Because of this, canvas items don't need to be redrawn on every frame, improving the performance significantly. Several functions for drawing on the [CanvasItem] are provided (see `draw_*` functions). However, they can only be used inside [_draw], its corresponding [Object.Notification] or methods connected to the [signal draw] signal. * - * Canvas items are drawn in tree order on their canvas layer. By default, children are on top of - * their parents, so a root [CanvasItem] will be drawn behind everything. This behavior can be changed - * on a per-item basis. + * Canvas items are drawn in tree order on their canvas layer. By default, children are on top of their parents, so a root [CanvasItem] will be drawn behind everything. This behavior can be changed on a per-item basis. * - * A [CanvasItem] can be hidden, which will also hide its children. By adjusting various other - * properties of a [CanvasItem], you can also modulate its color (via [modulate] or [selfModulate]), - * change its Z-index, blend mode, and more. + * A [CanvasItem] can be hidden, which will also hide its children. By adjusting various other properties of a [CanvasItem], you can also modulate its color (via [modulate] or [selfModulate]), change its Z-index, blend mode, and more. * - * Note that properties like transform, modulation, and visibility are only propagated to *direct* - * [CanvasItem] child nodes. If there is a non-[CanvasItem] node in between, like [Node] or - * [AnimationPlayer], the [CanvasItem] nodes below will have an independent position and [modulate] - * chain. See also [topLevel]. + * Note that properties like transform, modulation, and visibility are only propagated to *direct* [CanvasItem] child nodes. If there is a non-[CanvasItem] node in between, like [Node] or [AnimationPlayer], the [CanvasItem] nodes below will have an independent position and [modulate] chain. See also [topLevel]. */ @GodotBaseType public open class CanvasItem internal constructor() : Node() { /** - * Emitted when the [CanvasItem] must redraw, *after* the related [NOTIFICATION_DRAW] - * notification, and *before* [_draw] is called. + * Emitted when the [CanvasItem] must redraw, *after* the related [NOTIFICATION_DRAW] notification, and *before* [_draw] is called. * * **Note:** Deferred connections do not allow drawing through the `draw_*` methods. */ public val draw: Signal0 by Signal0 /** - * Emitted when the [CanvasItem]'s visibility changes, either because its own [visible] property - * changed or because its visibility in the tree changed (see [isVisibleInTree]). + * Emitted when the [CanvasItem]'s visibility changes, either because its own [visible] property changed or because its visibility in the tree changed (see [isVisibleInTree]). */ public val visibilityChanged: Signal0 by Signal0 /** - * Emitted when the [CanvasItem] is hidden, i.e. it's no longer visible in the tree (see - * [isVisibleInTree]). + * Emitted when the [CanvasItem] is hidden, i.e. it's no longer visible in the tree (see [isVisibleInTree]). */ public val hidden: Signal0 by Signal0 /** - * Emitted when the [CanvasItem]'s boundaries (position or size) change, or when an action took - * place that may have affected these boundaries (e.g. changing [Sprite2D.texture]). + * Emitted when the [CanvasItem]'s boundaries (position or size) change, or when an action took place that may have affected these boundaries (e.g. changing [Sprite2D.texture]). */ public val itemRectChanged: Signal0 by Signal0 /** - * If `true`, this [CanvasItem] may be drawn. Whether this [CanvasItem] is actually drawn depends - * on the visibility of all of its [CanvasItem] ancestors. In other words: this [CanvasItem] will be - * drawn when [isVisibleInTree] returns `true` and all [CanvasItem] ancestors share at least one - * [visibilityLayer] with this [CanvasItem]. + * If `true`, this [CanvasItem] may be drawn. Whether this [CanvasItem] is actually drawn depends on the visibility of all of its [CanvasItem] ancestors. In other words: this [CanvasItem] will be drawn when [isVisibleInTree] returns `true` and all [CanvasItem] ancestors share at least one [visibilityLayer] with this [CanvasItem]. * - * **Note:** For controls that inherit [Popup], the correct way to make them visible is to call - * one of the multiple `popup*()` functions instead. + * **Note:** For controls that inherit [Popup], the correct way to make them visible is to call one of the multiple `popup*()` functions instead. */ public final inline var visible: Boolean @JvmName("visibleProperty") @@ -122,15 +97,11 @@ public open class CanvasItem internal constructor() : Node() { } /** - * The color applied to this [CanvasItem]. This property does affect child [CanvasItem]s, unlike - * [selfModulate] which only affects the node itself. + * The color applied to this [CanvasItem]. This property does affect child [CanvasItem]s, unlike [selfModulate] which only affects the node itself. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var modulate: Color @@ -142,19 +113,13 @@ public open class CanvasItem internal constructor() : Node() { } /** - * The color applied to this [CanvasItem]. This property does **not** affect child [CanvasItem]s, - * unlike [modulate] which affects both the node itself and its children. + * The color applied to this [CanvasItem]. This property does **not** affect child [CanvasItem]s, unlike [modulate] which affects both the node itself and its children. * - * **Note:** Internal children (e.g. sliders in [ColorPicker] or tab bar in [TabContainer]) are - * also not affected by this property (see `include_internal` parameter of [Node.getChild] and other - * similar methods). + * **Note:** Internal children (e.g. sliders in [ColorPicker] or tab bar in [TabContainer]) are also not affected by this property (see `include_internal` parameter of [Node.getChild] and other similar methods). * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var selfModulate: Color @@ -177,10 +142,7 @@ public open class CanvasItem internal constructor() : Node() { } /** - * If `true`, this [CanvasItem] will *not* inherit its transform from parent [CanvasItem]s. Its - * draw order will also be changed to make it draw on top of other [CanvasItem]s that do not have - * [topLevel] set to `true`. The [CanvasItem] will effectively act as if it was placed as a child of - * a bare [Node]. + * If `true`, this [CanvasItem] will *not* inherit its transform from parent [CanvasItem]s. Its draw order will also be changed to make it draw on top of other [CanvasItem]s that do not have [topLevel] set to `true`. The [CanvasItem] will effectively act as if it was placed as a child of a bare [Node]. */ public final inline var topLevel: Boolean @JvmName("topLevelProperty") @@ -193,9 +155,7 @@ public open class CanvasItem internal constructor() : Node() { /** * Allows the current node to clip child nodes, essentially acting as a mask. * - * **Note:** Clipping nodes cannot be nested or placed within [CanvasGroup]s. If an ancestor of - * this node clips its children or is a [CanvasGroup], then this node's clip mode should be set to - * [CLIP_CHILDREN_DISABLED] to avoid unexpected behavior. + * **Note:** Clipping nodes cannot be nested or placed within [CanvasGroup]s. If an ancestor of this node clips its children or is a [CanvasGroup], then this node's clip mode should be set to [CLIP_CHILDREN_DISABLED] to avoid unexpected behavior. */ public final inline var clipChildren: ClipChildrenMode @JvmName("clipChildrenProperty") @@ -217,9 +177,7 @@ public open class CanvasItem internal constructor() : Node() { } /** - * The rendering layer in which this [CanvasItem] is rendered by [Viewport] nodes. A [Viewport] - * will render a [CanvasItem] if it and all its parents share a layer with the [Viewport]'s canvas - * cull mask. + * The rendering layer in which this [CanvasItem] is rendered by [Viewport] nodes. A [Viewport] will render a [CanvasItem] if it and all its parents share a layer with the [Viewport]'s canvas cull mask. */ public final inline var visibilityLayer: Long @JvmName("visibilityLayerProperty") @@ -230,13 +188,9 @@ public open class CanvasItem internal constructor() : Node() { } /** - * Controls the order in which the nodes render. A node with a higher Z index will display in - * front of others. Must be between [RenderingServer.CANVAS_ITEM_Z_MIN] and - * [RenderingServer.CANVAS_ITEM_Z_MAX] (inclusive). + * Controls the order in which the nodes render. A node with a higher Z index will display in front of others. Must be between [RenderingServer.CANVAS_ITEM_Z_MIN] and [RenderingServer.CANVAS_ITEM_Z_MAX] (inclusive). * - * **Note:** Changing the Z index of a [Control] only affects the drawing order, not the order in - * which input events are handled. This can be useful to implement certain UI animations, e.g. a menu - * where hovered items are scaled and should overlap others. + * **Note:** Changing the Z index of a [Control] only affects the drawing order, not the order in which input events are handled. This can be useful to implement certain UI animations, e.g. a menu where hovered items are scaled and should overlap others. */ public final inline var zIndex: Int @JvmName("zIndexProperty") @@ -247,8 +201,7 @@ public open class CanvasItem internal constructor() : Node() { } /** - * If `true`, the node's Z index is relative to its parent's Z index. If this node's Z index is 2 - * and its parent's effective Z index is 3, then this node's effective Z index will be 2 + 3 = 5. + * If `true`, the node's Z index is relative to its parent's Z index. If this node's Z index is 2 and its parent's effective Z index is 3, then this node's effective Z index will be 2 + 3 = 5. */ public final inline var zAsRelative: Boolean @JvmName("zAsRelativeProperty") @@ -259,14 +212,9 @@ public open class CanvasItem internal constructor() : Node() { } /** - * If `true`, this and child [CanvasItem] nodes with a higher Y position are rendered in front of - * nodes with a lower Y position. If `false`, this and child [CanvasItem] nodes are rendered normally - * in scene tree order. + * If `true`, this and child [CanvasItem] nodes with a higher Y position are rendered in front of nodes with a lower Y position. If `false`, this and child [CanvasItem] nodes are rendered normally in scene tree order. * - * With Y-sorting enabled on a parent node ('A') but disabled on a child node ('B'), the child - * node ('B') is sorted but its children ('C1', 'C2', etc.) render together on the same Y position as - * the child node ('B'). This allows you to organize the render order of a scene without changing the - * scene tree. + * With Y-sorting enabled on a parent node ('A') but disabled on a child node ('B'), the child node ('B') is sorted but its children ('C1', 'C2', etc.) render together on the same Y position as the child node ('B'). This allows you to organize the render order of a scene without changing the scene tree. * * Nodes sort relative to each other only if they are on the same [zIndex]. */ @@ -322,7 +270,7 @@ public open class CanvasItem internal constructor() : Node() { setUseParentMaterial(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(136, scriptIndex) } @@ -337,8 +285,7 @@ public open class CanvasItem internal constructor() : Node() { * canvasitem.modulate = myCoreType * `````` * - * The color applied to this [CanvasItem]. This property does affect child [CanvasItem]s, unlike - * [selfModulate] which only affects the node itself. + * The color applied to this [CanvasItem]. This property does affect child [CanvasItem]s, unlike [selfModulate] which only affects the node itself. */ @CoreTypeHelper public final fun modulateMutate(block: Color.() -> Unit): Color = modulate.apply { @@ -357,12 +304,9 @@ public open class CanvasItem internal constructor() : Node() { * canvasitem.selfModulate = myCoreType * `````` * - * The color applied to this [CanvasItem]. This property does **not** affect child [CanvasItem]s, - * unlike [modulate] which affects both the node itself and its children. + * The color applied to this [CanvasItem]. This property does **not** affect child [CanvasItem]s, unlike [modulate] which affects both the node itself and its children. * - * **Note:** Internal children (e.g. sliders in [ColorPicker] or tab bar in [TabContainer]) are - * also not affected by this property (see `include_internal` parameter of [Node.getChild] and other - * similar methods). + * **Note:** Internal children (e.g. sliders in [ColorPicker] or tab bar in [TabContainer]) are also not affected by this property (see `include_internal` parameter of [Node.getChild] and other similar methods). */ @CoreTypeHelper public final fun selfModulateMutate(block: Color.() -> Unit): Color = selfModulate.apply { @@ -371,12 +315,11 @@ public open class CanvasItem internal constructor() : Node() { } /** - * Called when [CanvasItem] has been requested to redraw (after [queueRedraw] is called, either - * manually or by the engine). + * Called when [CanvasItem] has been requested to redraw (after [queueRedraw] is called, either manually or by the engine). * * Corresponds to the [NOTIFICATION_DRAW] notification in [Object.Notification]. */ - public open fun _draw(): Unit { + public open fun _draw() { throw NotImplementedError("CanvasItem::_draw is not implemented.") } @@ -389,7 +332,7 @@ public open class CanvasItem internal constructor() : Node() { return (TransferContext.readReturnValue(_RID) as RID) } - public final fun setVisible(visible: Boolean): Unit { + public final fun setVisible(visible: Boolean) { TransferContext.writeArguments(BOOL to visible) TransferContext.callMethod(ptr, MethodBindings.setVisiblePtr, NIL) } @@ -401,16 +344,11 @@ public open class CanvasItem internal constructor() : Node() { } /** - * Returns `true` if the node is present in the [SceneTree], its [visible] property is `true` and - * all its ancestors are also visible. If any ancestor is hidden, this node will not be visible in - * the scene tree, and is therefore not drawn (see [_draw]). + * Returns `true` if the node is present in the [SceneTree], its [visible] property is `true` and all its ancestors are also visible. If any ancestor is hidden, this node will not be visible in the scene tree, and is therefore not drawn (see [_draw]). * - * Visibility is checked only in parent nodes that inherit from [CanvasItem], [CanvasLayer], and - * [Window]. If the parent is of any other type (such as [Node], [AnimationPlayer], or [Node3D]), it - * is assumed to be visible. + * Visibility is checked only in parent nodes that inherit from [CanvasItem], [CanvasLayer], and [Window]. If the parent is of any other type (such as [Node], [AnimationPlayer], or [Node3D]), it is assumed to be visible. * - * **Note:** This method does not take [visibilityLayer] into account, so even if this method - * returns `true`, the node might end up not being rendered. + * **Note:** This method does not take [visibilityLayer] into account, so even if this method returns `true`, the node might end up not being rendered. */ public final fun isVisibleInTree(): Boolean { TransferContext.writeArguments() @@ -419,30 +357,25 @@ public open class CanvasItem internal constructor() : Node() { } /** - * Show the [CanvasItem] if it's currently hidden. This is equivalent to setting [visible] to - * `true`. For controls that inherit [Popup], the correct way to make them visible is to call one of - * the multiple `popup*()` functions instead. + * Show the [CanvasItem] if it's currently hidden. This is equivalent to setting [visible] to `true`. For controls that inherit [Popup], the correct way to make them visible is to call one of the multiple `popup*()` functions instead. */ - public final fun show(): Unit { + public final fun show() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.showPtr, NIL) } /** - * Hide the [CanvasItem] if it's currently visible. This is equivalent to setting [visible] to - * `false`. + * Hide the [CanvasItem] if it's currently visible. This is equivalent to setting [visible] to `false`. */ - public final fun hide(): Unit { + public final fun hide() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.hidePtr, NIL) } /** - * Queues the [CanvasItem] to redraw. During idle time, if [CanvasItem] is visible, - * [NOTIFICATION_DRAW] is sent and [_draw] is called. This only occurs **once** per frame, even if - * this method has been called multiple times. + * Queues the [CanvasItem] to redraw. During idle time, if [CanvasItem] is visible, [NOTIFICATION_DRAW] is sent and [_draw] is called. This only occurs **once** per frame, even if this method has been called multiple times. */ - public final fun queueRedraw(): Unit { + public final fun queueRedraw() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.queueRedrawPtr, NIL) } @@ -450,15 +383,14 @@ public open class CanvasItem internal constructor() : Node() { /** * Moves this node to display on top of its siblings. * - * Internally, the node is moved to the bottom of parent's child list. The method has no effect on - * nodes without a parent. + * Internally, the node is moved to the bottom of parent's child list. The method has no effect on nodes without a parent. */ - public final fun moveToFront(): Unit { + public final fun moveToFront() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.moveToFrontPtr, NIL) } - public final fun setAsTopLevel(enable: Boolean): Unit { + public final fun setAsTopLevel(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setAsTopLevelPtr, NIL) } @@ -469,7 +401,7 @@ public open class CanvasItem internal constructor() : Node() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setLightMask(lightMask: Int): Unit { + public final fun setLightMask(lightMask: Int) { TransferContext.writeArguments(LONG to lightMask.toLong()) TransferContext.callMethod(ptr, MethodBindings.setLightMaskPtr, NIL) } @@ -480,7 +412,7 @@ public open class CanvasItem internal constructor() : Node() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setModulate(modulate: Color): Unit { + public final fun setModulate(modulate: Color) { TransferContext.writeArguments(COLOR to modulate) TransferContext.callMethod(ptr, MethodBindings.setModulatePtr, NIL) } @@ -491,7 +423,7 @@ public open class CanvasItem internal constructor() : Node() { return (TransferContext.readReturnValue(COLOR) as Color) } - public final fun setSelfModulate(selfModulate: Color): Unit { + public final fun setSelfModulate(selfModulate: Color) { TransferContext.writeArguments(COLOR to selfModulate) TransferContext.callMethod(ptr, MethodBindings.setSelfModulatePtr, NIL) } @@ -502,7 +434,7 @@ public open class CanvasItem internal constructor() : Node() { return (TransferContext.readReturnValue(COLOR) as Color) } - public final fun setZIndex(zIndex: Int): Unit { + public final fun setZIndex(zIndex: Int) { TransferContext.writeArguments(LONG to zIndex.toLong()) TransferContext.callMethod(ptr, MethodBindings.setZIndexPtr, NIL) } @@ -513,7 +445,7 @@ public open class CanvasItem internal constructor() : Node() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setZAsRelative(enable: Boolean): Unit { + public final fun setZAsRelative(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setZAsRelativePtr, NIL) } @@ -524,7 +456,7 @@ public open class CanvasItem internal constructor() : Node() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setYSortEnabled(enabled: Boolean): Unit { + public final fun setYSortEnabled(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setYSortEnabledPtr, NIL) } @@ -535,7 +467,7 @@ public open class CanvasItem internal constructor() : Node() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setDrawBehindParent(enable: Boolean): Unit { + public final fun setDrawBehindParent(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setDrawBehindParentPtr, NIL) } @@ -547,12 +479,9 @@ public open class CanvasItem internal constructor() : Node() { } /** - * Draws a line from a 2D point to another, with a given color and width. It can be optionally - * antialiased. See also [drawDashedLine], [drawMultiline], and [drawPolyline]. + * Draws a line from a 2D point to another, with a given color and width. It can be optionally antialiased. See also [drawDashedLine], [drawMultiline], and [drawPolyline]. * - * If [width] is negative, then a two-point primitive will be drawn instead of a four-point one. - * This means that when the CanvasItem is scaled, the line will remain thin. If this behavior is not - * desired, then pass a positive [width] like `1.0`. + * If [width] is negative, then a two-point primitive will be drawn instead of a four-point one. This means that when the CanvasItem is scaled, the line will remain thin. If this behavior is not desired, then pass a positive [width] like `1.0`. */ @JvmOverloads public final fun drawLine( @@ -561,28 +490,19 @@ public open class CanvasItem internal constructor() : Node() { color: Color, width: Float = -1.0f, antialiased: Boolean = false, - ): Unit { + ) { TransferContext.writeArguments(VECTOR2 to from, VECTOR2 to to, COLOR to color, DOUBLE to width.toDouble(), BOOL to antialiased) TransferContext.callMethod(ptr, MethodBindings.drawLinePtr, NIL) } /** - * Draws a dashed line from a 2D point to another, with a given color and width. See also - * [drawLine], [drawMultiline], and [drawPolyline]. + * Draws a dashed line from a 2D point to another, with a given color and width. See also [drawLine], [drawMultiline], and [drawPolyline]. * - * If [width] is negative, then a two-point primitives will be drawn instead of a four-point ones. - * This means that when the CanvasItem is scaled, the line parts will remain thin. If this behavior - * is not desired, then pass a positive [width] like `1.0`. + * If [width] is negative, then a two-point primitives will be drawn instead of a four-point ones. This means that when the CanvasItem is scaled, the line parts will remain thin. If this behavior is not desired, then pass a positive [width] like `1.0`. * - * [dash] is the length of each dash in pixels, with the gap between each dash being the same - * length. If [aligned] is `true`, the length of the first and last dashes may be shortened or - * lengthened to allow the line to begin and end at the precise points defined by [from] and [to]. - * Both ends are always symmetrical when [aligned] is `true`. If [aligned] is `false`, all dashes - * will have the same length, but the line may appear incomplete at the end due to the dash length - * not dividing evenly into the line length. Only full dashes are drawn when [aligned] is `false`. + * [dash] is the length of each dash in pixels, with the gap between each dash being the same length. If [aligned] is `true`, the length of the first and last dashes may be shortened or lengthened to allow the line to begin and end at the precise points defined by [from] and [to]. Both ends are always symmetrical when [aligned] is `true`. If [aligned] is `false`, all dashes will have the same length, but the line may appear incomplete at the end due to the dash length not dividing evenly into the line length. Only full dashes are drawn when [aligned] is `false`. * - * If [antialiased] is `true`, half transparent "feathers" will be attached to the boundary, - * making outlines smooth. + * If [antialiased] is `true`, half transparent "feathers" will be attached to the boundary, making outlines smooth. * * **Note:** [antialiased] is only effective if [width] is greater than `0.0`. */ @@ -595,21 +515,15 @@ public open class CanvasItem internal constructor() : Node() { dash: Float = 2.0f, aligned: Boolean = true, antialiased: Boolean = false, - ): Unit { + ) { TransferContext.writeArguments(VECTOR2 to from, VECTOR2 to to, COLOR to color, DOUBLE to width.toDouble(), DOUBLE to dash.toDouble(), BOOL to aligned, BOOL to antialiased) TransferContext.callMethod(ptr, MethodBindings.drawDashedLinePtr, NIL) } /** - * Draws interconnected line segments with a uniform [color] and [width] and optional antialiasing - * (supported only for positive [width]). When drawing large amounts of lines, this is faster than - * using individual [drawLine] calls. To draw disconnected lines, use [drawMultiline] instead. See - * also [drawPolygon]. + * Draws interconnected line segments with a uniform [color] and [width] and optional antialiasing (supported only for positive [width]). When drawing large amounts of lines, this is faster than using individual [drawLine] calls. To draw disconnected lines, use [drawMultiline] instead. See also [drawPolygon]. * - * If [width] is negative, it will be ignored and the polyline will be drawn using - * [RenderingServer.PRIMITIVE_LINE_STRIP]. This means that when the CanvasItem is scaled, the - * polyline will remain thin. If this behavior is not desired, then pass a positive [width] like - * `1.0`. + * If [width] is negative, it will be ignored and the polyline will be drawn using [RenderingServer.PRIMITIVE_LINE_STRIP]. This means that when the CanvasItem is scaled, the polyline will remain thin. If this behavior is not desired, then pass a positive [width] like `1.0`. */ @JvmOverloads public final fun drawPolyline( @@ -617,23 +531,15 @@ public open class CanvasItem internal constructor() : Node() { color: Color, width: Float = -1.0f, antialiased: Boolean = false, - ): Unit { + ) { TransferContext.writeArguments(PACKED_VECTOR2_ARRAY to points, COLOR to color, DOUBLE to width.toDouble(), BOOL to antialiased) TransferContext.callMethod(ptr, MethodBindings.drawPolylinePtr, NIL) } /** - * Draws interconnected line segments with a uniform [width], point-by-point coloring, and - * optional antialiasing (supported only for positive [width]). Colors assigned to line points match - * by index between [points] and [colors], i.e. each line segment is filled with a gradient between - * the colors of the endpoints. When drawing large amounts of lines, this is faster than using - * individual [drawLine] calls. To draw disconnected lines, use [drawMultilineColors] instead. See - * also [drawPolygon]. + * Draws interconnected line segments with a uniform [width], point-by-point coloring, and optional antialiasing (supported only for positive [width]). Colors assigned to line points match by index between [points] and [colors], i.e. each line segment is filled with a gradient between the colors of the endpoints. When drawing large amounts of lines, this is faster than using individual [drawLine] calls. To draw disconnected lines, use [drawMultilineColors] instead. See also [drawPolygon]. * - * If [width] is negative, it will be ignored and the polyline will be drawn using - * [RenderingServer.PRIMITIVE_LINE_STRIP]. This means that when the CanvasItem is scaled, the - * polyline will remain thin. If this behavior is not desired, then pass a positive [width] like - * `1.0`. + * If [width] is negative, it will be ignored and the polyline will be drawn using [RenderingServer.PRIMITIVE_LINE_STRIP]. This means that when the CanvasItem is scaled, the polyline will remain thin. If this behavior is not desired, then pass a positive [width] like `1.0`. */ @JvmOverloads public final fun drawPolylineColors( @@ -641,24 +547,17 @@ public open class CanvasItem internal constructor() : Node() { colors: PackedColorArray, width: Float = -1.0f, antialiased: Boolean = false, - ): Unit { + ) { TransferContext.writeArguments(PACKED_VECTOR2_ARRAY to points, PACKED_COLOR_ARRAY to colors, DOUBLE to width.toDouble(), BOOL to antialiased) TransferContext.callMethod(ptr, MethodBindings.drawPolylineColorsPtr, NIL) } /** - * Draws an unfilled arc between the given angles with a uniform [color] and [width] and optional - * antialiasing (supported only for positive [width]). The larger the value of [pointCount], the - * smoother the curve. See also [drawCircle]. + * Draws an unfilled arc between the given angles with a uniform [color] and [width] and optional antialiasing (supported only for positive [width]). The larger the value of [pointCount], the smoother the curve. See also [drawCircle]. * - * If [width] is negative, it will be ignored and the arc will be drawn using - * [RenderingServer.PRIMITIVE_LINE_STRIP]. This means that when the CanvasItem is scaled, the arc - * will remain thin. If this behavior is not desired, then pass a positive [width] like `1.0`. + * If [width] is negative, it will be ignored and the arc will be drawn using [RenderingServer.PRIMITIVE_LINE_STRIP]. This means that when the CanvasItem is scaled, the arc will remain thin. If this behavior is not desired, then pass a positive [width] like `1.0`. * - * The arc is drawn from [startAngle] towards the value of [endAngle] so in clockwise direction if - * `start_angle < end_angle` and counter-clockwise otherwise. Passing the same angles but in reversed - * order will produce the same arc. If absolute difference of [startAngle] and [endAngle] is greater - * than [@GDScript.TAU] radians, then a full circle arc is drawn (i.e. arc will not overlap itself). + * The arc is drawn from [startAngle] towards the value of [endAngle] so in clockwise direction if `start_angle < end_angle` and counter-clockwise otherwise. Passing the same angles but in reversed order will produce the same arc. If absolute difference of [startAngle] and [endAngle] is greater than [@GDScript.TAU] radians, then a full circle arc is drawn (i.e. arc will not overlap itself). */ @JvmOverloads public final fun drawArc( @@ -670,20 +569,15 @@ public open class CanvasItem internal constructor() : Node() { color: Color, width: Float = -1.0f, antialiased: Boolean = false, - ): Unit { + ) { TransferContext.writeArguments(VECTOR2 to center, DOUBLE to radius.toDouble(), DOUBLE to startAngle.toDouble(), DOUBLE to endAngle.toDouble(), LONG to pointCount.toLong(), COLOR to color, DOUBLE to width.toDouble(), BOOL to antialiased) TransferContext.callMethod(ptr, MethodBindings.drawArcPtr, NIL) } /** - * Draws multiple disconnected lines with a uniform [width] and [color]. Each line is defined by - * two consecutive points from [points] array, i.e. i-th segment consists of `points[2 * i]`, - * `points[2 * i + 1]` endpoints. When drawing large amounts of lines, this is faster than using - * individual [drawLine] calls. To draw interconnected lines, use [drawPolyline] instead. + * Draws multiple disconnected lines with a uniform [width] and [color]. Each line is defined by two consecutive points from [points] array, i.e. i-th segment consists of `points[2 * i]`, `points[2 * i + 1]` endpoints. When drawing large amounts of lines, this is faster than using individual [drawLine] calls. To draw interconnected lines, use [drawPolyline] instead. * - * If [width] is negative, then two-point primitives will be drawn instead of a four-point ones. - * This means that when the CanvasItem is scaled, the lines will remain thin. If this behavior is not - * desired, then pass a positive [width] like `1.0`. + * If [width] is negative, then two-point primitives will be drawn instead of a four-point ones. This means that when the CanvasItem is scaled, the lines will remain thin. If this behavior is not desired, then pass a positive [width] like `1.0`. * * **Note:** [antialiased] is only effective if [width] is greater than `0.0`. */ @@ -693,21 +587,15 @@ public open class CanvasItem internal constructor() : Node() { color: Color, width: Float = -1.0f, antialiased: Boolean = false, - ): Unit { + ) { TransferContext.writeArguments(PACKED_VECTOR2_ARRAY to points, COLOR to color, DOUBLE to width.toDouble(), BOOL to antialiased) TransferContext.callMethod(ptr, MethodBindings.drawMultilinePtr, NIL) } /** - * Draws multiple disconnected lines with a uniform [width] and segment-by-segment coloring. Each - * segment is defined by two consecutive points from [points] array and a corresponding color from - * [colors] array, i.e. i-th segment consists of `points[2 * i]`, `points[2 * i + 1]` endpoints and - * has `colors[i]` color. When drawing large amounts of lines, this is faster than using individual - * [drawLine] calls. To draw interconnected lines, use [drawPolylineColors] instead. + * Draws multiple disconnected lines with a uniform [width] and segment-by-segment coloring. Each segment is defined by two consecutive points from [points] array and a corresponding color from [colors] array, i.e. i-th segment consists of `points[2 * i]`, `points[2 * i + 1]` endpoints and has `colors[i]` color. When drawing large amounts of lines, this is faster than using individual [drawLine] calls. To draw interconnected lines, use [drawPolylineColors] instead. * - * If [width] is negative, then two-point primitives will be drawn instead of a four-point ones. - * This means that when the CanvasItem is scaled, the lines will remain thin. If this behavior is not - * desired, then pass a positive [width] like `1.0`. + * If [width] is negative, then two-point primitives will be drawn instead of a four-point ones. This means that when the CanvasItem is scaled, the lines will remain thin. If this behavior is not desired, then pass a positive [width] like `1.0`. * * **Note:** [antialiased] is only effective if [width] is greater than `0.0`. */ @@ -717,27 +605,21 @@ public open class CanvasItem internal constructor() : Node() { colors: PackedColorArray, width: Float = -1.0f, antialiased: Boolean = false, - ): Unit { + ) { TransferContext.writeArguments(PACKED_VECTOR2_ARRAY to points, PACKED_COLOR_ARRAY to colors, DOUBLE to width.toDouble(), BOOL to antialiased) TransferContext.callMethod(ptr, MethodBindings.drawMultilineColorsPtr, NIL) } /** - * Draws a rectangle. If [filled] is `true`, the rectangle will be filled with the [color] - * specified. If [filled] is `false`, the rectangle will be drawn as a stroke with the [color] and - * [width] specified. See also [drawTextureRect]. + * Draws a rectangle. If [filled] is `true`, the rectangle will be filled with the [color] specified. If [filled] is `false`, the rectangle will be drawn as a stroke with the [color] and [width] specified. See also [drawTextureRect]. * - * If [width] is negative, then two-point primitives will be drawn instead of a four-point ones. - * This means that when the CanvasItem is scaled, the lines will remain thin. If this behavior is not - * desired, then pass a positive [width] like `1.0`. + * If [width] is negative, then two-point primitives will be drawn instead of a four-point ones. This means that when the CanvasItem is scaled, the lines will remain thin. If this behavior is not desired, then pass a positive [width] like `1.0`. * - * If [antialiased] is `true`, half transparent "feathers" will be attached to the boundary, - * making outlines smooth. + * If [antialiased] is `true`, half transparent "feathers" will be attached to the boundary, making outlines smooth. * * **Note:** [width] is only effective if [filled] is `false`. * - * **Note:** Unfilled rectangles drawn with a negative [width] may not display perfectly. For - * example, corners may be missing or brighter due to overlapping lines (for a translucent [color]). + * **Note:** Unfilled rectangles drawn with a negative [width] may not display perfectly. For example, corners may be missing or brighter due to overlapping lines (for a translucent [color]). */ @JvmOverloads public final fun drawRect( @@ -746,7 +628,7 @@ public open class CanvasItem internal constructor() : Node() { filled: Boolean = true, width: Float = -1.0f, antialiased: Boolean = false, - ): Unit { + ) { TransferContext.writeArguments(RECT2 to rect, COLOR to color, BOOL to filled, DOUBLE to width.toDouble(), BOOL to antialiased) TransferContext.callMethod(ptr, MethodBindings.drawRectPtr, NIL) } @@ -754,15 +636,11 @@ public open class CanvasItem internal constructor() : Node() { /** * Draws a circle. See also [drawArc], [drawPolyline], and [drawPolygon]. * - * If [filled] is `true`, the circle will be filled with the [color] specified. If [filled] is - * `false`, the circle will be drawn as a stroke with the [color] and [width] specified. + * If [filled] is `true`, the circle will be filled with the [color] specified. If [filled] is `false`, the circle will be drawn as a stroke with the [color] and [width] specified. * - * If [width] is negative, then two-point primitives will be drawn instead of a four-point ones. - * This means that when the CanvasItem is scaled, the lines will remain thin. If this behavior is not - * desired, then pass a positive [width] like `1.0`. + * If [width] is negative, then two-point primitives will be drawn instead of a four-point ones. This means that when the CanvasItem is scaled, the lines will remain thin. If this behavior is not desired, then pass a positive [width] like `1.0`. * - * If [antialiased] is `true`, half transparent "feathers" will be attached to the boundary, - * making outlines smooth. + * If [antialiased] is `true`, half transparent "feathers" will be attached to the boundary, making outlines smooth. * * **Note:** [width] is only effective if [filled] is `false`. */ @@ -774,7 +652,7 @@ public open class CanvasItem internal constructor() : Node() { filled: Boolean = true, width: Float = -1.0f, antialiased: Boolean = false, - ): Unit { + ) { TransferContext.writeArguments(VECTOR2 to position, DOUBLE to radius.toDouble(), COLOR to color, BOOL to filled, DOUBLE to width.toDouble(), BOOL to antialiased) TransferContext.callMethod(ptr, MethodBindings.drawCirclePtr, NIL) } @@ -787,15 +665,13 @@ public open class CanvasItem internal constructor() : Node() { texture: Texture2D?, position: Vector2, modulate: Color = Color(Color(1, 1, 1, 1)), - ): Unit { + ) { TransferContext.writeArguments(OBJECT to texture, VECTOR2 to position, COLOR to modulate) TransferContext.callMethod(ptr, MethodBindings.drawTexturePtr, NIL) } /** - * Draws a textured rectangle at a given position, optionally modulated by a color. If [transpose] - * is `true`, the texture will have its X and Y coordinates swapped. See also [drawRect] and - * [drawTextureRectRegion]. + * Draws a textured rectangle at a given position, optionally modulated by a color. If [transpose] is `true`, the texture will have its X and Y coordinates swapped. See also [drawRect] and [drawTextureRectRegion]. */ @JvmOverloads public final fun drawTextureRect( @@ -804,15 +680,13 @@ public open class CanvasItem internal constructor() : Node() { tile: Boolean, modulate: Color = Color(Color(1, 1, 1, 1)), transpose: Boolean = false, - ): Unit { + ) { TransferContext.writeArguments(OBJECT to texture, RECT2 to rect, BOOL to tile, COLOR to modulate, BOOL to transpose) TransferContext.callMethod(ptr, MethodBindings.drawTextureRectPtr, NIL) } /** - * Draws a textured rectangle from a texture's region (specified by [srcRect]) at a given - * position, optionally modulated by a color. If [transpose] is `true`, the texture will have its X - * and Y coordinates swapped. See also [drawTextureRect]. + * Draws a textured rectangle from a texture's region (specified by [srcRect]) at a given position, optionally modulated by a color. If [transpose] is `true`, the texture will have its X and Y coordinates swapped. See also [drawTextureRect]. */ @JvmOverloads public final fun drawTextureRectRegion( @@ -822,21 +696,17 @@ public open class CanvasItem internal constructor() : Node() { modulate: Color = Color(Color(1, 1, 1, 1)), transpose: Boolean = false, clipUv: Boolean = true, - ): Unit { + ) { TransferContext.writeArguments(OBJECT to texture, RECT2 to rect, RECT2 to srcRect, COLOR to modulate, BOOL to transpose, BOOL to clipUv) TransferContext.callMethod(ptr, MethodBindings.drawTextureRectRegionPtr, NIL) } /** - * Draws a textured rectangle region of the multi-channel signed distance field texture at a given - * position, optionally modulated by a color. See [FontFile.multichannelSignedDistanceField] for more - * information and caveats about MSDF font rendering. + * Draws a textured rectangle region of the multi-channel signed distance field texture at a given position, optionally modulated by a color. See [FontFile.multichannelSignedDistanceField] for more information and caveats about MSDF font rendering. * - * If [outline] is positive, each alpha channel value of pixel in region is set to maximum value - * of true distance in the [outline] radius. + * If [outline] is positive, each alpha channel value of pixel in region is set to maximum value of true distance in the [outline] radius. * - * Value of the [pixelRange] should the same that was used during distance field texture - * generation. + * Value of the [pixelRange] should the same that was used during distance field texture generation. */ @JvmOverloads public final fun drawMsdfTextureRectRegion( @@ -847,17 +717,15 @@ public open class CanvasItem internal constructor() : Node() { outline: Double = 0.0, pixelRange: Double = 4.0, scale: Double = 1.0, - ): Unit { + ) { TransferContext.writeArguments(OBJECT to texture, RECT2 to rect, RECT2 to srcRect, COLOR to modulate, DOUBLE to outline, DOUBLE to pixelRange, DOUBLE to scale) TransferContext.callMethod(ptr, MethodBindings.drawMsdfTextureRectRegionPtr, NIL) } /** - * Draws a textured rectangle region of the font texture with LCD subpixel anti-aliasing at a - * given position, optionally modulated by a color. + * Draws a textured rectangle region of the font texture with LCD subpixel anti-aliasing at a given position, optionally modulated by a color. * - * Texture is drawn using the following blend operation, blend mode of the [CanvasItemMaterial] is - * ignored: + * Texture is drawn using the following blend operation, blend mode of the [CanvasItemMaterial] is ignored: * * ``` * dst.r = texture.r * modulate.r * modulate.a + dst.r * (1.0 - texture.r * modulate.a); @@ -872,7 +740,7 @@ public open class CanvasItem internal constructor() : Node() { rect: Rect2, srcRect: Rect2, modulate: Color = Color(Color(1, 1, 1, 1)), - ): Unit { + ) { TransferContext.writeArguments(OBJECT to texture, RECT2 to rect, RECT2 to srcRect, COLOR to modulate) TransferContext.callMethod(ptr, MethodBindings.drawLcdTextureRectRegionPtr, NIL) } @@ -880,16 +748,13 @@ public open class CanvasItem internal constructor() : Node() { /** * Draws a styled rectangle. */ - public final fun drawStyleBox(styleBox: StyleBox?, rect: Rect2): Unit { + public final fun drawStyleBox(styleBox: StyleBox?, rect: Rect2) { TransferContext.writeArguments(OBJECT to styleBox, RECT2 to rect) TransferContext.callMethod(ptr, MethodBindings.drawStyleBoxPtr, NIL) } /** - * Draws a custom primitive. 1 point for a point, 2 points for a line, 3 points for a triangle, - * and 4 points for a quad. If 0 points or more than 4 points are specified, nothing will be drawn - * and an error message will be printed. See also [drawLine], [drawPolyline], [drawPolygon], and - * [drawRect]. + * Draws a custom primitive. 1 point for a point, 2 points for a line, 3 points for a triangle, and 4 points for a quad. If 0 points or more than 4 points are specified, nothing will be drawn and an error message will be printed. See also [drawLine], [drawPolyline], [drawPolygon], and [drawRect]. */ @JvmOverloads public final fun drawPrimitive( @@ -897,20 +762,15 @@ public open class CanvasItem internal constructor() : Node() { colors: PackedColorArray, uvs: PackedVector2Array, texture: Texture2D? = null, - ): Unit { + ) { TransferContext.writeArguments(PACKED_VECTOR2_ARRAY to points, PACKED_COLOR_ARRAY to colors, PACKED_VECTOR2_ARRAY to uvs, OBJECT to texture) TransferContext.callMethod(ptr, MethodBindings.drawPrimitivePtr, NIL) } /** - * Draws a solid polygon of any number of points, convex or concave. Unlike [drawColoredPolygon], - * each point's color can be changed individually. See also [drawPolyline] and [drawPolylineColors]. - * If you need more flexibility (such as being able to use bones), use - * [RenderingServer.canvasItemAddTriangleArray] instead. + * Draws a solid polygon of any number of points, convex or concave. Unlike [drawColoredPolygon], each point's color can be changed individually. See also [drawPolyline] and [drawPolylineColors]. If you need more flexibility (such as being able to use bones), use [RenderingServer.canvasItemAddTriangleArray] instead. * - * **Note:** If you frequently redraw the same polygon with a large number of vertices, consider - * pre-calculating the triangulation with [Geometry2D.triangulatePolygon] and using [drawMesh], - * [drawMultimesh], or [RenderingServer.canvasItemAddTriangleArray]. + * **Note:** If you frequently redraw the same polygon with a large number of vertices, consider pre-calculating the triangulation with [Geometry2D.triangulatePolygon] and using [drawMesh], [drawMultimesh], or [RenderingServer.canvasItemAddTriangleArray]. */ @JvmOverloads public final fun drawPolygon( @@ -918,18 +778,15 @@ public open class CanvasItem internal constructor() : Node() { colors: PackedColorArray, uvs: PackedVector2Array = PackedVector2Array(), texture: Texture2D? = null, - ): Unit { + ) { TransferContext.writeArguments(PACKED_VECTOR2_ARRAY to points, PACKED_COLOR_ARRAY to colors, PACKED_VECTOR2_ARRAY to uvs, OBJECT to texture) TransferContext.callMethod(ptr, MethodBindings.drawPolygonPtr, NIL) } /** - * Draws a colored polygon of any number of points, convex or concave. Unlike [drawPolygon], a - * single color must be specified for the whole polygon. + * Draws a colored polygon of any number of points, convex or concave. Unlike [drawPolygon], a single color must be specified for the whole polygon. * - * **Note:** If you frequently redraw the same polygon with a large number of vertices, consider - * pre-calculating the triangulation with [Geometry2D.triangulatePolygon] and using [drawMesh], - * [drawMultimesh], or [RenderingServer.canvasItemAddTriangleArray]. + * **Note:** If you frequently redraw the same polygon with a large number of vertices, consider pre-calculating the triangulation with [Geometry2D.triangulatePolygon] and using [drawMesh], [drawMultimesh], or [RenderingServer.canvasItemAddTriangleArray]. */ @JvmOverloads public final fun drawColoredPolygon( @@ -937,15 +794,13 @@ public open class CanvasItem internal constructor() : Node() { color: Color, uvs: PackedVector2Array = PackedVector2Array(), texture: Texture2D? = null, - ): Unit { + ) { TransferContext.writeArguments(PACKED_VECTOR2_ARRAY to points, COLOR to color, PACKED_VECTOR2_ARRAY to uvs, OBJECT to texture) TransferContext.callMethod(ptr, MethodBindings.drawColoredPolygonPtr, NIL) } /** - * Draws [text] using the specified [font] at the [pos] (bottom-left corner using the baseline of - * the font). The text will have its color multiplied by [modulate]. If [width] is greater than or - * equal to 0, the text will be clipped if it exceeds the specified width. + * Draws [text] using the specified [font] at the [pos] (bottom-left corner using the baseline of the font). The text will have its color multiplied by [modulate]. If [width] is greater than or equal to 0, the text will be clipped if it exceeds the specified width. * * **Example:** Draw "Hello world", using the project's default font: * @@ -956,8 +811,7 @@ public open class CanvasItem internal constructor() : Node() { * # so the Control is only created once. * var default_font = ThemeDB.fallback_font * var default_font_size = ThemeDB.fallback_font_size - * draw_string(default_font, Vector2(64, 64), "Hello world", HORIZONTAL_ALIGNMENT_LEFT, -1, - * default_font_size) + * draw_string(default_font, Vector2(64, 64), "Hello world", HORIZONTAL_ALIGNMENT_LEFT, -1, default_font_size) * ``` * * ```csharp @@ -967,8 +821,7 @@ public open class CanvasItem internal constructor() : Node() { * // so the Control is only created once. * Font defaultFont = ThemeDB.FallbackFont; * int defaultFontSize = ThemeDB.FallbackFontSize; - * DrawString(defaultFont, new Vector2(64, 64), "Hello world", HORIZONTAL_ALIGNMENT_LEFT, -1, - * defaultFontSize); + * DrawString(defaultFont, new Vector2(64, 64), "Hello world", HORIZONTAL_ALIGNMENT_LEFT, -1, defaultFontSize); * ``` * * See also [Font.drawString]. @@ -985,15 +838,13 @@ public open class CanvasItem internal constructor() : Node() { justificationFlags: TextServer.JustificationFlag = TextServer.JustificationFlag(3), direction: TextServer.Direction = TextServer.Direction.AUTO, orientation: TextServer.Orientation = TextServer.Orientation.HORIZONTAL, - ): Unit { + ) { TransferContext.writeArguments(OBJECT to font, VECTOR2 to pos, STRING to text, LONG to alignment.id, DOUBLE to width.toDouble(), LONG to fontSize.toLong(), COLOR to modulate, LONG to justificationFlags.flag, LONG to direction.id, LONG to orientation.id) TransferContext.callMethod(ptr, MethodBindings.drawStringPtr, NIL) } /** - * Breaks [text] into lines and draws it using the specified [font] at the [pos] (top-left - * corner). The text will have its color multiplied by [modulate]. If [width] is greater than or - * equal to 0, the text will be clipped if it exceeds the specified width. + * Breaks [text] into lines and draws it using the specified [font] at the [pos] (top-left corner). The text will have its color multiplied by [modulate]. If [width] is greater than or equal to 0, the text will be clipped if it exceeds the specified width. */ @JvmOverloads public final fun drawMultilineString( @@ -1009,15 +860,13 @@ public open class CanvasItem internal constructor() : Node() { justificationFlags: TextServer.JustificationFlag = TextServer.JustificationFlag(3), direction: TextServer.Direction = TextServer.Direction.AUTO, orientation: TextServer.Orientation = TextServer.Orientation.HORIZONTAL, - ): Unit { + ) { TransferContext.writeArguments(OBJECT to font, VECTOR2 to pos, STRING to text, LONG to alignment.id, DOUBLE to width.toDouble(), LONG to fontSize.toLong(), LONG to maxLines.toLong(), COLOR to modulate, LONG to brkFlags.flag, LONG to justificationFlags.flag, LONG to direction.id, LONG to orientation.id) TransferContext.callMethod(ptr, MethodBindings.drawMultilineStringPtr, NIL) } /** - * Draws [text] outline using the specified [font] at the [pos] (bottom-left corner using the - * baseline of the font). The text will have its color multiplied by [modulate]. If [width] is - * greater than or equal to 0, the text will be clipped if it exceeds the specified width. + * Draws [text] outline using the specified [font] at the [pos] (bottom-left corner using the baseline of the font). The text will have its color multiplied by [modulate]. If [width] is greater than or equal to 0, the text will be clipped if it exceeds the specified width. */ @JvmOverloads public final fun drawStringOutline( @@ -1032,15 +881,13 @@ public open class CanvasItem internal constructor() : Node() { justificationFlags: TextServer.JustificationFlag = TextServer.JustificationFlag(3), direction: TextServer.Direction = TextServer.Direction.AUTO, orientation: TextServer.Orientation = TextServer.Orientation.HORIZONTAL, - ): Unit { + ) { TransferContext.writeArguments(OBJECT to font, VECTOR2 to pos, STRING to text, LONG to alignment.id, DOUBLE to width.toDouble(), LONG to fontSize.toLong(), LONG to size.toLong(), COLOR to modulate, LONG to justificationFlags.flag, LONG to direction.id, LONG to orientation.id) TransferContext.callMethod(ptr, MethodBindings.drawStringOutlinePtr, NIL) } /** - * Breaks [text] to the lines and draws text outline using the specified [font] at the [pos] - * (top-left corner). The text will have its color multiplied by [modulate]. If [width] is greater - * than or equal to 0, the text will be clipped if it exceeds the specified width. + * Breaks [text] to the lines and draws text outline using the specified [font] at the [pos] (top-left corner). The text will have its color multiplied by [modulate]. If [width] is greater than or equal to 0, the text will be clipped if it exceeds the specified width. */ @JvmOverloads public final fun drawMultilineStringOutline( @@ -1057,7 +904,7 @@ public open class CanvasItem internal constructor() : Node() { justificationFlags: TextServer.JustificationFlag = TextServer.JustificationFlag(3), direction: TextServer.Direction = TextServer.Direction.AUTO, orientation: TextServer.Orientation = TextServer.Orientation.HORIZONTAL, - ): Unit { + ) { TransferContext.writeArguments(OBJECT to font, VECTOR2 to pos, STRING to text, LONG to alignment.id, DOUBLE to width.toDouble(), LONG to fontSize.toLong(), LONG to maxLines.toLong(), LONG to size.toLong(), COLOR to modulate, LONG to brkFlags.flag, LONG to justificationFlags.flag, LONG to direction.id, LONG to orientation.id) TransferContext.callMethod(ptr, MethodBindings.drawMultilineStringOutlinePtr, NIL) } @@ -1072,7 +919,7 @@ public open class CanvasItem internal constructor() : Node() { char: String, fontSize: Int = 16, modulate: Color = Color(Color(1, 1, 1, 1)), - ): Unit { + ) { TransferContext.writeArguments(OBJECT to font, VECTOR2 to pos, STRING to char, LONG to fontSize.toLong(), COLOR to modulate) TransferContext.callMethod(ptr, MethodBindings.drawCharPtr, NIL) } @@ -1088,14 +935,13 @@ public open class CanvasItem internal constructor() : Node() { fontSize: Int = 16, size: Int = -1, modulate: Color = Color(Color(1, 1, 1, 1)), - ): Unit { + ) { TransferContext.writeArguments(OBJECT to font, VECTOR2 to pos, STRING to char, LONG to fontSize.toLong(), LONG to size.toLong(), COLOR to modulate) TransferContext.callMethod(ptr, MethodBindings.drawCharOutlinePtr, NIL) } /** - * Draws a [Mesh] in 2D, using the provided texture. See [MeshInstance2D] for related - * documentation. + * Draws a [Mesh] in 2D, using the provided texture. See [MeshInstance2D] for related documentation. */ @JvmOverloads public final fun drawMesh( @@ -1103,55 +949,44 @@ public open class CanvasItem internal constructor() : Node() { texture: Texture2D?, transform: Transform2D = Transform2D(), modulate: Color = Color(Color(1, 1, 1, 1)), - ): Unit { + ) { TransferContext.writeArguments(OBJECT to mesh, OBJECT to texture, TRANSFORM2D to transform, COLOR to modulate) TransferContext.callMethod(ptr, MethodBindings.drawMeshPtr, NIL) } /** - * Draws a [MultiMesh] in 2D with the provided texture. See [MultiMeshInstance2D] for related - * documentation. + * Draws a [MultiMesh] in 2D with the provided texture. See [MultiMeshInstance2D] for related documentation. */ - public final fun drawMultimesh(multimesh: MultiMesh?, texture: Texture2D?): Unit { + public final fun drawMultimesh(multimesh: MultiMesh?, texture: Texture2D?) { TransferContext.writeArguments(OBJECT to multimesh, OBJECT to texture) TransferContext.callMethod(ptr, MethodBindings.drawMultimeshPtr, NIL) } /** - * Sets a custom transform for drawing via components. Anything drawn afterwards will be - * transformed by this. + * Sets a custom transform for drawing via components. Anything drawn afterwards will be transformed by this. * - * **Note:** [FontFile.oversampling] does *not* take [scale] into account. This means that scaling - * up/down will cause bitmap fonts and rasterized (non-MSDF) dynamic fonts to appear blurry or - * pixelated. To ensure text remains crisp regardless of scale, you can enable MSDF font rendering by - * enabling [ProjectSettings.gui/theme/defaultFontMultichannelSignedDistanceField] (applies to the - * default project font only), or enabling **Multichannel Signed Distance Field** in the import - * options of a DynamicFont for custom fonts. On system fonts, - * [SystemFont.multichannelSignedDistanceField] can be enabled in the inspector. + * **Note:** [FontFile.oversampling] does *not* take [scale] into account. This means that scaling up/down will cause bitmap fonts and rasterized (non-MSDF) dynamic fonts to appear blurry or pixelated. To ensure text remains crisp regardless of scale, you can enable MSDF font rendering by enabling [ProjectSettings.gui/theme/defaultFontMultichannelSignedDistanceField] (applies to the default project font only), or enabling **Multichannel Signed Distance Field** in the import options of a DynamicFont for custom fonts. On system fonts, [SystemFont.multichannelSignedDistanceField] can be enabled in the inspector. */ @JvmOverloads public final fun drawSetTransform( position: Vector2, rotation: Float = 0.0f, scale: Vector2 = Vector2(1, 1), - ): Unit { + ) { TransferContext.writeArguments(VECTOR2 to position, DOUBLE to rotation.toDouble(), VECTOR2 to scale) TransferContext.callMethod(ptr, MethodBindings.drawSetTransformPtr, NIL) } /** - * Sets a custom transform for drawing via matrix. Anything drawn afterwards will be transformed - * by this. + * Sets a custom transform for drawing via matrix. Anything drawn afterwards will be transformed by this. */ - public final fun drawSetTransformMatrix(xform: Transform2D): Unit { + public final fun drawSetTransformMatrix(xform: Transform2D) { TransferContext.writeArguments(TRANSFORM2D to xform) TransferContext.callMethod(ptr, MethodBindings.drawSetTransformMatrixPtr, NIL) } /** - * Subsequent drawing commands will be ignored unless they fall within the specified animation - * slice. This is a faster way to implement animations that loop on background rather than redrawing - * constantly. + * Subsequent drawing commands will be ignored unless they fall within the specified animation slice. This is a faster way to implement animations that loop on background rather than redrawing constantly. */ @JvmOverloads public final fun drawAnimationSlice( @@ -1159,18 +994,15 @@ public open class CanvasItem internal constructor() : Node() { sliceBegin: Double, sliceEnd: Double, offset: Double = 0.0, - ): Unit { + ) { TransferContext.writeArguments(DOUBLE to animationLength, DOUBLE to sliceBegin, DOUBLE to sliceEnd, DOUBLE to offset) TransferContext.callMethod(ptr, MethodBindings.drawAnimationSlicePtr, NIL) } /** - * After submitting all animations slices via [drawAnimationSlice], this function can be used to - * revert drawing to its default state (all subsequent drawing commands will be visible). If you - * don't care about this particular use case, usage of this function after submitting the slices is - * not required. + * After submitting all animations slices via [drawAnimationSlice], this function can be used to revert drawing to its default state (all subsequent drawing commands will be visible). If you don't care about this particular use case, usage of this function after submitting the slices is not required. */ - public final fun drawEndAnimation(): Unit { + public final fun drawEndAnimation() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.drawEndAnimationPtr, NIL) } @@ -1185,9 +1017,7 @@ public open class CanvasItem internal constructor() : Node() { } /** - * Returns the global transform matrix of this item, i.e. the combined transform up to the topmost - * [CanvasItem] node. The topmost item is a [CanvasItem] that either has no parent, has - * non-[CanvasItem] parent or it has [topLevel] enabled. + * Returns the global transform matrix of this item, i.e. the combined transform up to the topmost [CanvasItem] node. The topmost item is a [CanvasItem] that either has no parent, has non-[CanvasItem] parent or it has [topLevel] enabled. */ public final fun getGlobalTransform(): Transform2D { TransferContext.writeArguments() @@ -1196,8 +1026,7 @@ public open class CanvasItem internal constructor() : Node() { } /** - * Returns the transform from the local coordinate system of this [CanvasItem] to the [Viewport]s - * coordinate system. + * Returns the transform from the local coordinate system of this [CanvasItem] to the [Viewport]s coordinate system. */ public final fun getGlobalTransformWithCanvas(): Transform2D { TransferContext.writeArguments() @@ -1206,8 +1035,7 @@ public open class CanvasItem internal constructor() : Node() { } /** - * Returns the transform from the coordinate system of the canvas, this item is in, to the - * [Viewport]s embedders coordinate system. + * Returns the transform from the coordinate system of the canvas, this item is in, to the [Viewport]s embedders coordinate system. */ public final fun getViewportTransform(): Transform2D { TransferContext.writeArguments() @@ -1225,8 +1053,7 @@ public open class CanvasItem internal constructor() : Node() { } /** - * Returns the transform from the coordinate system of the canvas, this item is in, to the - * [Viewport]s coordinate system. + * Returns the transform from the coordinate system of the canvas, this item is in, to the [Viewport]s coordinate system. */ public final fun getCanvasTransform(): Transform2D { TransferContext.writeArguments() @@ -1235,8 +1062,7 @@ public open class CanvasItem internal constructor() : Node() { } /** - * Returns the transform of this [CanvasItem] in global screen coordinates (i.e. taking window - * position into account). Mostly useful for editor plugins. + * Returns the transform of this [CanvasItem] in global screen coordinates (i.e. taking window position into account). Mostly useful for editor plugins. * * Equals to [getGlobalTransform] if the window is embedded (see [Viewport.guiEmbedSubwindows]). */ @@ -1247,8 +1073,7 @@ public open class CanvasItem internal constructor() : Node() { } /** - * Returns the mouse's position in this [CanvasItem] using the local coordinate system of this - * [CanvasItem]. + * Returns the mouse's position in this [CanvasItem] using the local coordinate system of this [CanvasItem]. */ public final fun getLocalMousePosition(): Vector2 { TransferContext.writeArguments() @@ -1257,11 +1082,9 @@ public open class CanvasItem internal constructor() : Node() { } /** - * Returns the mouse's position in the [CanvasLayer] that this [CanvasItem] is in using the - * coordinate system of the [CanvasLayer]. + * Returns the mouse's position in the [CanvasLayer] that this [CanvasItem] is in using the coordinate system of the [CanvasLayer]. * - * **Note:** For screen-space coordinates (e.g. when using a non-embedded [Popup]), you can use - * [DisplayServer.mouseGetPosition]. + * **Note:** For screen-space coordinates (e.g. when using a non-embedded [Popup]), you can use [DisplayServer.mouseGetPosition]. */ public final fun getGlobalMousePosition(): Vector2 { TransferContext.writeArguments() @@ -1279,8 +1102,7 @@ public open class CanvasItem internal constructor() : Node() { } /** - * Returns the [CanvasLayer] that contains this node, or `null` if the node is not in any - * [CanvasLayer]. + * Returns the [CanvasLayer] that contains this node, or `null` if the node is not in any [CanvasLayer]. */ public final fun getCanvasLayerNode(): CanvasLayer? { TransferContext.writeArguments() @@ -1297,7 +1119,7 @@ public open class CanvasItem internal constructor() : Node() { return (TransferContext.readReturnValue(OBJECT) as World2D?) } - public final fun setMaterial(material: Material?): Unit { + public final fun setMaterial(material: Material?) { TransferContext.writeArguments(OBJECT to material) TransferContext.callMethod(ptr, MethodBindings.setMaterialPtr, NIL) } @@ -1309,18 +1131,13 @@ public open class CanvasItem internal constructor() : Node() { } /** - * Set the value of a shader uniform for this instance only - * ([url=$DOCS_URL/tutorials/shaders/shader_reference/shading_language.html#per-instance-uniforms]per-instance - * uniform[/url]). See also [ShaderMaterial.setShaderParameter] to assign a uniform on all instances - * using the same [ShaderMaterial]. + * Set the value of a shader uniform for this instance only ([url=$DOCS_URL/tutorials/shaders/shader_reference/shading_language.html#per-instance-uniforms]per-instance uniform[/url]). See also [ShaderMaterial.setShaderParameter] to assign a uniform on all instances using the same [ShaderMaterial]. * - * **Note:** For a shader uniform to be assignable on a per-instance basis, it *must* be defined - * with `instance uniform ...` rather than `uniform ...` in the shader code. + * **Note:** For a shader uniform to be assignable on a per-instance basis, it *must* be defined with `instance uniform ...` rather than `uniform ...` in the shader code. * - * **Note:** [name] is case-sensitive and must match the name of the uniform in the code exactly - * (not the capitalized name in the inspector). + * **Note:** [name] is case-sensitive and must match the name of the uniform in the code exactly (not the capitalized name in the inspector). */ - public final fun setInstanceShaderParameter(name: StringName, `value`: Any?): Unit { + public final fun setInstanceShaderParameter(name: StringName, `value`: Any?) { TransferContext.writeArguments(STRING_NAME to name, ANY to value) TransferContext.callMethod(ptr, MethodBindings.setInstanceShaderParameterPtr, NIL) } @@ -1334,7 +1151,7 @@ public open class CanvasItem internal constructor() : Node() { return (TransferContext.readReturnValue(ANY) as Any?) } - public final fun setUseParentMaterial(enable: Boolean): Unit { + public final fun setUseParentMaterial(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setUseParentMaterialPtr, NIL) } @@ -1346,10 +1163,9 @@ public open class CanvasItem internal constructor() : Node() { } /** - * If [enable] is `true`, this node will receive [NOTIFICATION_LOCAL_TRANSFORM_CHANGED] when its - * local transform changes. + * If [enable] is `true`, this node will receive [NOTIFICATION_LOCAL_TRANSFORM_CHANGED] when its local transform changes. */ - public final fun setNotifyLocalTransform(enable: Boolean): Unit { + public final fun setNotifyLocalTransform(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setNotifyLocalTransformPtr, NIL) } @@ -1364,10 +1180,9 @@ public open class CanvasItem internal constructor() : Node() { } /** - * If [enable] is `true`, this node will receive [NOTIFICATION_TRANSFORM_CHANGED] when its global - * transform changes. + * If [enable] is `true`, this node will receive [NOTIFICATION_TRANSFORM_CHANGED] when its global transform changes. */ - public final fun setNotifyTransform(enable: Boolean): Unit { + public final fun setNotifyTransform(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setNotifyTransformPtr, NIL) } @@ -1382,11 +1197,9 @@ public open class CanvasItem internal constructor() : Node() { } /** - * Forces the transform to update. Transform changes in physics are not instant for performance - * reasons. Transforms are accumulated and then set. Use this if you need an up-to-date transform - * when doing physics operations. + * Forces the transform to update. Transform changes in physics are not instant for performance reasons. Transforms are accumulated and then set. Use this if you need an up-to-date transform when doing physics operations. */ - public final fun forceUpdateTransform(): Unit { + public final fun forceUpdateTransform() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.forceUpdateTransformPtr, NIL) } @@ -1415,7 +1228,7 @@ public open class CanvasItem internal constructor() : Node() { return (TransferContext.readReturnValue(OBJECT) as InputEvent?) } - public final fun setVisibilityLayer(layer: Long): Unit { + public final fun setVisibilityLayer(layer: Long) { TransferContext.writeArguments(LONG to layer) TransferContext.callMethod(ptr, MethodBindings.setVisibilityLayerPtr, NIL) } @@ -1427,10 +1240,9 @@ public open class CanvasItem internal constructor() : Node() { } /** - * Set/clear individual bits on the rendering visibility layer. This simplifies editing this - * [CanvasItem]'s visibility layer. + * Set/clear individual bits on the rendering visibility layer. This simplifies editing this [CanvasItem]'s visibility layer. */ - public final fun setVisibilityLayerBit(layer: Long, enabled: Boolean): Unit { + public final fun setVisibilityLayerBit(layer: Long, enabled: Boolean) { TransferContext.writeArguments(LONG to layer, BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setVisibilityLayerBitPtr, NIL) } @@ -1444,7 +1256,7 @@ public open class CanvasItem internal constructor() : Node() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setTextureFilter(mode: TextureFilter): Unit { + public final fun setTextureFilter(mode: TextureFilter) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setTextureFilterPtr, NIL) } @@ -1455,7 +1267,7 @@ public open class CanvasItem internal constructor() : Node() { return TextureFilter.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setTextureRepeat(mode: TextureRepeat): Unit { + public final fun setTextureRepeat(mode: TextureRepeat) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setTextureRepeatPtr, NIL) } @@ -1466,7 +1278,7 @@ public open class CanvasItem internal constructor() : Node() { return TextureRepeat.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setClipChildrenMode(mode: ClipChildrenMode): Unit { + public final fun setClipChildrenMode(mode: ClipChildrenMode) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setClipChildrenModePtr, NIL) } @@ -1478,25 +1290,18 @@ public open class CanvasItem internal constructor() : Node() { } /** - * Set the value of a shader uniform for this instance only - * ([url=$DOCS_URL/tutorials/shaders/shader_reference/shading_language.html#per-instance-uniforms]per-instance - * uniform[/url]). See also [ShaderMaterial.setShaderParameter] to assign a uniform on all instances - * using the same [ShaderMaterial]. + * Set the value of a shader uniform for this instance only ([url=$DOCS_URL/tutorials/shaders/shader_reference/shading_language.html#per-instance-uniforms]per-instance uniform[/url]). See also [ShaderMaterial.setShaderParameter] to assign a uniform on all instances using the same [ShaderMaterial]. * - * **Note:** For a shader uniform to be assignable on a per-instance basis, it *must* be defined - * with `instance uniform ...` rather than `uniform ...` in the shader code. + * **Note:** For a shader uniform to be assignable on a per-instance basis, it *must* be defined with `instance uniform ...` rather than `uniform ...` in the shader code. * - * **Note:** [name] is case-sensitive and must match the name of the uniform in the code exactly - * (not the capitalized name in the inspector). + * **Note:** [name] is case-sensitive and must match the name of the uniform in the code exactly (not the capitalized name in the inspector). */ - public final fun setInstanceShaderParameter(name: String, `value`: Any?) = - setInstanceShaderParameter(name.asCachedStringName(), value) + public final fun setInstanceShaderParameter(name: String, `value`: Any?): Unit = setInstanceShaderParameter(name.asCachedStringName(), value) /** * Get the value of a shader parameter as set on this instance. */ - public final fun getInstanceShaderParameter(name: String): Any? = - getInstanceShaderParameter(name.asCachedStringName()) + public final fun getInstanceShaderParameter(name: String): Any? = getInstanceShaderParameter(name.asCachedStringName()) public enum class TextureFilter( id: Long, @@ -1506,61 +1311,35 @@ public open class CanvasItem internal constructor() : Node() { */ PARENT_NODE(0), /** - * The texture filter reads from the nearest pixel only. This makes the texture look pixelated - * from up close, and grainy from a distance (due to mipmaps not being sampled). + * The texture filter reads from the nearest pixel only. This makes the texture look pixelated from up close, and grainy from a distance (due to mipmaps not being sampled). */ NEAREST(1), /** - * The texture filter blends between the nearest 4 pixels. This makes the texture look smooth - * from up close, and grainy from a distance (due to mipmaps not being sampled). + * The texture filter blends between the nearest 4 pixels. This makes the texture look smooth from up close, and grainy from a distance (due to mipmaps not being sampled). */ LINEAR(2), /** - * The texture filter reads from the nearest pixel and blends between the nearest 2 mipmaps (or - * uses the nearest mipmap if - * [ProjectSettings.rendering/textures/defaultFilters/useNearestMipmapFilter] is `true`). This - * makes the texture look pixelated from up close, and smooth from a distance. + * The texture filter reads from the nearest pixel and blends between the nearest 2 mipmaps (or uses the nearest mipmap if [ProjectSettings.rendering/textures/defaultFilters/useNearestMipmapFilter] is `true`). This makes the texture look pixelated from up close, and smooth from a distance. * - * Use this for non-pixel art textures that may be viewed at a low scale (e.g. due to [Camera2D] - * zoom or sprite scaling), as mipmaps are important to smooth out pixels that are smaller than - * on-screen pixels. + * Use this for non-pixel art textures that may be viewed at a low scale (e.g. due to [Camera2D] zoom or sprite scaling), as mipmaps are important to smooth out pixels that are smaller than on-screen pixels. */ NEAREST_WITH_MIPMAPS(3), /** - * The texture filter blends between the nearest 4 pixels and between the nearest 2 mipmaps (or - * uses the nearest mipmap if - * [ProjectSettings.rendering/textures/defaultFilters/useNearestMipmapFilter] is `true`). This - * makes the texture look smooth from up close, and smooth from a distance. + * The texture filter blends between the nearest 4 pixels and between the nearest 2 mipmaps (or uses the nearest mipmap if [ProjectSettings.rendering/textures/defaultFilters/useNearestMipmapFilter] is `true`). This makes the texture look smooth from up close, and smooth from a distance. * - * Use this for non-pixel art textures that may be viewed at a low scale (e.g. due to [Camera2D] - * zoom or sprite scaling), as mipmaps are important to smooth out pixels that are smaller than - * on-screen pixels. + * Use this for non-pixel art textures that may be viewed at a low scale (e.g. due to [Camera2D] zoom or sprite scaling), as mipmaps are important to smooth out pixels that are smaller than on-screen pixels. */ LINEAR_WITH_MIPMAPS(4), /** - * The texture filter reads from the nearest pixel and blends between 2 mipmaps (or uses the - * nearest mipmap if [ProjectSettings.rendering/textures/defaultFilters/useNearestMipmapFilter] is - * `true`) based on the angle between the surface and the camera view. This makes the texture look - * pixelated from up close, and smooth from a distance. Anisotropic filtering improves texture - * quality on surfaces that are almost in line with the camera, but is slightly slower. The - * anisotropic filtering level can be changed by adjusting - * [ProjectSettings.rendering/textures/defaultFilters/anisotropicFilteringLevel]. + * The texture filter reads from the nearest pixel and blends between 2 mipmaps (or uses the nearest mipmap if [ProjectSettings.rendering/textures/defaultFilters/useNearestMipmapFilter] is `true`) based on the angle between the surface and the camera view. This makes the texture look pixelated from up close, and smooth from a distance. Anisotropic filtering improves texture quality on surfaces that are almost in line with the camera, but is slightly slower. The anisotropic filtering level can be changed by adjusting [ProjectSettings.rendering/textures/defaultFilters/anisotropicFilteringLevel]. * - * **Note:** This texture filter is rarely useful in 2D projects. - * [TEXTURE_FILTER_NEAREST_WITH_MIPMAPS] is usually more appropriate in this case. + * **Note:** This texture filter is rarely useful in 2D projects. [TEXTURE_FILTER_NEAREST_WITH_MIPMAPS] is usually more appropriate in this case. */ NEAREST_WITH_MIPMAPS_ANISOTROPIC(5), /** - * The texture filter blends between the nearest 4 pixels and blends between 2 mipmaps (or uses - * the nearest mipmap if [ProjectSettings.rendering/textures/defaultFilters/useNearestMipmapFilter] - * is `true`) based on the angle between the surface and the camera view. This makes the texture - * look smooth from up close, and smooth from a distance. Anisotropic filtering improves texture - * quality on surfaces that are almost in line with the camera, but is slightly slower. The - * anisotropic filtering level can be changed by adjusting - * [ProjectSettings.rendering/textures/defaultFilters/anisotropicFilteringLevel]. + * The texture filter blends between the nearest 4 pixels and blends between 2 mipmaps (or uses the nearest mipmap if [ProjectSettings.rendering/textures/defaultFilters/useNearestMipmapFilter] is `true`) based on the angle between the surface and the camera view. This makes the texture look smooth from up close, and smooth from a distance. Anisotropic filtering improves texture quality on surfaces that are almost in line with the camera, but is slightly slower. The anisotropic filtering level can be changed by adjusting [ProjectSettings.rendering/textures/defaultFilters/anisotropicFilteringLevel]. * - * **Note:** This texture filter is rarely useful in 2D projects. - * [TEXTURE_FILTER_LINEAR_WITH_MIPMAPS] is usually more appropriate in this case. + * **Note:** This texture filter is rarely useful in 2D projects. [TEXTURE_FILTER_LINEAR_WITH_MIPMAPS] is usually more appropriate in this case. */ LINEAR_WITH_MIPMAPS_ANISOTROPIC(6), /** @@ -1622,13 +1401,11 @@ public open class CanvasItem internal constructor() : Node() { */ DISABLED(0), /** - * Parent is used for the purposes of clipping only. Child is clipped to the parent's visible - * area, parent is not drawn. + * Parent is used for the purposes of clipping only. Child is clipped to the parent's visible area, parent is not drawn. */ ONLY(1), /** - * Parent is used for clipping child, but parent is also drawn underneath child as normal before - * clipping child to its visible area. + * Parent is used for clipping child, but parent is also drawn underneath child as normal before clipping child to its visible area. */ AND_DRAW(2), /** @@ -1649,14 +1426,12 @@ public open class CanvasItem internal constructor() : Node() { public companion object { /** - * The [CanvasItem]'s global transform has changed. This notification is only received if - * enabled by [setNotifyTransform]. + * The [CanvasItem]'s global transform has changed. This notification is only received if enabled by [setNotifyTransform]. */ public final const val NOTIFICATION_TRANSFORM_CHANGED: Long = 2000 /** - * The [CanvasItem]'s local transform has changed. This notification is only received if enabled - * by [setNotifyLocalTransform]. + * The [CanvasItem]'s local transform has changed. This notification is only received if enabled by [setNotifyLocalTransform]. */ public final const val NOTIFICATION_LOCAL_TRANSFORM_CHANGED: Long = 35 @@ -1688,268 +1463,270 @@ public open class CanvasItem internal constructor() : Node() { public object MethodBindings { internal val getCanvasItemPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "get_canvas_item", 2944877500) + TypeManager.getMethodBindPtr("CanvasItem", "get_canvas_item", 2_944_877_500) internal val setVisiblePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "set_visible", 2586408642) + TypeManager.getMethodBindPtr("CanvasItem", "set_visible", 2_586_408_642) internal val isVisiblePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "is_visible", 36873697) + TypeManager.getMethodBindPtr("CanvasItem", "is_visible", 36_873_697) internal val isVisibleInTreePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "is_visible_in_tree", 36873697) + TypeManager.getMethodBindPtr("CanvasItem", "is_visible_in_tree", 36_873_697) - internal val showPtr: VoidPtr = TypeManager.getMethodBindPtr("CanvasItem", "show", 3218959716) + internal val showPtr: VoidPtr = + TypeManager.getMethodBindPtr("CanvasItem", "show", 3_218_959_716) - internal val hidePtr: VoidPtr = TypeManager.getMethodBindPtr("CanvasItem", "hide", 3218959716) + internal val hidePtr: VoidPtr = + TypeManager.getMethodBindPtr("CanvasItem", "hide", 3_218_959_716) internal val queueRedrawPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "queue_redraw", 3218959716) + TypeManager.getMethodBindPtr("CanvasItem", "queue_redraw", 3_218_959_716) internal val moveToFrontPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "move_to_front", 3218959716) + TypeManager.getMethodBindPtr("CanvasItem", "move_to_front", 3_218_959_716) internal val setAsTopLevelPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "set_as_top_level", 2586408642) + TypeManager.getMethodBindPtr("CanvasItem", "set_as_top_level", 2_586_408_642) internal val isSetAsTopLevelPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "is_set_as_top_level", 36873697) + TypeManager.getMethodBindPtr("CanvasItem", "is_set_as_top_level", 36_873_697) internal val setLightMaskPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "set_light_mask", 1286410249) + TypeManager.getMethodBindPtr("CanvasItem", "set_light_mask", 1_286_410_249) internal val getLightMaskPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "get_light_mask", 3905245786) + TypeManager.getMethodBindPtr("CanvasItem", "get_light_mask", 3_905_245_786) internal val setModulatePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "set_modulate", 2920490490) + TypeManager.getMethodBindPtr("CanvasItem", "set_modulate", 2_920_490_490) internal val getModulatePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "get_modulate", 3444240500) + TypeManager.getMethodBindPtr("CanvasItem", "get_modulate", 3_444_240_500) internal val setSelfModulatePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "set_self_modulate", 2920490490) + TypeManager.getMethodBindPtr("CanvasItem", "set_self_modulate", 2_920_490_490) internal val getSelfModulatePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "get_self_modulate", 3444240500) + TypeManager.getMethodBindPtr("CanvasItem", "get_self_modulate", 3_444_240_500) internal val setZIndexPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "set_z_index", 1286410249) + TypeManager.getMethodBindPtr("CanvasItem", "set_z_index", 1_286_410_249) internal val getZIndexPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "get_z_index", 3905245786) + TypeManager.getMethodBindPtr("CanvasItem", "get_z_index", 3_905_245_786) internal val setZAsRelativePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "set_z_as_relative", 2586408642) + TypeManager.getMethodBindPtr("CanvasItem", "set_z_as_relative", 2_586_408_642) internal val isZRelativePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "is_z_relative", 36873697) + TypeManager.getMethodBindPtr("CanvasItem", "is_z_relative", 36_873_697) internal val setYSortEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "set_y_sort_enabled", 2586408642) + TypeManager.getMethodBindPtr("CanvasItem", "set_y_sort_enabled", 2_586_408_642) internal val isYSortEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "is_y_sort_enabled", 36873697) + TypeManager.getMethodBindPtr("CanvasItem", "is_y_sort_enabled", 36_873_697) internal val setDrawBehindParentPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "set_draw_behind_parent", 2586408642) + TypeManager.getMethodBindPtr("CanvasItem", "set_draw_behind_parent", 2_586_408_642) internal val isDrawBehindParentEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "is_draw_behind_parent_enabled", 36873697) + TypeManager.getMethodBindPtr("CanvasItem", "is_draw_behind_parent_enabled", 36_873_697) internal val drawLinePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "draw_line", 1562330099) + TypeManager.getMethodBindPtr("CanvasItem", "draw_line", 1_562_330_099) internal val drawDashedLinePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "draw_dashed_line", 3653831622) + TypeManager.getMethodBindPtr("CanvasItem", "draw_dashed_line", 3_653_831_622) internal val drawPolylinePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "draw_polyline", 3797364428) + TypeManager.getMethodBindPtr("CanvasItem", "draw_polyline", 3_797_364_428) internal val drawPolylineColorsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "draw_polyline_colors", 2311979562) + TypeManager.getMethodBindPtr("CanvasItem", "draw_polyline_colors", 2_311_979_562) internal val drawArcPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "draw_arc", 4140652635) + TypeManager.getMethodBindPtr("CanvasItem", "draw_arc", 4_140_652_635) internal val drawMultilinePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "draw_multiline", 3797364428) + TypeManager.getMethodBindPtr("CanvasItem", "draw_multiline", 3_797_364_428) internal val drawMultilineColorsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "draw_multiline_colors", 2311979562) + TypeManager.getMethodBindPtr("CanvasItem", "draw_multiline_colors", 2_311_979_562) internal val drawRectPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "draw_rect", 2773573813) + TypeManager.getMethodBindPtr("CanvasItem", "draw_rect", 2_773_573_813) internal val drawCirclePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "draw_circle", 3153026596) + TypeManager.getMethodBindPtr("CanvasItem", "draw_circle", 3_153_026_596) internal val drawTexturePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "draw_texture", 520200117) + TypeManager.getMethodBindPtr("CanvasItem", "draw_texture", 520_200_117) internal val drawTextureRectPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "draw_texture_rect", 3832805018) + TypeManager.getMethodBindPtr("CanvasItem", "draw_texture_rect", 3_832_805_018) internal val drawTextureRectRegionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "draw_texture_rect_region", 3883821411) + TypeManager.getMethodBindPtr("CanvasItem", "draw_texture_rect_region", 3_883_821_411) internal val drawMsdfTextureRectRegionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "draw_msdf_texture_rect_region", 4219163252) + TypeManager.getMethodBindPtr("CanvasItem", "draw_msdf_texture_rect_region", 4_219_163_252) internal val drawLcdTextureRectRegionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "draw_lcd_texture_rect_region", 3212350954) + TypeManager.getMethodBindPtr("CanvasItem", "draw_lcd_texture_rect_region", 3_212_350_954) internal val drawStyleBoxPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "draw_style_box", 388176283) + TypeManager.getMethodBindPtr("CanvasItem", "draw_style_box", 388_176_283) internal val drawPrimitivePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "draw_primitive", 3288481815) + TypeManager.getMethodBindPtr("CanvasItem", "draw_primitive", 3_288_481_815) internal val drawPolygonPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "draw_polygon", 974537912) + TypeManager.getMethodBindPtr("CanvasItem", "draw_polygon", 974_537_912) internal val drawColoredPolygonPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "draw_colored_polygon", 15245644) + TypeManager.getMethodBindPtr("CanvasItem", "draw_colored_polygon", 15_245_644) internal val drawStringPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "draw_string", 728290553) + TypeManager.getMethodBindPtr("CanvasItem", "draw_string", 728_290_553) internal val drawMultilineStringPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "draw_multiline_string", 1927038192) + TypeManager.getMethodBindPtr("CanvasItem", "draw_multiline_string", 1_927_038_192) internal val drawStringOutlinePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "draw_string_outline", 340562381) + TypeManager.getMethodBindPtr("CanvasItem", "draw_string_outline", 340_562_381) internal val drawMultilineStringOutlinePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "draw_multiline_string_outline", 1912318525) + TypeManager.getMethodBindPtr("CanvasItem", "draw_multiline_string_outline", 1_912_318_525) internal val drawCharPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "draw_char", 3339793283) + TypeManager.getMethodBindPtr("CanvasItem", "draw_char", 3_339_793_283) internal val drawCharOutlinePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "draw_char_outline", 3302344391) + TypeManager.getMethodBindPtr("CanvasItem", "draw_char_outline", 3_302_344_391) internal val drawMeshPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "draw_mesh", 153818295) + TypeManager.getMethodBindPtr("CanvasItem", "draw_mesh", 153_818_295) internal val drawMultimeshPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "draw_multimesh", 937992368) + TypeManager.getMethodBindPtr("CanvasItem", "draw_multimesh", 937_992_368) internal val drawSetTransformPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "draw_set_transform", 288975085) + TypeManager.getMethodBindPtr("CanvasItem", "draw_set_transform", 288_975_085) internal val drawSetTransformMatrixPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "draw_set_transform_matrix", 2761652528) + TypeManager.getMethodBindPtr("CanvasItem", "draw_set_transform_matrix", 2_761_652_528) internal val drawAnimationSlicePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "draw_animation_slice", 3112831842) + TypeManager.getMethodBindPtr("CanvasItem", "draw_animation_slice", 3_112_831_842) internal val drawEndAnimationPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "draw_end_animation", 3218959716) + TypeManager.getMethodBindPtr("CanvasItem", "draw_end_animation", 3_218_959_716) internal val getTransformPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "get_transform", 3814499831) + TypeManager.getMethodBindPtr("CanvasItem", "get_transform", 3_814_499_831) internal val getGlobalTransformPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "get_global_transform", 3814499831) + TypeManager.getMethodBindPtr("CanvasItem", "get_global_transform", 3_814_499_831) internal val getGlobalTransformWithCanvasPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "get_global_transform_with_canvas", 3814499831) + TypeManager.getMethodBindPtr("CanvasItem", "get_global_transform_with_canvas", 3_814_499_831) internal val getViewportTransformPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "get_viewport_transform", 3814499831) + TypeManager.getMethodBindPtr("CanvasItem", "get_viewport_transform", 3_814_499_831) internal val getViewportRectPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "get_viewport_rect", 1639390495) + TypeManager.getMethodBindPtr("CanvasItem", "get_viewport_rect", 1_639_390_495) internal val getCanvasTransformPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "get_canvas_transform", 3814499831) + TypeManager.getMethodBindPtr("CanvasItem", "get_canvas_transform", 3_814_499_831) internal val getScreenTransformPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "get_screen_transform", 3814499831) + TypeManager.getMethodBindPtr("CanvasItem", "get_screen_transform", 3_814_499_831) internal val getLocalMousePositionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "get_local_mouse_position", 3341600327) + TypeManager.getMethodBindPtr("CanvasItem", "get_local_mouse_position", 3_341_600_327) internal val getGlobalMousePositionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "get_global_mouse_position", 3341600327) + TypeManager.getMethodBindPtr("CanvasItem", "get_global_mouse_position", 3_341_600_327) internal val getCanvasPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "get_canvas", 2944877500) + TypeManager.getMethodBindPtr("CanvasItem", "get_canvas", 2_944_877_500) internal val getCanvasLayerNodePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "get_canvas_layer_node", 2602762519) + TypeManager.getMethodBindPtr("CanvasItem", "get_canvas_layer_node", 2_602_762_519) internal val getWorld2dPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "get_world_2d", 2339128592) + TypeManager.getMethodBindPtr("CanvasItem", "get_world_2d", 2_339_128_592) internal val setMaterialPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "set_material", 2757459619) + TypeManager.getMethodBindPtr("CanvasItem", "set_material", 2_757_459_619) internal val getMaterialPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "get_material", 5934680) + TypeManager.getMethodBindPtr("CanvasItem", "get_material", 5_934_680) internal val setInstanceShaderParameterPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "set_instance_shader_parameter", 3776071444) + TypeManager.getMethodBindPtr("CanvasItem", "set_instance_shader_parameter", 3_776_071_444) internal val getInstanceShaderParameterPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "get_instance_shader_parameter", 2760726917) + TypeManager.getMethodBindPtr("CanvasItem", "get_instance_shader_parameter", 2_760_726_917) internal val setUseParentMaterialPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "set_use_parent_material", 2586408642) + TypeManager.getMethodBindPtr("CanvasItem", "set_use_parent_material", 2_586_408_642) internal val getUseParentMaterialPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "get_use_parent_material", 36873697) + TypeManager.getMethodBindPtr("CanvasItem", "get_use_parent_material", 36_873_697) internal val setNotifyLocalTransformPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "set_notify_local_transform", 2586408642) + TypeManager.getMethodBindPtr("CanvasItem", "set_notify_local_transform", 2_586_408_642) internal val isLocalTransformNotificationEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "is_local_transform_notification_enabled", 36873697) + TypeManager.getMethodBindPtr("CanvasItem", "is_local_transform_notification_enabled", 36_873_697) internal val setNotifyTransformPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "set_notify_transform", 2586408642) + TypeManager.getMethodBindPtr("CanvasItem", "set_notify_transform", 2_586_408_642) internal val isTransformNotificationEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "is_transform_notification_enabled", 36873697) + TypeManager.getMethodBindPtr("CanvasItem", "is_transform_notification_enabled", 36_873_697) internal val forceUpdateTransformPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "force_update_transform", 3218959716) + TypeManager.getMethodBindPtr("CanvasItem", "force_update_transform", 3_218_959_716) internal val makeCanvasPositionLocalPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "make_canvas_position_local", 2656412154) + TypeManager.getMethodBindPtr("CanvasItem", "make_canvas_position_local", 2_656_412_154) internal val makeInputLocalPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "make_input_local", 811130057) + TypeManager.getMethodBindPtr("CanvasItem", "make_input_local", 811_130_057) internal val setVisibilityLayerPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "set_visibility_layer", 1286410249) + TypeManager.getMethodBindPtr("CanvasItem", "set_visibility_layer", 1_286_410_249) internal val getVisibilityLayerPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "get_visibility_layer", 3905245786) + TypeManager.getMethodBindPtr("CanvasItem", "get_visibility_layer", 3_905_245_786) internal val setVisibilityLayerBitPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "set_visibility_layer_bit", 300928843) + TypeManager.getMethodBindPtr("CanvasItem", "set_visibility_layer_bit", 300_928_843) internal val getVisibilityLayerBitPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "get_visibility_layer_bit", 1116898809) + TypeManager.getMethodBindPtr("CanvasItem", "get_visibility_layer_bit", 1_116_898_809) internal val setTextureFilterPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "set_texture_filter", 1037999706) + TypeManager.getMethodBindPtr("CanvasItem", "set_texture_filter", 1_037_999_706) internal val getTextureFilterPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "get_texture_filter", 121960042) + TypeManager.getMethodBindPtr("CanvasItem", "get_texture_filter", 121_960_042) internal val setTextureRepeatPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "set_texture_repeat", 1716472974) + TypeManager.getMethodBindPtr("CanvasItem", "set_texture_repeat", 1_716_472_974) internal val getTextureRepeatPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "get_texture_repeat", 2667158319) + TypeManager.getMethodBindPtr("CanvasItem", "get_texture_repeat", 2_667_158_319) internal val setClipChildrenModePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "set_clip_children_mode", 1319393776) + TypeManager.getMethodBindPtr("CanvasItem", "set_clip_children_mode", 1_319_393_776) internal val getClipChildrenModePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItem", "get_clip_children_mode", 3581808349) + TypeManager.getMethodBindPtr("CanvasItem", "get_clip_children_mode", 3_581_808_349) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CanvasItemMaterial.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CanvasItemMaterial.kt index 204f18099a..3f3ba8bcd8 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CanvasItemMaterial.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CanvasItemMaterial.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -19,13 +16,10 @@ import kotlin.Int import kotlin.Long import kotlin.NotImplementedError import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * [CanvasItemMaterial]s provide a means of modifying the textures associated with a CanvasItem. - * They specialize in describing blend and lighting behaviors for textures. Use a [ShaderMaterial] to - * more fully customize a material's interactions with a [CanvasItem]. + * [CanvasItemMaterial]s provide a means of modifying the textures associated with a CanvasItem. They specialize in describing blend and lighting behaviors for textures. Use a [ShaderMaterial] to more fully customize a material's interactions with a [CanvasItem]. */ @GodotBaseType public open class CanvasItemMaterial : Material() { @@ -52,12 +46,9 @@ public open class CanvasItemMaterial : Material() { } /** - * If `true`, enable spritesheet-based animation features when assigned to [GPUParticles2D] and - * [CPUParticles2D] nodes. The [ParticleProcessMaterial.animSpeedMax] or - * [CPUParticles2D.animSpeedMax] should also be set to a positive value for the animation to play. + * If `true`, enable spritesheet-based animation features when assigned to [GPUParticles2D] and [CPUParticles2D] nodes. The [ParticleProcessMaterial.animSpeedMax] or [CPUParticles2D.animSpeedMax] should also be set to a positive value for the animation to play. * - * This property (and other `particles_anim_*` properties that depend on it) has no effect on - * other types of nodes. + * This property (and other `particles_anim_*` properties that depend on it) has no effect on other types of nodes. */ public final inline var particlesAnimation: Boolean @JvmName("particlesAnimationProperty") @@ -68,11 +59,9 @@ public open class CanvasItemMaterial : Material() { } /** - * The number of columns in the spritesheet assigned as [Texture2D] for a [GPUParticles2D] or - * [CPUParticles2D]. + * The number of columns in the spritesheet assigned as [Texture2D] for a [GPUParticles2D] or [CPUParticles2D]. * - * **Note:** This property is only used and visible in the editor if [particlesAnimation] is - * `true`. + * **Note:** This property is only used and visible in the editor if [particlesAnimation] is `true`. */ public final inline var particlesAnimHFrames: Int @JvmName("particlesAnimHFramesProperty") @@ -83,11 +72,9 @@ public open class CanvasItemMaterial : Material() { } /** - * The number of rows in the spritesheet assigned as [Texture2D] for a [GPUParticles2D] or - * [CPUParticles2D]. + * The number of rows in the spritesheet assigned as [Texture2D] for a [GPUParticles2D] or [CPUParticles2D]. * - * **Note:** This property is only used and visible in the editor if [particlesAnimation] is - * `true`. + * **Note:** This property is only used and visible in the editor if [particlesAnimation] is `true`. */ public final inline var particlesAnimVFrames: Int @JvmName("particlesAnimVFramesProperty") @@ -100,8 +87,7 @@ public open class CanvasItemMaterial : Material() { /** * If `true`, the particles animation will loop. * - * **Note:** This property is only used and visible in the editor if [particlesAnimation] is - * `true`. + * **Note:** This property is only used and visible in the editor if [particlesAnimation] is `true`. */ public final inline var particlesAnimLoop: Boolean @JvmName("particlesAnimLoopProperty") @@ -111,11 +97,11 @@ public open class CanvasItemMaterial : Material() { setParticlesAnimLoop(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(137, scriptIndex) } - public final fun setBlendMode(blendMode: BlendMode): Unit { + public final fun setBlendMode(blendMode: BlendMode) { TransferContext.writeArguments(LONG to blendMode.id) TransferContext.callMethod(ptr, MethodBindings.setBlendModePtr, NIL) } @@ -126,7 +112,7 @@ public open class CanvasItemMaterial : Material() { return BlendMode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setLightMode(lightMode: LightMode): Unit { + public final fun setLightMode(lightMode: LightMode) { TransferContext.writeArguments(LONG to lightMode.id) TransferContext.callMethod(ptr, MethodBindings.setLightModePtr, NIL) } @@ -137,7 +123,7 @@ public open class CanvasItemMaterial : Material() { return LightMode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setParticlesAnimation(particlesAnim: Boolean): Unit { + public final fun setParticlesAnimation(particlesAnim: Boolean) { TransferContext.writeArguments(BOOL to particlesAnim) TransferContext.callMethod(ptr, MethodBindings.setParticlesAnimationPtr, NIL) } @@ -148,7 +134,7 @@ public open class CanvasItemMaterial : Material() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setParticlesAnimHFrames(frames: Int): Unit { + public final fun setParticlesAnimHFrames(frames: Int) { TransferContext.writeArguments(LONG to frames.toLong()) TransferContext.callMethod(ptr, MethodBindings.setParticlesAnimHFramesPtr, NIL) } @@ -159,7 +145,7 @@ public open class CanvasItemMaterial : Material() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setParticlesAnimVFrames(frames: Int): Unit { + public final fun setParticlesAnimVFrames(frames: Int) { TransferContext.writeArguments(LONG to frames.toLong()) TransferContext.callMethod(ptr, MethodBindings.setParticlesAnimVFramesPtr, NIL) } @@ -170,7 +156,7 @@ public open class CanvasItemMaterial : Material() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setParticlesAnimLoop(loop: Boolean): Unit { + public final fun setParticlesAnimLoop(loop: Boolean) { TransferContext.writeArguments(BOOL to loop) TransferContext.callMethod(ptr, MethodBindings.setParticlesAnimLoopPtr, NIL) } @@ -184,14 +170,14 @@ public open class CanvasItemMaterial : Material() { /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _getShaderRid(): RID { + override fun _getShaderRid(): RID { throw NotImplementedError("CanvasItemMaterial::_getShaderRid can't be called from the JVM.") } /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _getShaderMode(): Shader.Mode { + override fun _getShaderMode(): Shader.Mode { throw NotImplementedError("CanvasItemMaterial::_getShaderMode can't be called from the JVM.") } @@ -261,39 +247,39 @@ public open class CanvasItemMaterial : Material() { public object MethodBindings { internal val setBlendModePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItemMaterial", "set_blend_mode", 1786054936) + TypeManager.getMethodBindPtr("CanvasItemMaterial", "set_blend_mode", 1_786_054_936) internal val getBlendModePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItemMaterial", "get_blend_mode", 3318684035) + TypeManager.getMethodBindPtr("CanvasItemMaterial", "get_blend_mode", 3_318_684_035) internal val setLightModePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItemMaterial", "set_light_mode", 628074070) + TypeManager.getMethodBindPtr("CanvasItemMaterial", "set_light_mode", 628_074_070) internal val getLightModePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItemMaterial", "get_light_mode", 3863292382) + TypeManager.getMethodBindPtr("CanvasItemMaterial", "get_light_mode", 3_863_292_382) internal val setParticlesAnimationPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItemMaterial", "set_particles_animation", 2586408642) + TypeManager.getMethodBindPtr("CanvasItemMaterial", "set_particles_animation", 2_586_408_642) internal val getParticlesAnimationPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItemMaterial", "get_particles_animation", 36873697) + TypeManager.getMethodBindPtr("CanvasItemMaterial", "get_particles_animation", 36_873_697) internal val setParticlesAnimHFramesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItemMaterial", "set_particles_anim_h_frames", 1286410249) + TypeManager.getMethodBindPtr("CanvasItemMaterial", "set_particles_anim_h_frames", 1_286_410_249) internal val getParticlesAnimHFramesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItemMaterial", "get_particles_anim_h_frames", 3905245786) + TypeManager.getMethodBindPtr("CanvasItemMaterial", "get_particles_anim_h_frames", 3_905_245_786) internal val setParticlesAnimVFramesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItemMaterial", "set_particles_anim_v_frames", 1286410249) + TypeManager.getMethodBindPtr("CanvasItemMaterial", "set_particles_anim_v_frames", 1_286_410_249) internal val getParticlesAnimVFramesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItemMaterial", "get_particles_anim_v_frames", 3905245786) + TypeManager.getMethodBindPtr("CanvasItemMaterial", "get_particles_anim_v_frames", 3_905_245_786) internal val setParticlesAnimLoopPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItemMaterial", "set_particles_anim_loop", 2586408642) + TypeManager.getMethodBindPtr("CanvasItemMaterial", "set_particles_anim_loop", 2_586_408_642) internal val getParticlesAnimLoopPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasItemMaterial", "get_particles_anim_loop", 36873697) + TypeManager.getMethodBindPtr("CanvasItemMaterial", "get_particles_anim_loop", 36_873_697) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CanvasLayer.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CanvasLayer.kt index fe57c89f7c..32050e7b02 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CanvasLayer.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CanvasLayer.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -34,23 +31,13 @@ import kotlin.Unit import kotlin.jvm.JvmName /** - * [CanvasItem]-derived nodes that are direct or indirect children of a [CanvasLayer] will be drawn - * in that layer. The layer is a numeric index that defines the draw order. The default 2D scene - * renders with index `0`, so a [CanvasLayer] with index `-1` will be drawn below, and a [CanvasLayer] - * with index `1` will be drawn above. This order will hold regardless of the [CanvasItem.zIndex] of - * the nodes within each layer. + * [CanvasItem]-derived nodes that are direct or indirect children of a [CanvasLayer] will be drawn in that layer. The layer is a numeric index that defines the draw order. The default 2D scene renders with index `0`, so a [CanvasLayer] with index `-1` will be drawn below, and a [CanvasLayer] with index `1` will be drawn above. This order will hold regardless of the [CanvasItem.zIndex] of the nodes within each layer. * - * [CanvasLayer]s can be hidden and they can also optionally follow the viewport. This makes them - * useful for HUDs like health bar overlays (on layers `1` and higher) or backgrounds (on layers `-1` - * and lower). + * [CanvasLayer]s can be hidden and they can also optionally follow the viewport. This makes them useful for HUDs like health bar overlays (on layers `1` and higher) or backgrounds (on layers `-1` and lower). * - * **Note:** Embedded [Window]s are placed on layer `1024`. [CanvasItem]s on layers `1025` and - * higher appear in front of embedded windows. + * **Note:** Embedded [Window]s are placed on layer `1024`. [CanvasItem]s on layers `1025` and higher appear in front of embedded windows. * - * **Note:** Each [CanvasLayer] is drawn on one specific [Viewport] and cannot be shared between - * multiple [Viewport]s, see [customViewport]. When using multiple [Viewport]s, for example in a - * split-screen game, you need create an individual [CanvasLayer] for each [Viewport] you want it to be - * drawn on. + * **Note:** Each [CanvasLayer] is drawn on one specific [Viewport] and cannot be shared between multiple [Viewport]s, see [customViewport]. When using multiple [Viewport]s, for example in a split-screen game, you need create an individual [CanvasLayer] for each [Viewport] you want it to be drawn on. */ @GodotBaseType public open class CanvasLayer : Node() { @@ -62,9 +49,7 @@ public open class CanvasLayer : Node() { /** * Layer index for draw order. Lower values are drawn behind higher values. * - * **Note:** If multiple CanvasLayers have the same layer index, [CanvasItem] children of one - * CanvasLayer are drawn behind the [CanvasItem] children of the other CanvasLayer. Which CanvasLayer - * is drawn in front is non-deterministic. + * **Note:** If multiple CanvasLayers have the same layer index, [CanvasItem] children of one CanvasLayer are drawn behind the [CanvasItem] children of the other CanvasLayer. Which CanvasLayer is drawn in front is non-deterministic. */ public final inline var layer: Int @JvmName("layerProperty") @@ -77,8 +62,7 @@ public open class CanvasLayer : Node() { /** * If `false`, any [CanvasItem] under this [CanvasLayer] will be hidden. * - * Unlike [CanvasItem.visible], visibility of a [CanvasLayer] isn't propagated to underlying - * layers. + * Unlike [CanvasItem.visible], visibility of a [CanvasLayer] isn't propagated to underlying layers. */ public final inline var visible: Boolean @JvmName("visibleProperty") @@ -92,11 +76,8 @@ public open class CanvasLayer : Node() { * The layer's base offset. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var offset: Vector2 @@ -122,11 +103,8 @@ public open class CanvasLayer : Node() { * The layer's scale. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var scale: Vector2 @@ -141,11 +119,8 @@ public open class CanvasLayer : Node() { * The layer's transform. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var transform: Transform2D @@ -157,8 +132,7 @@ public open class CanvasLayer : Node() { } /** - * The custom [Viewport] node assigned to the [CanvasLayer]. If `null`, uses the default viewport - * instead. + * The custom [Viewport] node assigned to the [CanvasLayer]. If `null`, uses the default viewport instead. */ public final inline var customViewport: Node? @JvmName("customViewportProperty") @@ -169,8 +143,7 @@ public open class CanvasLayer : Node() { } /** - * If enabled, the [CanvasLayer] stays in a fixed position on the screen. If disabled, the - * [CanvasLayer] maintains its position in world space. + * If enabled, the [CanvasLayer] stays in a fixed position on the screen. If disabled, the [CanvasLayer] maintains its position in world space. * * Together with [followViewportScale], this can be used for a pseudo-3D effect. */ @@ -183,8 +156,7 @@ public open class CanvasLayer : Node() { } /** - * Scales the layer when using [followViewportEnabled]. Layers moving into the foreground should - * have increasing scales, while layers moving into the background should have decreasing scales. + * Scales the layer when using [followViewportEnabled]. Layers moving into the foreground should have increasing scales, while layers moving into the background should have decreasing scales. */ public final inline var followViewportScale: Float @JvmName("followViewportScaleProperty") @@ -194,7 +166,7 @@ public open class CanvasLayer : Node() { setFollowViewportScale(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(138, scriptIndex) } @@ -255,7 +227,7 @@ public open class CanvasLayer : Node() { transform = this } - public final fun setLayer(layer: Int): Unit { + public final fun setLayer(layer: Int) { TransferContext.writeArguments(LONG to layer.toLong()) TransferContext.callMethod(ptr, MethodBindings.setLayerPtr, NIL) } @@ -266,7 +238,7 @@ public open class CanvasLayer : Node() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setVisible(visible: Boolean): Unit { + public final fun setVisible(visible: Boolean) { TransferContext.writeArguments(BOOL to visible) TransferContext.callMethod(ptr, MethodBindings.setVisiblePtr, NIL) } @@ -278,24 +250,22 @@ public open class CanvasLayer : Node() { } /** - * Shows any [CanvasItem] under this [CanvasLayer]. This is equivalent to setting [visible] to - * `true`. + * Shows any [CanvasItem] under this [CanvasLayer]. This is equivalent to setting [visible] to `true`. */ - public final fun show(): Unit { + public final fun show() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.showPtr, NIL) } /** - * Hides any [CanvasItem] under this [CanvasLayer]. This is equivalent to setting [visible] to - * `false`. + * Hides any [CanvasItem] under this [CanvasLayer]. This is equivalent to setting [visible] to `false`. */ - public final fun hide(): Unit { + public final fun hide() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.hidePtr, NIL) } - public final fun setTransform(transform: Transform2D): Unit { + public final fun setTransform(transform: Transform2D) { TransferContext.writeArguments(TRANSFORM2D to transform) TransferContext.callMethod(ptr, MethodBindings.setTransformPtr, NIL) } @@ -307,8 +277,7 @@ public open class CanvasLayer : Node() { } /** - * Returns the transform from the [CanvasLayer]s coordinate system to the [Viewport]s coordinate - * system. + * Returns the transform from the [CanvasLayer]s coordinate system to the [Viewport]s coordinate system. */ public final fun getFinalTransform(): Transform2D { TransferContext.writeArguments() @@ -316,7 +285,7 @@ public open class CanvasLayer : Node() { return (TransferContext.readReturnValue(TRANSFORM2D) as Transform2D) } - public final fun setOffset(offset: Vector2): Unit { + public final fun setOffset(offset: Vector2) { TransferContext.writeArguments(VECTOR2 to offset) TransferContext.callMethod(ptr, MethodBindings.setOffsetPtr, NIL) } @@ -327,7 +296,7 @@ public open class CanvasLayer : Node() { return (TransferContext.readReturnValue(VECTOR2) as Vector2) } - public final fun setRotation(radians: Float): Unit { + public final fun setRotation(radians: Float) { TransferContext.writeArguments(DOUBLE to radians.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setRotationPtr, NIL) } @@ -338,7 +307,7 @@ public open class CanvasLayer : Node() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setScale(scale: Vector2): Unit { + public final fun setScale(scale: Vector2) { TransferContext.writeArguments(VECTOR2 to scale) TransferContext.callMethod(ptr, MethodBindings.setScalePtr, NIL) } @@ -349,7 +318,7 @@ public open class CanvasLayer : Node() { return (TransferContext.readReturnValue(VECTOR2) as Vector2) } - public final fun setFollowViewport(enable: Boolean): Unit { + public final fun setFollowViewport(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setFollowViewportPtr, NIL) } @@ -360,7 +329,7 @@ public open class CanvasLayer : Node() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setFollowViewportScale(scale: Float): Unit { + public final fun setFollowViewportScale(scale: Float) { TransferContext.writeArguments(DOUBLE to scale.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setFollowViewportScalePtr, NIL) } @@ -371,7 +340,7 @@ public open class CanvasLayer : Node() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setCustomViewport(viewport: Node?): Unit { + public final fun setCustomViewport(viewport: Node?) { TransferContext.writeArguments(OBJECT to viewport) TransferContext.callMethod(ptr, MethodBindings.setCustomViewportPtr, NIL) } @@ -395,67 +364,69 @@ public open class CanvasLayer : Node() { public object MethodBindings { internal val setLayerPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasLayer", "set_layer", 1286410249) + TypeManager.getMethodBindPtr("CanvasLayer", "set_layer", 1_286_410_249) internal val getLayerPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasLayer", "get_layer", 3905245786) + TypeManager.getMethodBindPtr("CanvasLayer", "get_layer", 3_905_245_786) internal val setVisiblePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasLayer", "set_visible", 2586408642) + TypeManager.getMethodBindPtr("CanvasLayer", "set_visible", 2_586_408_642) internal val isVisiblePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasLayer", "is_visible", 36873697) + TypeManager.getMethodBindPtr("CanvasLayer", "is_visible", 36_873_697) - internal val showPtr: VoidPtr = TypeManager.getMethodBindPtr("CanvasLayer", "show", 3218959716) + internal val showPtr: VoidPtr = + TypeManager.getMethodBindPtr("CanvasLayer", "show", 3_218_959_716) - internal val hidePtr: VoidPtr = TypeManager.getMethodBindPtr("CanvasLayer", "hide", 3218959716) + internal val hidePtr: VoidPtr = + TypeManager.getMethodBindPtr("CanvasLayer", "hide", 3_218_959_716) internal val setTransformPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasLayer", "set_transform", 2761652528) + TypeManager.getMethodBindPtr("CanvasLayer", "set_transform", 2_761_652_528) internal val getTransformPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasLayer", "get_transform", 3814499831) + TypeManager.getMethodBindPtr("CanvasLayer", "get_transform", 3_814_499_831) internal val getFinalTransformPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasLayer", "get_final_transform", 3814499831) + TypeManager.getMethodBindPtr("CanvasLayer", "get_final_transform", 3_814_499_831) internal val setOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasLayer", "set_offset", 743155724) + TypeManager.getMethodBindPtr("CanvasLayer", "set_offset", 743_155_724) internal val getOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasLayer", "get_offset", 3341600327) + TypeManager.getMethodBindPtr("CanvasLayer", "get_offset", 3_341_600_327) internal val setRotationPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasLayer", "set_rotation", 373806689) + TypeManager.getMethodBindPtr("CanvasLayer", "set_rotation", 373_806_689) internal val getRotationPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasLayer", "get_rotation", 1740695150) + TypeManager.getMethodBindPtr("CanvasLayer", "get_rotation", 1_740_695_150) internal val setScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasLayer", "set_scale", 743155724) + TypeManager.getMethodBindPtr("CanvasLayer", "set_scale", 743_155_724) internal val getScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasLayer", "get_scale", 3341600327) + TypeManager.getMethodBindPtr("CanvasLayer", "get_scale", 3_341_600_327) internal val setFollowViewportPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasLayer", "set_follow_viewport", 2586408642) + TypeManager.getMethodBindPtr("CanvasLayer", "set_follow_viewport", 2_586_408_642) internal val isFollowingViewportPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasLayer", "is_following_viewport", 36873697) + TypeManager.getMethodBindPtr("CanvasLayer", "is_following_viewport", 36_873_697) internal val setFollowViewportScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasLayer", "set_follow_viewport_scale", 373806689) + TypeManager.getMethodBindPtr("CanvasLayer", "set_follow_viewport_scale", 373_806_689) internal val getFollowViewportScalePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasLayer", "get_follow_viewport_scale", 1740695150) + TypeManager.getMethodBindPtr("CanvasLayer", "get_follow_viewport_scale", 1_740_695_150) internal val setCustomViewportPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasLayer", "set_custom_viewport", 1078189570) + TypeManager.getMethodBindPtr("CanvasLayer", "set_custom_viewport", 1_078_189_570) internal val getCustomViewportPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasLayer", "get_custom_viewport", 3160264692) + TypeManager.getMethodBindPtr("CanvasLayer", "get_custom_viewport", 3_160_264_692) internal val getCanvasPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasLayer", "get_canvas", 2944877500) + TypeManager.getMethodBindPtr("CanvasLayer", "get_canvas", 2_944_877_500) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CanvasModulate.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CanvasModulate.kt index 6c51945063..bbbb573ff7 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CanvasModulate.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CanvasModulate.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -21,8 +18,7 @@ import kotlin.Unit import kotlin.jvm.JvmName /** - * [CanvasModulate] applies a color tint to all nodes on a canvas. Only one can be used to tint a - * canvas, but [CanvasLayer]s can be used to render things independently. + * [CanvasModulate] applies a color tint to all nodes on a canvas. Only one can be used to tint a canvas, but [CanvasLayer]s can be used to render things independently. */ @GodotBaseType public open class CanvasModulate : Node2D() { @@ -30,11 +26,8 @@ public open class CanvasModulate : Node2D() { * The tint color to apply. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var color: Color @@ -45,7 +38,7 @@ public open class CanvasModulate : Node2D() { setColor(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(139, scriptIndex) } @@ -68,7 +61,7 @@ public open class CanvasModulate : Node2D() { color = this } - public final fun setColor(color: Color): Unit { + public final fun setColor(color: Color) { TransferContext.writeArguments(COLOR to color) TransferContext.callMethod(ptr, MethodBindings.setColorPtr, NIL) } @@ -83,9 +76,9 @@ public open class CanvasModulate : Node2D() { public object MethodBindings { internal val setColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasModulate", "set_color", 2920490490) + TypeManager.getMethodBindPtr("CanvasModulate", "set_color", 2_920_490_490) internal val getColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasModulate", "get_color", 3444240500) + TypeManager.getMethodBindPtr("CanvasModulate", "get_color", 3_444_240_500) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CanvasTexture.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CanvasTexture.kt index 58b7adaf52..f907d34f2f 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CanvasTexture.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CanvasTexture.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -28,14 +25,9 @@ import kotlin.Unit import kotlin.jvm.JvmName /** - * [CanvasTexture] is an alternative to [ImageTexture] for 2D rendering. It allows using normal maps - * and specular maps in any node that inherits from [CanvasItem]. [CanvasTexture] also allows - * overriding the texture's filter and repeat mode independently of the node's properties (or the - * project settings). + * [CanvasTexture] is an alternative to [ImageTexture] for 2D rendering. It allows using normal maps and specular maps in any node that inherits from [CanvasItem]. [CanvasTexture] also allows overriding the texture's filter and repeat mode independently of the node's properties (or the project settings). * - * **Note:** [CanvasTexture] cannot be used in 3D. It will not display correctly when applied to any - * [VisualInstance3D], such as [Sprite3D] or [Decal]. For physically-based materials in 3D, use - * [BaseMaterial3D] instead. + * **Note:** [CanvasTexture] cannot be used in 3D. It will not display correctly when applied to any [VisualInstance3D], such as [Sprite3D] or [Decal]. For physically-based materials in 3D, use [BaseMaterial3D] instead. */ @GodotBaseType public open class CanvasTexture : Texture2D() { @@ -51,12 +43,9 @@ public open class CanvasTexture : Texture2D() { } /** - * The normal map texture to use. Only has a visible effect if [Light2D]s are affecting this - * [CanvasTexture]. + * The normal map texture to use. Only has a visible effect if [Light2D]s are affecting this [CanvasTexture]. * - * **Note:** Godot expects the normal map to use X+, Y+, and Z+ coordinates. See - * [url=http://wiki.polycount.com/wiki/Normal_Map_Technical_Details#Common_Swizzle_Coordinates]this - * page[/url] for a comparison of normal map coordinates expected by popular engines. + * **Note:** Godot expects the normal map to use X+, Y+, and Z+ coordinates. See [url=http://wiki.polycount.com/wiki/Normal_Map_Technical_Details#Common_Swizzle_Coordinates]this page[/url] for a comparison of normal map coordinates expected by popular engines. */ public final inline var normalTexture: Texture2D? @JvmName("normalTextureProperty") @@ -67,10 +56,7 @@ public open class CanvasTexture : Texture2D() { } /** - * The specular map to use for [Light2D] specular reflections. This should be a grayscale or - * colored texture, with brighter areas resulting in a higher [specularShininess] value. Using a - * colored [specularTexture] allows controlling specular shininess on a per-channel basis. Only has a - * visible effect if [Light2D]s are affecting this [CanvasTexture]. + * The specular map to use for [Light2D] specular reflections. This should be a grayscale or colored texture, with brighter areas resulting in a higher [specularShininess] value. Using a colored [specularTexture] allows controlling specular shininess on a per-channel basis. Only has a visible effect if [Light2D]s are affecting this [CanvasTexture]. */ public final inline var specularTexture: Texture2D? @JvmName("specularTextureProperty") @@ -81,16 +67,11 @@ public open class CanvasTexture : Texture2D() { } /** - * The multiplier for specular reflection colors. The [Light2D]'s color is also taken into account - * when determining the reflection color. Only has a visible effect if [Light2D]s are affecting this - * [CanvasTexture]. + * The multiplier for specular reflection colors. The [Light2D]'s color is also taken into account when determining the reflection color. Only has a visible effect if [Light2D]s are affecting this [CanvasTexture]. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var specularColor: Color @@ -102,10 +83,7 @@ public open class CanvasTexture : Texture2D() { } /** - * The specular exponent for [Light2D] specular reflections. Higher values result in a more - * glossy/"wet" look, with reflections becoming more localized and less visible overall. The default - * value of `1.0` disables specular reflections entirely. Only has a visible effect if [Light2D]s are - * affecting this [CanvasTexture]. + * The specular exponent for [Light2D] specular reflections. Higher values result in a more glossy/"wet" look, with reflections becoming more localized and less visible overall. The default value of `1.0` disables specular reflections entirely. Only has a visible effect if [Light2D]s are affecting this [CanvasTexture]. */ public final inline var specularShininess: Float @JvmName("specularShininessProperty") @@ -137,7 +115,7 @@ public open class CanvasTexture : Texture2D() { setTextureRepeat(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(140, scriptIndex) } @@ -152,9 +130,7 @@ public open class CanvasTexture : Texture2D() { * canvastexture.specularColor = myCoreType * `````` * - * The multiplier for specular reflection colors. The [Light2D]'s color is also taken into account - * when determining the reflection color. Only has a visible effect if [Light2D]s are affecting this - * [CanvasTexture]. + * The multiplier for specular reflection colors. The [Light2D]'s color is also taken into account when determining the reflection color. Only has a visible effect if [Light2D]s are affecting this [CanvasTexture]. */ @CoreTypeHelper public final fun specularColorMutate(block: Color.() -> Unit): Color = specularColor.apply { @@ -162,7 +138,7 @@ public open class CanvasTexture : Texture2D() { specularColor = this } - public final fun setDiffuseTexture(texture: Texture2D?): Unit { + public final fun setDiffuseTexture(texture: Texture2D?) { TransferContext.writeArguments(OBJECT to texture) TransferContext.callMethod(ptr, MethodBindings.setDiffuseTexturePtr, NIL) } @@ -173,7 +149,7 @@ public open class CanvasTexture : Texture2D() { return (TransferContext.readReturnValue(OBJECT) as Texture2D?) } - public final fun setNormalTexture(texture: Texture2D?): Unit { + public final fun setNormalTexture(texture: Texture2D?) { TransferContext.writeArguments(OBJECT to texture) TransferContext.callMethod(ptr, MethodBindings.setNormalTexturePtr, NIL) } @@ -184,7 +160,7 @@ public open class CanvasTexture : Texture2D() { return (TransferContext.readReturnValue(OBJECT) as Texture2D?) } - public final fun setSpecularTexture(texture: Texture2D?): Unit { + public final fun setSpecularTexture(texture: Texture2D?) { TransferContext.writeArguments(OBJECT to texture) TransferContext.callMethod(ptr, MethodBindings.setSpecularTexturePtr, NIL) } @@ -195,7 +171,7 @@ public open class CanvasTexture : Texture2D() { return (TransferContext.readReturnValue(OBJECT) as Texture2D?) } - public final fun setSpecularColor(color: Color): Unit { + public final fun setSpecularColor(color: Color) { TransferContext.writeArguments(COLOR to color) TransferContext.callMethod(ptr, MethodBindings.setSpecularColorPtr, NIL) } @@ -206,7 +182,7 @@ public open class CanvasTexture : Texture2D() { return (TransferContext.readReturnValue(COLOR) as Color) } - public final fun setSpecularShininess(shininess: Float): Unit { + public final fun setSpecularShininess(shininess: Float) { TransferContext.writeArguments(DOUBLE to shininess.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setSpecularShininessPtr, NIL) } @@ -217,7 +193,7 @@ public open class CanvasTexture : Texture2D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setTextureFilter(filter: CanvasItem.TextureFilter): Unit { + public final fun setTextureFilter(filter: CanvasItem.TextureFilter) { TransferContext.writeArguments(LONG to filter.id) TransferContext.callMethod(ptr, MethodBindings.setTextureFilterPtr, NIL) } @@ -228,7 +204,7 @@ public open class CanvasTexture : Texture2D() { return CanvasItem.TextureFilter.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setTextureRepeat(repeat: CanvasItem.TextureRepeat): Unit { + public final fun setTextureRepeat(repeat: CanvasItem.TextureRepeat) { TransferContext.writeArguments(LONG to repeat.id) TransferContext.callMethod(ptr, MethodBindings.setTextureRepeatPtr, NIL) } @@ -242,14 +218,14 @@ public open class CanvasTexture : Texture2D() { /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _getWidth(): Int { + override fun _getWidth(): Int { throw NotImplementedError("CanvasTexture::_getWidth can't be called from the JVM.") } /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _getHeight(): Int { + override fun _getHeight(): Int { throw NotImplementedError("CanvasTexture::_getHeight can't be called from the JVM.") } @@ -257,45 +233,45 @@ public open class CanvasTexture : Texture2D() { public object MethodBindings { internal val setDiffuseTexturePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasTexture", "set_diffuse_texture", 4051416890) + TypeManager.getMethodBindPtr("CanvasTexture", "set_diffuse_texture", 4_051_416_890) internal val getDiffuseTexturePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasTexture", "get_diffuse_texture", 3635182373) + TypeManager.getMethodBindPtr("CanvasTexture", "get_diffuse_texture", 3_635_182_373) internal val setNormalTexturePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasTexture", "set_normal_texture", 4051416890) + TypeManager.getMethodBindPtr("CanvasTexture", "set_normal_texture", 4_051_416_890) internal val getNormalTexturePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasTexture", "get_normal_texture", 3635182373) + TypeManager.getMethodBindPtr("CanvasTexture", "get_normal_texture", 3_635_182_373) internal val setSpecularTexturePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasTexture", "set_specular_texture", 4051416890) + TypeManager.getMethodBindPtr("CanvasTexture", "set_specular_texture", 4_051_416_890) internal val getSpecularTexturePtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasTexture", "get_specular_texture", 3635182373) + TypeManager.getMethodBindPtr("CanvasTexture", "get_specular_texture", 3_635_182_373) internal val setSpecularColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasTexture", "set_specular_color", 2920490490) + TypeManager.getMethodBindPtr("CanvasTexture", "set_specular_color", 2_920_490_490) internal val getSpecularColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasTexture", "get_specular_color", 3444240500) + TypeManager.getMethodBindPtr("CanvasTexture", "get_specular_color", 3_444_240_500) internal val setSpecularShininessPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasTexture", "set_specular_shininess", 373806689) + TypeManager.getMethodBindPtr("CanvasTexture", "set_specular_shininess", 373_806_689) internal val getSpecularShininessPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasTexture", "get_specular_shininess", 1740695150) + TypeManager.getMethodBindPtr("CanvasTexture", "get_specular_shininess", 1_740_695_150) internal val setTextureFilterPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasTexture", "set_texture_filter", 1037999706) + TypeManager.getMethodBindPtr("CanvasTexture", "set_texture_filter", 1_037_999_706) internal val getTextureFilterPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasTexture", "get_texture_filter", 121960042) + TypeManager.getMethodBindPtr("CanvasTexture", "get_texture_filter", 121_960_042) internal val setTextureRepeatPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasTexture", "set_texture_repeat", 1716472974) + TypeManager.getMethodBindPtr("CanvasTexture", "set_texture_repeat", 1_716_472_974) internal val getTextureRepeatPtr: VoidPtr = - TypeManager.getMethodBindPtr("CanvasTexture", "get_texture_repeat", 2667158319) + TypeManager.getMethodBindPtr("CanvasTexture", "get_texture_repeat", 2_667_158_319) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CapsuleMesh.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CapsuleMesh.kt index e865e380ec..c4ab8b4049 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CapsuleMesh.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CapsuleMesh.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -18,7 +15,6 @@ import kotlin.Float import kotlin.Int import kotlin.Long import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** @@ -70,11 +66,11 @@ public open class CapsuleMesh : PrimitiveMesh() { setRings(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(141, scriptIndex) } - public final fun setRadius(radius: Float): Unit { + public final fun setRadius(radius: Float) { TransferContext.writeArguments(DOUBLE to radius.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setRadiusPtr, NIL) } @@ -85,7 +81,7 @@ public open class CapsuleMesh : PrimitiveMesh() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setHeight(height: Float): Unit { + public final fun setHeight(height: Float) { TransferContext.writeArguments(DOUBLE to height.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setHeightPtr, NIL) } @@ -96,7 +92,7 @@ public open class CapsuleMesh : PrimitiveMesh() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setRadialSegments(segments: Int): Unit { + public final fun setRadialSegments(segments: Int) { TransferContext.writeArguments(LONG to segments.toLong()) TransferContext.callMethod(ptr, MethodBindings.setRadialSegmentsPtr, NIL) } @@ -107,7 +103,7 @@ public open class CapsuleMesh : PrimitiveMesh() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setRings(rings: Int): Unit { + public final fun setRings(rings: Int) { TransferContext.writeArguments(LONG to rings.toLong()) TransferContext.callMethod(ptr, MethodBindings.setRingsPtr, NIL) } @@ -122,27 +118,27 @@ public open class CapsuleMesh : PrimitiveMesh() { public object MethodBindings { internal val setRadiusPtr: VoidPtr = - TypeManager.getMethodBindPtr("CapsuleMesh", "set_radius", 373806689) + TypeManager.getMethodBindPtr("CapsuleMesh", "set_radius", 373_806_689) internal val getRadiusPtr: VoidPtr = - TypeManager.getMethodBindPtr("CapsuleMesh", "get_radius", 1740695150) + TypeManager.getMethodBindPtr("CapsuleMesh", "get_radius", 1_740_695_150) internal val setHeightPtr: VoidPtr = - TypeManager.getMethodBindPtr("CapsuleMesh", "set_height", 373806689) + TypeManager.getMethodBindPtr("CapsuleMesh", "set_height", 373_806_689) internal val getHeightPtr: VoidPtr = - TypeManager.getMethodBindPtr("CapsuleMesh", "get_height", 1740695150) + TypeManager.getMethodBindPtr("CapsuleMesh", "get_height", 1_740_695_150) internal val setRadialSegmentsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CapsuleMesh", "set_radial_segments", 1286410249) + TypeManager.getMethodBindPtr("CapsuleMesh", "set_radial_segments", 1_286_410_249) internal val getRadialSegmentsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CapsuleMesh", "get_radial_segments", 3905245786) + TypeManager.getMethodBindPtr("CapsuleMesh", "get_radial_segments", 3_905_245_786) internal val setRingsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CapsuleMesh", "set_rings", 1286410249) + TypeManager.getMethodBindPtr("CapsuleMesh", "set_rings", 1_286_410_249) internal val getRingsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CapsuleMesh", "get_rings", 3905245786) + TypeManager.getMethodBindPtr("CapsuleMesh", "get_rings", 3_905_245_786) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CapsuleShape2D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CapsuleShape2D.kt index ea40c1e7f0..d0f066d0a4 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CapsuleShape2D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CapsuleShape2D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -16,15 +13,12 @@ import kotlin.Double import kotlin.Float import kotlin.Int import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * A 2D capsule shape, intended for use in physics. Usually used to provide a shape for a - * [CollisionShape2D]. + * A 2D capsule shape, intended for use in physics. Usually used to provide a shape for a [CollisionShape2D]. * - * **Performance:** [CapsuleShape2D] is fast to check collisions against, but it is slower than - * [RectangleShape2D] and [CircleShape2D]. + * **Performance:** [CapsuleShape2D] is fast to check collisions against, but it is slower than [RectangleShape2D] and [CircleShape2D]. */ @GodotBaseType public open class CapsuleShape2D : Shape2D() { @@ -50,11 +44,11 @@ public open class CapsuleShape2D : Shape2D() { setHeight(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(142, scriptIndex) } - public final fun setRadius(radius: Float): Unit { + public final fun setRadius(radius: Float) { TransferContext.writeArguments(DOUBLE to radius.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setRadiusPtr, NIL) } @@ -65,7 +59,7 @@ public open class CapsuleShape2D : Shape2D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setHeight(height: Float): Unit { + public final fun setHeight(height: Float) { TransferContext.writeArguments(DOUBLE to height.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setHeightPtr, NIL) } @@ -80,15 +74,15 @@ public open class CapsuleShape2D : Shape2D() { public object MethodBindings { internal val setRadiusPtr: VoidPtr = - TypeManager.getMethodBindPtr("CapsuleShape2D", "set_radius", 373806689) + TypeManager.getMethodBindPtr("CapsuleShape2D", "set_radius", 373_806_689) internal val getRadiusPtr: VoidPtr = - TypeManager.getMethodBindPtr("CapsuleShape2D", "get_radius", 1740695150) + TypeManager.getMethodBindPtr("CapsuleShape2D", "get_radius", 1_740_695_150) internal val setHeightPtr: VoidPtr = - TypeManager.getMethodBindPtr("CapsuleShape2D", "set_height", 373806689) + TypeManager.getMethodBindPtr("CapsuleShape2D", "set_height", 373_806_689) internal val getHeightPtr: VoidPtr = - TypeManager.getMethodBindPtr("CapsuleShape2D", "get_height", 1740695150) + TypeManager.getMethodBindPtr("CapsuleShape2D", "get_height", 1_740_695_150) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CapsuleShape3D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CapsuleShape3D.kt index 352ed28b57..edd6bcaf94 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CapsuleShape3D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CapsuleShape3D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -16,15 +13,12 @@ import kotlin.Double import kotlin.Float import kotlin.Int import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * A 3D capsule shape, intended for use in physics. Usually used to provide a shape for a - * [CollisionShape3D]. + * A 3D capsule shape, intended for use in physics. Usually used to provide a shape for a [CollisionShape3D]. * - * **Performance:** [CapsuleShape3D] is fast to check collisions against. It is faster than - * [CylinderShape3D], but slower than [SphereShape3D] and [BoxShape3D]. + * **Performance:** [CapsuleShape3D] is fast to check collisions against. It is faster than [CylinderShape3D], but slower than [SphereShape3D] and [BoxShape3D]. */ @GodotBaseType public open class CapsuleShape3D : Shape3D() { @@ -50,11 +44,11 @@ public open class CapsuleShape3D : Shape3D() { setHeight(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(143, scriptIndex) } - public final fun setRadius(radius: Float): Unit { + public final fun setRadius(radius: Float) { TransferContext.writeArguments(DOUBLE to radius.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setRadiusPtr, NIL) } @@ -65,7 +59,7 @@ public open class CapsuleShape3D : Shape3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setHeight(height: Float): Unit { + public final fun setHeight(height: Float) { TransferContext.writeArguments(DOUBLE to height.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setHeightPtr, NIL) } @@ -80,15 +74,15 @@ public open class CapsuleShape3D : Shape3D() { public object MethodBindings { internal val setRadiusPtr: VoidPtr = - TypeManager.getMethodBindPtr("CapsuleShape3D", "set_radius", 373806689) + TypeManager.getMethodBindPtr("CapsuleShape3D", "set_radius", 373_806_689) internal val getRadiusPtr: VoidPtr = - TypeManager.getMethodBindPtr("CapsuleShape3D", "get_radius", 1740695150) + TypeManager.getMethodBindPtr("CapsuleShape3D", "get_radius", 1_740_695_150) internal val setHeightPtr: VoidPtr = - TypeManager.getMethodBindPtr("CapsuleShape3D", "set_height", 373806689) + TypeManager.getMethodBindPtr("CapsuleShape3D", "set_height", 373_806_689) internal val getHeightPtr: VoidPtr = - TypeManager.getMethodBindPtr("CapsuleShape3D", "get_height", 1740695150) + TypeManager.getMethodBindPtr("CapsuleShape3D", "get_height", 1_740_695_150) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CenterContainer.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CenterContainer.kt index 9d432a913e..3a5135562d 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CenterContainer.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CenterContainer.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -15,12 +12,10 @@ import godot.core.VariantParser.NIL import kotlin.Boolean import kotlin.Int import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * [CenterContainer] is a container that keeps all of its child controls in its center at their - * minimum size. + * [CenterContainer] is a container that keeps all of its child controls in its center at their minimum size. */ @GodotBaseType public open class CenterContainer : Container() { @@ -35,11 +30,11 @@ public open class CenterContainer : Container() { setUseTopLeft(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(144, scriptIndex) } - public final fun setUseTopLeft(enable: Boolean): Unit { + public final fun setUseTopLeft(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setUseTopLeftPtr, NIL) } @@ -54,9 +49,9 @@ public open class CenterContainer : Container() { public object MethodBindings { internal val setUseTopLeftPtr: VoidPtr = - TypeManager.getMethodBindPtr("CenterContainer", "set_use_top_left", 2586408642) + TypeManager.getMethodBindPtr("CenterContainer", "set_use_top_left", 2_586_408_642) internal val isUsingTopLeftPtr: VoidPtr = - TypeManager.getMethodBindPtr("CenterContainer", "is_using_top_left", 36873697) + TypeManager.getMethodBindPtr("CenterContainer", "is_using_top_left", 36_873_697) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CharFXTransform.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CharFXTransform.kt index f96ec57094..f169f923dc 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CharFXTransform.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CharFXTransform.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -38,22 +35,16 @@ import kotlin.Unit import kotlin.jvm.JvmName /** - * By setting various properties on this object, you can control how individual characters will be - * displayed in a [RichTextEffect]. + * By setting various properties on this object, you can control how individual characters will be displayed in a [RichTextEffect]. */ @GodotBaseType public open class CharFXTransform : RefCounted() { /** - * The current transform of the current glyph. It can be overridden (for example, by driving the - * position and rotation from a curve). You can also alter the existing value to apply transforms on - * top of other effects. + * The current transform of the current glyph. It can be overridden (for example, by driving the position and rotation from a curve). You can also alter the existing value to apply transforms on top of other effects. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var transform: Transform2D @@ -70,11 +61,8 @@ public open class CharFXTransform : RefCounted() { * **Note:** Read-only. Setting this property won't affect drawing. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var range: Vector2i @@ -86,9 +74,7 @@ public open class CharFXTransform : RefCounted() { } /** - * The time elapsed since the [RichTextLabel] was added to the scene tree (in seconds). Time stops - * when the [RichTextLabel] is paused (see [Node.processMode]). Resets when the text in the - * [RichTextLabel] is changed. + * The time elapsed since the [RichTextLabel] was added to the scene tree (in seconds). Time stops when the [RichTextLabel] is paused (see [Node.processMode]). Resets when the text in the [RichTextLabel] is changed. * * **Note:** Time still passes while the [RichTextLabel] is hidden. */ @@ -101,9 +87,7 @@ public open class CharFXTransform : RefCounted() { } /** - * If `true`, the character will be drawn. If `false`, the character will be hidden. Characters - * around hidden characters will reflow to take the space of hidden characters. If this is not - * desired, set their [color] to `Color(1, 1, 1, 0)` instead. + * If `true`, the character will be drawn. If `false`, the character will be hidden. Characters around hidden characters will reflow to take the space of hidden characters. If this is not desired, set their [color] to `Color(1, 1, 1, 0)` instead. */ public final inline var visible: Boolean @JvmName("visibleProperty") @@ -130,11 +114,8 @@ public open class CharFXTransform : RefCounted() { * The position offset the character will be drawn with (in pixels). * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var offset: Vector2 @@ -149,11 +130,8 @@ public open class CharFXTransform : RefCounted() { * The color the character will be drawn with. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var color: Color @@ -165,14 +143,9 @@ public open class CharFXTransform : RefCounted() { } /** - * Contains the arguments passed in the opening BBCode tag. By default, arguments are strings; if - * their contents match a type such as [bool], [int] or [float], they will be converted - * automatically. Color codes in the form `#rrggbb` or `#rgb` will be converted to an opaque [Color]. - * String arguments may not contain spaces, even if they're quoted. If present, quotes will also be - * present in the final string. + * Contains the arguments passed in the opening BBCode tag. By default, arguments are strings; if their contents match a type such as [bool], [int] or [float], they will be converted automatically. Color codes in the form `#rrggbb` or `#rgb` will be converted to an opaque [Color]. String arguments may not contain spaces, even if they're quoted. If present, quotes will also be present in the final string. * - * For example, the opening BBCode tag `[example foo=hello bar=true baz=42 color=#ffffff]` will - * map to the following [Dictionary]: + * For example, the opening BBCode tag `[example foo=hello bar=true baz=42 color=#ffffff]` will map to the following [Dictionary]: * * ``` * {"foo": "hello", "bar": true, "baz": 42, "color": Color(1, 1, 1, 1)} @@ -187,8 +160,7 @@ public open class CharFXTransform : RefCounted() { } /** - * Glyph index specific to the [font]. If you want to replace this glyph, use - * [TextServer.fontGetGlyphIndex] with [font] to get a new glyph index for a single character. + * Glyph index specific to the [font]. If you want to replace this glyph, use [TextServer.fontGetGlyphIndex] with [font] to get a new glyph index for a single character. */ public final inline var glyphIndex: Long @JvmName("glyphIndexProperty") @@ -238,8 +210,7 @@ public open class CharFXTransform : RefCounted() { } /** - * [TextServer] RID of the font used to render glyph, this value can be used with - * `TextServer.font_*` methods to retrieve font information. + * [TextServer] RID of the font used to render glyph, this value can be used with `TextServer.font_*` methods to retrieve font information. * * **Note:** Read-only. Setting this property won't affect drawing. */ @@ -251,7 +222,7 @@ public open class CharFXTransform : RefCounted() { setFont(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(145, scriptIndex) } @@ -266,9 +237,7 @@ public open class CharFXTransform : RefCounted() { * charfxtransform.transform = myCoreType * `````` * - * The current transform of the current glyph. It can be overridden (for example, by driving the - * position and rotation from a curve). You can also alter the existing value to apply transforms on - * top of other effects. + * The current transform of the current glyph. It can be overridden (for example, by driving the position and rotation from a curve). You can also alter the existing value to apply transforms on top of other effects. */ @CoreTypeHelper public final fun transformMutate(block: Transform2D.() -> Unit): Transform2D = transform.apply { @@ -341,7 +310,7 @@ public open class CharFXTransform : RefCounted() { return (TransferContext.readReturnValue(TRANSFORM2D) as Transform2D) } - public final fun setTransform(transform: Transform2D): Unit { + public final fun setTransform(transform: Transform2D) { TransferContext.writeArguments(TRANSFORM2D to transform) TransferContext.callMethod(ptr, MethodBindings.setTransformPtr, NIL) } @@ -352,7 +321,7 @@ public open class CharFXTransform : RefCounted() { return (TransferContext.readReturnValue(VECTOR2I) as Vector2i) } - public final fun setRange(range: Vector2i): Unit { + public final fun setRange(range: Vector2i) { TransferContext.writeArguments(VECTOR2I to range) TransferContext.callMethod(ptr, MethodBindings.setRangePtr, NIL) } @@ -363,7 +332,7 @@ public open class CharFXTransform : RefCounted() { return (TransferContext.readReturnValue(DOUBLE) as Double) } - public final fun setElapsedTime(time: Double): Unit { + public final fun setElapsedTime(time: Double) { TransferContext.writeArguments(DOUBLE to time) TransferContext.callMethod(ptr, MethodBindings.setElapsedTimePtr, NIL) } @@ -374,7 +343,7 @@ public open class CharFXTransform : RefCounted() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setVisibility(visibility: Boolean): Unit { + public final fun setVisibility(visibility: Boolean) { TransferContext.writeArguments(BOOL to visibility) TransferContext.callMethod(ptr, MethodBindings.setVisibilityPtr, NIL) } @@ -385,7 +354,7 @@ public open class CharFXTransform : RefCounted() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setOutline(outline: Boolean): Unit { + public final fun setOutline(outline: Boolean) { TransferContext.writeArguments(BOOL to outline) TransferContext.callMethod(ptr, MethodBindings.setOutlinePtr, NIL) } @@ -396,7 +365,7 @@ public open class CharFXTransform : RefCounted() { return (TransferContext.readReturnValue(VECTOR2) as Vector2) } - public final fun setOffset(offset: Vector2): Unit { + public final fun setOffset(offset: Vector2) { TransferContext.writeArguments(VECTOR2 to offset) TransferContext.callMethod(ptr, MethodBindings.setOffsetPtr, NIL) } @@ -407,7 +376,7 @@ public open class CharFXTransform : RefCounted() { return (TransferContext.readReturnValue(COLOR) as Color) } - public final fun setColor(color: Color): Unit { + public final fun setColor(color: Color) { TransferContext.writeArguments(COLOR to color) TransferContext.callMethod(ptr, MethodBindings.setColorPtr, NIL) } @@ -418,7 +387,7 @@ public open class CharFXTransform : RefCounted() { return (TransferContext.readReturnValue(DICTIONARY) as Dictionary) } - public final fun setEnvironment(environment: Dictionary): Unit { + public final fun setEnvironment(environment: Dictionary) { TransferContext.writeArguments(DICTIONARY to environment) TransferContext.callMethod(ptr, MethodBindings.setEnvironmentPtr, NIL) } @@ -429,7 +398,7 @@ public open class CharFXTransform : RefCounted() { return (TransferContext.readReturnValue(LONG) as Long) } - public final fun setGlyphIndex(glyphIndex: Long): Unit { + public final fun setGlyphIndex(glyphIndex: Long) { TransferContext.writeArguments(LONG to glyphIndex) TransferContext.callMethod(ptr, MethodBindings.setGlyphIndexPtr, NIL) } @@ -440,7 +409,7 @@ public open class CharFXTransform : RefCounted() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setRelativeIndex(relativeIndex: Int): Unit { + public final fun setRelativeIndex(relativeIndex: Int) { TransferContext.writeArguments(LONG to relativeIndex.toLong()) TransferContext.callMethod(ptr, MethodBindings.setRelativeIndexPtr, NIL) } @@ -451,7 +420,7 @@ public open class CharFXTransform : RefCounted() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setGlyphCount(glyphCount: Int): Unit { + public final fun setGlyphCount(glyphCount: Int) { TransferContext.writeArguments(LONG to glyphCount.toLong()) TransferContext.callMethod(ptr, MethodBindings.setGlyphCountPtr, NIL) } @@ -462,7 +431,7 @@ public open class CharFXTransform : RefCounted() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setGlyphFlags(glyphFlags: Int): Unit { + public final fun setGlyphFlags(glyphFlags: Int) { TransferContext.writeArguments(LONG to glyphFlags.toLong()) TransferContext.callMethod(ptr, MethodBindings.setGlyphFlagsPtr, NIL) } @@ -473,7 +442,7 @@ public open class CharFXTransform : RefCounted() { return (TransferContext.readReturnValue(_RID) as RID) } - public final fun setFont(font: RID): Unit { + public final fun setFont(font: RID) { TransferContext.writeArguments(_RID to font) TransferContext.callMethod(ptr, MethodBindings.setFontPtr, NIL) } @@ -482,81 +451,81 @@ public open class CharFXTransform : RefCounted() { public object MethodBindings { internal val getTransformPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharFXTransform", "get_transform", 3761352769) + TypeManager.getMethodBindPtr("CharFXTransform", "get_transform", 3_761_352_769) internal val setTransformPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharFXTransform", "set_transform", 2761652528) + TypeManager.getMethodBindPtr("CharFXTransform", "set_transform", 2_761_652_528) internal val getRangePtr: VoidPtr = - TypeManager.getMethodBindPtr("CharFXTransform", "get_range", 2741790807) + TypeManager.getMethodBindPtr("CharFXTransform", "get_range", 2_741_790_807) internal val setRangePtr: VoidPtr = - TypeManager.getMethodBindPtr("CharFXTransform", "set_range", 1130785943) + TypeManager.getMethodBindPtr("CharFXTransform", "set_range", 1_130_785_943) internal val getElapsedTimePtr: VoidPtr = - TypeManager.getMethodBindPtr("CharFXTransform", "get_elapsed_time", 191475506) + TypeManager.getMethodBindPtr("CharFXTransform", "get_elapsed_time", 191_475_506) internal val setElapsedTimePtr: VoidPtr = - TypeManager.getMethodBindPtr("CharFXTransform", "set_elapsed_time", 373806689) + TypeManager.getMethodBindPtr("CharFXTransform", "set_elapsed_time", 373_806_689) internal val isVisiblePtr: VoidPtr = - TypeManager.getMethodBindPtr("CharFXTransform", "is_visible", 2240911060) + TypeManager.getMethodBindPtr("CharFXTransform", "is_visible", 2_240_911_060) internal val setVisibilityPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharFXTransform", "set_visibility", 2586408642) + TypeManager.getMethodBindPtr("CharFXTransform", "set_visibility", 2_586_408_642) internal val isOutlinePtr: VoidPtr = - TypeManager.getMethodBindPtr("CharFXTransform", "is_outline", 2240911060) + TypeManager.getMethodBindPtr("CharFXTransform", "is_outline", 2_240_911_060) internal val setOutlinePtr: VoidPtr = - TypeManager.getMethodBindPtr("CharFXTransform", "set_outline", 2586408642) + TypeManager.getMethodBindPtr("CharFXTransform", "set_outline", 2_586_408_642) internal val getOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharFXTransform", "get_offset", 1497962370) + TypeManager.getMethodBindPtr("CharFXTransform", "get_offset", 1_497_962_370) internal val setOffsetPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharFXTransform", "set_offset", 743155724) + TypeManager.getMethodBindPtr("CharFXTransform", "set_offset", 743_155_724) internal val getColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharFXTransform", "get_color", 3200896285) + TypeManager.getMethodBindPtr("CharFXTransform", "get_color", 3_200_896_285) internal val setColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharFXTransform", "set_color", 2920490490) + TypeManager.getMethodBindPtr("CharFXTransform", "set_color", 2_920_490_490) internal val getEnvironmentPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharFXTransform", "get_environment", 2382534195) + TypeManager.getMethodBindPtr("CharFXTransform", "get_environment", 2_382_534_195) internal val setEnvironmentPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharFXTransform", "set_environment", 4155329257) + TypeManager.getMethodBindPtr("CharFXTransform", "set_environment", 4_155_329_257) internal val getGlyphIndexPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharFXTransform", "get_glyph_index", 3905245786) + TypeManager.getMethodBindPtr("CharFXTransform", "get_glyph_index", 3_905_245_786) internal val setGlyphIndexPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharFXTransform", "set_glyph_index", 1286410249) + TypeManager.getMethodBindPtr("CharFXTransform", "set_glyph_index", 1_286_410_249) internal val getRelativeIndexPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharFXTransform", "get_relative_index", 3905245786) + TypeManager.getMethodBindPtr("CharFXTransform", "get_relative_index", 3_905_245_786) internal val setRelativeIndexPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharFXTransform", "set_relative_index", 1286410249) + TypeManager.getMethodBindPtr("CharFXTransform", "set_relative_index", 1_286_410_249) internal val getGlyphCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharFXTransform", "get_glyph_count", 3905245786) + TypeManager.getMethodBindPtr("CharFXTransform", "get_glyph_count", 3_905_245_786) internal val setGlyphCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharFXTransform", "set_glyph_count", 1286410249) + TypeManager.getMethodBindPtr("CharFXTransform", "set_glyph_count", 1_286_410_249) internal val getGlyphFlagsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharFXTransform", "get_glyph_flags", 3905245786) + TypeManager.getMethodBindPtr("CharFXTransform", "get_glyph_flags", 3_905_245_786) internal val setGlyphFlagsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharFXTransform", "set_glyph_flags", 1286410249) + TypeManager.getMethodBindPtr("CharFXTransform", "set_glyph_flags", 1_286_410_249) internal val getFontPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharFXTransform", "get_font", 2944877500) + TypeManager.getMethodBindPtr("CharFXTransform", "get_font", 2_944_877_500) internal val setFontPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharFXTransform", "set_font", 2722037293) + TypeManager.getMethodBindPtr("CharFXTransform", "set_font", 2_722_037_293) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CharacterBody2D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CharacterBody2D.kt index 55bb441b88..450527a830 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CharacterBody2D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CharacterBody2D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -30,22 +27,14 @@ import kotlin.jvm.JvmName import kotlin.jvm.JvmOverloads /** - * [CharacterBody2D] is a specialized class for physics bodies that are meant to be user-controlled. - * They are not affected by physics at all, but they affect other physics bodies in their path. They - * are mainly used to provide high-level API to move objects with wall and slope detection - * ([moveAndSlide] method) in addition to the general collision detection provided by - * [PhysicsBody2D.moveAndCollide]. This makes it useful for highly configurable physics bodies that - * must move in specific ways and collide with the world, as is often the case with user-controlled - * characters. + * [CharacterBody2D] is a specialized class for physics bodies that are meant to be user-controlled. They are not affected by physics at all, but they affect other physics bodies in their path. They are mainly used to provide high-level API to move objects with wall and slope detection ([moveAndSlide] method) in addition to the general collision detection provided by [PhysicsBody2D.moveAndCollide]. This makes it useful for highly configurable physics bodies that must move in specific ways and collide with the world, as is often the case with user-controlled characters. * - * For game objects that don't require complex movement or collision detection, such as moving - * platforms, [AnimatableBody2D] is simpler to configure. + * For game objects that don't require complex movement or collision detection, such as moving platforms, [AnimatableBody2D] is simpler to configure. */ @GodotBaseType public open class CharacterBody2D : PhysicsBody2D() { /** - * Sets the motion mode which defines the behavior of [moveAndSlide]. See [MotionMode] constants - * for available modes. + * Sets the motion mode which defines the behavior of [moveAndSlide]. See [MotionMode] constants for available modes. */ public final inline var motionMode: MotionMode @JvmName("motionModeProperty") @@ -56,17 +45,11 @@ public open class CharacterBody2D : PhysicsBody2D() { } /** - * Vector pointing upwards, used to determine what is a wall and what is a floor (or a ceiling) - * when calling [moveAndSlide]. Defaults to [Vector2.UP]. As the vector will be normalized it can't - * be equal to [Vector2.ZERO], if you want all collisions to be reported as walls, consider using - * [MOTION_MODE_FLOATING] as [motionMode]. + * Vector pointing upwards, used to determine what is a wall and what is a floor (or a ceiling) when calling [moveAndSlide]. Defaults to [Vector2.UP]. As the vector will be normalized it can't be equal to [Vector2.ZERO], if you want all collisions to be reported as walls, consider using [MOTION_MODE_FLOATING] as [motionMode]. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var upDirection: Vector2 @@ -81,11 +64,8 @@ public open class CharacterBody2D : PhysicsBody2D() { * Current velocity vector in pixels per second, used and modified during calls to [moveAndSlide]. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var velocity: Vector2 @@ -97,8 +77,7 @@ public open class CharacterBody2D : PhysicsBody2D() { } /** - * If `true`, during a jump against the ceiling, the body will slide, if `false` it will be - * stopped and will fall vertically. + * If `true`, during a jump against the ceiling, the body will slide, if `false` it will be stopped and will fall vertically. */ public final inline var slideOnCeiling: Boolean @JvmName("slideOnCeilingProperty") @@ -109,8 +88,7 @@ public open class CharacterBody2D : PhysicsBody2D() { } /** - * Maximum number of times the body can change direction before it stops when calling - * [moveAndSlide]. + * Maximum number of times the body can change direction before it stops when calling [moveAndSlide]. */ public final inline var maxSlides: Int @JvmName("maxSlidesProperty") @@ -121,9 +99,7 @@ public open class CharacterBody2D : PhysicsBody2D() { } /** - * Minimum angle (in radians) where the body is allowed to slide when it encounters a slope. The - * default value equals 15 degrees. This property only affects movement when [motionMode] is - * [MOTION_MODE_FLOATING]. + * Minimum angle (in radians) where the body is allowed to slide when it encounters a slope. The default value equals 15 degrees. This property only affects movement when [motionMode] is [MOTION_MODE_FLOATING]. */ public final inline var wallMinSlideAngle: Float @JvmName("wallMinSlideAngleProperty") @@ -134,8 +110,7 @@ public open class CharacterBody2D : PhysicsBody2D() { } /** - * If `true`, the body will not slide on slopes when calling [moveAndSlide] when the body is - * standing still. + * If `true`, the body will not slide on slopes when calling [moveAndSlide] when the body is standing still. * * If `false`, the body will slide on floor's slopes when [velocity] applies a downward force. */ @@ -148,11 +123,9 @@ public open class CharacterBody2D : PhysicsBody2D() { } /** - * If `false` (by default), the body will move faster on downward slopes and slower on upward - * slopes. + * If `false` (by default), the body will move faster on downward slopes and slower on upward slopes. * - * If `true`, the body will always move at the same speed on the ground no matter the slope. Note - * that you need to use [floorSnapLength] to stick along a downward slope at constant speed. + * If `true`, the body will always move at the same speed on the ground no matter the slope. Note that you need to use [floorSnapLength] to stick along a downward slope at constant speed. */ public final inline var floorConstantSpeed: Boolean @JvmName("floorConstantSpeedProperty") @@ -163,8 +136,7 @@ public open class CharacterBody2D : PhysicsBody2D() { } /** - * If `true`, the body will be able to move on the floor only. This option avoids to be able to - * walk on walls, it will however allow to slide down along them. + * If `true`, the body will be able to move on the floor only. This option avoids to be able to walk on walls, it will however allow to slide down along them. */ public final inline var floorBlockOnWall: Boolean @JvmName("floorBlockOnWallProperty") @@ -175,8 +147,7 @@ public open class CharacterBody2D : PhysicsBody2D() { } /** - * Maximum angle (in radians) where a slope is still considered a floor (or a ceiling), rather - * than a wall, when calling [moveAndSlide]. The default value equals 45 degrees. + * Maximum angle (in radians) where a slope is still considered a floor (or a ceiling), rather than a wall, when calling [moveAndSlide]. The default value equals 45 degrees. */ public final inline var floorMaxAngle: Float @JvmName("floorMaxAngleProperty") @@ -187,15 +158,9 @@ public open class CharacterBody2D : PhysicsBody2D() { } /** - * Sets a snapping distance. When set to a value different from `0.0`, the body is kept attached - * to slopes when calling [moveAndSlide]. The snapping vector is determined by the given distance - * along the opposite direction of the [upDirection]. + * Sets a snapping distance. When set to a value different from `0.0`, the body is kept attached to slopes when calling [moveAndSlide]. The snapping vector is determined by the given distance along the opposite direction of the [upDirection]. * - * As long as the snapping vector is in contact with the ground and the body moves against - * [upDirection], the body will remain attached to the surface. Snapping is not applied if the body - * moves along [upDirection], meaning it contains vertical rising velocity, so it will be able to - * detach from the ground when jumping or when the body is pushed up by something. If you want to - * apply a snap without taking into account the velocity, use [applyFloorSnap]. + * As long as the snapping vector is in contact with the ground and the body moves against [upDirection], the body will remain attached to the surface. Snapping is not applied if the body moves along [upDirection], meaning it contains vertical rising velocity, so it will be able to detach from the ground when jumping or when the body is pushed up by something. If you want to apply a snap without taking into account the velocity, use [applyFloorSnap]. */ public final inline var floorSnapLength: Float @JvmName("floorSnapLengthProperty") @@ -206,9 +171,7 @@ public open class CharacterBody2D : PhysicsBody2D() { } /** - * Sets the behavior to apply when you leave a moving platform. By default, to be physically - * accurate, when you leave the last platform velocity is applied. See [PlatformOnLeave] constants - * for available behavior. + * Sets the behavior to apply when you leave a moving platform. By default, to be physically accurate, when you leave the last platform velocity is applied. See [PlatformOnLeave] constants for available behavior. */ public final inline var platformOnLeave: PlatformOnLeave @JvmName("platformOnLeaveProperty") @@ -219,9 +182,7 @@ public open class CharacterBody2D : PhysicsBody2D() { } /** - * Collision layers that will be included for detecting floor bodies that will act as moving - * platforms to be followed by the [CharacterBody2D]. By default, all floor bodies are detected and - * propagate their velocity. + * Collision layers that will be included for detecting floor bodies that will act as moving platforms to be followed by the [CharacterBody2D]. By default, all floor bodies are detected and propagate their velocity. */ public final inline var platformFloorLayers: Long @JvmName("platformFloorLayersProperty") @@ -232,8 +193,7 @@ public open class CharacterBody2D : PhysicsBody2D() { } /** - * Collision layers that will be included for detecting wall bodies that will act as moving - * platforms to be followed by the [CharacterBody2D]. By default, all wall bodies are ignored. + * Collision layers that will be included for detecting wall bodies that will act as moving platforms to be followed by the [CharacterBody2D]. By default, all wall bodies are ignored. */ public final inline var platformWallLayers: Long @JvmName("platformWallLayersProperty") @@ -246,15 +206,11 @@ public open class CharacterBody2D : PhysicsBody2D() { /** * Extra margin used for collision recovery when calling [moveAndSlide]. * - * If the body is at least this close to another body, it will consider them to be colliding and - * will be pushed away before performing the actual motion. + * If the body is at least this close to another body, it will consider them to be colliding and will be pushed away before performing the actual motion. * - * A higher value means it's more flexible for detecting collision, which helps with consistently - * detecting walls and floors. + * A higher value means it's more flexible for detecting collision, which helps with consistently detecting walls and floors. * - * A lower value forces the collision algorithm to use more exact detection, so it can be used in - * cases that specifically require precision, e.g at very low scale to avoid visible jittering, or - * for stability with a stack of character bodies. + * A lower value forces the collision algorithm to use more exact detection, so it can be used in cases that specifically require precision, e.g at very low scale to avoid visible jittering, or for stability with a stack of character bodies. */ public final inline var safeMargin: Float @JvmName("safeMarginProperty") @@ -264,7 +220,7 @@ public open class CharacterBody2D : PhysicsBody2D() { setSafeMargin(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(146, scriptIndex) } @@ -279,10 +235,7 @@ public open class CharacterBody2D : PhysicsBody2D() { * characterbody2d.upDirection = myCoreType * `````` * - * Vector pointing upwards, used to determine what is a wall and what is a floor (or a ceiling) - * when calling [moveAndSlide]. Defaults to [Vector2.UP]. As the vector will be normalized it can't - * be equal to [Vector2.ZERO], if you want all collisions to be reported as walls, consider using - * [MOTION_MODE_FLOATING] as [motionMode]. + * Vector pointing upwards, used to determine what is a wall and what is a floor (or a ceiling) when calling [moveAndSlide]. Defaults to [Vector2.UP]. As the vector will be normalized it can't be equal to [Vector2.ZERO], if you want all collisions to be reported as walls, consider using [MOTION_MODE_FLOATING] as [motionMode]. */ @CoreTypeHelper public final fun upDirectionMutate(block: Vector2.() -> Unit): Vector2 = upDirection.apply { @@ -310,18 +263,11 @@ public open class CharacterBody2D : PhysicsBody2D() { } /** - * Moves the body based on [velocity]. If the body collides with another, it will slide along the - * other body (by default only on floor) rather than stop immediately. If the other body is a - * [CharacterBody2D] or [RigidBody2D], it will also be affected by the motion of the other body. You - * can use this to make moving and rotating platforms, or to make nodes push other nodes. + * Moves the body based on [velocity]. If the body collides with another, it will slide along the other body (by default only on floor) rather than stop immediately. If the other body is a [CharacterBody2D] or [RigidBody2D], it will also be affected by the motion of the other body. You can use this to make moving and rotating platforms, or to make nodes push other nodes. * - * Modifies [velocity] if a slide collision occurred. To get the latest collision call - * [getLastSlideCollision], for detailed information about collisions that occurred, use - * [getSlideCollision]. + * Modifies [velocity] if a slide collision occurred. To get the latest collision call [getLastSlideCollision], for detailed information about collisions that occurred, use [getSlideCollision]. * - * When the body touches a moving platform, the platform's velocity is automatically added to the - * body motion. If a collision occurs due to the platform's motion, it will always be first in the - * slide collisions. + * When the body touches a moving platform, the platform's velocity is automatically added to the body motion. If a collision occurs due to the platform's motion, it will always be first in the slide collisions. * * The general behavior and available properties change according to the [motionMode]. * @@ -334,15 +280,14 @@ public open class CharacterBody2D : PhysicsBody2D() { } /** - * Allows to manually apply a snap to the floor regardless of the body's velocity. This function - * does nothing when [isOnFloor] returns `true`. + * Allows to manually apply a snap to the floor regardless of the body's velocity. This function does nothing when [isOnFloor] returns `true`. */ - public final fun applyFloorSnap(): Unit { + public final fun applyFloorSnap() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.applyFloorSnapPtr, NIL) } - public final fun setVelocity(velocity: Vector2): Unit { + public final fun setVelocity(velocity: Vector2) { TransferContext.writeArguments(VECTOR2 to velocity) TransferContext.callMethod(ptr, MethodBindings.setVelocityPtr, NIL) } @@ -353,7 +298,7 @@ public open class CharacterBody2D : PhysicsBody2D() { return (TransferContext.readReturnValue(VECTOR2) as Vector2) } - public final fun setSafeMargin(margin: Float): Unit { + public final fun setSafeMargin(margin: Float) { TransferContext.writeArguments(DOUBLE to margin.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setSafeMarginPtr, NIL) } @@ -370,12 +315,12 @@ public open class CharacterBody2D : PhysicsBody2D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setFloorStopOnSlopeEnabled(enabled: Boolean): Unit { + public final fun setFloorStopOnSlopeEnabled(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setFloorStopOnSlopeEnabledPtr, NIL) } - public final fun setFloorConstantSpeedEnabled(enabled: Boolean): Unit { + public final fun setFloorConstantSpeedEnabled(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setFloorConstantSpeedEnabledPtr, NIL) } @@ -386,7 +331,7 @@ public open class CharacterBody2D : PhysicsBody2D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setFloorBlockOnWallEnabled(enabled: Boolean): Unit { + public final fun setFloorBlockOnWallEnabled(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setFloorBlockOnWallEnabledPtr, NIL) } @@ -397,7 +342,7 @@ public open class CharacterBody2D : PhysicsBody2D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setSlideOnCeilingEnabled(enabled: Boolean): Unit { + public final fun setSlideOnCeilingEnabled(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setSlideOnCeilingEnabledPtr, NIL) } @@ -408,7 +353,7 @@ public open class CharacterBody2D : PhysicsBody2D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setPlatformFloorLayers(excludeLayer: Long): Unit { + public final fun setPlatformFloorLayers(excludeLayer: Long) { TransferContext.writeArguments(LONG to excludeLayer) TransferContext.callMethod(ptr, MethodBindings.setPlatformFloorLayersPtr, NIL) } @@ -419,7 +364,7 @@ public open class CharacterBody2D : PhysicsBody2D() { return (TransferContext.readReturnValue(LONG) as Long) } - public final fun setPlatformWallLayers(excludeLayer: Long): Unit { + public final fun setPlatformWallLayers(excludeLayer: Long) { TransferContext.writeArguments(LONG to excludeLayer) TransferContext.callMethod(ptr, MethodBindings.setPlatformWallLayersPtr, NIL) } @@ -436,7 +381,7 @@ public open class CharacterBody2D : PhysicsBody2D() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setMaxSlides(maxSlides: Int): Unit { + public final fun setMaxSlides(maxSlides: Int) { TransferContext.writeArguments(LONG to maxSlides.toLong()) TransferContext.callMethod(ptr, MethodBindings.setMaxSlidesPtr, NIL) } @@ -447,7 +392,7 @@ public open class CharacterBody2D : PhysicsBody2D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setFloorMaxAngle(radians: Float): Unit { + public final fun setFloorMaxAngle(radians: Float) { TransferContext.writeArguments(DOUBLE to radians.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setFloorMaxAnglePtr, NIL) } @@ -458,7 +403,7 @@ public open class CharacterBody2D : PhysicsBody2D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setFloorSnapLength(floorSnapLength: Float): Unit { + public final fun setFloorSnapLength(floorSnapLength: Float) { TransferContext.writeArguments(DOUBLE to floorSnapLength.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setFloorSnapLengthPtr, NIL) } @@ -469,7 +414,7 @@ public open class CharacterBody2D : PhysicsBody2D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setWallMinSlideAngle(radians: Float): Unit { + public final fun setWallMinSlideAngle(radians: Float) { TransferContext.writeArguments(DOUBLE to radians.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setWallMinSlideAnglePtr, NIL) } @@ -480,12 +425,12 @@ public open class CharacterBody2D : PhysicsBody2D() { return (TransferContext.readReturnValue(VECTOR2) as Vector2) } - public final fun setUpDirection(upDirection: Vector2): Unit { + public final fun setUpDirection(upDirection: Vector2) { TransferContext.writeArguments(VECTOR2 to upDirection) TransferContext.callMethod(ptr, MethodBindings.setUpDirectionPtr, NIL) } - public final fun setMotionMode(mode: MotionMode): Unit { + public final fun setMotionMode(mode: MotionMode) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setMotionModePtr, NIL) } @@ -496,7 +441,7 @@ public open class CharacterBody2D : PhysicsBody2D() { return MotionMode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setPlatformOnLeave(onLeaveApplyVelocity: PlatformOnLeave): Unit { + public final fun setPlatformOnLeave(onLeaveApplyVelocity: PlatformOnLeave) { TransferContext.writeArguments(LONG to onLeaveApplyVelocity.id) TransferContext.callMethod(ptr, MethodBindings.setPlatformOnLeavePtr, NIL) } @@ -508,9 +453,7 @@ public open class CharacterBody2D : PhysicsBody2D() { } /** - * Returns `true` if the body collided with the floor on the last call of [moveAndSlide]. - * Otherwise, returns `false`. The [upDirection] and [floorMaxAngle] are used to determine whether a - * surface is "floor" or not. + * Returns `true` if the body collided with the floor on the last call of [moveAndSlide]. Otherwise, returns `false`. The [upDirection] and [floorMaxAngle] are used to determine whether a surface is "floor" or not. */ public final fun isOnFloor(): Boolean { TransferContext.writeArguments() @@ -519,9 +462,7 @@ public open class CharacterBody2D : PhysicsBody2D() { } /** - * Returns `true` if the body collided only with the floor on the last call of [moveAndSlide]. - * Otherwise, returns `false`. The [upDirection] and [floorMaxAngle] are used to determine whether a - * surface is "floor" or not. + * Returns `true` if the body collided only with the floor on the last call of [moveAndSlide]. Otherwise, returns `false`. The [upDirection] and [floorMaxAngle] are used to determine whether a surface is "floor" or not. */ public final fun isOnFloorOnly(): Boolean { TransferContext.writeArguments() @@ -530,9 +471,7 @@ public open class CharacterBody2D : PhysicsBody2D() { } /** - * Returns `true` if the body collided with the ceiling on the last call of [moveAndSlide]. - * Otherwise, returns `false`. The [upDirection] and [floorMaxAngle] are used to determine whether a - * surface is "ceiling" or not. + * Returns `true` if the body collided with the ceiling on the last call of [moveAndSlide]. Otherwise, returns `false`. The [upDirection] and [floorMaxAngle] are used to determine whether a surface is "ceiling" or not. */ public final fun isOnCeiling(): Boolean { TransferContext.writeArguments() @@ -541,9 +480,7 @@ public open class CharacterBody2D : PhysicsBody2D() { } /** - * Returns `true` if the body collided only with the ceiling on the last call of [moveAndSlide]. - * Otherwise, returns `false`. The [upDirection] and [floorMaxAngle] are used to determine whether a - * surface is "ceiling" or not. + * Returns `true` if the body collided only with the ceiling on the last call of [moveAndSlide]. Otherwise, returns `false`. The [upDirection] and [floorMaxAngle] are used to determine whether a surface is "ceiling" or not. */ public final fun isOnCeilingOnly(): Boolean { TransferContext.writeArguments() @@ -552,9 +489,7 @@ public open class CharacterBody2D : PhysicsBody2D() { } /** - * Returns `true` if the body collided with a wall on the last call of [moveAndSlide]. Otherwise, - * returns `false`. The [upDirection] and [floorMaxAngle] are used to determine whether a surface is - * "wall" or not. + * Returns `true` if the body collided with a wall on the last call of [moveAndSlide]. Otherwise, returns `false`. The [upDirection] and [floorMaxAngle] are used to determine whether a surface is "wall" or not. */ public final fun isOnWall(): Boolean { TransferContext.writeArguments() @@ -563,9 +498,7 @@ public open class CharacterBody2D : PhysicsBody2D() { } /** - * Returns `true` if the body collided only with a wall on the last call of [moveAndSlide]. - * Otherwise, returns `false`. The [upDirection] and [floorMaxAngle] are used to determine whether a - * surface is "wall" or not. + * Returns `true` if the body collided only with a wall on the last call of [moveAndSlide]. Otherwise, returns `false`. The [upDirection] and [floorMaxAngle] are used to determine whether a surface is "wall" or not. */ public final fun isOnWallOnly(): Boolean { TransferContext.writeArguments() @@ -574,8 +507,7 @@ public open class CharacterBody2D : PhysicsBody2D() { } /** - * Returns the collision normal of the floor at the last collision point. Only valid after calling - * [moveAndSlide] and when [isOnFloor] returns `true`. + * Returns the collision normal of the floor at the last collision point. Only valid after calling [moveAndSlide] and when [isOnFloor] returns `true`. * * **Warning:** The collision normal is not always the same as the surface normal. */ @@ -586,8 +518,7 @@ public open class CharacterBody2D : PhysicsBody2D() { } /** - * Returns the collision normal of the wall at the last collision point. Only valid after calling - * [moveAndSlide] and when [isOnWall] returns `true`. + * Returns the collision normal of the wall at the last collision point. Only valid after calling [moveAndSlide] and when [isOnWall] returns `true`. * * **Warning:** The collision normal is not always the same as the surface normal. */ @@ -598,9 +529,7 @@ public open class CharacterBody2D : PhysicsBody2D() { } /** - * Returns the last motion applied to the [CharacterBody2D] during the last call to - * [moveAndSlide]. The movement can be split into multiple motions when sliding occurs, and this - * method return the last one, which is useful to retrieve the current direction of the movement. + * Returns the last motion applied to the [CharacterBody2D] during the last call to [moveAndSlide]. The movement can be split into multiple motions when sliding occurs, and this method return the last one, which is useful to retrieve the current direction of the movement. */ public final fun getLastMotion(): Vector2 { TransferContext.writeArguments() @@ -618,9 +547,7 @@ public open class CharacterBody2D : PhysicsBody2D() { } /** - * Returns the current real velocity since the last call to [moveAndSlide]. For example, when you - * climb a slope, you will move diagonally even though the velocity is horizontal. This method - * returns the diagonal movement, as opposed to [velocity] which returns the requested velocity. + * Returns the current real velocity since the last call to [moveAndSlide]. For example, when you climb a slope, you will move diagonally even though the velocity is horizontal. This method returns the diagonal movement, as opposed to [velocity] which returns the requested velocity. */ public final fun getRealVelocity(): Vector2 { TransferContext.writeArguments() @@ -629,9 +556,7 @@ public open class CharacterBody2D : PhysicsBody2D() { } /** - * Returns the floor's collision angle at the last collision point according to [upDirection], - * which is [Vector2.UP] by default. This value is always positive and only valid after calling - * [moveAndSlide] and when [isOnFloor] returns `true`. + * Returns the floor's collision angle at the last collision point according to [upDirection], which is [Vector2.UP] by default. This value is always positive and only valid after calling [moveAndSlide] and when [isOnFloor] returns `true`. */ @JvmOverloads public final fun getFloorAngle(upDirection: Vector2 = Vector2(0, -1)): Float { @@ -641,8 +566,7 @@ public open class CharacterBody2D : PhysicsBody2D() { } /** - * Returns the linear velocity of the platform at the last collision point. Only valid after - * calling [moveAndSlide]. + * Returns the linear velocity of the platform at the last collision point. Only valid after calling [moveAndSlide]. */ public final fun getPlatformVelocity(): Vector2 { TransferContext.writeArguments() @@ -651,8 +575,7 @@ public open class CharacterBody2D : PhysicsBody2D() { } /** - * Returns the number of times the body collided and changed direction during the last call to - * [moveAndSlide]. + * Returns the number of times the body collided and changed direction during the last call to [moveAndSlide]. */ public final fun getSlideCollisionCount(): Int { TransferContext.writeArguments() @@ -661,10 +584,7 @@ public open class CharacterBody2D : PhysicsBody2D() { } /** - * Returns a [KinematicCollision2D], which contains information about a collision that occurred - * during the last call to [moveAndSlide]. Since the body can collide several times in a single call - * to [moveAndSlide], you must specify the index of the collision in the range 0 to - * ([getSlideCollisionCount] - 1). + * Returns a [KinematicCollision2D], which contains information about a collision that occurred during the last call to [moveAndSlide]. Since the body can collide several times in a single call to [moveAndSlide], you must specify the index of the collision in the range 0 to ([getSlideCollisionCount] - 1). * * **Example:** Iterate through the collisions with a `for` loop: * @@ -691,8 +611,7 @@ public open class CharacterBody2D : PhysicsBody2D() { } /** - * Returns a [KinematicCollision2D], which contains information about the latest collision that - * occurred during the last call to [moveAndSlide]. + * Returns a [KinematicCollision2D], which contains information about the latest collision that occurred during the last call to [moveAndSlide]. */ public final fun getLastSlideCollision(): KinematicCollision2D? { TransferContext.writeArguments() @@ -704,15 +623,11 @@ public open class CharacterBody2D : PhysicsBody2D() { id: Long, ) { /** - * Apply when notions of walls, ceiling and floor are relevant. In this mode the body motion - * will react to slopes (acceleration/slowdown). This mode is suitable for sided games like - * platformers. + * Apply when notions of walls, ceiling and floor are relevant. In this mode the body motion will react to slopes (acceleration/slowdown). This mode is suitable for sided games like platformers. */ GROUNDED(0), /** - * Apply when there is no notion of floor or ceiling. All collisions will be reported as - * `on_wall`. In this mode, when you slide, the speed will always be constant. This mode is - * suitable for top-down games. + * Apply when there is no notion of floor or ceiling. All collisions will be reported as `on_wall`. In this mode, when you slide, the speed will always be constant. This mode is suitable for top-down games. */ FLOATING(1), ; @@ -735,9 +650,7 @@ public open class CharacterBody2D : PhysicsBody2D() { */ ADD_VELOCITY(0), /** - * Add the last platform velocity to the [velocity] when you leave a moving platform, but any - * downward motion is ignored. It's useful to keep full jump height even when the platform is - * moving down. + * Add the last platform velocity to the [velocity] when you leave a moving platform, but any downward motion is ignored. It's useful to keep full jump height even when the platform is moving down. */ ADD_UPWARD_VELOCITY(1), /** @@ -760,147 +673,147 @@ public open class CharacterBody2D : PhysicsBody2D() { public object MethodBindings { internal val moveAndSlidePtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "move_and_slide", 2240911060) + TypeManager.getMethodBindPtr("CharacterBody2D", "move_and_slide", 2_240_911_060) internal val applyFloorSnapPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "apply_floor_snap", 3218959716) + TypeManager.getMethodBindPtr("CharacterBody2D", "apply_floor_snap", 3_218_959_716) internal val setVelocityPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "set_velocity", 743155724) + TypeManager.getMethodBindPtr("CharacterBody2D", "set_velocity", 743_155_724) internal val getVelocityPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "get_velocity", 3341600327) + TypeManager.getMethodBindPtr("CharacterBody2D", "get_velocity", 3_341_600_327) internal val setSafeMarginPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "set_safe_margin", 373806689) + TypeManager.getMethodBindPtr("CharacterBody2D", "set_safe_margin", 373_806_689) internal val getSafeMarginPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "get_safe_margin", 1740695150) + TypeManager.getMethodBindPtr("CharacterBody2D", "get_safe_margin", 1_740_695_150) internal val isFloorStopOnSlopeEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "is_floor_stop_on_slope_enabled", 36873697) + TypeManager.getMethodBindPtr("CharacterBody2D", "is_floor_stop_on_slope_enabled", 36_873_697) internal val setFloorStopOnSlopeEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "set_floor_stop_on_slope_enabled", 2586408642) + TypeManager.getMethodBindPtr("CharacterBody2D", "set_floor_stop_on_slope_enabled", 2_586_408_642) internal val setFloorConstantSpeedEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "set_floor_constant_speed_enabled", 2586408642) + TypeManager.getMethodBindPtr("CharacterBody2D", "set_floor_constant_speed_enabled", 2_586_408_642) internal val isFloorConstantSpeedEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "is_floor_constant_speed_enabled", 36873697) + TypeManager.getMethodBindPtr("CharacterBody2D", "is_floor_constant_speed_enabled", 36_873_697) internal val setFloorBlockOnWallEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "set_floor_block_on_wall_enabled", 2586408642) + TypeManager.getMethodBindPtr("CharacterBody2D", "set_floor_block_on_wall_enabled", 2_586_408_642) internal val isFloorBlockOnWallEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "is_floor_block_on_wall_enabled", 36873697) + TypeManager.getMethodBindPtr("CharacterBody2D", "is_floor_block_on_wall_enabled", 36_873_697) internal val setSlideOnCeilingEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "set_slide_on_ceiling_enabled", 2586408642) + TypeManager.getMethodBindPtr("CharacterBody2D", "set_slide_on_ceiling_enabled", 2_586_408_642) internal val isSlideOnCeilingEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "is_slide_on_ceiling_enabled", 36873697) + TypeManager.getMethodBindPtr("CharacterBody2D", "is_slide_on_ceiling_enabled", 36_873_697) internal val setPlatformFloorLayersPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "set_platform_floor_layers", 1286410249) + TypeManager.getMethodBindPtr("CharacterBody2D", "set_platform_floor_layers", 1_286_410_249) internal val getPlatformFloorLayersPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "get_platform_floor_layers", 3905245786) + TypeManager.getMethodBindPtr("CharacterBody2D", "get_platform_floor_layers", 3_905_245_786) internal val setPlatformWallLayersPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "set_platform_wall_layers", 1286410249) + TypeManager.getMethodBindPtr("CharacterBody2D", "set_platform_wall_layers", 1_286_410_249) internal val getPlatformWallLayersPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "get_platform_wall_layers", 3905245786) + TypeManager.getMethodBindPtr("CharacterBody2D", "get_platform_wall_layers", 3_905_245_786) internal val getMaxSlidesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "get_max_slides", 3905245786) + TypeManager.getMethodBindPtr("CharacterBody2D", "get_max_slides", 3_905_245_786) internal val setMaxSlidesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "set_max_slides", 1286410249) + TypeManager.getMethodBindPtr("CharacterBody2D", "set_max_slides", 1_286_410_249) internal val getFloorMaxAnglePtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "get_floor_max_angle", 1740695150) + TypeManager.getMethodBindPtr("CharacterBody2D", "get_floor_max_angle", 1_740_695_150) internal val setFloorMaxAnglePtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "set_floor_max_angle", 373806689) + TypeManager.getMethodBindPtr("CharacterBody2D", "set_floor_max_angle", 373_806_689) internal val getFloorSnapLengthPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "get_floor_snap_length", 191475506) + TypeManager.getMethodBindPtr("CharacterBody2D", "get_floor_snap_length", 191_475_506) internal val setFloorSnapLengthPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "set_floor_snap_length", 373806689) + TypeManager.getMethodBindPtr("CharacterBody2D", "set_floor_snap_length", 373_806_689) internal val getWallMinSlideAnglePtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "get_wall_min_slide_angle", 1740695150) + TypeManager.getMethodBindPtr("CharacterBody2D", "get_wall_min_slide_angle", 1_740_695_150) internal val setWallMinSlideAnglePtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "set_wall_min_slide_angle", 373806689) + TypeManager.getMethodBindPtr("CharacterBody2D", "set_wall_min_slide_angle", 373_806_689) internal val getUpDirectionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "get_up_direction", 3341600327) + TypeManager.getMethodBindPtr("CharacterBody2D", "get_up_direction", 3_341_600_327) internal val setUpDirectionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "set_up_direction", 743155724) + TypeManager.getMethodBindPtr("CharacterBody2D", "set_up_direction", 743_155_724) internal val setMotionModePtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "set_motion_mode", 1224392233) + TypeManager.getMethodBindPtr("CharacterBody2D", "set_motion_mode", 1_224_392_233) internal val getMotionModePtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "get_motion_mode", 1160151236) + TypeManager.getMethodBindPtr("CharacterBody2D", "get_motion_mode", 1_160_151_236) internal val setPlatformOnLeavePtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "set_platform_on_leave", 2423324375) + TypeManager.getMethodBindPtr("CharacterBody2D", "set_platform_on_leave", 2_423_324_375) internal val getPlatformOnLeavePtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "get_platform_on_leave", 4054324341) + TypeManager.getMethodBindPtr("CharacterBody2D", "get_platform_on_leave", 4_054_324_341) internal val isOnFloorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "is_on_floor", 36873697) + TypeManager.getMethodBindPtr("CharacterBody2D", "is_on_floor", 36_873_697) internal val isOnFloorOnlyPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "is_on_floor_only", 36873697) + TypeManager.getMethodBindPtr("CharacterBody2D", "is_on_floor_only", 36_873_697) internal val isOnCeilingPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "is_on_ceiling", 36873697) + TypeManager.getMethodBindPtr("CharacterBody2D", "is_on_ceiling", 36_873_697) internal val isOnCeilingOnlyPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "is_on_ceiling_only", 36873697) + TypeManager.getMethodBindPtr("CharacterBody2D", "is_on_ceiling_only", 36_873_697) internal val isOnWallPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "is_on_wall", 36873697) + TypeManager.getMethodBindPtr("CharacterBody2D", "is_on_wall", 36_873_697) internal val isOnWallOnlyPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "is_on_wall_only", 36873697) + TypeManager.getMethodBindPtr("CharacterBody2D", "is_on_wall_only", 36_873_697) internal val getFloorNormalPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "get_floor_normal", 3341600327) + TypeManager.getMethodBindPtr("CharacterBody2D", "get_floor_normal", 3_341_600_327) internal val getWallNormalPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "get_wall_normal", 3341600327) + TypeManager.getMethodBindPtr("CharacterBody2D", "get_wall_normal", 3_341_600_327) internal val getLastMotionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "get_last_motion", 3341600327) + TypeManager.getMethodBindPtr("CharacterBody2D", "get_last_motion", 3_341_600_327) internal val getPositionDeltaPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "get_position_delta", 3341600327) + TypeManager.getMethodBindPtr("CharacterBody2D", "get_position_delta", 3_341_600_327) internal val getRealVelocityPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "get_real_velocity", 3341600327) + TypeManager.getMethodBindPtr("CharacterBody2D", "get_real_velocity", 3_341_600_327) internal val getFloorAnglePtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "get_floor_angle", 2841063350) + TypeManager.getMethodBindPtr("CharacterBody2D", "get_floor_angle", 2_841_063_350) internal val getPlatformVelocityPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "get_platform_velocity", 3341600327) + TypeManager.getMethodBindPtr("CharacterBody2D", "get_platform_velocity", 3_341_600_327) internal val getSlideCollisionCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "get_slide_collision_count", 3905245786) + TypeManager.getMethodBindPtr("CharacterBody2D", "get_slide_collision_count", 3_905_245_786) internal val getSlideCollisionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "get_slide_collision", 860659811) + TypeManager.getMethodBindPtr("CharacterBody2D", "get_slide_collision", 860_659_811) internal val getLastSlideCollisionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody2D", "get_last_slide_collision", 2161834755) + TypeManager.getMethodBindPtr("CharacterBody2D", "get_last_slide_collision", 2_161_834_755) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CharacterBody3D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CharacterBody3D.kt index 34899297d0..6a5b5234db 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CharacterBody3D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CharacterBody3D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -30,22 +27,14 @@ import kotlin.jvm.JvmName import kotlin.jvm.JvmOverloads /** - * [CharacterBody3D] is a specialized class for physics bodies that are meant to be user-controlled. - * They are not affected by physics at all, but they affect other physics bodies in their path. They - * are mainly used to provide high-level API to move objects with wall and slope detection - * ([moveAndSlide] method) in addition to the general collision detection provided by - * [PhysicsBody3D.moveAndCollide]. This makes it useful for highly configurable physics bodies that - * must move in specific ways and collide with the world, as is often the case with user-controlled - * characters. + * [CharacterBody3D] is a specialized class for physics bodies that are meant to be user-controlled. They are not affected by physics at all, but they affect other physics bodies in their path. They are mainly used to provide high-level API to move objects with wall and slope detection ([moveAndSlide] method) in addition to the general collision detection provided by [PhysicsBody3D.moveAndCollide]. This makes it useful for highly configurable physics bodies that must move in specific ways and collide with the world, as is often the case with user-controlled characters. * - * For game objects that don't require complex movement or collision detection, such as moving - * platforms, [AnimatableBody3D] is simpler to configure. + * For game objects that don't require complex movement or collision detection, such as moving platforms, [AnimatableBody3D] is simpler to configure. */ @GodotBaseType public open class CharacterBody3D : PhysicsBody3D() { /** - * Sets the motion mode which defines the behavior of [moveAndSlide]. See [MotionMode] constants - * for available modes. + * Sets the motion mode which defines the behavior of [moveAndSlide]. See [MotionMode] constants for available modes. */ public final inline var motionMode: MotionMode @JvmName("motionModeProperty") @@ -56,17 +45,11 @@ public open class CharacterBody3D : PhysicsBody3D() { } /** - * Vector pointing upwards, used to determine what is a wall and what is a floor (or a ceiling) - * when calling [moveAndSlide]. Defaults to [Vector3.UP]. As the vector will be normalized it can't - * be equal to [Vector3.ZERO], if you want all collisions to be reported as walls, consider using - * [MOTION_MODE_FLOATING] as [motionMode]. + * Vector pointing upwards, used to determine what is a wall and what is a floor (or a ceiling) when calling [moveAndSlide]. Defaults to [Vector3.UP]. As the vector will be normalized it can't be equal to [Vector3.ZERO], if you want all collisions to be reported as walls, consider using [MOTION_MODE_FLOATING] as [motionMode]. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var upDirection: Vector3 @@ -78,8 +61,7 @@ public open class CharacterBody3D : PhysicsBody3D() { } /** - * If `true`, during a jump against the ceiling, the body will slide, if `false` it will be - * stopped and will fall vertically. + * If `true`, during a jump against the ceiling, the body will slide, if `false` it will be stopped and will fall vertically. */ public final inline var slideOnCeiling: Boolean @JvmName("slideOnCeilingProperty") @@ -90,15 +72,11 @@ public open class CharacterBody3D : PhysicsBody3D() { } /** - * Current velocity vector (typically meters per second), used and modified during calls to - * [moveAndSlide]. + * Current velocity vector (typically meters per second), used and modified during calls to [moveAndSlide]. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var velocity: Vector3 @@ -110,8 +88,7 @@ public open class CharacterBody3D : PhysicsBody3D() { } /** - * Maximum number of times the body can change direction before it stops when calling - * [moveAndSlide]. + * Maximum number of times the body can change direction before it stops when calling [moveAndSlide]. */ public final inline var maxSlides: Int @JvmName("maxSlidesProperty") @@ -122,9 +99,7 @@ public open class CharacterBody3D : PhysicsBody3D() { } /** - * Minimum angle (in radians) where the body is allowed to slide when it encounters a slope. The - * default value equals 15 degrees. When [motionMode] is [MOTION_MODE_GROUNDED], it only affects - * movement if [floorBlockOnWall] is `true`. + * Minimum angle (in radians) where the body is allowed to slide when it encounters a slope. The default value equals 15 degrees. When [motionMode] is [MOTION_MODE_GROUNDED], it only affects movement if [floorBlockOnWall] is `true`. */ public final inline var wallMinSlideAngle: Float @JvmName("wallMinSlideAngleProperty") @@ -135,8 +110,7 @@ public open class CharacterBody3D : PhysicsBody3D() { } /** - * If `true`, the body will not slide on slopes when calling [moveAndSlide] when the body is - * standing still. + * If `true`, the body will not slide on slopes when calling [moveAndSlide] when the body is standing still. * * If `false`, the body will slide on floor's slopes when [velocity] applies a downward force. */ @@ -149,11 +123,9 @@ public open class CharacterBody3D : PhysicsBody3D() { } /** - * If `false` (by default), the body will move faster on downward slopes and slower on upward - * slopes. + * If `false` (by default), the body will move faster on downward slopes and slower on upward slopes. * - * If `true`, the body will always move at the same speed on the ground no matter the slope. Note - * that you need to use [floorSnapLength] to stick along a downward slope at constant speed. + * If `true`, the body will always move at the same speed on the ground no matter the slope. Note that you need to use [floorSnapLength] to stick along a downward slope at constant speed. */ public final inline var floorConstantSpeed: Boolean @JvmName("floorConstantSpeedProperty") @@ -164,8 +136,7 @@ public open class CharacterBody3D : PhysicsBody3D() { } /** - * If `true`, the body will be able to move on the floor only. This option avoids to be able to - * walk on walls, it will however allow to slide down along them. + * If `true`, the body will be able to move on the floor only. This option avoids to be able to walk on walls, it will however allow to slide down along them. */ public final inline var floorBlockOnWall: Boolean @JvmName("floorBlockOnWallProperty") @@ -176,8 +147,7 @@ public open class CharacterBody3D : PhysicsBody3D() { } /** - * Maximum angle (in radians) where a slope is still considered a floor (or a ceiling), rather - * than a wall, when calling [moveAndSlide]. The default value equals 45 degrees. + * Maximum angle (in radians) where a slope is still considered a floor (or a ceiling), rather than a wall, when calling [moveAndSlide]. The default value equals 45 degrees. */ public final inline var floorMaxAngle: Float @JvmName("floorMaxAngleProperty") @@ -188,15 +158,9 @@ public open class CharacterBody3D : PhysicsBody3D() { } /** - * Sets a snapping distance. When set to a value different from `0.0`, the body is kept attached - * to slopes when calling [moveAndSlide]. The snapping vector is determined by the given distance - * along the opposite direction of the [upDirection]. + * Sets a snapping distance. When set to a value different from `0.0`, the body is kept attached to slopes when calling [moveAndSlide]. The snapping vector is determined by the given distance along the opposite direction of the [upDirection]. * - * As long as the snapping vector is in contact with the ground and the body moves against - * [upDirection], the body will remain attached to the surface. Snapping is not applied if the body - * moves along [upDirection], meaning it contains vertical rising velocity, so it will be able to - * detach from the ground when jumping or when the body is pushed up by something. If you want to - * apply a snap without taking into account the velocity, use [applyFloorSnap]. + * As long as the snapping vector is in contact with the ground and the body moves against [upDirection], the body will remain attached to the surface. Snapping is not applied if the body moves along [upDirection], meaning it contains vertical rising velocity, so it will be able to detach from the ground when jumping or when the body is pushed up by something. If you want to apply a snap without taking into account the velocity, use [applyFloorSnap]. */ public final inline var floorSnapLength: Float @JvmName("floorSnapLengthProperty") @@ -207,9 +171,7 @@ public open class CharacterBody3D : PhysicsBody3D() { } /** - * Sets the behavior to apply when you leave a moving platform. By default, to be physically - * accurate, when you leave the last platform velocity is applied. See [PlatformOnLeave] constants - * for available behavior. + * Sets the behavior to apply when you leave a moving platform. By default, to be physically accurate, when you leave the last platform velocity is applied. See [PlatformOnLeave] constants for available behavior. */ public final inline var platformOnLeave: PlatformOnLeave @JvmName("platformOnLeaveProperty") @@ -220,9 +182,7 @@ public open class CharacterBody3D : PhysicsBody3D() { } /** - * Collision layers that will be included for detecting floor bodies that will act as moving - * platforms to be followed by the [CharacterBody3D]. By default, all floor bodies are detected and - * propagate their velocity. + * Collision layers that will be included for detecting floor bodies that will act as moving platforms to be followed by the [CharacterBody3D]. By default, all floor bodies are detected and propagate their velocity. */ public final inline var platformFloorLayers: Long @JvmName("platformFloorLayersProperty") @@ -233,8 +193,7 @@ public open class CharacterBody3D : PhysicsBody3D() { } /** - * Collision layers that will be included for detecting wall bodies that will act as moving - * platforms to be followed by the [CharacterBody3D]. By default, all wall bodies are ignored. + * Collision layers that will be included for detecting wall bodies that will act as moving platforms to be followed by the [CharacterBody3D]. By default, all wall bodies are ignored. */ public final inline var platformWallLayers: Long @JvmName("platformWallLayersProperty") @@ -247,15 +206,11 @@ public open class CharacterBody3D : PhysicsBody3D() { /** * Extra margin used for collision recovery when calling [moveAndSlide]. * - * If the body is at least this close to another body, it will consider them to be colliding and - * will be pushed away before performing the actual motion. + * If the body is at least this close to another body, it will consider them to be colliding and will be pushed away before performing the actual motion. * - * A higher value means it's more flexible for detecting collision, which helps with consistently - * detecting walls and floors. + * A higher value means it's more flexible for detecting collision, which helps with consistently detecting walls and floors. * - * A lower value forces the collision algorithm to use more exact detection, so it can be used in - * cases that specifically require precision, e.g at very low scale to avoid visible jittering, or - * for stability with a stack of character bodies. + * A lower value forces the collision algorithm to use more exact detection, so it can be used in cases that specifically require precision, e.g at very low scale to avoid visible jittering, or for stability with a stack of character bodies. */ public final inline var safeMargin: Float @JvmName("safeMarginProperty") @@ -265,7 +220,7 @@ public open class CharacterBody3D : PhysicsBody3D() { setSafeMargin(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(147, scriptIndex) } @@ -280,10 +235,7 @@ public open class CharacterBody3D : PhysicsBody3D() { * characterbody3d.upDirection = myCoreType * `````` * - * Vector pointing upwards, used to determine what is a wall and what is a floor (or a ceiling) - * when calling [moveAndSlide]. Defaults to [Vector3.UP]. As the vector will be normalized it can't - * be equal to [Vector3.ZERO], if you want all collisions to be reported as walls, consider using - * [MOTION_MODE_FLOATING] as [motionMode]. + * Vector pointing upwards, used to determine what is a wall and what is a floor (or a ceiling) when calling [moveAndSlide]. Defaults to [Vector3.UP]. As the vector will be normalized it can't be equal to [Vector3.ZERO], if you want all collisions to be reported as walls, consider using [MOTION_MODE_FLOATING] as [motionMode]. */ @CoreTypeHelper public final fun upDirectionMutate(block: Vector3.() -> Unit): Vector3 = upDirection.apply { @@ -302,8 +254,7 @@ public open class CharacterBody3D : PhysicsBody3D() { * characterbody3d.velocity = myCoreType * `````` * - * Current velocity vector (typically meters per second), used and modified during calls to - * [moveAndSlide]. + * Current velocity vector (typically meters per second), used and modified during calls to [moveAndSlide]. */ @CoreTypeHelper public final fun velocityMutate(block: Vector3.() -> Unit): Vector3 = velocity.apply { @@ -312,18 +263,11 @@ public open class CharacterBody3D : PhysicsBody3D() { } /** - * Moves the body based on [velocity]. If the body collides with another, it will slide along the - * other body rather than stop immediately. If the other body is a [CharacterBody3D] or - * [RigidBody3D], it will also be affected by the motion of the other body. You can use this to make - * moving and rotating platforms, or to make nodes push other nodes. + * Moves the body based on [velocity]. If the body collides with another, it will slide along the other body rather than stop immediately. If the other body is a [CharacterBody3D] or [RigidBody3D], it will also be affected by the motion of the other body. You can use this to make moving and rotating platforms, or to make nodes push other nodes. * - * Modifies [velocity] if a slide collision occurred. To get the latest collision call - * [getLastSlideCollision], for more detailed information about collisions that occurred, use - * [getSlideCollision]. + * Modifies [velocity] if a slide collision occurred. To get the latest collision call [getLastSlideCollision], for more detailed information about collisions that occurred, use [getSlideCollision]. * - * When the body touches a moving platform, the platform's velocity is automatically added to the - * body motion. If a collision occurs due to the platform's motion, it will always be first in the - * slide collisions. + * When the body touches a moving platform, the platform's velocity is automatically added to the body motion. If a collision occurs due to the platform's motion, it will always be first in the slide collisions. * * Returns `true` if the body collided, otherwise, returns `false`. */ @@ -334,15 +278,14 @@ public open class CharacterBody3D : PhysicsBody3D() { } /** - * Allows to manually apply a snap to the floor regardless of the body's velocity. This function - * does nothing when [isOnFloor] returns `true`. + * Allows to manually apply a snap to the floor regardless of the body's velocity. This function does nothing when [isOnFloor] returns `true`. */ - public final fun applyFloorSnap(): Unit { + public final fun applyFloorSnap() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.applyFloorSnapPtr, NIL) } - public final fun setVelocity(velocity: Vector3): Unit { + public final fun setVelocity(velocity: Vector3) { TransferContext.writeArguments(VECTOR3 to velocity) TransferContext.callMethod(ptr, MethodBindings.setVelocityPtr, NIL) } @@ -353,7 +296,7 @@ public open class CharacterBody3D : PhysicsBody3D() { return (TransferContext.readReturnValue(VECTOR3) as Vector3) } - public final fun setSafeMargin(margin: Float): Unit { + public final fun setSafeMargin(margin: Float) { TransferContext.writeArguments(DOUBLE to margin.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setSafeMarginPtr, NIL) } @@ -370,12 +313,12 @@ public open class CharacterBody3D : PhysicsBody3D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setFloorStopOnSlopeEnabled(enabled: Boolean): Unit { + public final fun setFloorStopOnSlopeEnabled(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setFloorStopOnSlopeEnabledPtr, NIL) } - public final fun setFloorConstantSpeedEnabled(enabled: Boolean): Unit { + public final fun setFloorConstantSpeedEnabled(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setFloorConstantSpeedEnabledPtr, NIL) } @@ -386,7 +329,7 @@ public open class CharacterBody3D : PhysicsBody3D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setFloorBlockOnWallEnabled(enabled: Boolean): Unit { + public final fun setFloorBlockOnWallEnabled(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setFloorBlockOnWallEnabledPtr, NIL) } @@ -397,7 +340,7 @@ public open class CharacterBody3D : PhysicsBody3D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setSlideOnCeilingEnabled(enabled: Boolean): Unit { + public final fun setSlideOnCeilingEnabled(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setSlideOnCeilingEnabledPtr, NIL) } @@ -408,7 +351,7 @@ public open class CharacterBody3D : PhysicsBody3D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setPlatformFloorLayers(excludeLayer: Long): Unit { + public final fun setPlatformFloorLayers(excludeLayer: Long) { TransferContext.writeArguments(LONG to excludeLayer) TransferContext.callMethod(ptr, MethodBindings.setPlatformFloorLayersPtr, NIL) } @@ -419,7 +362,7 @@ public open class CharacterBody3D : PhysicsBody3D() { return (TransferContext.readReturnValue(LONG) as Long) } - public final fun setPlatformWallLayers(excludeLayer: Long): Unit { + public final fun setPlatformWallLayers(excludeLayer: Long) { TransferContext.writeArguments(LONG to excludeLayer) TransferContext.callMethod(ptr, MethodBindings.setPlatformWallLayersPtr, NIL) } @@ -436,7 +379,7 @@ public open class CharacterBody3D : PhysicsBody3D() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setMaxSlides(maxSlides: Int): Unit { + public final fun setMaxSlides(maxSlides: Int) { TransferContext.writeArguments(LONG to maxSlides.toLong()) TransferContext.callMethod(ptr, MethodBindings.setMaxSlidesPtr, NIL) } @@ -447,7 +390,7 @@ public open class CharacterBody3D : PhysicsBody3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setFloorMaxAngle(radians: Float): Unit { + public final fun setFloorMaxAngle(radians: Float) { TransferContext.writeArguments(DOUBLE to radians.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setFloorMaxAnglePtr, NIL) } @@ -458,7 +401,7 @@ public open class CharacterBody3D : PhysicsBody3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setFloorSnapLength(floorSnapLength: Float): Unit { + public final fun setFloorSnapLength(floorSnapLength: Float) { TransferContext.writeArguments(DOUBLE to floorSnapLength.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setFloorSnapLengthPtr, NIL) } @@ -469,7 +412,7 @@ public open class CharacterBody3D : PhysicsBody3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setWallMinSlideAngle(radians: Float): Unit { + public final fun setWallMinSlideAngle(radians: Float) { TransferContext.writeArguments(DOUBLE to radians.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setWallMinSlideAnglePtr, NIL) } @@ -480,12 +423,12 @@ public open class CharacterBody3D : PhysicsBody3D() { return (TransferContext.readReturnValue(VECTOR3) as Vector3) } - public final fun setUpDirection(upDirection: Vector3): Unit { + public final fun setUpDirection(upDirection: Vector3) { TransferContext.writeArguments(VECTOR3 to upDirection) TransferContext.callMethod(ptr, MethodBindings.setUpDirectionPtr, NIL) } - public final fun setMotionMode(mode: MotionMode): Unit { + public final fun setMotionMode(mode: MotionMode) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setMotionModePtr, NIL) } @@ -496,7 +439,7 @@ public open class CharacterBody3D : PhysicsBody3D() { return MotionMode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setPlatformOnLeave(onLeaveApplyVelocity: PlatformOnLeave): Unit { + public final fun setPlatformOnLeave(onLeaveApplyVelocity: PlatformOnLeave) { TransferContext.writeArguments(LONG to onLeaveApplyVelocity.id) TransferContext.callMethod(ptr, MethodBindings.setPlatformOnLeavePtr, NIL) } @@ -508,9 +451,7 @@ public open class CharacterBody3D : PhysicsBody3D() { } /** - * Returns `true` if the body collided with the floor on the last call of [moveAndSlide]. - * Otherwise, returns `false`. The [upDirection] and [floorMaxAngle] are used to determine whether a - * surface is "floor" or not. + * Returns `true` if the body collided with the floor on the last call of [moveAndSlide]. Otherwise, returns `false`. The [upDirection] and [floorMaxAngle] are used to determine whether a surface is "floor" or not. */ public final fun isOnFloor(): Boolean { TransferContext.writeArguments() @@ -519,9 +460,7 @@ public open class CharacterBody3D : PhysicsBody3D() { } /** - * Returns `true` if the body collided only with the floor on the last call of [moveAndSlide]. - * Otherwise, returns `false`. The [upDirection] and [floorMaxAngle] are used to determine whether a - * surface is "floor" or not. + * Returns `true` if the body collided only with the floor on the last call of [moveAndSlide]. Otherwise, returns `false`. The [upDirection] and [floorMaxAngle] are used to determine whether a surface is "floor" or not. */ public final fun isOnFloorOnly(): Boolean { TransferContext.writeArguments() @@ -530,9 +469,7 @@ public open class CharacterBody3D : PhysicsBody3D() { } /** - * Returns `true` if the body collided with the ceiling on the last call of [moveAndSlide]. - * Otherwise, returns `false`. The [upDirection] and [floorMaxAngle] are used to determine whether a - * surface is "ceiling" or not. + * Returns `true` if the body collided with the ceiling on the last call of [moveAndSlide]. Otherwise, returns `false`. The [upDirection] and [floorMaxAngle] are used to determine whether a surface is "ceiling" or not. */ public final fun isOnCeiling(): Boolean { TransferContext.writeArguments() @@ -541,9 +478,7 @@ public open class CharacterBody3D : PhysicsBody3D() { } /** - * Returns `true` if the body collided only with the ceiling on the last call of [moveAndSlide]. - * Otherwise, returns `false`. The [upDirection] and [floorMaxAngle] are used to determine whether a - * surface is "ceiling" or not. + * Returns `true` if the body collided only with the ceiling on the last call of [moveAndSlide]. Otherwise, returns `false`. The [upDirection] and [floorMaxAngle] are used to determine whether a surface is "ceiling" or not. */ public final fun isOnCeilingOnly(): Boolean { TransferContext.writeArguments() @@ -552,9 +487,7 @@ public open class CharacterBody3D : PhysicsBody3D() { } /** - * Returns `true` if the body collided with a wall on the last call of [moveAndSlide]. Otherwise, - * returns `false`. The [upDirection] and [floorMaxAngle] are used to determine whether a surface is - * "wall" or not. + * Returns `true` if the body collided with a wall on the last call of [moveAndSlide]. Otherwise, returns `false`. The [upDirection] and [floorMaxAngle] are used to determine whether a surface is "wall" or not. */ public final fun isOnWall(): Boolean { TransferContext.writeArguments() @@ -563,9 +496,7 @@ public open class CharacterBody3D : PhysicsBody3D() { } /** - * Returns `true` if the body collided only with a wall on the last call of [moveAndSlide]. - * Otherwise, returns `false`. The [upDirection] and [floorMaxAngle] are used to determine whether a - * surface is "wall" or not. + * Returns `true` if the body collided only with a wall on the last call of [moveAndSlide]. Otherwise, returns `false`. The [upDirection] and [floorMaxAngle] are used to determine whether a surface is "wall" or not. */ public final fun isOnWallOnly(): Boolean { TransferContext.writeArguments() @@ -574,8 +505,7 @@ public open class CharacterBody3D : PhysicsBody3D() { } /** - * Returns the collision normal of the floor at the last collision point. Only valid after calling - * [moveAndSlide] and when [isOnFloor] returns `true`. + * Returns the collision normal of the floor at the last collision point. Only valid after calling [moveAndSlide] and when [isOnFloor] returns `true`. * * **Warning:** The collision normal is not always the same as the surface normal. */ @@ -586,8 +516,7 @@ public open class CharacterBody3D : PhysicsBody3D() { } /** - * Returns the collision normal of the wall at the last collision point. Only valid after calling - * [moveAndSlide] and when [isOnWall] returns `true`. + * Returns the collision normal of the wall at the last collision point. Only valid after calling [moveAndSlide] and when [isOnWall] returns `true`. * * **Warning:** The collision normal is not always the same as the surface normal. */ @@ -598,9 +527,7 @@ public open class CharacterBody3D : PhysicsBody3D() { } /** - * Returns the last motion applied to the [CharacterBody3D] during the last call to - * [moveAndSlide]. The movement can be split into multiple motions when sliding occurs, and this - * method return the last one, which is useful to retrieve the current direction of the movement. + * Returns the last motion applied to the [CharacterBody3D] during the last call to [moveAndSlide]. The movement can be split into multiple motions when sliding occurs, and this method return the last one, which is useful to retrieve the current direction of the movement. */ public final fun getLastMotion(): Vector3 { TransferContext.writeArguments() @@ -618,9 +545,7 @@ public open class CharacterBody3D : PhysicsBody3D() { } /** - * Returns the current real velocity since the last call to [moveAndSlide]. For example, when you - * climb a slope, you will move diagonally even though the velocity is horizontal. This method - * returns the diagonal movement, as opposed to [velocity] which returns the requested velocity. + * Returns the current real velocity since the last call to [moveAndSlide]. For example, when you climb a slope, you will move diagonally even though the velocity is horizontal. This method returns the diagonal movement, as opposed to [velocity] which returns the requested velocity. */ public final fun getRealVelocity(): Vector3 { TransferContext.writeArguments() @@ -629,9 +554,7 @@ public open class CharacterBody3D : PhysicsBody3D() { } /** - * Returns the floor's collision angle at the last collision point according to [upDirection], - * which is [Vector3.UP] by default. This value is always positive and only valid after calling - * [moveAndSlide] and when [isOnFloor] returns `true`. + * Returns the floor's collision angle at the last collision point according to [upDirection], which is [Vector3.UP] by default. This value is always positive and only valid after calling [moveAndSlide] and when [isOnFloor] returns `true`. */ @JvmOverloads public final fun getFloorAngle(upDirection: Vector3 = Vector3(0, 1, 0)): Float { @@ -641,8 +564,7 @@ public open class CharacterBody3D : PhysicsBody3D() { } /** - * Returns the linear velocity of the platform at the last collision point. Only valid after - * calling [moveAndSlide]. + * Returns the linear velocity of the platform at the last collision point. Only valid after calling [moveAndSlide]. */ public final fun getPlatformVelocity(): Vector3 { TransferContext.writeArguments() @@ -651,8 +573,7 @@ public open class CharacterBody3D : PhysicsBody3D() { } /** - * Returns the angular velocity of the platform at the last collision point. Only valid after - * calling [moveAndSlide]. + * Returns the angular velocity of the platform at the last collision point. Only valid after calling [moveAndSlide]. */ public final fun getPlatformAngularVelocity(): Vector3 { TransferContext.writeArguments() @@ -661,8 +582,7 @@ public open class CharacterBody3D : PhysicsBody3D() { } /** - * Returns the number of times the body collided and changed direction during the last call to - * [moveAndSlide]. + * Returns the number of times the body collided and changed direction during the last call to [moveAndSlide]. */ public final fun getSlideCollisionCount(): Int { TransferContext.writeArguments() @@ -671,10 +591,7 @@ public open class CharacterBody3D : PhysicsBody3D() { } /** - * Returns a [KinematicCollision3D], which contains information about a collision that occurred - * during the last call to [moveAndSlide]. Since the body can collide several times in a single call - * to [moveAndSlide], you must specify the index of the collision in the range 0 to - * ([getSlideCollisionCount] - 1). + * Returns a [KinematicCollision3D], which contains information about a collision that occurred during the last call to [moveAndSlide]. Since the body can collide several times in a single call to [moveAndSlide], you must specify the index of the collision in the range 0 to ([getSlideCollisionCount] - 1). */ public final fun getSlideCollision(slideIdx: Int): KinematicCollision3D? { TransferContext.writeArguments(LONG to slideIdx.toLong()) @@ -683,8 +600,7 @@ public open class CharacterBody3D : PhysicsBody3D() { } /** - * Returns a [KinematicCollision3D], which contains information about the latest collision that - * occurred during the last call to [moveAndSlide]. + * Returns a [KinematicCollision3D], which contains information about the latest collision that occurred during the last call to [moveAndSlide]. */ public final fun getLastSlideCollision(): KinematicCollision3D? { TransferContext.writeArguments() @@ -696,15 +612,11 @@ public open class CharacterBody3D : PhysicsBody3D() { id: Long, ) { /** - * Apply when notions of walls, ceiling and floor are relevant. In this mode the body motion - * will react to slopes (acceleration/slowdown). This mode is suitable for grounded games like - * platformers. + * Apply when notions of walls, ceiling and floor are relevant. In this mode the body motion will react to slopes (acceleration/slowdown). This mode is suitable for grounded games like platformers. */ GROUNDED(0), /** - * Apply when there is no notion of floor or ceiling. All collisions will be reported as - * `on_wall`. In this mode, when you slide, the speed will always be constant. This mode is - * suitable for games without ground like space games. + * Apply when there is no notion of floor or ceiling. All collisions will be reported as `on_wall`. In this mode, when you slide, the speed will always be constant. This mode is suitable for games without ground like space games. */ FLOATING(1), ; @@ -727,9 +639,7 @@ public open class CharacterBody3D : PhysicsBody3D() { */ ADD_VELOCITY(0), /** - * Add the last platform velocity to the [velocity] when you leave a moving platform, but any - * downward motion is ignored. It's useful to keep full jump height even when the platform is - * moving down. + * Add the last platform velocity to the [velocity] when you leave a moving platform, but any downward motion is ignored. It's useful to keep full jump height even when the platform is moving down. */ ADD_UPWARD_VELOCITY(1), /** @@ -752,150 +662,150 @@ public open class CharacterBody3D : PhysicsBody3D() { public object MethodBindings { internal val moveAndSlidePtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "move_and_slide", 2240911060) + TypeManager.getMethodBindPtr("CharacterBody3D", "move_and_slide", 2_240_911_060) internal val applyFloorSnapPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "apply_floor_snap", 3218959716) + TypeManager.getMethodBindPtr("CharacterBody3D", "apply_floor_snap", 3_218_959_716) internal val setVelocityPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "set_velocity", 3460891852) + TypeManager.getMethodBindPtr("CharacterBody3D", "set_velocity", 3_460_891_852) internal val getVelocityPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "get_velocity", 3360562783) + TypeManager.getMethodBindPtr("CharacterBody3D", "get_velocity", 3_360_562_783) internal val setSafeMarginPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "set_safe_margin", 373806689) + TypeManager.getMethodBindPtr("CharacterBody3D", "set_safe_margin", 373_806_689) internal val getSafeMarginPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "get_safe_margin", 1740695150) + TypeManager.getMethodBindPtr("CharacterBody3D", "get_safe_margin", 1_740_695_150) internal val isFloorStopOnSlopeEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "is_floor_stop_on_slope_enabled", 36873697) + TypeManager.getMethodBindPtr("CharacterBody3D", "is_floor_stop_on_slope_enabled", 36_873_697) internal val setFloorStopOnSlopeEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "set_floor_stop_on_slope_enabled", 2586408642) + TypeManager.getMethodBindPtr("CharacterBody3D", "set_floor_stop_on_slope_enabled", 2_586_408_642) internal val setFloorConstantSpeedEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "set_floor_constant_speed_enabled", 2586408642) + TypeManager.getMethodBindPtr("CharacterBody3D", "set_floor_constant_speed_enabled", 2_586_408_642) internal val isFloorConstantSpeedEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "is_floor_constant_speed_enabled", 36873697) + TypeManager.getMethodBindPtr("CharacterBody3D", "is_floor_constant_speed_enabled", 36_873_697) internal val setFloorBlockOnWallEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "set_floor_block_on_wall_enabled", 2586408642) + TypeManager.getMethodBindPtr("CharacterBody3D", "set_floor_block_on_wall_enabled", 2_586_408_642) internal val isFloorBlockOnWallEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "is_floor_block_on_wall_enabled", 36873697) + TypeManager.getMethodBindPtr("CharacterBody3D", "is_floor_block_on_wall_enabled", 36_873_697) internal val setSlideOnCeilingEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "set_slide_on_ceiling_enabled", 2586408642) + TypeManager.getMethodBindPtr("CharacterBody3D", "set_slide_on_ceiling_enabled", 2_586_408_642) internal val isSlideOnCeilingEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "is_slide_on_ceiling_enabled", 36873697) + TypeManager.getMethodBindPtr("CharacterBody3D", "is_slide_on_ceiling_enabled", 36_873_697) internal val setPlatformFloorLayersPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "set_platform_floor_layers", 1286410249) + TypeManager.getMethodBindPtr("CharacterBody3D", "set_platform_floor_layers", 1_286_410_249) internal val getPlatformFloorLayersPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "get_platform_floor_layers", 3905245786) + TypeManager.getMethodBindPtr("CharacterBody3D", "get_platform_floor_layers", 3_905_245_786) internal val setPlatformWallLayersPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "set_platform_wall_layers", 1286410249) + TypeManager.getMethodBindPtr("CharacterBody3D", "set_platform_wall_layers", 1_286_410_249) internal val getPlatformWallLayersPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "get_platform_wall_layers", 3905245786) + TypeManager.getMethodBindPtr("CharacterBody3D", "get_platform_wall_layers", 3_905_245_786) internal val getMaxSlidesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "get_max_slides", 3905245786) + TypeManager.getMethodBindPtr("CharacterBody3D", "get_max_slides", 3_905_245_786) internal val setMaxSlidesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "set_max_slides", 1286410249) + TypeManager.getMethodBindPtr("CharacterBody3D", "set_max_slides", 1_286_410_249) internal val getFloorMaxAnglePtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "get_floor_max_angle", 1740695150) + TypeManager.getMethodBindPtr("CharacterBody3D", "get_floor_max_angle", 1_740_695_150) internal val setFloorMaxAnglePtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "set_floor_max_angle", 373806689) + TypeManager.getMethodBindPtr("CharacterBody3D", "set_floor_max_angle", 373_806_689) internal val getFloorSnapLengthPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "get_floor_snap_length", 191475506) + TypeManager.getMethodBindPtr("CharacterBody3D", "get_floor_snap_length", 191_475_506) internal val setFloorSnapLengthPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "set_floor_snap_length", 373806689) + TypeManager.getMethodBindPtr("CharacterBody3D", "set_floor_snap_length", 373_806_689) internal val getWallMinSlideAnglePtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "get_wall_min_slide_angle", 1740695150) + TypeManager.getMethodBindPtr("CharacterBody3D", "get_wall_min_slide_angle", 1_740_695_150) internal val setWallMinSlideAnglePtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "set_wall_min_slide_angle", 373806689) + TypeManager.getMethodBindPtr("CharacterBody3D", "set_wall_min_slide_angle", 373_806_689) internal val getUpDirectionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "get_up_direction", 3360562783) + TypeManager.getMethodBindPtr("CharacterBody3D", "get_up_direction", 3_360_562_783) internal val setUpDirectionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "set_up_direction", 3460891852) + TypeManager.getMethodBindPtr("CharacterBody3D", "set_up_direction", 3_460_891_852) internal val setMotionModePtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "set_motion_mode", 2690739026) + TypeManager.getMethodBindPtr("CharacterBody3D", "set_motion_mode", 2_690_739_026) internal val getMotionModePtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "get_motion_mode", 3529553604) + TypeManager.getMethodBindPtr("CharacterBody3D", "get_motion_mode", 3_529_553_604) internal val setPlatformOnLeavePtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "set_platform_on_leave", 1459986142) + TypeManager.getMethodBindPtr("CharacterBody3D", "set_platform_on_leave", 1_459_986_142) internal val getPlatformOnLeavePtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "get_platform_on_leave", 996491171) + TypeManager.getMethodBindPtr("CharacterBody3D", "get_platform_on_leave", 996_491_171) internal val isOnFloorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "is_on_floor", 36873697) + TypeManager.getMethodBindPtr("CharacterBody3D", "is_on_floor", 36_873_697) internal val isOnFloorOnlyPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "is_on_floor_only", 36873697) + TypeManager.getMethodBindPtr("CharacterBody3D", "is_on_floor_only", 36_873_697) internal val isOnCeilingPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "is_on_ceiling", 36873697) + TypeManager.getMethodBindPtr("CharacterBody3D", "is_on_ceiling", 36_873_697) internal val isOnCeilingOnlyPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "is_on_ceiling_only", 36873697) + TypeManager.getMethodBindPtr("CharacterBody3D", "is_on_ceiling_only", 36_873_697) internal val isOnWallPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "is_on_wall", 36873697) + TypeManager.getMethodBindPtr("CharacterBody3D", "is_on_wall", 36_873_697) internal val isOnWallOnlyPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "is_on_wall_only", 36873697) + TypeManager.getMethodBindPtr("CharacterBody3D", "is_on_wall_only", 36_873_697) internal val getFloorNormalPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "get_floor_normal", 3360562783) + TypeManager.getMethodBindPtr("CharacterBody3D", "get_floor_normal", 3_360_562_783) internal val getWallNormalPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "get_wall_normal", 3360562783) + TypeManager.getMethodBindPtr("CharacterBody3D", "get_wall_normal", 3_360_562_783) internal val getLastMotionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "get_last_motion", 3360562783) + TypeManager.getMethodBindPtr("CharacterBody3D", "get_last_motion", 3_360_562_783) internal val getPositionDeltaPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "get_position_delta", 3360562783) + TypeManager.getMethodBindPtr("CharacterBody3D", "get_position_delta", 3_360_562_783) internal val getRealVelocityPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "get_real_velocity", 3360562783) + TypeManager.getMethodBindPtr("CharacterBody3D", "get_real_velocity", 3_360_562_783) internal val getFloorAnglePtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "get_floor_angle", 2906300789) + TypeManager.getMethodBindPtr("CharacterBody3D", "get_floor_angle", 2_906_300_789) internal val getPlatformVelocityPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "get_platform_velocity", 3360562783) + TypeManager.getMethodBindPtr("CharacterBody3D", "get_platform_velocity", 3_360_562_783) internal val getPlatformAngularVelocityPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "get_platform_angular_velocity", 3360562783) + TypeManager.getMethodBindPtr("CharacterBody3D", "get_platform_angular_velocity", 3_360_562_783) internal val getSlideCollisionCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "get_slide_collision_count", 3905245786) + TypeManager.getMethodBindPtr("CharacterBody3D", "get_slide_collision_count", 3_905_245_786) internal val getSlideCollisionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "get_slide_collision", 107003663) + TypeManager.getMethodBindPtr("CharacterBody3D", "get_slide_collision", 107_003_663) internal val getLastSlideCollisionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CharacterBody3D", "get_last_slide_collision", 186875014) + TypeManager.getMethodBindPtr("CharacterBody3D", "get_last_slide_collision", 186_875_014) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CheckBox.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CheckBox.kt index e96263a8aa..b2e6d1e802 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CheckBox.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CheckBox.kt @@ -1,31 +1,22 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api import godot.`annotation`.GodotBaseType import kotlin.Int import kotlin.Suppress -import kotlin.Unit /** - * [CheckBox] allows the user to choose one of only two possible options. It's similar to - * [CheckButton] in functionality, but it has a different appearance. To follow established UX - * patterns, it's recommended to use [CheckBox] when toggling it has **no** immediate effect on - * something. For example, it could be used when toggling it will only do something once a confirmation - * button is pressed. + * [CheckBox] allows the user to choose one of only two possible options. It's similar to [CheckButton] in functionality, but it has a different appearance. To follow established UX patterns, it's recommended to use [CheckBox] when toggling it has **no** immediate effect on something. For example, it could be used when toggling it will only do something once a confirmation button is pressed. * * See also [BaseButton] which contains common properties and methods associated with this node. * - * When [BaseButton.buttonGroup] specifies a [ButtonGroup], [CheckBox] changes its appearance to - * that of a radio button and uses the various `radio_*` theme properties. + * When [BaseButton.buttonGroup] specifies a [ButtonGroup], [CheckBox] changes its appearance to that of a radio button and uses the various `radio_*` theme properties. */ @GodotBaseType public open class CheckBox : Button() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(148, scriptIndex) } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CheckButton.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CheckButton.kt index 5486c22c84..f24ae515a8 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CheckButton.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CheckButton.kt @@ -1,28 +1,20 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api import godot.`annotation`.GodotBaseType import kotlin.Int import kotlin.Suppress -import kotlin.Unit /** - * [CheckButton] is a toggle button displayed as a check field. It's similar to [CheckBox] in - * functionality, but it has a different appearance. To follow established UX patterns, it's - * recommended to use [CheckButton] when toggling it has an **immediate** effect on something. For - * example, it can be used when pressing it shows or hides advanced settings, without asking the user - * to confirm this action. + * [CheckButton] is a toggle button displayed as a check field. It's similar to [CheckBox] in functionality, but it has a different appearance. To follow established UX patterns, it's recommended to use [CheckButton] when toggling it has an **immediate** effect on something. For example, it can be used when pressing it shows or hides advanced settings, without asking the user to confirm this action. * * See also [BaseButton] which contains common properties and methods associated with this node. */ @GodotBaseType public open class CheckButton : Button() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(149, scriptIndex) } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CircleShape2D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CircleShape2D.kt index 30124b8754..04cb365852 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CircleShape2D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CircleShape2D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -16,15 +13,12 @@ import kotlin.Double import kotlin.Float import kotlin.Int import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * A 2D circle shape, intended for use in physics. Usually used to provide a shape for a - * [CollisionShape2D]. + * A 2D circle shape, intended for use in physics. Usually used to provide a shape for a [CollisionShape2D]. * - * **Performance:** [CircleShape2D] is fast to check collisions against. It is faster than - * [RectangleShape2D] and [CapsuleShape2D]. + * **Performance:** [CircleShape2D] is fast to check collisions against. It is faster than [RectangleShape2D] and [CapsuleShape2D]. */ @GodotBaseType public open class CircleShape2D : Shape2D() { @@ -39,11 +33,11 @@ public open class CircleShape2D : Shape2D() { setRadius(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(150, scriptIndex) } - public final fun setRadius(radius: Float): Unit { + public final fun setRadius(radius: Float) { TransferContext.writeArguments(DOUBLE to radius.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setRadiusPtr, NIL) } @@ -58,9 +52,9 @@ public open class CircleShape2D : Shape2D() { public object MethodBindings { internal val setRadiusPtr: VoidPtr = - TypeManager.getMethodBindPtr("CircleShape2D", "set_radius", 373806689) + TypeManager.getMethodBindPtr("CircleShape2D", "set_radius", 373_806_689) internal val getRadiusPtr: VoidPtr = - TypeManager.getMethodBindPtr("CircleShape2D", "get_radius", 1740695150) + TypeManager.getMethodBindPtr("CircleShape2D", "get_radius", 1_740_695_150) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ClassDB.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ClassDB.kt index 2224e9b6f4..b02c3fc613 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ClassDB.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ClassDB.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -30,7 +27,6 @@ import kotlin.Int import kotlin.Long import kotlin.String import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmOverloads import kotlin.jvm.JvmStatic @@ -39,7 +35,7 @@ import kotlin.jvm.JvmStatic */ @GodotBaseType public object ClassDB : Object() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { getSingleton(2) } @@ -94,8 +90,7 @@ public object ClassDB : Object() { } /** - * Returns `true` if objects can be instantiated from the specified [class], otherwise returns - * `false`. + * Returns `true` if objects can be instantiated from the specified [class], otherwise returns `false`. */ @JvmStatic public final fun canInstantiate(`class`: StringName): Boolean { @@ -135,9 +130,7 @@ public object ClassDB : Object() { } /** - * Returns the [signal] data of [class] or its ancestry. The returned value is a [Dictionary] with - * the following keys: `args`, `default_args`, `flags`, `id`, `name`, `return: (class_name, hint, - * hint_string, name, type, usage)`. + * Returns the [signal] data of [class] or its ancestry. The returned value is a [Dictionary] with the following keys: `args`, `default_args`, `flags`, `id`, `name`, `return: (class_name, hint, hint_string, name, type, usage)`. */ @JvmStatic public final fun classGetSignal(`class`: StringName, signal: StringName): Dictionary { @@ -147,26 +140,22 @@ public object ClassDB : Object() { } /** - * Returns an array with all the signals of [class] or its ancestry if [noInheritance] is `false`. - * Every element of the array is a [Dictionary] as described in [classGetSignal]. + * Returns an array with all the signals of [class] or its ancestry if [noInheritance] is `false`. Every element of the array is a [Dictionary] as described in [classGetSignal]. */ @JvmOverloads @JvmStatic - public final fun classGetSignalList(`class`: StringName, noInheritance: Boolean = false): - VariantArray> { + public final fun classGetSignalList(`class`: StringName, noInheritance: Boolean = false): VariantArray> { TransferContext.writeArguments(STRING_NAME to `class`, BOOL to noInheritance) TransferContext.callMethod(ptr, MethodBindings.classGetSignalListPtr, ARRAY) return (TransferContext.readReturnValue(ARRAY) as VariantArray>) } /** - * Returns an array with all the properties of [class] or its ancestry if [noInheritance] is - * `false`. + * Returns an array with all the properties of [class] or its ancestry if [noInheritance] is `false`. */ @JvmOverloads @JvmStatic - public final fun classGetPropertyList(`class`: StringName, noInheritance: Boolean = false): - VariantArray> { + public final fun classGetPropertyList(`class`: StringName, noInheritance: Boolean = false): VariantArray> { TransferContext.writeArguments(STRING_NAME to `class`, BOOL to noInheritance) TransferContext.callMethod(ptr, MethodBindings.classGetPropertyListPtr, ARRAY) return (TransferContext.readReturnValue(ARRAY) as VariantArray>) @@ -227,8 +216,7 @@ public object ClassDB : Object() { } /** - * Returns whether [class] (or its ancestry if [noInheritance] is `false`) has a method called - * [method] or not. + * Returns whether [class] (or its ancestry if [noInheritance] is `false`) has a method called [method] or not. */ @JvmOverloads @JvmStatic @@ -243,8 +231,7 @@ public object ClassDB : Object() { } /** - * Returns the number of arguments of the method [method] of [class] or its ancestry if - * [noInheritance] is `false`. + * Returns the number of arguments of the method [method] of [class] or its ancestry if [noInheritance] is `false`. */ @JvmOverloads @JvmStatic @@ -259,17 +246,13 @@ public object ClassDB : Object() { } /** - * Returns an array with all the methods of [class] or its ancestry if [noInheritance] is `false`. - * Every element of the array is a [Dictionary] with the following keys: `args`, `default_args`, - * `flags`, `id`, `name`, `return: (class_name, hint, hint_string, name, type, usage)`. + * Returns an array with all the methods of [class] or its ancestry if [noInheritance] is `false`. Every element of the array is a [Dictionary] with the following keys: `args`, `default_args`, `flags`, `id`, `name`, `return: (class_name, hint, hint_string, name, type, usage)`. * - * **Note:** In exported release builds the debug info is not available, so the returned - * dictionaries will contain only method names. + * **Note:** In exported release builds the debug info is not available, so the returned dictionaries will contain only method names. */ @JvmOverloads @JvmStatic - public final fun classGetMethodList(`class`: StringName, noInheritance: Boolean = false): - VariantArray> { + public final fun classGetMethodList(`class`: StringName, noInheritance: Boolean = false): VariantArray> { TransferContext.writeArguments(STRING_NAME to `class`, BOOL to noInheritance) TransferContext.callMethod(ptr, MethodBindings.classGetMethodListPtr, ARRAY) return (TransferContext.readReturnValue(ARRAY) as VariantArray>) @@ -294,11 +277,9 @@ public object ClassDB : Object() { */ @JvmOverloads @JvmStatic - public final fun classGetIntegerConstantList(`class`: StringName, noInheritance: Boolean = false): - PackedStringArray { + public final fun classGetIntegerConstantList(`class`: StringName, noInheritance: Boolean = false): PackedStringArray { TransferContext.writeArguments(STRING_NAME to `class`, BOOL to noInheritance) - TransferContext.callMethod(ptr, MethodBindings.classGetIntegerConstantListPtr, - PACKED_STRING_ARRAY) + TransferContext.callMethod(ptr, MethodBindings.classGetIntegerConstantListPtr, PACKED_STRING_ARRAY) return (TransferContext.readReturnValue(PACKED_STRING_ARRAY) as PackedStringArray) } @@ -313,8 +294,7 @@ public object ClassDB : Object() { } /** - * Returns the value of the integer constant [name] of [class] or its ancestry. Always returns 0 - * when the constant could not be found. + * Returns the value of the integer constant [name] of [class] or its ancestry. Always returns 0 when the constant could not be found. */ @JvmStatic public final fun classGetIntegerConstant(`class`: StringName, name: StringName): Long { @@ -343,8 +323,7 @@ public object ClassDB : Object() { */ @JvmOverloads @JvmStatic - public final fun classGetEnumList(`class`: StringName, noInheritance: Boolean = false): - PackedStringArray { + public final fun classGetEnumList(`class`: StringName, noInheritance: Boolean = false): PackedStringArray { TransferContext.writeArguments(STRING_NAME to `class`, BOOL to noInheritance) TransferContext.callMethod(ptr, MethodBindings.classGetEnumListPtr, PACKED_STRING_ARRAY) return (TransferContext.readReturnValue(PACKED_STRING_ARRAY) as PackedStringArray) @@ -381,8 +360,7 @@ public object ClassDB : Object() { } /** - * Returns whether [class] (or its ancestor classes if [noInheritance] is `false`) has an enum - * called [enum] that is a bitfield. + * Returns whether [class] (or its ancestor classes if [noInheritance] is `false`) has an enum called [enum] that is a bitfield. */ @JvmOverloads @JvmStatic @@ -410,15 +388,13 @@ public object ClassDB : Object() { * Returns the names of all the classes that directly or indirectly inherit from [class]. */ @JvmStatic - public final fun getInheritersFromClass(`class`: String): PackedStringArray = - getInheritersFromClass(`class`.asCachedStringName()) + public final fun getInheritersFromClass(`class`: String): PackedStringArray = getInheritersFromClass(`class`.asCachedStringName()) /** * Returns the parent class of [class]. */ @JvmStatic - public final fun getParentClass(`class`: String): StringName = - getParentClass(`class`.asCachedStringName()) + public final fun getParentClass(`class`: String): StringName = getParentClass(`class`.asCachedStringName()) /** * Returns whether the specified [class] is available or not. @@ -430,16 +406,13 @@ public object ClassDB : Object() { * Returns whether [inherits] is an ancestor of [class] or not. */ @JvmStatic - public final fun isParentClass(`class`: String, inherits: String): Boolean = - isParentClass(`class`.asCachedStringName(), inherits.asCachedStringName()) + public final fun isParentClass(`class`: String, inherits: String): Boolean = isParentClass(`class`.asCachedStringName(), inherits.asCachedStringName()) /** - * Returns `true` if objects can be instantiated from the specified [class], otherwise returns - * `false`. + * Returns `true` if objects can be instantiated from the specified [class], otherwise returns `false`. */ @JvmStatic - public final fun canInstantiate(`class`: String): Boolean = - canInstantiate(`class`.asCachedStringName()) + public final fun canInstantiate(`class`: String): Boolean = canInstantiate(`class`.asCachedStringName()) /** * Creates an instance of [class]. @@ -451,65 +424,51 @@ public object ClassDB : Object() { * Returns the API type of [class]. See [APIType]. */ @JvmStatic - public final fun classGetApiType(`class`: String): APIType = - classGetApiType(`class`.asCachedStringName()) + public final fun classGetApiType(`class`: String): APIType = classGetApiType(`class`.asCachedStringName()) /** * Returns whether [class] or its ancestry has a signal called [signal] or not. */ @JvmStatic - public final fun classHasSignal(`class`: String, signal: String): Boolean = - classHasSignal(`class`.asCachedStringName(), signal.asCachedStringName()) + public final fun classHasSignal(`class`: String, signal: String): Boolean = classHasSignal(`class`.asCachedStringName(), signal.asCachedStringName()) /** - * Returns the [signal] data of [class] or its ancestry. The returned value is a [Dictionary] with - * the following keys: `args`, `default_args`, `flags`, `id`, `name`, `return: (class_name, hint, - * hint_string, name, type, usage)`. + * Returns the [signal] data of [class] or its ancestry. The returned value is a [Dictionary] with the following keys: `args`, `default_args`, `flags`, `id`, `name`, `return: (class_name, hint, hint_string, name, type, usage)`. */ @JvmStatic - public final fun classGetSignal(`class`: String, signal: String): Dictionary = - classGetSignal(`class`.asCachedStringName(), signal.asCachedStringName()) + public final fun classGetSignal(`class`: String, signal: String): Dictionary = classGetSignal(`class`.asCachedStringName(), signal.asCachedStringName()) /** - * Returns an array with all the signals of [class] or its ancestry if [noInheritance] is `false`. - * Every element of the array is a [Dictionary] as described in [classGetSignal]. + * Returns an array with all the signals of [class] or its ancestry if [noInheritance] is `false`. Every element of the array is a [Dictionary] as described in [classGetSignal]. */ @JvmOverloads @JvmStatic - public final fun classGetSignalList(`class`: String, noInheritance: Boolean = false): - VariantArray> = - classGetSignalList(`class`.asCachedStringName(), noInheritance) + public final fun classGetSignalList(`class`: String, noInheritance: Boolean = false): VariantArray> = classGetSignalList(`class`.asCachedStringName(), noInheritance) /** - * Returns an array with all the properties of [class] or its ancestry if [noInheritance] is - * `false`. + * Returns an array with all the properties of [class] or its ancestry if [noInheritance] is `false`. */ @JvmOverloads @JvmStatic - public final fun classGetPropertyList(`class`: String, noInheritance: Boolean = false): - VariantArray> = - classGetPropertyList(`class`.asCachedStringName(), noInheritance) + public final fun classGetPropertyList(`class`: String, noInheritance: Boolean = false): VariantArray> = classGetPropertyList(`class`.asCachedStringName(), noInheritance) /** * Returns the getter method name of [property] of [class]. */ @JvmStatic - public final fun classGetPropertyGetter(`class`: String, `property`: String): StringName = - classGetPropertyGetter(`class`.asCachedStringName(), property.asCachedStringName()) + public final fun classGetPropertyGetter(`class`: String, `property`: String): StringName = classGetPropertyGetter(`class`.asCachedStringName(), property.asCachedStringName()) /** * Returns the setter method name of [property] of [class]. */ @JvmStatic - public final fun classGetPropertySetter(`class`: String, `property`: String): StringName = - classGetPropertySetter(`class`.asCachedStringName(), property.asCachedStringName()) + public final fun classGetPropertySetter(`class`: String, `property`: String): StringName = classGetPropertySetter(`class`.asCachedStringName(), property.asCachedStringName()) /** * Returns the value of [property] of [object] or its ancestry. */ @JvmStatic - public final fun classGetProperty(`object`: Object?, `property`: String): Any? = - classGetProperty(`object`, property.asCachedStringName()) + public final fun classGetProperty(`object`: Object?, `property`: String): Any? = classGetProperty(`object`, property.asCachedStringName()) /** * Sets [property] value of [object] to [value]. @@ -525,12 +484,10 @@ public object ClassDB : Object() { * Returns the default value of [property] of [class] or its ancestor classes. */ @JvmStatic - public final fun classGetPropertyDefaultValue(`class`: String, `property`: String): Any? = - classGetPropertyDefaultValue(`class`.asCachedStringName(), property.asCachedStringName()) + public final fun classGetPropertyDefaultValue(`class`: String, `property`: String): Any? = classGetPropertyDefaultValue(`class`.asCachedStringName(), property.asCachedStringName()) /** - * Returns whether [class] (or its ancestry if [noInheritance] is `false`) has a method called - * [method] or not. + * Returns whether [class] (or its ancestry if [noInheritance] is `false`) has a method called [method] or not. */ @JvmOverloads @JvmStatic @@ -538,12 +495,10 @@ public object ClassDB : Object() { `class`: String, method: String, noInheritance: Boolean = false, - ): Boolean = - classHasMethod(`class`.asCachedStringName(), method.asCachedStringName(), noInheritance) + ): Boolean = classHasMethod(`class`.asCachedStringName(), method.asCachedStringName(), noInheritance) /** - * Returns the number of arguments of the method [method] of [class] or its ancestry if - * [noInheritance] is `false`. + * Returns the number of arguments of the method [method] of [class] or its ancestry if [noInheritance] is `false`. */ @JvmOverloads @JvmStatic @@ -551,22 +506,16 @@ public object ClassDB : Object() { `class`: String, method: String, noInheritance: Boolean = false, - ): Int = - classGetMethodArgumentCount(`class`.asCachedStringName(), method.asCachedStringName(), noInheritance) + ): Int = classGetMethodArgumentCount(`class`.asCachedStringName(), method.asCachedStringName(), noInheritance) /** - * Returns an array with all the methods of [class] or its ancestry if [noInheritance] is `false`. - * Every element of the array is a [Dictionary] with the following keys: `args`, `default_args`, - * `flags`, `id`, `name`, `return: (class_name, hint, hint_string, name, type, usage)`. + * Returns an array with all the methods of [class] or its ancestry if [noInheritance] is `false`. Every element of the array is a [Dictionary] with the following keys: `args`, `default_args`, `flags`, `id`, `name`, `return: (class_name, hint, hint_string, name, type, usage)`. * - * **Note:** In exported release builds the debug info is not available, so the returned - * dictionaries will contain only method names. + * **Note:** In exported release builds the debug info is not available, so the returned dictionaries will contain only method names. */ @JvmOverloads @JvmStatic - public final fun classGetMethodList(`class`: String, noInheritance: Boolean = false): - VariantArray> = - classGetMethodList(`class`.asCachedStringName(), noInheritance) + public final fun classGetMethodList(`class`: String, noInheritance: Boolean = false): VariantArray> = classGetMethodList(`class`.asCachedStringName(), noInheritance) /** * Calls a static method on a class. @@ -583,23 +532,19 @@ public object ClassDB : Object() { */ @JvmOverloads @JvmStatic - public final fun classGetIntegerConstantList(`class`: String, noInheritance: Boolean = false): - PackedStringArray = classGetIntegerConstantList(`class`.asCachedStringName(), noInheritance) + public final fun classGetIntegerConstantList(`class`: String, noInheritance: Boolean = false): PackedStringArray = classGetIntegerConstantList(`class`.asCachedStringName(), noInheritance) /** * Returns whether [class] or its ancestry has an integer constant called [name] or not. */ @JvmStatic - public final fun classHasIntegerConstant(`class`: String, name: String): Boolean = - classHasIntegerConstant(`class`.asCachedStringName(), name.asCachedStringName()) + public final fun classHasIntegerConstant(`class`: String, name: String): Boolean = classHasIntegerConstant(`class`.asCachedStringName(), name.asCachedStringName()) /** - * Returns the value of the integer constant [name] of [class] or its ancestry. Always returns 0 - * when the constant could not be found. + * Returns the value of the integer constant [name] of [class] or its ancestry. Always returns 0 when the constant could not be found. */ @JvmStatic - public final fun classGetIntegerConstant(`class`: String, name: String): Long = - classGetIntegerConstant(`class`.asCachedStringName(), name.asCachedStringName()) + public final fun classGetIntegerConstant(`class`: String, name: String): Long = classGetIntegerConstant(`class`.asCachedStringName(), name.asCachedStringName()) /** * Returns whether [class] or its ancestry has an enum called [name] or not. @@ -617,8 +562,7 @@ public object ClassDB : Object() { */ @JvmOverloads @JvmStatic - public final fun classGetEnumList(`class`: String, noInheritance: Boolean = false): - PackedStringArray = classGetEnumList(`class`.asCachedStringName(), noInheritance) + public final fun classGetEnumList(`class`: String, noInheritance: Boolean = false): PackedStringArray = classGetEnumList(`class`.asCachedStringName(), noInheritance) /** * Returns an array with all the keys in [enum] of [class] or its ancestry. @@ -629,8 +573,7 @@ public object ClassDB : Object() { `class`: String, `enum`: String, noInheritance: Boolean = false, - ): PackedStringArray = - classGetEnumConstants(`class`.asCachedStringName(), `enum`.asCachedStringName(), noInheritance) + ): PackedStringArray = classGetEnumConstants(`class`.asCachedStringName(), `enum`.asCachedStringName(), noInheritance) /** * Returns which enum the integer constant [name] of [class] or its ancestry belongs to. @@ -641,12 +584,10 @@ public object ClassDB : Object() { `class`: String, name: String, noInheritance: Boolean = false, - ): StringName = - classGetIntegerConstantEnum(`class`.asCachedStringName(), name.asCachedStringName(), noInheritance) + ): StringName = classGetIntegerConstantEnum(`class`.asCachedStringName(), name.asCachedStringName(), noInheritance) /** - * Returns whether [class] (or its ancestor classes if [noInheritance] is `false`) has an enum - * called [enum] that is a bitfield. + * Returns whether [class] (or its ancestor classes if [noInheritance] is `false`) has an enum called [enum] that is a bitfield. */ @JvmOverloads @JvmStatic @@ -654,15 +595,13 @@ public object ClassDB : Object() { `class`: String, `enum`: String, noInheritance: Boolean = false, - ): Boolean = - isClassEnumBitfield(`class`.asCachedStringName(), `enum`.asCachedStringName(), noInheritance) + ): Boolean = isClassEnumBitfield(`class`.asCachedStringName(), `enum`.asCachedStringName(), noInheritance) /** * Returns whether this [class] is enabled or not. */ @JvmStatic - public final fun isClassEnabled(`class`: String): Boolean = - isClassEnabled(`class`.asCachedStringName()) + public final fun isClassEnabled(`class`: String): Boolean = isClassEnabled(`class`.asCachedStringName()) public enum class APIType( id: Long, @@ -701,93 +640,93 @@ public object ClassDB : Object() { public object MethodBindings { internal val getClassListPtr: VoidPtr = - TypeManager.getMethodBindPtr("ClassDB", "get_class_list", 1139954409) + TypeManager.getMethodBindPtr("ClassDB", "get_class_list", 1_139_954_409) internal val getInheritersFromClassPtr: VoidPtr = - TypeManager.getMethodBindPtr("ClassDB", "get_inheriters_from_class", 1761182771) + TypeManager.getMethodBindPtr("ClassDB", "get_inheriters_from_class", 1_761_182_771) internal val getParentClassPtr: VoidPtr = - TypeManager.getMethodBindPtr("ClassDB", "get_parent_class", 1965194235) + TypeManager.getMethodBindPtr("ClassDB", "get_parent_class", 1_965_194_235) internal val classExistsPtr: VoidPtr = - TypeManager.getMethodBindPtr("ClassDB", "class_exists", 2619796661) + TypeManager.getMethodBindPtr("ClassDB", "class_exists", 2_619_796_661) internal val isParentClassPtr: VoidPtr = - TypeManager.getMethodBindPtr("ClassDB", "is_parent_class", 471820014) + TypeManager.getMethodBindPtr("ClassDB", "is_parent_class", 471_820_014) internal val canInstantiatePtr: VoidPtr = - TypeManager.getMethodBindPtr("ClassDB", "can_instantiate", 2619796661) + TypeManager.getMethodBindPtr("ClassDB", "can_instantiate", 2_619_796_661) internal val instantiatePtr: VoidPtr = - TypeManager.getMethodBindPtr("ClassDB", "instantiate", 2760726917) + TypeManager.getMethodBindPtr("ClassDB", "instantiate", 2_760_726_917) internal val classGetApiTypePtr: VoidPtr = - TypeManager.getMethodBindPtr("ClassDB", "class_get_api_type", 2475317043) + TypeManager.getMethodBindPtr("ClassDB", "class_get_api_type", 2_475_317_043) internal val classHasSignalPtr: VoidPtr = - TypeManager.getMethodBindPtr("ClassDB", "class_has_signal", 471820014) + TypeManager.getMethodBindPtr("ClassDB", "class_has_signal", 471_820_014) internal val classGetSignalPtr: VoidPtr = - TypeManager.getMethodBindPtr("ClassDB", "class_get_signal", 3061114238) + TypeManager.getMethodBindPtr("ClassDB", "class_get_signal", 3_061_114_238) internal val classGetSignalListPtr: VoidPtr = - TypeManager.getMethodBindPtr("ClassDB", "class_get_signal_list", 3504980660) + TypeManager.getMethodBindPtr("ClassDB", "class_get_signal_list", 3_504_980_660) internal val classGetPropertyListPtr: VoidPtr = - TypeManager.getMethodBindPtr("ClassDB", "class_get_property_list", 3504980660) + TypeManager.getMethodBindPtr("ClassDB", "class_get_property_list", 3_504_980_660) internal val classGetPropertyGetterPtr: VoidPtr = - TypeManager.getMethodBindPtr("ClassDB", "class_get_property_getter", 3770832642) + TypeManager.getMethodBindPtr("ClassDB", "class_get_property_getter", 3_770_832_642) internal val classGetPropertySetterPtr: VoidPtr = - TypeManager.getMethodBindPtr("ClassDB", "class_get_property_setter", 3770832642) + TypeManager.getMethodBindPtr("ClassDB", "class_get_property_setter", 3_770_832_642) internal val classGetPropertyPtr: VoidPtr = - TypeManager.getMethodBindPtr("ClassDB", "class_get_property", 2498641674) + TypeManager.getMethodBindPtr("ClassDB", "class_get_property", 2_498_641_674) internal val classSetPropertyPtr: VoidPtr = - TypeManager.getMethodBindPtr("ClassDB", "class_set_property", 1690314931) + TypeManager.getMethodBindPtr("ClassDB", "class_set_property", 1_690_314_931) internal val classGetPropertyDefaultValuePtr: VoidPtr = - TypeManager.getMethodBindPtr("ClassDB", "class_get_property_default_value", 2718203076) + TypeManager.getMethodBindPtr("ClassDB", "class_get_property_default_value", 2_718_203_076) internal val classHasMethodPtr: VoidPtr = - TypeManager.getMethodBindPtr("ClassDB", "class_has_method", 3860701026) + TypeManager.getMethodBindPtr("ClassDB", "class_has_method", 3_860_701_026) internal val classGetMethodArgumentCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("ClassDB", "class_get_method_argument_count", 3885694822) + TypeManager.getMethodBindPtr("ClassDB", "class_get_method_argument_count", 3_885_694_822) internal val classGetMethodListPtr: VoidPtr = - TypeManager.getMethodBindPtr("ClassDB", "class_get_method_list", 3504980660) + TypeManager.getMethodBindPtr("ClassDB", "class_get_method_list", 3_504_980_660) internal val classCallStaticPtr: VoidPtr = - TypeManager.getMethodBindPtr("ClassDB", "class_call_static", 3344196419) + TypeManager.getMethodBindPtr("ClassDB", "class_call_static", 3_344_196_419) internal val classGetIntegerConstantListPtr: VoidPtr = - TypeManager.getMethodBindPtr("ClassDB", "class_get_integer_constant_list", 3031669221) + TypeManager.getMethodBindPtr("ClassDB", "class_get_integer_constant_list", 3_031_669_221) internal val classHasIntegerConstantPtr: VoidPtr = - TypeManager.getMethodBindPtr("ClassDB", "class_has_integer_constant", 471820014) + TypeManager.getMethodBindPtr("ClassDB", "class_has_integer_constant", 471_820_014) internal val classGetIntegerConstantPtr: VoidPtr = - TypeManager.getMethodBindPtr("ClassDB", "class_get_integer_constant", 2419549490) + TypeManager.getMethodBindPtr("ClassDB", "class_get_integer_constant", 2_419_549_490) internal val classHasEnumPtr: VoidPtr = - TypeManager.getMethodBindPtr("ClassDB", "class_has_enum", 3860701026) + TypeManager.getMethodBindPtr("ClassDB", "class_has_enum", 3_860_701_026) internal val classGetEnumListPtr: VoidPtr = - TypeManager.getMethodBindPtr("ClassDB", "class_get_enum_list", 3031669221) + TypeManager.getMethodBindPtr("ClassDB", "class_get_enum_list", 3_031_669_221) internal val classGetEnumConstantsPtr: VoidPtr = - TypeManager.getMethodBindPtr("ClassDB", "class_get_enum_constants", 661528303) + TypeManager.getMethodBindPtr("ClassDB", "class_get_enum_constants", 661_528_303) internal val classGetIntegerConstantEnumPtr: VoidPtr = - TypeManager.getMethodBindPtr("ClassDB", "class_get_integer_constant_enum", 2457504236) + TypeManager.getMethodBindPtr("ClassDB", "class_get_integer_constant_enum", 2_457_504_236) internal val isClassEnumBitfieldPtr: VoidPtr = - TypeManager.getMethodBindPtr("ClassDB", "is_class_enum_bitfield", 3860701026) + TypeManager.getMethodBindPtr("ClassDB", "is_class_enum_bitfield", 3_860_701_026) internal val isClassEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("ClassDB", "is_class_enabled", 2619796661) + TypeManager.getMethodBindPtr("ClassDB", "is_class_enabled", 2_619_796_661) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CodeEdit.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CodeEdit.kt index 9b234e2f0f..07d4dc0d18 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CodeEdit.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CodeEdit.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -36,29 +33,23 @@ import kotlin.Long import kotlin.NotImplementedError import kotlin.String import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName import kotlin.jvm.JvmOverloads /** - * CodeEdit is a specialized [TextEdit] designed for editing plain text code files. It has many - * features commonly found in code editors such as line numbers, line folding, code completion, indent - * management, and string/comment management. + * CodeEdit is a specialized [TextEdit] designed for editing plain text code files. It has many features commonly found in code editors such as line numbers, line folding, code completion, indent management, and string/comment management. * - * **Note:** Regardless of locale, [CodeEdit] will by default always use left-to-right text - * direction to correctly display source code. + * **Note:** Regardless of locale, [CodeEdit] will by default always use left-to-right text direction to correctly display source code. */ @GodotBaseType public open class CodeEdit : TextEdit() { /** - * Emitted when a breakpoint is added or removed from a line. If the line is moved via backspace a - * removed is emitted at the old line. + * Emitted when a breakpoint is added or removed from a line. If the line is moved via backspace a removed is emitted at the old line. */ public val breakpointToggled: Signal1 by Signal1 /** - * Emitted when the user requests code completion. This signal will not be sent if - * [_requestCodeCompletion] is overridden or [codeCompletionEnabled] is `false`. + * Emitted when the user requests code completion. This signal will not be sent if [_requestCodeCompletion] is overridden or [codeCompletionEnabled] is `false`. */ public val codeCompletionRequested: Signal0 by Signal0 @@ -68,25 +59,21 @@ public open class CodeEdit : TextEdit() { public val symbolLookup: Signal3 by Signal3 /** - * Emitted when the user hovers over a symbol. The symbol should be validated and responded to, by - * calling [setSymbolLookupWordAsValid]. + * Emitted when the user hovers over a symbol. The symbol should be validated and responded to, by calling [setSymbolLookupWordAsValid]. * * **Note:** [symbolLookupOnClick] must be `true` for this signal to be emitted. */ public val symbolValidate: Signal1 by Signal1 /** - * Emitted when the user hovers over a symbol. Unlike [signal Control.mouse_entered], this signal - * is not emitted immediately, but when the cursor is over the symbol for - * [ProjectSettings.gui/timers/tooltipDelaySec] seconds. + * Emitted when the user hovers over a symbol. Unlike [signal Control.mouse_entered], this signal is not emitted immediately, but when the cursor is over the symbol for [ProjectSettings.gui/timers/tooltipDelaySec] seconds. * * **Note:** [symbolTooltipOnHover] must be `true` for this signal to be emitted. */ public val symbolHovered: Signal3 by Signal3 /** - * Set when a validated word from [signal symbol_validate] is clicked, the [signal symbol_lookup] - * should be emitted. + * Set when a validated word from [signal symbol_validate] is clicked, the [signal symbol_lookup] should be emitted. */ public final inline var symbolLookupOnClick: Boolean @JvmName("symbolLookupOnClickProperty") @@ -108,8 +95,7 @@ public open class CodeEdit : TextEdit() { } /** - * If `true`, lines can be folded. Otherwise, line folding methods like [foldLine] will not work - * and [canFoldLine] will always return `false`. See [guttersDrawFoldGutter]. + * If `true`, lines can be folded. Otherwise, line folding methods like [foldLine] will not work and [canFoldLine] will always return `false`. See [guttersDrawFoldGutter]. */ public final inline var lineFolding: Boolean @JvmName("lineFoldingProperty") @@ -120,8 +106,7 @@ public open class CodeEdit : TextEdit() { } /** - * Draws vertical lines at the provided columns. The first entry is considered a main hard - * guideline and is draw more prominently. + * Draws vertical lines at the provided columns. The first entry is considered a main hard guideline and is draw more prominently. */ public final inline var lineLengthGuidelines: VariantArray @JvmName("lineLengthGuidelinesProperty") @@ -132,9 +117,7 @@ public open class CodeEdit : TextEdit() { } /** - * If `true`, breakpoints are drawn in the gutter. This gutter is shared with bookmarks and - * executing lines. Clicking the gutter will toggle the breakpoint for the line, see - * [setLineAsBreakpoint]. + * If `true`, breakpoints are drawn in the gutter. This gutter is shared with bookmarks and executing lines. Clicking the gutter will toggle the breakpoint for the line, see [setLineAsBreakpoint]. */ public final inline var guttersDrawBreakpointsGutter: Boolean @JvmName("guttersDrawBreakpointsGutterProperty") @@ -145,8 +128,7 @@ public open class CodeEdit : TextEdit() { } /** - * If `true`, bookmarks are drawn in the gutter. This gutter is shared with breakpoints and - * executing lines. See [setLineAsBookmarked]. + * If `true`, bookmarks are drawn in the gutter. This gutter is shared with breakpoints and executing lines. See [setLineAsBookmarked]. */ public final inline var guttersDrawBookmarks: Boolean @JvmName("guttersDrawBookmarksProperty") @@ -157,8 +139,7 @@ public open class CodeEdit : TextEdit() { } /** - * If `true`, executing lines are marked in the gutter. This gutter is shared with breakpoints and - * bookmarks. See [setLineAsExecuting]. + * If `true`, executing lines are marked in the gutter. This gutter is shared with breakpoints and bookmarks. See [setLineAsExecuting]. */ public final inline var guttersDrawExecutingLines: Boolean @JvmName("guttersDrawExecutingLinesProperty") @@ -169,9 +150,7 @@ public open class CodeEdit : TextEdit() { } /** - * If `true`, the line number gutter is drawn. Line numbers start at `1` and are incremented for - * each line of text. Clicking and dragging in the line number gutter will select entire lines of - * text. + * If `true`, the line number gutter is drawn. Line numbers start at `1` and are incremented for each line of text. Clicking and dragging in the line number gutter will select entire lines of text. */ public final inline var guttersDrawLineNumbers: Boolean @JvmName("guttersDrawLineNumbersProperty") @@ -182,8 +161,7 @@ public open class CodeEdit : TextEdit() { } /** - * If `true`, line numbers drawn in the gutter are zero padded based on the total line count. - * Requires [guttersDrawLineNumbers] to be set to `true`. + * If `true`, line numbers drawn in the gutter are zero padded based on the total line count. Requires [guttersDrawLineNumbers] to be set to `true`. */ public final inline var guttersZeroPadLineNumbers: Boolean @JvmName("guttersZeroPadLineNumbersProperty") @@ -194,10 +172,7 @@ public open class CodeEdit : TextEdit() { } /** - * If `true`, the fold gutter is drawn. In this gutter, the [theme_item can_fold_code_region] icon - * is drawn for each foldable line (see [canFoldLine]) and the [theme_item folded_code_region] icon - * is drawn for each folded line (see [isLineFolded]). These icons can be clicked to toggle the fold - * state, see [toggleFoldableLine]. [lineFolding] must be `true` to show icons. + * If `true`, the fold gutter is drawn. In this gutter, the [theme_item can_fold_code_region] icon is drawn for each foldable line (see [canFoldLine]) and the [theme_item folded_code_region] icon is drawn for each folded line (see [isLineFolded]). These icons can be clicked to toggle the fold state, see [toggleFoldableLine]. [lineFolding] must be `true` to show icons. */ public final inline var guttersDrawFoldGutter: Boolean @JvmName("guttersDrawFoldGutterProperty") @@ -230,8 +205,7 @@ public open class CodeEdit : TextEdit() { } /** - * If `true`, the [ProjectSettings.input/uiTextCompletionQuery] action requests code completion. - * To handle it, see [_requestCodeCompletion] or [signal code_completion_requested]. + * If `true`, the [ProjectSettings.input/uiTextCompletionQuery] action requests code completion. To handle it, see [_requestCodeCompletion] or [signal code_completion_requested]. */ public final inline var codeCompletionEnabled: Boolean @JvmName("codeCompletionEnabledProperty") @@ -253,8 +227,7 @@ public open class CodeEdit : TextEdit() { } /** - * Size of the tabulation indent (one [kbd]Tab[/kbd] press) in characters. If [indentUseSpaces] is - * enabled the number of spaces to use. + * Size of the tabulation indent (one [kbd]Tab[/kbd] press) in characters. If [indentUseSpaces] is enabled the number of spaces to use. */ public final inline var indentSize: Int @JvmName("indentSizeProperty") @@ -276,9 +249,7 @@ public open class CodeEdit : TextEdit() { } /** - * If `true`, an extra indent is automatically inserted when a new line is added and a prefix in - * [indentAutomaticPrefixes] is found. If a brace pair opening key is found, the matching closing - * brace will be moved to another new line (see [autoBraceCompletionPairs]). + * If `true`, an extra indent is automatically inserted when a new line is added and a prefix in [indentAutomaticPrefixes] is found. If a brace pair opening key is found, the matching closing brace will be moved to another new line (see [autoBraceCompletionPairs]). */ public final inline var indentAutomatic: Boolean @JvmName("indentAutomaticProperty") @@ -300,9 +271,7 @@ public open class CodeEdit : TextEdit() { } /** - * If `true`, uses [autoBraceCompletionPairs] to automatically insert the closing brace when the - * opening brace is inserted by typing or autocompletion. Also automatically removes the closing - * brace when using backspace on the opening brace. + * If `true`, uses [autoBraceCompletionPairs] to automatically insert the closing brace when the opening brace is inserted by typing or autocompletion. Also automatically removes the closing brace when using backspace on the opening brace. */ public final inline var autoBraceCompletionEnabled: Boolean @JvmName("autoBraceCompletionEnabledProperty") @@ -313,9 +282,7 @@ public open class CodeEdit : TextEdit() { } /** - * If `true`, highlights brace pairs when the caret is on either one, using - * [autoBraceCompletionPairs]. If matching, the pairs will be underlined. If a brace is unmatched, it - * is colored with [theme_item brace_mismatch_color]. + * If `true`, highlights brace pairs when the caret is on either one, using [autoBraceCompletionPairs]. If matching, the pairs will be underlined. If a brace is unmatched, it is colored with [theme_item brace_mismatch_color]. */ public final inline var autoBraceCompletionHighlightMatching: Boolean @JvmName("autoBraceCompletionHighlightMatchingProperty") @@ -326,9 +293,7 @@ public open class CodeEdit : TextEdit() { } /** - * Sets the brace pairs to be autocompleted. For each entry in the dictionary, the key is the - * opening brace and the value is the closing brace that matches it. A brace is a [String] made of - * symbols. See [autoBraceCompletionEnabled] and [autoBraceCompletionHighlightMatching]. + * Sets the brace pairs to be autocompleted. For each entry in the dictionary, the key is the opening brace and the value is the closing brace that matches it. A brace is a [String] made of symbols. See [autoBraceCompletionEnabled] and [autoBraceCompletionHighlightMatching]. */ public final inline var autoBraceCompletionPairs: Dictionary @JvmName("autoBraceCompletionPairsProperty") @@ -338,38 +303,34 @@ public open class CodeEdit : TextEdit() { setAutoBraceCompletionPairs(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(152, scriptIndex) } /** - * Override this method to define how the selected entry should be inserted. If [replace] is - * `true`, any existing text should be replaced. + * Override this method to define how the selected entry should be inserted. If [replace] is `true`, any existing text should be replaced. */ - public open fun _confirmCodeCompletion(replace: Boolean): Unit { + public open fun _confirmCodeCompletion(replace: Boolean) { throw NotImplementedError("CodeEdit::_confirmCodeCompletion is not implemented.") } /** - * Override this method to define what happens when the user requests code completion. If [force] - * is `true`, any checks should be bypassed. + * Override this method to define what happens when the user requests code completion. If [force] is `true`, any checks should be bypassed. */ - public open fun _requestCodeCompletion(force: Boolean): Unit { + public open fun _requestCodeCompletion(force: Boolean) { throw NotImplementedError("CodeEdit::_requestCodeCompletion is not implemented.") } /** * Override this method to define what items in [candidates] should be displayed. * - * Both [candidates] and the return is a [Array] of [Dictionary], see [getCodeCompletionOption] - * for [Dictionary] content. + * Both [candidates] and the return is a [Array] of [Dictionary], see [getCodeCompletionOption] for [Dictionary] content. */ - public open fun _filterCodeCompletionCandidates(candidates: VariantArray>): - VariantArray> { + public open fun _filterCodeCompletionCandidates(candidates: VariantArray>): VariantArray> { throw NotImplementedError("CodeEdit::_filterCodeCompletionCandidates is not implemented.") } - public final fun setIndentSize(size: Int): Unit { + public final fun setIndentSize(size: Int) { TransferContext.writeArguments(LONG to size.toLong()) TransferContext.callMethod(ptr, MethodBindings.setIndentSizePtr, NIL) } @@ -380,7 +341,7 @@ public open class CodeEdit : TextEdit() { return (TransferContext.readReturnValue(LONG) as Long).toInt() } - public final fun setIndentUsingSpaces(useSpaces: Boolean): Unit { + public final fun setIndentUsingSpaces(useSpaces: Boolean) { TransferContext.writeArguments(BOOL to useSpaces) TransferContext.callMethod(ptr, MethodBindings.setIndentUsingSpacesPtr, NIL) } @@ -391,7 +352,7 @@ public open class CodeEdit : TextEdit() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setAutoIndentEnabled(enable: Boolean): Unit { + public final fun setAutoIndentEnabled(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setAutoIndentEnabledPtr, NIL) } @@ -402,7 +363,7 @@ public open class CodeEdit : TextEdit() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setAutoIndentPrefixes(prefixes: VariantArray): Unit { + public final fun setAutoIndentPrefixes(prefixes: VariantArray) { TransferContext.writeArguments(ARRAY to prefixes) TransferContext.callMethod(ptr, MethodBindings.setAutoIndentPrefixesPtr, NIL) } @@ -414,47 +375,41 @@ public open class CodeEdit : TextEdit() { } /** - * If there is no selection, indentation is inserted at the caret. Otherwise, the selected lines - * are indented like [indentLines]. Equivalent to the [ProjectSettings.input/uiTextIndent] action. - * The indentation characters used depend on [indentUseSpaces] and [indentSize]. + * If there is no selection, indentation is inserted at the caret. Otherwise, the selected lines are indented like [indentLines]. Equivalent to the [ProjectSettings.input/uiTextIndent] action. The indentation characters used depend on [indentUseSpaces] and [indentSize]. */ - public final fun doIndent(): Unit { + public final fun doIndent() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.doIndentPtr, NIL) } /** - * Indents all lines that are selected or have a caret on them. Uses spaces or a tab depending on - * [indentUseSpaces]. See [unindentLines]. + * Indents all lines that are selected or have a caret on them. Uses spaces or a tab depending on [indentUseSpaces]. See [unindentLines]. */ - public final fun indentLines(): Unit { + public final fun indentLines() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.indentLinesPtr, NIL) } /** - * Unindents all lines that are selected or have a caret on them. Uses spaces or a tab depending - * on [indentUseSpaces]. Equivalent to the [ProjectSettings.input/uiTextDedent] action. See - * [indentLines]. + * Unindents all lines that are selected or have a caret on them. Uses spaces or a tab depending on [indentUseSpaces]. Equivalent to the [ProjectSettings.input/uiTextDedent] action. See [indentLines]. */ - public final fun unindentLines(): Unit { + public final fun unindentLines() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.unindentLinesPtr, NIL) } /** - * Converts the indents of lines between [fromLine] and [toLine] to tabs or spaces as set by - * [indentUseSpaces]. + * Converts the indents of lines between [fromLine] and [toLine] to tabs or spaces as set by [indentUseSpaces]. * * Values of `-1` convert the entire text. */ @JvmOverloads - public final fun convertIndent(fromLine: Int = -1, toLine: Int = -1): Unit { + public final fun convertIndent(fromLine: Int = -1, toLine: Int = -1) { TransferContext.writeArguments(LONG to fromLine.toLong(), LONG to toLine.toLong()) TransferContext.callMethod(ptr, MethodBindings.convertIndentPtr, NIL) } - public final fun setAutoBraceCompletionEnabled(enable: Boolean): Unit { + public final fun setAutoBraceCompletionEnabled(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setAutoBraceCompletionEnabledPtr, NIL) } @@ -465,7 +420,7 @@ public open class CodeEdit : TextEdit() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setHighlightMatchingBracesEnabled(enable: Boolean): Unit { + public final fun setHighlightMatchingBracesEnabled(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setHighlightMatchingBracesEnabledPtr, NIL) } @@ -481,12 +436,12 @@ public open class CodeEdit : TextEdit() { * * Both the start and end keys must be symbols. Only the start key has to be unique. */ - public final fun addAutoBraceCompletionPair(startKey: String, endKey: String): Unit { + public final fun addAutoBraceCompletionPair(startKey: String, endKey: String) { TransferContext.writeArguments(STRING to startKey, STRING to endKey) TransferContext.callMethod(ptr, MethodBindings.addAutoBraceCompletionPairPtr, NIL) } - public final fun setAutoBraceCompletionPairs(pairs: Dictionary): Unit { + public final fun setAutoBraceCompletionPairs(pairs: Dictionary) { TransferContext.writeArguments(DICTIONARY to pairs) TransferContext.callMethod(ptr, MethodBindings.setAutoBraceCompletionPairsPtr, NIL) } @@ -524,7 +479,7 @@ public open class CodeEdit : TextEdit() { return (TransferContext.readReturnValue(STRING) as String) } - public final fun setDrawBreakpointsGutter(enable: Boolean): Unit { + public final fun setDrawBreakpointsGutter(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setDrawBreakpointsGutterPtr, NIL) } @@ -535,7 +490,7 @@ public open class CodeEdit : TextEdit() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setDrawBookmarksGutter(enable: Boolean): Unit { + public final fun setDrawBookmarksGutter(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setDrawBookmarksGutterPtr, NIL) } @@ -546,7 +501,7 @@ public open class CodeEdit : TextEdit() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setDrawExecutingLinesGutter(enable: Boolean): Unit { + public final fun setDrawExecutingLinesGutter(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setDrawExecutingLinesGutterPtr, NIL) } @@ -558,11 +513,9 @@ public open class CodeEdit : TextEdit() { } /** - * Sets the given line as a breakpoint. If `true` and [guttersDrawBreakpointsGutter] is `true`, - * draws the [theme_item breakpoint] icon in the gutter for this line. See [getBreakpointedLines] and - * [isLineBreakpointed]. + * Sets the given line as a breakpoint. If `true` and [guttersDrawBreakpointsGutter] is `true`, draws the [theme_item breakpoint] icon in the gutter for this line. See [getBreakpointedLines] and [isLineBreakpointed]. */ - public final fun setLineAsBreakpoint(line: Int, breakpointed: Boolean): Unit { + public final fun setLineAsBreakpoint(line: Int, breakpointed: Boolean) { TransferContext.writeArguments(LONG to line.toLong(), BOOL to breakpointed) TransferContext.callMethod(ptr, MethodBindings.setLineAsBreakpointPtr, NIL) } @@ -579,7 +532,7 @@ public open class CodeEdit : TextEdit() { /** * Clears all breakpointed lines. */ - public final fun clearBreakpointedLines(): Unit { + public final fun clearBreakpointedLines() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.clearBreakpointedLinesPtr, NIL) } @@ -594,11 +547,9 @@ public open class CodeEdit : TextEdit() { } /** - * Sets the given line as bookmarked. If `true` and [guttersDrawBookmarks] is `true`, draws the - * [theme_item bookmark] icon in the gutter for this line. See [getBookmarkedLines] and - * [isLineBookmarked]. + * Sets the given line as bookmarked. If `true` and [guttersDrawBookmarks] is `true`, draws the [theme_item bookmark] icon in the gutter for this line. See [getBookmarkedLines] and [isLineBookmarked]. */ - public final fun setLineAsBookmarked(line: Int, bookmarked: Boolean): Unit { + public final fun setLineAsBookmarked(line: Int, bookmarked: Boolean) { TransferContext.writeArguments(LONG to line.toLong(), BOOL to bookmarked) TransferContext.callMethod(ptr, MethodBindings.setLineAsBookmarkedPtr, NIL) } @@ -615,7 +566,7 @@ public open class CodeEdit : TextEdit() { /** * Clears all bookmarked lines. */ - public final fun clearBookmarkedLines(): Unit { + public final fun clearBookmarkedLines() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.clearBookmarkedLinesPtr, NIL) } @@ -630,11 +581,9 @@ public open class CodeEdit : TextEdit() { } /** - * Sets the given line as executing. If `true` and [guttersDrawExecutingLines] is `true`, draws - * the [theme_item executing_line] icon in the gutter for this line. See [getExecutingLines] and - * [isLineExecuting]. + * Sets the given line as executing. If `true` and [guttersDrawExecutingLines] is `true`, draws the [theme_item executing_line] icon in the gutter for this line. See [getExecutingLines] and [isLineExecuting]. */ - public final fun setLineAsExecuting(line: Int, executing: Boolean): Unit { + public final fun setLineAsExecuting(line: Int, executing: Boolean) { TransferContext.writeArguments(LONG to line.toLong(), BOOL to executing) TransferContext.callMethod(ptr, MethodBindings.setLineAsExecutingPtr, NIL) } @@ -651,7 +600,7 @@ public open class CodeEdit : TextEdit() { /** * Clears all executed lines. */ - public final fun clearExecutingLines(): Unit { + public final fun clearExecutingLines() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.clearExecutingLinesPtr, NIL) } @@ -665,7 +614,7 @@ public open class CodeEdit : TextEdit() { return (TransferContext.readReturnValue(PACKED_INT_32_ARRAY) as PackedInt32Array) } - public final fun setDrawLineNumbers(enable: Boolean): Unit { + public final fun setDrawLineNumbers(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setDrawLineNumbersPtr, NIL) } @@ -676,7 +625,7 @@ public open class CodeEdit : TextEdit() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setLineNumbersZeroPadded(enable: Boolean): Unit { + public final fun setLineNumbersZeroPadded(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setLineNumbersZeroPaddedPtr, NIL) } @@ -687,7 +636,7 @@ public open class CodeEdit : TextEdit() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setDrawFoldGutter(enable: Boolean): Unit { + public final fun setDrawFoldGutter(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setDrawFoldGutterPtr, NIL) } @@ -698,7 +647,7 @@ public open class CodeEdit : TextEdit() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setLineFoldingEnabled(enabled: Boolean): Unit { + public final fun setLineFoldingEnabled(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setLineFoldingEnabledPtr, NIL) } @@ -710,9 +659,7 @@ public open class CodeEdit : TextEdit() { } /** - * Returns `true` if the given line is foldable. A line is foldable if it is the start of a valid - * code region (see [getCodeRegionStartTag]), if it is the start of a comment or string block, or if - * the next non-empty line is more indented (see [TextEdit.getIndentLevel]). + * Returns `true` if the given line is foldable. A line is foldable if it is the start of a valid code region (see [getCodeRegionStartTag]), if it is the start of a comment or string block, or if the next non-empty line is more indented (see [TextEdit.getIndentLevel]). */ public final fun canFoldLine(line: Int): Boolean { TransferContext.writeArguments(LONG to line.toLong()) @@ -723,7 +670,7 @@ public open class CodeEdit : TextEdit() { /** * Folds the given line, if possible (see [canFoldLine]). */ - public final fun foldLine(line: Int): Unit { + public final fun foldLine(line: Int) { TransferContext.writeArguments(LONG to line.toLong()) TransferContext.callMethod(ptr, MethodBindings.foldLinePtr, NIL) } @@ -731,7 +678,7 @@ public open class CodeEdit : TextEdit() { /** * Unfolds the given line if it is folded or if it is hidden under a folded line. */ - public final fun unfoldLine(line: Int): Unit { + public final fun unfoldLine(line: Int) { TransferContext.writeArguments(LONG to line.toLong()) TransferContext.callMethod(ptr, MethodBindings.unfoldLinePtr, NIL) } @@ -739,7 +686,7 @@ public open class CodeEdit : TextEdit() { /** * Folds all lines that are possible to be folded (see [canFoldLine]). */ - public final fun foldAllLines(): Unit { + public final fun foldAllLines() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.foldAllLinesPtr, NIL) } @@ -747,7 +694,7 @@ public open class CodeEdit : TextEdit() { /** * Unfolds all lines that are folded. */ - public final fun unfoldAllLines(): Unit { + public final fun unfoldAllLines() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.unfoldAllLinesPtr, NIL) } @@ -755,7 +702,7 @@ public open class CodeEdit : TextEdit() { /** * Toggle the folding of the code block at the given line. */ - public final fun toggleFoldableLine(line: Int): Unit { + public final fun toggleFoldableLine(line: Int) { TransferContext.writeArguments(LONG to line.toLong()) TransferContext.callMethod(ptr, MethodBindings.toggleFoldableLinePtr, NIL) } @@ -763,7 +710,7 @@ public open class CodeEdit : TextEdit() { /** * Toggle the folding of the code block on all lines with a caret on them. */ - public final fun toggleFoldableLinesAtCarets(): Unit { + public final fun toggleFoldableLinesAtCarets() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.toggleFoldableLinesAtCaretsPtr, NIL) } @@ -787,18 +734,15 @@ public open class CodeEdit : TextEdit() { } /** - * Creates a new code region with the selection. At least one single line comment delimiter have - * to be defined (see [addCommentDelimiter]). + * Creates a new code region with the selection. At least one single line comment delimiter have to be defined (see [addCommentDelimiter]). * - * A code region is a part of code that is highlighted when folded and can help organize your - * script. + * A code region is a part of code that is highlighted when folded and can help organize your script. * * Code region start and end tags can be customized (see [setCodeRegionTags]). * - * Code regions are delimited using start and end tags (respectively `region` and `endregion` by - * default) preceded by one line comment delimiter. (eg. `#region` and `#endregion`) + * Code regions are delimited using start and end tags (respectively `region` and `endregion` by default) preceded by one line comment delimiter. (eg. `#region` and `#endregion`) */ - public final fun createCodeRegion(): Unit { + public final fun createCodeRegion() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.createCodeRegionPtr, NIL) } @@ -825,7 +769,7 @@ public open class CodeEdit : TextEdit() { * Sets the code region start and end tags (without comment delimiter). */ @JvmOverloads - public final fun setCodeRegionTags(start: String = "region", end: String = "endregion"): Unit { + public final fun setCodeRegionTags(start: String = "region", end: String = "endregion") { TransferContext.writeArguments(STRING to start, STRING to end) TransferContext.callMethod(ptr, MethodBindings.setCodeRegionTagsPtr, NIL) } @@ -849,18 +793,16 @@ public open class CodeEdit : TextEdit() { } /** - * Defines a string delimiter from [startKey] to [endKey]. Both keys should be symbols, and - * [startKey] must not be shared with other delimiters. + * Defines a string delimiter from [startKey] to [endKey]. Both keys should be symbols, and [startKey] must not be shared with other delimiters. * - * If [lineOnly] is `true` or [endKey] is an empty [String], the region does not carry over to the - * next line. + * If [lineOnly] is `true` or [endKey] is an empty [String], the region does not carry over to the next line. */ @JvmOverloads public final fun addStringDelimiter( startKey: String, endKey: String, lineOnly: Boolean = false, - ): Unit { + ) { TransferContext.writeArguments(STRING to startKey, STRING to endKey, BOOL to lineOnly) TransferContext.callMethod(ptr, MethodBindings.addStringDelimiterPtr, NIL) } @@ -868,7 +810,7 @@ public open class CodeEdit : TextEdit() { /** * Removes the string delimiter with [startKey]. */ - public final fun removeStringDelimiter(startKey: String): Unit { + public final fun removeStringDelimiter(startKey: String) { TransferContext.writeArguments(STRING to startKey) TransferContext.callMethod(ptr, MethodBindings.removeStringDelimiterPtr, NIL) } @@ -882,7 +824,7 @@ public open class CodeEdit : TextEdit() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setStringDelimiters(stringDelimiters: VariantArray): Unit { + public final fun setStringDelimiters(stringDelimiters: VariantArray) { TransferContext.writeArguments(ARRAY to stringDelimiters) TransferContext.callMethod(ptr, MethodBindings.setStringDelimitersPtr, NIL) } @@ -890,7 +832,7 @@ public open class CodeEdit : TextEdit() { /** * Removes all string delimiters. */ - public final fun clearStringDelimiters(): Unit { + public final fun clearStringDelimiters() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.clearStringDelimitersPtr, NIL) } @@ -902,8 +844,7 @@ public open class CodeEdit : TextEdit() { } /** - * Returns the delimiter index if [line] [column] is in a string. If [column] is not provided, - * will return the delimiter index if the entire [line] is a string. Otherwise `-1`. + * Returns the delimiter index if [line] [column] is in a string. If [column] is not provided, will return the delimiter index if the entire [line] is a string. Otherwise `-1`. */ @JvmOverloads public final fun isInString(line: Int, column: Int = -1): Int { @@ -913,18 +854,16 @@ public open class CodeEdit : TextEdit() { } /** - * Adds a comment delimiter from [startKey] to [endKey]. Both keys should be symbols, and - * [startKey] must not be shared with other delimiters. + * Adds a comment delimiter from [startKey] to [endKey]. Both keys should be symbols, and [startKey] must not be shared with other delimiters. * - * If [lineOnly] is `true` or [endKey] is an empty [String], the region does not carry over to the - * next line. + * If [lineOnly] is `true` or [endKey] is an empty [String], the region does not carry over to the next line. */ @JvmOverloads public final fun addCommentDelimiter( startKey: String, endKey: String, lineOnly: Boolean = false, - ): Unit { + ) { TransferContext.writeArguments(STRING to startKey, STRING to endKey, BOOL to lineOnly) TransferContext.callMethod(ptr, MethodBindings.addCommentDelimiterPtr, NIL) } @@ -932,7 +871,7 @@ public open class CodeEdit : TextEdit() { /** * Removes the comment delimiter with [startKey]. */ - public final fun removeCommentDelimiter(startKey: String): Unit { + public final fun removeCommentDelimiter(startKey: String) { TransferContext.writeArguments(STRING to startKey) TransferContext.callMethod(ptr, MethodBindings.removeCommentDelimiterPtr, NIL) } @@ -946,7 +885,7 @@ public open class CodeEdit : TextEdit() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setCommentDelimiters(commentDelimiters: VariantArray): Unit { + public final fun setCommentDelimiters(commentDelimiters: VariantArray) { TransferContext.writeArguments(ARRAY to commentDelimiters) TransferContext.callMethod(ptr, MethodBindings.setCommentDelimitersPtr, NIL) } @@ -954,7 +893,7 @@ public open class CodeEdit : TextEdit() { /** * Removes all comment delimiters. */ - public final fun clearCommentDelimiters(): Unit { + public final fun clearCommentDelimiters() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.clearCommentDelimitersPtr, NIL) } @@ -966,8 +905,7 @@ public open class CodeEdit : TextEdit() { } /** - * Returns delimiter index if [line] [column] is in a comment. If [column] is not provided, will - * return delimiter index if the entire [line] is a comment. Otherwise `-1`. + * Returns delimiter index if [line] [column] is in a comment. If [column] is not provided, will return delimiter index if the entire [line] is a comment. Otherwise `-1`. */ @JvmOverloads public final fun isInComment(line: Int, column: Int = -1): Int { @@ -995,8 +933,7 @@ public open class CodeEdit : TextEdit() { } /** - * If [line] [column] is in a string or comment, returns the start position of the region. If not - * or no start could be found, both [Vector2] values will be `-1`. + * If [line] [column] is in a string or comment, returns the start position of the region. If not or no start could be found, both [Vector2] values will be `-1`. */ public final fun getDelimiterStartPosition(line: Int, column: Int): Vector2 { TransferContext.writeArguments(LONG to line.toLong(), LONG to column.toLong()) @@ -1005,8 +942,7 @@ public open class CodeEdit : TextEdit() { } /** - * If [line] [column] is in a string or comment, returns the end position of the region. If not or - * no end could be found, both [Vector2] values will be `-1`. + * If [line] [column] is in a string or comment, returns the end position of the region. If not or no end could be found, both [Vector2] values will be `-1`. */ public final fun getDelimiterEndPosition(line: Int, column: Int): Vector2 { TransferContext.writeArguments(LONG to line.toLong(), LONG to column.toLong()) @@ -1017,16 +953,15 @@ public open class CodeEdit : TextEdit() { /** * Sets the code hint text. Pass an empty string to clear. */ - public final fun setCodeHint(codeHint: String): Unit { + public final fun setCodeHint(codeHint: String) { TransferContext.writeArguments(STRING to codeHint) TransferContext.callMethod(ptr, MethodBindings.setCodeHintPtr, NIL) } /** - * If `true`, the code hint will draw below the main caret. If `false`, the code hint will draw - * above the main caret. See [setCodeHint]. + * If `true`, the code hint will draw below the main caret. If `false`, the code hint will draw above the main caret. See [setCodeHint]. */ - public final fun setCodeHintDrawBelow(drawBelow: Boolean): Unit { + public final fun setCodeHintDrawBelow(drawBelow: Boolean) { TransferContext.writeArguments(BOOL to drawBelow) TransferContext.callMethod(ptr, MethodBindings.setCodeHintDrawBelowPtr, NIL) } @@ -1041,22 +976,18 @@ public open class CodeEdit : TextEdit() { } /** - * Emits [signal code_completion_requested], if [force] is `true` will bypass all checks. - * Otherwise will check that the caret is in a word or in front of a prefix. Will ignore the request - * if all current options are of type file path, node path, or signal. + * Emits [signal code_completion_requested], if [force] is `true` will bypass all checks. Otherwise will check that the caret is in a word or in front of a prefix. Will ignore the request if all current options are of type file path, node path, or signal. */ @JvmOverloads - public final fun requestCodeCompletion(force: Boolean = false): Unit { + public final fun requestCodeCompletion(force: Boolean = false) { TransferContext.writeArguments(BOOL to force) TransferContext.callMethod(ptr, MethodBindings.requestCodeCompletionPtr, NIL) } /** - * Submits an item to the queue of potential candidates for the autocomplete menu. Call - * [updateCodeCompletionOptions] to update the list. + * Submits an item to the queue of potential candidates for the autocomplete menu. Call [updateCodeCompletionOptions] to update the list. * - * [location] indicates location of the option relative to the location of the code completion - * query. See [CodeEdit.CodeCompletionLocation] for how to set this value. + * [location] indicates location of the option relative to the location of the code completion query. See [CodeEdit.CodeCompletionLocation] for how to set this value. * * **Note:** This list will replace all current candidates. */ @@ -1069,18 +1000,17 @@ public open class CodeEdit : TextEdit() { icon: Resource? = null, `value`: Any? = null, location: Int = 1024, - ): Unit { + ) { TransferContext.writeArguments(LONG to type.id, STRING to displayText, STRING to insertText, COLOR to textColor, OBJECT to icon, ANY to value, LONG to location.toLong()) TransferContext.callMethod(ptr, MethodBindings.addCodeCompletionOptionPtr, NIL) } /** - * Submits all completion options added with [addCodeCompletionOption]. Will try to force the - * autocomplete menu to popup, if [force] is `true`. + * Submits all completion options added with [addCodeCompletionOption]. Will try to force the autocomplete menu to popup, if [force] is `true`. * * **Note:** This will replace all current candidates. */ - public final fun updateCodeCompletionOptions(force: Boolean): Unit { + public final fun updateCodeCompletionOptions(force: Boolean) { TransferContext.writeArguments(BOOL to force) TransferContext.callMethod(ptr, MethodBindings.updateCodeCompletionOptionsPtr, NIL) } @@ -1127,17 +1057,16 @@ public open class CodeEdit : TextEdit() { /** * Sets the current selected completion option. */ - public final fun setCodeCompletionSelectedIndex(index: Int): Unit { + public final fun setCodeCompletionSelectedIndex(index: Int) { TransferContext.writeArguments(LONG to index.toLong()) TransferContext.callMethod(ptr, MethodBindings.setCodeCompletionSelectedIndexPtr, NIL) } /** - * Inserts the selected entry into the text. If [replace] is `true`, any existing text is replaced - * rather than merged. + * Inserts the selected entry into the text. If [replace] is `true`, any existing text is replaced rather than merged. */ @JvmOverloads - public final fun confirmCodeCompletion(replace: Boolean = false): Unit { + public final fun confirmCodeCompletion(replace: Boolean = false) { TransferContext.writeArguments(BOOL to replace) TransferContext.callMethod(ptr, MethodBindings.confirmCodeCompletionPtr, NIL) } @@ -1145,12 +1074,12 @@ public open class CodeEdit : TextEdit() { /** * Cancels the autocomplete menu. */ - public final fun cancelCodeCompletion(): Unit { + public final fun cancelCodeCompletion() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.cancelCodeCompletionPtr, NIL) } - public final fun setCodeCompletionEnabled(enable: Boolean): Unit { + public final fun setCodeCompletionEnabled(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setCodeCompletionEnabledPtr, NIL) } @@ -1161,7 +1090,7 @@ public open class CodeEdit : TextEdit() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setCodeCompletionPrefixes(prefixes: VariantArray): Unit { + public final fun setCodeCompletionPrefixes(prefixes: VariantArray) { TransferContext.writeArguments(ARRAY to prefixes) TransferContext.callMethod(ptr, MethodBindings.setCodeCompletionPrefixesPtr, NIL) } @@ -1172,7 +1101,7 @@ public open class CodeEdit : TextEdit() { return (TransferContext.readReturnValue(ARRAY) as VariantArray) } - public final fun setLineLengthGuidelines(guidelineColumns: VariantArray): Unit { + public final fun setLineLengthGuidelines(guidelineColumns: VariantArray) { TransferContext.writeArguments(ARRAY to guidelineColumns) TransferContext.callMethod(ptr, MethodBindings.setLineLengthGuidelinesPtr, NIL) } @@ -1183,7 +1112,7 @@ public open class CodeEdit : TextEdit() { return (TransferContext.readReturnValue(ARRAY) as VariantArray) } - public final fun setSymbolLookupOnClickEnabled(enable: Boolean): Unit { + public final fun setSymbolLookupOnClickEnabled(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setSymbolLookupOnClickEnabledPtr, NIL) } @@ -1215,12 +1144,12 @@ public open class CodeEdit : TextEdit() { /** * Sets the symbol emitted by [signal symbol_validate] as a valid lookup. */ - public final fun setSymbolLookupWordAsValid(valid: Boolean): Unit { + public final fun setSymbolLookupWordAsValid(valid: Boolean) { TransferContext.writeArguments(BOOL to valid) TransferContext.callMethod(ptr, MethodBindings.setSymbolLookupWordAsValidPtr, NIL) } - public final fun setSymbolTooltipOnHoverEnabled(enable: Boolean): Unit { + public final fun setSymbolTooltipOnHoverEnabled(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setSymbolTooltipOnHoverEnabledPtr, NIL) } @@ -1234,7 +1163,7 @@ public open class CodeEdit : TextEdit() { /** * Moves all lines up that are selected or have a caret on them. */ - public final fun moveLinesUp(): Unit { + public final fun moveLinesUp() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.moveLinesUpPtr, NIL) } @@ -1242,7 +1171,7 @@ public open class CodeEdit : TextEdit() { /** * Moves all lines down that are selected or have a caret on them. */ - public final fun moveLinesDown(): Unit { + public final fun moveLinesDown() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.moveLinesDownPtr, NIL) } @@ -1250,7 +1179,7 @@ public open class CodeEdit : TextEdit() { /** * Deletes all lines that are selected or have a caret on them. */ - public final fun deleteLines(): Unit { + public final fun deleteLines() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.deleteLinesPtr, NIL) } @@ -1258,16 +1187,15 @@ public open class CodeEdit : TextEdit() { /** * Duplicates all selected text and duplicates all lines with a caret on them. */ - public final fun duplicateSelection(): Unit { + public final fun duplicateSelection() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.duplicateSelectionPtr, NIL) } /** - * Duplicates all lines currently selected with any caret. Duplicates the entire line beneath the - * current one no matter where the caret is within the line. + * Duplicates all lines currently selected with any caret. Duplicates the entire line beneath the current one no matter where the caret is within the line. */ - public final fun duplicateLines(): Unit { + public final fun duplicateLines() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.duplicateLinesPtr, NIL) } @@ -1331,28 +1259,21 @@ public open class CodeEdit : TextEdit() { id: Long, ) { /** - * The option is local to the location of the code completion query - e.g. a local variable. - * Subsequent value of location represent options from the outer class, the exact value represent - * how far they are (in terms of inner classes). + * The option is local to the location of the code completion query - e.g. a local variable. Subsequent value of location represent options from the outer class, the exact value represent how far they are (in terms of inner classes). */ LOCATION_LOCAL(0), /** - * The option is from the containing class or a parent class, relative to the location of the - * code completion query. Perform a bitwise OR with the class depth (e.g. `0` for the local class, - * `1` for the parent, `2` for the grandparent, etc.) to store the depth of an option in the class - * or a parent class. + * The option is from the containing class or a parent class, relative to the location of the code completion query. Perform a bitwise OR with the class depth (e.g. `0` for the local class, `1` for the parent, `2` for the grandparent, etc.) to store the depth of an option in the class or a parent class. */ LOCATION_PARENT_MASK(256), /** - * The option is from user code which is not local and not in a derived class (e.g. Autoload - * Singletons). + * The option is from user code which is not local and not in a derived class (e.g. Autoload Singletons). */ LOCATION_OTHER_USER_CODE(512), /** - * The option is from other engine code, not covered by the other enum constants - e.g. built-in - * classes. + * The option is from other engine code, not covered by the other enum constants - e.g. built-in classes. */ - LOCATION_OTHER(1024), + LOCATION_OTHER(1_024), ; public val id: Long @@ -1369,336 +1290,336 @@ public open class CodeEdit : TextEdit() { public object MethodBindings { internal val setIndentSizePtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "set_indent_size", 1286410249) + TypeManager.getMethodBindPtr("CodeEdit", "set_indent_size", 1_286_410_249) internal val getIndentSizePtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "get_indent_size", 3905245786) + TypeManager.getMethodBindPtr("CodeEdit", "get_indent_size", 3_905_245_786) internal val setIndentUsingSpacesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "set_indent_using_spaces", 2586408642) + TypeManager.getMethodBindPtr("CodeEdit", "set_indent_using_spaces", 2_586_408_642) internal val isIndentUsingSpacesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "is_indent_using_spaces", 36873697) + TypeManager.getMethodBindPtr("CodeEdit", "is_indent_using_spaces", 36_873_697) internal val setAutoIndentEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "set_auto_indent_enabled", 2586408642) + TypeManager.getMethodBindPtr("CodeEdit", "set_auto_indent_enabled", 2_586_408_642) internal val isAutoIndentEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "is_auto_indent_enabled", 36873697) + TypeManager.getMethodBindPtr("CodeEdit", "is_auto_indent_enabled", 36_873_697) internal val setAutoIndentPrefixesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "set_auto_indent_prefixes", 381264803) + TypeManager.getMethodBindPtr("CodeEdit", "set_auto_indent_prefixes", 381_264_803) internal val getAutoIndentPrefixesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "get_auto_indent_prefixes", 3995934104) + TypeManager.getMethodBindPtr("CodeEdit", "get_auto_indent_prefixes", 3_995_934_104) internal val doIndentPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "do_indent", 3218959716) + TypeManager.getMethodBindPtr("CodeEdit", "do_indent", 3_218_959_716) internal val indentLinesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "indent_lines", 3218959716) + TypeManager.getMethodBindPtr("CodeEdit", "indent_lines", 3_218_959_716) internal val unindentLinesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "unindent_lines", 3218959716) + TypeManager.getMethodBindPtr("CodeEdit", "unindent_lines", 3_218_959_716) internal val convertIndentPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "convert_indent", 423910286) + TypeManager.getMethodBindPtr("CodeEdit", "convert_indent", 423_910_286) internal val setAutoBraceCompletionEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "set_auto_brace_completion_enabled", 2586408642) + TypeManager.getMethodBindPtr("CodeEdit", "set_auto_brace_completion_enabled", 2_586_408_642) internal val isAutoBraceCompletionEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "is_auto_brace_completion_enabled", 36873697) + TypeManager.getMethodBindPtr("CodeEdit", "is_auto_brace_completion_enabled", 36_873_697) internal val setHighlightMatchingBracesEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "set_highlight_matching_braces_enabled", 2586408642) + TypeManager.getMethodBindPtr("CodeEdit", "set_highlight_matching_braces_enabled", 2_586_408_642) internal val isHighlightMatchingBracesEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "is_highlight_matching_braces_enabled", 36873697) + TypeManager.getMethodBindPtr("CodeEdit", "is_highlight_matching_braces_enabled", 36_873_697) internal val addAutoBraceCompletionPairPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "add_auto_brace_completion_pair", 3186203200) + TypeManager.getMethodBindPtr("CodeEdit", "add_auto_brace_completion_pair", 3_186_203_200) internal val setAutoBraceCompletionPairsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "set_auto_brace_completion_pairs", 4155329257) + TypeManager.getMethodBindPtr("CodeEdit", "set_auto_brace_completion_pairs", 4_155_329_257) internal val getAutoBraceCompletionPairsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "get_auto_brace_completion_pairs", 3102165223) + TypeManager.getMethodBindPtr("CodeEdit", "get_auto_brace_completion_pairs", 3_102_165_223) internal val hasAutoBraceCompletionOpenKeyPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "has_auto_brace_completion_open_key", 3927539163) + TypeManager.getMethodBindPtr("CodeEdit", "has_auto_brace_completion_open_key", 3_927_539_163) internal val hasAutoBraceCompletionCloseKeyPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "has_auto_brace_completion_close_key", 3927539163) + TypeManager.getMethodBindPtr("CodeEdit", "has_auto_brace_completion_close_key", 3_927_539_163) internal val getAutoBraceCompletionCloseKeyPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "get_auto_brace_completion_close_key", 3135753539) + TypeManager.getMethodBindPtr("CodeEdit", "get_auto_brace_completion_close_key", 3_135_753_539) internal val setDrawBreakpointsGutterPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "set_draw_breakpoints_gutter", 2586408642) + TypeManager.getMethodBindPtr("CodeEdit", "set_draw_breakpoints_gutter", 2_586_408_642) internal val isDrawingBreakpointsGutterPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "is_drawing_breakpoints_gutter", 36873697) + TypeManager.getMethodBindPtr("CodeEdit", "is_drawing_breakpoints_gutter", 36_873_697) internal val setDrawBookmarksGutterPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "set_draw_bookmarks_gutter", 2586408642) + TypeManager.getMethodBindPtr("CodeEdit", "set_draw_bookmarks_gutter", 2_586_408_642) internal val isDrawingBookmarksGutterPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "is_drawing_bookmarks_gutter", 36873697) + TypeManager.getMethodBindPtr("CodeEdit", "is_drawing_bookmarks_gutter", 36_873_697) internal val setDrawExecutingLinesGutterPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "set_draw_executing_lines_gutter", 2586408642) + TypeManager.getMethodBindPtr("CodeEdit", "set_draw_executing_lines_gutter", 2_586_408_642) internal val isDrawingExecutingLinesGutterPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "is_drawing_executing_lines_gutter", 36873697) + TypeManager.getMethodBindPtr("CodeEdit", "is_drawing_executing_lines_gutter", 36_873_697) internal val setLineAsBreakpointPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "set_line_as_breakpoint", 300928843) + TypeManager.getMethodBindPtr("CodeEdit", "set_line_as_breakpoint", 300_928_843) internal val isLineBreakpointedPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "is_line_breakpointed", 1116898809) + TypeManager.getMethodBindPtr("CodeEdit", "is_line_breakpointed", 1_116_898_809) internal val clearBreakpointedLinesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "clear_breakpointed_lines", 3218959716) + TypeManager.getMethodBindPtr("CodeEdit", "clear_breakpointed_lines", 3_218_959_716) internal val getBreakpointedLinesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "get_breakpointed_lines", 1930428628) + TypeManager.getMethodBindPtr("CodeEdit", "get_breakpointed_lines", 1_930_428_628) internal val setLineAsBookmarkedPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "set_line_as_bookmarked", 300928843) + TypeManager.getMethodBindPtr("CodeEdit", "set_line_as_bookmarked", 300_928_843) internal val isLineBookmarkedPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "is_line_bookmarked", 1116898809) + TypeManager.getMethodBindPtr("CodeEdit", "is_line_bookmarked", 1_116_898_809) internal val clearBookmarkedLinesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "clear_bookmarked_lines", 3218959716) + TypeManager.getMethodBindPtr("CodeEdit", "clear_bookmarked_lines", 3_218_959_716) internal val getBookmarkedLinesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "get_bookmarked_lines", 1930428628) + TypeManager.getMethodBindPtr("CodeEdit", "get_bookmarked_lines", 1_930_428_628) internal val setLineAsExecutingPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "set_line_as_executing", 300928843) + TypeManager.getMethodBindPtr("CodeEdit", "set_line_as_executing", 300_928_843) internal val isLineExecutingPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "is_line_executing", 1116898809) + TypeManager.getMethodBindPtr("CodeEdit", "is_line_executing", 1_116_898_809) internal val clearExecutingLinesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "clear_executing_lines", 3218959716) + TypeManager.getMethodBindPtr("CodeEdit", "clear_executing_lines", 3_218_959_716) internal val getExecutingLinesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "get_executing_lines", 1930428628) + TypeManager.getMethodBindPtr("CodeEdit", "get_executing_lines", 1_930_428_628) internal val setDrawLineNumbersPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "set_draw_line_numbers", 2586408642) + TypeManager.getMethodBindPtr("CodeEdit", "set_draw_line_numbers", 2_586_408_642) internal val isDrawLineNumbersEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "is_draw_line_numbers_enabled", 36873697) + TypeManager.getMethodBindPtr("CodeEdit", "is_draw_line_numbers_enabled", 36_873_697) internal val setLineNumbersZeroPaddedPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "set_line_numbers_zero_padded", 2586408642) + TypeManager.getMethodBindPtr("CodeEdit", "set_line_numbers_zero_padded", 2_586_408_642) internal val isLineNumbersZeroPaddedPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "is_line_numbers_zero_padded", 36873697) + TypeManager.getMethodBindPtr("CodeEdit", "is_line_numbers_zero_padded", 36_873_697) internal val setDrawFoldGutterPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "set_draw_fold_gutter", 2586408642) + TypeManager.getMethodBindPtr("CodeEdit", "set_draw_fold_gutter", 2_586_408_642) internal val isDrawingFoldGutterPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "is_drawing_fold_gutter", 36873697) + TypeManager.getMethodBindPtr("CodeEdit", "is_drawing_fold_gutter", 36_873_697) internal val setLineFoldingEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "set_line_folding_enabled", 2586408642) + TypeManager.getMethodBindPtr("CodeEdit", "set_line_folding_enabled", 2_586_408_642) internal val isLineFoldingEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "is_line_folding_enabled", 36873697) + TypeManager.getMethodBindPtr("CodeEdit", "is_line_folding_enabled", 36_873_697) internal val canFoldLinePtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "can_fold_line", 1116898809) + TypeManager.getMethodBindPtr("CodeEdit", "can_fold_line", 1_116_898_809) internal val foldLinePtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "fold_line", 1286410249) + TypeManager.getMethodBindPtr("CodeEdit", "fold_line", 1_286_410_249) internal val unfoldLinePtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "unfold_line", 1286410249) + TypeManager.getMethodBindPtr("CodeEdit", "unfold_line", 1_286_410_249) internal val foldAllLinesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "fold_all_lines", 3218959716) + TypeManager.getMethodBindPtr("CodeEdit", "fold_all_lines", 3_218_959_716) internal val unfoldAllLinesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "unfold_all_lines", 3218959716) + TypeManager.getMethodBindPtr("CodeEdit", "unfold_all_lines", 3_218_959_716) internal val toggleFoldableLinePtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "toggle_foldable_line", 1286410249) + TypeManager.getMethodBindPtr("CodeEdit", "toggle_foldable_line", 1_286_410_249) internal val toggleFoldableLinesAtCaretsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "toggle_foldable_lines_at_carets", 3218959716) + TypeManager.getMethodBindPtr("CodeEdit", "toggle_foldable_lines_at_carets", 3_218_959_716) internal val isLineFoldedPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "is_line_folded", 1116898809) + TypeManager.getMethodBindPtr("CodeEdit", "is_line_folded", 1_116_898_809) internal val getFoldedLinesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "get_folded_lines", 3995934104) + TypeManager.getMethodBindPtr("CodeEdit", "get_folded_lines", 3_995_934_104) internal val createCodeRegionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "create_code_region", 3218959716) + TypeManager.getMethodBindPtr("CodeEdit", "create_code_region", 3_218_959_716) internal val getCodeRegionStartTagPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "get_code_region_start_tag", 201670096) + TypeManager.getMethodBindPtr("CodeEdit", "get_code_region_start_tag", 201_670_096) internal val getCodeRegionEndTagPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "get_code_region_end_tag", 201670096) + TypeManager.getMethodBindPtr("CodeEdit", "get_code_region_end_tag", 201_670_096) internal val setCodeRegionTagsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "set_code_region_tags", 708800718) + TypeManager.getMethodBindPtr("CodeEdit", "set_code_region_tags", 708_800_718) internal val isLineCodeRegionStartPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "is_line_code_region_start", 1116898809) + TypeManager.getMethodBindPtr("CodeEdit", "is_line_code_region_start", 1_116_898_809) internal val isLineCodeRegionEndPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "is_line_code_region_end", 1116898809) + TypeManager.getMethodBindPtr("CodeEdit", "is_line_code_region_end", 1_116_898_809) internal val addStringDelimiterPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "add_string_delimiter", 3146098955) + TypeManager.getMethodBindPtr("CodeEdit", "add_string_delimiter", 3_146_098_955) internal val removeStringDelimiterPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "remove_string_delimiter", 83702148) + TypeManager.getMethodBindPtr("CodeEdit", "remove_string_delimiter", 83_702_148) internal val hasStringDelimiterPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "has_string_delimiter", 3927539163) + TypeManager.getMethodBindPtr("CodeEdit", "has_string_delimiter", 3_927_539_163) internal val setStringDelimitersPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "set_string_delimiters", 381264803) + TypeManager.getMethodBindPtr("CodeEdit", "set_string_delimiters", 381_264_803) internal val clearStringDelimitersPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "clear_string_delimiters", 3218959716) + TypeManager.getMethodBindPtr("CodeEdit", "clear_string_delimiters", 3_218_959_716) internal val getStringDelimitersPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "get_string_delimiters", 3995934104) + TypeManager.getMethodBindPtr("CodeEdit", "get_string_delimiters", 3_995_934_104) internal val isInStringPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "is_in_string", 688195400) + TypeManager.getMethodBindPtr("CodeEdit", "is_in_string", 688_195_400) internal val addCommentDelimiterPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "add_comment_delimiter", 3146098955) + TypeManager.getMethodBindPtr("CodeEdit", "add_comment_delimiter", 3_146_098_955) internal val removeCommentDelimiterPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "remove_comment_delimiter", 83702148) + TypeManager.getMethodBindPtr("CodeEdit", "remove_comment_delimiter", 83_702_148) internal val hasCommentDelimiterPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "has_comment_delimiter", 3927539163) + TypeManager.getMethodBindPtr("CodeEdit", "has_comment_delimiter", 3_927_539_163) internal val setCommentDelimitersPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "set_comment_delimiters", 381264803) + TypeManager.getMethodBindPtr("CodeEdit", "set_comment_delimiters", 381_264_803) internal val clearCommentDelimitersPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "clear_comment_delimiters", 3218959716) + TypeManager.getMethodBindPtr("CodeEdit", "clear_comment_delimiters", 3_218_959_716) internal val getCommentDelimitersPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "get_comment_delimiters", 3995934104) + TypeManager.getMethodBindPtr("CodeEdit", "get_comment_delimiters", 3_995_934_104) internal val isInCommentPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "is_in_comment", 688195400) + TypeManager.getMethodBindPtr("CodeEdit", "is_in_comment", 688_195_400) internal val getDelimiterStartKeyPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "get_delimiter_start_key", 844755477) + TypeManager.getMethodBindPtr("CodeEdit", "get_delimiter_start_key", 844_755_477) internal val getDelimiterEndKeyPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "get_delimiter_end_key", 844755477) + TypeManager.getMethodBindPtr("CodeEdit", "get_delimiter_end_key", 844_755_477) internal val getDelimiterStartPositionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "get_delimiter_start_position", 3016396712) + TypeManager.getMethodBindPtr("CodeEdit", "get_delimiter_start_position", 3_016_396_712) internal val getDelimiterEndPositionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "get_delimiter_end_position", 3016396712) + TypeManager.getMethodBindPtr("CodeEdit", "get_delimiter_end_position", 3_016_396_712) internal val setCodeHintPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "set_code_hint", 83702148) + TypeManager.getMethodBindPtr("CodeEdit", "set_code_hint", 83_702_148) internal val setCodeHintDrawBelowPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "set_code_hint_draw_below", 2586408642) + TypeManager.getMethodBindPtr("CodeEdit", "set_code_hint_draw_below", 2_586_408_642) internal val getTextForCodeCompletionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "get_text_for_code_completion", 201670096) + TypeManager.getMethodBindPtr("CodeEdit", "get_text_for_code_completion", 201_670_096) internal val requestCodeCompletionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "request_code_completion", 107499316) + TypeManager.getMethodBindPtr("CodeEdit", "request_code_completion", 107_499_316) internal val addCodeCompletionOptionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "add_code_completion_option", 3944379502) + TypeManager.getMethodBindPtr("CodeEdit", "add_code_completion_option", 3_944_379_502) internal val updateCodeCompletionOptionsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "update_code_completion_options", 2586408642) + TypeManager.getMethodBindPtr("CodeEdit", "update_code_completion_options", 2_586_408_642) internal val getCodeCompletionOptionsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "get_code_completion_options", 3995934104) + TypeManager.getMethodBindPtr("CodeEdit", "get_code_completion_options", 3_995_934_104) internal val getCodeCompletionOptionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "get_code_completion_option", 3485342025) + TypeManager.getMethodBindPtr("CodeEdit", "get_code_completion_option", 3_485_342_025) internal val getCodeCompletionSelectedIndexPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "get_code_completion_selected_index", 3905245786) + TypeManager.getMethodBindPtr("CodeEdit", "get_code_completion_selected_index", 3_905_245_786) internal val setCodeCompletionSelectedIndexPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "set_code_completion_selected_index", 1286410249) + TypeManager.getMethodBindPtr("CodeEdit", "set_code_completion_selected_index", 1_286_410_249) internal val confirmCodeCompletionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "confirm_code_completion", 107499316) + TypeManager.getMethodBindPtr("CodeEdit", "confirm_code_completion", 107_499_316) internal val cancelCodeCompletionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "cancel_code_completion", 3218959716) + TypeManager.getMethodBindPtr("CodeEdit", "cancel_code_completion", 3_218_959_716) internal val setCodeCompletionEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "set_code_completion_enabled", 2586408642) + TypeManager.getMethodBindPtr("CodeEdit", "set_code_completion_enabled", 2_586_408_642) internal val isCodeCompletionEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "is_code_completion_enabled", 36873697) + TypeManager.getMethodBindPtr("CodeEdit", "is_code_completion_enabled", 36_873_697) internal val setCodeCompletionPrefixesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "set_code_completion_prefixes", 381264803) + TypeManager.getMethodBindPtr("CodeEdit", "set_code_completion_prefixes", 381_264_803) internal val getCodeCompletionPrefixesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "get_code_completion_prefixes", 3995934104) + TypeManager.getMethodBindPtr("CodeEdit", "get_code_completion_prefixes", 3_995_934_104) internal val setLineLengthGuidelinesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "set_line_length_guidelines", 381264803) + TypeManager.getMethodBindPtr("CodeEdit", "set_line_length_guidelines", 381_264_803) internal val getLineLengthGuidelinesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "get_line_length_guidelines", 3995934104) + TypeManager.getMethodBindPtr("CodeEdit", "get_line_length_guidelines", 3_995_934_104) internal val setSymbolLookupOnClickEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "set_symbol_lookup_on_click_enabled", 2586408642) + TypeManager.getMethodBindPtr("CodeEdit", "set_symbol_lookup_on_click_enabled", 2_586_408_642) internal val isSymbolLookupOnClickEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "is_symbol_lookup_on_click_enabled", 36873697) + TypeManager.getMethodBindPtr("CodeEdit", "is_symbol_lookup_on_click_enabled", 36_873_697) internal val getTextForSymbolLookupPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "get_text_for_symbol_lookup", 201670096) + TypeManager.getMethodBindPtr("CodeEdit", "get_text_for_symbol_lookup", 201_670_096) internal val getTextWithCursorCharPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "get_text_with_cursor_char", 1391810591) + TypeManager.getMethodBindPtr("CodeEdit", "get_text_with_cursor_char", 1_391_810_591) internal val setSymbolLookupWordAsValidPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "set_symbol_lookup_word_as_valid", 2586408642) + TypeManager.getMethodBindPtr("CodeEdit", "set_symbol_lookup_word_as_valid", 2_586_408_642) internal val setSymbolTooltipOnHoverEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "set_symbol_tooltip_on_hover_enabled", 2586408642) + TypeManager.getMethodBindPtr("CodeEdit", "set_symbol_tooltip_on_hover_enabled", 2_586_408_642) internal val isSymbolTooltipOnHoverEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "is_symbol_tooltip_on_hover_enabled", 36873697) + TypeManager.getMethodBindPtr("CodeEdit", "is_symbol_tooltip_on_hover_enabled", 36_873_697) internal val moveLinesUpPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "move_lines_up", 3218959716) + TypeManager.getMethodBindPtr("CodeEdit", "move_lines_up", 3_218_959_716) internal val moveLinesDownPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "move_lines_down", 3218959716) + TypeManager.getMethodBindPtr("CodeEdit", "move_lines_down", 3_218_959_716) internal val deleteLinesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "delete_lines", 3218959716) + TypeManager.getMethodBindPtr("CodeEdit", "delete_lines", 3_218_959_716) internal val duplicateSelectionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "duplicate_selection", 3218959716) + TypeManager.getMethodBindPtr("CodeEdit", "duplicate_selection", 3_218_959_716) internal val duplicateLinesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeEdit", "duplicate_lines", 3218959716) + TypeManager.getMethodBindPtr("CodeEdit", "duplicate_lines", 3_218_959_716) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CodeHighlighter.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CodeHighlighter.kt index b52391cf67..c5290c2a17 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CodeHighlighter.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CodeHighlighter.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -29,8 +26,7 @@ import kotlin.jvm.JvmName import kotlin.jvm.JvmOverloads /** - * By adjusting various properties of this resource, you can change the colors of strings, comments, - * numbers, and other text patterns inside a [TextEdit] control. + * By adjusting various properties of this resource, you can change the colors of strings, comments, numbers, and other text patterns inside a [TextEdit] control. */ @GodotBaseType public open class CodeHighlighter : SyntaxHighlighter() { @@ -38,11 +34,8 @@ public open class CodeHighlighter : SyntaxHighlighter() { * Sets the color for numbers. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var numberColor: Color @@ -57,11 +50,8 @@ public open class CodeHighlighter : SyntaxHighlighter() { * Sets the color for symbols. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var symbolColor: Color @@ -76,11 +66,8 @@ public open class CodeHighlighter : SyntaxHighlighter() { * Sets color for functions. A function is a non-keyword string followed by a '('. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var functionColor: Color @@ -92,15 +79,11 @@ public open class CodeHighlighter : SyntaxHighlighter() { } /** - * Sets color for member variables. A member variable is non-keyword, non-function string - * proceeded with a '.'. + * Sets color for member variables. A member variable is non-keyword, non-function string proceeded with a '.'. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var memberVariableColor: Color @@ -112,8 +95,7 @@ public open class CodeHighlighter : SyntaxHighlighter() { } /** - * Sets the keyword colors. All existing keywords will be removed. The [Dictionary] key is the - * keyword. The value is the keyword color. + * Sets the keyword colors. All existing keywords will be removed. The [Dictionary] key is the keyword. The value is the keyword color. */ public final inline var keywordColors: Dictionary @JvmName("keywordColorsProperty") @@ -124,8 +106,7 @@ public open class CodeHighlighter : SyntaxHighlighter() { } /** - * Sets the member keyword colors. All existing member keyword will be removed. The [Dictionary] - * key is the member keyword. The value is the member keyword color. + * Sets the member keyword colors. All existing member keyword will be removed. The [Dictionary] key is the member keyword. The value is the member keyword color. */ public final inline var memberKeywordColors: Dictionary @JvmName("memberKeywordColorsProperty") @@ -136,8 +117,7 @@ public open class CodeHighlighter : SyntaxHighlighter() { } /** - * Sets the color regions. All existing regions will be removed. The [Dictionary] key is the - * region start and end key, separated by a space. The value is the region color. + * Sets the color regions. All existing regions will be removed. The [Dictionary] key is the region start and end key, separated by a space. The value is the region color. */ public final inline var colorRegions: Dictionary @JvmName("colorRegionsProperty") @@ -147,7 +127,7 @@ public open class CodeHighlighter : SyntaxHighlighter() { setColorRegions(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(153, scriptIndex) } @@ -219,12 +199,10 @@ public open class CodeHighlighter : SyntaxHighlighter() { * codehighlighter.memberVariableColor = myCoreType * `````` * - * Sets color for member variables. A member variable is non-keyword, non-function string - * proceeded with a '.'. + * Sets color for member variables. A member variable is non-keyword, non-function string proceeded with a '.'. */ @CoreTypeHelper - public final fun memberVariableColorMutate(block: Color.() -> Unit): Color = - memberVariableColor.apply { + public final fun memberVariableColorMutate(block: Color.() -> Unit): Color = memberVariableColor.apply { block(this) memberVariableColor = this } @@ -234,7 +212,7 @@ public open class CodeHighlighter : SyntaxHighlighter() { * * The keyword cannot contain any symbols except '_'. */ - public final fun addKeywordColor(keyword: String, color: Color): Unit { + public final fun addKeywordColor(keyword: String, color: Color) { TransferContext.writeArguments(STRING to keyword, COLOR to color) TransferContext.callMethod(ptr, MethodBindings.addKeywordColorPtr, NIL) } @@ -242,7 +220,7 @@ public open class CodeHighlighter : SyntaxHighlighter() { /** * Removes the keyword. */ - public final fun removeKeywordColor(keyword: String): Unit { + public final fun removeKeywordColor(keyword: String) { TransferContext.writeArguments(STRING to keyword) TransferContext.callMethod(ptr, MethodBindings.removeKeywordColorPtr, NIL) } @@ -265,7 +243,7 @@ public open class CodeHighlighter : SyntaxHighlighter() { return (TransferContext.readReturnValue(COLOR) as Color) } - public final fun setKeywordColors(keywords: Dictionary): Unit { + public final fun setKeywordColors(keywords: Dictionary) { TransferContext.writeArguments(DICTIONARY to keywords) TransferContext.callMethod(ptr, MethodBindings.setKeywordColorsPtr, NIL) } @@ -273,7 +251,7 @@ public open class CodeHighlighter : SyntaxHighlighter() { /** * Removes all keywords. */ - public final fun clearKeywordColors(): Unit { + public final fun clearKeywordColors() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.clearKeywordColorsPtr, NIL) } @@ -291,7 +269,7 @@ public open class CodeHighlighter : SyntaxHighlighter() { * * It will not be highlighted if preceded by a '.'. */ - public final fun addMemberKeywordColor(memberKeyword: String, color: Color): Unit { + public final fun addMemberKeywordColor(memberKeyword: String, color: Color) { TransferContext.writeArguments(STRING to memberKeyword, COLOR to color) TransferContext.callMethod(ptr, MethodBindings.addMemberKeywordColorPtr, NIL) } @@ -299,7 +277,7 @@ public open class CodeHighlighter : SyntaxHighlighter() { /** * Removes the member keyword. */ - public final fun removeMemberKeywordColor(memberKeyword: String): Unit { + public final fun removeMemberKeywordColor(memberKeyword: String) { TransferContext.writeArguments(STRING to memberKeyword) TransferContext.callMethod(ptr, MethodBindings.removeMemberKeywordColorPtr, NIL) } @@ -322,7 +300,7 @@ public open class CodeHighlighter : SyntaxHighlighter() { return (TransferContext.readReturnValue(COLOR) as Color) } - public final fun setMemberKeywordColors(memberKeyword: Dictionary): Unit { + public final fun setMemberKeywordColors(memberKeyword: Dictionary) { TransferContext.writeArguments(DICTIONARY to memberKeyword) TransferContext.callMethod(ptr, MethodBindings.setMemberKeywordColorsPtr, NIL) } @@ -330,7 +308,7 @@ public open class CodeHighlighter : SyntaxHighlighter() { /** * Removes all member keywords. */ - public final fun clearMemberKeywordColors(): Unit { + public final fun clearMemberKeywordColors() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.clearMemberKeywordColorsPtr, NIL) } @@ -342,11 +320,9 @@ public open class CodeHighlighter : SyntaxHighlighter() { } /** - * Adds a color region (such as for comments or strings) from [startKey] to [endKey]. Both keys - * should be symbols, and [startKey] must not be shared with other delimiters. + * Adds a color region (such as for comments or strings) from [startKey] to [endKey]. Both keys should be symbols, and [startKey] must not be shared with other delimiters. * - * If [lineOnly] is `true` or [endKey] is an empty [String], the region does not carry over to the - * next line. + * If [lineOnly] is `true` or [endKey] is an empty [String], the region does not carry over to the next line. */ @JvmOverloads public final fun addColorRegion( @@ -354,7 +330,7 @@ public open class CodeHighlighter : SyntaxHighlighter() { endKey: String, color: Color, lineOnly: Boolean = false, - ): Unit { + ) { TransferContext.writeArguments(STRING to startKey, STRING to endKey, COLOR to color, BOOL to lineOnly) TransferContext.callMethod(ptr, MethodBindings.addColorRegionPtr, NIL) } @@ -362,7 +338,7 @@ public open class CodeHighlighter : SyntaxHighlighter() { /** * Removes the color region that uses that start key. */ - public final fun removeColorRegion(startKey: String): Unit { + public final fun removeColorRegion(startKey: String) { TransferContext.writeArguments(STRING to startKey) TransferContext.callMethod(ptr, MethodBindings.removeColorRegionPtr, NIL) } @@ -376,7 +352,7 @@ public open class CodeHighlighter : SyntaxHighlighter() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setColorRegions(colorRegions: Dictionary): Unit { + public final fun setColorRegions(colorRegions: Dictionary) { TransferContext.writeArguments(DICTIONARY to colorRegions) TransferContext.callMethod(ptr, MethodBindings.setColorRegionsPtr, NIL) } @@ -384,7 +360,7 @@ public open class CodeHighlighter : SyntaxHighlighter() { /** * Removes all color regions. */ - public final fun clearColorRegions(): Unit { + public final fun clearColorRegions() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.clearColorRegionsPtr, NIL) } @@ -395,7 +371,7 @@ public open class CodeHighlighter : SyntaxHighlighter() { return (TransferContext.readReturnValue(DICTIONARY) as Dictionary) } - public final fun setFunctionColor(color: Color): Unit { + public final fun setFunctionColor(color: Color) { TransferContext.writeArguments(COLOR to color) TransferContext.callMethod(ptr, MethodBindings.setFunctionColorPtr, NIL) } @@ -406,7 +382,7 @@ public open class CodeHighlighter : SyntaxHighlighter() { return (TransferContext.readReturnValue(COLOR) as Color) } - public final fun setNumberColor(color: Color): Unit { + public final fun setNumberColor(color: Color) { TransferContext.writeArguments(COLOR to color) TransferContext.callMethod(ptr, MethodBindings.setNumberColorPtr, NIL) } @@ -417,7 +393,7 @@ public open class CodeHighlighter : SyntaxHighlighter() { return (TransferContext.readReturnValue(COLOR) as Color) } - public final fun setSymbolColor(color: Color): Unit { + public final fun setSymbolColor(color: Color) { TransferContext.writeArguments(COLOR to color) TransferContext.callMethod(ptr, MethodBindings.setSymbolColorPtr, NIL) } @@ -428,7 +404,7 @@ public open class CodeHighlighter : SyntaxHighlighter() { return (TransferContext.readReturnValue(COLOR) as Color) } - public final fun setMemberVariableColor(color: Color): Unit { + public final fun setMemberVariableColor(color: Color) { TransferContext.writeArguments(COLOR to color) TransferContext.callMethod(ptr, MethodBindings.setMemberVariableColorPtr, NIL) } @@ -443,87 +419,87 @@ public open class CodeHighlighter : SyntaxHighlighter() { public object MethodBindings { internal val addKeywordColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeHighlighter", "add_keyword_color", 1636512886) + TypeManager.getMethodBindPtr("CodeHighlighter", "add_keyword_color", 1_636_512_886) internal val removeKeywordColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeHighlighter", "remove_keyword_color", 83702148) + TypeManager.getMethodBindPtr("CodeHighlighter", "remove_keyword_color", 83_702_148) internal val hasKeywordColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeHighlighter", "has_keyword_color", 3927539163) + TypeManager.getMethodBindPtr("CodeHighlighter", "has_keyword_color", 3_927_539_163) internal val getKeywordColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeHighlighter", "get_keyword_color", 3855908743) + TypeManager.getMethodBindPtr("CodeHighlighter", "get_keyword_color", 3_855_908_743) internal val setKeywordColorsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeHighlighter", "set_keyword_colors", 4155329257) + TypeManager.getMethodBindPtr("CodeHighlighter", "set_keyword_colors", 4_155_329_257) internal val clearKeywordColorsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeHighlighter", "clear_keyword_colors", 3218959716) + TypeManager.getMethodBindPtr("CodeHighlighter", "clear_keyword_colors", 3_218_959_716) internal val getKeywordColorsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeHighlighter", "get_keyword_colors", 3102165223) + TypeManager.getMethodBindPtr("CodeHighlighter", "get_keyword_colors", 3_102_165_223) internal val addMemberKeywordColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeHighlighter", "add_member_keyword_color", 1636512886) + TypeManager.getMethodBindPtr("CodeHighlighter", "add_member_keyword_color", 1_636_512_886) internal val removeMemberKeywordColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeHighlighter", "remove_member_keyword_color", 83702148) + TypeManager.getMethodBindPtr("CodeHighlighter", "remove_member_keyword_color", 83_702_148) internal val hasMemberKeywordColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeHighlighter", "has_member_keyword_color", 3927539163) + TypeManager.getMethodBindPtr("CodeHighlighter", "has_member_keyword_color", 3_927_539_163) internal val getMemberKeywordColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeHighlighter", "get_member_keyword_color", 3855908743) + TypeManager.getMethodBindPtr("CodeHighlighter", "get_member_keyword_color", 3_855_908_743) internal val setMemberKeywordColorsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeHighlighter", "set_member_keyword_colors", 4155329257) + TypeManager.getMethodBindPtr("CodeHighlighter", "set_member_keyword_colors", 4_155_329_257) internal val clearMemberKeywordColorsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeHighlighter", "clear_member_keyword_colors", 3218959716) + TypeManager.getMethodBindPtr("CodeHighlighter", "clear_member_keyword_colors", 3_218_959_716) internal val getMemberKeywordColorsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeHighlighter", "get_member_keyword_colors", 3102165223) + TypeManager.getMethodBindPtr("CodeHighlighter", "get_member_keyword_colors", 3_102_165_223) internal val addColorRegionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeHighlighter", "add_color_region", 2924977451) + TypeManager.getMethodBindPtr("CodeHighlighter", "add_color_region", 2_924_977_451) internal val removeColorRegionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeHighlighter", "remove_color_region", 83702148) + TypeManager.getMethodBindPtr("CodeHighlighter", "remove_color_region", 83_702_148) internal val hasColorRegionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeHighlighter", "has_color_region", 3927539163) + TypeManager.getMethodBindPtr("CodeHighlighter", "has_color_region", 3_927_539_163) internal val setColorRegionsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeHighlighter", "set_color_regions", 4155329257) + TypeManager.getMethodBindPtr("CodeHighlighter", "set_color_regions", 4_155_329_257) internal val clearColorRegionsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeHighlighter", "clear_color_regions", 3218959716) + TypeManager.getMethodBindPtr("CodeHighlighter", "clear_color_regions", 3_218_959_716) internal val getColorRegionsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeHighlighter", "get_color_regions", 3102165223) + TypeManager.getMethodBindPtr("CodeHighlighter", "get_color_regions", 3_102_165_223) internal val setFunctionColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeHighlighter", "set_function_color", 2920490490) + TypeManager.getMethodBindPtr("CodeHighlighter", "set_function_color", 2_920_490_490) internal val getFunctionColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeHighlighter", "get_function_color", 3444240500) + TypeManager.getMethodBindPtr("CodeHighlighter", "get_function_color", 3_444_240_500) internal val setNumberColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeHighlighter", "set_number_color", 2920490490) + TypeManager.getMethodBindPtr("CodeHighlighter", "set_number_color", 2_920_490_490) internal val getNumberColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeHighlighter", "get_number_color", 3444240500) + TypeManager.getMethodBindPtr("CodeHighlighter", "get_number_color", 3_444_240_500) internal val setSymbolColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeHighlighter", "set_symbol_color", 2920490490) + TypeManager.getMethodBindPtr("CodeHighlighter", "set_symbol_color", 2_920_490_490) internal val getSymbolColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeHighlighter", "get_symbol_color", 3444240500) + TypeManager.getMethodBindPtr("CodeHighlighter", "get_symbol_color", 3_444_240_500) internal val setMemberVariableColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeHighlighter", "set_member_variable_color", 2920490490) + TypeManager.getMethodBindPtr("CodeHighlighter", "set_member_variable_color", 2_920_490_490) internal val getMemberVariableColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CodeHighlighter", "get_member_variable_color", 3444240500) + TypeManager.getMethodBindPtr("CodeHighlighter", "get_member_variable_color", 3_444_240_500) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CollisionObject2D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CollisionObject2D.kt index 0cc4cd89fc..a5c2e72a14 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CollisionObject2D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CollisionObject2D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -31,67 +28,46 @@ import kotlin.Int import kotlin.Long import kotlin.NotImplementedError import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * Abstract base class for 2D physics objects. [CollisionObject2D] can hold any number of [Shape2D]s - * for collision. Each shape must be assigned to a *shape owner*. Shape owners are not nodes and do not - * appear in the editor, but are accessible through code using the `shape_owner_*` methods. + * Abstract base class for 2D physics objects. [CollisionObject2D] can hold any number of [Shape2D]s for collision. Each shape must be assigned to a *shape owner*. Shape owners are not nodes and do not appear in the editor, but are accessible through code using the `shape_owner_*` methods. * - * **Note:** Only collisions between objects within the same canvas ([Viewport] canvas or - * [CanvasLayer]) are supported. The behavior of collisions between objects in different canvases is - * undefined. + * **Note:** Only collisions between objects within the same canvas ([Viewport] canvas or [CanvasLayer]) are supported. The behavior of collisions between objects in different canvases is undefined. */ @GodotBaseType public open class CollisionObject2D internal constructor() : Node2D() { /** - * Emitted when an input event occurs. Requires [inputPickable] to be `true` and at least one - * [collisionLayer] bit to be set. See [_inputEvent] for details. + * Emitted when an input event occurs. Requires [inputPickable] to be `true` and at least one [collisionLayer] bit to be set. See [_inputEvent] for details. */ public val inputEvent: Signal3 by Signal3 /** - * Emitted when the mouse pointer enters any of this object's shapes. Requires [inputPickable] to - * be `true` and at least one [collisionLayer] bit to be set. Note that moving between different - * shapes within a single [CollisionObject2D] won't cause this signal to be emitted. + * Emitted when the mouse pointer enters any of this object's shapes. Requires [inputPickable] to be `true` and at least one [collisionLayer] bit to be set. Note that moving between different shapes within a single [CollisionObject2D] won't cause this signal to be emitted. * - * **Note:** Due to the lack of continuous collision detection, this signal may not be emitted in - * the expected order if the mouse moves fast enough and the [CollisionObject2D]'s area is small. - * This signal may also not be emitted if another [CollisionObject2D] is overlapping the - * [CollisionObject2D] in question. + * **Note:** Due to the lack of continuous collision detection, this signal may not be emitted in the expected order if the mouse moves fast enough and the [CollisionObject2D]'s area is small. This signal may also not be emitted if another [CollisionObject2D] is overlapping the [CollisionObject2D] in question. */ public val mouseEntered: Signal0 by Signal0 /** - * Emitted when the mouse pointer exits all this object's shapes. Requires [inputPickable] to be - * `true` and at least one [collisionLayer] bit to be set. Note that moving between different shapes - * within a single [CollisionObject2D] won't cause this signal to be emitted. + * Emitted when the mouse pointer exits all this object's shapes. Requires [inputPickable] to be `true` and at least one [collisionLayer] bit to be set. Note that moving between different shapes within a single [CollisionObject2D] won't cause this signal to be emitted. * - * **Note:** Due to the lack of continuous collision detection, this signal may not be emitted in - * the expected order if the mouse moves fast enough and the [CollisionObject2D]'s area is small. - * This signal may also not be emitted if another [CollisionObject2D] is overlapping the - * [CollisionObject2D] in question. + * **Note:** Due to the lack of continuous collision detection, this signal may not be emitted in the expected order if the mouse moves fast enough and the [CollisionObject2D]'s area is small. This signal may also not be emitted if another [CollisionObject2D] is overlapping the [CollisionObject2D] in question. */ public val mouseExited: Signal0 by Signal0 /** - * Emitted when the mouse pointer enters any of this object's shapes or moves from one shape to - * another. [shapeIdx] is the child index of the newly entered [Shape2D]. Requires [inputPickable] to - * be `true` and at least one [collisionLayer] bit to be set. + * Emitted when the mouse pointer enters any of this object's shapes or moves from one shape to another. [shapeIdx] is the child index of the newly entered [Shape2D]. Requires [inputPickable] to be `true` and at least one [collisionLayer] bit to be set. */ public val mouseShapeEntered: Signal1 by Signal1 /** - * Emitted when the mouse pointer exits any of this object's shapes. [shapeIdx] is the child index - * of the exited [Shape2D]. Requires [inputPickable] to be `true` and at least one [collisionLayer] - * bit to be set. + * Emitted when the mouse pointer exits any of this object's shapes. [shapeIdx] is the child index of the exited [Shape2D]. Requires [inputPickable] to be `true` and at least one [collisionLayer] bit to be set. */ public val mouseShapeExited: Signal1 by Signal1 /** - * Defines the behavior in physics when [Node.processMode] is set to [Node.PROCESS_MODE_DISABLED]. - * See [DisableMode] for more details about the different modes. + * Defines the behavior in physics when [Node.processMode] is set to [Node.PROCESS_MODE_DISABLED]. See [DisableMode] for more details about the different modes. */ public final inline var disableMode: DisableMode @JvmName("disableModeProperty") @@ -102,13 +78,9 @@ public open class CollisionObject2D internal constructor() : Node2D() { } /** - * The physics layers this CollisionObject2D is in. Collision objects can exist in one or more of - * 32 different layers. See also [collisionMask]. + * The physics layers this CollisionObject2D is in. Collision objects can exist in one or more of 32 different layers. See also [collisionMask]. * - * **Note:** Object A can detect a contact with object B only if object B is in any of the layers - * that object A scans. See - * [url=$DOCS_URL/tutorials/physics/physics_introduction.html#collision-layers-and-masks]Collision - * layers and masks[/url] in the documentation for more information. + * **Note:** Object A can detect a contact with object B only if object B is in any of the layers that object A scans. See [url=$DOCS_URL/tutorials/physics/physics_introduction.html#collision-layers-and-masks]Collision layers and masks[/url] in the documentation for more information. */ public final inline var collisionLayer: Long @JvmName("collisionLayerProperty") @@ -119,13 +91,9 @@ public open class CollisionObject2D internal constructor() : Node2D() { } /** - * The physics layers this CollisionObject2D scans. Collision objects can scan one or more of 32 - * different layers. See also [collisionLayer]. + * The physics layers this CollisionObject2D scans. Collision objects can scan one or more of 32 different layers. See also [collisionLayer]. * - * **Note:** Object A can detect a contact with object B only if object B is in any of the layers - * that object A scans. See - * [url=$DOCS_URL/tutorials/physics/physics_introduction.html#collision-layers-and-masks]Collision - * layers and masks[/url] in the documentation for more information. + * **Note:** Object A can detect a contact with object B only if object B is in any of the layers that object A scans. See [url=$DOCS_URL/tutorials/physics/physics_introduction.html#collision-layers-and-masks]Collision layers and masks[/url] in the documentation for more information. */ public final inline var collisionMask: Long @JvmName("collisionMaskProperty") @@ -136,9 +104,7 @@ public open class CollisionObject2D internal constructor() : Node2D() { } /** - * The priority used to solve colliding when occurring penetration. The higher the priority is, - * the lower the penetration into the object will be. This can for example be used to prevent the - * player from breaking through the boundaries of a level. + * The priority used to solve colliding when occurring penetration. The higher the priority is, the lower the penetration into the object will be. This can for example be used to prevent the player from breaking through the boundaries of a level. */ public final inline var collisionPriority: Float @JvmName("collisionPriorityProperty") @@ -149,9 +115,7 @@ public open class CollisionObject2D internal constructor() : Node2D() { } /** - * If `true`, this object is pickable. A pickable object can detect the mouse pointer - * entering/leaving, and if the mouse is inside it, report input events. Requires at least one - * [collisionLayer] bit to be set. + * If `true`, this object is pickable. A pickable object can detect the mouse pointer entering/leaving, and if the mouse is inside it, report input events. Requires at least one [collisionLayer] bit to be set. */ public final inline var inputPickable: Boolean @JvmName("inputPickableProperty") @@ -161,58 +125,48 @@ public open class CollisionObject2D internal constructor() : Node2D() { setPickable(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(154, scriptIndex) } /** - * Accepts unhandled [InputEvent]s. [shapeIdx] is the child index of the clicked [Shape2D]. - * Connect to [signal input_event] to easily pick up these events. + * Accepts unhandled [InputEvent]s. [shapeIdx] is the child index of the clicked [Shape2D]. Connect to [signal input_event] to easily pick up these events. * - * **Note:** [_inputEvent] requires [inputPickable] to be `true` and at least one [collisionLayer] - * bit to be set. + * **Note:** [_inputEvent] requires [inputPickable] to be `true` and at least one [collisionLayer] bit to be set. */ public open fun _inputEvent( viewport: Viewport?, event: InputEvent?, shapeIdx: Int, - ): Unit { + ) { throw NotImplementedError("CollisionObject2D::_inputEvent is not implemented.") } /** - * Called when the mouse pointer enters any of this object's shapes. Requires [inputPickable] to - * be `true` and at least one [collisionLayer] bit to be set. Note that moving between different - * shapes within a single [CollisionObject2D] won't cause this function to be called. + * Called when the mouse pointer enters any of this object's shapes. Requires [inputPickable] to be `true` and at least one [collisionLayer] bit to be set. Note that moving between different shapes within a single [CollisionObject2D] won't cause this function to be called. */ - public open fun _mouseEnter(): Unit { + public open fun _mouseEnter() { throw NotImplementedError("CollisionObject2D::_mouseEnter is not implemented.") } /** - * Called when the mouse pointer exits all this object's shapes. Requires [inputPickable] to be - * `true` and at least one [collisionLayer] bit to be set. Note that moving between different shapes - * within a single [CollisionObject2D] won't cause this function to be called. + * Called when the mouse pointer exits all this object's shapes. Requires [inputPickable] to be `true` and at least one [collisionLayer] bit to be set. Note that moving between different shapes within a single [CollisionObject2D] won't cause this function to be called. */ - public open fun _mouseExit(): Unit { + public open fun _mouseExit() { throw NotImplementedError("CollisionObject2D::_mouseExit is not implemented.") } /** - * Called when the mouse pointer enters any of this object's shapes or moves from one shape to - * another. [shapeIdx] is the child index of the newly entered [Shape2D]. Requires [inputPickable] to - * be `true` and at least one [collisionLayer] bit to be called. + * Called when the mouse pointer enters any of this object's shapes or moves from one shape to another. [shapeIdx] is the child index of the newly entered [Shape2D]. Requires [inputPickable] to be `true` and at least one [collisionLayer] bit to be called. */ - public open fun _mouseShapeEnter(shapeIdx: Int): Unit { + public open fun _mouseShapeEnter(shapeIdx: Int) { throw NotImplementedError("CollisionObject2D::_mouseShapeEnter is not implemented.") } /** - * Called when the mouse pointer exits any of this object's shapes. [shapeIdx] is the child index - * of the exited [Shape2D]. Requires [inputPickable] to be `true` and at least one [collisionLayer] - * bit to be called. + * Called when the mouse pointer exits any of this object's shapes. [shapeIdx] is the child index of the exited [Shape2D]. Requires [inputPickable] to be `true` and at least one [collisionLayer] bit to be called. */ - public open fun _mouseShapeExit(shapeIdx: Int): Unit { + public open fun _mouseShapeExit(shapeIdx: Int) { throw NotImplementedError("CollisionObject2D::_mouseShapeExit is not implemented.") } @@ -225,7 +179,7 @@ public open class CollisionObject2D internal constructor() : Node2D() { return (TransferContext.readReturnValue(_RID) as RID) } - public final fun setCollisionLayer(layer: Long): Unit { + public final fun setCollisionLayer(layer: Long) { TransferContext.writeArguments(LONG to layer) TransferContext.callMethod(ptr, MethodBindings.setCollisionLayerPtr, NIL) } @@ -236,7 +190,7 @@ public open class CollisionObject2D internal constructor() : Node2D() { return (TransferContext.readReturnValue(LONG) as Long) } - public final fun setCollisionMask(mask: Long): Unit { + public final fun setCollisionMask(mask: Long) { TransferContext.writeArguments(LONG to mask) TransferContext.callMethod(ptr, MethodBindings.setCollisionMaskPtr, NIL) } @@ -248,17 +202,15 @@ public open class CollisionObject2D internal constructor() : Node2D() { } /** - * Based on [value], enables or disables the specified layer in the [collisionLayer], given a - * [layerNumber] between 1 and 32. + * Based on [value], enables or disables the specified layer in the [collisionLayer], given a [layerNumber] between 1 and 32. */ - public final fun setCollisionLayerValue(layerNumber: Int, `value`: Boolean): Unit { + public final fun setCollisionLayerValue(layerNumber: Int, `value`: Boolean) { TransferContext.writeArguments(LONG to layerNumber.toLong(), BOOL to value) TransferContext.callMethod(ptr, MethodBindings.setCollisionLayerValuePtr, NIL) } /** - * Returns whether or not the specified layer of the [collisionLayer] is enabled, given a - * [layerNumber] between 1 and 32. + * Returns whether or not the specified layer of the [collisionLayer] is enabled, given a [layerNumber] between 1 and 32. */ public final fun getCollisionLayerValue(layerNumber: Int): Boolean { TransferContext.writeArguments(LONG to layerNumber.toLong()) @@ -267,17 +219,15 @@ public open class CollisionObject2D internal constructor() : Node2D() { } /** - * Based on [value], enables or disables the specified layer in the [collisionMask], given a - * [layerNumber] between 1 and 32. + * Based on [value], enables or disables the specified layer in the [collisionMask], given a [layerNumber] between 1 and 32. */ - public final fun setCollisionMaskValue(layerNumber: Int, `value`: Boolean): Unit { + public final fun setCollisionMaskValue(layerNumber: Int, `value`: Boolean) { TransferContext.writeArguments(LONG to layerNumber.toLong(), BOOL to value) TransferContext.callMethod(ptr, MethodBindings.setCollisionMaskValuePtr, NIL) } /** - * Returns whether or not the specified layer of the [collisionMask] is enabled, given a - * [layerNumber] between 1 and 32. + * Returns whether or not the specified layer of the [collisionMask] is enabled, given a [layerNumber] between 1 and 32. */ public final fun getCollisionMaskValue(layerNumber: Int): Boolean { TransferContext.writeArguments(LONG to layerNumber.toLong()) @@ -285,7 +235,7 @@ public open class CollisionObject2D internal constructor() : Node2D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setCollisionPriority(priority: Float): Unit { + public final fun setCollisionPriority(priority: Float) { TransferContext.writeArguments(DOUBLE to priority.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setCollisionPriorityPtr, NIL) } @@ -296,7 +246,7 @@ public open class CollisionObject2D internal constructor() : Node2D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setDisableMode(mode: DisableMode): Unit { + public final fun setDisableMode(mode: DisableMode) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setDisableModePtr, NIL) } @@ -307,7 +257,7 @@ public open class CollisionObject2D internal constructor() : Node2D() { return DisableMode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setPickable(enabled: Boolean): Unit { + public final fun setPickable(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setPickablePtr, NIL) } @@ -319,8 +269,7 @@ public open class CollisionObject2D internal constructor() : Node2D() { } /** - * Creates a new shape owner for the given object. Returns `owner_id` of the new owner for future - * reference. + * Creates a new shape owner for the given object. Returns `owner_id` of the new owner for future reference. */ public final fun createShapeOwner(owner: Object?): Long { TransferContext.writeArguments(OBJECT to owner) @@ -331,14 +280,13 @@ public open class CollisionObject2D internal constructor() : Node2D() { /** * Removes the given shape owner. */ - public final fun removeShapeOwner(ownerId: Long): Unit { + public final fun removeShapeOwner(ownerId: Long) { TransferContext.writeArguments(LONG to ownerId) TransferContext.callMethod(ptr, MethodBindings.removeShapeOwnerPtr, NIL) } /** - * Returns an [Array] of `owner_id` identifiers. You can use these ids in other methods that take - * `owner_id` as an argument. + * Returns an [Array] of `owner_id` identifiers. You can use these ids in other methods that take `owner_id` as an argument. */ public final fun getShapeOwners(): PackedInt32Array { TransferContext.writeArguments() @@ -349,7 +297,7 @@ public open class CollisionObject2D internal constructor() : Node2D() { /** * Sets the [Transform2D] of the given shape owner. */ - public final fun shapeOwnerSetTransform(ownerId: Long, transform: Transform2D): Unit { + public final fun shapeOwnerSetTransform(ownerId: Long, transform: Transform2D) { TransferContext.writeArguments(LONG to ownerId, TRANSFORM2D to transform) TransferContext.callMethod(ptr, MethodBindings.shapeOwnerSetTransformPtr, NIL) } @@ -375,7 +323,7 @@ public open class CollisionObject2D internal constructor() : Node2D() { /** * If `true`, disables the given shape owner. */ - public final fun shapeOwnerSetDisabled(ownerId: Long, disabled: Boolean): Unit { + public final fun shapeOwnerSetDisabled(ownerId: Long, disabled: Boolean) { TransferContext.writeArguments(LONG to ownerId, BOOL to disabled) TransferContext.callMethod(ptr, MethodBindings.shapeOwnerSetDisabledPtr, NIL) } @@ -390,17 +338,15 @@ public open class CollisionObject2D internal constructor() : Node2D() { } /** - * If [enable] is `true`, collisions for the shape owner originating from this [CollisionObject2D] - * will not be reported to collided with [CollisionObject2D]s. + * If [enable] is `true`, collisions for the shape owner originating from this [CollisionObject2D] will not be reported to collided with [CollisionObject2D]s. */ - public final fun shapeOwnerSetOneWayCollision(ownerId: Long, enable: Boolean): Unit { + public final fun shapeOwnerSetOneWayCollision(ownerId: Long, enable: Boolean) { TransferContext.writeArguments(LONG to ownerId, BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.shapeOwnerSetOneWayCollisionPtr, NIL) } /** - * Returns `true` if collisions for the shape owner originating from this [CollisionObject2D] will - * not be reported to collided with [CollisionObject2D]s. + * Returns `true` if collisions for the shape owner originating from this [CollisionObject2D] will not be reported to collided with [CollisionObject2D]s. */ public final fun isShapeOwnerOneWayCollisionEnabled(ownerId: Long): Boolean { TransferContext.writeArguments(LONG to ownerId) @@ -409,10 +355,9 @@ public open class CollisionObject2D internal constructor() : Node2D() { } /** - * Sets the `one_way_collision_margin` of the shape owner identified by given [ownerId] to - * [margin] pixels. + * Sets the `one_way_collision_margin` of the shape owner identified by given [ownerId] to [margin] pixels. */ - public final fun shapeOwnerSetOneWayCollisionMargin(ownerId: Long, margin: Float): Unit { + public final fun shapeOwnerSetOneWayCollisionMargin(ownerId: Long, margin: Float) { TransferContext.writeArguments(LONG to ownerId, DOUBLE to margin.toDouble()) TransferContext.callMethod(ptr, MethodBindings.shapeOwnerSetOneWayCollisionMarginPtr, NIL) } @@ -429,7 +374,7 @@ public open class CollisionObject2D internal constructor() : Node2D() { /** * Adds a [Shape2D] to the shape owner. */ - public final fun shapeOwnerAddShape(ownerId: Long, shape: Shape2D?): Unit { + public final fun shapeOwnerAddShape(ownerId: Long, shape: Shape2D?) { TransferContext.writeArguments(LONG to ownerId, OBJECT to shape) TransferContext.callMethod(ptr, MethodBindings.shapeOwnerAddShapePtr, NIL) } @@ -464,7 +409,7 @@ public open class CollisionObject2D internal constructor() : Node2D() { /** * Removes a shape from the given shape owner. */ - public final fun shapeOwnerRemoveShape(ownerId: Long, shapeId: Int): Unit { + public final fun shapeOwnerRemoveShape(ownerId: Long, shapeId: Int) { TransferContext.writeArguments(LONG to ownerId, LONG to shapeId.toLong()) TransferContext.callMethod(ptr, MethodBindings.shapeOwnerRemoveShapePtr, NIL) } @@ -472,7 +417,7 @@ public open class CollisionObject2D internal constructor() : Node2D() { /** * Removes all shapes from the shape owner. */ - public final fun shapeOwnerClearShapes(ownerId: Long): Unit { + public final fun shapeOwnerClearShapes(ownerId: Long) { TransferContext.writeArguments(LONG to ownerId) TransferContext.callMethod(ptr, MethodBindings.shapeOwnerClearShapesPtr, NIL) } @@ -490,23 +435,19 @@ public open class CollisionObject2D internal constructor() : Node2D() { id: Long, ) { /** - * When [Node.processMode] is set to [Node.PROCESS_MODE_DISABLED], remove from the physics - * simulation to stop all physics interactions with this [CollisionObject2D]. + * When [Node.processMode] is set to [Node.PROCESS_MODE_DISABLED], remove from the physics simulation to stop all physics interactions with this [CollisionObject2D]. * * Automatically re-added to the physics simulation when the [Node] is processed again. */ REMOVE(0), /** - * When [Node.processMode] is set to [Node.PROCESS_MODE_DISABLED], make the body static. Doesn't - * affect [Area2D]. [PhysicsBody2D] can't be affected by forces or other bodies while static. + * When [Node.processMode] is set to [Node.PROCESS_MODE_DISABLED], make the body static. Doesn't affect [Area2D]. [PhysicsBody2D] can't be affected by forces or other bodies while static. * - * Automatically set [PhysicsBody2D] back to its original mode when the [Node] is processed - * again. + * Automatically set [PhysicsBody2D] back to its original mode when the [Node] is processed again. */ MAKE_STATIC(1), /** - * When [Node.processMode] is set to [Node.PROCESS_MODE_DISABLED], do not affect the physics - * simulation. + * When [Node.processMode] is set to [Node.PROCESS_MODE_DISABLED], do not affect the physics simulation. */ KEEP_ACTIVE(2), ; @@ -525,105 +466,105 @@ public open class CollisionObject2D internal constructor() : Node2D() { public object MethodBindings { internal val getRidPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "get_rid", 2944877500) + TypeManager.getMethodBindPtr("CollisionObject2D", "get_rid", 2_944_877_500) internal val setCollisionLayerPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "set_collision_layer", 1286410249) + TypeManager.getMethodBindPtr("CollisionObject2D", "set_collision_layer", 1_286_410_249) internal val getCollisionLayerPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "get_collision_layer", 3905245786) + TypeManager.getMethodBindPtr("CollisionObject2D", "get_collision_layer", 3_905_245_786) internal val setCollisionMaskPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "set_collision_mask", 1286410249) + TypeManager.getMethodBindPtr("CollisionObject2D", "set_collision_mask", 1_286_410_249) internal val getCollisionMaskPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "get_collision_mask", 3905245786) + TypeManager.getMethodBindPtr("CollisionObject2D", "get_collision_mask", 3_905_245_786) internal val setCollisionLayerValuePtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "set_collision_layer_value", 300928843) + TypeManager.getMethodBindPtr("CollisionObject2D", "set_collision_layer_value", 300_928_843) internal val getCollisionLayerValuePtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "get_collision_layer_value", 1116898809) + TypeManager.getMethodBindPtr("CollisionObject2D", "get_collision_layer_value", 1_116_898_809) internal val setCollisionMaskValuePtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "set_collision_mask_value", 300928843) + TypeManager.getMethodBindPtr("CollisionObject2D", "set_collision_mask_value", 300_928_843) internal val getCollisionMaskValuePtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "get_collision_mask_value", 1116898809) + TypeManager.getMethodBindPtr("CollisionObject2D", "get_collision_mask_value", 1_116_898_809) internal val setCollisionPriorityPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "set_collision_priority", 373806689) + TypeManager.getMethodBindPtr("CollisionObject2D", "set_collision_priority", 373_806_689) internal val getCollisionPriorityPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "get_collision_priority", 1740695150) + TypeManager.getMethodBindPtr("CollisionObject2D", "get_collision_priority", 1_740_695_150) internal val setDisableModePtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "set_disable_mode", 1919204045) + TypeManager.getMethodBindPtr("CollisionObject2D", "set_disable_mode", 1_919_204_045) internal val getDisableModePtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "get_disable_mode", 3172846349) + TypeManager.getMethodBindPtr("CollisionObject2D", "get_disable_mode", 3_172_846_349) internal val setPickablePtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "set_pickable", 2586408642) + TypeManager.getMethodBindPtr("CollisionObject2D", "set_pickable", 2_586_408_642) internal val isPickablePtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "is_pickable", 36873697) + TypeManager.getMethodBindPtr("CollisionObject2D", "is_pickable", 36_873_697) internal val createShapeOwnerPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "create_shape_owner", 3429307534) + TypeManager.getMethodBindPtr("CollisionObject2D", "create_shape_owner", 3_429_307_534) internal val removeShapeOwnerPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "remove_shape_owner", 1286410249) + TypeManager.getMethodBindPtr("CollisionObject2D", "remove_shape_owner", 1_286_410_249) internal val getShapeOwnersPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "get_shape_owners", 969006518) + TypeManager.getMethodBindPtr("CollisionObject2D", "get_shape_owners", 969_006_518) internal val shapeOwnerSetTransformPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "shape_owner_set_transform", 30160968) + TypeManager.getMethodBindPtr("CollisionObject2D", "shape_owner_set_transform", 30_160_968) internal val shapeOwnerGetTransformPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "shape_owner_get_transform", 3836996910) + TypeManager.getMethodBindPtr("CollisionObject2D", "shape_owner_get_transform", 3_836_996_910) internal val shapeOwnerGetOwnerPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "shape_owner_get_owner", 3332903315) + TypeManager.getMethodBindPtr("CollisionObject2D", "shape_owner_get_owner", 3_332_903_315) internal val shapeOwnerSetDisabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "shape_owner_set_disabled", 300928843) + TypeManager.getMethodBindPtr("CollisionObject2D", "shape_owner_set_disabled", 300_928_843) internal val isShapeOwnerDisabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "is_shape_owner_disabled", 1116898809) + TypeManager.getMethodBindPtr("CollisionObject2D", "is_shape_owner_disabled", 1_116_898_809) internal val shapeOwnerSetOneWayCollisionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "shape_owner_set_one_way_collision", 300928843) + TypeManager.getMethodBindPtr("CollisionObject2D", "shape_owner_set_one_way_collision", 300_928_843) internal val isShapeOwnerOneWayCollisionEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "is_shape_owner_one_way_collision_enabled", 1116898809) + TypeManager.getMethodBindPtr("CollisionObject2D", "is_shape_owner_one_way_collision_enabled", 1_116_898_809) internal val shapeOwnerSetOneWayCollisionMarginPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "shape_owner_set_one_way_collision_margin", 1602489585) + TypeManager.getMethodBindPtr("CollisionObject2D", "shape_owner_set_one_way_collision_margin", 1_602_489_585) internal val getShapeOwnerOneWayCollisionMarginPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "get_shape_owner_one_way_collision_margin", 2339986948) + TypeManager.getMethodBindPtr("CollisionObject2D", "get_shape_owner_one_way_collision_margin", 2_339_986_948) internal val shapeOwnerAddShapePtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "shape_owner_add_shape", 2077425081) + TypeManager.getMethodBindPtr("CollisionObject2D", "shape_owner_add_shape", 2_077_425_081) internal val shapeOwnerGetShapeCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "shape_owner_get_shape_count", 923996154) + TypeManager.getMethodBindPtr("CollisionObject2D", "shape_owner_get_shape_count", 923_996_154) internal val shapeOwnerGetShapePtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "shape_owner_get_shape", 3106725749) + TypeManager.getMethodBindPtr("CollisionObject2D", "shape_owner_get_shape", 3_106_725_749) internal val shapeOwnerGetShapeIndexPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "shape_owner_get_shape_index", 3175239445) + TypeManager.getMethodBindPtr("CollisionObject2D", "shape_owner_get_shape_index", 3_175_239_445) internal val shapeOwnerRemoveShapePtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "shape_owner_remove_shape", 3937882851) + TypeManager.getMethodBindPtr("CollisionObject2D", "shape_owner_remove_shape", 3_937_882_851) internal val shapeOwnerClearShapesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "shape_owner_clear_shapes", 1286410249) + TypeManager.getMethodBindPtr("CollisionObject2D", "shape_owner_clear_shapes", 1_286_410_249) internal val shapeFindOwnerPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject2D", "shape_find_owner", 923996154) + TypeManager.getMethodBindPtr("CollisionObject2D", "shape_find_owner", 923_996_154) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CollisionObject3D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CollisionObject3D.kt index e1c0067bc9..7074c8703b 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CollisionObject3D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CollisionObject3D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -31,51 +28,36 @@ import kotlin.Int import kotlin.Long import kotlin.NotImplementedError import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * Abstract base class for 3D physics objects. [CollisionObject3D] can hold any number of [Shape3D]s - * for collision. Each shape must be assigned to a *shape owner*. Shape owners are not nodes and do not - * appear in the editor, but are accessible through code using the `shape_owner_*` methods. + * Abstract base class for 3D physics objects. [CollisionObject3D] can hold any number of [Shape3D]s for collision. Each shape must be assigned to a *shape owner*. Shape owners are not nodes and do not appear in the editor, but are accessible through code using the `shape_owner_*` methods. * - * **Warning:** With a non-uniform scale, this node will likely not behave as expected. It is - * advised to keep its scale the same on all axes and adjust its collision shape(s) instead. + * **Warning:** With a non-uniform scale, this node will likely not behave as expected. It is advised to keep its scale the same on all axes and adjust its collision shape(s) instead. */ @GodotBaseType public open class CollisionObject3D internal constructor() : Node3D() { /** - * Emitted when the object receives an unhandled [InputEvent]. [eventPosition] is the location in - * world space of the mouse pointer on the surface of the shape with index [shapeIdx] and [normal] is - * the normal vector of the surface at that point. + * Emitted when the object receives an unhandled [InputEvent]. [eventPosition] is the location in world space of the mouse pointer on the surface of the shape with index [shapeIdx] and [normal] is the normal vector of the surface at that point. */ public val inputEvent: Signal5 by Signal5 /** - * Emitted when the mouse pointer enters any of this object's shapes. Requires [inputRayPickable] - * to be `true` and at least one [collisionLayer] bit to be set. + * Emitted when the mouse pointer enters any of this object's shapes. Requires [inputRayPickable] to be `true` and at least one [collisionLayer] bit to be set. * - * **Note:** Due to the lack of continuous collision detection, this signal may not be emitted in - * the expected order if the mouse moves fast enough and the [CollisionObject3D]'s area is small. - * This signal may also not be emitted if another [CollisionObject3D] is overlapping the - * [CollisionObject3D] in question. + * **Note:** Due to the lack of continuous collision detection, this signal may not be emitted in the expected order if the mouse moves fast enough and the [CollisionObject3D]'s area is small. This signal may also not be emitted if another [CollisionObject3D] is overlapping the [CollisionObject3D] in question. */ public val mouseEntered: Signal0 by Signal0 /** - * Emitted when the mouse pointer exits all this object's shapes. Requires [inputRayPickable] to - * be `true` and at least one [collisionLayer] bit to be set. + * Emitted when the mouse pointer exits all this object's shapes. Requires [inputRayPickable] to be `true` and at least one [collisionLayer] bit to be set. * - * **Note:** Due to the lack of continuous collision detection, this signal may not be emitted in - * the expected order if the mouse moves fast enough and the [CollisionObject3D]'s area is small. - * This signal may also not be emitted if another [CollisionObject3D] is overlapping the - * [CollisionObject3D] in question. + * **Note:** Due to the lack of continuous collision detection, this signal may not be emitted in the expected order if the mouse moves fast enough and the [CollisionObject3D]'s area is small. This signal may also not be emitted if another [CollisionObject3D] is overlapping the [CollisionObject3D] in question. */ public val mouseExited: Signal0 by Signal0 /** - * Defines the behavior in physics when [Node.processMode] is set to [Node.PROCESS_MODE_DISABLED]. - * See [DisableMode] for more details about the different modes. + * Defines the behavior in physics when [Node.processMode] is set to [Node.PROCESS_MODE_DISABLED]. See [DisableMode] for more details about the different modes. */ public final inline var disableMode: DisableMode @JvmName("disableModeProperty") @@ -86,13 +68,9 @@ public open class CollisionObject3D internal constructor() : Node3D() { } /** - * The physics layers this CollisionObject3D **is in**. Collision objects can exist in one or more - * of 32 different layers. See also [collisionMask]. + * The physics layers this CollisionObject3D **is in**. Collision objects can exist in one or more of 32 different layers. See also [collisionMask]. * - * **Note:** Object A can detect a contact with object B only if object B is in any of the layers - * that object A scans. See - * [url=$DOCS_URL/tutorials/physics/physics_introduction.html#collision-layers-and-masks]Collision - * layers and masks[/url] in the documentation for more information. + * **Note:** Object A can detect a contact with object B only if object B is in any of the layers that object A scans. See [url=$DOCS_URL/tutorials/physics/physics_introduction.html#collision-layers-and-masks]Collision layers and masks[/url] in the documentation for more information. */ public final inline var collisionLayer: Long @JvmName("collisionLayerProperty") @@ -103,13 +81,9 @@ public open class CollisionObject3D internal constructor() : Node3D() { } /** - * The physics layers this CollisionObject3D **scans**. Collision objects can scan one or more of - * 32 different layers. See also [collisionLayer]. + * The physics layers this CollisionObject3D **scans**. Collision objects can scan one or more of 32 different layers. See also [collisionLayer]. * - * **Note:** Object A can detect a contact with object B only if object B is in any of the layers - * that object A scans. See - * [url=$DOCS_URL/tutorials/physics/physics_introduction.html#collision-layers-and-masks]Collision - * layers and masks[/url] in the documentation for more information. + * **Note:** Object A can detect a contact with object B only if object B is in any of the layers that object A scans. See [url=$DOCS_URL/tutorials/physics/physics_introduction.html#collision-layers-and-masks]Collision layers and masks[/url] in the documentation for more information. */ public final inline var collisionMask: Long @JvmName("collisionMaskProperty") @@ -120,9 +94,7 @@ public open class CollisionObject3D internal constructor() : Node3D() { } /** - * The priority used to solve colliding when occurring penetration. The higher the priority is, - * the lower the penetration into the object will be. This can for example be used to prevent the - * player from breaking through the boundaries of a level. + * The priority used to solve colliding when occurring penetration. The higher the priority is, the lower the penetration into the object will be. This can for example be used to prevent the player from breaking through the boundaries of a level. */ public final inline var collisionPriority: Float @JvmName("collisionPriorityProperty") @@ -133,9 +105,7 @@ public open class CollisionObject3D internal constructor() : Node3D() { } /** - * If `true`, this object is pickable. A pickable object can detect the mouse pointer - * entering/leaving, and if the mouse is inside it, report input events. Requires at least one - * [collisionLayer] bit to be set. + * If `true`, this object is pickable. A pickable object can detect the mouse pointer entering/leaving, and if the mouse is inside it, report input events. Requires at least one [collisionLayer] bit to be set. */ public final inline var inputRayPickable: Boolean @JvmName("inputRayPickableProperty") @@ -146,8 +116,7 @@ public open class CollisionObject3D internal constructor() : Node3D() { } /** - * If `true`, the [CollisionObject3D] will continue to receive input events as the mouse is - * dragged across its shapes. + * If `true`, the [CollisionObject3D] will continue to receive input events as the mouse is dragged across its shapes. */ public final inline var inputCaptureOnDrag: Boolean @JvmName("inputCaptureOnDragProperty") @@ -157,17 +126,14 @@ public open class CollisionObject3D internal constructor() : Node3D() { setCaptureInputOnDrag(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(155, scriptIndex) } /** - * Receives unhandled [InputEvent]s. [eventPosition] is the location in world space of the mouse - * pointer on the surface of the shape with index [shapeIdx] and [normal] is the normal vector of the - * surface at that point. Connect to the [signal input_event] signal to easily pick up these events. + * Receives unhandled [InputEvent]s. [eventPosition] is the location in world space of the mouse pointer on the surface of the shape with index [shapeIdx] and [normal] is the normal vector of the surface at that point. Connect to the [signal input_event] signal to easily pick up these events. * - * **Note:** [_inputEvent] requires [inputRayPickable] to be `true` and at least one - * [collisionLayer] bit to be set. + * **Note:** [_inputEvent] requires [inputRayPickable] to be `true` and at least one [collisionLayer] bit to be set. */ public open fun _inputEvent( camera: Camera3D?, @@ -175,29 +141,25 @@ public open class CollisionObject3D internal constructor() : Node3D() { eventPosition: Vector3, normal: Vector3, shapeIdx: Int, - ): Unit { + ) { throw NotImplementedError("CollisionObject3D::_inputEvent is not implemented.") } /** - * Called when the mouse pointer enters any of this object's shapes. Requires [inputRayPickable] - * to be `true` and at least one [collisionLayer] bit to be set. Note that moving between different - * shapes within a single [CollisionObject3D] won't cause this function to be called. + * Called when the mouse pointer enters any of this object's shapes. Requires [inputRayPickable] to be `true` and at least one [collisionLayer] bit to be set. Note that moving between different shapes within a single [CollisionObject3D] won't cause this function to be called. */ - public open fun _mouseEnter(): Unit { + public open fun _mouseEnter() { throw NotImplementedError("CollisionObject3D::_mouseEnter is not implemented.") } /** - * Called when the mouse pointer exits all this object's shapes. Requires [inputRayPickable] to be - * `true` and at least one [collisionLayer] bit to be set. Note that moving between different shapes - * within a single [CollisionObject3D] won't cause this function to be called. + * Called when the mouse pointer exits all this object's shapes. Requires [inputRayPickable] to be `true` and at least one [collisionLayer] bit to be set. Note that moving between different shapes within a single [CollisionObject3D] won't cause this function to be called. */ - public open fun _mouseExit(): Unit { + public open fun _mouseExit() { throw NotImplementedError("CollisionObject3D::_mouseExit is not implemented.") } - public final fun setCollisionLayer(layer: Long): Unit { + public final fun setCollisionLayer(layer: Long) { TransferContext.writeArguments(LONG to layer) TransferContext.callMethod(ptr, MethodBindings.setCollisionLayerPtr, NIL) } @@ -208,7 +170,7 @@ public open class CollisionObject3D internal constructor() : Node3D() { return (TransferContext.readReturnValue(LONG) as Long) } - public final fun setCollisionMask(mask: Long): Unit { + public final fun setCollisionMask(mask: Long) { TransferContext.writeArguments(LONG to mask) TransferContext.callMethod(ptr, MethodBindings.setCollisionMaskPtr, NIL) } @@ -220,17 +182,15 @@ public open class CollisionObject3D internal constructor() : Node3D() { } /** - * Based on [value], enables or disables the specified layer in the [collisionLayer], given a - * [layerNumber] between 1 and 32. + * Based on [value], enables or disables the specified layer in the [collisionLayer], given a [layerNumber] between 1 and 32. */ - public final fun setCollisionLayerValue(layerNumber: Int, `value`: Boolean): Unit { + public final fun setCollisionLayerValue(layerNumber: Int, `value`: Boolean) { TransferContext.writeArguments(LONG to layerNumber.toLong(), BOOL to value) TransferContext.callMethod(ptr, MethodBindings.setCollisionLayerValuePtr, NIL) } /** - * Returns whether or not the specified layer of the [collisionLayer] is enabled, given a - * [layerNumber] between 1 and 32. + * Returns whether or not the specified layer of the [collisionLayer] is enabled, given a [layerNumber] between 1 and 32. */ public final fun getCollisionLayerValue(layerNumber: Int): Boolean { TransferContext.writeArguments(LONG to layerNumber.toLong()) @@ -239,17 +199,15 @@ public open class CollisionObject3D internal constructor() : Node3D() { } /** - * Based on [value], enables or disables the specified layer in the [collisionMask], given a - * [layerNumber] between 1 and 32. + * Based on [value], enables or disables the specified layer in the [collisionMask], given a [layerNumber] between 1 and 32. */ - public final fun setCollisionMaskValue(layerNumber: Int, `value`: Boolean): Unit { + public final fun setCollisionMaskValue(layerNumber: Int, `value`: Boolean) { TransferContext.writeArguments(LONG to layerNumber.toLong(), BOOL to value) TransferContext.callMethod(ptr, MethodBindings.setCollisionMaskValuePtr, NIL) } /** - * Returns whether or not the specified layer of the [collisionMask] is enabled, given a - * [layerNumber] between 1 and 32. + * Returns whether or not the specified layer of the [collisionMask] is enabled, given a [layerNumber] between 1 and 32. */ public final fun getCollisionMaskValue(layerNumber: Int): Boolean { TransferContext.writeArguments(LONG to layerNumber.toLong()) @@ -257,7 +215,7 @@ public open class CollisionObject3D internal constructor() : Node3D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setCollisionPriority(priority: Float): Unit { + public final fun setCollisionPriority(priority: Float) { TransferContext.writeArguments(DOUBLE to priority.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setCollisionPriorityPtr, NIL) } @@ -268,7 +226,7 @@ public open class CollisionObject3D internal constructor() : Node3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setDisableMode(mode: DisableMode): Unit { + public final fun setDisableMode(mode: DisableMode) { TransferContext.writeArguments(LONG to mode.id) TransferContext.callMethod(ptr, MethodBindings.setDisableModePtr, NIL) } @@ -279,7 +237,7 @@ public open class CollisionObject3D internal constructor() : Node3D() { return DisableMode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setRayPickable(rayPickable: Boolean): Unit { + public final fun setRayPickable(rayPickable: Boolean) { TransferContext.writeArguments(BOOL to rayPickable) TransferContext.callMethod(ptr, MethodBindings.setRayPickablePtr, NIL) } @@ -290,7 +248,7 @@ public open class CollisionObject3D internal constructor() : Node3D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setCaptureInputOnDrag(enable: Boolean): Unit { + public final fun setCaptureInputOnDrag(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setCaptureInputOnDragPtr, NIL) } @@ -311,8 +269,7 @@ public open class CollisionObject3D internal constructor() : Node3D() { } /** - * Creates a new shape owner for the given object. Returns `owner_id` of the new owner for future - * reference. + * Creates a new shape owner for the given object. Returns `owner_id` of the new owner for future reference. */ public final fun createShapeOwner(owner: Object?): Long { TransferContext.writeArguments(OBJECT to owner) @@ -323,14 +280,13 @@ public open class CollisionObject3D internal constructor() : Node3D() { /** * Removes the given shape owner. */ - public final fun removeShapeOwner(ownerId: Long): Unit { + public final fun removeShapeOwner(ownerId: Long) { TransferContext.writeArguments(LONG to ownerId) TransferContext.callMethod(ptr, MethodBindings.removeShapeOwnerPtr, NIL) } /** - * Returns an [Array] of `owner_id` identifiers. You can use these ids in other methods that take - * `owner_id` as an argument. + * Returns an [Array] of `owner_id` identifiers. You can use these ids in other methods that take `owner_id` as an argument. */ public final fun getShapeOwners(): PackedInt32Array { TransferContext.writeArguments() @@ -341,7 +297,7 @@ public open class CollisionObject3D internal constructor() : Node3D() { /** * Sets the [Transform3D] of the given shape owner. */ - public final fun shapeOwnerSetTransform(ownerId: Long, transform: Transform3D): Unit { + public final fun shapeOwnerSetTransform(ownerId: Long, transform: Transform3D) { TransferContext.writeArguments(LONG to ownerId, TRANSFORM3D to transform) TransferContext.callMethod(ptr, MethodBindings.shapeOwnerSetTransformPtr, NIL) } @@ -367,7 +323,7 @@ public open class CollisionObject3D internal constructor() : Node3D() { /** * If `true`, disables the given shape owner. */ - public final fun shapeOwnerSetDisabled(ownerId: Long, disabled: Boolean): Unit { + public final fun shapeOwnerSetDisabled(ownerId: Long, disabled: Boolean) { TransferContext.writeArguments(LONG to ownerId, BOOL to disabled) TransferContext.callMethod(ptr, MethodBindings.shapeOwnerSetDisabledPtr, NIL) } @@ -384,7 +340,7 @@ public open class CollisionObject3D internal constructor() : Node3D() { /** * Adds a [Shape3D] to the shape owner. */ - public final fun shapeOwnerAddShape(ownerId: Long, shape: Shape3D?): Unit { + public final fun shapeOwnerAddShape(ownerId: Long, shape: Shape3D?) { TransferContext.writeArguments(LONG to ownerId, OBJECT to shape) TransferContext.callMethod(ptr, MethodBindings.shapeOwnerAddShapePtr, NIL) } @@ -419,7 +375,7 @@ public open class CollisionObject3D internal constructor() : Node3D() { /** * Removes a shape from the given shape owner. */ - public final fun shapeOwnerRemoveShape(ownerId: Long, shapeId: Int): Unit { + public final fun shapeOwnerRemoveShape(ownerId: Long, shapeId: Int) { TransferContext.writeArguments(LONG to ownerId, LONG to shapeId.toLong()) TransferContext.callMethod(ptr, MethodBindings.shapeOwnerRemoveShapePtr, NIL) } @@ -427,7 +383,7 @@ public open class CollisionObject3D internal constructor() : Node3D() { /** * Removes all shapes from the shape owner. */ - public final fun shapeOwnerClearShapes(ownerId: Long): Unit { + public final fun shapeOwnerClearShapes(ownerId: Long) { TransferContext.writeArguments(LONG to ownerId) TransferContext.callMethod(ptr, MethodBindings.shapeOwnerClearShapesPtr, NIL) } @@ -445,23 +401,19 @@ public open class CollisionObject3D internal constructor() : Node3D() { id: Long, ) { /** - * When [Node.processMode] is set to [Node.PROCESS_MODE_DISABLED], remove from the physics - * simulation to stop all physics interactions with this [CollisionObject3D]. + * When [Node.processMode] is set to [Node.PROCESS_MODE_DISABLED], remove from the physics simulation to stop all physics interactions with this [CollisionObject3D]. * * Automatically re-added to the physics simulation when the [Node] is processed again. */ REMOVE(0), /** - * When [Node.processMode] is set to [Node.PROCESS_MODE_DISABLED], make the body static. Doesn't - * affect [Area3D]. [PhysicsBody3D] can't be affected by forces or other bodies while static. + * When [Node.processMode] is set to [Node.PROCESS_MODE_DISABLED], make the body static. Doesn't affect [Area3D]. [PhysicsBody3D] can't be affected by forces or other bodies while static. * - * Automatically set [PhysicsBody3D] back to its original mode when the [Node] is processed - * again. + * Automatically set [PhysicsBody3D] back to its original mode when the [Node] is processed again. */ MAKE_STATIC(1), /** - * When [Node.processMode] is set to [Node.PROCESS_MODE_DISABLED], do not affect the physics - * simulation. + * When [Node.processMode] is set to [Node.PROCESS_MODE_DISABLED], do not affect the physics simulation. */ KEEP_ACTIVE(2), ; @@ -480,99 +432,99 @@ public open class CollisionObject3D internal constructor() : Node3D() { public object MethodBindings { internal val setCollisionLayerPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject3D", "set_collision_layer", 1286410249) + TypeManager.getMethodBindPtr("CollisionObject3D", "set_collision_layer", 1_286_410_249) internal val getCollisionLayerPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject3D", "get_collision_layer", 3905245786) + TypeManager.getMethodBindPtr("CollisionObject3D", "get_collision_layer", 3_905_245_786) internal val setCollisionMaskPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject3D", "set_collision_mask", 1286410249) + TypeManager.getMethodBindPtr("CollisionObject3D", "set_collision_mask", 1_286_410_249) internal val getCollisionMaskPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject3D", "get_collision_mask", 3905245786) + TypeManager.getMethodBindPtr("CollisionObject3D", "get_collision_mask", 3_905_245_786) internal val setCollisionLayerValuePtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject3D", "set_collision_layer_value", 300928843) + TypeManager.getMethodBindPtr("CollisionObject3D", "set_collision_layer_value", 300_928_843) internal val getCollisionLayerValuePtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject3D", "get_collision_layer_value", 1116898809) + TypeManager.getMethodBindPtr("CollisionObject3D", "get_collision_layer_value", 1_116_898_809) internal val setCollisionMaskValuePtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject3D", "set_collision_mask_value", 300928843) + TypeManager.getMethodBindPtr("CollisionObject3D", "set_collision_mask_value", 300_928_843) internal val getCollisionMaskValuePtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject3D", "get_collision_mask_value", 1116898809) + TypeManager.getMethodBindPtr("CollisionObject3D", "get_collision_mask_value", 1_116_898_809) internal val setCollisionPriorityPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject3D", "set_collision_priority", 373806689) + TypeManager.getMethodBindPtr("CollisionObject3D", "set_collision_priority", 373_806_689) internal val getCollisionPriorityPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject3D", "get_collision_priority", 1740695150) + TypeManager.getMethodBindPtr("CollisionObject3D", "get_collision_priority", 1_740_695_150) internal val setDisableModePtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject3D", "set_disable_mode", 1623620376) + TypeManager.getMethodBindPtr("CollisionObject3D", "set_disable_mode", 1_623_620_376) internal val getDisableModePtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject3D", "get_disable_mode", 410164780) + TypeManager.getMethodBindPtr("CollisionObject3D", "get_disable_mode", 410_164_780) internal val setRayPickablePtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject3D", "set_ray_pickable", 2586408642) + TypeManager.getMethodBindPtr("CollisionObject3D", "set_ray_pickable", 2_586_408_642) internal val isRayPickablePtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject3D", "is_ray_pickable", 36873697) + TypeManager.getMethodBindPtr("CollisionObject3D", "is_ray_pickable", 36_873_697) internal val setCaptureInputOnDragPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject3D", "set_capture_input_on_drag", 2586408642) + TypeManager.getMethodBindPtr("CollisionObject3D", "set_capture_input_on_drag", 2_586_408_642) internal val getCaptureInputOnDragPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject3D", "get_capture_input_on_drag", 36873697) + TypeManager.getMethodBindPtr("CollisionObject3D", "get_capture_input_on_drag", 36_873_697) internal val getRidPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject3D", "get_rid", 2944877500) + TypeManager.getMethodBindPtr("CollisionObject3D", "get_rid", 2_944_877_500) internal val createShapeOwnerPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject3D", "create_shape_owner", 3429307534) + TypeManager.getMethodBindPtr("CollisionObject3D", "create_shape_owner", 3_429_307_534) internal val removeShapeOwnerPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject3D", "remove_shape_owner", 1286410249) + TypeManager.getMethodBindPtr("CollisionObject3D", "remove_shape_owner", 1_286_410_249) internal val getShapeOwnersPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject3D", "get_shape_owners", 969006518) + TypeManager.getMethodBindPtr("CollisionObject3D", "get_shape_owners", 969_006_518) internal val shapeOwnerSetTransformPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject3D", "shape_owner_set_transform", 3616898986) + TypeManager.getMethodBindPtr("CollisionObject3D", "shape_owner_set_transform", 3_616_898_986) internal val shapeOwnerGetTransformPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject3D", "shape_owner_get_transform", 1965739696) + TypeManager.getMethodBindPtr("CollisionObject3D", "shape_owner_get_transform", 1_965_739_696) internal val shapeOwnerGetOwnerPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject3D", "shape_owner_get_owner", 3332903315) + TypeManager.getMethodBindPtr("CollisionObject3D", "shape_owner_get_owner", 3_332_903_315) internal val shapeOwnerSetDisabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject3D", "shape_owner_set_disabled", 300928843) + TypeManager.getMethodBindPtr("CollisionObject3D", "shape_owner_set_disabled", 300_928_843) internal val isShapeOwnerDisabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject3D", "is_shape_owner_disabled", 1116898809) + TypeManager.getMethodBindPtr("CollisionObject3D", "is_shape_owner_disabled", 1_116_898_809) internal val shapeOwnerAddShapePtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject3D", "shape_owner_add_shape", 2566676345) + TypeManager.getMethodBindPtr("CollisionObject3D", "shape_owner_add_shape", 2_566_676_345) internal val shapeOwnerGetShapeCountPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject3D", "shape_owner_get_shape_count", 923996154) + TypeManager.getMethodBindPtr("CollisionObject3D", "shape_owner_get_shape_count", 923_996_154) internal val shapeOwnerGetShapePtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject3D", "shape_owner_get_shape", 4015519174) + TypeManager.getMethodBindPtr("CollisionObject3D", "shape_owner_get_shape", 4_015_519_174) internal val shapeOwnerGetShapeIndexPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject3D", "shape_owner_get_shape_index", 3175239445) + TypeManager.getMethodBindPtr("CollisionObject3D", "shape_owner_get_shape_index", 3_175_239_445) internal val shapeOwnerRemoveShapePtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject3D", "shape_owner_remove_shape", 3937882851) + TypeManager.getMethodBindPtr("CollisionObject3D", "shape_owner_remove_shape", 3_937_882_851) internal val shapeOwnerClearShapesPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject3D", "shape_owner_clear_shapes", 1286410249) + TypeManager.getMethodBindPtr("CollisionObject3D", "shape_owner_clear_shapes", 1_286_410_249) internal val shapeFindOwnerPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionObject3D", "shape_find_owner", 923996154) + TypeManager.getMethodBindPtr("CollisionObject3D", "shape_find_owner", 923_996_154) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CollisionPolygon2D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CollisionPolygon2D.kt index 09067b4d5b..4d147799c6 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CollisionPolygon2D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CollisionPolygon2D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -29,12 +26,9 @@ import kotlin.Unit import kotlin.jvm.JvmName /** - * A node that provides a polygon shape to a [CollisionObject2D] parent and allows to edit it. The - * polygon can be concave or convex. This can give a detection shape to an [Area2D], turn - * [PhysicsBody2D] into a solid object, or give a hollow shape to a [StaticBody2D]. + * A node that provides a polygon shape to a [CollisionObject2D] parent and allows to edit it. The polygon can be concave or convex. This can give a detection shape to an [Area2D], turn [PhysicsBody2D] into a solid object, or give a hollow shape to a [StaticBody2D]. * - * **Warning:** A non-uniformly scaled [CollisionPolygon2D] will likely not behave as expected. Make - * sure to keep its scale the same on all axes and adjust its polygon instead. + * **Warning:** A non-uniformly scaled [CollisionPolygon2D] will likely not behave as expected. Make sure to keep its scale the same on all axes and adjust its polygon instead. */ @GodotBaseType public open class CollisionPolygon2D : Node2D() { @@ -50,18 +44,13 @@ public open class CollisionPolygon2D : Node2D() { } /** - * The polygon's list of vertices. Each point will be connected to the next, and the final point - * will be connected to the first. + * The polygon's list of vertices. Each point will be connected to the next, and the final point will be connected to the first. * - * **Note:** The returned vertices are in the local coordinate space of the given - * [CollisionPolygon2D]. + * **Note:** The returned vertices are in the local coordinate space of the given [CollisionPolygon2D]. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var polygon: PackedVector2Array @@ -84,11 +73,9 @@ public open class CollisionPolygon2D : Node2D() { } /** - * If `true`, only edges that face up, relative to [CollisionPolygon2D]'s rotation, will collide - * with other objects. + * If `true`, only edges that face up, relative to [CollisionPolygon2D]'s rotation, will collide with other objects. * - * **Note:** This property has no effect if this [CollisionPolygon2D] is a child of an [Area2D] - * node. + * **Note:** This property has no effect if this [CollisionPolygon2D] is a child of an [Area2D] node. */ public final inline var oneWayCollision: Boolean @JvmName("oneWayCollisionProperty") @@ -99,8 +86,7 @@ public open class CollisionPolygon2D : Node2D() { } /** - * The margin used for one-way collision (in pixels). Higher values will make the shape thicker, - * and work better for colliders that enter the polygon at a high velocity. + * The margin used for one-way collision (in pixels). Higher values will make the shape thicker, and work better for colliders that enter the polygon at a high velocity. */ public final inline var oneWayCollisionMargin: Float @JvmName("oneWayCollisionMarginProperty") @@ -110,7 +96,7 @@ public open class CollisionPolygon2D : Node2D() { setOneWayCollisionMargin(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(156, scriptIndex) } @@ -125,33 +111,26 @@ public open class CollisionPolygon2D : Node2D() { * collisionpolygon2d.polygon = myCoreType * `````` * - * The polygon's list of vertices. Each point will be connected to the next, and the final point - * will be connected to the first. + * The polygon's list of vertices. Each point will be connected to the next, and the final point will be connected to the first. * - * **Note:** The returned vertices are in the local coordinate space of the given - * [CollisionPolygon2D]. + * **Note:** The returned vertices are in the local coordinate space of the given [CollisionPolygon2D]. */ @CoreTypeHelper - public final fun polygonMutate(block: PackedVector2Array.() -> Unit): PackedVector2Array = - polygon.apply { + public final fun polygonMutate(block: PackedVector2Array.() -> Unit): PackedVector2Array = polygon.apply { block(this) polygon = this } /** * This is a helper function for [polygon] to make dealing with local copies easier. - * Allow to directly modify each element of the local copy of the property and assign it back to - * the Object. + * Allow to directly modify each element of the local copy of the property and assign it back to the Object. * - * The polygon's list of vertices. Each point will be connected to the next, and the final point - * will be connected to the first. + * The polygon's list of vertices. Each point will be connected to the next, and the final point will be connected to the first. * - * **Note:** The returned vertices are in the local coordinate space of the given - * [CollisionPolygon2D]. + * **Note:** The returned vertices are in the local coordinate space of the given [CollisionPolygon2D]. */ @CoreTypeHelper - public final fun polygonMutateEach(block: (index: Int, `value`: Vector2) -> Unit): - PackedVector2Array = polygon.apply { + public final fun polygonMutateEach(block: (index: Int, `value`: Vector2) -> Unit): PackedVector2Array = polygon.apply { this.forEachIndexed { index, value -> block(index, value) this[index] = value @@ -159,7 +138,7 @@ public open class CollisionPolygon2D : Node2D() { polygon = this } - public final fun setPolygon(polygon: PackedVector2Array): Unit { + public final fun setPolygon(polygon: PackedVector2Array) { TransferContext.writeArguments(PACKED_VECTOR2_ARRAY to polygon) TransferContext.callMethod(ptr, MethodBindings.setPolygonPtr, NIL) } @@ -170,7 +149,7 @@ public open class CollisionPolygon2D : Node2D() { return (TransferContext.readReturnValue(PACKED_VECTOR2_ARRAY) as PackedVector2Array) } - public final fun setBuildMode(buildMode: BuildMode): Unit { + public final fun setBuildMode(buildMode: BuildMode) { TransferContext.writeArguments(LONG to buildMode.id) TransferContext.callMethod(ptr, MethodBindings.setBuildModePtr, NIL) } @@ -181,7 +160,7 @@ public open class CollisionPolygon2D : Node2D() { return BuildMode.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setDisabled(disabled: Boolean): Unit { + public final fun setDisabled(disabled: Boolean) { TransferContext.writeArguments(BOOL to disabled) TransferContext.callMethod(ptr, MethodBindings.setDisabledPtr, NIL) } @@ -192,7 +171,7 @@ public open class CollisionPolygon2D : Node2D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setOneWayCollision(enabled: Boolean): Unit { + public final fun setOneWayCollision(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setOneWayCollisionPtr, NIL) } @@ -203,7 +182,7 @@ public open class CollisionPolygon2D : Node2D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setOneWayCollisionMargin(margin: Float): Unit { + public final fun setOneWayCollisionMargin(margin: Float) { TransferContext.writeArguments(DOUBLE to margin.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setOneWayCollisionMarginPtr, NIL) } @@ -218,16 +197,11 @@ public open class CollisionPolygon2D : Node2D() { id: Long, ) { /** - * Collisions will include the polygon and its contained area. In this mode the node has the - * same effect as several [ConvexPolygonShape2D] nodes, one for each convex shape in the convex - * decomposition of the polygon (but without the overhead of multiple nodes). + * Collisions will include the polygon and its contained area. In this mode the node has the same effect as several [ConvexPolygonShape2D] nodes, one for each convex shape in the convex decomposition of the polygon (but without the overhead of multiple nodes). */ SOLIDS(0), /** - * Collisions will only include the polygon edges. In this mode the node has the same effect as - * a single [ConcavePolygonShape2D] made of segments, with the restriction that each segment (after - * the first one) starts where the previous one ends, and the last one ends where the first one - * starts (forming a closed but hollow polygon). + * Collisions will only include the polygon edges. In this mode the node has the same effect as a single [ConcavePolygonShape2D] made of segments, with the restriction that each segment (after the first one) starts where the previous one ends, and the last one ends where the first one starts (forming a closed but hollow polygon). */ SEGMENTS(1), ; @@ -246,33 +220,33 @@ public open class CollisionPolygon2D : Node2D() { public object MethodBindings { internal val setPolygonPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionPolygon2D", "set_polygon", 1509147220) + TypeManager.getMethodBindPtr("CollisionPolygon2D", "set_polygon", 1_509_147_220) internal val getPolygonPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionPolygon2D", "get_polygon", 2961356807) + TypeManager.getMethodBindPtr("CollisionPolygon2D", "get_polygon", 2_961_356_807) internal val setBuildModePtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionPolygon2D", "set_build_mode", 2780803135) + TypeManager.getMethodBindPtr("CollisionPolygon2D", "set_build_mode", 2_780_803_135) internal val getBuildModePtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionPolygon2D", "get_build_mode", 3044948800) + TypeManager.getMethodBindPtr("CollisionPolygon2D", "get_build_mode", 3_044_948_800) internal val setDisabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionPolygon2D", "set_disabled", 2586408642) + TypeManager.getMethodBindPtr("CollisionPolygon2D", "set_disabled", 2_586_408_642) internal val isDisabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionPolygon2D", "is_disabled", 36873697) + TypeManager.getMethodBindPtr("CollisionPolygon2D", "is_disabled", 36_873_697) internal val setOneWayCollisionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionPolygon2D", "set_one_way_collision", 2586408642) + TypeManager.getMethodBindPtr("CollisionPolygon2D", "set_one_way_collision", 2_586_408_642) internal val isOneWayCollisionEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionPolygon2D", "is_one_way_collision_enabled", 36873697) + TypeManager.getMethodBindPtr("CollisionPolygon2D", "is_one_way_collision_enabled", 36_873_697) internal val setOneWayCollisionMarginPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionPolygon2D", "set_one_way_collision_margin", 373806689) + TypeManager.getMethodBindPtr("CollisionPolygon2D", "set_one_way_collision_margin", 373_806_689) internal val getOneWayCollisionMarginPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionPolygon2D", "get_one_way_collision_margin", 1740695150) + TypeManager.getMethodBindPtr("CollisionPolygon2D", "get_one_way_collision_margin", 1_740_695_150) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CollisionPolygon3D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CollisionPolygon3D.kt index 9af77654bf..23ce93dc8f 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CollisionPolygon3D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CollisionPolygon3D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -29,18 +26,14 @@ import kotlin.Unit import kotlin.jvm.JvmName /** - * A node that provides a thickened polygon shape (a prism) to a [CollisionObject3D] parent and - * allows to edit it. The polygon can be concave or convex. This can give a detection shape to an - * [Area3D] or turn [PhysicsBody3D] into a solid object. + * A node that provides a thickened polygon shape (a prism) to a [CollisionObject3D] parent and allows to edit it. The polygon can be concave or convex. This can give a detection shape to an [Area3D] or turn [PhysicsBody3D] into a solid object. * - * **Warning:** A non-uniformly scaled [CollisionShape3D] will likely not behave as expected. Make - * sure to keep its scale the same on all axes and adjust its shape resource instead. + * **Warning:** A non-uniformly scaled [CollisionShape3D] will likely not behave as expected. Make sure to keep its scale the same on all axes and adjust its shape resource instead. */ @GodotBaseType public open class CollisionPolygon3D : Node3D() { /** - * Length that the resulting collision extends in either direction perpendicular to its 2D - * polygon. + * Length that the resulting collision extends in either direction perpendicular to its 2D polygon. */ public final inline var depth: Float @JvmName("depthProperty") @@ -65,11 +58,8 @@ public open class CollisionPolygon3D : Node3D() { * Array of vertices which define the 2D polygon in the local XY plane. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var polygon: PackedVector2Array @@ -92,19 +82,13 @@ public open class CollisionPolygon3D : Node3D() { } /** - * The collision shape color that is displayed in the editor, or in the running project if **Debug - * > Visible Collision Shapes** is checked at the top of the editor. + * The collision shape color that is displayed in the editor, or in the running project if **Debug > Visible Collision Shapes** is checked at the top of the editor. * - * **Note:** The default value is [ProjectSettings.debug/shapes/collision/shapeColor]. The - * `Color(0, 0, 0, 0)` value documented here is a placeholder, and not the actual default debug - * color. + * **Note:** The default value is [ProjectSettings.debug/shapes/collision/shapeColor]. The `Color(0, 0, 0, 0)` value documented here is a placeholder, and not the actual default debug color. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var debugColor: Color @@ -116,8 +100,7 @@ public open class CollisionPolygon3D : Node3D() { } /** - * If `true`, when the shape is displayed, it will show a solid fill color in addition to its - * wireframe. + * If `true`, when the shape is displayed, it will show a solid fill color in addition to its wireframe. */ public final inline var debugFill: Boolean @JvmName("debugFillProperty") @@ -127,7 +110,7 @@ public open class CollisionPolygon3D : Node3D() { setEnableDebugFill(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(157, scriptIndex) } @@ -145,22 +128,19 @@ public open class CollisionPolygon3D : Node3D() { * Array of vertices which define the 2D polygon in the local XY plane. */ @CoreTypeHelper - public final fun polygonMutate(block: PackedVector2Array.() -> Unit): PackedVector2Array = - polygon.apply { + public final fun polygonMutate(block: PackedVector2Array.() -> Unit): PackedVector2Array = polygon.apply { block(this) polygon = this } /** * This is a helper function for [polygon] to make dealing with local copies easier. - * Allow to directly modify each element of the local copy of the property and assign it back to - * the Object. + * Allow to directly modify each element of the local copy of the property and assign it back to the Object. * * Array of vertices which define the 2D polygon in the local XY plane. */ @CoreTypeHelper - public final fun polygonMutateEach(block: (index: Int, `value`: Vector2) -> Unit): - PackedVector2Array = polygon.apply { + public final fun polygonMutateEach(block: (index: Int, `value`: Vector2) -> Unit): PackedVector2Array = polygon.apply { this.forEachIndexed { index, value -> block(index, value) this[index] = value @@ -179,12 +159,9 @@ public open class CollisionPolygon3D : Node3D() { * collisionpolygon3d.debugColor = myCoreType * `````` * - * The collision shape color that is displayed in the editor, or in the running project if **Debug - * > Visible Collision Shapes** is checked at the top of the editor. + * The collision shape color that is displayed in the editor, or in the running project if **Debug > Visible Collision Shapes** is checked at the top of the editor. * - * **Note:** The default value is [ProjectSettings.debug/shapes/collision/shapeColor]. The - * `Color(0, 0, 0, 0)` value documented here is a placeholder, and not the actual default debug - * color. + * **Note:** The default value is [ProjectSettings.debug/shapes/collision/shapeColor]. The `Color(0, 0, 0, 0)` value documented here is a placeholder, and not the actual default debug color. */ @CoreTypeHelper public final fun debugColorMutate(block: Color.() -> Unit): Color = debugColor.apply { @@ -192,7 +169,7 @@ public open class CollisionPolygon3D : Node3D() { debugColor = this } - public final fun setDepth(depth: Float): Unit { + public final fun setDepth(depth: Float) { TransferContext.writeArguments(DOUBLE to depth.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setDepthPtr, NIL) } @@ -203,7 +180,7 @@ public open class CollisionPolygon3D : Node3D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setPolygon(polygon: PackedVector2Array): Unit { + public final fun setPolygon(polygon: PackedVector2Array) { TransferContext.writeArguments(PACKED_VECTOR2_ARRAY to polygon) TransferContext.callMethod(ptr, MethodBindings.setPolygonPtr, NIL) } @@ -214,7 +191,7 @@ public open class CollisionPolygon3D : Node3D() { return (TransferContext.readReturnValue(PACKED_VECTOR2_ARRAY) as PackedVector2Array) } - public final fun setDisabled(disabled: Boolean): Unit { + public final fun setDisabled(disabled: Boolean) { TransferContext.writeArguments(BOOL to disabled) TransferContext.callMethod(ptr, MethodBindings.setDisabledPtr, NIL) } @@ -225,7 +202,7 @@ public open class CollisionPolygon3D : Node3D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setDebugColor(color: Color): Unit { + public final fun setDebugColor(color: Color) { TransferContext.writeArguments(COLOR to color) TransferContext.callMethod(ptr, MethodBindings.setDebugColorPtr, NIL) } @@ -236,7 +213,7 @@ public open class CollisionPolygon3D : Node3D() { return (TransferContext.readReturnValue(COLOR) as Color) } - public final fun setEnableDebugFill(enable: Boolean): Unit { + public final fun setEnableDebugFill(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setEnableDebugFillPtr, NIL) } @@ -247,7 +224,7 @@ public open class CollisionPolygon3D : Node3D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setMargin(margin: Float): Unit { + public final fun setMargin(margin: Float) { TransferContext.writeArguments(DOUBLE to margin.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setMarginPtr, NIL) } @@ -262,39 +239,39 @@ public open class CollisionPolygon3D : Node3D() { public object MethodBindings { internal val setDepthPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionPolygon3D", "set_depth", 373806689) + TypeManager.getMethodBindPtr("CollisionPolygon3D", "set_depth", 373_806_689) internal val getDepthPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionPolygon3D", "get_depth", 1740695150) + TypeManager.getMethodBindPtr("CollisionPolygon3D", "get_depth", 1_740_695_150) internal val setPolygonPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionPolygon3D", "set_polygon", 1509147220) + TypeManager.getMethodBindPtr("CollisionPolygon3D", "set_polygon", 1_509_147_220) internal val getPolygonPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionPolygon3D", "get_polygon", 2961356807) + TypeManager.getMethodBindPtr("CollisionPolygon3D", "get_polygon", 2_961_356_807) internal val setDisabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionPolygon3D", "set_disabled", 2586408642) + TypeManager.getMethodBindPtr("CollisionPolygon3D", "set_disabled", 2_586_408_642) internal val isDisabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionPolygon3D", "is_disabled", 36873697) + TypeManager.getMethodBindPtr("CollisionPolygon3D", "is_disabled", 36_873_697) internal val setDebugColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionPolygon3D", "set_debug_color", 2920490490) + TypeManager.getMethodBindPtr("CollisionPolygon3D", "set_debug_color", 2_920_490_490) internal val getDebugColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionPolygon3D", "get_debug_color", 3444240500) + TypeManager.getMethodBindPtr("CollisionPolygon3D", "get_debug_color", 3_444_240_500) internal val setEnableDebugFillPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionPolygon3D", "set_enable_debug_fill", 2586408642) + TypeManager.getMethodBindPtr("CollisionPolygon3D", "set_enable_debug_fill", 2_586_408_642) internal val getEnableDebugFillPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionPolygon3D", "get_enable_debug_fill", 36873697) + TypeManager.getMethodBindPtr("CollisionPolygon3D", "get_enable_debug_fill", 36_873_697) internal val setMarginPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionPolygon3D", "set_margin", 373806689) + TypeManager.getMethodBindPtr("CollisionPolygon3D", "set_margin", 373_806_689) internal val getMarginPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionPolygon3D", "get_margin", 1740695150) + TypeManager.getMethodBindPtr("CollisionPolygon3D", "get_margin", 1_740_695_150) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CollisionShape2D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CollisionShape2D.kt index ab873d7615..fd69487053 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CollisionShape2D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CollisionShape2D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -27,8 +24,7 @@ import kotlin.Unit import kotlin.jvm.JvmName /** - * A node that provides a [Shape2D] to a [CollisionObject2D] parent and allows to edit it. This can - * give a detection shape to an [Area2D] or turn a [PhysicsBody2D] into a solid object. + * A node that provides a [Shape2D] to a [CollisionObject2D] parent and allows to edit it. This can give a detection shape to an [Area2D] or turn a [PhysicsBody2D] into a solid object. */ @GodotBaseType public open class CollisionShape2D : Node2D() { @@ -44,8 +40,7 @@ public open class CollisionShape2D : Node2D() { } /** - * A disabled collision shape has no effect in the world. This property should be changed with - * [Object.setDeferred]. + * A disabled collision shape has no effect in the world. This property should be changed with [Object.setDeferred]. */ public final inline var disabled: Boolean @JvmName("disabledProperty") @@ -58,8 +53,7 @@ public open class CollisionShape2D : Node2D() { /** * Sets whether this collision shape should only detect collision on one side (top or bottom). * - * **Note:** This property has no effect if this [CollisionShape2D] is a child of an [Area2D] - * node. + * **Note:** This property has no effect if this [CollisionShape2D] is a child of an [Area2D] node. */ public final inline var oneWayCollision: Boolean @JvmName("oneWayCollisionProperty") @@ -70,8 +64,7 @@ public open class CollisionShape2D : Node2D() { } /** - * The margin used for one-way collision (in pixels). Higher values will make the shape thicker, - * and work better for colliders that enter the shape at a high velocity. + * The margin used for one-way collision (in pixels). Higher values will make the shape thicker, and work better for colliders that enter the shape at a high velocity. */ public final inline var oneWayCollisionMargin: Float @JvmName("oneWayCollisionMarginProperty") @@ -82,19 +75,13 @@ public open class CollisionShape2D : Node2D() { } /** - * The collision shape color that is displayed in the editor, or in the running project if **Debug - * > Visible Collision Shapes** is checked at the top of the editor. + * The collision shape color that is displayed in the editor, or in the running project if **Debug > Visible Collision Shapes** is checked at the top of the editor. * - * **Note:** The default value is [ProjectSettings.debug/shapes/collision/shapeColor]. The - * `Color(0, 0, 0, 0)` value documented here is a placeholder, and not the actual default debug - * color. + * **Note:** The default value is [ProjectSettings.debug/shapes/collision/shapeColor]. The `Color(0, 0, 0, 0)` value documented here is a placeholder, and not the actual default debug color. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var debugColor: Color @@ -105,7 +92,7 @@ public open class CollisionShape2D : Node2D() { setDebugColor(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(158, scriptIndex) } @@ -120,12 +107,9 @@ public open class CollisionShape2D : Node2D() { * collisionshape2d.debugColor = myCoreType * `````` * - * The collision shape color that is displayed in the editor, or in the running project if **Debug - * > Visible Collision Shapes** is checked at the top of the editor. + * The collision shape color that is displayed in the editor, or in the running project if **Debug > Visible Collision Shapes** is checked at the top of the editor. * - * **Note:** The default value is [ProjectSettings.debug/shapes/collision/shapeColor]. The - * `Color(0, 0, 0, 0)` value documented here is a placeholder, and not the actual default debug - * color. + * **Note:** The default value is [ProjectSettings.debug/shapes/collision/shapeColor]. The `Color(0, 0, 0, 0)` value documented here is a placeholder, and not the actual default debug color. */ @CoreTypeHelper public final fun debugColorMutate(block: Color.() -> Unit): Color = debugColor.apply { @@ -133,7 +117,7 @@ public open class CollisionShape2D : Node2D() { debugColor = this } - public final fun setShape(shape: Shape2D?): Unit { + public final fun setShape(shape: Shape2D?) { TransferContext.writeArguments(OBJECT to shape) TransferContext.callMethod(ptr, MethodBindings.setShapePtr, NIL) } @@ -144,7 +128,7 @@ public open class CollisionShape2D : Node2D() { return (TransferContext.readReturnValue(OBJECT) as Shape2D?) } - public final fun setDisabled(disabled: Boolean): Unit { + public final fun setDisabled(disabled: Boolean) { TransferContext.writeArguments(BOOL to disabled) TransferContext.callMethod(ptr, MethodBindings.setDisabledPtr, NIL) } @@ -155,7 +139,7 @@ public open class CollisionShape2D : Node2D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setOneWayCollision(enabled: Boolean): Unit { + public final fun setOneWayCollision(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setOneWayCollisionPtr, NIL) } @@ -166,7 +150,7 @@ public open class CollisionShape2D : Node2D() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setOneWayCollisionMargin(margin: Float): Unit { + public final fun setOneWayCollisionMargin(margin: Float) { TransferContext.writeArguments(DOUBLE to margin.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setOneWayCollisionMarginPtr, NIL) } @@ -177,7 +161,7 @@ public open class CollisionShape2D : Node2D() { return (TransferContext.readReturnValue(DOUBLE) as Double).toFloat() } - public final fun setDebugColor(color: Color): Unit { + public final fun setDebugColor(color: Color) { TransferContext.writeArguments(COLOR to color) TransferContext.callMethod(ptr, MethodBindings.setDebugColorPtr, NIL) } @@ -192,33 +176,33 @@ public open class CollisionShape2D : Node2D() { public object MethodBindings { internal val setShapePtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionShape2D", "set_shape", 771364740) + TypeManager.getMethodBindPtr("CollisionShape2D", "set_shape", 771_364_740) internal val getShapePtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionShape2D", "get_shape", 522005891) + TypeManager.getMethodBindPtr("CollisionShape2D", "get_shape", 522_005_891) internal val setDisabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionShape2D", "set_disabled", 2586408642) + TypeManager.getMethodBindPtr("CollisionShape2D", "set_disabled", 2_586_408_642) internal val isDisabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionShape2D", "is_disabled", 36873697) + TypeManager.getMethodBindPtr("CollisionShape2D", "is_disabled", 36_873_697) internal val setOneWayCollisionPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionShape2D", "set_one_way_collision", 2586408642) + TypeManager.getMethodBindPtr("CollisionShape2D", "set_one_way_collision", 2_586_408_642) internal val isOneWayCollisionEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionShape2D", "is_one_way_collision_enabled", 36873697) + TypeManager.getMethodBindPtr("CollisionShape2D", "is_one_way_collision_enabled", 36_873_697) internal val setOneWayCollisionMarginPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionShape2D", "set_one_way_collision_margin", 373806689) + TypeManager.getMethodBindPtr("CollisionShape2D", "set_one_way_collision_margin", 373_806_689) internal val getOneWayCollisionMarginPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionShape2D", "get_one_way_collision_margin", 1740695150) + TypeManager.getMethodBindPtr("CollisionShape2D", "get_one_way_collision_margin", 1_740_695_150) internal val setDebugColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionShape2D", "set_debug_color", 2920490490) + TypeManager.getMethodBindPtr("CollisionShape2D", "set_debug_color", 2_920_490_490) internal val getDebugColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionShape2D", "get_debug_color", 3444240500) + TypeManager.getMethodBindPtr("CollisionShape2D", "get_debug_color", 3_444_240_500) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CollisionShape3D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CollisionShape3D.kt index c5f345e820..094eb53965 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CollisionShape3D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CollisionShape3D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -24,11 +21,9 @@ import kotlin.Unit import kotlin.jvm.JvmName /** - * A node that provides a [Shape3D] to a [CollisionObject3D] parent and allows to edit it. This can - * give a detection shape to an [Area3D] or turn a [PhysicsBody3D] into a solid object. + * A node that provides a [Shape3D] to a [CollisionObject3D] parent and allows to edit it. This can give a detection shape to an [Area3D] or turn a [PhysicsBody3D] into a solid object. * - * **Warning:** A non-uniformly scaled [CollisionShape3D] will likely not behave as expected. Make - * sure to keep its scale the same on all axes and adjust its [shape] resource instead. + * **Warning:** A non-uniformly scaled [CollisionShape3D] will likely not behave as expected. Make sure to keep its scale the same on all axes and adjust its [shape] resource instead. */ @GodotBaseType public open class CollisionShape3D : Node3D() { @@ -55,19 +50,13 @@ public open class CollisionShape3D : Node3D() { } /** - * The collision shape color that is displayed in the editor, or in the running project if **Debug - * > Visible Collision Shapes** is checked at the top of the editor. + * The collision shape color that is displayed in the editor, or in the running project if **Debug > Visible Collision Shapes** is checked at the top of the editor. * - * **Note:** The default value is [ProjectSettings.debug/shapes/collision/shapeColor]. The - * `Color(0, 0, 0, 0)` value documented here is a placeholder, and not the actual default debug - * color. + * **Note:** The default value is [ProjectSettings.debug/shapes/collision/shapeColor]. The `Color(0, 0, 0, 0)` value documented here is a placeholder, and not the actual default debug color. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var debugColor: Color @@ -79,8 +68,7 @@ public open class CollisionShape3D : Node3D() { } /** - * If `true`, when the shape is displayed, it will show a solid fill color in addition to its - * wireframe. + * If `true`, when the shape is displayed, it will show a solid fill color in addition to its wireframe. */ public final inline var debugFill: Boolean @JvmName("debugFillProperty") @@ -90,7 +78,7 @@ public open class CollisionShape3D : Node3D() { setEnableDebugFill(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(159, scriptIndex) } @@ -105,12 +93,9 @@ public open class CollisionShape3D : Node3D() { * collisionshape3d.debugColor = myCoreType * `````` * - * The collision shape color that is displayed in the editor, or in the running project if **Debug - * > Visible Collision Shapes** is checked at the top of the editor. + * The collision shape color that is displayed in the editor, or in the running project if **Debug > Visible Collision Shapes** is checked at the top of the editor. * - * **Note:** The default value is [ProjectSettings.debug/shapes/collision/shapeColor]. The - * `Color(0, 0, 0, 0)` value documented here is a placeholder, and not the actual default debug - * color. + * **Note:** The default value is [ProjectSettings.debug/shapes/collision/shapeColor]. The `Color(0, 0, 0, 0)` value documented here is a placeholder, and not the actual default debug color. */ @CoreTypeHelper public final fun debugColorMutate(block: Color.() -> Unit): Color = debugColor.apply { @@ -121,12 +106,12 @@ public open class CollisionShape3D : Node3D() { /** * This method does nothing. */ - public final fun resourceChanged(resource: Resource?): Unit { + public final fun resourceChanged(resource: Resource?) { TransferContext.writeArguments(OBJECT to resource) TransferContext.callMethod(ptr, MethodBindings.resourceChangedPtr, NIL) } - public final fun setShape(shape: Shape3D?): Unit { + public final fun setShape(shape: Shape3D?) { TransferContext.writeArguments(OBJECT to shape) TransferContext.callMethod(ptr, MethodBindings.setShapePtr, NIL) } @@ -137,7 +122,7 @@ public open class CollisionShape3D : Node3D() { return (TransferContext.readReturnValue(OBJECT) as Shape3D?) } - public final fun setDisabled(enable: Boolean): Unit { + public final fun setDisabled(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setDisabledPtr, NIL) } @@ -149,15 +134,14 @@ public open class CollisionShape3D : Node3D() { } /** - * Sets the collision shape's shape to the addition of all its convexed [MeshInstance3D] siblings - * geometry. + * Sets the collision shape's shape to the addition of all its convexed [MeshInstance3D] siblings geometry. */ - public final fun makeConvexFromSiblings(): Unit { + public final fun makeConvexFromSiblings() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.makeConvexFromSiblingsPtr, NIL) } - public final fun setDebugColor(color: Color): Unit { + public final fun setDebugColor(color: Color) { TransferContext.writeArguments(COLOR to color) TransferContext.callMethod(ptr, MethodBindings.setDebugColorPtr, NIL) } @@ -168,7 +152,7 @@ public open class CollisionShape3D : Node3D() { return (TransferContext.readReturnValue(COLOR) as Color) } - public final fun setEnableDebugFill(enable: Boolean): Unit { + public final fun setEnableDebugFill(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setEnableDebugFillPtr, NIL) } @@ -183,33 +167,33 @@ public open class CollisionShape3D : Node3D() { public object MethodBindings { internal val resourceChangedPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionShape3D", "resource_changed", 968641751) + TypeManager.getMethodBindPtr("CollisionShape3D", "resource_changed", 968_641_751) internal val setShapePtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionShape3D", "set_shape", 1549710052) + TypeManager.getMethodBindPtr("CollisionShape3D", "set_shape", 1_549_710_052) internal val getShapePtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionShape3D", "get_shape", 3214262478) + TypeManager.getMethodBindPtr("CollisionShape3D", "get_shape", 3_214_262_478) internal val setDisabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionShape3D", "set_disabled", 2586408642) + TypeManager.getMethodBindPtr("CollisionShape3D", "set_disabled", 2_586_408_642) internal val isDisabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionShape3D", "is_disabled", 36873697) + TypeManager.getMethodBindPtr("CollisionShape3D", "is_disabled", 36_873_697) internal val makeConvexFromSiblingsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionShape3D", "make_convex_from_siblings", 3218959716) + TypeManager.getMethodBindPtr("CollisionShape3D", "make_convex_from_siblings", 3_218_959_716) internal val setDebugColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionShape3D", "set_debug_color", 2920490490) + TypeManager.getMethodBindPtr("CollisionShape3D", "set_debug_color", 2_920_490_490) internal val getDebugColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionShape3D", "get_debug_color", 3444240500) + TypeManager.getMethodBindPtr("CollisionShape3D", "get_debug_color", 3_444_240_500) internal val setEnableDebugFillPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionShape3D", "set_enable_debug_fill", 2586408642) + TypeManager.getMethodBindPtr("CollisionShape3D", "set_enable_debug_fill", 2_586_408_642) internal val getEnableDebugFillPtr: VoidPtr = - TypeManager.getMethodBindPtr("CollisionShape3D", "get_enable_debug_fill", 36873697) + TypeManager.getMethodBindPtr("CollisionShape3D", "get_enable_debug_fill", 36_873_697) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ColorPalette.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ColorPalette.kt index 06e605abb6..ae5faab021 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ColorPalette.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ColorPalette.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -15,14 +12,10 @@ import godot.core.VariantParser.NIL import godot.core.VariantParser.PACKED_COLOR_ARRAY import kotlin.Int import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * The [ColorPalette] resource is designed to store and manage a collection of colors. This resource - * is useful in scenarios where a predefined set of colors is required, such as for creating themes, - * designing user interfaces, or managing game assets. The built-in [ColorPicker] control can also make - * use of [ColorPalette] without additional code. + * The [ColorPalette] resource is designed to store and manage a collection of colors. This resource is useful in scenarios where a predefined set of colors is required, such as for creating themes, designing user interfaces, or managing game assets. The built-in [ColorPicker] control can also make use of [ColorPalette] without additional code. */ @GodotBaseType public open class ColorPalette : Resource() { @@ -37,11 +30,11 @@ public open class ColorPalette : Resource() { setColors(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(160, scriptIndex) } - public final fun setColors(colors: PackedColorArray): Unit { + public final fun setColors(colors: PackedColorArray) { TransferContext.writeArguments(PACKED_COLOR_ARRAY to colors) TransferContext.callMethod(ptr, MethodBindings.setColorsPtr, NIL) } @@ -56,9 +49,9 @@ public open class ColorPalette : Resource() { public object MethodBindings { internal val setColorsPtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPalette", "set_colors", 3546319833) + TypeManager.getMethodBindPtr("ColorPalette", "set_colors", 3_546_319_833) internal val getColorsPtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPalette", "get_colors", 1392750486) + TypeManager.getMethodBindPtr("ColorPalette", "get_colors", 1_392_750_486) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ColorPicker.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ColorPicker.kt index 10646fcca2..07e16304c2 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ColorPicker.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ColorPicker.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -28,11 +25,9 @@ import kotlin.Unit import kotlin.jvm.JvmName /** - * A widget that provides an interface for selecting or modifying a color. It can optionally provide - * functionalities like a color sampler (eyedropper), color modes, and presets. + * A widget that provides an interface for selecting or modifying a color. It can optionally provide functionalities like a color sampler (eyedropper), color modes, and presets. * - * **Note:** This control is the color picker widget itself. You can use a [ColorPickerButton] - * instead if you need a button that brings up a [ColorPicker] in a popup. + * **Note:** This control is the color picker widget itself. You can use a [ColorPickerButton] instead if you need a button that brings up a [ColorPicker] in a popup. */ @GodotBaseType public open class ColorPicker : VBoxContainer() { @@ -55,11 +50,8 @@ public open class ColorPicker : VBoxContainer() { * The currently selected color. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var color: Color @@ -93,8 +85,7 @@ public open class ColorPicker : VBoxContainer() { } /** - * If `true`, the color will apply only after the user releases the mouse button, otherwise it - * will apply immediately even in mouse motion event (which can cause performance issues). + * If `true`, the color will apply only after the user releases the mouse button, otherwise it will apply immediately even in mouse motion event (which can cause performance issues). */ public final inline var deferredMode: Boolean @JvmName("deferredModeProperty") @@ -116,8 +107,7 @@ public open class ColorPicker : VBoxContainer() { } /** - * If `true`, it's possible to add presets under Swatches. If `false`, the button to add presets - * is disabled. + * If `true`, it's possible to add presets under Swatches. If `false`, the button to add presets is disabled. */ public final inline var canAddSwatches: Boolean @JvmName("canAddSwatchesProperty") @@ -182,7 +172,7 @@ public open class ColorPicker : VBoxContainer() { setPresetsVisible(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(161, scriptIndex) } @@ -205,7 +195,7 @@ public open class ColorPicker : VBoxContainer() { color = this } - public final fun setPickColor(color: Color): Unit { + public final fun setPickColor(color: Color) { TransferContext.writeArguments(COLOR to color) TransferContext.callMethod(ptr, MethodBindings.setPickColorPtr, NIL) } @@ -216,7 +206,7 @@ public open class ColorPicker : VBoxContainer() { return (TransferContext.readReturnValue(COLOR) as Color) } - public final fun setDeferredMode(mode: Boolean): Unit { + public final fun setDeferredMode(mode: Boolean) { TransferContext.writeArguments(BOOL to mode) TransferContext.callMethod(ptr, MethodBindings.setDeferredModePtr, NIL) } @@ -227,7 +217,7 @@ public open class ColorPicker : VBoxContainer() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setColorMode(colorMode: ColorModeType): Unit { + public final fun setColorMode(colorMode: ColorModeType) { TransferContext.writeArguments(LONG to colorMode.id) TransferContext.callMethod(ptr, MethodBindings.setColorModePtr, NIL) } @@ -238,7 +228,7 @@ public open class ColorPicker : VBoxContainer() { return ColorModeType.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setEditAlpha(show: Boolean): Unit { + public final fun setEditAlpha(show: Boolean) { TransferContext.writeArguments(BOOL to show) TransferContext.callMethod(ptr, MethodBindings.setEditAlphaPtr, NIL) } @@ -249,7 +239,7 @@ public open class ColorPicker : VBoxContainer() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setCanAddSwatches(enabled: Boolean): Unit { + public final fun setCanAddSwatches(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setCanAddSwatchesPtr, NIL) } @@ -260,7 +250,7 @@ public open class ColorPicker : VBoxContainer() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setPresetsVisible(visible: Boolean): Unit { + public final fun setPresetsVisible(visible: Boolean) { TransferContext.writeArguments(BOOL to visible) TransferContext.callMethod(ptr, MethodBindings.setPresetsVisiblePtr, NIL) } @@ -271,7 +261,7 @@ public open class ColorPicker : VBoxContainer() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setModesVisible(visible: Boolean): Unit { + public final fun setModesVisible(visible: Boolean) { TransferContext.writeArguments(BOOL to visible) TransferContext.callMethod(ptr, MethodBindings.setModesVisiblePtr, NIL) } @@ -282,7 +272,7 @@ public open class ColorPicker : VBoxContainer() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setSamplerVisible(visible: Boolean): Unit { + public final fun setSamplerVisible(visible: Boolean) { TransferContext.writeArguments(BOOL to visible) TransferContext.callMethod(ptr, MethodBindings.setSamplerVisiblePtr, NIL) } @@ -293,7 +283,7 @@ public open class ColorPicker : VBoxContainer() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setSlidersVisible(visible: Boolean): Unit { + public final fun setSlidersVisible(visible: Boolean) { TransferContext.writeArguments(BOOL to visible) TransferContext.callMethod(ptr, MethodBindings.setSlidersVisiblePtr, NIL) } @@ -304,7 +294,7 @@ public open class ColorPicker : VBoxContainer() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setHexVisible(visible: Boolean): Unit { + public final fun setHexVisible(visible: Boolean) { TransferContext.writeArguments(BOOL to visible) TransferContext.callMethod(ptr, MethodBindings.setHexVisiblePtr, NIL) } @@ -316,12 +306,11 @@ public open class ColorPicker : VBoxContainer() { } /** - * Adds the given color to a list of color presets. The presets are displayed in the color picker - * and the user will be able to select them. + * Adds the given color to a list of color presets. The presets are displayed in the color picker and the user will be able to select them. * * **Note:** The presets list is only for *this* color picker. */ - public final fun addPreset(color: Color): Unit { + public final fun addPreset(color: Color) { TransferContext.writeArguments(COLOR to color) TransferContext.callMethod(ptr, MethodBindings.addPresetPtr, NIL) } @@ -329,7 +318,7 @@ public open class ColorPicker : VBoxContainer() { /** * Removes the given color from the list of color presets of this color picker. */ - public final fun erasePreset(color: Color): Unit { + public final fun erasePreset(color: Color) { TransferContext.writeArguments(COLOR to color) TransferContext.callMethod(ptr, MethodBindings.erasePresetPtr, NIL) } @@ -344,13 +333,11 @@ public open class ColorPicker : VBoxContainer() { } /** - * Adds the given color to a list of color recent presets so that it can be picked later. Recent - * presets are the colors that were picked recently, a new preset is automatically created and added - * to recent presets when you pick a new color. + * Adds the given color to a list of color recent presets so that it can be picked later. Recent presets are the colors that were picked recently, a new preset is automatically created and added to recent presets when you pick a new color. * * **Note:** The recent presets list is only for *this* color picker. */ - public final fun addRecentPreset(color: Color): Unit { + public final fun addRecentPreset(color: Color) { TransferContext.writeArguments(COLOR to color) TransferContext.callMethod(ptr, MethodBindings.addRecentPresetPtr, NIL) } @@ -358,7 +345,7 @@ public open class ColorPicker : VBoxContainer() { /** * Removes the given color from the list of color recent presets of this color picker. */ - public final fun eraseRecentPreset(color: Color): Unit { + public final fun eraseRecentPreset(color: Color) { TransferContext.writeArguments(COLOR to color) TransferContext.callMethod(ptr, MethodBindings.eraseRecentPresetPtr, NIL) } @@ -372,7 +359,7 @@ public open class ColorPicker : VBoxContainer() { return (TransferContext.readReturnValue(PACKED_COLOR_ARRAY) as PackedColorArray) } - public final fun setPickerShape(shape: PickerShapeType): Unit { + public final fun setPickerShape(shape: PickerShapeType) { TransferContext.writeArguments(LONG to shape.id) TransferContext.callMethod(ptr, MethodBindings.setPickerShapePtr, NIL) } @@ -395,16 +382,13 @@ public open class ColorPicker : VBoxContainer() { */ MODE_HSV(1), /** - * Allows the color R, G, B component values to go beyond 1.0, which can be used for certain - * special operations that require it (like tinting without darkening or rendering sprites in HDR). + * Allows the color R, G, B component values to go beyond 1.0, which can be used for certain special operations that require it (like tinting without darkening or rendering sprites in HDR). */ MODE_RAW(2), /** * Allows editing the color with Hue/Saturation/Lightness sliders. * - * OKHSL is a new color space similar to HSL but that better match perception by leveraging the - * Oklab color space which is designed to be simple to use, while doing a good job at predicting - * perceived lightness, chroma and hue. + * OKHSL is a new color space similar to HSL but that better match perception by leveraging the Oklab color space which is designed to be simple to use, while doing a good job at predicting perceived lightness, chroma and hue. * * [url=https://bottosson.github.io/posts/colorpicker/]Okhsv and Okhsl color spaces[/url] */ @@ -441,8 +425,7 @@ public open class ColorPicker : VBoxContainer() { */ SHAPE_OKHSL_CIRCLE(3), /** - * The color space shape and the shape select button are hidden. Can't be selected from the - * shapes popup. + * The color space shape and the shape select button are hidden. Can't be selected from the shapes popup. */ SHAPE_NONE(4), ; @@ -461,87 +444,87 @@ public open class ColorPicker : VBoxContainer() { public object MethodBindings { internal val setPickColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPicker", "set_pick_color", 2920490490) + TypeManager.getMethodBindPtr("ColorPicker", "set_pick_color", 2_920_490_490) internal val getPickColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPicker", "get_pick_color", 3444240500) + TypeManager.getMethodBindPtr("ColorPicker", "get_pick_color", 3_444_240_500) internal val setDeferredModePtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPicker", "set_deferred_mode", 2586408642) + TypeManager.getMethodBindPtr("ColorPicker", "set_deferred_mode", 2_586_408_642) internal val isDeferredModePtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPicker", "is_deferred_mode", 36873697) + TypeManager.getMethodBindPtr("ColorPicker", "is_deferred_mode", 36_873_697) internal val setColorModePtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPicker", "set_color_mode", 1579114136) + TypeManager.getMethodBindPtr("ColorPicker", "set_color_mode", 1_579_114_136) internal val getColorModePtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPicker", "get_color_mode", 392907674) + TypeManager.getMethodBindPtr("ColorPicker", "get_color_mode", 392_907_674) internal val setEditAlphaPtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPicker", "set_edit_alpha", 2586408642) + TypeManager.getMethodBindPtr("ColorPicker", "set_edit_alpha", 2_586_408_642) internal val isEditingAlphaPtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPicker", "is_editing_alpha", 36873697) + TypeManager.getMethodBindPtr("ColorPicker", "is_editing_alpha", 36_873_697) internal val setCanAddSwatchesPtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPicker", "set_can_add_swatches", 2586408642) + TypeManager.getMethodBindPtr("ColorPicker", "set_can_add_swatches", 2_586_408_642) internal val areSwatchesEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPicker", "are_swatches_enabled", 36873697) + TypeManager.getMethodBindPtr("ColorPicker", "are_swatches_enabled", 36_873_697) internal val setPresetsVisiblePtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPicker", "set_presets_visible", 2586408642) + TypeManager.getMethodBindPtr("ColorPicker", "set_presets_visible", 2_586_408_642) internal val arePresetsVisiblePtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPicker", "are_presets_visible", 36873697) + TypeManager.getMethodBindPtr("ColorPicker", "are_presets_visible", 36_873_697) internal val setModesVisiblePtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPicker", "set_modes_visible", 2586408642) + TypeManager.getMethodBindPtr("ColorPicker", "set_modes_visible", 2_586_408_642) internal val areModesVisiblePtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPicker", "are_modes_visible", 36873697) + TypeManager.getMethodBindPtr("ColorPicker", "are_modes_visible", 36_873_697) internal val setSamplerVisiblePtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPicker", "set_sampler_visible", 2586408642) + TypeManager.getMethodBindPtr("ColorPicker", "set_sampler_visible", 2_586_408_642) internal val isSamplerVisiblePtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPicker", "is_sampler_visible", 36873697) + TypeManager.getMethodBindPtr("ColorPicker", "is_sampler_visible", 36_873_697) internal val setSlidersVisiblePtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPicker", "set_sliders_visible", 2586408642) + TypeManager.getMethodBindPtr("ColorPicker", "set_sliders_visible", 2_586_408_642) internal val areSlidersVisiblePtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPicker", "are_sliders_visible", 36873697) + TypeManager.getMethodBindPtr("ColorPicker", "are_sliders_visible", 36_873_697) internal val setHexVisiblePtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPicker", "set_hex_visible", 2586408642) + TypeManager.getMethodBindPtr("ColorPicker", "set_hex_visible", 2_586_408_642) internal val isHexVisiblePtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPicker", "is_hex_visible", 36873697) + TypeManager.getMethodBindPtr("ColorPicker", "is_hex_visible", 36_873_697) internal val addPresetPtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPicker", "add_preset", 2920490490) + TypeManager.getMethodBindPtr("ColorPicker", "add_preset", 2_920_490_490) internal val erasePresetPtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPicker", "erase_preset", 2920490490) + TypeManager.getMethodBindPtr("ColorPicker", "erase_preset", 2_920_490_490) internal val getPresetsPtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPicker", "get_presets", 1392750486) + TypeManager.getMethodBindPtr("ColorPicker", "get_presets", 1_392_750_486) internal val addRecentPresetPtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPicker", "add_recent_preset", 2920490490) + TypeManager.getMethodBindPtr("ColorPicker", "add_recent_preset", 2_920_490_490) internal val eraseRecentPresetPtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPicker", "erase_recent_preset", 2920490490) + TypeManager.getMethodBindPtr("ColorPicker", "erase_recent_preset", 2_920_490_490) internal val getRecentPresetsPtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPicker", "get_recent_presets", 1392750486) + TypeManager.getMethodBindPtr("ColorPicker", "get_recent_presets", 1_392_750_486) internal val setPickerShapePtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPicker", "set_picker_shape", 3981373861) + TypeManager.getMethodBindPtr("ColorPicker", "set_picker_shape", 3_981_373_861) internal val getPickerShapePtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPicker", "get_picker_shape", 1143229889) + TypeManager.getMethodBindPtr("ColorPicker", "get_picker_shape", 1_143_229_889) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ColorPickerButton.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ColorPickerButton.kt index 2f6bbe316c..d51fdd770b 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ColorPickerButton.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ColorPickerButton.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -26,14 +23,11 @@ import kotlin.Unit import kotlin.jvm.JvmName /** - * Encapsulates a [ColorPicker], making it accessible by pressing a button. Pressing the button will - * toggle the [ColorPicker]'s visibility. + * Encapsulates a [ColorPicker], making it accessible by pressing a button. Pressing the button will toggle the [ColorPicker]'s visibility. * * See also [BaseButton] which contains common properties and methods associated with this node. * - * **Note:** By default, the button may not be wide enough for the color preview swatch to be - * visible. Make sure to set [Control.customMinimumSize] to a big enough value to give the button - * enough space. + * **Note:** By default, the button may not be wide enough for the color preview swatch to be visible. Make sure to set [Control.customMinimumSize] to a big enough value to give the button enough space. */ @GodotBaseType public open class ColorPickerButton : Button() { @@ -56,11 +50,8 @@ public open class ColorPickerButton : Button() { * The currently selected color. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var color: Color @@ -82,7 +73,7 @@ public open class ColorPickerButton : Button() { setEditAlpha(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(162, scriptIndex) } @@ -105,7 +96,7 @@ public open class ColorPickerButton : Button() { color = this } - public final fun setPickColor(color: Color): Unit { + public final fun setPickColor(color: Color) { TransferContext.writeArguments(COLOR to color) TransferContext.callMethod(ptr, MethodBindings.setPickColorPtr, NIL) } @@ -119,8 +110,7 @@ public open class ColorPickerButton : Button() { /** * Returns the [ColorPicker] that this node toggles. * - * **Warning:** This is a required internal node, removing and freeing it may cause a crash. If - * you wish to hide it or any of its children, use their [CanvasItem.visible] property. + * **Warning:** This is a required internal node, removing and freeing it may cause a crash. If you wish to hide it or any of its children, use their [CanvasItem.visible] property. */ public final fun getPicker(): ColorPicker? { TransferContext.writeArguments() @@ -129,11 +119,9 @@ public open class ColorPickerButton : Button() { } /** - * Returns the control's [PopupPanel] which allows you to connect to popup signals. This allows - * you to handle events when the ColorPicker is shown or hidden. + * Returns the control's [PopupPanel] which allows you to connect to popup signals. This allows you to handle events when the ColorPicker is shown or hidden. * - * **Warning:** This is a required internal node, removing and freeing it may cause a crash. If - * you wish to hide it or any of its children, use their [Window.visible] property. + * **Warning:** This is a required internal node, removing and freeing it may cause a crash. If you wish to hide it or any of its children, use their [Window.visible] property. */ public final fun getPopup(): PopupPanel? { TransferContext.writeArguments() @@ -141,7 +129,7 @@ public open class ColorPickerButton : Button() { return (TransferContext.readReturnValue(OBJECT) as PopupPanel?) } - public final fun setEditAlpha(show: Boolean): Unit { + public final fun setEditAlpha(show: Boolean) { TransferContext.writeArguments(BOOL to show) TransferContext.callMethod(ptr, MethodBindings.setEditAlphaPtr, NIL) } @@ -156,21 +144,21 @@ public open class ColorPickerButton : Button() { public object MethodBindings { internal val setPickColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPickerButton", "set_pick_color", 2920490490) + TypeManager.getMethodBindPtr("ColorPickerButton", "set_pick_color", 2_920_490_490) internal val getPickColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPickerButton", "get_pick_color", 3444240500) + TypeManager.getMethodBindPtr("ColorPickerButton", "get_pick_color", 3_444_240_500) internal val getPickerPtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPickerButton", "get_picker", 331835996) + TypeManager.getMethodBindPtr("ColorPickerButton", "get_picker", 331_835_996) internal val getPopupPtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPickerButton", "get_popup", 1322440207) + TypeManager.getMethodBindPtr("ColorPickerButton", "get_popup", 1_322_440_207) internal val setEditAlphaPtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPickerButton", "set_edit_alpha", 2586408642) + TypeManager.getMethodBindPtr("ColorPickerButton", "set_edit_alpha", 2_586_408_642) internal val isEditingAlphaPtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorPickerButton", "is_editing_alpha", 36873697) + TypeManager.getMethodBindPtr("ColorPickerButton", "is_editing_alpha", 36_873_697) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ColorRect.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ColorRect.kt index 7396063977..c1e3c28def 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ColorRect.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ColorRect.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -21,8 +18,7 @@ import kotlin.Unit import kotlin.jvm.JvmName /** - * Displays a rectangle filled with a solid [color]. If you need to display the border alone, - * consider using a [Panel] instead. + * Displays a rectangle filled with a solid [color]. If you need to display the border alone, consider using a [Panel] instead. */ @GodotBaseType public open class ColorRect : Control() { @@ -30,11 +26,8 @@ public open class ColorRect : Control() { * The fill color of the rectangle. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var color: Color @@ -45,7 +38,7 @@ public open class ColorRect : Control() { setColor(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(163, scriptIndex) } @@ -68,7 +61,7 @@ public open class ColorRect : Control() { color = this } - public final fun setColor(color: Color): Unit { + public final fun setColor(color: Color) { TransferContext.writeArguments(COLOR to color) TransferContext.callMethod(ptr, MethodBindings.setColorPtr, NIL) } @@ -83,9 +76,9 @@ public open class ColorRect : Control() { public object MethodBindings { internal val setColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorRect", "set_color", 2920490490) + TypeManager.getMethodBindPtr("ColorRect", "set_color", 2_920_490_490) internal val getColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("ColorRect", "get_color", 3444240500) + TypeManager.getMethodBindPtr("ColorRect", "get_color", 3_444_240_500) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Compositor.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Compositor.kt index 2fad6bcdd7..506348b846 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Compositor.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Compositor.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -15,7 +12,6 @@ import godot.core.VariantParser.ARRAY import godot.core.VariantParser.NIL import kotlin.Int import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** @@ -24,8 +20,7 @@ import kotlin.jvm.JvmName @GodotBaseType public open class Compositor : Resource() { /** - * The custom [CompositorEffect]s that are applied during rendering of viewports using this - * compositor. + * The custom [CompositorEffect]s that are applied during rendering of viewports using this compositor. */ public final inline var compositorEffects: VariantArray @JvmName("compositorEffectsProperty") @@ -35,11 +30,11 @@ public open class Compositor : Resource() { setCompositorEffects(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(164, scriptIndex) } - public final fun setCompositorEffects(compositorEffects: VariantArray): Unit { + public final fun setCompositorEffects(compositorEffects: VariantArray) { TransferContext.writeArguments(ARRAY to compositorEffects) TransferContext.callMethod(ptr, MethodBindings.setCompositorEffectsPtr, NIL) } @@ -54,9 +49,9 @@ public open class Compositor : Resource() { public object MethodBindings { internal val setCompositorEffectsPtr: VoidPtr = - TypeManager.getMethodBindPtr("Compositor", "set_compositor_effects", 381264803) + TypeManager.getMethodBindPtr("Compositor", "set_compositor_effects", 381_264_803) internal val getCompositorEffectsPtr: VoidPtr = - TypeManager.getMethodBindPtr("Compositor", "get_compositor_effects", 3995934104) + TypeManager.getMethodBindPtr("Compositor", "get_compositor_effects", 3_995_934_104) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CompositorEffect.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CompositorEffect.kt index dae6245a02..1472172d71 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CompositorEffect.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CompositorEffect.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -18,15 +15,10 @@ import kotlin.Int import kotlin.Long import kotlin.NotImplementedError import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * This resource defines a custom rendering effect that can be applied to [Viewport]s through the - * viewports' [Environment]. You can implement a callback that is called during rendering at a given - * stage of the rendering pipeline and allows you to insert additional passes. Note that this callback - * happens on the rendering thread. CompositorEffect is an abstract base class and must be extended to - * implement specific rendering logic. + * This resource defines a custom rendering effect that can be applied to [Viewport]s through the viewports' [Environment]. You can implement a callback that is called during rendering at a given stage of the rendering pipeline and allows you to insert additional passes. Note that this callback happens on the rendering thread. CompositorEffect is an abstract base class and must be extended to implement specific rendering logic. */ @GodotBaseType public open class CompositorEffect : Resource() { @@ -42,8 +34,7 @@ public open class CompositorEffect : Resource() { } /** - * The type of effect that is implemented, determines at what stage of rendering the callback is - * called. + * The type of effect that is implemented, determines at what stage of rendering the callback is called. */ public final inline var effectCallbackType: EffectCallbackType @JvmName("effectCallbackTypeProperty") @@ -54,8 +45,7 @@ public open class CompositorEffect : Resource() { } /** - * If `true` and MSAA is enabled, this will trigger a color buffer resolve before the effect is - * run. + * If `true` and MSAA is enabled, this will trigger a color buffer resolve before the effect is run. * * **Note:** In [_renderCallback], to access the resolved buffer use: * @@ -73,8 +63,7 @@ public open class CompositorEffect : Resource() { } /** - * If `true` and MSAA is enabled, this will trigger a depth buffer resolve before the effect is - * run. + * If `true` and MSAA is enabled, this will trigger a depth buffer resolve before the effect is run. * * **Note:** In [_renderCallback], to access the resolved buffer use: * @@ -110,21 +99,16 @@ public open class CompositorEffect : Resource() { } /** - * If `true` this triggers normal and roughness data to be output during our depth pre-pass, only - * applicable for the Forward+ renderer. + * If `true` this triggers normal and roughness data to be output during our depth pre-pass, only applicable for the Forward+ renderer. * * **Note:** In [_renderCallback], to access the roughness buffer use: * * ``` * var render_scene_buffers = render_data.get_render_scene_buffers() - * var roughness_buffer = render_scene_buffers.get_texture("forward_clustered", - * "normal_roughness") + * var roughness_buffer = render_scene_buffers.get_texture("forward_clustered", "normal_roughness") * ``` * - * The raw normal and roughness buffer is stored in an optimized format, different than the one - * available in Spatial shaders. When sampling the buffer, a conversion function must be applied. Use - * this function, copied from - * [url=https://github.com/godotengine/godot/blob/da5f39889f155658cef7f7ec3cc1abb94e17d815/servers/rendering/renderer_rd/shaders/forward_clustered/scene_forward_clustered_inc.glsl#L334-L341]here[/url]: + * The raw normal and roughness buffer is stored in an optimized format, different than the one available in Spatial shaders. When sampling the buffer, a conversion function must be applied. Use this function, copied from [url=https://github.com/godotengine/godot/blob/da5f39889f155658cef7f7ec3cc1abb94e17d815/servers/rendering/renderer_rd/shaders/forward_clustered/scene_forward_clustered_inc.glsl#L334-L341]here[/url]: * * ``` * vec4 normal_roughness_compatibility(vec4 p_normal_roughness) { @@ -146,8 +130,7 @@ public open class CompositorEffect : Resource() { } /** - * If `true` this triggers specular data being rendered to a separate buffer and combined after - * effects have been applied, only applicable for the Forward+ renderer. + * If `true` this triggers specular data being rendered to a separate buffer and combined after effects have been applied, only applicable for the Forward+ renderer. */ public final inline var needsSeparateSpecular: Boolean @JvmName("needsSeparateSpecularProperty") @@ -157,20 +140,18 @@ public open class CompositorEffect : Resource() { setNeedsSeparateSpecular(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(165, scriptIndex) } /** - * Implement this function with your custom rendering code. [effectCallbackType] should always - * match the effect callback type you've specified in [effectCallbackType]. [renderData] provides - * access to the rendering state, it is only valid during rendering and should not be stored. + * Implement this function with your custom rendering code. [effectCallbackType] should always match the effect callback type you've specified in [effectCallbackType]. [renderData] provides access to the rendering state, it is only valid during rendering and should not be stored. */ - public open fun _renderCallback(effectCallbackType: Int, renderData: RenderData?): Unit { + public open fun _renderCallback(effectCallbackType: Int, renderData: RenderData?) { throw NotImplementedError("CompositorEffect::_renderCallback is not implemented.") } - public final fun setEnabled(enabled: Boolean): Unit { + public final fun setEnabled(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setEnabledPtr, NIL) } @@ -181,7 +162,7 @@ public open class CompositorEffect : Resource() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setEffectCallbackType(effectCallbackType: EffectCallbackType): Unit { + public final fun setEffectCallbackType(effectCallbackType: EffectCallbackType) { TransferContext.writeArguments(LONG to effectCallbackType.id) TransferContext.callMethod(ptr, MethodBindings.setEffectCallbackTypePtr, NIL) } @@ -192,7 +173,7 @@ public open class CompositorEffect : Resource() { return EffectCallbackType.from(TransferContext.readReturnValue(LONG) as Long) } - public final fun setAccessResolvedColor(enable: Boolean): Unit { + public final fun setAccessResolvedColor(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setAccessResolvedColorPtr, NIL) } @@ -203,7 +184,7 @@ public open class CompositorEffect : Resource() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setAccessResolvedDepth(enable: Boolean): Unit { + public final fun setAccessResolvedDepth(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setAccessResolvedDepthPtr, NIL) } @@ -214,7 +195,7 @@ public open class CompositorEffect : Resource() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setNeedsMotionVectors(enable: Boolean): Unit { + public final fun setNeedsMotionVectors(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setNeedsMotionVectorsPtr, NIL) } @@ -225,7 +206,7 @@ public open class CompositorEffect : Resource() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setNeedsNormalRoughness(enable: Boolean): Unit { + public final fun setNeedsNormalRoughness(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setNeedsNormalRoughnessPtr, NIL) } @@ -236,7 +217,7 @@ public open class CompositorEffect : Resource() { return (TransferContext.readReturnValue(BOOL) as Boolean) } - public final fun setNeedsSeparateSpecular(enable: Boolean): Unit { + public final fun setNeedsSeparateSpecular(enable: Boolean) { TransferContext.writeArguments(BOOL to enable) TransferContext.callMethod(ptr, MethodBindings.setNeedsSeparateSpecularPtr, NIL) } @@ -251,8 +232,7 @@ public open class CompositorEffect : Resource() { id: Long, ) { /** - * The callback is called before our opaque rendering pass, but after depth prepass (if - * applicable). + * The callback is called before our opaque rendering pass, but after depth prepass (if applicable). */ PRE_OPAQUE(0), /** @@ -260,18 +240,15 @@ public open class CompositorEffect : Resource() { */ POST_OPAQUE(1), /** - * The callback is called after our sky is rendered, but before our back buffers are created - * (and if enabled, before subsurface scattering and/or screen space reflections). + * The callback is called after our sky is rendered, but before our back buffers are created (and if enabled, before subsurface scattering and/or screen space reflections). */ POST_SKY(2), /** - * The callback is called before our transparent rendering pass, but after our sky is rendered - * and we've created our back buffers. + * The callback is called before our transparent rendering pass, but after our sky is rendered and we've created our back buffers. */ PRE_TRANSPARENT(3), /** - * The callback is called after our transparent rendering pass, but before any built-in - * post-processing effects and output to our render target. + * The callback is called after our transparent rendering pass, but before any built-in post-processing effects and output to our render target. */ POST_TRANSPARENT(4), /** @@ -294,45 +271,45 @@ public open class CompositorEffect : Resource() { public object MethodBindings { internal val setEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CompositorEffect", "set_enabled", 2586408642) + TypeManager.getMethodBindPtr("CompositorEffect", "set_enabled", 2_586_408_642) internal val getEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("CompositorEffect", "get_enabled", 36873697) + TypeManager.getMethodBindPtr("CompositorEffect", "get_enabled", 36_873_697) internal val setEffectCallbackTypePtr: VoidPtr = - TypeManager.getMethodBindPtr("CompositorEffect", "set_effect_callback_type", 1390728419) + TypeManager.getMethodBindPtr("CompositorEffect", "set_effect_callback_type", 1_390_728_419) internal val getEffectCallbackTypePtr: VoidPtr = - TypeManager.getMethodBindPtr("CompositorEffect", "get_effect_callback_type", 1221912590) + TypeManager.getMethodBindPtr("CompositorEffect", "get_effect_callback_type", 1_221_912_590) internal val setAccessResolvedColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CompositorEffect", "set_access_resolved_color", 2586408642) + TypeManager.getMethodBindPtr("CompositorEffect", "set_access_resolved_color", 2_586_408_642) internal val getAccessResolvedColorPtr: VoidPtr = - TypeManager.getMethodBindPtr("CompositorEffect", "get_access_resolved_color", 36873697) + TypeManager.getMethodBindPtr("CompositorEffect", "get_access_resolved_color", 36_873_697) internal val setAccessResolvedDepthPtr: VoidPtr = - TypeManager.getMethodBindPtr("CompositorEffect", "set_access_resolved_depth", 2586408642) + TypeManager.getMethodBindPtr("CompositorEffect", "set_access_resolved_depth", 2_586_408_642) internal val getAccessResolvedDepthPtr: VoidPtr = - TypeManager.getMethodBindPtr("CompositorEffect", "get_access_resolved_depth", 36873697) + TypeManager.getMethodBindPtr("CompositorEffect", "get_access_resolved_depth", 36_873_697) internal val setNeedsMotionVectorsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CompositorEffect", "set_needs_motion_vectors", 2586408642) + TypeManager.getMethodBindPtr("CompositorEffect", "set_needs_motion_vectors", 2_586_408_642) internal val getNeedsMotionVectorsPtr: VoidPtr = - TypeManager.getMethodBindPtr("CompositorEffect", "get_needs_motion_vectors", 36873697) + TypeManager.getMethodBindPtr("CompositorEffect", "get_needs_motion_vectors", 36_873_697) internal val setNeedsNormalRoughnessPtr: VoidPtr = - TypeManager.getMethodBindPtr("CompositorEffect", "set_needs_normal_roughness", 2586408642) + TypeManager.getMethodBindPtr("CompositorEffect", "set_needs_normal_roughness", 2_586_408_642) internal val getNeedsNormalRoughnessPtr: VoidPtr = - TypeManager.getMethodBindPtr("CompositorEffect", "get_needs_normal_roughness", 36873697) + TypeManager.getMethodBindPtr("CompositorEffect", "get_needs_normal_roughness", 36_873_697) internal val setNeedsSeparateSpecularPtr: VoidPtr = - TypeManager.getMethodBindPtr("CompositorEffect", "set_needs_separate_specular", 2586408642) + TypeManager.getMethodBindPtr("CompositorEffect", "set_needs_separate_specular", 2_586_408_642) internal val getNeedsSeparateSpecularPtr: VoidPtr = - TypeManager.getMethodBindPtr("CompositorEffect", "get_needs_separate_specular", 36873697) + TypeManager.getMethodBindPtr("CompositorEffect", "get_needs_separate_specular", 36_873_697) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CompressedCubemap.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CompressedCubemap.kt index ad6e33f0d7..f1353d2947 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CompressedCubemap.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CompressedCubemap.kt @@ -1,20 +1,14 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api import godot.`annotation`.GodotBaseType import kotlin.Int import kotlin.Suppress -import kotlin.Unit /** - * A cubemap that is loaded from a `.ccube` file. This file format is internal to Godot; it is - * created by importing other image formats with the import system. [CompressedCubemap] can use one of - * 4 compression methods: + * A cubemap that is loaded from a `.ccube` file. This file format is internal to Godot; it is created by importing other image formats with the import system. [CompressedCubemap] can use one of 4 compression methods: * * - Lossless (WebP or PNG, uncompressed on the GPU) * @@ -24,22 +18,17 @@ import kotlin.Unit * * - VRAM Uncompressed (uncompressed on the GPU) * - * - Basis Universal (compressed on the GPU. Lower file sizes than VRAM Compressed, but slower to - * compress and lower quality than VRAM Compressed) + * - Basis Universal (compressed on the GPU. Lower file sizes than VRAM Compressed, but slower to compress and lower quality than VRAM Compressed) * - * Only **VRAM Compressed** actually reduces the memory usage on the GPU. The **Lossless** and - * **Lossy** compression methods will reduce the required storage on disk, but they will not reduce - * memory usage on the GPU as the texture is sent to the GPU uncompressed. + * Only **VRAM Compressed** actually reduces the memory usage on the GPU. The **Lossless** and **Lossy** compression methods will reduce the required storage on disk, but they will not reduce memory usage on the GPU as the texture is sent to the GPU uncompressed. * - * Using **VRAM Compressed** also improves loading times, as VRAM-compressed textures are faster to - * load compared to textures using lossless or lossy compression. VRAM compression can exhibit - * noticeable artifacts and is intended to be used for 3D rendering, not 2D. + * Using **VRAM Compressed** also improves loading times, as VRAM-compressed textures are faster to load compared to textures using lossless or lossy compression. VRAM compression can exhibit noticeable artifacts and is intended to be used for 3D rendering, not 2D. * * See [Cubemap] for a general description of cubemaps. */ @GodotBaseType public open class CompressedCubemap : CompressedTextureLayered() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(166, scriptIndex) } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CompressedCubemapArray.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CompressedCubemapArray.kt index cb5009c7c5..676c1f8e0e 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CompressedCubemapArray.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CompressedCubemapArray.kt @@ -1,20 +1,14 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api import godot.`annotation`.GodotBaseType import kotlin.Int import kotlin.Suppress -import kotlin.Unit /** - * A cubemap array that is loaded from a `.ccubearray` file. This file format is internal to Godot; - * it is created by importing other image formats with the import system. [CompressedCubemapArray] can - * use one of 4 compression methods: + * A cubemap array that is loaded from a `.ccubearray` file. This file format is internal to Godot; it is created by importing other image formats with the import system. [CompressedCubemapArray] can use one of 4 compression methods: * * - Lossless (WebP or PNG, uncompressed on the GPU) * @@ -24,22 +18,17 @@ import kotlin.Unit * * - VRAM Uncompressed (uncompressed on the GPU) * - * - Basis Universal (compressed on the GPU. Lower file sizes than VRAM Compressed, but slower to - * compress and lower quality than VRAM Compressed) + * - Basis Universal (compressed on the GPU. Lower file sizes than VRAM Compressed, but slower to compress and lower quality than VRAM Compressed) * - * Only **VRAM Compressed** actually reduces the memory usage on the GPU. The **Lossless** and - * **Lossy** compression methods will reduce the required storage on disk, but they will not reduce - * memory usage on the GPU as the texture is sent to the GPU uncompressed. + * Only **VRAM Compressed** actually reduces the memory usage on the GPU. The **Lossless** and **Lossy** compression methods will reduce the required storage on disk, but they will not reduce memory usage on the GPU as the texture is sent to the GPU uncompressed. * - * Using **VRAM Compressed** also improves loading times, as VRAM-compressed textures are faster to - * load compared to textures using lossless or lossy compression. VRAM compression can exhibit - * noticeable artifacts and is intended to be used for 3D rendering, not 2D. + * Using **VRAM Compressed** also improves loading times, as VRAM-compressed textures are faster to load compared to textures using lossless or lossy compression. VRAM compression can exhibit noticeable artifacts and is intended to be used for 3D rendering, not 2D. * * See [CubemapArray] for a general description of cubemap arrays. */ @GodotBaseType public open class CompressedCubemapArray : CompressedTextureLayered() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(167, scriptIndex) } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CompressedTexture2D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CompressedTexture2D.kt index f9c3066cd9..068396f955 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CompressedTexture2D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CompressedTexture2D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -18,13 +15,10 @@ import kotlin.Long import kotlin.NotImplementedError import kotlin.String import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * A texture that is loaded from a `.ctex` file. This file format is internal to Godot; it is - * created by importing other image formats with the import system. [CompressedTexture2D] can use one - * of 4 compression methods (including a lack of any compression): + * A texture that is loaded from a `.ctex` file. This file format is internal to Godot; it is created by importing other image formats with the import system. [CompressedTexture2D] can use one of 4 compression methods (including a lack of any compression): * * - Lossless (WebP or PNG, uncompressed on the GPU) * @@ -34,16 +28,11 @@ import kotlin.jvm.JvmName * * - VRAM Uncompressed (uncompressed on the GPU) * - * - Basis Universal (compressed on the GPU. Lower file sizes than VRAM Compressed, but slower to - * compress and lower quality than VRAM Compressed) + * - Basis Universal (compressed on the GPU. Lower file sizes than VRAM Compressed, but slower to compress and lower quality than VRAM Compressed) * - * Only **VRAM Compressed** actually reduces the memory usage on the GPU. The **Lossless** and - * **Lossy** compression methods will reduce the required storage on disk, but they will not reduce - * memory usage on the GPU as the texture is sent to the GPU uncompressed. + * Only **VRAM Compressed** actually reduces the memory usage on the GPU. The **Lossless** and **Lossy** compression methods will reduce the required storage on disk, but they will not reduce memory usage on the GPU as the texture is sent to the GPU uncompressed. * - * Using **VRAM Compressed** also improves loading times, as VRAM-compressed textures are faster to - * load compared to textures using lossless or lossy compression. VRAM compression can exhibit - * noticeable artifacts and is intended to be used for 3D rendering, not 2D. + * Using **VRAM Compressed** also improves loading times, as VRAM-compressed textures are faster to load compared to textures using lossless or lossy compression. VRAM compression can exhibit noticeable artifacts and is intended to be used for 3D rendering, not 2D. */ @GodotBaseType public open class CompressedTexture2D : Texture2D() { @@ -54,7 +43,7 @@ public open class CompressedTexture2D : Texture2D() { @JvmName("loadPathProperty") get() = getLoadPath() - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(168, scriptIndex) } @@ -76,14 +65,14 @@ public open class CompressedTexture2D : Texture2D() { /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _getWidth(): Int { + override fun _getWidth(): Int { throw NotImplementedError("CompressedTexture2D::_getWidth can't be called from the JVM.") } /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _getHeight(): Int { + override fun _getHeight(): Int { throw NotImplementedError("CompressedTexture2D::_getHeight can't be called from the JVM.") } @@ -91,9 +80,9 @@ public open class CompressedTexture2D : Texture2D() { public object MethodBindings { internal val loadPtr: VoidPtr = - TypeManager.getMethodBindPtr("CompressedTexture2D", "load", 166001499) + TypeManager.getMethodBindPtr("CompressedTexture2D", "load", 166_001_499) internal val getLoadPathPtr: VoidPtr = - TypeManager.getMethodBindPtr("CompressedTexture2D", "get_load_path", 201670096) + TypeManager.getMethodBindPtr("CompressedTexture2D", "get_load_path", 201_670_096) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CompressedTexture2DArray.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CompressedTexture2DArray.kt index 7c8c789bb8..3dea62fada 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CompressedTexture2DArray.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CompressedTexture2DArray.kt @@ -1,20 +1,14 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api import godot.`annotation`.GodotBaseType import kotlin.Int import kotlin.Suppress -import kotlin.Unit /** - * A texture array that is loaded from a `.ctexarray` file. This file format is internal to Godot; - * it is created by importing other image formats with the import system. [CompressedTexture2DArray] - * can use one of 4 compression methods: + * A texture array that is loaded from a `.ctexarray` file. This file format is internal to Godot; it is created by importing other image formats with the import system. [CompressedTexture2DArray] can use one of 4 compression methods: * * - Lossless (WebP or PNG, uncompressed on the GPU) * @@ -24,22 +18,17 @@ import kotlin.Unit * * - VRAM Uncompressed (uncompressed on the GPU) * - * - Basis Universal (compressed on the GPU. Lower file sizes than VRAM Compressed, but slower to - * compress and lower quality than VRAM Compressed) + * - Basis Universal (compressed on the GPU. Lower file sizes than VRAM Compressed, but slower to compress and lower quality than VRAM Compressed) * - * Only **VRAM Compressed** actually reduces the memory usage on the GPU. The **Lossless** and - * **Lossy** compression methods will reduce the required storage on disk, but they will not reduce - * memory usage on the GPU as the texture is sent to the GPU uncompressed. + * Only **VRAM Compressed** actually reduces the memory usage on the GPU. The **Lossless** and **Lossy** compression methods will reduce the required storage on disk, but they will not reduce memory usage on the GPU as the texture is sent to the GPU uncompressed. * - * Using **VRAM Compressed** also improves loading times, as VRAM-compressed textures are faster to - * load compared to textures using lossless or lossy compression. VRAM compression can exhibit - * noticeable artifacts and is intended to be used for 3D rendering, not 2D. + * Using **VRAM Compressed** also improves loading times, as VRAM-compressed textures are faster to load compared to textures using lossless or lossy compression. VRAM compression can exhibit noticeable artifacts and is intended to be used for 3D rendering, not 2D. * * See [Texture2DArray] for a general description of texture arrays. */ @GodotBaseType public open class CompressedTexture2DArray : CompressedTextureLayered() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(169, scriptIndex) } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CompressedTexture3D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CompressedTexture3D.kt index a811b66611..f3fc9d7a2b 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CompressedTexture3D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CompressedTexture3D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -20,18 +17,12 @@ import kotlin.Long import kotlin.NotImplementedError import kotlin.String import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * [CompressedTexture3D] is the VRAM-compressed counterpart of [ImageTexture3D]. The file extension - * for [CompressedTexture3D] files is `.ctex3d`. This file format is internal to Godot; it is created - * by importing other image formats with the import system. + * [CompressedTexture3D] is the VRAM-compressed counterpart of [ImageTexture3D]. The file extension for [CompressedTexture3D] files is `.ctex3d`. This file format is internal to Godot; it is created by importing other image formats with the import system. * - * [CompressedTexture3D] uses VRAM compression, which allows to reduce memory usage on the GPU when - * rendering the texture. This also improves loading times, as VRAM-compressed textures are faster to - * load compared to textures using lossless compression. VRAM compression can exhibit noticeable - * artifacts and is intended to be used for 3D rendering, not 2D. + * [CompressedTexture3D] uses VRAM compression, which allows to reduce memory usage on the GPU when rendering the texture. This also improves loading times, as VRAM-compressed textures are faster to load compared to textures using lossless compression. VRAM compression can exhibit noticeable artifacts and is intended to be used for 3D rendering, not 2D. * * See [Texture3D] for a general description of 3D textures. */ @@ -44,7 +35,7 @@ public open class CompressedTexture3D : Texture3D() { @JvmName("loadPathProperty") get() = getLoadPath() - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(170, scriptIndex) } @@ -66,42 +57,42 @@ public open class CompressedTexture3D : Texture3D() { /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _getFormat(): Image.Format { + override fun _getFormat(): Image.Format { throw NotImplementedError("CompressedTexture3D::_getFormat can't be called from the JVM.") } /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _getWidth(): Int { + override fun _getWidth(): Int { throw NotImplementedError("CompressedTexture3D::_getWidth can't be called from the JVM.") } /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _getHeight(): Int { + override fun _getHeight(): Int { throw NotImplementedError("CompressedTexture3D::_getHeight can't be called from the JVM.") } /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _getDepth(): Int { + override fun _getDepth(): Int { throw NotImplementedError("CompressedTexture3D::_getDepth can't be called from the JVM.") } /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _hasMipmaps(): Boolean { + override fun _hasMipmaps(): Boolean { throw NotImplementedError("CompressedTexture3D::_hasMipmaps can't be called from the JVM.") } /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _getData(): VariantArray { + override fun _getData(): VariantArray { throw NotImplementedError("CompressedTexture3D::_getData can't be called from the JVM.") } @@ -109,9 +100,9 @@ public open class CompressedTexture3D : Texture3D() { public object MethodBindings { internal val loadPtr: VoidPtr = - TypeManager.getMethodBindPtr("CompressedTexture3D", "load", 166001499) + TypeManager.getMethodBindPtr("CompressedTexture3D", "load", 166_001_499) internal val getLoadPathPtr: VoidPtr = - TypeManager.getMethodBindPtr("CompressedTexture3D", "get_load_path", 201670096) + TypeManager.getMethodBindPtr("CompressedTexture3D", "get_load_path", 201_670_096) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CompressedTextureLayered.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CompressedTextureLayered.kt index 3d8e13e5af..a8e33ed1dc 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CompressedTextureLayered.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/CompressedTextureLayered.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -19,13 +16,10 @@ import kotlin.Long import kotlin.NotImplementedError import kotlin.String import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * Base class for [CompressedTexture2DArray] and [CompressedTexture3D]. Cannot be used directly, but - * contains all the functions necessary for accessing the derived resource types. See also - * [TextureLayered]. + * Base class for [CompressedTexture2DArray] and [CompressedTexture3D]. Cannot be used directly, but contains all the functions necessary for accessing the derived resource types. See also [TextureLayered]. */ @GodotBaseType public open class CompressedTextureLayered internal constructor() : TextureLayered() { @@ -36,7 +30,7 @@ public open class CompressedTextureLayered internal constructor() : TextureLayer @JvmName("loadPathProperty") get() = getLoadPath() - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(171, scriptIndex) } @@ -58,49 +52,49 @@ public open class CompressedTextureLayered internal constructor() : TextureLayer /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _getFormat(): Image.Format { + override fun _getFormat(): Image.Format { throw NotImplementedError("CompressedTextureLayered::_getFormat can't be called from the JVM.") } /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _getLayeredType(): Long { + override fun _getLayeredType(): Long { throw NotImplementedError("CompressedTextureLayered::_getLayeredType can't be called from the JVM.") } /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _getWidth(): Int { + override fun _getWidth(): Int { throw NotImplementedError("CompressedTextureLayered::_getWidth can't be called from the JVM.") } /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _getHeight(): Int { + override fun _getHeight(): Int { throw NotImplementedError("CompressedTextureLayered::_getHeight can't be called from the JVM.") } /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _getLayers(): Int { + override fun _getLayers(): Int { throw NotImplementedError("CompressedTextureLayered::_getLayers can't be called from the JVM.") } /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _hasMipmaps(): Boolean { + override fun _hasMipmaps(): Boolean { throw NotImplementedError("CompressedTextureLayered::_hasMipmaps can't be called from the JVM.") } /** * Virtual method inherited from base class implemented in non-JVM code. Don't call it. */ - public override fun _getLayerData(layerIndex: Int): Image? { + override fun _getLayerData(layerIndex: Int): Image? { throw NotImplementedError("CompressedTextureLayered::_getLayerData can't be called from the JVM.") } @@ -108,9 +102,9 @@ public open class CompressedTextureLayered internal constructor() : TextureLayer public object MethodBindings { internal val loadPtr: VoidPtr = - TypeManager.getMethodBindPtr("CompressedTextureLayered", "load", 166001499) + TypeManager.getMethodBindPtr("CompressedTextureLayered", "load", 166_001_499) internal val getLoadPathPtr: VoidPtr = - TypeManager.getMethodBindPtr("CompressedTextureLayered", "get_load_path", 201670096) + TypeManager.getMethodBindPtr("CompressedTextureLayered", "get_load_path", 201_670_096) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ConcavePolygonShape2D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ConcavePolygonShape2D.kt index 5d0f06a90b..82dd4fe798 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ConcavePolygonShape2D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ConcavePolygonShape2D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -22,42 +19,24 @@ import kotlin.Unit import kotlin.jvm.JvmName /** - * A 2D polyline shape, intended for use in physics. Used internally in [CollisionPolygon2D] when - * it's in [CollisionPolygon2D.BUILD_SEGMENTS] mode. + * A 2D polyline shape, intended for use in physics. Used internally in [CollisionPolygon2D] when it's in [CollisionPolygon2D.BUILD_SEGMENTS] mode. * - * Being just a collection of interconnected line segments, [ConcavePolygonShape2D] is the most - * freely configurable single 2D shape. It can be used to form polygons of any nature, or even shapes - * that don't enclose an area. However, [ConcavePolygonShape2D] is *hollow* even if the interconnected - * line segments do enclose an area, which often makes it unsuitable for physics or detection. + * Being just a collection of interconnected line segments, [ConcavePolygonShape2D] is the most freely configurable single 2D shape. It can be used to form polygons of any nature, or even shapes that don't enclose an area. However, [ConcavePolygonShape2D] is *hollow* even if the interconnected line segments do enclose an area, which often makes it unsuitable for physics or detection. * - * **Note:** When used for collision, [ConcavePolygonShape2D] is intended to work with static - * [CollisionShape2D] nodes like [StaticBody2D] and will likely not behave well for [CharacterBody2D]s - * or [RigidBody2D]s in a mode other than Static. + * **Note:** When used for collision, [ConcavePolygonShape2D] is intended to work with static [CollisionShape2D] nodes like [StaticBody2D] and will likely not behave well for [CharacterBody2D]s or [RigidBody2D]s in a mode other than Static. * - * **Warning:** Physics bodies that are small have a chance to clip through this shape when moving - * fast. This happens because on one frame, the physics body may be on the "outside" of the shape, and - * on the next frame it may be "inside" it. [ConcavePolygonShape2D] is hollow, so it won't detect a - * collision. + * **Warning:** Physics bodies that are small have a chance to clip through this shape when moving fast. This happens because on one frame, the physics body may be on the "outside" of the shape, and on the next frame it may be "inside" it. [ConcavePolygonShape2D] is hollow, so it won't detect a collision. * - * **Performance:** Due to its complexity, [ConcavePolygonShape2D] is the slowest 2D collision shape - * to check collisions against. Its use should generally be limited to level geometry. If the polyline - * is closed, [CollisionPolygon2D]'s [CollisionPolygon2D.BUILD_SOLIDS] mode can be used, which - * decomposes the polygon into convex ones; see [ConvexPolygonShape2D]'s documentation for - * instructions. + * **Performance:** Due to its complexity, [ConcavePolygonShape2D] is the slowest 2D collision shape to check collisions against. Its use should generally be limited to level geometry. If the polyline is closed, [CollisionPolygon2D]'s [CollisionPolygon2D.BUILD_SOLIDS] mode can be used, which decomposes the polygon into convex ones; see [ConvexPolygonShape2D]'s documentation for instructions. */ @GodotBaseType public open class ConcavePolygonShape2D : Shape2D() { /** - * The array of points that make up the [ConcavePolygonShape2D]'s line segments. The array (of - * length divisible by two) is naturally divided into pairs (one pair for each segment); each pair - * consists of the starting point of a segment and the endpoint of a segment. + * The array of points that make up the [ConcavePolygonShape2D]'s line segments. The array (of length divisible by two) is naturally divided into pairs (one pair for each segment); each pair consists of the starting point of a segment and the endpoint of a segment. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var segments: PackedVector2Array @@ -68,7 +47,7 @@ public open class ConcavePolygonShape2D : Shape2D() { setSegments(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(172, scriptIndex) } @@ -83,29 +62,22 @@ public open class ConcavePolygonShape2D : Shape2D() { * concavepolygonshape2d.segments = myCoreType * `````` * - * The array of points that make up the [ConcavePolygonShape2D]'s line segments. The array (of - * length divisible by two) is naturally divided into pairs (one pair for each segment); each pair - * consists of the starting point of a segment and the endpoint of a segment. + * The array of points that make up the [ConcavePolygonShape2D]'s line segments. The array (of length divisible by two) is naturally divided into pairs (one pair for each segment); each pair consists of the starting point of a segment and the endpoint of a segment. */ @CoreTypeHelper - public final fun segmentsMutate(block: PackedVector2Array.() -> Unit): PackedVector2Array = - segments.apply { + public final fun segmentsMutate(block: PackedVector2Array.() -> Unit): PackedVector2Array = segments.apply { block(this) segments = this } /** * This is a helper function for [segments] to make dealing with local copies easier. - * Allow to directly modify each element of the local copy of the property and assign it back to - * the Object. + * Allow to directly modify each element of the local copy of the property and assign it back to the Object. * - * The array of points that make up the [ConcavePolygonShape2D]'s line segments. The array (of - * length divisible by two) is naturally divided into pairs (one pair for each segment); each pair - * consists of the starting point of a segment and the endpoint of a segment. + * The array of points that make up the [ConcavePolygonShape2D]'s line segments. The array (of length divisible by two) is naturally divided into pairs (one pair for each segment); each pair consists of the starting point of a segment and the endpoint of a segment. */ @CoreTypeHelper - public final fun segmentsMutateEach(block: (index: Int, `value`: Vector2) -> Unit): - PackedVector2Array = segments.apply { + public final fun segmentsMutateEach(block: (index: Int, `value`: Vector2) -> Unit): PackedVector2Array = segments.apply { this.forEachIndexed { index, value -> block(index, value) this[index] = value @@ -113,7 +85,7 @@ public open class ConcavePolygonShape2D : Shape2D() { segments = this } - public final fun setSegments(segments: PackedVector2Array): Unit { + public final fun setSegments(segments: PackedVector2Array) { TransferContext.writeArguments(PACKED_VECTOR2_ARRAY to segments) TransferContext.callMethod(ptr, MethodBindings.setSegmentsPtr, NIL) } @@ -128,9 +100,9 @@ public open class ConcavePolygonShape2D : Shape2D() { public object MethodBindings { internal val setSegmentsPtr: VoidPtr = - TypeManager.getMethodBindPtr("ConcavePolygonShape2D", "set_segments", 1509147220) + TypeManager.getMethodBindPtr("ConcavePolygonShape2D", "set_segments", 1_509_147_220) internal val getSegmentsPtr: VoidPtr = - TypeManager.getMethodBindPtr("ConcavePolygonShape2D", "get_segments", 2961356807) + TypeManager.getMethodBindPtr("ConcavePolygonShape2D", "get_segments", 2_961_356_807) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ConcavePolygonShape3D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ConcavePolygonShape3D.kt index e68e74ac05..be7c69039c 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ConcavePolygonShape3D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ConcavePolygonShape3D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -24,28 +21,15 @@ import kotlin.Unit import kotlin.jvm.JvmName /** - * A 3D trimesh shape, intended for use in physics. Usually used to provide a shape for a - * [CollisionShape3D]. + * A 3D trimesh shape, intended for use in physics. Usually used to provide a shape for a [CollisionShape3D]. * - * Being just a collection of interconnected triangles, [ConcavePolygonShape3D] is the most freely - * configurable single 3D shape. It can be used to form polyhedra of any nature, or even shapes that - * don't enclose a volume. However, [ConcavePolygonShape3D] is *hollow* even if the interconnected - * triangles do enclose a volume, which often makes it unsuitable for physics or detection. + * Being just a collection of interconnected triangles, [ConcavePolygonShape3D] is the most freely configurable single 3D shape. It can be used to form polyhedra of any nature, or even shapes that don't enclose a volume. However, [ConcavePolygonShape3D] is *hollow* even if the interconnected triangles do enclose a volume, which often makes it unsuitable for physics or detection. * - * **Note:** When used for collision, [ConcavePolygonShape3D] is intended to work with static - * [CollisionShape3D] nodes like [StaticBody3D] and will likely not behave well for [CharacterBody3D]s - * or [RigidBody3D]s in a mode other than Static. + * **Note:** When used for collision, [ConcavePolygonShape3D] is intended to work with static [CollisionShape3D] nodes like [StaticBody3D] and will likely not behave well for [CharacterBody3D]s or [RigidBody3D]s in a mode other than Static. * - * **Warning:** Physics bodies that are small have a chance to clip through this shape when moving - * fast. This happens because on one frame, the physics body may be on the "outside" of the shape, and - * on the next frame it may be "inside" it. [ConcavePolygonShape3D] is hollow, so it won't detect a - * collision. + * **Warning:** Physics bodies that are small have a chance to clip through this shape when moving fast. This happens because on one frame, the physics body may be on the "outside" of the shape, and on the next frame it may be "inside" it. [ConcavePolygonShape3D] is hollow, so it won't detect a collision. * - * **Performance:** Due to its complexity, [ConcavePolygonShape3D] is the slowest 3D collision shape - * to check collisions against. Its use should generally be limited to level geometry. For convex - * geometry, [ConvexPolygonShape3D] should be used. For dynamic physics bodies that need concave - * collision, several [ConvexPolygonShape3D]s can be used to represent its collision by using convex - * decomposition; see [ConvexPolygonShape3D]'s documentation for instructions. + * **Performance:** Due to its complexity, [ConcavePolygonShape3D] is the slowest 3D collision shape to check collisions against. Its use should generally be limited to level geometry. For convex geometry, [ConvexPolygonShape3D] should be used. For dynamic physics bodies that need concave collision, several [ConvexPolygonShape3D]s can be used to represent its collision by using convex decomposition; see [ConvexPolygonShape3D]'s documentation for instructions. */ @GodotBaseType public open class ConcavePolygonShape3D : Shape3D() { @@ -53,11 +37,8 @@ public open class ConcavePolygonShape3D : Shape3D() { * * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var `data`: PackedVector3Array @@ -69,8 +50,7 @@ public open class ConcavePolygonShape3D : Shape3D() { } /** - * If set to `true`, collisions occur on both sides of the concave shape faces. Otherwise they - * occur only along the face normals. + * If set to `true`, collisions occur on both sides of the concave shape faces. Otherwise they occur only along the face normals. */ public final inline var backfaceCollision: Boolean @JvmName("backfaceCollisionProperty") @@ -80,7 +60,7 @@ public open class ConcavePolygonShape3D : Shape3D() { setBackfaceCollisionEnabled(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(173, scriptIndex) } @@ -96,20 +76,17 @@ public open class ConcavePolygonShape3D : Shape3D() { * `````` */ @CoreTypeHelper - public final fun dataMutate(block: PackedVector3Array.() -> Unit): PackedVector3Array = - data.apply { + public final fun dataMutate(block: PackedVector3Array.() -> Unit): PackedVector3Array = data.apply { block(this) data = this } /** * This is a helper function for [data] to make dealing with local copies easier. - * Allow to directly modify each element of the local copy of the property and assign it back to - * the Object. + * Allow to directly modify each element of the local copy of the property and assign it back to the Object. */ @CoreTypeHelper - public final fun dataMutateEach(block: (index: Int, `value`: Vector3) -> Unit): PackedVector3Array - = data.apply { + public final fun dataMutateEach(block: (index: Int, `value`: Vector3) -> Unit): PackedVector3Array = data.apply { this.forEachIndexed { index, value -> block(index, value) this[index] = value @@ -118,17 +95,15 @@ public open class ConcavePolygonShape3D : Shape3D() { } /** - * Sets the faces of the trimesh shape from an array of vertices. The [faces] array should be - * composed of triples such that each triple of vertices defines a triangle. + * Sets the faces of the trimesh shape from an array of vertices. The [faces] array should be composed of triples such that each triple of vertices defines a triangle. */ - public final fun setFaces(faces: PackedVector3Array): Unit { + public final fun setFaces(faces: PackedVector3Array) { TransferContext.writeArguments(PACKED_VECTOR3_ARRAY to faces) TransferContext.callMethod(ptr, MethodBindings.setFacesPtr, NIL) } /** - * Returns the faces of the trimesh shape as an array of vertices. The array (of length divisible - * by three) is naturally divided into triples; each triple of vertices defines a triangle. + * Returns the faces of the trimesh shape as an array of vertices. The array (of length divisible by three) is naturally divided into triples; each triple of vertices defines a triangle. */ public final fun getFaces(): PackedVector3Array { TransferContext.writeArguments() @@ -136,7 +111,7 @@ public open class ConcavePolygonShape3D : Shape3D() { return (TransferContext.readReturnValue(PACKED_VECTOR3_ARRAY) as PackedVector3Array) } - public final fun setBackfaceCollisionEnabled(enabled: Boolean): Unit { + public final fun setBackfaceCollisionEnabled(enabled: Boolean) { TransferContext.writeArguments(BOOL to enabled) TransferContext.callMethod(ptr, MethodBindings.setBackfaceCollisionEnabledPtr, NIL) } @@ -151,15 +126,15 @@ public open class ConcavePolygonShape3D : Shape3D() { public object MethodBindings { internal val setFacesPtr: VoidPtr = - TypeManager.getMethodBindPtr("ConcavePolygonShape3D", "set_faces", 334873810) + TypeManager.getMethodBindPtr("ConcavePolygonShape3D", "set_faces", 334_873_810) internal val getFacesPtr: VoidPtr = - TypeManager.getMethodBindPtr("ConcavePolygonShape3D", "get_faces", 497664490) + TypeManager.getMethodBindPtr("ConcavePolygonShape3D", "get_faces", 497_664_490) internal val setBackfaceCollisionEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("ConcavePolygonShape3D", "set_backface_collision_enabled", 2586408642) + TypeManager.getMethodBindPtr("ConcavePolygonShape3D", "set_backface_collision_enabled", 2_586_408_642) internal val isBackfaceCollisionEnabledPtr: VoidPtr = - TypeManager.getMethodBindPtr("ConcavePolygonShape3D", "is_backface_collision_enabled", 36873697) + TypeManager.getMethodBindPtr("ConcavePolygonShape3D", "is_backface_collision_enabled", 36_873_697) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ConeTwistJoint3D.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ConeTwistJoint3D.kt index 3bdfbdea3e..747ab9c281 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ConeTwistJoint3D.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ConeTwistJoint3D.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -18,14 +15,10 @@ import kotlin.Float import kotlin.Int import kotlin.Long import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * A physics joint that connects two 3D physics bodies in a way that simulates a ball-and-socket - * joint. The twist axis is initiated as the X axis of the [ConeTwistJoint3D]. Once the physics bodies - * swing, the twist axis is calculated as the middle of the X axes of the joint in the local space of - * the two physics bodies. Useful for limbs like shoulders and hips, lamps hanging off a ceiling, etc. + * A physics joint that connects two 3D physics bodies in a way that simulates a ball-and-socket joint. The twist axis is initiated as the X axis of the [ConeTwistJoint3D]. Once the physics bodies swing, the twist axis is calculated as the middle of the X axes of the joint in the local space of the two physics bodies. Useful for limbs like shoulders and hips, lamps hanging off a ceiling, etc. */ @GodotBaseType public open class ConeTwistJoint3D : Joint3D() { @@ -73,8 +66,7 @@ public open class ConeTwistJoint3D : Joint3D() { } /** - * The ease with which the joint starts to twist. If it's too low, it takes more force to start - * twisting the joint. + * The ease with which the joint starts to twist. If it's too low, it takes more force to start twisting the joint. */ public final inline var softness: Float @JvmName("softnessProperty") @@ -95,14 +87,14 @@ public open class ConeTwistJoint3D : Joint3D() { setParam(ConeTwistJoint3D.Param.RELAXATION, value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(174, scriptIndex) } /** * Sets the value of the specified parameter. */ - public final fun setParam(`param`: Param, `value`: Float): Unit { + public final fun setParam(`param`: Param, `value`: Float) { TransferContext.writeArguments(LONG to param.id, DOUBLE to value.toDouble()) TransferContext.callMethod(ptr, MethodBindings.setParamPtr, NIL) } @@ -142,8 +134,7 @@ public open class ConeTwistJoint3D : Joint3D() { */ BIAS(2), /** - * The ease with which the joint starts to twist. If it's too low, it takes more force to start - * twisting the joint. + * The ease with which the joint starts to twist. If it's too low, it takes more force to start twisting the joint. */ SOFTNESS(3), /** @@ -170,9 +161,9 @@ public open class ConeTwistJoint3D : Joint3D() { public object MethodBindings { internal val setParamPtr: VoidPtr = - TypeManager.getMethodBindPtr("ConeTwistJoint3D", "set_param", 1062470226) + TypeManager.getMethodBindPtr("ConeTwistJoint3D", "set_param", 1_062_470_226) internal val getParamPtr: VoidPtr = - TypeManager.getMethodBindPtr("ConeTwistJoint3D", "get_param", 2928790850) + TypeManager.getMethodBindPtr("ConeTwistJoint3D", "get_param", 2_928_790_850) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ConfigFile.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ConfigFile.kt index a611cb43fd..9d661073d0 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ConfigFile.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ConfigFile.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -26,12 +23,10 @@ import kotlin.Int import kotlin.Long import kotlin.String import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmOverloads /** - * This helper class can be used to store [Variant] values on the filesystem using INI-style - * formatting. The stored values are identified by a section and a key: + * This helper class can be used to store [Variant] values on the filesystem using INI-style formatting. The stored values are identified by a section and a key: * * [codeblock lang=text] * @@ -44,8 +39,7 @@ import kotlin.jvm.JvmOverloads * a_vector=Vector3(1, 0, 2) * * ``` - * The stored data can be saved to or parsed from a file, though ConfigFile objects can also be used - * directly without accessing the filesystem. + * The stored data can be saved to or parsed from a file, though ConfigFile objects can also be used directly without accessing the filesystem. * The following example shows how to create a simple [ConfigFile] and save it on disc: * * ```gdscript @@ -168,47 +162,34 @@ import kotlin.jvm.JvmOverloads * * ``` * - * Any operation that mutates the ConfigFile such as [setValue], [clear], or [eraseSection], only - * changes what is loaded in memory. If you want to write the change to a file, you have to save the - * changes with [save], [saveEncrypted], or [saveEncryptedPass]. + * Any operation that mutates the ConfigFile such as [setValue], [clear], or [eraseSection], only changes what is loaded in memory. If you want to write the change to a file, you have to save the changes with [save], [saveEncrypted], or [saveEncryptedPass]. * - * Keep in mind that section and property names can't contain spaces. Anything after a space will be - * ignored on save and on load. + * Keep in mind that section and property names can't contain spaces. Anything after a space will be ignored on save and on load. * - * ConfigFiles can also contain manually written comment lines starting with a semicolon (`;`). - * Those lines will be ignored when parsing the file. Note that comments will be lost when saving the - * ConfigFile. This can still be useful for dedicated server configuration files, which are typically - * never overwritten without explicit user action. + * ConfigFiles can also contain manually written comment lines starting with a semicolon (`;`). Those lines will be ignored when parsing the file. Note that comments will be lost when saving the ConfigFile. This can still be useful for dedicated server configuration files, which are typically never overwritten without explicit user action. * - * **Note:** The file extension given to a ConfigFile does not have any impact on its formatting or - * behavior. By convention, the `.cfg` extension is used here, but any other extension such as `.ini` - * is also valid. Since neither `.cfg` nor `.ini` are standardized, Godot's ConfigFile formatting may - * differ from files written by other programs. + * **Note:** The file extension given to a ConfigFile does not have any impact on its formatting or behavior. By convention, the `.cfg` extension is used here, but any other extension such as `.ini` is also valid. Since neither `.cfg` nor `.ini` are standardized, Godot's ConfigFile formatting may differ from files written by other programs. */ @GodotBaseType public open class ConfigFile : RefCounted() { - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(175, scriptIndex) } /** - * Assigns a value to the specified key of the specified section. If either the section or the key - * do not exist, they are created. Passing a `null` value deletes the specified key if it exists, and - * deletes the section if it ends up empty once the key has been removed. + * Assigns a value to the specified key of the specified section. If either the section or the key do not exist, they are created. Passing a `null` value deletes the specified key if it exists, and deletes the section if it ends up empty once the key has been removed. */ public final fun setValue( section: String, key: String, `value`: Any?, - ): Unit { + ) { TransferContext.writeArguments(STRING to section, STRING to key, ANY to value) TransferContext.callMethod(ptr, MethodBindings.setValuePtr, NIL) } /** - * Returns the current value for the specified section and key. If either the section or the key - * do not exist, the method returns the fallback [default] value. If [default] is not specified or - * set to `null`, an error is also raised. + * Returns the current value for the specified section and key. If either the section or the key do not exist, the method returns the fallback [default] value. If [default] is not specified or set to `null`, an error is also raised. */ @JvmOverloads public final fun getValue( @@ -249,8 +230,7 @@ public open class ConfigFile : RefCounted() { } /** - * Returns an array of all defined key identifiers in the specified section. Raises an error and - * returns an empty array if the section does not exist. + * Returns an array of all defined key identifiers in the specified section. Raises an error and returns an empty array if the section does not exist. */ public final fun getSectionKeys(section: String): PackedStringArray { TransferContext.writeArguments(STRING to section) @@ -259,26 +239,23 @@ public open class ConfigFile : RefCounted() { } /** - * Deletes the specified section along with all the key-value pairs inside. Raises an error if the - * section does not exist. + * Deletes the specified section along with all the key-value pairs inside. Raises an error if the section does not exist. */ - public final fun eraseSection(section: String): Unit { + public final fun eraseSection(section: String) { TransferContext.writeArguments(STRING to section) TransferContext.callMethod(ptr, MethodBindings.eraseSectionPtr, NIL) } /** - * Deletes the specified key in a section. Raises an error if either the section or the key do not - * exist. + * Deletes the specified key in a section. Raises an error if either the section or the key do not exist. */ - public final fun eraseSectionKey(section: String, key: String): Unit { + public final fun eraseSectionKey(section: String, key: String) { TransferContext.writeArguments(STRING to section, STRING to key) TransferContext.callMethod(ptr, MethodBindings.eraseSectionKeyPtr, NIL) } /** - * Loads the config file specified as a parameter. The file's contents are parsed and loaded in - * the [ConfigFile] object which the method was called on. + * Loads the config file specified as a parameter. The file's contents are parsed and loaded in the [ConfigFile] object which the method was called on. * * Returns [OK] on success, or one of the other [Error] values if the operation failed. */ @@ -289,8 +266,7 @@ public open class ConfigFile : RefCounted() { } /** - * Parses the passed string as the contents of a config file. The string is parsed and loaded in - * the ConfigFile object which the method was called on. + * Parses the passed string as the contents of a config file. The string is parsed and loaded in the ConfigFile object which the method was called on. * * Returns [OK] on success, or one of the other [Error] values if the operation failed. */ @@ -301,8 +277,7 @@ public open class ConfigFile : RefCounted() { } /** - * Saves the contents of the [ConfigFile] object to the file specified as a parameter. The output - * file uses an INI-style structure. + * Saves the contents of the [ConfigFile] object to the file specified as a parameter. The output file uses an INI-style structure. * * Returns [OK] on success, or one of the other [Error] values if the operation failed. */ @@ -322,9 +297,7 @@ public open class ConfigFile : RefCounted() { } /** - * Loads the encrypted config file specified as a parameter, using the provided [key] to decrypt - * it. The file's contents are parsed and loaded in the [ConfigFile] object which the method was - * called on. + * Loads the encrypted config file specified as a parameter, using the provided [key] to decrypt it. The file's contents are parsed and loaded in the [ConfigFile] object which the method was called on. * * Returns [OK] on success, or one of the other [Error] values if the operation failed. */ @@ -335,9 +308,7 @@ public open class ConfigFile : RefCounted() { } /** - * Loads the encrypted config file specified as a parameter, using the provided [password] to - * decrypt it. The file's contents are parsed and loaded in the [ConfigFile] object which the method - * was called on. + * Loads the encrypted config file specified as a parameter, using the provided [password] to decrypt it. The file's contents are parsed and loaded in the [ConfigFile] object which the method was called on. * * Returns [OK] on success, or one of the other [Error] values if the operation failed. */ @@ -348,8 +319,7 @@ public open class ConfigFile : RefCounted() { } /** - * Saves the contents of the [ConfigFile] object to the AES-256 encrypted file specified as a - * parameter, using the provided [key] to encrypt it. The output file uses an INI-style structure. + * Saves the contents of the [ConfigFile] object to the AES-256 encrypted file specified as a parameter, using the provided [key] to encrypt it. The output file uses an INI-style structure. * * Returns [OK] on success, or one of the other [Error] values if the operation failed. */ @@ -360,9 +330,7 @@ public open class ConfigFile : RefCounted() { } /** - * Saves the contents of the [ConfigFile] object to the AES-256 encrypted file specified as a - * parameter, using the provided [password] to encrypt it. The output file uses an INI-style - * structure. + * Saves the contents of the [ConfigFile] object to the AES-256 encrypted file specified as a parameter, using the provided [password] to encrypt it. The output file uses an INI-style structure. * * Returns [OK] on success, or one of the other [Error] values if the operation failed. */ @@ -375,7 +343,7 @@ public open class ConfigFile : RefCounted() { /** * Removes the entire contents of the config. */ - public final fun clear(): Unit { + public final fun clear() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.clearPtr, NIL) } @@ -384,50 +352,52 @@ public open class ConfigFile : RefCounted() { public object MethodBindings { internal val setValuePtr: VoidPtr = - TypeManager.getMethodBindPtr("ConfigFile", "set_value", 2504492430) + TypeManager.getMethodBindPtr("ConfigFile", "set_value", 2_504_492_430) internal val getValuePtr: VoidPtr = - TypeManager.getMethodBindPtr("ConfigFile", "get_value", 89809366) + TypeManager.getMethodBindPtr("ConfigFile", "get_value", 89_809_366) internal val hasSectionPtr: VoidPtr = - TypeManager.getMethodBindPtr("ConfigFile", "has_section", 3927539163) + TypeManager.getMethodBindPtr("ConfigFile", "has_section", 3_927_539_163) internal val hasSectionKeyPtr: VoidPtr = - TypeManager.getMethodBindPtr("ConfigFile", "has_section_key", 820780508) + TypeManager.getMethodBindPtr("ConfigFile", "has_section_key", 820_780_508) internal val getSectionsPtr: VoidPtr = - TypeManager.getMethodBindPtr("ConfigFile", "get_sections", 1139954409) + TypeManager.getMethodBindPtr("ConfigFile", "get_sections", 1_139_954_409) internal val getSectionKeysPtr: VoidPtr = - TypeManager.getMethodBindPtr("ConfigFile", "get_section_keys", 4291131558) + TypeManager.getMethodBindPtr("ConfigFile", "get_section_keys", 4_291_131_558) internal val eraseSectionPtr: VoidPtr = - TypeManager.getMethodBindPtr("ConfigFile", "erase_section", 83702148) + TypeManager.getMethodBindPtr("ConfigFile", "erase_section", 83_702_148) internal val eraseSectionKeyPtr: VoidPtr = - TypeManager.getMethodBindPtr("ConfigFile", "erase_section_key", 3186203200) + TypeManager.getMethodBindPtr("ConfigFile", "erase_section_key", 3_186_203_200) - internal val loadPtr: VoidPtr = TypeManager.getMethodBindPtr("ConfigFile", "load", 166001499) + internal val loadPtr: VoidPtr = TypeManager.getMethodBindPtr("ConfigFile", "load", 166_001_499) - internal val parsePtr: VoidPtr = TypeManager.getMethodBindPtr("ConfigFile", "parse", 166001499) + internal val parsePtr: VoidPtr = + TypeManager.getMethodBindPtr("ConfigFile", "parse", 166_001_499) - internal val savePtr: VoidPtr = TypeManager.getMethodBindPtr("ConfigFile", "save", 166001499) + internal val savePtr: VoidPtr = TypeManager.getMethodBindPtr("ConfigFile", "save", 166_001_499) internal val encodeToTextPtr: VoidPtr = - TypeManager.getMethodBindPtr("ConfigFile", "encode_to_text", 201670096) + TypeManager.getMethodBindPtr("ConfigFile", "encode_to_text", 201_670_096) internal val loadEncryptedPtr: VoidPtr = - TypeManager.getMethodBindPtr("ConfigFile", "load_encrypted", 887037711) + TypeManager.getMethodBindPtr("ConfigFile", "load_encrypted", 887_037_711) internal val loadEncryptedPassPtr: VoidPtr = - TypeManager.getMethodBindPtr("ConfigFile", "load_encrypted_pass", 852856452) + TypeManager.getMethodBindPtr("ConfigFile", "load_encrypted_pass", 852_856_452) internal val saveEncryptedPtr: VoidPtr = - TypeManager.getMethodBindPtr("ConfigFile", "save_encrypted", 887037711) + TypeManager.getMethodBindPtr("ConfigFile", "save_encrypted", 887_037_711) internal val saveEncryptedPassPtr: VoidPtr = - TypeManager.getMethodBindPtr("ConfigFile", "save_encrypted_pass", 852856452) + TypeManager.getMethodBindPtr("ConfigFile", "save_encrypted_pass", 852_856_452) - internal val clearPtr: VoidPtr = TypeManager.getMethodBindPtr("ConfigFile", "clear", 3218959716) + internal val clearPtr: VoidPtr = + TypeManager.getMethodBindPtr("ConfigFile", "clear", 3_218_959_716) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ConfirmationDialog.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ConfirmationDialog.kt index 4bb1050bc6..a7a862cfd2 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ConfirmationDialog.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/ConfirmationDialog.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -16,13 +13,10 @@ import godot.core.VariantParser.STRING import kotlin.Int import kotlin.String import kotlin.Suppress -import kotlin.Unit import kotlin.jvm.JvmName /** - * A dialog used for confirmation of actions. This window is similar to [AcceptDialog], but pressing - * its Cancel button can have a different outcome from pressing the OK button. The order of the two - * buttons varies depending on the host OS. + * A dialog used for confirmation of actions. This window is similar to [AcceptDialog], but pressing its Cancel button can have a different outcome from pressing the OK button. The order of the two buttons varies depending on the host OS. * * To get cancel action, you can use: * @@ -49,15 +43,14 @@ public open class ConfirmationDialog : AcceptDialog() { setCancelButtonText(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(176, scriptIndex) } /** * Returns the cancel button. * - * **Warning:** This is a required internal node, removing and freeing it may cause a crash. If - * you wish to hide it or any of its children, use their [CanvasItem.visible] property. + * **Warning:** This is a required internal node, removing and freeing it may cause a crash. If you wish to hide it or any of its children, use their [CanvasItem.visible] property. */ public final fun getCancelButton(): Button? { TransferContext.writeArguments() @@ -65,7 +58,7 @@ public open class ConfirmationDialog : AcceptDialog() { return (TransferContext.readReturnValue(OBJECT) as Button?) } - public final fun setCancelButtonText(text: String): Unit { + public final fun setCancelButtonText(text: String) { TransferContext.writeArguments(STRING to text) TransferContext.callMethod(ptr, MethodBindings.setCancelButtonTextPtr, NIL) } @@ -80,12 +73,12 @@ public open class ConfirmationDialog : AcceptDialog() { public object MethodBindings { internal val getCancelButtonPtr: VoidPtr = - TypeManager.getMethodBindPtr("ConfirmationDialog", "get_cancel_button", 1856205918) + TypeManager.getMethodBindPtr("ConfirmationDialog", "get_cancel_button", 1_856_205_918) internal val setCancelButtonTextPtr: VoidPtr = - TypeManager.getMethodBindPtr("ConfirmationDialog", "set_cancel_button_text", 83702148) + TypeManager.getMethodBindPtr("ConfirmationDialog", "set_cancel_button_text", 83_702_148) internal val getCancelButtonTextPtr: VoidPtr = - TypeManager.getMethodBindPtr("ConfirmationDialog", "get_cancel_button_text", 201670096) + TypeManager.getMethodBindPtr("ConfirmationDialog", "get_cancel_button_text", 201_670_096) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Container.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Container.kt index 7c8ff9efd3..9016493004 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Container.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Container.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -20,11 +17,9 @@ import kotlin.Int import kotlin.Long import kotlin.NotImplementedError import kotlin.Suppress -import kotlin.Unit /** - * Base class for all GUI containers. A [Container] automatically arranges its child controls in a - * certain way. This class can be inherited to make custom container types. + * Base class for all GUI containers. A [Container] automatically arranges its child controls in a certain way. This class can be inherited to make custom container types. */ @GodotBaseType public open class Container : Control() { @@ -38,56 +33,47 @@ public open class Container : Control() { */ public val sortChildren: Signal0 by Signal0 - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(177, scriptIndex) } /** - * Implement to return a list of allowed horizontal [Control.SizeFlags] for child nodes. This - * doesn't technically prevent the usages of any other size flags, if your implementation requires - * that. This only limits the options available to the user in the Inspector dock. + * Implement to return a list of allowed horizontal [Control.SizeFlags] for child nodes. This doesn't technically prevent the usages of any other size flags, if your implementation requires that. This only limits the options available to the user in the Inspector dock. * - * **Note:** Having no size flags is equal to having [Control.SIZE_SHRINK_BEGIN]. As such, this - * value is always implicitly allowed. + * **Note:** Having no size flags is equal to having [Control.SIZE_SHRINK_BEGIN]. As such, this value is always implicitly allowed. */ public open fun _getAllowedSizeFlagsHorizontal(): PackedInt32Array { throw NotImplementedError("Container::_getAllowedSizeFlagsHorizontal is not implemented.") } /** - * Implement to return a list of allowed vertical [Control.SizeFlags] for child nodes. This - * doesn't technically prevent the usages of any other size flags, if your implementation requires - * that. This only limits the options available to the user in the Inspector dock. + * Implement to return a list of allowed vertical [Control.SizeFlags] for child nodes. This doesn't technically prevent the usages of any other size flags, if your implementation requires that. This only limits the options available to the user in the Inspector dock. * - * **Note:** Having no size flags is equal to having [Control.SIZE_SHRINK_BEGIN]. As such, this - * value is always implicitly allowed. + * **Note:** Having no size flags is equal to having [Control.SIZE_SHRINK_BEGIN]. As such, this value is always implicitly allowed. */ public open fun _getAllowedSizeFlagsVertical(): PackedInt32Array { throw NotImplementedError("Container::_getAllowedSizeFlagsVertical is not implemented.") } /** - * Queue resort of the contained children. This is called automatically anyway, but can be called - * upon request. + * Queue resort of the contained children. This is called automatically anyway, but can be called upon request. */ - public final fun queueSort(): Unit { + public final fun queueSort() { TransferContext.writeArguments() TransferContext.callMethod(ptr, MethodBindings.queueSortPtr, NIL) } /** - * Fit a child control in a given rect. This is mainly a helper for creating custom container - * classes. + * Fit a child control in a given rect. This is mainly a helper for creating custom container classes. */ - public final fun fitChildInRect(child: Control?, rect: Rect2): Unit { + public final fun fitChildInRect(child: Control?, rect: Rect2) { TransferContext.writeArguments(OBJECT to child, RECT2 to rect) TransferContext.callMethod(ptr, MethodBindings.fitChildInRectPtr, NIL) } public companion object { /** - * Notification just before children are going to be sorted, in case there's something to - * process beforehand. + * Notification just before children are going to be sorted, in case there's something to process beforehand. */ public final const val NOTIFICATION_PRE_SORT_CHILDREN: Long = 50 @@ -99,9 +85,9 @@ public open class Container : Control() { public object MethodBindings { internal val queueSortPtr: VoidPtr = - TypeManager.getMethodBindPtr("Container", "queue_sort", 3218959716) + TypeManager.getMethodBindPtr("Container", "queue_sort", 3_218_959_716) internal val fitChildInRectPtr: VoidPtr = - TypeManager.getMethodBindPtr("Container", "fit_child_in_rect", 1993438598) + TypeManager.getMethodBindPtr("Container", "fit_child_in_rect", 1_993_438_598) } } diff --git a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Control.kt b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Control.kt index 80f5370ebd..bff60ade45 100644 --- a/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Control.kt +++ b/kt/godot-library/godot-api-library/src/main/kotlin/godot/api/Control.kt @@ -1,8 +1,5 @@ // THIS FILE IS GENERATED! DO NOT EDIT IT MANUALLY! -@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", - "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", - "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", - "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") +@file:Suppress("PackageDirectoryMismatch", "unused", "FunctionName", "RedundantModalityModifier", "UNCHECKED_CAST", "JoinDeclarationAndAssignment", "USELESS_CAST", "RemoveRedundantQualifierName", "NOTHING_TO_INLINE", "NON_FINAL_MEMBER_IN_OBJECT", "RedundantVisibilityModifier", "RedundantUnitReturnType", "MemberVisibilityCanBePrivate") package godot.api @@ -59,47 +56,27 @@ public infix fun Long.xor(other: Control.SizeFlags): Long = this.xor(other.flag) public infix fun Long.and(other: Control.SizeFlags): Long = this.and(other.flag) /** - * Base class for all UI-related nodes. [Control] features a bounding rectangle that defines its - * extents, an anchor position relative to its parent control or the current viewport, and offsets - * relative to the anchor. The offsets update automatically when the node, any of its parents, or the - * screen size change. + * Base class for all UI-related nodes. [Control] features a bounding rectangle that defines its extents, an anchor position relative to its parent control or the current viewport, and offsets relative to the anchor. The offsets update automatically when the node, any of its parents, or the screen size change. * - * For more information on Godot's UI system, anchors, offsets, and containers, see the related - * tutorials in the manual. To build flexible UIs, you'll need a mix of UI elements that inherit from - * [Control] and [Container] nodes. + * For more information on Godot's UI system, anchors, offsets, and containers, see the related tutorials in the manual. To build flexible UIs, you'll need a mix of UI elements that inherit from [Control] and [Container] nodes. * - * **Note:** Since both [Node2D] and [Control] inherit from [CanvasItem], they share several - * concepts from the class such as the [CanvasItem.zIndex] and [CanvasItem.visible] properties. + * **Note:** Since both [Node2D] and [Control] inherit from [CanvasItem], they share several concepts from the class such as the [CanvasItem.zIndex] and [CanvasItem.visible] properties. * * **User Interface nodes and input** * - * Godot propagates input events via viewports. Each [Viewport] is responsible for propagating - * [InputEvent]s to their child nodes. As the [SceneTree.root] is a [Window], this already happens - * automatically for all UI elements in your game. + * Godot propagates input events via viewports. Each [Viewport] is responsible for propagating [InputEvent]s to their child nodes. As the [SceneTree.root] is a [Window], this already happens automatically for all UI elements in your game. * - * Input events are propagated through the [SceneTree] from the root node to all child nodes by - * calling [Node.Input]. For UI elements specifically, it makes more sense to override the virtual - * method [_guiInput], which filters out unrelated input events, such as by checking z-order, - * [mouseFilter], focus, or if the event was inside of the control's bounding box. + * Input events are propagated through the [SceneTree] from the root node to all child nodes by calling [Node.Input]. For UI elements specifically, it makes more sense to override the virtual method [_guiInput], which filters out unrelated input events, such as by checking z-order, [mouseFilter], focus, or if the event was inside of the control's bounding box. * - * Call [acceptEvent] so no other node receives the event. Once you accept an input, it becomes - * handled so [Node.UnhandledInput] will not process it. + * Call [acceptEvent] so no other node receives the event. Once you accept an input, it becomes handled so [Node.UnhandledInput] will not process it. * - * Only one [Control] node can be in focus. Only the node in focus will receive events. To get the - * focus, call [grabFocus]. [Control] nodes lose focus when another node grabs it, or if you hide the - * node in focus. + * Only one [Control] node can be in focus. Only the node in focus will receive events. To get the focus, call [grabFocus]. [Control] nodes lose focus when another node grabs it, or if you hide the node in focus. * - * Sets [mouseFilter] to [MOUSE_FILTER_IGNORE] to tell a [Control] node to ignore mouse or touch - * events. You'll need it if you place an icon on top of a button. + * Sets [mouseFilter] to [MOUSE_FILTER_IGNORE] to tell a [Control] node to ignore mouse or touch events. You'll need it if you place an icon on top of a button. * - * [Theme] resources change the control's appearance. The [theme] of a [Control] node affects all of - * its direct and indirect children (as long as a chain of controls is uninterrupted). To override some - * of the theme items, call one of the `add_theme_*_override` methods, like [addThemeFontOverride]. You - * can also override theme items in the Inspector. + * [Theme] resources change the control's appearance. The [theme] of a [Control] node affects all of its direct and indirect children (as long as a chain of controls is uninterrupted). To override some of the theme items, call one of the `add_theme_*_override` methods, like [addThemeFontOverride]. You can also override theme items in the Inspector. * - * **Note:** Theme items are *not* [Object] properties. This means you can't access their values - * using [Object.get] and [Object.set]. Instead, use the `get_theme_*` and `add_theme_*_override` - * methods provided by this class. + * **Note:** Theme items are *not* [Object] properties. This means you can't access their values using [Object.get] and [Object.set]. Instead, use the `get_theme_*` and `add_theme_*_override` methods provided by this class. */ @GodotBaseType public open class Control : CanvasItem() { @@ -114,23 +91,18 @@ public open class Control : CanvasItem() { public val guiInput: Signal1 by Signal1 /** - * Emitted when the mouse cursor enters the control's (or any child control's) visible area, that - * is not occluded behind other Controls or Windows, provided its [mouseFilter] lets the event reach - * it and regardless if it's currently focused or not. + * Emitted when the mouse cursor enters the control's (or any child control's) visible area, that is not occluded behind other Controls or Windows, provided its [mouseFilter] lets the event reach it and regardless if it's currently focused or not. * * **Note:** [CanvasItem.zIndex] doesn't affect, which Control receives the signal. */ public val mouseEntered: Signal0 by Signal0 /** - * Emitted when the mouse cursor leaves the control's (and all child control's) visible area, that - * is not occluded behind other Controls or Windows, provided its [mouseFilter] lets the event reach - * it and regardless if it's currently focused or not. + * Emitted when the mouse cursor leaves the control's (and all child control's) visible area, that is not occluded behind other Controls or Windows, provided its [mouseFilter] lets the event reach it and regardless if it's currently focused or not. * * **Note:** [CanvasItem.zIndex] doesn't affect, which Control receives the signal. * - * **Note:** If you want to check whether the mouse truly left the area, ignoring any top nodes, - * you can use code like this: + * **Note:** If you want to check whether the mouse truly left the area, ignoring any top nodes, you can use code like this: * * ``` * func _on_mouse_exited(): @@ -166,9 +138,7 @@ public open class Control : CanvasItem() { public val themeChanged: Signal0 by Signal0 /** - * Enables whether rendering of [CanvasItem] based children should be clipped to this control's - * rectangle. If `true`, parts of a child which would be visibly outside of this control's rectangle - * will not be rendered and won't receive input. + * Enables whether rendering of [CanvasItem] based children should be clipped to this control's rectangle. If `true`, parts of a child which would be visibly outside of this control's rectangle will not be rendered and won't receive input. */ public final inline var clipContents: Boolean @JvmName("clipContentsProperty") @@ -179,18 +149,11 @@ public open class Control : CanvasItem() { } /** - * The minimum size of the node's bounding rectangle. If you set it to a value greater than `(0, - * 0)`, the node's bounding rectangle will always have at least this size. Note that [Control] nodes - * have their internal minimum size returned by [getMinimumSize]. It depends on the control's - * contents, like text, textures, or style boxes. The actual minimum size is the maximum value of - * this property and the internal minimum size (see [getCombinedMinimumSize]). + * The minimum size of the node's bounding rectangle. If you set it to a value greater than `(0, 0)`, the node's bounding rectangle will always have at least this size. Note that [Control] nodes have their internal minimum size returned by [getMinimumSize]. It depends on the control's contents, like text, textures, or style boxes. The actual minimum size is the maximum value of this property and the internal minimum size (see [getCombinedMinimumSize]). * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var customMinimumSize: Vector2 @@ -202,8 +165,7 @@ public open class Control : CanvasItem() { } /** - * Controls layout direction and text writing direction. Right-to-left layouts are necessary for - * certain languages (e.g. Arabic and Hebrew). See also [isLayoutRtl]. + * Controls layout direction and text writing direction. Right-to-left layouts are necessary for certain languages (e.g. Arabic and Hebrew). See also [isLayoutRtl]. */ public final inline var layoutDirection: LayoutDirection @JvmName("layoutDirectionProperty") @@ -214,36 +176,28 @@ public open class Control : CanvasItem() { } /** - * Anchors the left edge of the node to the origin, the center or the end of its parent control. - * It changes how the left offset updates when the node moves or changes size. You can use one of the - * [Anchor] constants for convenience. + * Anchors the left edge of the node to the origin, the center or the end of its parent control. It changes how the left offset updates when the node moves or changes size. You can use one of the [Anchor] constants for convenience. */ public final inline val anchorLeft: Float @JvmName("anchorLeftProperty") get() = getAnchor(Side.LEFT) /** - * Anchors the top edge of the node to the origin, the center or the end of its parent control. It - * changes how the top offset updates when the node moves or changes size. You can use one of the - * [Anchor] constants for convenience. + * Anchors the top edge of the node to the origin, the center or the end of its parent control. It changes how the top offset updates when the node moves or changes size. You can use one of the [Anchor] constants for convenience. */ public final inline val anchorTop: Float @JvmName("anchorTopProperty") get() = getAnchor(Side.TOP) /** - * Anchors the right edge of the node to the origin, the center or the end of its parent control. - * It changes how the right offset updates when the node moves or changes size. You can use one of - * the [Anchor] constants for convenience. + * Anchors the right edge of the node to the origin, the center or the end of its parent control. It changes how the right offset updates when the node moves or changes size. You can use one of the [Anchor] constants for convenience. */ public final inline val anchorRight: Float @JvmName("anchorRightProperty") get() = getAnchor(Side.RIGHT) /** - * Anchors the bottom edge of the node to the origin, the center, or the end of its parent - * control. It changes how the bottom offset updates when the node moves or changes size. You can use - * one of the [Anchor] constants for convenience. + * Anchors the bottom edge of the node to the origin, the center, or the end of its parent control. It changes how the bottom offset updates when the node moves or changes size. You can use one of the [Anchor] constants for convenience. */ public final inline val anchorBottom: Float @JvmName("anchorBottomProperty") @@ -252,9 +206,7 @@ public open class Control : CanvasItem() { /** * Distance between the node's left edge and its parent control, based on [anchorLeft]. * - * Offsets are often controlled by one or multiple parent [Container] nodes, so you should not - * modify them manually if your node is a direct child of a [Container]. Offsets update automatically - * when you move or resize the node. + * Offsets are often controlled by one or multiple parent [Container] nodes, so you should not modify them manually if your node is a direct child of a [Container]. Offsets update automatically when you move or resize the node. */ public final inline var offsetLeft: Float @JvmName("offsetLeftProperty") @@ -267,9 +219,7 @@ public open class Control : CanvasItem() { /** * Distance between the node's top edge and its parent control, based on [anchorTop]. * - * Offsets are often controlled by one or multiple parent [Container] nodes, so you should not - * modify them manually if your node is a direct child of a [Container]. Offsets update automatically - * when you move or resize the node. + * Offsets are often controlled by one or multiple parent [Container] nodes, so you should not modify them manually if your node is a direct child of a [Container]. Offsets update automatically when you move or resize the node. */ public final inline var offsetTop: Float @JvmName("offsetTopProperty") @@ -282,9 +232,7 @@ public open class Control : CanvasItem() { /** * Distance between the node's right edge and its parent control, based on [anchorRight]. * - * Offsets are often controlled by one or multiple parent [Container] nodes, so you should not - * modify them manually if your node is a direct child of a [Container]. Offsets update automatically - * when you move or resize the node. + * Offsets are often controlled by one or multiple parent [Container] nodes, so you should not modify them manually if your node is a direct child of a [Container]. Offsets update automatically when you move or resize the node. */ public final inline var offsetRight: Float @JvmName("offsetRightProperty") @@ -297,9 +245,7 @@ public open class Control : CanvasItem() { /** * Distance between the node's bottom edge and its parent control, based on [anchorBottom]. * - * Offsets are often controlled by one or multiple parent [Container] nodes, so you should not - * modify them manually if your node is a direct child of a [Container]. Offsets update automatically - * when you move or resize the node. + * Offsets are often controlled by one or multiple parent [Container] nodes, so you should not modify them manually if your node is a direct child of a [Container]. Offsets update automatically when you move or resize the node. */ public final inline var offsetBottom: Float @JvmName("offsetBottomProperty") @@ -310,9 +256,7 @@ public open class Control : CanvasItem() { } /** - * Controls the direction on the horizontal axis in which the control should grow if its - * horizontal minimum size is changed to be greater than its current size, as the control always has - * to be at least the minimum size. + * Controls the direction on the horizontal axis in which the control should grow if its horizontal minimum size is changed to be greater than its current size, as the control always has to be at least the minimum size. */ public final inline var growHorizontal: GrowDirection @JvmName("growHorizontalProperty") @@ -323,9 +267,7 @@ public open class Control : CanvasItem() { } /** - * Controls the direction on the vertical axis in which the control should grow if its vertical - * minimum size is changed to be greater than its current size, as the control always has to be at - * least the minimum size. + * Controls the direction on the vertical axis in which the control should grow if its vertical minimum size is changed to be greater than its current size, as the control always has to be at least the minimum size. */ public final inline var growVertical: GrowDirection @JvmName("growVerticalProperty") @@ -336,16 +278,14 @@ public open class Control : CanvasItem() { } /** - * The size of the node's bounding rectangle, in the node's coordinate system. [Container] nodes - * update this property automatically. + * The size of the node's bounding rectangle, in the node's coordinate system. [Container] nodes update this property automatically. */ public final inline val size: Vector2 @JvmName("sizeProperty") get() = getSize() /** - * The node's position, relative to its containing node. It corresponds to the rectangle's - * top-left corner. The property is not affected by [pivotOffset]. + * The node's position, relative to its containing node. It corresponds to the rectangle's top-left corner. The property is not affected by [pivotOffset]. */ public final inline val position: Vector2 @JvmName("positionProperty") @@ -359,11 +299,9 @@ public open class Control : CanvasItem() { get() = getGlobalPosition() /** - * The node's rotation around its pivot, in radians. See [pivotOffset] to change the pivot's - * position. + * The node's rotation around its pivot, in radians. See [pivotOffset] to change the pivot's position. * - * **Note:** This property is edited in the inspector in degrees. If you want to use degrees in a - * script, use [rotationDegrees]. + * **Note:** This property is edited in the inspector in degrees. If you want to use degrees in a script, use [rotationDegrees]. */ public final inline var rotation: Float @JvmName("rotationProperty") @@ -385,32 +323,17 @@ public open class Control : CanvasItem() { } /** - * The node's scale, relative to its [size]. Change this property to scale the node around its - * [pivotOffset]. The Control's [tooltipText] will also scale according to this value. + * The node's scale, relative to its [size]. Change this property to scale the node around its [pivotOffset]. The Control's [tooltipText] will also scale according to this value. * - * **Note:** This property is mainly intended to be used for animation purposes. To support - * multiple resolutions in your project, use an appropriate viewport stretch mode as described in the - * [url=$DOCS_URL/tutorials/rendering/multiple_resolutions.html]documentation[/url] instead of - * scaling Controls individually. + * **Note:** This property is mainly intended to be used for animation purposes. To support multiple resolutions in your project, use an appropriate viewport stretch mode as described in the [url=$DOCS_URL/tutorials/rendering/multiple_resolutions.html]documentation[/url] instead of scaling Controls individually. * - * **Note:** [FontFile.oversampling] does *not* take [Control] [scale] into account. This means - * that scaling up/down will cause bitmap fonts and rasterized (non-MSDF) dynamic fonts to appear - * blurry or pixelated. To ensure text remains crisp regardless of scale, you can enable MSDF font - * rendering by enabling [ProjectSettings.gui/theme/defaultFontMultichannelSignedDistanceField] - * (applies to the default project font only), or enabling **Multichannel Signed Distance Field** in - * the import options of a DynamicFont for custom fonts. On system fonts, - * [SystemFont.multichannelSignedDistanceField] can be enabled in the inspector. + * **Note:** [FontFile.oversampling] does *not* take [Control] [scale] into account. This means that scaling up/down will cause bitmap fonts and rasterized (non-MSDF) dynamic fonts to appear blurry or pixelated. To ensure text remains crisp regardless of scale, you can enable MSDF font rendering by enabling [ProjectSettings.gui/theme/defaultFontMultichannelSignedDistanceField] (applies to the default project font only), or enabling **Multichannel Signed Distance Field** in the import options of a DynamicFont for custom fonts. On system fonts, [SystemFont.multichannelSignedDistanceField] can be enabled in the inspector. * - * **Note:** If the Control node is a child of a [Container] node, the scale will be reset to - * `Vector2(1, 1)` when the scene is instantiated. To set the Control's scale when it's instantiated, - * wait for one frame using `await get_tree().process_frame` then set its [scale] property. + * **Note:** If the Control node is a child of a [Container] node, the scale will be reset to `Vector2(1, 1)` when the scene is instantiated. To set the Control's scale when it's instantiated, wait for one frame using `await get_tree().process_frame` then set its [scale] property. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var scale: Vector2 @@ -422,16 +345,11 @@ public open class Control : CanvasItem() { } /** - * By default, the node's pivot is its top-left corner. When you change its [rotation] or [scale], - * it will rotate or scale around this pivot. Set this property to [size] / 2 to pivot around the - * Control's center. + * By default, the node's pivot is its top-left corner. When you change its [rotation] or [scale], it will rotate or scale around this pivot. Set this property to [size] / 2 to pivot around the Control's center. * * **Warning:** - * Be careful when trying to modify a local - * [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this - * getter. - * Mutating it alone won't have any effect on the actual property, it has to be reassigned again - * afterward. + * Be careful when trying to modify a local [copy](https://godot-kotl.in/en/stable/user-guide/api-differences/#core-types) obtained from this getter. + * Mutating it alone won't have any effect on the actual property, it has to be reassigned again afterward. */ @CoreTypeLocalCopy public final inline var pivotOffset: Vector2 @@ -443,9 +361,7 @@ public open class Control : CanvasItem() { } /** - * Tells the parent [Container] nodes how they should resize and place the node on the X axis. Use - * a combination of the [SizeFlags] constants to change the flags. See the constants to learn what - * each does. + * Tells the parent [Container] nodes how they should resize and place the node on the X axis. Use a combination of the [SizeFlags] constants to change the flags. See the constants to learn what each does. */ public final inline var sizeFlagsHorizontal: SizeFlags @JvmName("sizeFlagsHorizontalProperty") @@ -456,9 +372,7 @@ public open class Control : CanvasItem() { } /** - * Tells the parent [Container] nodes how they should resize and place the node on the Y axis. Use - * a combination of the [SizeFlags] constants to change the flags. See the constants to learn what - * each does. + * Tells the parent [Container] nodes how they should resize and place the node on the Y axis. Use a combination of the [SizeFlags] constants to change the flags. See the constants to learn what each does. */ public final inline var sizeFlagsVertical: SizeFlags @JvmName("sizeFlagsVerticalProperty") @@ -469,10 +383,7 @@ public open class Control : CanvasItem() { } /** - * If the node and at least one of its neighbors uses the [SIZE_EXPAND] size flag, the parent - * [Container] will let it take more or less space depending on this property. If this node has a - * stretch ratio of 2 and its neighbor a ratio of 1, this node will take two thirds of the available - * space. + * If the node and at least one of its neighbors uses the [SIZE_EXPAND] size flag, the parent [Container] will let it take more or less space depending on this property. If this node has a stretch ratio of 2 and its neighbor a ratio of 1, this node will take two thirds of the available space. */ public final inline var sizeFlagsStretchRatio: Float @JvmName("sizeFlagsStretchRatioProperty") @@ -483,11 +394,9 @@ public open class Control : CanvasItem() { } /** - * If `true`, automatically converts code line numbers, list indices, [SpinBox] and [ProgressBar] - * values from the Western Arabic (0..9) to the numeral systems used in current locale. + * If `true`, automatically converts code line numbers, list indices, [SpinBox] and [ProgressBar] values from the Western Arabic (0..9) to the numeral systems used in current locale. * - * **Note:** Numbers within the text are not automatically converted, it can be done manually, - * using [TextServer.formatNumber]. + * **Note:** Numbers within the text are not automatically converted, it can be done manually, using [TextServer.formatNumber]. */ public final inline var localizeNumeralSystem: Boolean @JvmName("localizeNumeralSystemProperty") @@ -498,8 +407,7 @@ public open class Control : CanvasItem() { } /** - * Toggles if any text should automatically change to its translated version depending on the - * current locale. + * Toggles if any text should automatically change to its translated version depending on the current locale. */ public final inline var autoTranslate: Boolean @JvmName("autoTranslateProperty") @@ -510,19 +418,11 @@ public open class Control : CanvasItem() { } /** - * The default tooltip text. The tooltip appears when the user's mouse cursor stays idle over this - * control for a few moments, provided that the [mouseFilter] property is not [MOUSE_FILTER_IGNORE]. - * The time required for the tooltip to appear can be changed with the - * [ProjectSettings.gui/timers/tooltipDelaySec] setting. + * The default tooltip text. The tooltip appears when the user's mouse cursor stays idle over this control for a few moments, provided that the [mouseFilter] property is not [MOUSE_FILTER_IGNORE]. The time required for the tooltip to appear can be changed with the [ProjectSettings.gui/timers/tooltipDelaySec] setting. * - * This string is the default return value of [getTooltip]. Override [_getTooltip] to generate - * tooltip text dynamically. Override [_makeCustomTooltip] to customize the tooltip interface and - * behavior. + * This string is the default return value of [getTooltip]. Override [_getTooltip] to generate tooltip text dynamically. Override [_makeCustomTooltip] to customize the tooltip interface and behavior. * - * The tooltip popup will use either a default implementation, or a custom one that you can - * provide by overriding [_makeCustomTooltip]. The default tooltip includes a [PopupPanel] and - * [Label] whose theme properties can be customized using [Theme] methods with the `"TooltipPanel"` - * and `"TooltipLabel"` respectively. For example: + * The tooltip popup will use either a default implementation, or a custom one that you can provide by overriding [_makeCustomTooltip]. The default tooltip includes a [PopupPanel] and [Label] whose theme properties can be customized using [Theme] methods with the `"TooltipPanel"` and `"TooltipLabel"` respectively. For example: * * ```gdscript * //gdscript @@ -553,12 +453,9 @@ public open class Control : CanvasItem() { } /** - * Defines if tooltip text should automatically change to its translated version depending on the - * current locale. Uses the same auto translate mode as this control when set to - * [Node.AUTO_TRANSLATE_MODE_INHERIT]. + * Defines if tooltip text should automatically change to its translated version depending on the current locale. Uses the same auto translate mode as this control when set to [Node.AUTO_TRANSLATE_MODE_INHERIT]. * - * **Note:** Tooltips customized using [_makeCustomTooltip] do not use this auto translate mode - * automatically. + * **Note:** Tooltips customized using [_makeCustomTooltip] do not use this auto translate mode automatically. */ public final inline var tooltipAutoTranslateMode: Node.AutoTranslateMode @JvmName("tooltipAutoTranslateModeProperty") @@ -569,10 +466,7 @@ public open class Control : CanvasItem() { } /** - * Tells Godot which node it should give focus to if the user presses the left arrow on the - * keyboard or left on a gamepad by default. You can change the key by editing the - * [ProjectSettings.input/uiLeft] input action. The node must be a [Control]. If this property is not - * set, Godot will give focus to the closest [Control] to the left of this one. + * Tells Godot which node it should give focus to if the user presses the left arrow on the keyboard or left on a gamepad by default. You can change the key by editing the [ProjectSettings.input/uiLeft] input action. The node must be a [Control]. If this property is not set, Godot will give focus to the closest [Control] to the left of this one. */ public final inline var focusNeighborLeft: NodePath @JvmName("focusNeighborLeftProperty") @@ -583,10 +477,7 @@ public open class Control : CanvasItem() { } /** - * Tells Godot which node it should give focus to if the user presses the top arrow on the - * keyboard or top on a gamepad by default. You can change the key by editing the - * [ProjectSettings.input/uiUp] input action. The node must be a [Control]. If this property is not - * set, Godot will give focus to the closest [Control] to the top of this one. + * Tells Godot which node it should give focus to if the user presses the top arrow on the keyboard or top on a gamepad by default. You can change the key by editing the [ProjectSettings.input/uiUp] input action. The node must be a [Control]. If this property is not set, Godot will give focus to the closest [Control] to the top of this one. */ public final inline var focusNeighborTop: NodePath @JvmName("focusNeighborTopProperty") @@ -597,10 +488,7 @@ public open class Control : CanvasItem() { } /** - * Tells Godot which node it should give focus to if the user presses the right arrow on the - * keyboard or right on a gamepad by default. You can change the key by editing the - * [ProjectSettings.input/uiRight] input action. The node must be a [Control]. If this property is - * not set, Godot will give focus to the closest [Control] to the right of this one. + * Tells Godot which node it should give focus to if the user presses the right arrow on the keyboard or right on a gamepad by default. You can change the key by editing the [ProjectSettings.input/uiRight] input action. The node must be a [Control]. If this property is not set, Godot will give focus to the closest [Control] to the right of this one. */ public final inline var focusNeighborRight: NodePath @JvmName("focusNeighborRightProperty") @@ -611,10 +499,7 @@ public open class Control : CanvasItem() { } /** - * Tells Godot which node it should give focus to if the user presses the down arrow on the - * keyboard or down on a gamepad by default. You can change the key by editing the - * [ProjectSettings.input/uiDown] input action. The node must be a [Control]. If this property is not - * set, Godot will give focus to the closest [Control] to the bottom of this one. + * Tells Godot which node it should give focus to if the user presses the down arrow on the keyboard or down on a gamepad by default. You can change the key by editing the [ProjectSettings.input/uiDown] input action. The node must be a [Control]. If this property is not set, Godot will give focus to the closest [Control] to the bottom of this one. */ public final inline var focusNeighborBottom: NodePath @JvmName("focusNeighborBottomProperty") @@ -625,12 +510,9 @@ public open class Control : CanvasItem() { } /** - * Tells Godot which node it should give focus to if the user presses [kbd]Tab[/kbd] on a keyboard - * by default. You can change the key by editing the [ProjectSettings.input/uiFocusNext] input - * action. + * Tells Godot which node it should give focus to if the user presses [kbd]Tab[/kbd] on a keyboard by default. You can change the key by editing the [ProjectSettings.input/uiFocusNext] input action. * - * If this property is not set, Godot will select a "best guess" based on surrounding nodes in the - * scene tree. + * If this property is not set, Godot will select a "best guess" based on surrounding nodes in the scene tree. */ public final inline var focusNext: NodePath @JvmName("focusNextProperty") @@ -641,12 +523,9 @@ public open class Control : CanvasItem() { } /** - * Tells Godot which node it should give focus to if the user presses [kbd]Shift + Tab[/kbd] on a - * keyboard by default. You can change the key by editing the [ProjectSettings.input/uiFocusPrev] - * input action. + * Tells Godot which node it should give focus to if the user presses [kbd]Shift + Tab[/kbd] on a keyboard by default. You can change the key by editing the [ProjectSettings.input/uiFocusPrev] input action. * - * If this property is not set, Godot will select a "best guess" based on surrounding nodes in the - * scene tree. + * If this property is not set, Godot will select a "best guess" based on surrounding nodes in the scene tree. */ public final inline var focusPrevious: NodePath @JvmName("focusPreviousProperty") @@ -657,8 +536,7 @@ public open class Control : CanvasItem() { } /** - * The focus access mode for the control (None, Click or All). Only one Control can be focused at - * the same time, and it will receive keyboard, gamepad, and mouse signals. + * The focus access mode for the control (None, Click or All). Only one Control can be focused at the same time, and it will receive keyboard, gamepad, and mouse signals. */ public final inline var focusMode: FocusMode @JvmName("focusModeProperty") @@ -669,10 +547,7 @@ public open class Control : CanvasItem() { } /** - * Controls whether the control will be able to receive mouse button input events through - * [_guiInput] and how these events should be handled. Also controls whether the control can receive - * the [signal mouse_entered], and [signal mouse_exited] signals. See the constants to learn what - * each does. + * Controls whether the control will be able to receive mouse button input events through [_guiInput] and how these events should be handled. Also controls whether the control can receive the [signal mouse_entered], and [signal mouse_exited] signals. See the constants to learn what each does. */ public final inline var mouseFilter: MouseFilter @JvmName("mouseFilterProperty") @@ -683,14 +558,11 @@ public open class Control : CanvasItem() { } /** - * When enabled, scroll wheel events processed by [_guiInput] will be passed to the parent control - * even if [mouseFilter] is set to [MOUSE_FILTER_STOP]. + * When enabled, scroll wheel events processed by [_guiInput] will be passed to the parent control even if [mouseFilter] is set to [MOUSE_FILTER_STOP]. * - * You should disable it on the root of your UI if you do not want scroll events to go to the - * [Node.UnhandledInput] processing. + * You should disable it on the root of your UI if you do not want scroll events to go to the [Node.UnhandledInput] processing. * - * **Note:** Because this property defaults to `true`, this allows nested scrollable containers to - * work out of the box. + * **Note:** Because this property defaults to `true`, this allows nested scrollable containers to work out of the box. */ public final inline var mouseForcePassScrollEvents: Boolean @JvmName("mouseForcePassScrollEventsProperty") @@ -701,8 +573,7 @@ public open class Control : CanvasItem() { } /** - * The default cursor shape for this control. Useful for Godot plugins and applications or games - * that use the system's mouse cursors. + * The default cursor shape for this control. Useful for Godot plugins and applications or games that use the system's mouse cursors. * * **Note:** On Linux, shapes may vary depending on the cursor theme of the system. */ @@ -715,9 +586,7 @@ public open class Control : CanvasItem() { } /** - * The [Node] which must be a parent of the focused [Control] for the shortcut to be activated. If - * `null`, the shortcut can be activated when any control is focused (a global shortcut). This allows - * shortcuts to be accepted only when the user has a certain area of the GUI focused. + * The [Node] which must be a parent of the focused [Control] for the shortcut to be activated. If `null`, the shortcut can be activated when any control is focused (a global shortcut). This allows shortcuts to be accepted only when the user has a certain area of the GUI focused. */ public final inline var shortcutContext: Node? @JvmName("shortcutContextProperty") @@ -728,9 +597,7 @@ public open class Control : CanvasItem() { } /** - * The [Theme] resource this node and all its [Control] and [Window] children use. If a child node - * has its own [Theme] resource set, theme items are merged with child's definitions having higher - * priority. + * The [Theme] resource this node and all its [Control] and [Window] children use. If a child node has its own [Theme] resource set, theme items are merged with child's definitions having higher priority. * * **Note:** [Window] styles will have no effect unless the window is embedded. */ @@ -743,21 +610,13 @@ public open class Control : CanvasItem() { } /** - * The name of a theme type variation used by this [Control] to look up its own theme items. When - * empty, the class name of the node is used (e.g. [code skip-lint]Button[/code] for the [Button] - * control), as well as the class names of all parent classes (in order of inheritance). + * The name of a theme type variation used by this [Control] to look up its own theme items. When empty, the class name of the node is used (e.g. [code skip-lint]Button[/code] for the [Button] control), as well as the class names of all parent classes (in order of inheritance). * - * When set, this property gives the highest priority to the type of the specified name. This type - * can in turn extend another type, forming a dependency chain. See [Theme.setTypeVariation]. If the - * theme item cannot be found using this type or its base types, lookup falls back on the class - * names. + * When set, this property gives the highest priority to the type of the specified name. This type can in turn extend another type, forming a dependency chain. See [Theme.setTypeVariation]. If the theme item cannot be found using this type or its base types, lookup falls back on the class names. * - * **Note:** To look up [Control]'s own items use various `get_theme_*` methods without specifying - * `theme_type`. + * **Note:** To look up [Control]'s own items use various `get_theme_*` methods without specifying `theme_type`. * - * **Note:** Theme items are looked for in the tree order, from branch to root, where each - * [Control] node is checked for its [theme] property. The earliest match against any type/class name - * is returned. The project-level Theme and the default Theme are checked last. + * **Note:** Theme items are looked for in the tree order, from branch to root, where each [Control] node is checked for its [theme] property. The earliest match against any type/class name is returned. The project-level Theme and the default Theme are checked last. */ public final inline var themeTypeVariation: StringName @JvmName("themeTypeVariationProperty") @@ -767,7 +626,7 @@ public open class Control : CanvasItem() { setThemeTypeVariation(value) } - public override fun new(scriptIndex: Int): Unit { + override fun new(scriptIndex: Int) { createNativeObject(178, scriptIndex) } @@ -782,15 +641,10 @@ public open class Control : CanvasItem() { * control.customMinimumSize = myCoreType * `````` * - * The minimum size of the node's bounding rectangle. If you set it to a value greater than `(0, - * 0)`, the node's bounding rectangle will always have at least this size. Note that [Control] nodes - * have their internal minimum size returned by [getMinimumSize]. It depends on the control's - * contents, like text, textures, or style boxes. The actual minimum size is the maximum value of - * this property and the internal minimum size (see [getCombinedMinimumSize]). + * The minimum size of the node's bounding rectangle. If you set it to a value greater than `(0, 0)`, the node's bounding rectangle will always have at least this size. Note that [Control] nodes have their internal minimum size returned by [getMinimumSize]. It depends on the control's contents, like text, textures, or style boxes. The actual minimum size is the maximum value of this property and the internal minimum size (see [getCombinedMinimumSize]). */ @CoreTypeHelper - public final fun customMinimumSizeMutate(block: Vector2.() -> Unit): Vector2 = - customMinimumSize.apply { + public final fun customMinimumSizeMutate(block: Vector2.() -> Unit): Vector2 = customMinimumSize.apply { block(this) customMinimumSize = this } @@ -806,25 +660,13 @@ public open class Control : CanvasItem() { * control.scale = myCoreType * `````` * - * The node's scale, relative to its [size]. Change this property to scale the node around its - * [pivotOffset]. The Control's [tooltipText] will also scale according to this value. + * The node's scale, relative to its [size]. Change this property to scale the node around its [pivotOffset]. The Control's [tooltipText] will also scale according to this value. * - * **Note:** This property is mainly intended to be used for animation purposes. To support - * multiple resolutions in your project, use an appropriate viewport stretch mode as described in the - * [url=$DOCS_URL/tutorials/rendering/multiple_resolutions.html]documentation[/url] instead of - * scaling Controls individually. + * **Note:** This property is mainly intended to be used for animation purposes. To support multiple resolutions in your project, use an appropriate viewport stretch mode as described in the [url=$DOCS_URL/tutorials/rendering/multiple_resolutions.html]documentation[/url] instead of scaling Controls individually. * - * **Note:** [FontFile.oversampling] does *not* take [Control] [scale] into account. This means - * that scaling up/down will cause bitmap fonts and rasterized (non-MSDF) dynamic fonts to appear - * blurry or pixelated. To ensure text remains crisp regardless of scale, you can enable MSDF font - * rendering by enabling [ProjectSettings.gui/theme/defaultFontMultichannelSignedDistanceField] - * (applies to the default project font only), or enabling **Multichannel Signed Distance Field** in - * the import options of a DynamicFont for custom fonts. On system fonts, - * [SystemFont.multichannelSignedDistanceField] can be enabled in the inspector. + * **Note:** [FontFile.oversampling] does *not* take [Control] [scale] into account. This means that scaling up/down will cause bitmap fonts and rasterized (non-MSDF) dynamic fonts to appear blurry or pixelated. To ensure text remains crisp regardless of scale, you can enable MSDF font rendering by enabling [ProjectSettings.gui/theme/defaultFontMultichannelSignedDistanceField] (applies to the default project font only), or enabling **Multichannel Signed Distance Field** in the import options of a DynamicFont for custom fonts. On system fonts, [SystemFont.multichannelSignedDistanceField] can be enabled in the inspector. * - * **Note:** If the Control node is a child of a [Container] node, the scale will be reset to - * `Vector2(1, 1)` when the scene is instantiated. To set the Control's scale when it's instantiated, - * wait for one frame using `await get_tree().process_frame` then set its [scale] property. + * **Note:** If the Control node is a child of a [Container] node, the scale will be reset to `Vector2(1, 1)` when the scene is instantiated. To set the Control's scale when it's instantiated, wait for one frame using `await get_tree().process_frame` then set its [scale] property. */ @CoreTypeHelper public final fun scaleMutate(block: Vector2.() -> Unit): Vector2 = scale.apply { @@ -843,9 +685,7 @@ public open class Control : CanvasItem() { * control.pivotOffset = myCoreType * `````` * - * By default, the node's pivot is its top-left corner. When you change its [rotation] or [scale], - * it will rotate or scale around this pivot. Set this property to [size] / 2 to pivot around the - * Control's center. + * By default, the node's pivot is its top-left corner. When you change its [rotation] or [scale], it will rotate or scale around this pivot. Set this property to [size] / 2 to pivot around the Control's center. */ @CoreTypeHelper public final fun pivotOffsetMutate(block: Vector2.() -> Unit): Vector2 = pivotOffset.apply { @@ -854,13 +694,11 @@ public open class Control : CanvasItem() { } /** - * Virtual method to be implemented by the user. Returns whether the given [point] is inside this - * control. + * Virtual method to be implemented by the user. Returns whether the given [point] is inside this control. * * If not overridden, default behavior is checking if the point is within control's Rect. * - * **Note:** If you want to check if a point is inside the control, you can use - * `Rect2(Vector2.ZERO, size).has_point(point)`. + * **Note:** If you want to check if a point is inside the control, you can use `Rect2(Vector2.ZERO, size).has_point(point)`. */ public open fun _hasPoint(point: Vector2): Boolean { throw NotImplementedError("Control::_hasPoint is not implemented.") @@ -869,57 +707,42 @@ public open class Control : CanvasItem() { /** * User defined BiDi algorithm override function. * - * Returns an [Array] of [Vector3i] text ranges and text base directions, in the left-to-right - * order. Ranges should cover full source [text] without overlaps. BiDi algorithm will be used on - * each range separately. + * Returns an [Array] of [Vector3i] text ranges and text base directions, in the left-to-right order. Ranges should cover full source [text] without overlaps. BiDi algorithm will be used on each range separately. */ - public open fun _structuredTextParser(args: VariantArray, text: String): - VariantArray { + public open fun _structuredTextParser(args: VariantArray, text: String): VariantArray { throw NotImplementedError("Control::_structuredTextParser is not implemented.") } /** - * Virtual method to be implemented by the user. Returns the minimum size for this control. - * Alternative to [customMinimumSize] for controlling minimum size via code. The actual minimum size - * will be the max value of these two (in each axis separately). + * Virtual method to be implemented by the user. Returns the minimum size for this control. Alternative to [customMinimumSize] for controlling minimum size via code. The actual minimum size will be the max value of these two (in each axis separately). * * If not overridden, defaults to [Vector2.ZERO]. * - * **Note:** This method will not be called when the script is attached to a [Control] node that - * already overrides its minimum size (e.g. [Label], [Button], [PanelContainer] etc.). It can only be - * used with most basic GUI nodes, like [Control], [Container], [Panel] etc. + * **Note:** This method will not be called when the script is attached to a [Control] node that already overrides its minimum size (e.g. [Label], [Button], [PanelContainer] etc.). It can only be used with most basic GUI nodes, like [Control], [Container], [Panel] etc. */ public open fun _getMinimumSize(): Vector2 { throw NotImplementedError("Control::_getMinimumSize is not implemented.") } /** - * Virtual method to be implemented by the user. Returns the tooltip text for the position - * [atPosition] in control's local coordinates, which will typically appear when the cursor is - * resting over this control. See [getTooltip]. + * Virtual method to be implemented by the user. Returns the tooltip text for the position [atPosition] in control's local coordinates, which will typically appear when the cursor is resting over this control. See [getTooltip]. * - * **Note:** If this method returns an empty [String] and [_makeCustomTooltip] is not overridden, - * no tooltip is displayed. + * **Note:** If this method returns an empty [String] and [_makeCustomTooltip] is not overridden, no tooltip is displayed. */ public open fun _getTooltip(atPosition: Vector2): String { throw NotImplementedError("Control::_getTooltip is not implemented.") } /** - * Godot calls this method to get data that can be dragged and dropped onto controls that expect - * drop data. Returns `null` if there is no data to drag. Controls that want to receive drop data - * should implement [_canDropData] and [_dropData]. [atPosition] is local to this control. Drag may - * be forced with [forceDrag]. + * Godot calls this method to get data that can be dragged and dropped onto controls that expect drop data. Returns `null` if there is no data to drag. Controls that want to receive drop data should implement [_canDropData] and [_dropData]. [atPosition] is local to this control. Drag may be forced with [forceDrag]. * - * A preview that will follow the mouse that should represent the data can be set with - * [setDragPreview]. A good time to set the preview is in this method. + * A preview that will follow the mouse that should represent the data can be set with [setDragPreview]. A good time to set the preview is in this method. * * ```gdscript * //gdscript * func _get_drag_data(position): * var mydata = make_data() # This is your custom method generating the drag data. - * set_drag_preview(make_preview(mydata)) # This is your custom method generating the preview - * of the drag data. + * set_drag_preview(make_preview(mydata)) # This is your custom method generating the preview of the drag data. * return mydata * ``` * @@ -928,8 +751,7 @@ public open class Control : CanvasItem() { * public override Variant _GetDragData(Vector2 atPosition) * { * var myData = MakeData(); // This is your custom method generating the drag data. - * SetDragPreview(MakePreview(myData)); // This is your custom method generating the preview - * of the drag data. + * SetDragPreview(MakePreview(myData)); // This is your custom method generating the preview of the drag data. * return myData; * } * ``` @@ -939,8 +761,7 @@ public open class Control : CanvasItem() { } /** - * Godot calls this method to test if [data] from a control's [_getDragData] can be dropped at - * [atPosition]. [atPosition] is local to this control. + * Godot calls this method to test if [data] from a control's [_getDragData] can be dropped at [atPosition]. [atPosition] is local to this control. * * This method should only be used to test the data. Process the data in [_dropData]. * @@ -958,8 +779,7 @@ public open class Control : CanvasItem() { * { * // Check position if it is relevant to you * // Otherwise, just check data - * return data.VariantType == Variant.Type.Dictionary && - * data.AsGodotDictionary().ContainsKey("expected"); + * return data.VariantType == Variant.Type.Dictionary && data.AsGodotDictionary().ContainsKey("expected"); * } * ``` */ @@ -968,9 +788,7 @@ public open class Control : CanvasItem() { } /** - * Godot calls this method to pass you the [data] from a control's [_getDragData] result. Godot - * first calls [_canDropData] to test if [data] is allowed to drop at [atPosition] where [atPosition] - * is local to this control. + * Godot calls this method to pass you the [data] from a control's [_getDragData] result. Godot first calls [_canDropData] to test if [data] is allowed to drop at [atPosition] where [atPosition] is local to this control. * * ```gdscript * //gdscript @@ -985,8 +803,7 @@ public open class Control : CanvasItem() { * //csharp * public override bool _CanDropData(Vector2 atPosition, Variant data) * { - * return data.VariantType == Variant.Type.Dictionary && - * data.AsGodotDictionary().ContainsKey("color"); + * return data.VariantType == Variant.Type.Dictionary && data.AsGodotDictionary().ContainsKey("color"); * } * * public override void _DropData(Vector2 atPosition, Variant data) @@ -995,34 +812,22 @@ public open class Control : CanvasItem() { * } * ``` */ - public open fun _dropData(atPosition: Vector2, `data`: Any?): Unit { + public open fun _dropData(atPosition: Vector2, `data`: Any?) { throw NotImplementedError("Control::_dropData is not implemented.") } /** - * Virtual method to be implemented by the user. Returns a [Control] node that should be used as a - * tooltip instead of the default one. [forText] is the return value of [getTooltip]. + * Virtual method to be implemented by the user. Returns a [Control] node that should be used as a tooltip instead of the default one. [forText] is the return value of [getTooltip]. * - * The returned node must be of type [Control] or Control-derived. It can have child nodes of any - * type. It is freed when the tooltip disappears, so make sure you always provide a new instance (if - * you want to use a pre-existing node from your scene tree, you can duplicate it and pass the - * duplicated instance). When `null` or a non-Control node is returned, the default tooltip will be - * used instead. + * The returned node must be of type [Control] or Control-derived. It can have child nodes of any type. It is freed when the tooltip disappears, so make sure you always provide a new instance (if you want to use a pre-existing node from your scene tree, you can duplicate it and pass the duplicated instance). When `null` or a non-Control node is returned, the default tooltip will be used instead. * - * The returned node will be added as child to a [PopupPanel], so you should only provide the - * contents of that panel. That [PopupPanel] can be themed using [Theme.setStylebox] for the type - * `"TooltipPanel"` (see [tooltipText] for an example). + * The returned node will be added as child to a [PopupPanel], so you should only provide the contents of that panel. That [PopupPanel] can be themed using [Theme.setStylebox] for the type `"TooltipPanel"` (see [tooltipText] for an example). * - * **Note:** The tooltip is shrunk to minimal size. If you want to ensure it's fully visible, you - * might want to set its [customMinimumSize] to some non-zero value. + * **Note:** The tooltip is shrunk to minimal size. If you want to ensure it's fully visible, you might want to set its [customMinimumSize] to some non-zero value. * - * **Note:** The node (and any relevant children) should have their [CanvasItem.visible] set to - * `true` when returned, otherwise, the viewport that instantiates it will not be able to calculate - * its minimum size reliably. + * **Note:** The node (and any relevant children) should have their [CanvasItem.visible] set to `true` when returned, otherwise, the viewport that instantiates it will not be able to calculate its minimum size reliably. * - * **Note:** If overridden, this method is called even if [getTooltip] returns an empty string. - * When this happens with the default tooltip, it is not displayed. To copy this behavior, return - * `null` in this method when [forText] is empty. + * **Note:** If overridden, this method is called even if [getTooltip] returns an empty string. When this happens with the default tooltip, it is not displayed. To copy this behavior, return `null` in this method when [forText] is empty. * * **Example:** Use a constructed node as a tooltip: * @@ -1058,8 +863,7 @@ public open class Control : CanvasItem() { * //csharp * public override Control _MakeCustomTooltip(string forText) * { - * Node tooltip = - * ResourceLoader.Load("res://some_tooltip_scene.tscn").Instantiate(); + * Node tooltip = ResourceLoader.Load("res://some_tooltip_scene.tscn").Instantiate(); * tooltip.GetNode