diff --git a/.github/workflows/format-check.yml b/.github/workflows/format-check.yml index e3cddad83..2a781ed32 100644 --- a/.github/workflows/format-check.yml +++ b/.github/workflows/format-check.yml @@ -1,48 +1,28 @@ -name: Check format +name: Check Formatting on: push: workflow_dispatch: jobs: - build: - runs-on: ubuntu-latest + check: + runs-on: ubuntu-24.04 steps: - - name: Install OS dependencies (needed for act on ubuntu-latest) - run: | - sudo apt update - sudo apt install -y --force-yes curl xz-utils libicu-dev git dos2unix - wget http://security.ubuntu.com/ubuntu/pool/universe/n/ncurses/libtinfo5_6.3-2ubuntu0.1_amd64.deb - sudo apt install ./libtinfo5_6.3-2ubuntu0.1_amd64.deb - - uses: actions/checkout@v3 - - name: Cache Clang - id: cache-clang - uses: actions/cache@v3 - with: - path: clang - key: ${{ runner.os }}-clang-13-0-1 - - - name: Install Clang - if: steps.cache-clang.outputs.cache-hit != 'true' - run: | - curl -L https://github.com/llvm/llvm-project/releases/download/llvmorg-13.0.1/clang+llvm-13.0.1-x86_64-linux-gnu-ubuntu-18.04.tar.xz --output clang.tar.xz - tar -xf clang.tar.xz - mv clang+llvm-13.0.1-x86_64-linux-gnu-ubuntu-18.04 clang + - name: Setup clang-format + run: ./formatters/setup-clang-format-docker.sh - name: Install dotnet uses: actions/setup-dotnet@v3 with: - dotnet-version: "6.0.x" - - run: dotnet tool install -g dotnet-format + dotnet-version: "8.0.x" - - name: Install Node and dependenceis + - name: Install Node and dependencies uses: actions/setup-node@v3 with: - node-version: "16" - - run: npm install -g typescript typescript-formatter + node-version: "24" - name: Install JDK uses: actions/setup-java@v3 @@ -50,14 +30,29 @@ jobs: distribution: 'zulu' java-version: "16" + - name: Install Haxe + uses: krdlab/setup-haxe@v1 + with: + haxe-version: '4.3.2' + - run: haxelib install formatter + + - name: Install Dart + uses: dart-lang/setup-dart@v1 + with: + sdk: '3.8.1' + + - name: Check dart format version + run: | + dart format --version + - name: Format run: | - export CLANGFORMAT=`pwd`/clang/bin/clang-format - export PATH="$PATH:/root/.dotnet/tools" - dotnet-format --version - ./formatters/format.sh - find . -type f -name '*.cs' -exec perl -pi -e 's/\r\n/\n/g' '{}' + - git diff + ./formatters/format-cpp.sh + ./formatters/format-csharp.sh + ./formatters/format-dart.sh + ./formatters/format-haxe.sh + ./formatters/format-java.sh + ./formatters/format-ts.sh git diff > format-diff.txt - name: Archive formatting result diff --git a/.gitignore b/.gitignore index e7ca0f590..01d836a35 100644 --- a/.gitignore +++ b/.gitignore @@ -252,3 +252,5 @@ spine-libgdx/.project .clang-format spine-c/codegen/spine-cpp-types.json spine-flutter/example/devtools_options.yaml +spine-glfw/.cache +formatters/eclipse-formatter/format-diff.txt diff --git a/formatters/.clang-format b/formatters/.clang-format index 4edd46c68..469dba70c 100644 --- a/formatters/.clang-format +++ b/formatters/.clang-format @@ -70,6 +70,7 @@ SpaceBeforeInheritanceColon: true SpaceBeforeParens: ControlStatements SpaceBeforeRangeBasedForLoopColon: true SpaceInEmptyParentheses: false +SpaceInEmptyBlock: true SpacesBeforeTrailingComments: 0 SpacesInAngles: false SpacesInCStyleCastParentheses: false diff --git a/formatters/.editorconfig b/formatters/.editorconfig index 65b41a160..22fdec84d 100644 --- a/formatters/.editorconfig +++ b/formatters/.editorconfig @@ -12,7 +12,7 @@ indent_style = tab tab_width = 4 # New line preferences -end_of_line = crlf +end_of_line = lf insert_final_newline = true #### .NET Coding Conventions #### diff --git a/formatters/.gitignore b/formatters/.gitignore new file mode 100644 index 000000000..23d818327 --- /dev/null +++ b/formatters/.gitignore @@ -0,0 +1 @@ +eclipse-formatter/target/ diff --git a/formatters/README.md b/formatters/README.md index d896d422f..a72d4ea7d 100644 --- a/formatters/README.md +++ b/formatters/README.md @@ -1,11 +1,103 @@ -# Formatters -This folder contains formatter configuration files to be used with IDEs as well as the [spotless](https://github.com/diffplug/spotless/blob/main/plugin-gradle/README.md) formatter expressed in the Gradle project in this directory. +# Spine Runtimes Code Formatters -You will need the following on your `PATH`: +This directory contains formatting scripts and tools to ensure consistent code style across all Spine runtime implementations. -- JDK 10+ -- clang-format 12.0.1 (i.e. `brew install clang-format`). Also set the environment variable `CLANGFORMAT` to the path of the `clang-format` executable. -- dotnet format (i.e. `dotnet tool install -g dotnet-format`, comes with dotnet 6 out of the box) -- tsfmt, (i.e. `npm install -g typescript-formatter`) +## Scripts -To run the formatter, invoke the `format.sh` script. This will shuffle around the Gradle config files, invoke spotless, then undo the config file shuffling. Invoking `./gradlew spotlessApply` from the `formatters/` directory will not work. \ No newline at end of file +### format-cpp.sh +Formats C/C++ source files using clang-format. +- **Prerequisites**: clang-format 18.1.8 +- **Coverage**: All C/C++ files in spine-cpp, spine-c, spine-godot, spine-ue, spine-glfw, spine-sdl, spine-sfml, spine-cocos2dx, spine-ios, spine-flutter +- **Configuration**: Uses .clang-format configuration file +- **Behavior**: Batches all files in a single clang-format call for performance + +### format-csharp.sh +Formats C# source files using dotnet format. +- **Prerequisites**: .NET SDK with dotnet format tool +- **Coverage**: All C# files in spine-csharp, spine-monogame, spine-unity +- **Configuration**: Uses .editorconfig (temporarily copied to each project) +- **Behavior**: Runs with --no-restore and --verbosity quiet to suppress warnings + +### format-dart.sh +Formats Dart source files using dart format. +- **Prerequisites**: Dart SDK +- **Coverage**: All Dart files in spine-flutter +- **Configuration**: Uses --page-width 120 parameter +- **Behavior**: Formats all files in place + +### format-haxe.sh +Formats Haxe source files using haxelib formatter. +- **Prerequisites**: Haxe and haxelib formatter package +- **Coverage**: All Haxe files in spine-haxe +- **Configuration**: Uses hxformat.json configuration file +- **Behavior**: Formats all files in place + +### format-java.sh +Formats Java source files using a custom Eclipse formatter. +- **Prerequisites**: Java JDK and Maven +- **Coverage**: All Java files in spine-libgdx and spine-android +- **Configuration**: Uses eclipse-formatter.xml configuration file +- **Behavior**: Builds Eclipse formatter JAR if needed, only outputs changed files + +### format-ts.sh +Formats TypeScript source files using typescript-formatter. +- **Prerequisites**: Node.js and npm +- **Coverage**: All TypeScript files in spine-ts and tests +- **Configuration**: Uses tsfmt.json configuration files +- **Behavior**: Uses npx to auto-download formatter, validates tsfmt.json consistency + +### setup-clang-format-docker.sh +Helper script for GitHub Actions to set up clang-format via Docker. +- **Prerequisites**: Docker +- **Purpose**: Creates a wrapper script that runs clang-format 18.1.8 in a Docker container +- **Usage**: Called by GitHub Actions workflow to ensure version consistency + +## Configuration Files + +- **.clang-format**: C/C++ formatting rules +- **.editorconfig**: C# formatting rules +- **eclipse-formatter.xml**: Java formatting rules for Eclipse formatter +- **hxformat.json**: Haxe formatting rules + +## Eclipse Formatter + +The eclipse-formatter directory contains a Maven project that builds a standalone Eclipse code formatter: +- **Source**: eclipse-formatter/src/main/java/com/esotericsoftware/spine/formatter/EclipseFormatter.java +- **Build**: Automatically built by format-java.sh when the JAR doesn't exist or source is newer +- **Output**: Only prints files that were actually modified + +## GitHub Actions Workflow + +The formatting check runs automatically on push and can be triggered manually: + +1. **Workflow file**: .github/workflows/format-check-new.yml +2. **Process**: + - Sets up all required formatters and dependencies + - Runs all format scripts + - Captures any file changes to format-diff.txt + - Uploads diff as artifact + - Fails if any files were modified + +### Docker-based clang-format + +To ensure consistent formatting across local development and CI, the workflow uses Docker to run clang-format 18.1.8. The setup-clang-format-docker.sh script creates a wrapper that: +- Mounts the project directory in the Docker container +- Converts relative paths to absolute paths +- Runs clang-format with the same version everywhere + +## Local Development + +To run formatters locally: + +```bash +cd formatters +./format-cpp.sh # Format C/C++ files +./format-csharp.sh # Format C# files +./format-dart.sh # Format Dart files +./format-haxe.sh # Format Haxe files +./format-java.sh # Format Java files +./format-ts.sh # Format TypeScript files +./format.sh # Format everything +``` + +Ensure you have the required tools installed for each formatter you want to run. \ No newline at end of file diff --git a/formatters/build.gradle b/formatters/build.gradle deleted file mode 100644 index 1b8b485ae..000000000 --- a/formatters/build.gradle +++ /dev/null @@ -1,51 +0,0 @@ -buildscript { repositories { mavenCentral() }} - -plugins { - id "com.diffplug.spotless" version "5.14.0" -} - -spotless { - lineEndings 'UNIX' - - java { - target 'spine-libgdx/**/*.java', - 'spine-android/**/*.java' - eclipse().configFile('formatters/eclipse-formatter.xml') - } - - cpp { - target 'spine-c/**/*.c', - 'spine-c/**/.h', - 'spine-cpp/**/*.cpp', - 'spine-cpp/**/.h', - 'spine-cocos2dx/src/**/*.cpp', - 'spine-cocos2dx/src/**/*.h', - 'spine-cocos2dx/example/Classes/**/*.cpp', - 'spine-cocos2dx/example/Classes/**/*.h', - 'spine-glfw/src/**/*.cpp', - 'spine-glfw/src/**/*.h', - 'spine-glfw/example/**/*.cpp', - 'spine-glfw/example/**/*.h', - 'spine-sdl/src/**/*.c', - 'spine-sdl/src/**/*.cpp', - 'spine-sdl/src/**/*.h', - 'spine-sdl/example/**/*.c', - 'spine-sdl/example/**/*.cpp', - 'spine-sdl/example/**/*.h', - 'spine-sfml/c/src/**/*.c', - 'spine-sfml/c/src/**/*.h', - 'spine-sfml/cpp/src/**/*.cpp', - 'spine-sfml/cpp/src/**/*.h', - 'spine-ue/**/*.cpp', - 'spine-ue/**/*.h', - 'spine-godot/spine_godot/*.cpp', - 'spine-godot/spine_godot/*.h' - clangFormat("13.0.1").pathToExe("$System.env.CLANGFORMAT").style('file') - } - - typescript { - target 'spine-ts/**/src/*.ts' - targetExclude 'spine-ts/**/*.d.ts', 'spine-ts/**/node_modules/**/*.ts' - tsfmt('7.2.2').tsfmtFile('formatters/tsfmt.json') - } -} \ No newline at end of file diff --git a/formatters/eclipse-formatter/pom.xml b/formatters/eclipse-formatter/pom.xml new file mode 100644 index 000000000..2fb1a086f --- /dev/null +++ b/formatters/eclipse-formatter/pom.xml @@ -0,0 +1,106 @@ + + + 4.0.0 + + com.esotericsoftware.spine + eclipse-formatter + 1.0.0 + jar + + + 11 + 11 + UTF-8 + 4.26 + + + + + + org.eclipse.jdt + org.eclipse.jdt.core + 3.32.0 + + + + + org.eclipse.platform + org.eclipse.text + 3.12.300 + + + + + org.eclipse.platform + org.eclipse.jface.text + 3.22.0 + + + + + org.eclipse.platform + org.eclipse.core.runtime + 3.26.100 + + + + + org.eclipse.platform + org.eclipse.equinox.common + 3.17.100 + + + + + org.eclipse.platform + org.eclipse.core.resources + 3.18.100 + + + + + org.eclipse.platform + org.eclipse.osgi + 3.18.300 + + + + + + + org.apache.maven.plugins + maven-compiler-plugin + 3.11.0 + + + + + org.apache.maven.plugins + maven-assembly-plugin + 3.6.0 + + + jar-with-dependencies + + + + com.esotericsoftware.spine.formatter.EclipseFormatter + + + + + + make-assembly + package + + single + + + + + + + \ No newline at end of file diff --git a/formatters/eclipse-formatter/src/main/java/com/esotericsoftware/spine/formatter/EclipseFormatter.java b/formatters/eclipse-formatter/src/main/java/com/esotericsoftware/spine/formatter/EclipseFormatter.java new file mode 100644 index 000000000..b8ad48d1a --- /dev/null +++ b/formatters/eclipse-formatter/src/main/java/com/esotericsoftware/spine/formatter/EclipseFormatter.java @@ -0,0 +1,129 @@ +package com.esotericsoftware.spine.formatter; + +import java.io.*; +import java.nio.file.*; +import java.util.*; +import javax.xml.parsers.*; +import org.w3c.dom.*; +import org.eclipse.jdt.core.formatter.CodeFormatter; +import org.eclipse.jdt.internal.formatter.DefaultCodeFormatter; +import org.eclipse.jface.text.Document; +import org.eclipse.jface.text.IDocument; +import org.eclipse.text.edits.TextEdit; + +public class EclipseFormatter { + private static final String LINE_DELIMITER = "\n"; + + public static void main(String[] args) throws Exception { + if (args.length < 2) { + System.err.println("Usage: java -jar eclipse-formatter.jar [file2.java ...]"); + System.exit(1); + } + + // Load formatter settings from XML + Map options = loadFormatterSettings(args[0]); + + // Create formatter + CodeFormatter formatter = new DefaultCodeFormatter(options); + + // Format each file + int changedCount = 0; + int errorCount = 0; + + for (int i = 1; i < args.length; i++) { + try { + if (formatFile(formatter, args[i])) { + changedCount++; + } + } catch (Exception e) { + System.err.println("Error formatting " + args[i] + ": " + e.getMessage()); + errorCount++; + } + } + + System.out.println("Formatting complete: " + changedCount + " files changed, " + errorCount + " errors"); + + if (errorCount > 0) { + System.exit(1); + } + } + + private static Map loadFormatterSettings(String xmlPath) throws Exception { + Map settings = new HashMap<>(); + + DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance(); + DocumentBuilder builder = factory.newDocumentBuilder(); + org.w3c.dom.Document doc = builder.parse(new File(xmlPath)); + + // Handle both direct settings and profile-based settings + NodeList profiles = doc.getElementsByTagName("profile"); + if (profiles.getLength() > 0) { + // Profile-based format (Eclipse export) + Element profile = (Element) profiles.item(0); + NodeList settingNodes = profile.getElementsByTagName("setting"); + + for (int i = 0; i < settingNodes.getLength(); i++) { + Element setting = (Element) settingNodes.item(i); + String id = setting.getAttribute("id"); + String value = setting.getAttribute("value"); + if (id != null && !id.isEmpty() && value != null) { + settings.put(id, value); + } + } + } else { + // Direct settings format + NodeList settingNodes = doc.getElementsByTagName("setting"); + + for (int i = 0; i < settingNodes.getLength(); i++) { + Element setting = (Element) settingNodes.item(i); + String id = setting.getAttribute("id"); + String value = setting.getAttribute("value"); + if (id != null && !id.isEmpty() && value != null) { + settings.put(id, value); + } + } + } + + // Removed verbose output + + return settings; + } + + private static boolean formatFile(CodeFormatter formatter, String filePath) throws Exception { + Path path = Paths.get(filePath); + + if (!Files.exists(path)) { + throw new FileNotFoundException("File not found: " + filePath); + } + + String content = Files.readString(path); + + // Determine if it's a module-info.java file + int kind = path.getFileName().toString().equals("module-info.java") + ? CodeFormatter.K_MODULE_INFO + : CodeFormatter.K_COMPILATION_UNIT; + kind |= CodeFormatter.F_INCLUDE_COMMENTS; + + // Format the code + TextEdit edit = formatter.format(kind, content, 0, content.length(), 0, LINE_DELIMITER); + + if (edit == null) { + throw new IllegalArgumentException("Cannot format file - invalid Java syntax or formatter configuration issue"); + } + + // Apply the edit + IDocument document = new Document(content); + edit.apply(document); + String formatted = document.get(); + + // Only write if content changed + if (!content.equals(formatted)) { + Files.writeString(path, formatted); + System.out.println("Formatted: " + filePath); + return true; + } else { + // Silent when no changes + return false; + } + } +} \ No newline at end of file diff --git a/formatters/format-cpp.sh b/formatters/format-cpp.sh index 23e8b3d91..b56aa7916 100755 --- a/formatters/format-cpp.sh +++ b/formatters/format-cpp.sh @@ -6,8 +6,12 @@ echo "Formatting C/C++ files..." dir="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )" -if [ ! -f "$dir/.clang-format" ]; then +# Store original directory +pushd "$dir" > /dev/null + +if [ ! -f ".clang-format" ]; then echo "Error: .clang-format not found in formatters directory" + popd > /dev/null exit 1 fi @@ -84,28 +88,20 @@ done echo "Found ${#files[@]} C/C++ files to format" -# Format each file with progress -count=0 -errors=0 -for file in "${files[@]}"; do - count=$((count + 1)) - # Show progress every 10 files or for the last file - if [ $((count % 10)) -eq 0 ] || [ $count -eq ${#files[@]} ]; then - printf "\r[$count/${#files[@]}] Formatting: %-80s" "$(basename "$file")" - fi - - # Format the file and capture any errors - if ! clang-format -i -style=file:"$dir/.clang-format" "$file" 2>/dev/null; then - printf "\nError formatting: $file\n" - errors=$((errors + 1)) - fi -done - -# Clear the progress line and show completion -printf "\r%-100s\r" " " +# Format all files in one call - works for both Docker and native +echo "Formatting ${#files[@]} files..." +if ! clang-format -i -style=file:".clang-format" "${files[@]}" 2>&1; then + echo "Error: clang-format failed" + errors=1 +else + errors=0 +fi if [ $errors -gt 0 ]; then echo "Completed with $errors errors" fi -echo "C/C++ formatting complete" \ No newline at end of file +echo "C/C++ formatting complete" + +# Return to original directory +popd > /dev/null \ No newline at end of file diff --git a/formatters/format-csharp.sh b/formatters/format-csharp.sh index 9cd06c508..05051686a 100755 --- a/formatters/format-csharp.sh +++ b/formatters/format-csharp.sh @@ -6,20 +6,43 @@ echo "Formatting C# files..." dir="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )" -if command -v dotnet-format &> /dev/null; then +if command -v dotnet &> /dev/null; then + # Store original directory + pushd "$dir" > /dev/null + # Copy .editorconfig to C# directories cp .editorconfig ../spine-csharp/ 2>/dev/null || true cp .editorconfig ../spine-monogame/ 2>/dev/null || true cp .editorconfig ../spine-unity/ 2>/dev/null || true - dotnet-format ../spine-csharp/spine-csharp.sln || true - dotnet-format -f ../spine-monogame || true - dotnet-format -f ../spine-unity || true + # Format spine-csharp + pushd ../spine-csharp > /dev/null + dotnet format spine-csharp.csproj --no-restore --verbosity quiet 2>/dev/null || echo "Warning: Some issues with spine-csharp formatting" + popd > /dev/null + + # Format spine-monogame + pushd ../spine-monogame > /dev/null + dotnet format --no-restore --verbosity quiet 2>/dev/null || echo "Warning: Some issues with spine-monogame formatting" + popd > /dev/null + + # Format spine-unity - look for .cs files directly + if [ -d ../spine-unity ]; then + echo "Formatting spine-unity C# files directly..." + pushd ../spine-unity > /dev/null + # Find all .cs files and format them using dotnet format whitespace + find . -name "*.cs" -type f -not -path "./Library/*" -not -path "./Temp/*" -not -path "./obj/*" -not -path "./bin/*" | while read -r file; do + dotnet format whitespace --include "$file" --no-restore 2>/dev/null || true + done + popd > /dev/null + fi # Clean up .editorconfig files rm -f ../spine-csharp/.editorconfig rm -f ../spine-monogame/.editorconfig rm -f ../spine-unity/.editorconfig + + # Return to original directory + popd > /dev/null else - echo "Warning: dotnet-format not found. Skipping C# formatting." + echo "Warning: dotnet not found. Skipping C# formatting." fi \ No newline at end of file diff --git a/formatters/format-dart.sh b/formatters/format-dart.sh index 601cd2bc8..558c6a95d 100755 --- a/formatters/format-dart.sh +++ b/formatters/format-dart.sh @@ -4,12 +4,20 @@ set -e # Format Dart files echo "Formatting Dart files..." +dir="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )" + +# Store original directory +pushd "$dir" > /dev/null + if command -v dart &> /dev/null; then find .. -name "*.dart" \ -not -path "*/.*" \ -not -path "*/node_modules/*" \ -not -path "*/build/*" \ - -exec dart format {} + + -exec dart format --page-width 120 {} + else echo "Warning: dart not found. Skipping Dart formatting." -fi \ No newline at end of file +fi + +# Return to original directory +popd > /dev/null \ No newline at end of file diff --git a/formatters/format-haxe.sh b/formatters/format-haxe.sh index d034523d9..4c02cb069 100755 --- a/formatters/format-haxe.sh +++ b/formatters/format-haxe.sh @@ -4,12 +4,19 @@ set -e # Format Haxe files echo "Formatting Haxe files..." +dir="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )" + +# Store original directory +pushd "$dir" > /dev/null + if command -v haxelib &> /dev/null && haxelib list formatter &> /dev/null; then - find .. -name "*.hx" \ - -not -path "*/.*" \ - -not -path "*/node_modules/*" \ - -not -path "*/build/*" \ - | xargs haxelib run formatter -s + # Format spine-haxe directory + if [ -d ../spine-haxe ]; then + haxelib run formatter -s ../spine-haxe + fi else echo "Warning: haxe formatter not found. Install with: haxelib install formatter" -fi \ No newline at end of file +fi + +# Return to original directory +popd > /dev/null \ No newline at end of file diff --git a/formatters/format-java.sh b/formatters/format-java.sh index 93c837bc1..fa7934c19 100755 --- a/formatters/format-java.sh +++ b/formatters/format-java.sh @@ -1,9 +1,42 @@ #!/bin/bash set -e -# Format Java files with Spotless (keeping this for Eclipse formatter) +# Format Java files with Eclipse formatter echo "Formatting Java files..." dir="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )" -./formatters/gradlew -p formatters spotlessJavaApply --quiet \ No newline at end of file +# Store original directory +pushd "$dir" > /dev/null + +# Build the Eclipse formatter if needed +jar_file="eclipse-formatter/target/eclipse-formatter-1.0.0-jar-with-dependencies.jar" +src_file="eclipse-formatter/src/main/java/com/esotericsoftware/spine/formatter/EclipseFormatter.java" + +if [ ! -f "$jar_file" ] || [ "$src_file" -nt "$jar_file" ]; then + echo "Building Eclipse formatter..." + pushd eclipse-formatter > /dev/null + mvn -q clean package + popd > /dev/null +fi + +# Find all Java files +java_files=$(find ../spine-libgdx ../spine-android -name "*.java" -type f \ + -not -path "*/build/*" \ + -not -path "*/.gradle/*" \ + -not -path "*/bin/*" \ + -not -path "*/gen/*" \ + -not -path "*/target/*") + +# Run the formatter +if [ -n "$java_files" ]; then + echo "Running Eclipse formatter on Java files..." + java -jar eclipse-formatter/target/eclipse-formatter-1.0.0-jar-with-dependencies.jar \ + eclipse-formatter.xml \ + $java_files +fi + +echo "Java formatting complete" + +# Return to original directory +popd > /dev/null \ No newline at end of file diff --git a/formatters/format-swift.sh b/formatters/format-swift.sh index d39767952..819931c55 100755 --- a/formatters/format-swift.sh +++ b/formatters/format-swift.sh @@ -4,6 +4,11 @@ set -e # Format Swift files echo "Formatting Swift files..." +dir="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )" + +# Store original directory +pushd "$dir" > /dev/null + if command -v swift-format &> /dev/null; then find .. -name "*.swift" \ -not -path "*/.*" \ @@ -12,4 +17,7 @@ if command -v swift-format &> /dev/null; then | xargs swift-format -i else echo "Warning: swift-format not found. Install from https://github.com/apple/swift-format" -fi \ No newline at end of file +fi + +# Return to original directory +popd > /dev/null \ No newline at end of file diff --git a/formatters/format-ts.sh b/formatters/format-ts.sh index 741209a70..2ea327518 100755 --- a/formatters/format-ts.sh +++ b/formatters/format-ts.sh @@ -6,13 +6,25 @@ echo "Formatting TypeScript files..." dir="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )" +# Store original directory +pushd "$dir" > /dev/null + # Check if tsfmt.json files match if ! cmp -s ../spine-ts/tsfmt.json ../tests/tsfmt.json; then echo -e "\033[1;31mERROR: spine-ts/tsfmt.json and tests/tsfmt.json differ!\033[0m" echo -e "\033[1;31mPlease sync them to ensure consistent formatting.\033[0m" + popd > /dev/null exit 1 fi # Format TypeScript files -cd ../spine-ts && npm run format && cd ../formatters -cd ../tests && npm run format -r && cd ../formatters \ No newline at end of file +pushd ../spine-ts > /dev/null +npm run format +popd > /dev/null + +pushd ../tests > /dev/null +npm run format +popd > /dev/null + +# Return to original directory +popd > /dev/null \ No newline at end of file diff --git a/formatters/format.sh b/formatters/format.sh index f22b003c3..f2bc76e56 100755 --- a/formatters/format.sh +++ b/formatters/format.sh @@ -31,10 +31,10 @@ show_help() { echo "Multiple language flags can be combined, e.g.: ./format.sh java ts" echo "" echo "Tools used:" - echo " Java: Spotless with Eclipse formatter" - echo " TypeScript: Biome" + echo " Java: Eclipse formatter (via eclipse-formatter.xml)" + echo " TypeScript: tsfmt (typescript-formatter)" echo " C/C++: clang-format" - echo " C#: dotnet-format" + echo " C#: dotnet format" echo " Haxe: haxe formatter" echo " Dart: dart format" echo " Swift: swift-format" diff --git a/formatters/gradle/wrapper/gradle-wrapper.jar b/formatters/gradle/wrapper/gradle-wrapper.jar deleted file mode 100644 index 01b8bf6b1..000000000 Binary files a/formatters/gradle/wrapper/gradle-wrapper.jar and /dev/null differ diff --git a/formatters/gradle/wrapper/gradle-wrapper.properties b/formatters/gradle/wrapper/gradle-wrapper.properties deleted file mode 100644 index 6b74f0f6b..000000000 --- a/formatters/gradle/wrapper/gradle-wrapper.properties +++ /dev/null @@ -1,5 +0,0 @@ -distributionBase=GRADLE_USER_HOME -distributionPath=wrapper/dists -zipStoreBase=GRADLE_USER_HOME -zipStorePath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-8.10.2-bin.zip diff --git a/formatters/gradlew b/formatters/gradlew deleted file mode 100755 index cccdd3d51..000000000 --- a/formatters/gradlew +++ /dev/null @@ -1,172 +0,0 @@ -#!/usr/bin/env sh - -############################################################################## -## -## Gradle start up script for UN*X -## -############################################################################## - -# Attempt to set APP_HOME -# Resolve links: $0 may be a link -PRG="$0" -# Need this for relative symlinks. -while [ -h "$PRG" ] ; do - ls=`ls -ld "$PRG"` - link=`expr "$ls" : '.*-> \(.*\)$'` - if expr "$link" : '/.*' > /dev/null; then - PRG="$link" - else - PRG=`dirname "$PRG"`"/$link" - fi -done -SAVED="`pwd`" -cd "`dirname \"$PRG\"`/" >/dev/null -APP_HOME="`pwd -P`" -cd "$SAVED" >/dev/null - -APP_NAME="Gradle" -APP_BASE_NAME=`basename "$0"` - -# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. -DEFAULT_JVM_OPTS="" - -# Use the maximum available, or set MAX_FD != -1 to use that value. -MAX_FD="maximum" - -warn () { - echo "$*" -} - -die () { - echo - echo "$*" - echo - exit 1 -} - -# OS specific support (must be 'true' or 'false'). -cygwin=false -msys=false -darwin=false -nonstop=false -case "`uname`" in - CYGWIN* ) - cygwin=true - ;; - Darwin* ) - darwin=true - ;; - MINGW* ) - msys=true - ;; - NONSTOP* ) - nonstop=true - ;; -esac - -CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar - -# Determine the Java command to use to start the JVM. -if [ -n "$JAVA_HOME" ] ; then - if [ -x "$JAVA_HOME/jre/sh/java" ] ; then - # IBM's JDK on AIX uses strange locations for the executables - JAVACMD="$JAVA_HOME/jre/sh/java" - else - JAVACMD="$JAVA_HOME/bin/java" - fi - if [ ! -x "$JAVACMD" ] ; then - die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME - -Please set the JAVA_HOME variable in your environment to match the -location of your Java installation." - fi -else - JAVACMD="java" - which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. - -Please set the JAVA_HOME variable in your environment to match the -location of your Java installation." -fi - -# Increase the maximum file descriptors if we can. -if [ "$cygwin" = "false" -a "$darwin" = "false" -a "$nonstop" = "false" ] ; then - MAX_FD_LIMIT=`ulimit -H -n` - if [ $? -eq 0 ] ; then - if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then - MAX_FD="$MAX_FD_LIMIT" - fi - ulimit -n $MAX_FD - if [ $? -ne 0 ] ; then - warn "Could not set maximum file descriptor limit: $MAX_FD" - fi - else - warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT" - fi -fi - -# For Darwin, add options to specify how the application appears in the dock -if $darwin; then - GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\"" -fi - -# For Cygwin, switch paths to Windows format before running java -if $cygwin ; then - APP_HOME=`cygpath --path --mixed "$APP_HOME"` - CLASSPATH=`cygpath --path --mixed "$CLASSPATH"` - JAVACMD=`cygpath --unix "$JAVACMD"` - - # We build the pattern for arguments to be converted via cygpath - ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null` - SEP="" - for dir in $ROOTDIRSRAW ; do - ROOTDIRS="$ROOTDIRS$SEP$dir" - SEP="|" - done - OURCYGPATTERN="(^($ROOTDIRS))" - # Add a user-defined pattern to the cygpath arguments - if [ "$GRADLE_CYGPATTERN" != "" ] ; then - OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)" - fi - # Now convert the arguments - kludge to limit ourselves to /bin/sh - i=0 - for arg in "$@" ; do - CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -` - CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option - - if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition - eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"` - else - eval `echo args$i`="\"$arg\"" - fi - i=$((i+1)) - done - case $i in - (0) set -- ;; - (1) set -- "$args0" ;; - (2) set -- "$args0" "$args1" ;; - (3) set -- "$args0" "$args1" "$args2" ;; - (4) set -- "$args0" "$args1" "$args2" "$args3" ;; - (5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;; - (6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;; - (7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;; - (8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;; - (9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;; - esac -fi - -# Escape application args -save () { - for i do printf %s\\n "$i" | sed "s/'/'\\\\''/g;1s/^/'/;\$s/\$/' \\\\/" ; done - echo " " -} -APP_ARGS=$(save "$@") - -# Collect all arguments for the java command, following the shell quoting and substitution rules -eval set -- $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS "\"-Dorg.gradle.appname=$APP_BASE_NAME\"" -classpath "\"$CLASSPATH\"" org.gradle.wrapper.GradleWrapperMain "$APP_ARGS" - -# by default we should be in the correct project dir, but when run from Finder on Mac, the cwd is wrong -if [ "$(uname)" = "Darwin" ] && [ "$HOME" = "$PWD" ]; then - cd "$(dirname "$0")" -fi - -exec "$JAVACMD" "$@" diff --git a/formatters/gradlew.bat b/formatters/gradlew.bat deleted file mode 100644 index f9553162f..000000000 --- a/formatters/gradlew.bat +++ /dev/null @@ -1,84 +0,0 @@ -@if "%DEBUG%" == "" @echo off -@rem ########################################################################## -@rem -@rem Gradle startup script for Windows -@rem -@rem ########################################################################## - -@rem Set local scope for the variables with windows NT shell -if "%OS%"=="Windows_NT" setlocal - -set DIRNAME=%~dp0 -if "%DIRNAME%" == "" set DIRNAME=. -set APP_BASE_NAME=%~n0 -set APP_HOME=%DIRNAME% - -@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. -set DEFAULT_JVM_OPTS= - -@rem Find java.exe -if defined JAVA_HOME goto findJavaFromJavaHome - -set JAVA_EXE=java.exe -%JAVA_EXE% -version >NUL 2>&1 -if "%ERRORLEVEL%" == "0" goto init - -echo. -echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. -echo. -echo Please set the JAVA_HOME variable in your environment to match the -echo location of your Java installation. - -goto fail - -:findJavaFromJavaHome -set JAVA_HOME=%JAVA_HOME:"=% -set JAVA_EXE=%JAVA_HOME%/bin/java.exe - -if exist "%JAVA_EXE%" goto init - -echo. -echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% -echo. -echo Please set the JAVA_HOME variable in your environment to match the -echo location of your Java installation. - -goto fail - -:init -@rem Get command-line arguments, handling Windows variants - -if not "%OS%" == "Windows_NT" goto win9xME_args - -:win9xME_args -@rem Slurp the command line arguments. -set CMD_LINE_ARGS= -set _SKIP=2 - -:win9xME_args_slurp -if "x%~1" == "x" goto execute - -set CMD_LINE_ARGS=%* - -:execute -@rem Setup the command line - -set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar - -@rem Execute Gradle -"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS% - -:end -@rem End local scope for the variables with windows NT shell -if "%ERRORLEVEL%"=="0" goto mainEnd - -:fail -rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of -rem the _cmd.exe /c_ return code! -if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1 -exit /b 1 - -:mainEnd -if "%OS%"=="Windows_NT" endlocal - -:omega diff --git a/formatters/settings.gradle b/formatters/settings.gradle deleted file mode 100644 index c98ec4958..000000000 --- a/formatters/settings.gradle +++ /dev/null @@ -1,3 +0,0 @@ -include ':spine-libgdx:spine-libgdx' -include ':spine-libgdx:spine-libgdx-tests' -include ':spine-libgdx:spine-skeletonviewer' diff --git a/formatters/setup-clang-format-docker.sh b/formatters/setup-clang-format-docker.sh new file mode 100755 index 000000000..f045aec92 --- /dev/null +++ b/formatters/setup-clang-format-docker.sh @@ -0,0 +1,51 @@ +#!/bin/bash +set -e + +echo "Setting up clang-format Docker wrapper..." + +# Pull the Docker image with clang-format 18 +echo "Pulling Docker image..." +docker pull silkeh/clang:18 + +# Create a wrapper script that runs clang-format in Docker +echo "Creating wrapper script..." +cat > /tmp/clang-format-wrapper <<'EOF' +#!/bin/bash +# Get the absolute path of the file being formatted +args=() +for arg in "$@"; do + if [[ -f "$arg" ]]; then + # Convert to absolute path + args+=("$(realpath "$arg")") + else + args+=("$arg") + fi +done + +# Find the project root (where .github directory is) +current_dir="$PWD" +while [[ "$current_dir" != "/" ]]; do + if [[ -d "$current_dir/.github" ]]; then + project_root="$current_dir" + break + fi + current_dir="$(dirname "$current_dir")" +done + +# If we didn't find project root, use current directory's parent +if [[ -z "$project_root" ]]; then + project_root="$(dirname "$PWD")" +fi + +# Run docker with the project root mounted +exec docker run --rm -i -v "$project_root:$project_root" -w "$PWD" silkeh/clang:18 clang-format "${args[@]}" +EOF + +# Install the wrapper +sudo mv /tmp/clang-format-wrapper /usr/local/bin/clang-format +sudo chmod +x /usr/local/bin/clang-format + +# Verify version and location +echo "Verifying installation..." +which clang-format +clang-format --version \ No newline at end of file diff --git a/spine-c/build.sh b/spine-c/build.sh index 5e22de200..b4ce0c8d1 100755 --- a/spine-c/build.sh +++ b/spine-c/build.sh @@ -32,7 +32,7 @@ fi # Run codegen if requested if [ "$1" = "codegen" ]; then - npx tsx codegen/src/index.ts + npx -y tsx codegen/src/index.ts # Format the generated C++ files echo "Formatting generated C++ files..." ../formatters/format.sh cpp diff --git a/spine-c/codegen/README.md b/spine-c/codegen/README.md index 93a5e0906..6250b03bf 100644 --- a/spine-c/codegen/README.md +++ b/spine-c/codegen/README.md @@ -133,7 +133,7 @@ Generated files are output to `../src/generated/`: # Install dependencies npm install -npx tsx src/index.ts +npx -y tsx src/index.ts # The generated files will be in ../src/generated/ ``` diff --git a/spine-csharp/spine-csharp.csproj b/spine-csharp/spine-csharp.csproj index 546174f58..3522bef16 100644 --- a/spine-csharp/spine-csharp.csproj +++ b/spine-csharp/spine-csharp.csproj @@ -1,113 +1,20 @@ - - + + - {94144E22-2431-4A8F-AC04-DEC22F7EDD8F} - 9.0.21022 - 2.0 - Debug - x86 - Library - Properties + netstandard2.0 Spine spine-csharp - v4.8 - - - v4.0 - Windows - HiDef - 99dfd52d-8beb-4e5c-a68b-365be39e8064 - Library - - - 3.5 - - - - true - bin\Debug\ - DEBUG;TRACE;WINDOWS - true - full - AnyCPU - false - prompt - - - bin\Release\ - TRACE;WINDOWS - true - true - pdbonly - AnyCPU - false - prompt + false + false + - - - - 4.0 - - + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + - - + \ No newline at end of file diff --git a/spine-csharp/spine-csharp.sln b/spine-csharp/spine-csharp.sln deleted file mode 100644 index d15d71314..000000000 --- a/spine-csharp/spine-csharp.sln +++ /dev/null @@ -1,23 +0,0 @@ - -Microsoft Visual Studio Solution File, Format Version 11.00 -# Visual Studio 2010 -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "spine-csharp", "spine-csharp.csproj", "{94144E22-2431-4A8F-AC04-DEC22F7EDD8F}" -EndProject -Global - GlobalSection(SolutionConfigurationPlatforms) = preSolution - Debug|Any CPU = Debug|Any CPU - Release|Any CPU = Release|Any CPU - EndGlobalSection - GlobalSection(ProjectConfigurationPlatforms) = postSolution - {94144E22-2431-4A8F-AC04-DEC22F7EDD8F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {94144E22-2431-4A8F-AC04-DEC22F7EDD8F}.Debug|Any CPU.Build.0 = Debug|Any CPU - {94144E22-2431-4A8F-AC04-DEC22F7EDD8F}.Release|Any CPU.ActiveCfg = Release|Any CPU - {94144E22-2431-4A8F-AC04-DEC22F7EDD8F}.Release|Any CPU.Build.0 = Release|Any CPU - EndGlobalSection - GlobalSection(SolutionProperties) = preSolution - HideSolutionNode = FALSE - EndGlobalSection - GlobalSection(MonoDevelopProperties) = preSolution - StartupItem = spine-csharp.csproj - EndGlobalSection -EndGlobal diff --git a/spine-csharp/src/ColorMono.cs b/spine-csharp/src/ColorMono.cs index fc59368e6..87f1040b3 100644 --- a/spine-csharp/src/ColorMono.cs +++ b/spine-csharp/src/ColorMono.cs @@ -51,7 +51,7 @@ namespace Spine { } public static implicit operator Color32F (Microsoft.Xna.Framework.Color xnaColor) { - return new Color32F(xnaColor); + return new Color32F(xnaColor); } public static implicit operator Microsoft.Xna.Framework.Color (Color32F c) { diff --git a/spine-csharp/src/IkConstraintPose.cs b/spine-csharp/src/IkConstraintPose.cs index b5cfdc96f..b62835b0c 100644 --- a/spine-csharp/src/IkConstraintPose.cs +++ b/spine-csharp/src/IkConstraintPose.cs @@ -36,7 +36,7 @@ namespace Spine { internal int bendDirection; internal bool compress, stretch; internal float mix, softness; - + public void Set (IkConstraintPose pose) { mix = pose.mix; softness = pose.softness; diff --git a/spine-flutter/example/lib/animated_login.dart b/spine-flutter/example/lib/animated_login.dart index c7f2d3674..686e837cc 100644 --- a/spine-flutter/example/lib/animated_login.dart +++ b/spine-flutter/example/lib/animated_login.dart @@ -36,24 +36,28 @@ class AnimatedLogin extends StatelessWidget { @override Widget build(BuildContext context) { reportLeaks(); - final controller = SpineWidgetController(onInitialized: (controller) { - controller.skeleton.setSkinByName("nate"); - controller.skeleton.setToSetupPose(); - controller.animationState.setAnimationByName(0, "login/look-left-down", true); - }); + final controller = SpineWidgetController( + onInitialized: (controller) { + controller.skeleton.setSkinByName("nate"); + controller.skeleton.setToSetupPose(); + controller.animationState.setAnimationByName(0, "login/look-left-down", true); + }, + ); return Scaffold( - appBar: AppBar(title: const Text('Animated login')), - body: Container( - margin: const EdgeInsets.all(15.0), - padding: const EdgeInsets.all(3.0), - decoration: BoxDecoration(border: Border.all(color: Colors.blueAccent)), - child: SpineWidget.fromAsset( - "assets/chibi/chibi-stickers.atlas", - "assets/chibi/chibi-stickers.skel", - controller, - boundsProvider: SkinAndAnimationBounds(skins: ["nate"], animation: "login/look-left-down"), - sizedByBounds: true, - ))); + appBar: AppBar(title: const Text('Animated login')), + body: Container( + margin: const EdgeInsets.all(15.0), + padding: const EdgeInsets.all(3.0), + decoration: BoxDecoration(border: Border.all(color: Colors.blueAccent)), + child: SpineWidget.fromAsset( + "assets/chibi/chibi-stickers.atlas", + "assets/chibi/chibi-stickers.skel", + controller, + boundsProvider: SkinAndAnimationBounds(skins: ["nate"], animation: "login/look-left-down"), + sizedByBounds: true, + ), + ), + ); } } diff --git a/spine-flutter/example/lib/animation_state_events.dart b/spine-flutter/example/lib/animation_state_events.dart index 86641452b..b9e25e627 100644 --- a/spine-flutter/example/lib/animation_state_events.dart +++ b/spine-flutter/example/lib/animation_state_events.dart @@ -8,32 +8,38 @@ class AnimationStateEvents extends StatelessWidget { @override Widget build(BuildContext context) { reportLeaks(); - final controller = SpineWidgetController(onInitialized: (controller) { - controller.skeleton.setScaleX(0.5); - controller.skeleton.setScaleY(0.5); - controller.skeleton.findSlot("gun")?.setColor(Color(1, 0, 0, 1)); - controller.animationStateData.setDefaultMix(0.2); - controller.animationState.setAnimationByName(0, "walk", true).setListener((type, trackEntry, event) { - print("Walk animation event $type"); - }); - controller.animationState.addAnimationByName(0, "jump", false, 2); - controller.animationState.addAnimationByName(0, "run", true, 0).setListener((type, trackEntry, event) { - print("Run animation event $type"); - }); - controller.animationState.setListener((type, trackEntry, event) { - if (type == EventType.event) { - print( - "User event: { name: ${event?.getData().getName()}, intValue: ${event?.getIntValue()}, floatValue: ${event?.getFloatValue()}, stringValue: ${event?.getStringValue()} }"); - } - }); - print("Current: ${controller.animationState.getCurrent(0)?.getAnimation().getName()}"); - }); + final controller = SpineWidgetController( + onInitialized: (controller) { + controller.skeleton.setScaleX(0.5); + controller.skeleton.setScaleY(0.5); + controller.skeleton.findSlot("gun")?.setColor(Color(1, 0, 0, 1)); + controller.animationStateData.setDefaultMix(0.2); + controller.animationState.setAnimationByName(0, "walk", true).setListener((type, trackEntry, event) { + print("Walk animation event $type"); + }); + controller.animationState.addAnimationByName(0, "jump", false, 2); + controller.animationState.addAnimationByName(0, "run", true, 0).setListener((type, trackEntry, event) { + print("Run animation event $type"); + }); + controller.animationState.setListener((type, trackEntry, event) { + if (type == EventType.event) { + print( + "User event: { name: ${event?.getData().getName()}, intValue: ${event?.getIntValue()}, floatValue: ${event?.getFloatValue()}, stringValue: ${event?.getStringValue()} }", + ); + } + }); + print("Current: ${controller.animationState.getCurrent(0)?.getAnimation().getName()}"); + }, + ); return Scaffold( - appBar: AppBar(title: const Text('Animation State Listener')), - body: Column(children: [ + appBar: AppBar(title: const Text('Animation State Listener')), + body: Column( + children: [ const Text("See output in console!"), - Expanded(child: SpineWidget.fromAsset("assets/spineboy.atlas", "assets/spineboy-pro.skel", controller)) - ])); + Expanded(child: SpineWidget.fromAsset("assets/spineboy.atlas", "assets/spineboy-pro.skel", controller)), + ], + ), + ); } } diff --git a/spine-flutter/example/lib/debug_rendering.dart b/spine-flutter/example/lib/debug_rendering.dart index d0c9363d3..5799fd90c 100644 --- a/spine-flutter/example/lib/debug_rendering.dart +++ b/spine-flutter/example/lib/debug_rendering.dart @@ -38,36 +38,40 @@ class DebugRendering extends StatelessWidget { reportLeaks(); const debugRenderer = DebugRenderer(); - final controller = SpineWidgetController(onInitialized: (controller) { - controller.animationState.setAnimationByName(0, "walk", true); -}, onBeforePaint: (controller, canvas) { - // Save the current transform and other canvas state - canvas.save(); + final controller = SpineWidgetController( + onInitialized: (controller) { + controller.animationState.setAnimationByName(0, "walk", true); + }, + onBeforePaint: (controller, canvas) { + // Save the current transform and other canvas state + canvas.save(); - // Get the current canvas transform an invert it, so we can work in the - // canvas coordinate system. - final currentMatrix = canvas.getTransform(); - final invertedMatrix = Matrix4.tryInvert(Matrix4.fromFloat64List(currentMatrix)); - if (invertedMatrix != null) { - canvas.transform(invertedMatrix.storage); - } + // Get the current canvas transform an invert it, so we can work in the + // canvas coordinate system. + final currentMatrix = canvas.getTransform(); + final invertedMatrix = Matrix4.tryInvert(Matrix4.fromFloat64List(currentMatrix)); + if (invertedMatrix != null) { + canvas.transform(invertedMatrix.storage); + } - // Draw something. - final Paint paint = Paint() - ..color = Colors.black - ..strokeWidth = 2.0; + // Draw something. + final Paint paint = Paint() + ..color = Colors.black + ..strokeWidth = 2.0; - canvas.drawLine( - Offset(0, 0), - Offset(canvas.getLocalClipBounds().width, canvas.getLocalClipBounds().height), - paint, - ); + canvas.drawLine( + Offset(0, 0), + Offset(canvas.getLocalClipBounds().width, canvas.getLocalClipBounds().height), + paint, + ); - // Restore the old transform and canvas state - canvas.restore(); -}, onAfterPaint: (controller, canvas, commands) { - debugRenderer.render(controller.drawable, canvas, commands); - }); + // Restore the old transform and canvas state + canvas.restore(); + }, + onAfterPaint: (controller, canvas, commands) { + debugRenderer.render(controller.drawable, canvas, commands); + }, + ); return Scaffold( appBar: AppBar(title: const Text('Debug Renderer')), diff --git a/spine-flutter/example/lib/dress_up.dart b/spine-flutter/example/lib/dress_up.dart index af5a39c55..15155792e 100644 --- a/spine-flutter/example/lib/dress_up.dart +++ b/spine-flutter/example/lib/dress_up.dart @@ -84,23 +84,26 @@ class DressUpState extends State { @override Widget build(BuildContext context) { - final controller = SpineWidgetController(onInitialized: (controller) { - controller.animationState.setAnimationByName(0, "dance", true); - }); + final controller = SpineWidgetController( + onInitialized: (controller) { + controller.animationState.setAnimationByName(0, "dance", true); + }, + ); return Scaffold( - appBar: AppBar(title: const Text('Dress Up')), - body: _skinImages.isEmpty - ? const SizedBox() - : Row(children: [ + appBar: AppBar(title: const Text('Dress Up')), + body: _skinImages.isEmpty + ? const SizedBox() + : Row( + children: [ SizedBox( width: thumbnailSize, child: ListView( - children: _skinImages.keys.map((skinName) { - var rawImageData = _skinImages[skinName]!; - var image = Image(image: RawImageProvider(rawImageData)); - var box = SizedBox(width: 200, height: 200, child: image); - return GestureDetector( + children: _skinImages.keys.map((skinName) { + var rawImageData = _skinImages[skinName]!; + var image = Image(image: RawImageProvider(rawImageData)); + var box = SizedBox(width: 200, height: 200, child: image); + return GestureDetector( onTap: () { _toggleSkin(skinName); setState(() {}); @@ -114,16 +117,22 @@ class DressUpState extends State { color: Colors.grey, backgroundBlendMode: painting.BlendMode.saturation, ), - child: box)); - }).toList()), + child: box, + ), + ); + }).toList(), + ), ), Expanded( - child: SpineWidget.fromDrawable( - _drawable, - controller, - boundsProvider: SkinAndAnimationBounds(skins: ["full-skins/girl"]), - )) - ])); + child: SpineWidget.fromDrawable( + _drawable, + controller, + boundsProvider: SkinAndAnimationBounds(skins: ["full-skins/girl"]), + ), + ), + ], + ), + ); } @override diff --git a/spine-flutter/example/lib/flame_example.dart b/spine-flutter/example/lib/flame_example.dart index e8e0d3986..3dff06c0f 100644 --- a/spine-flutter/example/lib/flame_example.dart +++ b/spine-flutter/example/lib/flame_example.dart @@ -50,8 +50,8 @@ class SpineComponent extends PositionComponent { Anchor super.anchor = Anchor.topLeft, super.children, super.priority, - }) : _ownsDrawable = ownsDrawable, - _boundsProvider = boundsProvider { + }) : _ownsDrawable = ownsDrawable, + _boundsProvider = boundsProvider { _drawable.update(0); _bounds = _boundsProvider.computeBounds(_drawable); size = Vector2(_bounds.width, _bounds.height); @@ -69,15 +69,17 @@ class SpineComponent extends PositionComponent { Iterable? children, int? priority, }) async { - return SpineComponent(await SkeletonDrawable.fromAsset(atlasFile, skeletonFile, bundle: bundle), - ownsDrawable: true, - boundsProvider: boundsProvider, - position: position, - scale: scale, - angle: angle, - anchor: anchor, - children: children, - priority: priority); + return SpineComponent( + await SkeletonDrawable.fromAsset(atlasFile, skeletonFile, bundle: bundle), + ownsDrawable: true, + boundsProvider: boundsProvider, + position: position, + scale: scale, + angle: angle, + anchor: anchor, + children: children, + priority: priority, + ); } void dispose() { @@ -114,8 +116,13 @@ class SimpleFlameExample extends FlameGame { // Load the Spineboy atlas and skeleton data from asset files // and create a SpineComponent from them, scaled down and // centered on the screen - spineboy = await SpineComponent.fromAssets("assets/spineboy.atlas", "assets/spineboy-pro.json", - scale: Vector2(0.4, 0.4), anchor: Anchor.center, position: Vector2(size.x / 2, size.y / 2)); + spineboy = await SpineComponent.fromAssets( + "assets/spineboy.atlas", + "assets/spineboy-pro.json", + scale: Vector2(0.4, 0.4), + anchor: Anchor.center, + position: Vector2(size.x / 2, size.y / 2), + ); // Set the "walk" animation on track 0 in looping mode spineboy.animationState.setAnimationByName(0, "walk", true); @@ -137,7 +144,7 @@ class DragonExample extends FlameGame { @override Future onLoad() async { cachedAtlas = await Atlas.fromAsset("assets/dragon.atlas"); - cachedSkeletonData = await SkeletonData.fromAsset(cachedAtlas, "assets/dragon-ess.skel"); + cachedSkeletonData = await SkeletonData.fromAsset(cachedAtlas, "assets/dragon-ess.skel"); final drawable = SkeletonDrawable(cachedAtlas, cachedSkeletonData, false); dragon = SpineComponent( drawable, @@ -205,6 +212,9 @@ class SpineFlameGameWidget extends StatelessWidget { @override Widget build(BuildContext context) { - return Scaffold(appBar: AppBar(title: const Text('Flame Integration')), body: GameWidget(game: game)); + return Scaffold( + appBar: AppBar(title: const Text('Flame Integration')), + body: GameWidget(game: game), + ); } } diff --git a/spine-flutter/example/lib/ik_following.dart b/spine-flutter/example/lib/ik_following.dart index dd1e5532d..4f6fc22c1 100644 --- a/spine-flutter/example/lib/ik_following.dart +++ b/spine-flutter/example/lib/ik_following.dart @@ -45,19 +45,22 @@ class IkFollowingState extends State { void initState() { super.initState(); - controller = SpineWidgetController(onInitialized: (controller) { - // Set the walk animation on track 0, let it loop - controller.animationState.setAnimationByName(0, "walk", true); - controller.animationState.setAnimationByName(1, "aim", true); - }, onAfterUpdateWorldTransforms: (controller) { - final worldPosition = crossHairPosition; - if (worldPosition == null) return; - final bone = controller.skeleton.findBone("crosshair")!; - final parent = bone.getParent()!; - final position = parent.worldToLocal(worldPosition.dx, worldPosition.dy); - bone.setX(position.x); - bone.setY(position.y); - }); + controller = SpineWidgetController( + onInitialized: (controller) { + // Set the walk animation on track 0, let it loop + controller.animationState.setAnimationByName(0, "walk", true); + controller.animationState.setAnimationByName(1, "aim", true); + }, + onAfterUpdateWorldTransforms: (controller) { + final worldPosition = crossHairPosition; + if (worldPosition == null) return; + final bone = controller.skeleton.findBone("crosshair")!; + final parent = bone.getParent()!; + final position = parent.worldToLocal(worldPosition.dx, worldPosition.dy); + bone.setX(position.x); + bone.setY(position.y); + }, + ); } void _updateBonePosition(Offset position) { @@ -69,11 +72,17 @@ class IkFollowingState extends State { reportLeaks(); return Scaffold( - appBar: AppBar(title: const Text('IK Following')), - body: GestureDetector( - onPanDown: (drag) => _updateBonePosition(drag.localPosition), - onPanUpdate: (drag) => _updateBonePosition(drag.localPosition), - child: SpineWidget.fromAsset("assets/spineboy.atlas", "assets/spineboy-pro.skel", controller, alignment: Alignment.centerLeft,), - )); + appBar: AppBar(title: const Text('IK Following')), + body: GestureDetector( + onPanDown: (drag) => _updateBonePosition(drag.localPosition), + onPanUpdate: (drag) => _updateBonePosition(drag.localPosition), + child: SpineWidget.fromAsset( + "assets/spineboy.atlas", + "assets/spineboy-pro.skel", + controller, + alignment: Alignment.centerLeft, + ), + ), + ); } } diff --git a/spine-flutter/example/lib/main.dart b/spine-flutter/example/lib/main.dart index 7480e7a81..ddc899934 100644 --- a/spine-flutter/example/lib/main.dart +++ b/spine-flutter/example/lib/main.dart @@ -46,130 +46,96 @@ class ExampleSelector extends StatelessWidget { Widget build(BuildContext context) { const spacer = SizedBox(height: 10); return Scaffold( - appBar: AppBar(title: const Text('Spine Examples')), - body: Center( - child: Column(mainAxisSize: MainAxisSize.min, children: [ - ElevatedButton( - child: const Text('Simple Animation'), - onPressed: () { - Navigator.push( - context, - MaterialPageRoute( - builder: (context) => const SimpleAnimation(), - ), - ); - }, - ), - spacer, - ElevatedButton( - child: const Text('Pause/Play animation'), - onPressed: () { - Navigator.push( - context, - MaterialPageRoute( - builder: (context) => const PlayPauseAnimation(), - ), - ); - }, - ), - spacer, - ElevatedButton( - child: const Text('Animation State Listener'), - onPressed: () { - Navigator.push( - context, - MaterialPageRoute( - builder: (context) => const AnimationStateEvents(), - ), - ); - }, - ), - spacer, - ElevatedButton( - child: const Text('Debug Rendering'), - onPressed: () { - Navigator.push( - context, - MaterialPageRoute( - builder: (context) => const DebugRendering(), - ), - ); - }, - ), - spacer, - ElevatedButton( - child: const Text('Dress Up'), - onPressed: () { - Navigator.push( - context, - MaterialPageRoute( - builder: (context) => const DressUp(), - ), - ); - }, - ), - spacer, - ElevatedButton( - child: const Text('IK Following'), - onPressed: () { - Navigator.push( - context, - MaterialPageRoute( - builder: (context) => const IkFollowing(), - ), - ); - }, - ), - spacer, - ElevatedButton( - child: const Text('Physics'), - onPressed: () { - Navigator.push( - context, - MaterialPageRoute( - builder: (context) => const PhysicsTest(), - ), - ); - }, - ), - spacer, - ElevatedButton( - child: const Text('Flame: Simple Example'), - onPressed: () { - Navigator.push( - context, - MaterialPageRoute( - builder: (context) => SpineFlameGameWidget(SimpleFlameExample()), - ), - ); - }, - ), - spacer, - ElevatedButton( - child: const Text('Flame: Pre-load and share Spine data'), - onPressed: () { - Navigator.push( - context, - MaterialPageRoute( - builder: (context) => SpineFlameGameWidget(PreloadAndShareSpineDataExample()), - ), - ); - }, - ), - spacer, - ElevatedButton( - child: const Text('Flame: Dragon Example'), - onPressed: () { - Navigator.push( - context, - MaterialPageRoute( - builder: (context) => SpineFlameGameWidget(DragonExample()), - ), - ); - }, - ), - spacer, - ]))); + appBar: AppBar(title: const Text('Spine Examples')), + body: Center( + child: Column( + mainAxisSize: MainAxisSize.min, + children: [ + ElevatedButton( + child: const Text('Simple Animation'), + onPressed: () { + Navigator.push(context, MaterialPageRoute(builder: (context) => const SimpleAnimation())); + }, + ), + spacer, + ElevatedButton( + child: const Text('Pause/Play animation'), + onPressed: () { + Navigator.push(context, MaterialPageRoute(builder: (context) => const PlayPauseAnimation())); + }, + ), + spacer, + ElevatedButton( + child: const Text('Animation State Listener'), + onPressed: () { + Navigator.push(context, MaterialPageRoute(builder: (context) => const AnimationStateEvents())); + }, + ), + spacer, + ElevatedButton( + child: const Text('Debug Rendering'), + onPressed: () { + Navigator.push(context, MaterialPageRoute(builder: (context) => const DebugRendering())); + }, + ), + spacer, + ElevatedButton( + child: const Text('Dress Up'), + onPressed: () { + Navigator.push(context, MaterialPageRoute(builder: (context) => const DressUp())); + }, + ), + spacer, + ElevatedButton( + child: const Text('IK Following'), + onPressed: () { + Navigator.push(context, MaterialPageRoute(builder: (context) => const IkFollowing())); + }, + ), + spacer, + ElevatedButton( + child: const Text('Physics'), + onPressed: () { + Navigator.push(context, MaterialPageRoute(builder: (context) => const PhysicsTest())); + }, + ), + spacer, + ElevatedButton( + child: const Text('Flame: Simple Example'), + onPressed: () { + Navigator.push( + context, + MaterialPageRoute(builder: (context) => SpineFlameGameWidget(SimpleFlameExample())), + ); + }, + ), + spacer, + ElevatedButton( + child: const Text('Flame: Pre-load and share Spine data'), + onPressed: () { + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => SpineFlameGameWidget(PreloadAndShareSpineDataExample()), + ), + ); + }, + ), + spacer, + ElevatedButton( + child: const Text('Flame: Dragon Example'), + onPressed: () { + Navigator.push( + context, + MaterialPageRoute(builder: (context) => SpineFlameGameWidget(DragonExample())), + ); + }, + ), + spacer, + ], + ), + ), + ); } } diff --git a/spine-flutter/example/lib/pause_play_animation.dart b/spine-flutter/example/lib/pause_play_animation.dart index 4ca894c9b..89df8b749 100644 --- a/spine-flutter/example/lib/pause_play_animation.dart +++ b/spine-flutter/example/lib/pause_play_animation.dart @@ -43,9 +43,11 @@ class PlayPauseAnimationState extends State { @override void initState() { super.initState(); - controller = SpineWidgetController(onInitialized: (controller) { - controller.animationState.setAnimationByName(0, "flying", true); - }); + controller = SpineWidgetController( + onInitialized: (controller) { + controller.animationState.setAnimationByName(0, "flying", true); + }, + ); } void _togglePlay() { diff --git a/spine-flutter/example/lib/physics.dart b/spine-flutter/example/lib/physics.dart index a77f13e50..27ebdd24f 100644 --- a/spine-flutter/example/lib/physics.dart +++ b/spine-flutter/example/lib/physics.dart @@ -46,26 +46,29 @@ class PhysicsState extends State { void initState() { super.initState(); - controller = SpineWidgetController(onInitialized: (controller) { - controller.animationState.setAnimationByName(0, "eyeblink-long", true); - controller.animationState.setAnimationByName(1, "wings-and-feet", true); - }, onAfterUpdateWorldTransforms: (controller) { - if (lastMousePosition == null) { - lastMousePosition = mousePosition; - return; - } - if (mousePosition == null) { - return; - } + controller = SpineWidgetController( + onInitialized: (controller) { + controller.animationState.setAnimationByName(0, "eyeblink-long", true); + controller.animationState.setAnimationByName(1, "wings-and-feet", true); + }, + onAfterUpdateWorldTransforms: (controller) { + if (lastMousePosition == null) { + lastMousePosition = mousePosition; + return; + } + if (mousePosition == null) { + return; + } - final dx = mousePosition!.dx - lastMousePosition!.dx; - final dy = mousePosition!.dy - lastMousePosition!.dy; - final position = controller.skeleton.getPosition(); - position.x += dx; - position.y += dy; - controller.skeleton.setPosition(position.x, position.y); - lastMousePosition = mousePosition; - }); + final dx = mousePosition!.dx - lastMousePosition!.dx; + final dy = mousePosition!.dy - lastMousePosition!.dy; + final position = controller.skeleton.getPosition(); + position.x += dx; + position.y += dy; + controller.skeleton.setPosition(position.x, position.y); + lastMousePosition = mousePosition; + }, + ); } void _updateBonePosition(Offset position) { @@ -77,11 +80,12 @@ class PhysicsState extends State { reportLeaks(); return Scaffold( - appBar: AppBar(title: const Text('Physics (drag anywhere)')), - body: GestureDetector( - onPanDown: (drag) => _updateBonePosition(drag.localPosition), - onPanUpdate: (drag) => _updateBonePosition(drag.localPosition), - child: SpineWidget.fromAsset("assets/celestial-circus.atlas", "assets/celestial-circus-pro.skel", controller), - )); + appBar: AppBar(title: const Text('Physics (drag anywhere)')), + body: GestureDetector( + onPanDown: (drag) => _updateBonePosition(drag.localPosition), + onPanUpdate: (drag) => _updateBonePosition(drag.localPosition), + child: SpineWidget.fromAsset("assets/celestial-circus.atlas", "assets/celestial-circus-pro.skel", controller), + ), + ); } } diff --git a/spine-flutter/example/lib/simple_animation.dart b/spine-flutter/example/lib/simple_animation.dart index d6ebf2fdb..a7f44b7cd 100644 --- a/spine-flutter/example/lib/simple_animation.dart +++ b/spine-flutter/example/lib/simple_animation.dart @@ -36,18 +36,20 @@ class SimpleAnimation extends StatelessWidget { @override Widget build(BuildContext context) { reportLeaks(); - final controller = SpineWidgetController(onInitialized: (controller) { - // Set the default mixing time between animations - controller.animationState.getData().setDefaultMix(0.2); - // Set the portal animation on track 0 - controller.animationState.setAnimationByName(0, "portal", true); - // Queue the run animation after the portal animation - controller.animationState.addAnimationByName(0, "run", true, 0); - }); + final controller = SpineWidgetController( + onInitialized: (controller) { + // Set the default mixing time between animations + controller.animationState.getData().setDefaultMix(0.2); + // Set the portal animation on track 0 + controller.animationState.setAnimationByName(0, "portal", true); + // Queue the run animation after the portal animation + controller.animationState.addAnimationByName(0, "run", true, 0); + }, + ); return Scaffold( appBar: AppBar(title: const Text('Simple Animation')), - body: SpineWidget.fromAsset("assets/spineboy.atlas", "assets/spineboy-pro.skel", controller) + body: SpineWidget.fromAsset("assets/spineboy.atlas", "assets/spineboy-pro.skel", controller), ); } } diff --git a/spine-flutter/lib/init_web.dart b/spine-flutter/lib/init_web.dart index 02e07d597..9a609e09d 100644 --- a/spine-flutter/lib/init_web.dart +++ b/spine-flutter/lib/init_web.dart @@ -91,8 +91,9 @@ Future initSpineFlutterFFI(bool useStaticLinkage) async { registerOpaqueType(); await js.importLibrary('assets/packages/spine_flutter/lib/assets/libspine_flutter.js'); - Uint8List wasmBinaries = - (await rootBundle.load('packages/spine_flutter/lib/assets/libspine_flutter.wasm')).buffer.asUint8List(); + Uint8List wasmBinaries = (await rootBundle.load( + 'packages/spine_flutter/lib/assets/libspine_flutter.wasm', + )).buffer.asUint8List(); _module = await EmscriptenModule.compile(wasmBinaries, 'libspine_flutter'); } Module? m = _module; diff --git a/spine-flutter/lib/raw_image_provider.dart b/spine-flutter/lib/raw_image_provider.dart index a0eddb29f..911a4b3bc 100644 --- a/spine-flutter/lib/raw_image_provider.dart +++ b/spine-flutter/lib/raw_image_provider.dart @@ -32,12 +32,7 @@ class RawImageProvider extends ImageProvider<_RawImageKey> { final double? scale; final int? targetWidth; final int? targetHeight; - RawImageProvider( - this.image, { - this.scale = 1.0, - this.targetWidth, - this.targetHeight, - }); + RawImageProvider(this.image, {this.scale = 1.0, this.targetWidth, this.targetHeight}); @override ImageStreamCompleter loadImage(_RawImageKey key, ImageDecoderCallback decode) { @@ -69,8 +64,7 @@ class RawImageProvider extends ImageProvider<_RawImageKey> { debugPrint('ImageDescriptor: ${descriptor.width}x${descriptor.height}'); return true; }()); - return descriptor.instantiateCodec( - targetWidth: targetWidth, targetHeight: targetHeight); + return descriptor.instantiateCodec(targetWidth: targetWidth, targetHeight: targetHeight); } } @@ -105,16 +99,10 @@ class RawImageData { final int height; final ui.PixelFormat pixelFormat; - RawImageData( - this.pixels, - this.width, - this.height, { - this.pixelFormat = ui.PixelFormat.rgba8888, - }); + RawImageData(this.pixels, this.width, this.height, {this.pixelFormat = ui.PixelFormat.rgba8888}); _RawImageKey? _key; _RawImageKey _obtainKey() { - return _key ??= - _RawImageKey(width, height, pixelFormat.index, md5.convert(pixels)); + return _key ??= _RawImageKey(width, height, pixelFormat.index, md5.convert(pixels)); } } diff --git a/spine-flutter/lib/spine_flutter.dart b/spine-flutter/lib/spine_flutter.dart index 65e7c6946..d32175bd5 100644 --- a/spine-flutter/lib/spine_flutter.dart +++ b/spine-flutter/lib/spine_flutter.dart @@ -39,7 +39,6 @@ import 'package:flutter/services.dart'; import 'package:http/http.dart' as http; import 'package:path/path.dart' as path; - import 'ffi_proxy.dart'; import 'init.dart' if (dart.library.html) 'init_web.dart'; import 'spine_flutter_bindings_generated.dart'; @@ -137,9 +136,13 @@ class Atlas { Map paints = {}; for (final blendMode in BlendMode.values) { paints[blendMode] = Paint() - ..shader = ImageShader(image, TileMode.clamp, TileMode.clamp, Matrix4 - .identity() - .storage, filterQuality: Atlas.filterQuality) + ..shader = ImageShader( + image, + TileMode.clamp, + TileMode.clamp, + Matrix4.identity().storage, + filterQuality: Atlas.filterQuality, + ) ..isAntiAlias = true ..blendMode = blendMode.canvasBlendMode; } @@ -747,8 +750,12 @@ class BoneData { /// rendered at runtime. Color getColor() { final color = _bindings.spine_bone_data_get_color(_data); - return Color(_bindings.spine_color_get_r(color), _bindings.spine_color_get_g(color), _bindings.spine_color_get_b(color), - _bindings.spine_color_get_a(color)); + return Color( + _bindings.spine_color_get_r(color), + _bindings.spine_color_get_g(color), + _bindings.spine_color_get_b(color), + _bindings.spine_color_get_a(color), + ); } void setColor(double r, double g, double b, double a) { @@ -797,7 +804,15 @@ class Bone { /// /// See [World transform](http://esotericsoftware.com/spine-runtime-skeletons#World-transforms) in the Spine /// Runtimes Guide. - void updateWorldTransformWith(double x, double y, double rotation, double scaleX, double scaleY, double shearX, double shearY) { + void updateWorldTransformWith( + double x, + double y, + double rotation, + double scaleX, + double scaleY, + double shearX, + double shearY, + ) { _bindings.spine_bone_update_world_transform_with(_bone, x, y, rotation, scaleX, scaleY, shearX, shearY); } @@ -1123,8 +1138,12 @@ class SlotData { /// color tinting. Color getColor() { final color = _bindings.spine_slot_data_get_color(_data); - return Color(_bindings.spine_color_get_r(color), _bindings.spine_color_get_g(color), _bindings.spine_color_get_b(color), - _bindings.spine_color_get_a(color)); + return Color( + _bindings.spine_color_get_r(color), + _bindings.spine_color_get_g(color), + _bindings.spine_color_get_b(color), + _bindings.spine_color_get_a(color), + ); } void setColor(double r, double g, double b, double a) { @@ -1135,8 +1154,12 @@ class SlotData { /// color's alpha is not used. Color getDarkColor() { final color = _bindings.spine_slot_data_get_dark_color(_data); - return Color(_bindings.spine_color_get_r(color), _bindings.spine_color_get_g(color), _bindings.spine_color_get_b(color), - _bindings.spine_color_get_a(color)); + return Color( + _bindings.spine_color_get_r(color), + _bindings.spine_color_get_g(color), + _bindings.spine_color_get_b(color), + _bindings.spine_color_get_a(color), + ); } void setDarkColor(double r, double g, double b, double a) { @@ -1211,8 +1234,12 @@ class Slot { /// color tinting. Color getColor() { final color = _bindings.spine_slot_get_color(_slot); - return Color(_bindings.spine_color_get_r(color), _bindings.spine_color_get_g(color), _bindings.spine_color_get_b(color), - _bindings.spine_color_get_a(color)); + return Color( + _bindings.spine_color_get_r(color), + _bindings.spine_color_get_g(color), + _bindings.spine_color_get_b(color), + _bindings.spine_color_get_a(color), + ); } void setColor(Color color) { @@ -1223,8 +1250,12 @@ class Slot { /// color's alpha is not used. Color getDarkColor() { final color = _bindings.spine_slot_get_dark_color(_slot); - return Color(_bindings.spine_color_get_r(color), _bindings.spine_color_get_g(color), _bindings.spine_color_get_b(color), - _bindings.spine_color_get_a(color)); + return Color( + _bindings.spine_color_get_r(color), + _bindings.spine_color_get_g(color), + _bindings.spine_color_get_b(color), + _bindings.spine_color_get_a(color), + ); } void setDarkColor(Color color) { @@ -1574,8 +1605,12 @@ class RegionAttachment extends Attachment { Color getColor() { final color = _bindings.spine_region_attachment_get_color(_attachment); - return Color(_bindings.spine_color_get_r(color), _bindings.spine_color_get_g(color), _bindings.spine_color_get_b(color), - _bindings.spine_color_get_a(color)); + return Color( + _bindings.spine_color_get_r(color), + _bindings.spine_color_get_g(color), + _bindings.spine_color_get_b(color), + _bindings.spine_color_get_a(color), + ); } void setColor(double r, double g, double b, double a) { @@ -1662,7 +1697,9 @@ class VertexAttachment extends Attachment { void setTimelineAttachment(Attachment? attachment) { _bindings.spine_vertex_attachment_set_timeline_attachment( - _attachment.cast(), attachment == null ? nullptr : attachment._attachment.cast()); + _attachment.cast(), + attachment == null ? nullptr : attachment._attachment.cast(), + ); } } @@ -1713,8 +1750,12 @@ class MeshAttachment extends VertexAttachment { Color getColor() { final color = _bindings.spine_mesh_attachment_get_color(_attachment); - return Color(_bindings.spine_color_get_r(color), _bindings.spine_color_get_g(color), _bindings.spine_color_get_b(color), - _bindings.spine_color_get_a(color)); + return Color( + _bindings.spine_color_get_r(color), + _bindings.spine_color_get_g(color), + _bindings.spine_color_get_b(color), + _bindings.spine_color_get_a(color), + ); } void setColor(double r, double g, double b, double a) { @@ -1798,8 +1839,12 @@ class ClippingAttachment extends VertexAttachment { /// attachments are not usually rendered at runtime. Color getColor() { final color = _bindings.spine_clipping_attachment_get_color(_attachment); - return Color(_bindings.spine_color_get_r(color), _bindings.spine_color_get_g(color), _bindings.spine_color_get_b(color), - _bindings.spine_color_get_a(color)); + return Color( + _bindings.spine_color_get_r(color), + _bindings.spine_color_get_g(color), + _bindings.spine_color_get_b(color), + _bindings.spine_color_get_a(color), + ); } void setColor(double r, double g, double b, double a) { @@ -1819,8 +1864,12 @@ class BoundingBoxAttachment extends VertexAttachment { /// rendered at runtime. Color getColor() { final color = _bindings.spine_path_attachment_get_color(_attachment); - return Color(_bindings.spine_color_get_r(color), _bindings.spine_color_get_g(color), _bindings.spine_color_get_b(color), - _bindings.spine_color_get_a(color)); + return Color( + _bindings.spine_color_get_r(color), + _bindings.spine_color_get_g(color), + _bindings.spine_color_get_b(color), + _bindings.spine_color_get_a(color), + ); } void setColor(double r, double g, double b, double a) { @@ -1919,8 +1972,12 @@ class PointAttachment extends Attachment { /// attachments are not usually rendered at runtime. Color getColor() { final color = _bindings.spine_point_attachment_get_color(_attachment); - return Color(_bindings.spine_color_get_r(color), _bindings.spine_color_get_g(color), _bindings.spine_color_get_b(color), - _bindings.spine_color_get_a(color)); + return Color( + _bindings.spine_color_get_r(color), + _bindings.spine_color_get_g(color), + _bindings.spine_color_get_b(color), + _bindings.spine_color_get_a(color), + ); } void setColor(double r, double g, double b, double a) { @@ -1968,7 +2025,12 @@ class Skin { /// Adds an attachment to the skin for the specified slot index and name. void setAttachment(int slotIndex, String name, Attachment? attachment) { final nativeName = name.toNativeUtf8(allocator: _allocator); - _bindings.spine_skin_set_attachment(_skin, slotIndex, nativeName.cast(), attachment == null ? nullptr : attachment._attachment.cast()); + _bindings.spine_skin_set_attachment( + _skin, + slotIndex, + nativeName.cast(), + attachment == null ? nullptr : attachment._attachment.cast(), + ); _allocator.free(nativeName); } @@ -2007,12 +2069,15 @@ class Skin { for (int i = 0; i < numEntries; i++) { final entry = _bindings.spine_skin_entries_get_entry(entries, i); Pointer name = _bindings.spine_skin_entry_get_name(entry).cast(); - result.add(SkinEntry( + result.add( + SkinEntry( _bindings.spine_skin_entry_get_slot_index(entry), name.toDartString(), _bindings.spine_skin_entry_get_attachment(entry).address == nullptr.address ? null - : Attachment._toSubclass(_bindings.spine_skin_entry_get_attachment(entry)))); + : Attachment._toSubclass(_bindings.spine_skin_entry_get_attachment(entry)), + ), + ); } return result; } @@ -2836,7 +2901,11 @@ class Skeleton { Attachment? getAttachmentByName(String slotName, String attachmentName) { final slotNameNative = slotName.toNativeUtf8(allocator: _allocator); final attachmentNameNative = attachmentName.toNativeUtf8(allocator: _allocator); - final attachment = _bindings.spine_skeleton_get_attachment_by_name(_skeleton, slotNameNative.cast(), attachmentNameNative.cast()); + final attachment = _bindings.spine_skeleton_get_attachment_by_name( + _skeleton, + slotNameNative.cast(), + attachmentNameNative.cast(), + ); _allocator.free(slotNameNative); _allocator.free(attachmentNameNative); if (attachment.address == nullptr.address) return null; @@ -2898,8 +2967,12 @@ class Skeleton { /// Returns the axis aligned bounding box (AABB) of the region and mesh attachments for the current pose. Bounds getBounds() { final nativeBounds = _bindings.spine_skeleton_get_bounds(_skeleton); - final bounds = Bounds(_bindings.spine_bounds_get_x(nativeBounds), _bindings.spine_bounds_get_y(nativeBounds), - _bindings.spine_bounds_get_width(nativeBounds), _bindings.spine_bounds_get_height(nativeBounds)); + final bounds = Bounds( + _bindings.spine_bounds_get_x(nativeBounds), + _bindings.spine_bounds_get_y(nativeBounds), + _bindings.spine_bounds_get_width(nativeBounds), + _bindings.spine_bounds_get_height(nativeBounds), + ); return bounds; } @@ -2993,8 +3066,12 @@ class Skeleton { /// The color to tint all the skeleton's attachments. Color getColor() { final color = _bindings.spine_skeleton_get_color(_skeleton); - return Color(_bindings.spine_color_get_r(color), _bindings.spine_color_get_g(color), _bindings.spine_color_get_b(color), - _bindings.spine_color_get_a(color)); + return Color( + _bindings.spine_color_get_r(color), + _bindings.spine_color_get_g(color), + _bindings.spine_color_get_b(color), + _bindings.spine_color_get_a(color), + ); } void setColor(Color color) { @@ -3508,7 +3585,7 @@ enum EventType { /// /// Because this event is triggered at the end of [AnimationState.apply], any animations set in response to /// the event won't be applied until the next time the [AnimationState] is applied. - event + event, } /// Stores the setup pose values for an [Event]. @@ -3801,7 +3878,12 @@ class AnimationState { /// See [setAnimation]. TrackEntry setAnimationByName(int trackIndex, String animationName, bool loop) { final animation = animationName.toNativeUtf8(allocator: _allocator); - final entry = _bindings.spine_animation_state_set_animation_by_name(_state, trackIndex, animation.cast(), loop ? -1 : 0); + final entry = _bindings.spine_animation_state_set_animation_by_name( + _state, + trackIndex, + animation.cast(), + loop ? -1 : 0, + ); _allocator.free(animation); if (entry.address == nullptr.address) throw Exception("Couldn't set animation $animationName"); return TrackEntry._(entry, this); @@ -3816,7 +3898,12 @@ class AnimationState { /// Returns a track entry to allow further customization of animation playback. References to the track entry must not be kept /// after the [EventType.dispose] event occurs. TrackEntry setAnimation(int trackIndex, Animation animation, bool loop) { - final entry = _bindings.spine_animation_state_set_animation(_state, trackIndex, animation._animation, loop ? -1 : 0); + final entry = _bindings.spine_animation_state_set_animation( + _state, + trackIndex, + animation._animation, + loop ? -1 : 0, + ); if (entry.address == nullptr.address) throw Exception("Couldn't set animation ${animation.getName()}"); return TrackEntry._(entry, this); } @@ -3826,7 +3913,13 @@ class AnimationState { /// See [addAnimation]. TrackEntry addAnimationByName(int trackIndex, String animationName, bool loop, double delay) { final animation = animationName.toNativeUtf8(allocator: _allocator); - final entry = _bindings.spine_animation_state_add_animation_by_name(_state, trackIndex, animation.cast(), loop ? -1 : 0, delay); + final entry = _bindings.spine_animation_state_add_animation_by_name( + _state, + trackIndex, + animation.cast(), + loop ? -1 : 0, + delay, + ); _allocator.free(animation); if (entry.address == nullptr.address) throw Exception("Couldn't add animation $animationName"); return TrackEntry._(entry, this); @@ -3843,7 +3936,13 @@ class AnimationState { /// Returns a track entry to allow further customization of animation playback. References to the track entry must not be kept /// after the [EventType.dispose] event occurs. TrackEntry addAnimation(int trackIndex, Animation animation, bool loop, double delay) { - final entry = _bindings.spine_animation_state_add_animation(_state, trackIndex, animation._animation, loop ? -1 : 0, delay); + final entry = _bindings.spine_animation_state_add_animation( + _state, + trackIndex, + animation._animation, + loop ? -1 : 0, + delay, + ); if (entry.address == nullptr.address) throw Exception("Couldn't add animation ${animation.getName()}"); return TrackEntry._(entry, this); } @@ -3966,8 +4065,10 @@ class SkeletonDrawable { _drawable = _bindings.spine_skeleton_drawable_create(skeletonData._data); skeleton = Skeleton._(_bindings.spine_skeleton_drawable_get_skeleton(_drawable)); animationStateData = AnimationStateData._(_bindings.spine_skeleton_drawable_get_animation_state_data(_drawable)); - animationState = AnimationState._(_bindings.spine_skeleton_drawable_get_animation_state(_drawable), - _bindings.spine_skeleton_drawable_get_animation_state_events(_drawable)); + animationState = AnimationState._( + _bindings.spine_skeleton_drawable_get_animation_state(_drawable), + _bindings.spine_skeleton_drawable_get_animation_state_events(_drawable), + ); skeleton.updateWorldTransform(Physics.none); } @@ -4030,7 +4131,11 @@ class SkeletonDrawable { List renderToCanvas(Canvas canvas) { var commands = render(); for (final cmd in commands) { - canvas.drawVertices(cmd.vertices, rendering.BlendMode.modulate, atlas.atlasPagePaints[cmd.atlasPageIndex][cmd.blendMode]!); + canvas.drawVertices( + cmd.vertices, + rendering.BlendMode.modulate, + atlas.atlasPagePaints[cmd.atlasPageIndex][cmd.blendMode]!, + ); } return commands; } @@ -4070,10 +4175,10 @@ class SkeletonDrawable { /// Scales and centers the skeleton to fit the within the bounds of [width] and [height]. Future renderToRawImageData(double width, double height, int bgColor) async { final recorder = renderToPictureRecorder(width, height, bgColor); - var rawImageData = - (await (await recorder.endRecording().toImage(width.toInt(), height.toInt())).toByteData(format: ImageByteFormat.rawRgba))! - .buffer - .asUint8List(); + var rawImageData = (await (await recorder.endRecording().toImage( + width.toInt(), + height.toInt(), + )).toByteData(format: ImageByteFormat.rawRgba))!.buffer.asUint8List(); return RawImageData(rawImageData, width.toInt(), height.toInt()); } @@ -4135,7 +4240,13 @@ class RenderCommand { if (colors.isNotEmpty && colors[0] == -1) { vertices = Vertices.raw(VertexMode.triangles, positions, textureCoordinates: uvs, indices: indices); } else { - vertices = Vertices.raw(VertexMode.triangles, positions, textureCoordinates: uvs, colors: colors, indices: indices); + vertices = Vertices.raw( + VertexMode.triangles, + positions, + textureCoordinates: uvs, + colors: colors, + indices: indices, + ); } } else { // On the web, rendering is done through CanvasKit, which requires copies of the native data. @@ -4143,7 +4254,13 @@ class RenderCommand { final uvsCopy = Float32List.fromList(uvs); final colorsCopy = Int32List.fromList(colors); final indicesCopy = Uint16List.fromList(indices); - vertices = Vertices.raw(VertexMode.triangles, positionsCopy, textureCoordinates: uvsCopy, colors: colorsCopy, indices: indicesCopy); + vertices = Vertices.raw( + VertexMode.triangles, + positionsCopy, + textureCoordinates: uvsCopy, + colors: colorsCopy, + indices: indicesCopy, + ); } } } @@ -4158,7 +4275,10 @@ class DebugRenderer { ..color = material.Colors.blue ..style = PaintingStyle.fill; for (final bone in drawable.skeleton.getBones()) { - canvas.drawRect(Rect.fromCenter(center: Offset(bone.getWorldX(), bone.getWorldY()), width: 5, height: 5), bonePaint); + canvas.drawRect( + Rect.fromCenter(center: Offset(bone.getWorldX(), bone.getWorldY()), width: 5, height: 5), + bonePaint, + ); } } } diff --git a/spine-flutter/lib/spine_flutter_bindings_generated.dart b/spine-flutter/lib/spine_flutter_bindings_generated.dart index 2f38c9b1c..679d09ead 100644 --- a/spine-flutter/lib/spine_flutter_bindings_generated.dart +++ b/spine-flutter/lib/spine_flutter_bindings_generated.dart @@ -14,1426 +14,926 @@ import 'ffi_proxy.dart' as ffi; /// class SpineFlutterBindings { /// Holds the symbol lookup function. - final ffi.Pointer Function(String symbolName) - _lookup; + final ffi.Pointer Function(String symbolName) _lookup; /// The symbols are looked up in [dynamicLibrary]. - SpineFlutterBindings(ffi.DynamicLibrary dynamicLibrary) - : _lookup = dynamicLibrary.lookup; + SpineFlutterBindings(ffi.DynamicLibrary dynamicLibrary) : _lookup = dynamicLibrary.lookup; /// The symbols are looked up with [lookup]. - SpineFlutterBindings.fromLookup( - ffi.Pointer Function(String symbolName) - lookup) - : _lookup = lookup; + SpineFlutterBindings.fromLookup(ffi.Pointer Function(String symbolName) lookup) + : _lookup = lookup; int spine_major_version() { return _spine_major_version(); } - late final _spine_major_versionPtr = - _lookup>('spine_major_version'); - late final _spine_major_version = - _spine_major_versionPtr.asFunction(); + late final _spine_major_versionPtr = _lookup>('spine_major_version'); + late final _spine_major_version = _spine_major_versionPtr.asFunction(); int spine_minor_version() { return _spine_minor_version(); } - late final _spine_minor_versionPtr = - _lookup>('spine_minor_version'); - late final _spine_minor_version = - _spine_minor_versionPtr.asFunction(); + late final _spine_minor_versionPtr = _lookup>('spine_minor_version'); + late final _spine_minor_version = _spine_minor_versionPtr.asFunction(); - void spine_enable_debug_extension( - int enable, - ) { - return _spine_enable_debug_extension( - enable, - ); + void spine_enable_debug_extension(int enable) { + return _spine_enable_debug_extension(enable); } - late final _spine_enable_debug_extensionPtr = - _lookup>( - 'spine_enable_debug_extension'); - late final _spine_enable_debug_extension = - _spine_enable_debug_extensionPtr.asFunction(); + late final _spine_enable_debug_extensionPtr = _lookup>( + 'spine_enable_debug_extension', + ); + late final _spine_enable_debug_extension = _spine_enable_debug_extensionPtr.asFunction(); void spine_report_leaks() { return _spine_report_leaks(); } - late final _spine_report_leaksPtr = - _lookup>('spine_report_leaks'); - late final _spine_report_leaks = - _spine_report_leaksPtr.asFunction(); + late final _spine_report_leaksPtr = _lookup>('spine_report_leaks'); + late final _spine_report_leaks = _spine_report_leaksPtr.asFunction(); - double spine_color_get_r( - spine_color color, - ) { - return _spine_color_get_r( - color, - ); + double spine_color_get_r(spine_color color) { + return _spine_color_get_r(color); } - late final _spine_color_get_rPtr = - _lookup>( - 'spine_color_get_r'); - late final _spine_color_get_r = - _spine_color_get_rPtr.asFunction(); + late final _spine_color_get_rPtr = _lookup>('spine_color_get_r'); + late final _spine_color_get_r = _spine_color_get_rPtr.asFunction(); - double spine_color_get_g( - spine_color color, - ) { - return _spine_color_get_g( - color, - ); + double spine_color_get_g(spine_color color) { + return _spine_color_get_g(color); } - late final _spine_color_get_gPtr = - _lookup>( - 'spine_color_get_g'); - late final _spine_color_get_g = - _spine_color_get_gPtr.asFunction(); + late final _spine_color_get_gPtr = _lookup>('spine_color_get_g'); + late final _spine_color_get_g = _spine_color_get_gPtr.asFunction(); - double spine_color_get_b( - spine_color color, - ) { - return _spine_color_get_b( - color, - ); + double spine_color_get_b(spine_color color) { + return _spine_color_get_b(color); } - late final _spine_color_get_bPtr = - _lookup>( - 'spine_color_get_b'); - late final _spine_color_get_b = - _spine_color_get_bPtr.asFunction(); + late final _spine_color_get_bPtr = _lookup>('spine_color_get_b'); + late final _spine_color_get_b = _spine_color_get_bPtr.asFunction(); - double spine_color_get_a( - spine_color color, - ) { - return _spine_color_get_a( - color, - ); + double spine_color_get_a(spine_color color) { + return _spine_color_get_a(color); } - late final _spine_color_get_aPtr = - _lookup>( - 'spine_color_get_a'); - late final _spine_color_get_a = - _spine_color_get_aPtr.asFunction(); + late final _spine_color_get_aPtr = _lookup>('spine_color_get_a'); + late final _spine_color_get_a = _spine_color_get_aPtr.asFunction(); - double spine_bounds_get_x( - spine_bounds bounds, - ) { - return _spine_bounds_get_x( - bounds, - ); + double spine_bounds_get_x(spine_bounds bounds) { + return _spine_bounds_get_x(bounds); } - late final _spine_bounds_get_xPtr = - _lookup>( - 'spine_bounds_get_x'); - late final _spine_bounds_get_x = - _spine_bounds_get_xPtr.asFunction(); + late final _spine_bounds_get_xPtr = _lookup>( + 'spine_bounds_get_x', + ); + late final _spine_bounds_get_x = _spine_bounds_get_xPtr.asFunction(); - double spine_bounds_get_y( - spine_bounds bounds, - ) { - return _spine_bounds_get_y( - bounds, - ); + double spine_bounds_get_y(spine_bounds bounds) { + return _spine_bounds_get_y(bounds); } - late final _spine_bounds_get_yPtr = - _lookup>( - 'spine_bounds_get_y'); - late final _spine_bounds_get_y = - _spine_bounds_get_yPtr.asFunction(); + late final _spine_bounds_get_yPtr = _lookup>( + 'spine_bounds_get_y', + ); + late final _spine_bounds_get_y = _spine_bounds_get_yPtr.asFunction(); - double spine_bounds_get_width( - spine_bounds bounds, - ) { - return _spine_bounds_get_width( - bounds, - ); + double spine_bounds_get_width(spine_bounds bounds) { + return _spine_bounds_get_width(bounds); } - late final _spine_bounds_get_widthPtr = - _lookup>( - 'spine_bounds_get_width'); - late final _spine_bounds_get_width = - _spine_bounds_get_widthPtr.asFunction(); + late final _spine_bounds_get_widthPtr = _lookup>( + 'spine_bounds_get_width', + ); + late final _spine_bounds_get_width = _spine_bounds_get_widthPtr.asFunction(); - double spine_bounds_get_height( - spine_bounds bounds, - ) { - return _spine_bounds_get_height( - bounds, - ); + double spine_bounds_get_height(spine_bounds bounds) { + return _spine_bounds_get_height(bounds); } - late final _spine_bounds_get_heightPtr = - _lookup>( - 'spine_bounds_get_height'); - late final _spine_bounds_get_height = - _spine_bounds_get_heightPtr.asFunction(); + late final _spine_bounds_get_heightPtr = _lookup>( + 'spine_bounds_get_height', + ); + late final _spine_bounds_get_height = _spine_bounds_get_heightPtr.asFunction(); - double spine_vector_get_x( - spine_vector vector, - ) { - return _spine_vector_get_x( - vector, - ); + double spine_vector_get_x(spine_vector vector) { + return _spine_vector_get_x(vector); } - late final _spine_vector_get_xPtr = - _lookup>( - 'spine_vector_get_x'); - late final _spine_vector_get_x = - _spine_vector_get_xPtr.asFunction(); + late final _spine_vector_get_xPtr = _lookup>( + 'spine_vector_get_x', + ); + late final _spine_vector_get_x = _spine_vector_get_xPtr.asFunction(); - double spine_vector_get_y( - spine_vector vector, - ) { - return _spine_vector_get_y( - vector, - ); + double spine_vector_get_y(spine_vector vector) { + return _spine_vector_get_y(vector); } - late final _spine_vector_get_yPtr = - _lookup>( - 'spine_vector_get_y'); - late final _spine_vector_get_y = - _spine_vector_get_yPtr.asFunction(); + late final _spine_vector_get_yPtr = _lookup>( + 'spine_vector_get_y', + ); + late final _spine_vector_get_y = _spine_vector_get_yPtr.asFunction(); - spine_atlas spine_atlas_load( - ffi.Pointer atlasData, - ) { - return _spine_atlas_load( - atlasData, - ); + spine_atlas spine_atlas_load(ffi.Pointer atlasData) { + return _spine_atlas_load(atlasData); } - late final _spine_atlas_loadPtr = - _lookup)>>( - 'spine_atlas_load'); - late final _spine_atlas_load = _spine_atlas_loadPtr - .asFunction)>(); + late final _spine_atlas_loadPtr = _lookup)>>( + 'spine_atlas_load', + ); + late final _spine_atlas_load = _spine_atlas_loadPtr.asFunction)>(); - int spine_atlas_get_num_image_paths( - spine_atlas atlas, - ) { - return _spine_atlas_get_num_image_paths( - atlas, - ); + int spine_atlas_get_num_image_paths(spine_atlas atlas) { + return _spine_atlas_get_num_image_paths(atlas); } - late final _spine_atlas_get_num_image_pathsPtr = - _lookup>( - 'spine_atlas_get_num_image_paths'); - late final _spine_atlas_get_num_image_paths = - _spine_atlas_get_num_image_pathsPtr - .asFunction(); + late final _spine_atlas_get_num_image_pathsPtr = _lookup>( + 'spine_atlas_get_num_image_paths', + ); + late final _spine_atlas_get_num_image_paths = _spine_atlas_get_num_image_pathsPtr + .asFunction(); - ffi.Pointer spine_atlas_get_image_path( - spine_atlas atlas, - int index, - ) { - return _spine_atlas_get_image_path( - atlas, - index, - ); + ffi.Pointer spine_atlas_get_image_path(spine_atlas atlas, int index) { + return _spine_atlas_get_image_path(atlas, index); } - late final _spine_atlas_get_image_pathPtr = _lookup< - ffi - .NativeFunction Function(spine_atlas, ffi.Int32)>>( - 'spine_atlas_get_image_path'); + late final _spine_atlas_get_image_pathPtr = + _lookup Function(spine_atlas, ffi.Int32)>>('spine_atlas_get_image_path'); late final _spine_atlas_get_image_path = _spine_atlas_get_image_pathPtr .asFunction Function(spine_atlas, int)>(); - ffi.Pointer spine_atlas_get_error( - spine_atlas atlas, - ) { - return _spine_atlas_get_error( - atlas, - ); + ffi.Pointer spine_atlas_get_error(spine_atlas atlas) { + return _spine_atlas_get_error(atlas); } - late final _spine_atlas_get_errorPtr = - _lookup Function(spine_atlas)>>( - 'spine_atlas_get_error'); - late final _spine_atlas_get_error = _spine_atlas_get_errorPtr - .asFunction Function(spine_atlas)>(); + late final _spine_atlas_get_errorPtr = _lookup Function(spine_atlas)>>( + 'spine_atlas_get_error', + ); + late final _spine_atlas_get_error = _spine_atlas_get_errorPtr.asFunction Function(spine_atlas)>(); - void spine_atlas_dispose( - spine_atlas atlas, - ) { - return _spine_atlas_dispose( - atlas, - ); + void spine_atlas_dispose(spine_atlas atlas) { + return _spine_atlas_dispose(atlas); } - late final _spine_atlas_disposePtr = - _lookup>( - 'spine_atlas_dispose'); - late final _spine_atlas_dispose = - _spine_atlas_disposePtr.asFunction(); + late final _spine_atlas_disposePtr = _lookup>( + 'spine_atlas_dispose', + ); + late final _spine_atlas_dispose = _spine_atlas_disposePtr.asFunction(); - spine_skeleton_data_result spine_skeleton_data_load_json( - spine_atlas atlas, - ffi.Pointer skeletonData, - ) { - return _spine_skeleton_data_load_json( - atlas, - skeletonData, - ); + spine_skeleton_data_result spine_skeleton_data_load_json(spine_atlas atlas, ffi.Pointer skeletonData) { + return _spine_skeleton_data_load_json(atlas, skeletonData); } - late final _spine_skeleton_data_load_jsonPtr = _lookup< - ffi.NativeFunction< - spine_skeleton_data_result Function(spine_atlas, - ffi.Pointer)>>('spine_skeleton_data_load_json'); - late final _spine_skeleton_data_load_json = - _spine_skeleton_data_load_jsonPtr.asFunction< - spine_skeleton_data_result Function( - spine_atlas, ffi.Pointer)>(); + late final _spine_skeleton_data_load_jsonPtr = + _lookup)>>( + 'spine_skeleton_data_load_json', + ); + late final _spine_skeleton_data_load_json = _spine_skeleton_data_load_jsonPtr + .asFunction)>(); spine_skeleton_data_result spine_skeleton_data_load_binary( spine_atlas atlas, ffi.Pointer skeletonData, int length, ) { - return _spine_skeleton_data_load_binary( - atlas, - skeletonData, - length, - ); + return _spine_skeleton_data_load_binary(atlas, skeletonData, length); } - late final _spine_skeleton_data_load_binaryPtr = _lookup< - ffi.NativeFunction< - spine_skeleton_data_result Function( - spine_atlas, - ffi.Pointer, - ffi.Int32)>>('spine_skeleton_data_load_binary'); - late final _spine_skeleton_data_load_binary = - _spine_skeleton_data_load_binaryPtr.asFunction< - spine_skeleton_data_result Function( - spine_atlas, ffi.Pointer, int)>(); + late final _spine_skeleton_data_load_binaryPtr = + _lookup, ffi.Int32)>>( + 'spine_skeleton_data_load_binary', + ); + late final _spine_skeleton_data_load_binary = _spine_skeleton_data_load_binaryPtr + .asFunction, int)>(); - ffi.Pointer spine_skeleton_data_result_get_error( - spine_skeleton_data_result result, - ) { - return _spine_skeleton_data_result_get_error( - result, - ); + ffi.Pointer spine_skeleton_data_result_get_error(spine_skeleton_data_result result) { + return _spine_skeleton_data_result_get_error(result); } - late final _spine_skeleton_data_result_get_errorPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(spine_skeleton_data_result)>>( - 'spine_skeleton_data_result_get_error'); - late final _spine_skeleton_data_result_get_error = - _spine_skeleton_data_result_get_errorPtr - .asFunction Function(spine_skeleton_data_result)>(); + late final _spine_skeleton_data_result_get_errorPtr = + _lookup Function(spine_skeleton_data_result)>>( + 'spine_skeleton_data_result_get_error', + ); + late final _spine_skeleton_data_result_get_error = _spine_skeleton_data_result_get_errorPtr + .asFunction Function(spine_skeleton_data_result)>(); - spine_skeleton_data spine_skeleton_data_result_get_data( - spine_skeleton_data_result result, - ) { - return _spine_skeleton_data_result_get_data( - result, - ); + spine_skeleton_data spine_skeleton_data_result_get_data(spine_skeleton_data_result result) { + return _spine_skeleton_data_result_get_data(result); } - late final _spine_skeleton_data_result_get_dataPtr = _lookup< - ffi.NativeFunction< - spine_skeleton_data Function(spine_skeleton_data_result)>>( - 'spine_skeleton_data_result_get_data'); - late final _spine_skeleton_data_result_get_data = - _spine_skeleton_data_result_get_dataPtr.asFunction< - spine_skeleton_data Function(spine_skeleton_data_result)>(); + late final _spine_skeleton_data_result_get_dataPtr = + _lookup>( + 'spine_skeleton_data_result_get_data', + ); + late final _spine_skeleton_data_result_get_data = _spine_skeleton_data_result_get_dataPtr + .asFunction(); - void spine_skeleton_data_result_dispose( - spine_skeleton_data_result result, - ) { - return _spine_skeleton_data_result_dispose( - result, - ); + void spine_skeleton_data_result_dispose(spine_skeleton_data_result result) { + return _spine_skeleton_data_result_dispose(result); } - late final _spine_skeleton_data_result_disposePtr = _lookup< - ffi.NativeFunction>( - 'spine_skeleton_data_result_dispose'); - late final _spine_skeleton_data_result_dispose = - _spine_skeleton_data_result_disposePtr - .asFunction(); + late final _spine_skeleton_data_result_disposePtr = + _lookup>('spine_skeleton_data_result_dispose'); + late final _spine_skeleton_data_result_dispose = _spine_skeleton_data_result_disposePtr + .asFunction(); - spine_bone_data spine_skeleton_data_find_bone( - spine_skeleton_data data, - ffi.Pointer name, - ) { - return _spine_skeleton_data_find_bone( - data, - name, - ); + spine_bone_data spine_skeleton_data_find_bone(spine_skeleton_data data, ffi.Pointer name) { + return _spine_skeleton_data_find_bone(data, name); } - late final _spine_skeleton_data_find_bonePtr = _lookup< - ffi.NativeFunction< - spine_bone_data Function(spine_skeleton_data, - ffi.Pointer)>>('spine_skeleton_data_find_bone'); - late final _spine_skeleton_data_find_bone = - _spine_skeleton_data_find_bonePtr.asFunction< - spine_bone_data Function(spine_skeleton_data, ffi.Pointer)>(); + late final _spine_skeleton_data_find_bonePtr = + _lookup)>>( + 'spine_skeleton_data_find_bone', + ); + late final _spine_skeleton_data_find_bone = _spine_skeleton_data_find_bonePtr + .asFunction)>(); - spine_slot_data spine_skeleton_data_find_slot( - spine_skeleton_data data, - ffi.Pointer name, - ) { - return _spine_skeleton_data_find_slot( - data, - name, - ); + spine_slot_data spine_skeleton_data_find_slot(spine_skeleton_data data, ffi.Pointer name) { + return _spine_skeleton_data_find_slot(data, name); } - late final _spine_skeleton_data_find_slotPtr = _lookup< - ffi.NativeFunction< - spine_slot_data Function(spine_skeleton_data, - ffi.Pointer)>>('spine_skeleton_data_find_slot'); - late final _spine_skeleton_data_find_slot = - _spine_skeleton_data_find_slotPtr.asFunction< - spine_slot_data Function(spine_skeleton_data, ffi.Pointer)>(); + late final _spine_skeleton_data_find_slotPtr = + _lookup)>>( + 'spine_skeleton_data_find_slot', + ); + late final _spine_skeleton_data_find_slot = _spine_skeleton_data_find_slotPtr + .asFunction)>(); - spine_skin spine_skeleton_data_find_skin( - spine_skeleton_data data, - ffi.Pointer name, - ) { - return _spine_skeleton_data_find_skin( - data, - name, - ); + spine_skin spine_skeleton_data_find_skin(spine_skeleton_data data, ffi.Pointer name) { + return _spine_skeleton_data_find_skin(data, name); } - late final _spine_skeleton_data_find_skinPtr = _lookup< - ffi.NativeFunction< - spine_skin Function(spine_skeleton_data, - ffi.Pointer)>>('spine_skeleton_data_find_skin'); - late final _spine_skeleton_data_find_skin = - _spine_skeleton_data_find_skinPtr.asFunction< - spine_skin Function(spine_skeleton_data, ffi.Pointer)>(); + late final _spine_skeleton_data_find_skinPtr = + _lookup)>>( + 'spine_skeleton_data_find_skin', + ); + late final _spine_skeleton_data_find_skin = _spine_skeleton_data_find_skinPtr + .asFunction)>(); - spine_event_data spine_skeleton_data_find_event( - spine_skeleton_data data, - ffi.Pointer name, - ) { - return _spine_skeleton_data_find_event( - data, - name, - ); + spine_event_data spine_skeleton_data_find_event(spine_skeleton_data data, ffi.Pointer name) { + return _spine_skeleton_data_find_event(data, name); } - late final _spine_skeleton_data_find_eventPtr = _lookup< - ffi.NativeFunction< - spine_event_data Function(spine_skeleton_data, - ffi.Pointer)>>('spine_skeleton_data_find_event'); - late final _spine_skeleton_data_find_event = - _spine_skeleton_data_find_eventPtr.asFunction< - spine_event_data Function(spine_skeleton_data, ffi.Pointer)>(); + late final _spine_skeleton_data_find_eventPtr = + _lookup)>>( + 'spine_skeleton_data_find_event', + ); + late final _spine_skeleton_data_find_event = _spine_skeleton_data_find_eventPtr + .asFunction)>(); - spine_animation spine_skeleton_data_find_animation( - spine_skeleton_data data, - ffi.Pointer name, - ) { - return _spine_skeleton_data_find_animation( - data, - name, - ); + spine_animation spine_skeleton_data_find_animation(spine_skeleton_data data, ffi.Pointer name) { + return _spine_skeleton_data_find_animation(data, name); } - late final _spine_skeleton_data_find_animationPtr = _lookup< - ffi.NativeFunction< - spine_animation Function(spine_skeleton_data, - ffi.Pointer)>>('spine_skeleton_data_find_animation'); - late final _spine_skeleton_data_find_animation = - _spine_skeleton_data_find_animationPtr.asFunction< - spine_animation Function(spine_skeleton_data, ffi.Pointer)>(); + late final _spine_skeleton_data_find_animationPtr = + _lookup)>>( + 'spine_skeleton_data_find_animation', + ); + late final _spine_skeleton_data_find_animation = _spine_skeleton_data_find_animationPtr + .asFunction)>(); - spine_ik_constraint_data spine_skeleton_data_find_ik_constraint( - spine_skeleton_data data, - ffi.Pointer name, - ) { - return _spine_skeleton_data_find_ik_constraint( - data, - name, - ); + spine_ik_constraint_data spine_skeleton_data_find_ik_constraint(spine_skeleton_data data, ffi.Pointer name) { + return _spine_skeleton_data_find_ik_constraint(data, name); } - late final _spine_skeleton_data_find_ik_constraintPtr = _lookup< - ffi.NativeFunction< - spine_ik_constraint_data Function(spine_skeleton_data, - ffi.Pointer)>>('spine_skeleton_data_find_ik_constraint'); - late final _spine_skeleton_data_find_ik_constraint = - _spine_skeleton_data_find_ik_constraintPtr.asFunction< - spine_ik_constraint_data Function( - spine_skeleton_data, ffi.Pointer)>(); + late final _spine_skeleton_data_find_ik_constraintPtr = + _lookup)>>( + 'spine_skeleton_data_find_ik_constraint', + ); + late final _spine_skeleton_data_find_ik_constraint = _spine_skeleton_data_find_ik_constraintPtr + .asFunction)>(); spine_transform_constraint_data spine_skeleton_data_find_transform_constraint( spine_skeleton_data data, ffi.Pointer name, ) { - return _spine_skeleton_data_find_transform_constraint( - data, - name, - ); + return _spine_skeleton_data_find_transform_constraint(data, name); } - late final _spine_skeleton_data_find_transform_constraintPtr = _lookup< - ffi.NativeFunction< - spine_transform_constraint_data Function( - spine_skeleton_data, ffi.Pointer)>>( - 'spine_skeleton_data_find_transform_constraint'); - late final _spine_skeleton_data_find_transform_constraint = - _spine_skeleton_data_find_transform_constraintPtr.asFunction< - spine_transform_constraint_data Function( - spine_skeleton_data, ffi.Pointer)>(); + late final _spine_skeleton_data_find_transform_constraintPtr = + _lookup)>>( + 'spine_skeleton_data_find_transform_constraint', + ); + late final _spine_skeleton_data_find_transform_constraint = _spine_skeleton_data_find_transform_constraintPtr + .asFunction)>(); spine_path_constraint_data spine_skeleton_data_find_path_constraint( spine_skeleton_data data, ffi.Pointer name, ) { - return _spine_skeleton_data_find_path_constraint( - data, - name, - ); + return _spine_skeleton_data_find_path_constraint(data, name); } - late final _spine_skeleton_data_find_path_constraintPtr = _lookup< - ffi.NativeFunction< - spine_path_constraint_data Function(spine_skeleton_data, - ffi.Pointer)>>('spine_skeleton_data_find_path_constraint'); - late final _spine_skeleton_data_find_path_constraint = - _spine_skeleton_data_find_path_constraintPtr.asFunction< - spine_path_constraint_data Function( - spine_skeleton_data, ffi.Pointer)>(); + late final _spine_skeleton_data_find_path_constraintPtr = + _lookup)>>( + 'spine_skeleton_data_find_path_constraint', + ); + late final _spine_skeleton_data_find_path_constraint = _spine_skeleton_data_find_path_constraintPtr + .asFunction)>(); spine_physics_constraint_data spine_skeleton_data_find_physics_constraint( spine_skeleton_data data, ffi.Pointer name, ) { - return _spine_skeleton_data_find_physics_constraint( - data, - name, - ); + return _spine_skeleton_data_find_physics_constraint(data, name); } - late final _spine_skeleton_data_find_physics_constraintPtr = _lookup< - ffi.NativeFunction< - spine_physics_constraint_data Function( - spine_skeleton_data, ffi.Pointer)>>( - 'spine_skeleton_data_find_physics_constraint'); - late final _spine_skeleton_data_find_physics_constraint = - _spine_skeleton_data_find_physics_constraintPtr.asFunction< - spine_physics_constraint_data Function( - spine_skeleton_data, ffi.Pointer)>(); + late final _spine_skeleton_data_find_physics_constraintPtr = + _lookup)>>( + 'spine_skeleton_data_find_physics_constraint', + ); + late final _spine_skeleton_data_find_physics_constraint = _spine_skeleton_data_find_physics_constraintPtr + .asFunction)>(); - ffi.Pointer spine_skeleton_data_get_name( - spine_skeleton_data data, - ) { - return _spine_skeleton_data_get_name( - data, - ); + ffi.Pointer spine_skeleton_data_get_name(spine_skeleton_data data) { + return _spine_skeleton_data_get_name(data); } - late final _spine_skeleton_data_get_namePtr = _lookup< - ffi.NativeFunction Function(spine_skeleton_data)>>( - 'spine_skeleton_data_get_name'); + late final _spine_skeleton_data_get_namePtr = + _lookup Function(spine_skeleton_data)>>('spine_skeleton_data_get_name'); late final _spine_skeleton_data_get_name = _spine_skeleton_data_get_namePtr .asFunction Function(spine_skeleton_data)>(); /// OMITTED setName() - int spine_skeleton_data_get_num_bones( - spine_skeleton_data data, - ) { - return _spine_skeleton_data_get_num_bones( - data, - ); + int spine_skeleton_data_get_num_bones(spine_skeleton_data data) { + return _spine_skeleton_data_get_num_bones(data); } late final _spine_skeleton_data_get_num_bonesPtr = - _lookup>( - 'spine_skeleton_data_get_num_bones'); - late final _spine_skeleton_data_get_num_bones = - _spine_skeleton_data_get_num_bonesPtr - .asFunction(); + _lookup>('spine_skeleton_data_get_num_bones'); + late final _spine_skeleton_data_get_num_bones = _spine_skeleton_data_get_num_bonesPtr + .asFunction(); - ffi.Pointer spine_skeleton_data_get_bones( - spine_skeleton_data data, - ) { - return _spine_skeleton_data_get_bones( - data, - ); + ffi.Pointer spine_skeleton_data_get_bones(spine_skeleton_data data) { + return _spine_skeleton_data_get_bones(data); } - late final _spine_skeleton_data_get_bonesPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_skeleton_data)>>('spine_skeleton_data_get_bones'); + late final _spine_skeleton_data_get_bonesPtr = + _lookup Function(spine_skeleton_data)>>( + 'spine_skeleton_data_get_bones', + ); late final _spine_skeleton_data_get_bones = _spine_skeleton_data_get_bonesPtr .asFunction Function(spine_skeleton_data)>(); - int spine_skeleton_data_get_num_slots( - spine_skeleton_data data, - ) { - return _spine_skeleton_data_get_num_slots( - data, - ); + int spine_skeleton_data_get_num_slots(spine_skeleton_data data) { + return _spine_skeleton_data_get_num_slots(data); } late final _spine_skeleton_data_get_num_slotsPtr = - _lookup>( - 'spine_skeleton_data_get_num_slots'); - late final _spine_skeleton_data_get_num_slots = - _spine_skeleton_data_get_num_slotsPtr - .asFunction(); + _lookup>('spine_skeleton_data_get_num_slots'); + late final _spine_skeleton_data_get_num_slots = _spine_skeleton_data_get_num_slotsPtr + .asFunction(); - ffi.Pointer spine_skeleton_data_get_slots( - spine_skeleton_data data, - ) { - return _spine_skeleton_data_get_slots( - data, - ); + ffi.Pointer spine_skeleton_data_get_slots(spine_skeleton_data data) { + return _spine_skeleton_data_get_slots(data); } - late final _spine_skeleton_data_get_slotsPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_skeleton_data)>>('spine_skeleton_data_get_slots'); + late final _spine_skeleton_data_get_slotsPtr = + _lookup Function(spine_skeleton_data)>>( + 'spine_skeleton_data_get_slots', + ); late final _spine_skeleton_data_get_slots = _spine_skeleton_data_get_slotsPtr .asFunction Function(spine_skeleton_data)>(); - int spine_skeleton_data_get_num_skins( - spine_skeleton_data data, - ) { - return _spine_skeleton_data_get_num_skins( - data, - ); + int spine_skeleton_data_get_num_skins(spine_skeleton_data data) { + return _spine_skeleton_data_get_num_skins(data); } late final _spine_skeleton_data_get_num_skinsPtr = - _lookup>( - 'spine_skeleton_data_get_num_skins'); - late final _spine_skeleton_data_get_num_skins = - _spine_skeleton_data_get_num_skinsPtr - .asFunction(); + _lookup>('spine_skeleton_data_get_num_skins'); + late final _spine_skeleton_data_get_num_skins = _spine_skeleton_data_get_num_skinsPtr + .asFunction(); - ffi.Pointer spine_skeleton_data_get_skins( - spine_skeleton_data data, - ) { - return _spine_skeleton_data_get_skins( - data, - ); + ffi.Pointer spine_skeleton_data_get_skins(spine_skeleton_data data) { + return _spine_skeleton_data_get_skins(data); } - late final _spine_skeleton_data_get_skinsPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_skeleton_data)>>('spine_skeleton_data_get_skins'); + late final _spine_skeleton_data_get_skinsPtr = + _lookup Function(spine_skeleton_data)>>( + 'spine_skeleton_data_get_skins', + ); late final _spine_skeleton_data_get_skins = _spine_skeleton_data_get_skinsPtr .asFunction Function(spine_skeleton_data)>(); - spine_skin spine_skeleton_data_get_default_skin( - spine_skeleton_data data, - ) { - return _spine_skeleton_data_get_default_skin( - data, - ); + spine_skin spine_skeleton_data_get_default_skin(spine_skeleton_data data) { + return _spine_skeleton_data_get_default_skin(data); } late final _spine_skeleton_data_get_default_skinPtr = - _lookup>( - 'spine_skeleton_data_get_default_skin'); - late final _spine_skeleton_data_get_default_skin = - _spine_skeleton_data_get_default_skinPtr - .asFunction(); + _lookup>('spine_skeleton_data_get_default_skin'); + late final _spine_skeleton_data_get_default_skin = _spine_skeleton_data_get_default_skinPtr + .asFunction(); - void spine_skeleton_data_set_default_skin( - spine_skeleton_data data, - spine_skin skin, - ) { - return _spine_skeleton_data_set_default_skin( - data, - skin, - ); + void spine_skeleton_data_set_default_skin(spine_skeleton_data data, spine_skin skin) { + return _spine_skeleton_data_set_default_skin(data, skin); } - late final _spine_skeleton_data_set_default_skinPtr = _lookup< - ffi - .NativeFunction>( - 'spine_skeleton_data_set_default_skin'); - late final _spine_skeleton_data_set_default_skin = - _spine_skeleton_data_set_default_skinPtr - .asFunction(); + late final _spine_skeleton_data_set_default_skinPtr = + _lookup>( + 'spine_skeleton_data_set_default_skin', + ); + late final _spine_skeleton_data_set_default_skin = _spine_skeleton_data_set_default_skinPtr + .asFunction(); - int spine_skeleton_data_get_num_events( - spine_skeleton_data data, - ) { - return _spine_skeleton_data_get_num_events( - data, - ); + int spine_skeleton_data_get_num_events(spine_skeleton_data data) { + return _spine_skeleton_data_get_num_events(data); } late final _spine_skeleton_data_get_num_eventsPtr = - _lookup>( - 'spine_skeleton_data_get_num_events'); - late final _spine_skeleton_data_get_num_events = - _spine_skeleton_data_get_num_eventsPtr - .asFunction(); + _lookup>('spine_skeleton_data_get_num_events'); + late final _spine_skeleton_data_get_num_events = _spine_skeleton_data_get_num_eventsPtr + .asFunction(); - ffi.Pointer spine_skeleton_data_get_events( - spine_skeleton_data data, - ) { - return _spine_skeleton_data_get_events( - data, - ); + ffi.Pointer spine_skeleton_data_get_events(spine_skeleton_data data) { + return _spine_skeleton_data_get_events(data); } - late final _spine_skeleton_data_get_eventsPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_skeleton_data)>>('spine_skeleton_data_get_events'); - late final _spine_skeleton_data_get_events = - _spine_skeleton_data_get_eventsPtr.asFunction< - ffi.Pointer Function(spine_skeleton_data)>(); + late final _spine_skeleton_data_get_eventsPtr = + _lookup Function(spine_skeleton_data)>>( + 'spine_skeleton_data_get_events', + ); + late final _spine_skeleton_data_get_events = _spine_skeleton_data_get_eventsPtr + .asFunction Function(spine_skeleton_data)>(); - int spine_skeleton_data_get_num_animations( - spine_skeleton_data data, - ) { - return _spine_skeleton_data_get_num_animations( - data, - ); + int spine_skeleton_data_get_num_animations(spine_skeleton_data data) { + return _spine_skeleton_data_get_num_animations(data); } late final _spine_skeleton_data_get_num_animationsPtr = - _lookup>( - 'spine_skeleton_data_get_num_animations'); - late final _spine_skeleton_data_get_num_animations = - _spine_skeleton_data_get_num_animationsPtr - .asFunction(); + _lookup>('spine_skeleton_data_get_num_animations'); + late final _spine_skeleton_data_get_num_animations = _spine_skeleton_data_get_num_animationsPtr + .asFunction(); - ffi.Pointer spine_skeleton_data_get_animations( - spine_skeleton_data data, - ) { - return _spine_skeleton_data_get_animations( - data, - ); + ffi.Pointer spine_skeleton_data_get_animations(spine_skeleton_data data) { + return _spine_skeleton_data_get_animations(data); } - late final _spine_skeleton_data_get_animationsPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_skeleton_data)>>('spine_skeleton_data_get_animations'); - late final _spine_skeleton_data_get_animations = - _spine_skeleton_data_get_animationsPtr.asFunction< - ffi.Pointer Function(spine_skeleton_data)>(); + late final _spine_skeleton_data_get_animationsPtr = + _lookup Function(spine_skeleton_data)>>( + 'spine_skeleton_data_get_animations', + ); + late final _spine_skeleton_data_get_animations = _spine_skeleton_data_get_animationsPtr + .asFunction Function(spine_skeleton_data)>(); - int spine_skeleton_data_get_num_ik_constraints( - spine_skeleton_data data, - ) { - return _spine_skeleton_data_get_num_ik_constraints( - data, - ); + int spine_skeleton_data_get_num_ik_constraints(spine_skeleton_data data) { + return _spine_skeleton_data_get_num_ik_constraints(data); } late final _spine_skeleton_data_get_num_ik_constraintsPtr = _lookup>( - 'spine_skeleton_data_get_num_ik_constraints'); - late final _spine_skeleton_data_get_num_ik_constraints = - _spine_skeleton_data_get_num_ik_constraintsPtr - .asFunction(); + 'spine_skeleton_data_get_num_ik_constraints', + ); + late final _spine_skeleton_data_get_num_ik_constraints = _spine_skeleton_data_get_num_ik_constraintsPtr + .asFunction(); - ffi.Pointer spine_skeleton_data_get_ik_constraints( - spine_skeleton_data data, - ) { - return _spine_skeleton_data_get_ik_constraints( - data, - ); + ffi.Pointer spine_skeleton_data_get_ik_constraints(spine_skeleton_data data) { + return _spine_skeleton_data_get_ik_constraints(data); } - late final _spine_skeleton_data_get_ik_constraintsPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_skeleton_data)>>('spine_skeleton_data_get_ik_constraints'); - late final _spine_skeleton_data_get_ik_constraints = - _spine_skeleton_data_get_ik_constraintsPtr.asFunction< - ffi.Pointer Function( - spine_skeleton_data)>(); + late final _spine_skeleton_data_get_ik_constraintsPtr = + _lookup Function(spine_skeleton_data)>>( + 'spine_skeleton_data_get_ik_constraints', + ); + late final _spine_skeleton_data_get_ik_constraints = _spine_skeleton_data_get_ik_constraintsPtr + .asFunction Function(spine_skeleton_data)>(); - int spine_skeleton_data_get_num_transform_constraints( - spine_skeleton_data data, - ) { - return _spine_skeleton_data_get_num_transform_constraints( - data, - ); + int spine_skeleton_data_get_num_transform_constraints(spine_skeleton_data data) { + return _spine_skeleton_data_get_num_transform_constraints(data); } late final _spine_skeleton_data_get_num_transform_constraintsPtr = _lookup>( - 'spine_skeleton_data_get_num_transform_constraints'); - late final _spine_skeleton_data_get_num_transform_constraints = - _spine_skeleton_data_get_num_transform_constraintsPtr - .asFunction(); + 'spine_skeleton_data_get_num_transform_constraints', + ); + late final _spine_skeleton_data_get_num_transform_constraints = _spine_skeleton_data_get_num_transform_constraintsPtr + .asFunction(); - ffi.Pointer - spine_skeleton_data_get_transform_constraints( - spine_skeleton_data data, - ) { - return _spine_skeleton_data_get_transform_constraints( - data, - ); + ffi.Pointer spine_skeleton_data_get_transform_constraints(spine_skeleton_data data) { + return _spine_skeleton_data_get_transform_constraints(data); } - late final _spine_skeleton_data_get_transform_constraintsPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_skeleton_data)>>( - 'spine_skeleton_data_get_transform_constraints'); - late final _spine_skeleton_data_get_transform_constraints = - _spine_skeleton_data_get_transform_constraintsPtr.asFunction< - ffi.Pointer Function( - spine_skeleton_data)>(); + late final _spine_skeleton_data_get_transform_constraintsPtr = + _lookup Function(spine_skeleton_data)>>( + 'spine_skeleton_data_get_transform_constraints', + ); + late final _spine_skeleton_data_get_transform_constraints = _spine_skeleton_data_get_transform_constraintsPtr + .asFunction Function(spine_skeleton_data)>(); - int spine_skeleton_data_get_num_path_constraints( - spine_skeleton_data data, - ) { - return _spine_skeleton_data_get_num_path_constraints( - data, - ); + int spine_skeleton_data_get_num_path_constraints(spine_skeleton_data data) { + return _spine_skeleton_data_get_num_path_constraints(data); } late final _spine_skeleton_data_get_num_path_constraintsPtr = _lookup>( - 'spine_skeleton_data_get_num_path_constraints'); - late final _spine_skeleton_data_get_num_path_constraints = - _spine_skeleton_data_get_num_path_constraintsPtr - .asFunction(); + 'spine_skeleton_data_get_num_path_constraints', + ); + late final _spine_skeleton_data_get_num_path_constraints = _spine_skeleton_data_get_num_path_constraintsPtr + .asFunction(); - ffi.Pointer - spine_skeleton_data_get_path_constraints( - spine_skeleton_data data, - ) { - return _spine_skeleton_data_get_path_constraints( - data, - ); + ffi.Pointer spine_skeleton_data_get_path_constraints(spine_skeleton_data data) { + return _spine_skeleton_data_get_path_constraints(data); } - late final _spine_skeleton_data_get_path_constraintsPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_skeleton_data)>>( - 'spine_skeleton_data_get_path_constraints'); - late final _spine_skeleton_data_get_path_constraints = - _spine_skeleton_data_get_path_constraintsPtr.asFunction< - ffi.Pointer Function( - spine_skeleton_data)>(); + late final _spine_skeleton_data_get_path_constraintsPtr = + _lookup Function(spine_skeleton_data)>>( + 'spine_skeleton_data_get_path_constraints', + ); + late final _spine_skeleton_data_get_path_constraints = _spine_skeleton_data_get_path_constraintsPtr + .asFunction Function(spine_skeleton_data)>(); - int spine_skeleton_data_get_num_physics_constraints( - spine_skeleton_data data, - ) { - return _spine_skeleton_data_get_num_physics_constraints( - data, - ); + int spine_skeleton_data_get_num_physics_constraints(spine_skeleton_data data) { + return _spine_skeleton_data_get_num_physics_constraints(data); } late final _spine_skeleton_data_get_num_physics_constraintsPtr = _lookup>( - 'spine_skeleton_data_get_num_physics_constraints'); - late final _spine_skeleton_data_get_num_physics_constraints = - _spine_skeleton_data_get_num_physics_constraintsPtr - .asFunction(); + 'spine_skeleton_data_get_num_physics_constraints', + ); + late final _spine_skeleton_data_get_num_physics_constraints = _spine_skeleton_data_get_num_physics_constraintsPtr + .asFunction(); - ffi.Pointer - spine_skeleton_data_get_physics_constraints( - spine_skeleton_data data, - ) { - return _spine_skeleton_data_get_physics_constraints( - data, - ); + ffi.Pointer spine_skeleton_data_get_physics_constraints(spine_skeleton_data data) { + return _spine_skeleton_data_get_physics_constraints(data); } - late final _spine_skeleton_data_get_physics_constraintsPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_skeleton_data)>>( - 'spine_skeleton_data_get_physics_constraints'); - late final _spine_skeleton_data_get_physics_constraints = - _spine_skeleton_data_get_physics_constraintsPtr.asFunction< - ffi.Pointer Function( - spine_skeleton_data)>(); + late final _spine_skeleton_data_get_physics_constraintsPtr = + _lookup Function(spine_skeleton_data)>>( + 'spine_skeleton_data_get_physics_constraints', + ); + late final _spine_skeleton_data_get_physics_constraints = _spine_skeleton_data_get_physics_constraintsPtr + .asFunction Function(spine_skeleton_data)>(); - double spine_skeleton_data_get_x( - spine_skeleton_data data, - ) { - return _spine_skeleton_data_get_x( - data, - ); + double spine_skeleton_data_get_x(spine_skeleton_data data) { + return _spine_skeleton_data_get_x(data); } - late final _spine_skeleton_data_get_xPtr = - _lookup>( - 'spine_skeleton_data_get_x'); + late final _spine_skeleton_data_get_xPtr = _lookup>( + 'spine_skeleton_data_get_x', + ); late final _spine_skeleton_data_get_x = _spine_skeleton_data_get_xPtr .asFunction(); - void spine_skeleton_data_set_x( - spine_skeleton_data data, - double x, - ) { - return _spine_skeleton_data_set_x( - data, - x, - ); + void spine_skeleton_data_set_x(spine_skeleton_data data, double x) { + return _spine_skeleton_data_set_x(data, x); } - late final _spine_skeleton_data_set_xPtr = _lookup< - ffi - .NativeFunction>( - 'spine_skeleton_data_set_x'); + late final _spine_skeleton_data_set_xPtr = + _lookup>('spine_skeleton_data_set_x'); late final _spine_skeleton_data_set_x = _spine_skeleton_data_set_xPtr .asFunction(); - double spine_skeleton_data_get_y( - spine_skeleton_data data, - ) { - return _spine_skeleton_data_get_y( - data, - ); + double spine_skeleton_data_get_y(spine_skeleton_data data) { + return _spine_skeleton_data_get_y(data); } - late final _spine_skeleton_data_get_yPtr = - _lookup>( - 'spine_skeleton_data_get_y'); + late final _spine_skeleton_data_get_yPtr = _lookup>( + 'spine_skeleton_data_get_y', + ); late final _spine_skeleton_data_get_y = _spine_skeleton_data_get_yPtr .asFunction(); - void spine_skeleton_data_set_y( - spine_skeleton_data data, - double y, - ) { - return _spine_skeleton_data_set_y( - data, - y, - ); + void spine_skeleton_data_set_y(spine_skeleton_data data, double y) { + return _spine_skeleton_data_set_y(data, y); } - late final _spine_skeleton_data_set_yPtr = _lookup< - ffi - .NativeFunction>( - 'spine_skeleton_data_set_y'); + late final _spine_skeleton_data_set_yPtr = + _lookup>('spine_skeleton_data_set_y'); late final _spine_skeleton_data_set_y = _spine_skeleton_data_set_yPtr .asFunction(); - double spine_skeleton_data_get_width( - spine_skeleton_data data, - ) { - return _spine_skeleton_data_get_width( - data, - ); + double spine_skeleton_data_get_width(spine_skeleton_data data) { + return _spine_skeleton_data_get_width(data); } - late final _spine_skeleton_data_get_widthPtr = - _lookup>( - 'spine_skeleton_data_get_width'); + late final _spine_skeleton_data_get_widthPtr = _lookup>( + 'spine_skeleton_data_get_width', + ); late final _spine_skeleton_data_get_width = _spine_skeleton_data_get_widthPtr .asFunction(); - void spine_skeleton_data_set_width( - spine_skeleton_data data, - double width, - ) { - return _spine_skeleton_data_set_width( - data, - width, - ); + void spine_skeleton_data_set_width(spine_skeleton_data data, double width) { + return _spine_skeleton_data_set_width(data, width); } - late final _spine_skeleton_data_set_widthPtr = _lookup< - ffi - .NativeFunction>( - 'spine_skeleton_data_set_width'); + late final _spine_skeleton_data_set_widthPtr = + _lookup>('spine_skeleton_data_set_width'); late final _spine_skeleton_data_set_width = _spine_skeleton_data_set_widthPtr .asFunction(); - double spine_skeleton_data_get_height( - spine_skeleton_data data, - ) { - return _spine_skeleton_data_get_height( - data, - ); + double spine_skeleton_data_get_height(spine_skeleton_data data) { + return _spine_skeleton_data_get_height(data); } - late final _spine_skeleton_data_get_heightPtr = - _lookup>( - 'spine_skeleton_data_get_height'); - late final _spine_skeleton_data_get_height = - _spine_skeleton_data_get_heightPtr - .asFunction(); + late final _spine_skeleton_data_get_heightPtr = _lookup>( + 'spine_skeleton_data_get_height', + ); + late final _spine_skeleton_data_get_height = _spine_skeleton_data_get_heightPtr + .asFunction(); - void spine_skeleton_data_set_height( - spine_skeleton_data data, - double height, - ) { - return _spine_skeleton_data_set_height( - data, - height, - ); + void spine_skeleton_data_set_height(spine_skeleton_data data, double height) { + return _spine_skeleton_data_set_height(data, height); } - late final _spine_skeleton_data_set_heightPtr = _lookup< - ffi - .NativeFunction>( - 'spine_skeleton_data_set_height'); - late final _spine_skeleton_data_set_height = - _spine_skeleton_data_set_heightPtr - .asFunction(); + late final _spine_skeleton_data_set_heightPtr = + _lookup>('spine_skeleton_data_set_height'); + late final _spine_skeleton_data_set_height = _spine_skeleton_data_set_heightPtr + .asFunction(); - ffi.Pointer spine_skeleton_data_get_version( - spine_skeleton_data data, - ) { - return _spine_skeleton_data_get_version( - data, - ); + ffi.Pointer spine_skeleton_data_get_version(spine_skeleton_data data) { + return _spine_skeleton_data_get_version(data); } - late final _spine_skeleton_data_get_versionPtr = _lookup< - ffi.NativeFunction Function(spine_skeleton_data)>>( - 'spine_skeleton_data_get_version'); - late final _spine_skeleton_data_get_version = - _spine_skeleton_data_get_versionPtr - .asFunction Function(spine_skeleton_data)>(); + late final _spine_skeleton_data_get_versionPtr = + _lookup Function(spine_skeleton_data)>>('spine_skeleton_data_get_version'); + late final _spine_skeleton_data_get_version = _spine_skeleton_data_get_versionPtr + .asFunction Function(spine_skeleton_data)>(); /// OMITTED setVersion() - ffi.Pointer spine_skeleton_data_get_hash( - spine_skeleton_data data, - ) { - return _spine_skeleton_data_get_hash( - data, - ); + ffi.Pointer spine_skeleton_data_get_hash(spine_skeleton_data data) { + return _spine_skeleton_data_get_hash(data); } - late final _spine_skeleton_data_get_hashPtr = _lookup< - ffi.NativeFunction Function(spine_skeleton_data)>>( - 'spine_skeleton_data_get_hash'); + late final _spine_skeleton_data_get_hashPtr = + _lookup Function(spine_skeleton_data)>>('spine_skeleton_data_get_hash'); late final _spine_skeleton_data_get_hash = _spine_skeleton_data_get_hashPtr .asFunction Function(spine_skeleton_data)>(); /// OMITTED setHash() - ffi.Pointer spine_skeleton_data_get_images_path( - spine_skeleton_data data, - ) { - return _spine_skeleton_data_get_images_path( - data, - ); + ffi.Pointer spine_skeleton_data_get_images_path(spine_skeleton_data data) { + return _spine_skeleton_data_get_images_path(data); } - late final _spine_skeleton_data_get_images_pathPtr = _lookup< - ffi.NativeFunction Function(spine_skeleton_data)>>( - 'spine_skeleton_data_get_images_path'); - late final _spine_skeleton_data_get_images_path = - _spine_skeleton_data_get_images_pathPtr - .asFunction Function(spine_skeleton_data)>(); + late final _spine_skeleton_data_get_images_pathPtr = + _lookup Function(spine_skeleton_data)>>( + 'spine_skeleton_data_get_images_path', + ); + late final _spine_skeleton_data_get_images_path = _spine_skeleton_data_get_images_pathPtr + .asFunction Function(spine_skeleton_data)>(); /// OMITTED setImagesPath() - ffi.Pointer spine_skeleton_data_get_audio_path( - spine_skeleton_data data, - ) { - return _spine_skeleton_data_get_audio_path( - data, - ); + ffi.Pointer spine_skeleton_data_get_audio_path(spine_skeleton_data data) { + return _spine_skeleton_data_get_audio_path(data); } - late final _spine_skeleton_data_get_audio_pathPtr = _lookup< - ffi.NativeFunction Function(spine_skeleton_data)>>( - 'spine_skeleton_data_get_audio_path'); - late final _spine_skeleton_data_get_audio_path = - _spine_skeleton_data_get_audio_pathPtr - .asFunction Function(spine_skeleton_data)>(); + late final _spine_skeleton_data_get_audio_pathPtr = + _lookup Function(spine_skeleton_data)>>( + 'spine_skeleton_data_get_audio_path', + ); + late final _spine_skeleton_data_get_audio_path = _spine_skeleton_data_get_audio_pathPtr + .asFunction Function(spine_skeleton_data)>(); /// OMITTED setAudioPath() - double spine_skeleton_data_get_fps( - spine_skeleton_data data, - ) { - return _spine_skeleton_data_get_fps( - data, - ); + double spine_skeleton_data_get_fps(spine_skeleton_data data) { + return _spine_skeleton_data_get_fps(data); } - late final _spine_skeleton_data_get_fpsPtr = - _lookup>( - 'spine_skeleton_data_get_fps'); + late final _spine_skeleton_data_get_fpsPtr = _lookup>( + 'spine_skeleton_data_get_fps', + ); late final _spine_skeleton_data_get_fps = _spine_skeleton_data_get_fpsPtr .asFunction(); /// OMITTED setFps() - double spine_skeleton_data_get_reference_scale( - spine_skeleton_data data, - ) { - return _spine_skeleton_data_get_reference_scale( - data, - ); + double spine_skeleton_data_get_reference_scale(spine_skeleton_data data) { + return _spine_skeleton_data_get_reference_scale(data); } late final _spine_skeleton_data_get_reference_scalePtr = - _lookup>( - 'spine_skeleton_data_get_reference_scale'); - late final _spine_skeleton_data_get_reference_scale = - _spine_skeleton_data_get_reference_scalePtr - .asFunction(); + _lookup>('spine_skeleton_data_get_reference_scale'); + late final _spine_skeleton_data_get_reference_scale = _spine_skeleton_data_get_reference_scalePtr + .asFunction(); - void spine_skeleton_data_dispose( - spine_skeleton_data data, - ) { - return _spine_skeleton_data_dispose( - data, - ); + void spine_skeleton_data_dispose(spine_skeleton_data data) { + return _spine_skeleton_data_dispose(data); } - late final _spine_skeleton_data_disposePtr = - _lookup>( - 'spine_skeleton_data_dispose'); + late final _spine_skeleton_data_disposePtr = _lookup>( + 'spine_skeleton_data_dispose', + ); late final _spine_skeleton_data_dispose = _spine_skeleton_data_disposePtr .asFunction(); - spine_skeleton_drawable spine_skeleton_drawable_create( - spine_skeleton_data skeletonData, - ) { - return _spine_skeleton_drawable_create( - skeletonData, - ); + spine_skeleton_drawable spine_skeleton_drawable_create(spine_skeleton_data skeletonData) { + return _spine_skeleton_drawable_create(skeletonData); } - late final _spine_skeleton_drawable_createPtr = _lookup< - ffi.NativeFunction< - spine_skeleton_drawable Function( - spine_skeleton_data)>>('spine_skeleton_drawable_create'); - late final _spine_skeleton_drawable_create = - _spine_skeleton_drawable_createPtr - .asFunction(); + late final _spine_skeleton_drawable_createPtr = + _lookup>( + 'spine_skeleton_drawable_create', + ); + late final _spine_skeleton_drawable_create = _spine_skeleton_drawable_createPtr + .asFunction(); - spine_render_command spine_skeleton_drawable_render( - spine_skeleton_drawable drawable, - ) { - return _spine_skeleton_drawable_render( - drawable, - ); + spine_render_command spine_skeleton_drawable_render(spine_skeleton_drawable drawable) { + return _spine_skeleton_drawable_render(drawable); } - late final _spine_skeleton_drawable_renderPtr = _lookup< - ffi.NativeFunction< - spine_render_command Function( - spine_skeleton_drawable)>>('spine_skeleton_drawable_render'); - late final _spine_skeleton_drawable_render = - _spine_skeleton_drawable_renderPtr - .asFunction(); + late final _spine_skeleton_drawable_renderPtr = + _lookup>( + 'spine_skeleton_drawable_render', + ); + late final _spine_skeleton_drawable_render = _spine_skeleton_drawable_renderPtr + .asFunction(); - void spine_skeleton_drawable_dispose( - spine_skeleton_drawable drawable, - ) { - return _spine_skeleton_drawable_dispose( - drawable, - ); + void spine_skeleton_drawable_dispose(spine_skeleton_drawable drawable) { + return _spine_skeleton_drawable_dispose(drawable); } late final _spine_skeleton_drawable_disposePtr = - _lookup>( - 'spine_skeleton_drawable_dispose'); - late final _spine_skeleton_drawable_dispose = - _spine_skeleton_drawable_disposePtr - .asFunction(); + _lookup>('spine_skeleton_drawable_dispose'); + late final _spine_skeleton_drawable_dispose = _spine_skeleton_drawable_disposePtr + .asFunction(); - spine_skeleton spine_skeleton_drawable_get_skeleton( - spine_skeleton_drawable drawable, - ) { - return _spine_skeleton_drawable_get_skeleton( - drawable, - ); + spine_skeleton spine_skeleton_drawable_get_skeleton(spine_skeleton_drawable drawable) { + return _spine_skeleton_drawable_get_skeleton(drawable); } - late final _spine_skeleton_drawable_get_skeletonPtr = _lookup< - ffi.NativeFunction>( - 'spine_skeleton_drawable_get_skeleton'); - late final _spine_skeleton_drawable_get_skeleton = - _spine_skeleton_drawable_get_skeletonPtr - .asFunction(); + late final _spine_skeleton_drawable_get_skeletonPtr = + _lookup>( + 'spine_skeleton_drawable_get_skeleton', + ); + late final _spine_skeleton_drawable_get_skeleton = _spine_skeleton_drawable_get_skeletonPtr + .asFunction(); - spine_animation_state spine_skeleton_drawable_get_animation_state( - spine_skeleton_drawable drawable, - ) { - return _spine_skeleton_drawable_get_animation_state( - drawable, - ); + spine_animation_state spine_skeleton_drawable_get_animation_state(spine_skeleton_drawable drawable) { + return _spine_skeleton_drawable_get_animation_state(drawable); } - late final _spine_skeleton_drawable_get_animation_statePtr = _lookup< - ffi.NativeFunction< - spine_animation_state Function(spine_skeleton_drawable)>>( - 'spine_skeleton_drawable_get_animation_state'); - late final _spine_skeleton_drawable_get_animation_state = - _spine_skeleton_drawable_get_animation_statePtr.asFunction< - spine_animation_state Function(spine_skeleton_drawable)>(); + late final _spine_skeleton_drawable_get_animation_statePtr = + _lookup>( + 'spine_skeleton_drawable_get_animation_state', + ); + late final _spine_skeleton_drawable_get_animation_state = _spine_skeleton_drawable_get_animation_statePtr + .asFunction(); - spine_animation_state_data spine_skeleton_drawable_get_animation_state_data( - spine_skeleton_drawable drawable, - ) { - return _spine_skeleton_drawable_get_animation_state_data( - drawable, - ); + spine_animation_state_data spine_skeleton_drawable_get_animation_state_data(spine_skeleton_drawable drawable) { + return _spine_skeleton_drawable_get_animation_state_data(drawable); } - late final _spine_skeleton_drawable_get_animation_state_dataPtr = _lookup< - ffi.NativeFunction< - spine_animation_state_data Function(spine_skeleton_drawable)>>( - 'spine_skeleton_drawable_get_animation_state_data'); - late final _spine_skeleton_drawable_get_animation_state_data = - _spine_skeleton_drawable_get_animation_state_dataPtr.asFunction< - spine_animation_state_data Function(spine_skeleton_drawable)>(); + late final _spine_skeleton_drawable_get_animation_state_dataPtr = + _lookup>( + 'spine_skeleton_drawable_get_animation_state_data', + ); + late final _spine_skeleton_drawable_get_animation_state_data = _spine_skeleton_drawable_get_animation_state_dataPtr + .asFunction(); - spine_animation_state_events - spine_skeleton_drawable_get_animation_state_events( - spine_skeleton_drawable drawable, - ) { - return _spine_skeleton_drawable_get_animation_state_events( - drawable, - ); + spine_animation_state_events spine_skeleton_drawable_get_animation_state_events(spine_skeleton_drawable drawable) { + return _spine_skeleton_drawable_get_animation_state_events(drawable); } - late final _spine_skeleton_drawable_get_animation_state_eventsPtr = _lookup< - ffi.NativeFunction< - spine_animation_state_events Function(spine_skeleton_drawable)>>( - 'spine_skeleton_drawable_get_animation_state_events'); + late final _spine_skeleton_drawable_get_animation_state_eventsPtr = + _lookup>( + 'spine_skeleton_drawable_get_animation_state_events', + ); late final _spine_skeleton_drawable_get_animation_state_events = - _spine_skeleton_drawable_get_animation_state_eventsPtr.asFunction< - spine_animation_state_events Function(spine_skeleton_drawable)>(); + _spine_skeleton_drawable_get_animation_state_eventsPtr + .asFunction(); - ffi.Pointer spine_render_command_get_positions( - spine_render_command command, - ) { - return _spine_render_command_get_positions( - command, - ); + ffi.Pointer spine_render_command_get_positions(spine_render_command command) { + return _spine_render_command_get_positions(command); } - late final _spine_render_command_get_positionsPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_render_command)>>('spine_render_command_get_positions'); - late final _spine_render_command_get_positions = - _spine_render_command_get_positionsPtr - .asFunction Function(spine_render_command)>(); + late final _spine_render_command_get_positionsPtr = + _lookup Function(spine_render_command)>>( + 'spine_render_command_get_positions', + ); + late final _spine_render_command_get_positions = _spine_render_command_get_positionsPtr + .asFunction Function(spine_render_command)>(); - ffi.Pointer spine_render_command_get_uvs( - spine_render_command command, - ) { - return _spine_render_command_get_uvs( - command, - ); + ffi.Pointer spine_render_command_get_uvs(spine_render_command command) { + return _spine_render_command_get_uvs(command); } - late final _spine_render_command_get_uvsPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_render_command)>>('spine_render_command_get_uvs'); + late final _spine_render_command_get_uvsPtr = + _lookup Function(spine_render_command)>>( + 'spine_render_command_get_uvs', + ); late final _spine_render_command_get_uvs = _spine_render_command_get_uvsPtr .asFunction Function(spine_render_command)>(); - ffi.Pointer spine_render_command_get_colors( - spine_render_command command, - ) { - return _spine_render_command_get_colors( - command, - ); + ffi.Pointer spine_render_command_get_colors(spine_render_command command) { + return _spine_render_command_get_colors(command); } - late final _spine_render_command_get_colorsPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_render_command)>>('spine_render_command_get_colors'); - late final _spine_render_command_get_colors = - _spine_render_command_get_colorsPtr - .asFunction Function(spine_render_command)>(); + late final _spine_render_command_get_colorsPtr = + _lookup Function(spine_render_command)>>( + 'spine_render_command_get_colors', + ); + late final _spine_render_command_get_colors = _spine_render_command_get_colorsPtr + .asFunction Function(spine_render_command)>(); - int spine_render_command_get_num_vertices( - spine_render_command command, - ) { - return _spine_render_command_get_num_vertices( - command, - ); + int spine_render_command_get_num_vertices(spine_render_command command) { + return _spine_render_command_get_num_vertices(command); } late final _spine_render_command_get_num_verticesPtr = - _lookup>( - 'spine_render_command_get_num_vertices'); - late final _spine_render_command_get_num_vertices = - _spine_render_command_get_num_verticesPtr - .asFunction(); + _lookup>('spine_render_command_get_num_vertices'); + late final _spine_render_command_get_num_vertices = _spine_render_command_get_num_verticesPtr + .asFunction(); - ffi.Pointer spine_render_command_get_indices( - spine_render_command command, - ) { - return _spine_render_command_get_indices( - command, - ); + ffi.Pointer spine_render_command_get_indices(spine_render_command command) { + return _spine_render_command_get_indices(command); } - late final _spine_render_command_get_indicesPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_render_command)>>('spine_render_command_get_indices'); - late final _spine_render_command_get_indices = - _spine_render_command_get_indicesPtr - .asFunction Function(spine_render_command)>(); + late final _spine_render_command_get_indicesPtr = + _lookup Function(spine_render_command)>>( + 'spine_render_command_get_indices', + ); + late final _spine_render_command_get_indices = _spine_render_command_get_indicesPtr + .asFunction Function(spine_render_command)>(); - int spine_render_command_get_num_indices( - spine_render_command command, - ) { - return _spine_render_command_get_num_indices( - command, - ); + int spine_render_command_get_num_indices(spine_render_command command) { + return _spine_render_command_get_num_indices(command); } late final _spine_render_command_get_num_indicesPtr = - _lookup>( - 'spine_render_command_get_num_indices'); - late final _spine_render_command_get_num_indices = - _spine_render_command_get_num_indicesPtr - .asFunction(); + _lookup>('spine_render_command_get_num_indices'); + late final _spine_render_command_get_num_indices = _spine_render_command_get_num_indicesPtr + .asFunction(); - int spine_render_command_get_atlas_page( - spine_render_command command, - ) { - return _spine_render_command_get_atlas_page( - command, - ); + int spine_render_command_get_atlas_page(spine_render_command command) { + return _spine_render_command_get_atlas_page(command); } late final _spine_render_command_get_atlas_pagePtr = - _lookup>( - 'spine_render_command_get_atlas_page'); - late final _spine_render_command_get_atlas_page = - _spine_render_command_get_atlas_pagePtr - .asFunction(); + _lookup>('spine_render_command_get_atlas_page'); + late final _spine_render_command_get_atlas_page = _spine_render_command_get_atlas_pagePtr + .asFunction(); - int spine_render_command_get_blend_mode( - spine_render_command command, - ) { - return _spine_render_command_get_blend_mode( - command, - ); + int spine_render_command_get_blend_mode(spine_render_command command) { + return _spine_render_command_get_blend_mode(command); } late final _spine_render_command_get_blend_modePtr = - _lookup>( - 'spine_render_command_get_blend_mode'); - late final _spine_render_command_get_blend_mode = - _spine_render_command_get_blend_modePtr - .asFunction(); + _lookup>('spine_render_command_get_blend_mode'); + late final _spine_render_command_get_blend_mode = _spine_render_command_get_blend_modePtr + .asFunction(); - spine_render_command spine_render_command_get_next( - spine_render_command command, - ) { - return _spine_render_command_get_next( - command, - ); + spine_render_command spine_render_command_get_next(spine_render_command command) { + return _spine_render_command_get_next(command); } - late final _spine_render_command_get_nextPtr = _lookup< - ffi - .NativeFunction>( - 'spine_render_command_get_next'); + late final _spine_render_command_get_nextPtr = + _lookup>('spine_render_command_get_next'); late final _spine_render_command_get_next = _spine_render_command_get_nextPtr .asFunction(); - ffi.Pointer spine_animation_get_name( - spine_animation animation, - ) { - return _spine_animation_get_name( - animation, - ); + ffi.Pointer spine_animation_get_name(spine_animation animation) { + return _spine_animation_get_name(animation); } - late final _spine_animation_get_namePtr = - _lookup Function(spine_animation)>>( - 'spine_animation_get_name'); + late final _spine_animation_get_namePtr = _lookup Function(spine_animation)>>( + 'spine_animation_get_name', + ); late final _spine_animation_get_name = _spine_animation_get_namePtr .asFunction Function(spine_animation)>(); /// OMITTED getTimelines() /// OMITTED hasTimeline() - double spine_animation_get_duration( - spine_animation animation, - ) { - return _spine_animation_get_duration( - animation, - ); + double spine_animation_get_duration(spine_animation animation) { + return _spine_animation_get_duration(animation); } - late final _spine_animation_get_durationPtr = - _lookup>( - 'spine_animation_get_duration'); + late final _spine_animation_get_durationPtr = _lookup>( + 'spine_animation_get_duration', + ); late final _spine_animation_get_duration = _spine_animation_get_durationPtr .asFunction(); /// OMITTED setDuration() - spine_skeleton_data spine_animation_state_data_get_skeleton_data( - spine_animation_state_data stateData, - ) { - return _spine_animation_state_data_get_skeleton_data( - stateData, - ); + spine_skeleton_data spine_animation_state_data_get_skeleton_data(spine_animation_state_data stateData) { + return _spine_animation_state_data_get_skeleton_data(stateData); } - late final _spine_animation_state_data_get_skeleton_dataPtr = _lookup< - ffi.NativeFunction< - spine_skeleton_data Function(spine_animation_state_data)>>( - 'spine_animation_state_data_get_skeleton_data'); - late final _spine_animation_state_data_get_skeleton_data = - _spine_animation_state_data_get_skeleton_dataPtr.asFunction< - spine_skeleton_data Function(spine_animation_state_data)>(); + late final _spine_animation_state_data_get_skeleton_dataPtr = + _lookup>( + 'spine_animation_state_data_get_skeleton_data', + ); + late final _spine_animation_state_data_get_skeleton_data = _spine_animation_state_data_get_skeleton_dataPtr + .asFunction(); - double spine_animation_state_data_get_default_mix( - spine_animation_state_data stateData, - ) { - return _spine_animation_state_data_get_default_mix( - stateData, - ); + double spine_animation_state_data_get_default_mix(spine_animation_state_data stateData) { + return _spine_animation_state_data_get_default_mix(stateData); } - late final _spine_animation_state_data_get_default_mixPtr = _lookup< - ffi.NativeFunction>( - 'spine_animation_state_data_get_default_mix'); - late final _spine_animation_state_data_get_default_mix = - _spine_animation_state_data_get_default_mixPtr - .asFunction(); + late final _spine_animation_state_data_get_default_mixPtr = + _lookup>( + 'spine_animation_state_data_get_default_mix', + ); + late final _spine_animation_state_data_get_default_mix = _spine_animation_state_data_get_default_mixPtr + .asFunction(); - void spine_animation_state_data_set_default_mix( - spine_animation_state_data stateData, - double defaultMix, - ) { - return _spine_animation_state_data_set_default_mix( - stateData, - defaultMix, - ); + void spine_animation_state_data_set_default_mix(spine_animation_state_data stateData, double defaultMix) { + return _spine_animation_state_data_set_default_mix(stateData, defaultMix); } - late final _spine_animation_state_data_set_default_mixPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_animation_state_data, - ffi.Float)>>('spine_animation_state_data_set_default_mix'); - late final _spine_animation_state_data_set_default_mix = - _spine_animation_state_data_set_default_mixPtr - .asFunction(); + late final _spine_animation_state_data_set_default_mixPtr = + _lookup>( + 'spine_animation_state_data_set_default_mix', + ); + late final _spine_animation_state_data_set_default_mix = _spine_animation_state_data_set_default_mixPtr + .asFunction(); void spine_animation_state_data_set_mix( spine_animation_state_data stateData, @@ -1441,46 +941,30 @@ class SpineFlutterBindings { spine_animation to, double duration, ) { - return _spine_animation_state_data_set_mix( - stateData, - from, - to, - duration, - ); + return _spine_animation_state_data_set_mix(stateData, from, to, duration); } - late final _spine_animation_state_data_set_mixPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function( - spine_animation_state_data, - spine_animation, - spine_animation, - ffi.Float)>>('spine_animation_state_data_set_mix'); - late final _spine_animation_state_data_set_mix = - _spine_animation_state_data_set_mixPtr.asFunction< - void Function(spine_animation_state_data, spine_animation, - spine_animation, double)>(); + late final _spine_animation_state_data_set_mixPtr = + _lookup< + ffi.NativeFunction + >('spine_animation_state_data_set_mix'); + late final _spine_animation_state_data_set_mix = _spine_animation_state_data_set_mixPtr + .asFunction(); double spine_animation_state_data_get_mix( spine_animation_state_data stateData, spine_animation from, spine_animation to, ) { - return _spine_animation_state_data_get_mix( - stateData, - from, - to, - ); + return _spine_animation_state_data_get_mix(stateData, from, to); } - late final _spine_animation_state_data_get_mixPtr = _lookup< - ffi.NativeFunction< - ffi.Float Function(spine_animation_state_data, spine_animation, - spine_animation)>>('spine_animation_state_data_get_mix'); - late final _spine_animation_state_data_get_mix = - _spine_animation_state_data_get_mixPtr.asFunction< - double Function( - spine_animation_state_data, spine_animation, spine_animation)>(); + late final _spine_animation_state_data_get_mixPtr = + _lookup>( + 'spine_animation_state_data_get_mix', + ); + late final _spine_animation_state_data_get_mix = _spine_animation_state_data_get_mixPtr + .asFunction(); void spine_animation_state_data_set_mix_by_name( spine_animation_state_data stateData, @@ -1488,144 +972,90 @@ class SpineFlutterBindings { ffi.Pointer toName, double duration, ) { - return _spine_animation_state_data_set_mix_by_name( - stateData, - fromName, - toName, - duration, - ); + return _spine_animation_state_data_set_mix_by_name(stateData, fromName, toName, duration); } - late final _spine_animation_state_data_set_mix_by_namePtr = _lookup< - ffi.NativeFunction< - ffi.Void Function( - spine_animation_state_data, - ffi.Pointer, - ffi.Pointer, - ffi.Float)>>('spine_animation_state_data_set_mix_by_name'); - late final _spine_animation_state_data_set_mix_by_name = - _spine_animation_state_data_set_mix_by_namePtr.asFunction< - void Function(spine_animation_state_data, ffi.Pointer, - ffi.Pointer, double)>(); + late final _spine_animation_state_data_set_mix_by_namePtr = + _lookup< + ffi.NativeFunction< + ffi.Void Function(spine_animation_state_data, ffi.Pointer, ffi.Pointer, ffi.Float) + > + >('spine_animation_state_data_set_mix_by_name'); + late final _spine_animation_state_data_set_mix_by_name = _spine_animation_state_data_set_mix_by_namePtr + .asFunction, ffi.Pointer, double)>(); double spine_animation_state_data_get_mix_by_name( spine_animation_state_data stateData, ffi.Pointer fromName, ffi.Pointer toName, ) { - return _spine_animation_state_data_get_mix_by_name( - stateData, - fromName, - toName, - ); + return _spine_animation_state_data_get_mix_by_name(stateData, fromName, toName); } - late final _spine_animation_state_data_get_mix_by_namePtr = _lookup< - ffi.NativeFunction< - ffi.Float Function(spine_animation_state_data, ffi.Pointer, - ffi.Pointer)>>( - 'spine_animation_state_data_get_mix_by_name'); - late final _spine_animation_state_data_get_mix_by_name = - _spine_animation_state_data_get_mix_by_namePtr.asFunction< - double Function(spine_animation_state_data, ffi.Pointer, - ffi.Pointer)>(); + late final _spine_animation_state_data_get_mix_by_namePtr = + _lookup, ffi.Pointer)>>( + 'spine_animation_state_data_get_mix_by_name', + ); + late final _spine_animation_state_data_get_mix_by_name = _spine_animation_state_data_get_mix_by_namePtr + .asFunction, ffi.Pointer)>(); - void spine_animation_state_data_clear( - spine_animation_state_data stateData, - ) { - return _spine_animation_state_data_clear( - stateData, - ); + void spine_animation_state_data_clear(spine_animation_state_data stateData) { + return _spine_animation_state_data_clear(stateData); } - late final _spine_animation_state_data_clearPtr = _lookup< - ffi.NativeFunction>( - 'spine_animation_state_data_clear'); - late final _spine_animation_state_data_clear = - _spine_animation_state_data_clearPtr - .asFunction(); + late final _spine_animation_state_data_clearPtr = + _lookup>('spine_animation_state_data_clear'); + late final _spine_animation_state_data_clear = _spine_animation_state_data_clearPtr + .asFunction(); - void spine_animation_state_update( - spine_animation_state state, - double delta, - ) { - return _spine_animation_state_update( - state, - delta, - ); + void spine_animation_state_update(spine_animation_state state, double delta) { + return _spine_animation_state_update(state, delta); } - late final _spine_animation_state_updatePtr = _lookup< - ffi - .NativeFunction>( - 'spine_animation_state_update'); + late final _spine_animation_state_updatePtr = + _lookup>('spine_animation_state_update'); late final _spine_animation_state_update = _spine_animation_state_updatePtr .asFunction(); - void spine_animation_state_apply( - spine_animation_state state, - spine_skeleton skeleton, - ) { - return _spine_animation_state_apply( - state, - skeleton, - ); + void spine_animation_state_apply(spine_animation_state state, spine_skeleton skeleton) { + return _spine_animation_state_apply(state, skeleton); } - late final _spine_animation_state_applyPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_animation_state, - spine_skeleton)>>('spine_animation_state_apply'); + late final _spine_animation_state_applyPtr = + _lookup>( + 'spine_animation_state_apply', + ); late final _spine_animation_state_apply = _spine_animation_state_applyPtr .asFunction(); - void spine_animation_state_clear_tracks( - spine_animation_state state, - ) { - return _spine_animation_state_clear_tracks( - state, - ); + void spine_animation_state_clear_tracks(spine_animation_state state) { + return _spine_animation_state_clear_tracks(state); } late final _spine_animation_state_clear_tracksPtr = - _lookup>( - 'spine_animation_state_clear_tracks'); - late final _spine_animation_state_clear_tracks = - _spine_animation_state_clear_tracksPtr - .asFunction(); + _lookup>('spine_animation_state_clear_tracks'); + late final _spine_animation_state_clear_tracks = _spine_animation_state_clear_tracksPtr + .asFunction(); - void spine_animation_state_clear_track( - spine_animation_state state, - int trackIndex, - ) { - return _spine_animation_state_clear_track( - state, - trackIndex, - ); + void spine_animation_state_clear_track(spine_animation_state state, int trackIndex) { + return _spine_animation_state_clear_track(state, trackIndex); } - late final _spine_animation_state_clear_trackPtr = _lookup< - ffi - .NativeFunction>( - 'spine_animation_state_clear_track'); - late final _spine_animation_state_clear_track = - _spine_animation_state_clear_trackPtr - .asFunction(); + late final _spine_animation_state_clear_trackPtr = + _lookup>( + 'spine_animation_state_clear_track', + ); + late final _spine_animation_state_clear_track = _spine_animation_state_clear_trackPtr + .asFunction(); - int spine_animation_state_get_num_tracks( - spine_animation_state state, - ) { - return _spine_animation_state_get_num_tracks( - state, - ); + int spine_animation_state_get_num_tracks(spine_animation_state state) { + return _spine_animation_state_get_num_tracks(state); } late final _spine_animation_state_get_num_tracksPtr = - _lookup>( - 'spine_animation_state_get_num_tracks'); - late final _spine_animation_state_get_num_tracks = - _spine_animation_state_get_num_tracksPtr - .asFunction(); + _lookup>('spine_animation_state_get_num_tracks'); + late final _spine_animation_state_get_num_tracks = _spine_animation_state_get_num_tracksPtr + .asFunction(); spine_track_entry spine_animation_state_set_animation_by_name( spine_animation_state state, @@ -1633,25 +1063,15 @@ class SpineFlutterBindings { ffi.Pointer animationName, int loop, ) { - return _spine_animation_state_set_animation_by_name( - state, - trackIndex, - animationName, - loop, - ); + return _spine_animation_state_set_animation_by_name(state, trackIndex, animationName, loop); } - late final _spine_animation_state_set_animation_by_namePtr = _lookup< - ffi.NativeFunction< - spine_track_entry Function( - spine_animation_state, - ffi.Int32, - ffi.Pointer, - spine_bool)>>('spine_animation_state_set_animation_by_name'); - late final _spine_animation_state_set_animation_by_name = - _spine_animation_state_set_animation_by_namePtr.asFunction< - spine_track_entry Function( - spine_animation_state, int, ffi.Pointer, int)>(); + late final _spine_animation_state_set_animation_by_namePtr = + _lookup< + ffi.NativeFunction, spine_bool)> + >('spine_animation_state_set_animation_by_name'); + late final _spine_animation_state_set_animation_by_name = _spine_animation_state_set_animation_by_namePtr + .asFunction, int)>(); spine_track_entry spine_animation_state_set_animation( spine_animation_state state, @@ -1659,25 +1079,15 @@ class SpineFlutterBindings { spine_animation animation, int loop, ) { - return _spine_animation_state_set_animation( - state, - trackIndex, - animation, - loop, - ); + return _spine_animation_state_set_animation(state, trackIndex, animation, loop); } - late final _spine_animation_state_set_animationPtr = _lookup< - ffi.NativeFunction< - spine_track_entry Function( - spine_animation_state, - ffi.Int32, - spine_animation, - spine_bool)>>('spine_animation_state_set_animation'); - late final _spine_animation_state_set_animation = - _spine_animation_state_set_animationPtr.asFunction< - spine_track_entry Function( - spine_animation_state, int, spine_animation, int)>(); + late final _spine_animation_state_set_animationPtr = + _lookup< + ffi.NativeFunction + >('spine_animation_state_set_animation'); + late final _spine_animation_state_set_animation = _spine_animation_state_set_animationPtr + .asFunction(); spine_track_entry spine_animation_state_add_animation_by_name( spine_animation_state state, @@ -1686,27 +1096,17 @@ class SpineFlutterBindings { int loop, double delay, ) { - return _spine_animation_state_add_animation_by_name( - state, - trackIndex, - animationName, - loop, - delay, - ); + return _spine_animation_state_add_animation_by_name(state, trackIndex, animationName, loop, delay); } - late final _spine_animation_state_add_animation_by_namePtr = _lookup< - ffi.NativeFunction< - spine_track_entry Function( - spine_animation_state, - ffi.Int32, - ffi.Pointer, - spine_bool, - ffi.Float)>>('spine_animation_state_add_animation_by_name'); - late final _spine_animation_state_add_animation_by_name = - _spine_animation_state_add_animation_by_namePtr.asFunction< - spine_track_entry Function( - spine_animation_state, int, ffi.Pointer, int, double)>(); + late final _spine_animation_state_add_animation_by_namePtr = + _lookup< + ffi.NativeFunction< + spine_track_entry Function(spine_animation_state, ffi.Int32, ffi.Pointer, spine_bool, ffi.Float) + > + >('spine_animation_state_add_animation_by_name'); + late final _spine_animation_state_add_animation_by_name = _spine_animation_state_add_animation_by_namePtr + .asFunction, int, double)>(); spine_track_entry spine_animation_state_add_animation( spine_animation_state state, @@ -1715,47 +1115,32 @@ class SpineFlutterBindings { int loop, double delay, ) { - return _spine_animation_state_add_animation( - state, - trackIndex, - animation, - loop, - delay, - ); + return _spine_animation_state_add_animation(state, trackIndex, animation, loop, delay); } - late final _spine_animation_state_add_animationPtr = _lookup< - ffi.NativeFunction< - spine_track_entry Function( - spine_animation_state, - ffi.Int32, - spine_animation, - spine_bool, - ffi.Float)>>('spine_animation_state_add_animation'); - late final _spine_animation_state_add_animation = - _spine_animation_state_add_animationPtr.asFunction< - spine_track_entry Function( - spine_animation_state, int, spine_animation, int, double)>(); + late final _spine_animation_state_add_animationPtr = + _lookup< + ffi.NativeFunction< + spine_track_entry Function(spine_animation_state, ffi.Int32, spine_animation, spine_bool, ffi.Float) + > + >('spine_animation_state_add_animation'); + late final _spine_animation_state_add_animation = _spine_animation_state_add_animationPtr + .asFunction(); spine_track_entry spine_animation_state_set_empty_animation( spine_animation_state state, int trackIndex, double mixDuration, ) { - return _spine_animation_state_set_empty_animation( - state, - trackIndex, - mixDuration, - ); + return _spine_animation_state_set_empty_animation(state, trackIndex, mixDuration); } - late final _spine_animation_state_set_empty_animationPtr = _lookup< - ffi.NativeFunction< - spine_track_entry Function(spine_animation_state, ffi.Int32, - ffi.Float)>>('spine_animation_state_set_empty_animation'); - late final _spine_animation_state_set_empty_animation = - _spine_animation_state_set_empty_animationPtr.asFunction< - spine_track_entry Function(spine_animation_state, int, double)>(); + late final _spine_animation_state_set_empty_animationPtr = + _lookup>( + 'spine_animation_state_set_empty_animation', + ); + late final _spine_animation_state_set_empty_animation = _spine_animation_state_set_empty_animationPtr + .asFunction(); spine_track_entry spine_animation_state_add_empty_animation( spine_animation_state state, @@ -1763,110 +1148,68 @@ class SpineFlutterBindings { double mixDuration, double delay, ) { - return _spine_animation_state_add_empty_animation( - state, - trackIndex, - mixDuration, - delay, - ); + return _spine_animation_state_add_empty_animation(state, trackIndex, mixDuration, delay); } - late final _spine_animation_state_add_empty_animationPtr = _lookup< - ffi.NativeFunction< - spine_track_entry Function( - spine_animation_state, - ffi.Int32, - ffi.Float, - ffi.Float)>>('spine_animation_state_add_empty_animation'); - late final _spine_animation_state_add_empty_animation = - _spine_animation_state_add_empty_animationPtr.asFunction< - spine_track_entry Function( - spine_animation_state, int, double, double)>(); + late final _spine_animation_state_add_empty_animationPtr = + _lookup>( + 'spine_animation_state_add_empty_animation', + ); + late final _spine_animation_state_add_empty_animation = _spine_animation_state_add_empty_animationPtr + .asFunction(); - void spine_animation_state_set_empty_animations( - spine_animation_state state, - double mixDuration, - ) { - return _spine_animation_state_set_empty_animations( - state, - mixDuration, - ); + void spine_animation_state_set_empty_animations(spine_animation_state state, double mixDuration) { + return _spine_animation_state_set_empty_animations(state, mixDuration); } - late final _spine_animation_state_set_empty_animationsPtr = _lookup< - ffi - .NativeFunction>( - 'spine_animation_state_set_empty_animations'); - late final _spine_animation_state_set_empty_animations = - _spine_animation_state_set_empty_animationsPtr - .asFunction(); + late final _spine_animation_state_set_empty_animationsPtr = + _lookup>( + 'spine_animation_state_set_empty_animations', + ); + late final _spine_animation_state_set_empty_animations = _spine_animation_state_set_empty_animationsPtr + .asFunction(); - spine_track_entry spine_animation_state_get_current( - spine_animation_state state, - int trackIndex, - ) { - return _spine_animation_state_get_current( - state, - trackIndex, - ); + spine_track_entry spine_animation_state_get_current(spine_animation_state state, int trackIndex) { + return _spine_animation_state_get_current(state, trackIndex); } - late final _spine_animation_state_get_currentPtr = _lookup< - ffi.NativeFunction< - spine_track_entry Function(spine_animation_state, - ffi.Int32)>>('spine_animation_state_get_current'); - late final _spine_animation_state_get_current = - _spine_animation_state_get_currentPtr - .asFunction(); + late final _spine_animation_state_get_currentPtr = + _lookup>( + 'spine_animation_state_get_current', + ); + late final _spine_animation_state_get_current = _spine_animation_state_get_currentPtr + .asFunction(); - spine_animation_state_data spine_animation_state_get_data( - spine_animation_state state, - ) { - return _spine_animation_state_get_data( - state, - ); + spine_animation_state_data spine_animation_state_get_data(spine_animation_state state) { + return _spine_animation_state_get_data(state); } - late final _spine_animation_state_get_dataPtr = _lookup< - ffi.NativeFunction< - spine_animation_state_data Function( - spine_animation_state)>>('spine_animation_state_get_data'); - late final _spine_animation_state_get_data = - _spine_animation_state_get_dataPtr.asFunction< - spine_animation_state_data Function(spine_animation_state)>(); + late final _spine_animation_state_get_dataPtr = + _lookup>( + 'spine_animation_state_get_data', + ); + late final _spine_animation_state_get_data = _spine_animation_state_get_dataPtr + .asFunction(); - double spine_animation_state_get_time_scale( - spine_animation_state state, - ) { - return _spine_animation_state_get_time_scale( - state, - ); + double spine_animation_state_get_time_scale(spine_animation_state state) { + return _spine_animation_state_get_time_scale(state); } late final _spine_animation_state_get_time_scalePtr = - _lookup>( - 'spine_animation_state_get_time_scale'); - late final _spine_animation_state_get_time_scale = - _spine_animation_state_get_time_scalePtr - .asFunction(); + _lookup>('spine_animation_state_get_time_scale'); + late final _spine_animation_state_get_time_scale = _spine_animation_state_get_time_scalePtr + .asFunction(); - void spine_animation_state_set_time_scale( - spine_animation_state state, - double timeScale, - ) { - return _spine_animation_state_set_time_scale( - state, - timeScale, - ); + void spine_animation_state_set_time_scale(spine_animation_state state, double timeScale) { + return _spine_animation_state_set_time_scale(state, timeScale); } - late final _spine_animation_state_set_time_scalePtr = _lookup< - ffi - .NativeFunction>( - 'spine_animation_state_set_time_scale'); - late final _spine_animation_state_set_time_scale = - _spine_animation_state_set_time_scalePtr - .asFunction(); + late final _spine_animation_state_set_time_scalePtr = + _lookup>( + 'spine_animation_state_set_time_scale', + ); + late final _spine_animation_state_set_time_scale = _spine_animation_state_set_time_scalePtr + .asFunction(); /// OMITTED setListener() /// OMITTED setListener() @@ -1874,1049 +1217,658 @@ class SpineFlutterBindings { /// OMITTED enableQueue() /// OMITTED setManualTrackEntryDisposal() /// OMITTED getManualTrackEntryDisposal() - void spine_animation_state_dispose_track_entry( - spine_animation_state state, - spine_track_entry entry, - ) { - return _spine_animation_state_dispose_track_entry( - state, - entry, - ); + void spine_animation_state_dispose_track_entry(spine_animation_state state, spine_track_entry entry) { + return _spine_animation_state_dispose_track_entry(state, entry); } - late final _spine_animation_state_dispose_track_entryPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_animation_state, - spine_track_entry)>>('spine_animation_state_dispose_track_entry'); - late final _spine_animation_state_dispose_track_entry = - _spine_animation_state_dispose_track_entryPtr.asFunction< - void Function(spine_animation_state, spine_track_entry)>(); + late final _spine_animation_state_dispose_track_entryPtr = + _lookup>( + 'spine_animation_state_dispose_track_entry', + ); + late final _spine_animation_state_dispose_track_entry = _spine_animation_state_dispose_track_entryPtr + .asFunction(); - int spine_animation_state_events_get_num_events( - spine_animation_state_events events, - ) { - return _spine_animation_state_events_get_num_events( - events, - ); + int spine_animation_state_events_get_num_events(spine_animation_state_events events) { + return _spine_animation_state_events_get_num_events(events); } - late final _spine_animation_state_events_get_num_eventsPtr = _lookup< - ffi.NativeFunction>( - 'spine_animation_state_events_get_num_events'); - late final _spine_animation_state_events_get_num_events = - _spine_animation_state_events_get_num_eventsPtr - .asFunction(); + late final _spine_animation_state_events_get_num_eventsPtr = + _lookup>( + 'spine_animation_state_events_get_num_events', + ); + late final _spine_animation_state_events_get_num_events = _spine_animation_state_events_get_num_eventsPtr + .asFunction(); - int spine_animation_state_events_get_event_type( - spine_animation_state_events events, - int index, - ) { - return _spine_animation_state_events_get_event_type( - events, - index, - ); + int spine_animation_state_events_get_event_type(spine_animation_state_events events, int index) { + return _spine_animation_state_events_get_event_type(events, index); } - late final _spine_animation_state_events_get_event_typePtr = _lookup< - ffi.NativeFunction< - ffi.Int32 Function(spine_animation_state_events, - ffi.Int32)>>('spine_animation_state_events_get_event_type'); - late final _spine_animation_state_events_get_event_type = - _spine_animation_state_events_get_event_typePtr - .asFunction(); + late final _spine_animation_state_events_get_event_typePtr = + _lookup>( + 'spine_animation_state_events_get_event_type', + ); + late final _spine_animation_state_events_get_event_type = _spine_animation_state_events_get_event_typePtr + .asFunction(); - spine_track_entry spine_animation_state_events_get_track_entry( - spine_animation_state_events events, - int index, - ) { - return _spine_animation_state_events_get_track_entry( - events, - index, - ); + spine_track_entry spine_animation_state_events_get_track_entry(spine_animation_state_events events, int index) { + return _spine_animation_state_events_get_track_entry(events, index); } - late final _spine_animation_state_events_get_track_entryPtr = _lookup< - ffi.NativeFunction< - spine_track_entry Function(spine_animation_state_events, - ffi.Int32)>>('spine_animation_state_events_get_track_entry'); - late final _spine_animation_state_events_get_track_entry = - _spine_animation_state_events_get_track_entryPtr.asFunction< - spine_track_entry Function(spine_animation_state_events, int)>(); + late final _spine_animation_state_events_get_track_entryPtr = + _lookup>( + 'spine_animation_state_events_get_track_entry', + ); + late final _spine_animation_state_events_get_track_entry = _spine_animation_state_events_get_track_entryPtr + .asFunction(); - spine_event spine_animation_state_events_get_event( - spine_animation_state_events events, - int index, - ) { - return _spine_animation_state_events_get_event( - events, - index, - ); + spine_event spine_animation_state_events_get_event(spine_animation_state_events events, int index) { + return _spine_animation_state_events_get_event(events, index); } - late final _spine_animation_state_events_get_eventPtr = _lookup< - ffi.NativeFunction< - spine_event Function(spine_animation_state_events, - ffi.Int32)>>('spine_animation_state_events_get_event'); - late final _spine_animation_state_events_get_event = - _spine_animation_state_events_get_eventPtr.asFunction< - spine_event Function(spine_animation_state_events, int)>(); + late final _spine_animation_state_events_get_eventPtr = + _lookup>( + 'spine_animation_state_events_get_event', + ); + late final _spine_animation_state_events_get_event = _spine_animation_state_events_get_eventPtr + .asFunction(); - void spine_animation_state_events_reset( - spine_animation_state_events events, - ) { - return _spine_animation_state_events_reset( - events, - ); + void spine_animation_state_events_reset(spine_animation_state_events events) { + return _spine_animation_state_events_reset(events); } - late final _spine_animation_state_events_resetPtr = _lookup< - ffi.NativeFunction>( - 'spine_animation_state_events_reset'); - late final _spine_animation_state_events_reset = - _spine_animation_state_events_resetPtr - .asFunction(); + late final _spine_animation_state_events_resetPtr = + _lookup>( + 'spine_animation_state_events_reset', + ); + late final _spine_animation_state_events_reset = _spine_animation_state_events_resetPtr + .asFunction(); - int spine_track_entry_get_track_index( - spine_track_entry entry, - ) { - return _spine_track_entry_get_track_index( - entry, - ); + int spine_track_entry_get_track_index(spine_track_entry entry) { + return _spine_track_entry_get_track_index(entry); } - late final _spine_track_entry_get_track_indexPtr = - _lookup>( - 'spine_track_entry_get_track_index'); - late final _spine_track_entry_get_track_index = - _spine_track_entry_get_track_indexPtr - .asFunction(); + late final _spine_track_entry_get_track_indexPtr = _lookup>( + 'spine_track_entry_get_track_index', + ); + late final _spine_track_entry_get_track_index = _spine_track_entry_get_track_indexPtr + .asFunction(); - spine_animation spine_track_entry_get_animation( - spine_track_entry entry, - ) { - return _spine_track_entry_get_animation( - entry, - ); + spine_animation spine_track_entry_get_animation(spine_track_entry entry) { + return _spine_track_entry_get_animation(entry); } late final _spine_track_entry_get_animationPtr = - _lookup>( - 'spine_track_entry_get_animation'); - late final _spine_track_entry_get_animation = - _spine_track_entry_get_animationPtr - .asFunction(); + _lookup>('spine_track_entry_get_animation'); + late final _spine_track_entry_get_animation = _spine_track_entry_get_animationPtr + .asFunction(); - spine_track_entry spine_track_entry_get_previous( - spine_track_entry entry, - ) { - return _spine_track_entry_get_previous( - entry, - ); + spine_track_entry spine_track_entry_get_previous(spine_track_entry entry) { + return _spine_track_entry_get_previous(entry); } - late final _spine_track_entry_get_previousPtr = _lookup< - ffi.NativeFunction>( - 'spine_track_entry_get_previous'); - late final _spine_track_entry_get_previous = - _spine_track_entry_get_previousPtr - .asFunction(); + late final _spine_track_entry_get_previousPtr = + _lookup>('spine_track_entry_get_previous'); + late final _spine_track_entry_get_previous = _spine_track_entry_get_previousPtr + .asFunction(); - int spine_track_entry_get_loop( - spine_track_entry entry, - ) { - return _spine_track_entry_get_loop( - entry, - ); + int spine_track_entry_get_loop(spine_track_entry entry) { + return _spine_track_entry_get_loop(entry); } - late final _spine_track_entry_get_loopPtr = - _lookup>( - 'spine_track_entry_get_loop'); - late final _spine_track_entry_get_loop = _spine_track_entry_get_loopPtr - .asFunction(); + late final _spine_track_entry_get_loopPtr = _lookup>( + 'spine_track_entry_get_loop', + ); + late final _spine_track_entry_get_loop = _spine_track_entry_get_loopPtr.asFunction(); - void spine_track_entry_set_loop( - spine_track_entry entry, - int loop, - ) { - return _spine_track_entry_set_loop( - entry, - loop, - ); + void spine_track_entry_set_loop(spine_track_entry entry, int loop) { + return _spine_track_entry_set_loop(entry, loop); } - late final _spine_track_entry_set_loopPtr = _lookup< - ffi.NativeFunction>( - 'spine_track_entry_set_loop'); + late final _spine_track_entry_set_loopPtr = + _lookup>('spine_track_entry_set_loop'); late final _spine_track_entry_set_loop = _spine_track_entry_set_loopPtr .asFunction(); - int spine_track_entry_get_hold_previous( - spine_track_entry entry, - ) { - return _spine_track_entry_get_hold_previous( - entry, - ); + int spine_track_entry_get_hold_previous(spine_track_entry entry) { + return _spine_track_entry_get_hold_previous(entry); } late final _spine_track_entry_get_hold_previousPtr = - _lookup>( - 'spine_track_entry_get_hold_previous'); - late final _spine_track_entry_get_hold_previous = - _spine_track_entry_get_hold_previousPtr - .asFunction(); + _lookup>('spine_track_entry_get_hold_previous'); + late final _spine_track_entry_get_hold_previous = _spine_track_entry_get_hold_previousPtr + .asFunction(); - void spine_track_entry_set_hold_previous( - spine_track_entry entry, - int holdPrevious, - ) { - return _spine_track_entry_set_hold_previous( - entry, - holdPrevious, - ); + void spine_track_entry_set_hold_previous(spine_track_entry entry, int holdPrevious) { + return _spine_track_entry_set_hold_previous(entry, holdPrevious); } - late final _spine_track_entry_set_hold_previousPtr = _lookup< - ffi.NativeFunction>( - 'spine_track_entry_set_hold_previous'); - late final _spine_track_entry_set_hold_previous = - _spine_track_entry_set_hold_previousPtr - .asFunction(); + late final _spine_track_entry_set_hold_previousPtr = + _lookup>( + 'spine_track_entry_set_hold_previous', + ); + late final _spine_track_entry_set_hold_previous = _spine_track_entry_set_hold_previousPtr + .asFunction(); - int spine_track_entry_get_reverse( - spine_track_entry entry, - ) { - return _spine_track_entry_get_reverse( - entry, - ); + int spine_track_entry_get_reverse(spine_track_entry entry) { + return _spine_track_entry_get_reverse(entry); } - late final _spine_track_entry_get_reversePtr = - _lookup>( - 'spine_track_entry_get_reverse'); + late final _spine_track_entry_get_reversePtr = _lookup>( + 'spine_track_entry_get_reverse', + ); late final _spine_track_entry_get_reverse = _spine_track_entry_get_reversePtr .asFunction(); - void spine_track_entry_set_reverse( - spine_track_entry entry, - int reverse, - ) { - return _spine_track_entry_set_reverse( - entry, - reverse, - ); + void spine_track_entry_set_reverse(spine_track_entry entry, int reverse) { + return _spine_track_entry_set_reverse(entry, reverse); } - late final _spine_track_entry_set_reversePtr = _lookup< - ffi.NativeFunction>( - 'spine_track_entry_set_reverse'); + late final _spine_track_entry_set_reversePtr = + _lookup>('spine_track_entry_set_reverse'); late final _spine_track_entry_set_reverse = _spine_track_entry_set_reversePtr .asFunction(); - int spine_track_entry_get_shortest_rotation( - spine_track_entry entry, - ) { - return _spine_track_entry_get_shortest_rotation( - entry, - ); + int spine_track_entry_get_shortest_rotation(spine_track_entry entry) { + return _spine_track_entry_get_shortest_rotation(entry); } late final _spine_track_entry_get_shortest_rotationPtr = - _lookup>( - 'spine_track_entry_get_shortest_rotation'); - late final _spine_track_entry_get_shortest_rotation = - _spine_track_entry_get_shortest_rotationPtr - .asFunction(); + _lookup>('spine_track_entry_get_shortest_rotation'); + late final _spine_track_entry_get_shortest_rotation = _spine_track_entry_get_shortest_rotationPtr + .asFunction(); - void spine_track_entry_set_shortest_rotation( - spine_track_entry entry, - int shortestRotation, - ) { - return _spine_track_entry_set_shortest_rotation( - entry, - shortestRotation, - ); + void spine_track_entry_set_shortest_rotation(spine_track_entry entry, int shortestRotation) { + return _spine_track_entry_set_shortest_rotation(entry, shortestRotation); } - late final _spine_track_entry_set_shortest_rotationPtr = _lookup< - ffi.NativeFunction>( - 'spine_track_entry_set_shortest_rotation'); - late final _spine_track_entry_set_shortest_rotation = - _spine_track_entry_set_shortest_rotationPtr - .asFunction(); + late final _spine_track_entry_set_shortest_rotationPtr = + _lookup>( + 'spine_track_entry_set_shortest_rotation', + ); + late final _spine_track_entry_set_shortest_rotation = _spine_track_entry_set_shortest_rotationPtr + .asFunction(); - double spine_track_entry_get_delay( - spine_track_entry entry, - ) { - return _spine_track_entry_get_delay( - entry, - ); + double spine_track_entry_get_delay(spine_track_entry entry) { + return _spine_track_entry_get_delay(entry); } - late final _spine_track_entry_get_delayPtr = - _lookup>( - 'spine_track_entry_get_delay'); + late final _spine_track_entry_get_delayPtr = _lookup>( + 'spine_track_entry_get_delay', + ); late final _spine_track_entry_get_delay = _spine_track_entry_get_delayPtr .asFunction(); - void spine_track_entry_set_delay( - spine_track_entry entry, - double delay, - ) { - return _spine_track_entry_set_delay( - entry, - delay, - ); + void spine_track_entry_set_delay(spine_track_entry entry, double delay) { + return _spine_track_entry_set_delay(entry, delay); } - late final _spine_track_entry_set_delayPtr = _lookup< - ffi.NativeFunction>( - 'spine_track_entry_set_delay'); + late final _spine_track_entry_set_delayPtr = + _lookup>('spine_track_entry_set_delay'); late final _spine_track_entry_set_delay = _spine_track_entry_set_delayPtr .asFunction(); - double spine_track_entry_get_track_time( - spine_track_entry entry, - ) { - return _spine_track_entry_get_track_time( - entry, - ); + double spine_track_entry_get_track_time(spine_track_entry entry) { + return _spine_track_entry_get_track_time(entry); } - late final _spine_track_entry_get_track_timePtr = - _lookup>( - 'spine_track_entry_get_track_time'); - late final _spine_track_entry_get_track_time = - _spine_track_entry_get_track_timePtr - .asFunction(); + late final _spine_track_entry_get_track_timePtr = _lookup>( + 'spine_track_entry_get_track_time', + ); + late final _spine_track_entry_get_track_time = _spine_track_entry_get_track_timePtr + .asFunction(); - void spine_track_entry_set_track_time( - spine_track_entry entry, - double trackTime, - ) { - return _spine_track_entry_set_track_time( - entry, - trackTime, - ); + void spine_track_entry_set_track_time(spine_track_entry entry, double trackTime) { + return _spine_track_entry_set_track_time(entry, trackTime); } - late final _spine_track_entry_set_track_timePtr = _lookup< - ffi.NativeFunction>( - 'spine_track_entry_set_track_time'); - late final _spine_track_entry_set_track_time = - _spine_track_entry_set_track_timePtr - .asFunction(); + late final _spine_track_entry_set_track_timePtr = + _lookup>('spine_track_entry_set_track_time'); + late final _spine_track_entry_set_track_time = _spine_track_entry_set_track_timePtr + .asFunction(); - double spine_track_entry_get_track_end( - spine_track_entry entry, - ) { - return _spine_track_entry_get_track_end( - entry, - ); + double spine_track_entry_get_track_end(spine_track_entry entry) { + return _spine_track_entry_get_track_end(entry); } - late final _spine_track_entry_get_track_endPtr = - _lookup>( - 'spine_track_entry_get_track_end'); - late final _spine_track_entry_get_track_end = - _spine_track_entry_get_track_endPtr - .asFunction(); + late final _spine_track_entry_get_track_endPtr = _lookup>( + 'spine_track_entry_get_track_end', + ); + late final _spine_track_entry_get_track_end = _spine_track_entry_get_track_endPtr + .asFunction(); - void spine_track_entry_set_track_end( - spine_track_entry entry, - double trackEnd, - ) { - return _spine_track_entry_set_track_end( - entry, - trackEnd, - ); + void spine_track_entry_set_track_end(spine_track_entry entry, double trackEnd) { + return _spine_track_entry_set_track_end(entry, trackEnd); } - late final _spine_track_entry_set_track_endPtr = _lookup< - ffi.NativeFunction>( - 'spine_track_entry_set_track_end'); - late final _spine_track_entry_set_track_end = - _spine_track_entry_set_track_endPtr - .asFunction(); + late final _spine_track_entry_set_track_endPtr = + _lookup>('spine_track_entry_set_track_end'); + late final _spine_track_entry_set_track_end = _spine_track_entry_set_track_endPtr + .asFunction(); - double spine_track_entry_get_animation_start( - spine_track_entry entry, - ) { - return _spine_track_entry_get_animation_start( - entry, - ); + double spine_track_entry_get_animation_start(spine_track_entry entry) { + return _spine_track_entry_get_animation_start(entry); } late final _spine_track_entry_get_animation_startPtr = - _lookup>( - 'spine_track_entry_get_animation_start'); - late final _spine_track_entry_get_animation_start = - _spine_track_entry_get_animation_startPtr - .asFunction(); + _lookup>('spine_track_entry_get_animation_start'); + late final _spine_track_entry_get_animation_start = _spine_track_entry_get_animation_startPtr + .asFunction(); - void spine_track_entry_set_animation_start( - spine_track_entry entry, - double animationStart, - ) { - return _spine_track_entry_set_animation_start( - entry, - animationStart, - ); + void spine_track_entry_set_animation_start(spine_track_entry entry, double animationStart) { + return _spine_track_entry_set_animation_start(entry, animationStart); } - late final _spine_track_entry_set_animation_startPtr = _lookup< - ffi.NativeFunction>( - 'spine_track_entry_set_animation_start'); - late final _spine_track_entry_set_animation_start = - _spine_track_entry_set_animation_startPtr - .asFunction(); + late final _spine_track_entry_set_animation_startPtr = + _lookup>( + 'spine_track_entry_set_animation_start', + ); + late final _spine_track_entry_set_animation_start = _spine_track_entry_set_animation_startPtr + .asFunction(); - double spine_track_entry_get_animation_end( - spine_track_entry entry, - ) { - return _spine_track_entry_get_animation_end( - entry, - ); + double spine_track_entry_get_animation_end(spine_track_entry entry) { + return _spine_track_entry_get_animation_end(entry); } late final _spine_track_entry_get_animation_endPtr = - _lookup>( - 'spine_track_entry_get_animation_end'); - late final _spine_track_entry_get_animation_end = - _spine_track_entry_get_animation_endPtr - .asFunction(); + _lookup>('spine_track_entry_get_animation_end'); + late final _spine_track_entry_get_animation_end = _spine_track_entry_get_animation_endPtr + .asFunction(); - void spine_track_entry_set_animation_end( - spine_track_entry entry, - double animationEnd, - ) { - return _spine_track_entry_set_animation_end( - entry, - animationEnd, - ); + void spine_track_entry_set_animation_end(spine_track_entry entry, double animationEnd) { + return _spine_track_entry_set_animation_end(entry, animationEnd); } - late final _spine_track_entry_set_animation_endPtr = _lookup< - ffi.NativeFunction>( - 'spine_track_entry_set_animation_end'); - late final _spine_track_entry_set_animation_end = - _spine_track_entry_set_animation_endPtr - .asFunction(); + late final _spine_track_entry_set_animation_endPtr = + _lookup>( + 'spine_track_entry_set_animation_end', + ); + late final _spine_track_entry_set_animation_end = _spine_track_entry_set_animation_endPtr + .asFunction(); - double spine_track_entry_get_animation_last( - spine_track_entry entry, - ) { - return _spine_track_entry_get_animation_last( - entry, - ); + double spine_track_entry_get_animation_last(spine_track_entry entry) { + return _spine_track_entry_get_animation_last(entry); } late final _spine_track_entry_get_animation_lastPtr = - _lookup>( - 'spine_track_entry_get_animation_last'); - late final _spine_track_entry_get_animation_last = - _spine_track_entry_get_animation_lastPtr - .asFunction(); + _lookup>('spine_track_entry_get_animation_last'); + late final _spine_track_entry_get_animation_last = _spine_track_entry_get_animation_lastPtr + .asFunction(); - void spine_track_entry_set_animation_last( - spine_track_entry entry, - double animationLast, - ) { - return _spine_track_entry_set_animation_last( - entry, - animationLast, - ); + void spine_track_entry_set_animation_last(spine_track_entry entry, double animationLast) { + return _spine_track_entry_set_animation_last(entry, animationLast); } - late final _spine_track_entry_set_animation_lastPtr = _lookup< - ffi.NativeFunction>( - 'spine_track_entry_set_animation_last'); - late final _spine_track_entry_set_animation_last = - _spine_track_entry_set_animation_lastPtr - .asFunction(); + late final _spine_track_entry_set_animation_lastPtr = + _lookup>( + 'spine_track_entry_set_animation_last', + ); + late final _spine_track_entry_set_animation_last = _spine_track_entry_set_animation_lastPtr + .asFunction(); - double spine_track_entry_get_animation_time( - spine_track_entry entry, - ) { - return _spine_track_entry_get_animation_time( - entry, - ); + double spine_track_entry_get_animation_time(spine_track_entry entry) { + return _spine_track_entry_get_animation_time(entry); } late final _spine_track_entry_get_animation_timePtr = - _lookup>( - 'spine_track_entry_get_animation_time'); - late final _spine_track_entry_get_animation_time = - _spine_track_entry_get_animation_timePtr - .asFunction(); + _lookup>('spine_track_entry_get_animation_time'); + late final _spine_track_entry_get_animation_time = _spine_track_entry_get_animation_timePtr + .asFunction(); - double spine_track_entry_get_time_scale( - spine_track_entry entry, - ) { - return _spine_track_entry_get_time_scale( - entry, - ); + double spine_track_entry_get_time_scale(spine_track_entry entry) { + return _spine_track_entry_get_time_scale(entry); } - late final _spine_track_entry_get_time_scalePtr = - _lookup>( - 'spine_track_entry_get_time_scale'); - late final _spine_track_entry_get_time_scale = - _spine_track_entry_get_time_scalePtr - .asFunction(); + late final _spine_track_entry_get_time_scalePtr = _lookup>( + 'spine_track_entry_get_time_scale', + ); + late final _spine_track_entry_get_time_scale = _spine_track_entry_get_time_scalePtr + .asFunction(); - void spine_track_entry_set_time_scale( - spine_track_entry entry, - double timeScale, - ) { - return _spine_track_entry_set_time_scale( - entry, - timeScale, - ); + void spine_track_entry_set_time_scale(spine_track_entry entry, double timeScale) { + return _spine_track_entry_set_time_scale(entry, timeScale); } - late final _spine_track_entry_set_time_scalePtr = _lookup< - ffi.NativeFunction>( - 'spine_track_entry_set_time_scale'); - late final _spine_track_entry_set_time_scale = - _spine_track_entry_set_time_scalePtr - .asFunction(); + late final _spine_track_entry_set_time_scalePtr = + _lookup>('spine_track_entry_set_time_scale'); + late final _spine_track_entry_set_time_scale = _spine_track_entry_set_time_scalePtr + .asFunction(); - double spine_track_entry_get_alpha( - spine_track_entry entry, - ) { - return _spine_track_entry_get_alpha( - entry, - ); + double spine_track_entry_get_alpha(spine_track_entry entry) { + return _spine_track_entry_get_alpha(entry); } - late final _spine_track_entry_get_alphaPtr = - _lookup>( - 'spine_track_entry_get_alpha'); + late final _spine_track_entry_get_alphaPtr = _lookup>( + 'spine_track_entry_get_alpha', + ); late final _spine_track_entry_get_alpha = _spine_track_entry_get_alphaPtr .asFunction(); - void spine_track_entry_set_alpha( - spine_track_entry entry, - double alpha, - ) { - return _spine_track_entry_set_alpha( - entry, - alpha, - ); + void spine_track_entry_set_alpha(spine_track_entry entry, double alpha) { + return _spine_track_entry_set_alpha(entry, alpha); } - late final _spine_track_entry_set_alphaPtr = _lookup< - ffi.NativeFunction>( - 'spine_track_entry_set_alpha'); + late final _spine_track_entry_set_alphaPtr = + _lookup>('spine_track_entry_set_alpha'); late final _spine_track_entry_set_alpha = _spine_track_entry_set_alphaPtr .asFunction(); - double spine_track_entry_get_event_threshold( - spine_track_entry entry, - ) { - return _spine_track_entry_get_event_threshold( - entry, - ); + double spine_track_entry_get_event_threshold(spine_track_entry entry) { + return _spine_track_entry_get_event_threshold(entry); } late final _spine_track_entry_get_event_thresholdPtr = - _lookup>( - 'spine_track_entry_get_event_threshold'); - late final _spine_track_entry_get_event_threshold = - _spine_track_entry_get_event_thresholdPtr - .asFunction(); + _lookup>('spine_track_entry_get_event_threshold'); + late final _spine_track_entry_get_event_threshold = _spine_track_entry_get_event_thresholdPtr + .asFunction(); - void spine_track_entry_set_event_threshold( - spine_track_entry entry, - double eventThreshold, - ) { - return _spine_track_entry_set_event_threshold( - entry, - eventThreshold, - ); + void spine_track_entry_set_event_threshold(spine_track_entry entry, double eventThreshold) { + return _spine_track_entry_set_event_threshold(entry, eventThreshold); } - late final _spine_track_entry_set_event_thresholdPtr = _lookup< - ffi.NativeFunction>( - 'spine_track_entry_set_event_threshold'); - late final _spine_track_entry_set_event_threshold = - _spine_track_entry_set_event_thresholdPtr - .asFunction(); + late final _spine_track_entry_set_event_thresholdPtr = + _lookup>( + 'spine_track_entry_set_event_threshold', + ); + late final _spine_track_entry_set_event_threshold = _spine_track_entry_set_event_thresholdPtr + .asFunction(); - double spine_track_entry_get_alpha_attachment_threshold( - spine_track_entry entry, - ) { - return _spine_track_entry_get_alpha_attachment_threshold( - entry, - ); + double spine_track_entry_get_alpha_attachment_threshold(spine_track_entry entry) { + return _spine_track_entry_get_alpha_attachment_threshold(entry); } late final _spine_track_entry_get_alpha_attachment_thresholdPtr = _lookup>( - 'spine_track_entry_get_alpha_attachment_threshold'); - late final _spine_track_entry_get_alpha_attachment_threshold = - _spine_track_entry_get_alpha_attachment_thresholdPtr - .asFunction(); + 'spine_track_entry_get_alpha_attachment_threshold', + ); + late final _spine_track_entry_get_alpha_attachment_threshold = _spine_track_entry_get_alpha_attachment_thresholdPtr + .asFunction(); - void spine_track_entry_set_alpha_attachment_threshold( - spine_track_entry entry, - double attachmentThreshold, - ) { - return _spine_track_entry_set_alpha_attachment_threshold( - entry, - attachmentThreshold, - ); + void spine_track_entry_set_alpha_attachment_threshold(spine_track_entry entry, double attachmentThreshold) { + return _spine_track_entry_set_alpha_attachment_threshold(entry, attachmentThreshold); } - late final _spine_track_entry_set_alpha_attachment_thresholdPtr = _lookup< - ffi.NativeFunction>( - 'spine_track_entry_set_alpha_attachment_threshold'); - late final _spine_track_entry_set_alpha_attachment_threshold = - _spine_track_entry_set_alpha_attachment_thresholdPtr - .asFunction(); + late final _spine_track_entry_set_alpha_attachment_thresholdPtr = + _lookup>( + 'spine_track_entry_set_alpha_attachment_threshold', + ); + late final _spine_track_entry_set_alpha_attachment_threshold = _spine_track_entry_set_alpha_attachment_thresholdPtr + .asFunction(); - double spine_track_entry_get_mix_attachment_threshold( - spine_track_entry entry, - ) { - return _spine_track_entry_get_mix_attachment_threshold( - entry, - ); + double spine_track_entry_get_mix_attachment_threshold(spine_track_entry entry) { + return _spine_track_entry_get_mix_attachment_threshold(entry); } late final _spine_track_entry_get_mix_attachment_thresholdPtr = _lookup>( - 'spine_track_entry_get_mix_attachment_threshold'); - late final _spine_track_entry_get_mix_attachment_threshold = - _spine_track_entry_get_mix_attachment_thresholdPtr - .asFunction(); + 'spine_track_entry_get_mix_attachment_threshold', + ); + late final _spine_track_entry_get_mix_attachment_threshold = _spine_track_entry_get_mix_attachment_thresholdPtr + .asFunction(); - void spine_track_entry_set_mix_attachment_threshold( - spine_track_entry entry, - double attachmentThreshold, - ) { - return _spine_track_entry_set_mix_attachment_threshold( - entry, - attachmentThreshold, - ); + void spine_track_entry_set_mix_attachment_threshold(spine_track_entry entry, double attachmentThreshold) { + return _spine_track_entry_set_mix_attachment_threshold(entry, attachmentThreshold); } - late final _spine_track_entry_set_mix_attachment_thresholdPtr = _lookup< - ffi.NativeFunction>( - 'spine_track_entry_set_mix_attachment_threshold'); - late final _spine_track_entry_set_mix_attachment_threshold = - _spine_track_entry_set_mix_attachment_thresholdPtr - .asFunction(); + late final _spine_track_entry_set_mix_attachment_thresholdPtr = + _lookup>( + 'spine_track_entry_set_mix_attachment_threshold', + ); + late final _spine_track_entry_set_mix_attachment_threshold = _spine_track_entry_set_mix_attachment_thresholdPtr + .asFunction(); - double spine_track_entry_get_mix_draw_order_threshold( - spine_track_entry entry, - ) { - return _spine_track_entry_get_mix_draw_order_threshold( - entry, - ); + double spine_track_entry_get_mix_draw_order_threshold(spine_track_entry entry) { + return _spine_track_entry_get_mix_draw_order_threshold(entry); } late final _spine_track_entry_get_mix_draw_order_thresholdPtr = _lookup>( - 'spine_track_entry_get_mix_draw_order_threshold'); - late final _spine_track_entry_get_mix_draw_order_threshold = - _spine_track_entry_get_mix_draw_order_thresholdPtr - .asFunction(); + 'spine_track_entry_get_mix_draw_order_threshold', + ); + late final _spine_track_entry_get_mix_draw_order_threshold = _spine_track_entry_get_mix_draw_order_thresholdPtr + .asFunction(); - void spine_track_entry_set_mix_draw_order_threshold( - spine_track_entry entry, - double drawOrderThreshold, - ) { - return _spine_track_entry_set_mix_draw_order_threshold( - entry, - drawOrderThreshold, - ); + void spine_track_entry_set_mix_draw_order_threshold(spine_track_entry entry, double drawOrderThreshold) { + return _spine_track_entry_set_mix_draw_order_threshold(entry, drawOrderThreshold); } - late final _spine_track_entry_set_mix_draw_order_thresholdPtr = _lookup< - ffi.NativeFunction>( - 'spine_track_entry_set_mix_draw_order_threshold'); - late final _spine_track_entry_set_mix_draw_order_threshold = - _spine_track_entry_set_mix_draw_order_thresholdPtr - .asFunction(); + late final _spine_track_entry_set_mix_draw_order_thresholdPtr = + _lookup>( + 'spine_track_entry_set_mix_draw_order_threshold', + ); + late final _spine_track_entry_set_mix_draw_order_threshold = _spine_track_entry_set_mix_draw_order_thresholdPtr + .asFunction(); - spine_track_entry spine_track_entry_get_next( - spine_track_entry entry, - ) { - return _spine_track_entry_get_next( - entry, - ); + spine_track_entry spine_track_entry_get_next(spine_track_entry entry) { + return _spine_track_entry_get_next(entry); } - late final _spine_track_entry_get_nextPtr = _lookup< - ffi.NativeFunction>( - 'spine_track_entry_get_next'); + late final _spine_track_entry_get_nextPtr = + _lookup>('spine_track_entry_get_next'); late final _spine_track_entry_get_next = _spine_track_entry_get_nextPtr .asFunction(); - int spine_track_entry_is_complete( - spine_track_entry entry, - ) { - return _spine_track_entry_is_complete( - entry, - ); + int spine_track_entry_is_complete(spine_track_entry entry) { + return _spine_track_entry_is_complete(entry); } - late final _spine_track_entry_is_completePtr = - _lookup>( - 'spine_track_entry_is_complete'); + late final _spine_track_entry_is_completePtr = _lookup>( + 'spine_track_entry_is_complete', + ); late final _spine_track_entry_is_complete = _spine_track_entry_is_completePtr .asFunction(); - double spine_track_entry_get_mix_time( - spine_track_entry entry, - ) { - return _spine_track_entry_get_mix_time( - entry, - ); + double spine_track_entry_get_mix_time(spine_track_entry entry) { + return _spine_track_entry_get_mix_time(entry); } - late final _spine_track_entry_get_mix_timePtr = - _lookup>( - 'spine_track_entry_get_mix_time'); - late final _spine_track_entry_get_mix_time = - _spine_track_entry_get_mix_timePtr - .asFunction(); + late final _spine_track_entry_get_mix_timePtr = _lookup>( + 'spine_track_entry_get_mix_time', + ); + late final _spine_track_entry_get_mix_time = _spine_track_entry_get_mix_timePtr + .asFunction(); - void spine_track_entry_set_mix_time( - spine_track_entry entry, - double mixTime, - ) { - return _spine_track_entry_set_mix_time( - entry, - mixTime, - ); + void spine_track_entry_set_mix_time(spine_track_entry entry, double mixTime) { + return _spine_track_entry_set_mix_time(entry, mixTime); } - late final _spine_track_entry_set_mix_timePtr = _lookup< - ffi.NativeFunction>( - 'spine_track_entry_set_mix_time'); - late final _spine_track_entry_set_mix_time = - _spine_track_entry_set_mix_timePtr - .asFunction(); + late final _spine_track_entry_set_mix_timePtr = + _lookup>('spine_track_entry_set_mix_time'); + late final _spine_track_entry_set_mix_time = _spine_track_entry_set_mix_timePtr + .asFunction(); - double spine_track_entry_get_mix_duration( - spine_track_entry entry, - ) { - return _spine_track_entry_get_mix_duration( - entry, - ); + double spine_track_entry_get_mix_duration(spine_track_entry entry) { + return _spine_track_entry_get_mix_duration(entry); } late final _spine_track_entry_get_mix_durationPtr = - _lookup>( - 'spine_track_entry_get_mix_duration'); - late final _spine_track_entry_get_mix_duration = - _spine_track_entry_get_mix_durationPtr - .asFunction(); + _lookup>('spine_track_entry_get_mix_duration'); + late final _spine_track_entry_get_mix_duration = _spine_track_entry_get_mix_durationPtr + .asFunction(); - void spine_track_entry_set_mix_duration( - spine_track_entry entry, - double mixDuration, - ) { - return _spine_track_entry_set_mix_duration( - entry, - mixDuration, - ); + void spine_track_entry_set_mix_duration(spine_track_entry entry, double mixDuration) { + return _spine_track_entry_set_mix_duration(entry, mixDuration); } - late final _spine_track_entry_set_mix_durationPtr = _lookup< - ffi.NativeFunction>( - 'spine_track_entry_set_mix_duration'); - late final _spine_track_entry_set_mix_duration = - _spine_track_entry_set_mix_durationPtr - .asFunction(); + late final _spine_track_entry_set_mix_durationPtr = + _lookup>( + 'spine_track_entry_set_mix_duration', + ); + late final _spine_track_entry_set_mix_duration = _spine_track_entry_set_mix_durationPtr + .asFunction(); - int spine_track_entry_get_mix_blend( - spine_track_entry entry, - ) { - return _spine_track_entry_get_mix_blend( - entry, - ); + int spine_track_entry_get_mix_blend(spine_track_entry entry) { + return _spine_track_entry_get_mix_blend(entry); } - late final _spine_track_entry_get_mix_blendPtr = - _lookup>( - 'spine_track_entry_get_mix_blend'); - late final _spine_track_entry_get_mix_blend = - _spine_track_entry_get_mix_blendPtr - .asFunction(); + late final _spine_track_entry_get_mix_blendPtr = _lookup>( + 'spine_track_entry_get_mix_blend', + ); + late final _spine_track_entry_get_mix_blend = _spine_track_entry_get_mix_blendPtr + .asFunction(); - void spine_track_entry_set_mix_blend( - spine_track_entry entry, - int mixBlend, - ) { - return _spine_track_entry_set_mix_blend( - entry, - mixBlend, - ); + void spine_track_entry_set_mix_blend(spine_track_entry entry, int mixBlend) { + return _spine_track_entry_set_mix_blend(entry, mixBlend); } - late final _spine_track_entry_set_mix_blendPtr = _lookup< - ffi.NativeFunction>( - 'spine_track_entry_set_mix_blend'); - late final _spine_track_entry_set_mix_blend = - _spine_track_entry_set_mix_blendPtr - .asFunction(); + late final _spine_track_entry_set_mix_blendPtr = + _lookup>('spine_track_entry_set_mix_blend'); + late final _spine_track_entry_set_mix_blend = _spine_track_entry_set_mix_blendPtr + .asFunction(); - spine_track_entry spine_track_entry_get_mixing_from( - spine_track_entry entry, - ) { - return _spine_track_entry_get_mixing_from( - entry, - ); + spine_track_entry spine_track_entry_get_mixing_from(spine_track_entry entry) { + return _spine_track_entry_get_mixing_from(entry); } - late final _spine_track_entry_get_mixing_fromPtr = _lookup< - ffi.NativeFunction>( - 'spine_track_entry_get_mixing_from'); - late final _spine_track_entry_get_mixing_from = - _spine_track_entry_get_mixing_fromPtr - .asFunction(); + late final _spine_track_entry_get_mixing_fromPtr = + _lookup>('spine_track_entry_get_mixing_from'); + late final _spine_track_entry_get_mixing_from = _spine_track_entry_get_mixing_fromPtr + .asFunction(); - spine_track_entry spine_track_entry_get_mixing_to( - spine_track_entry entry, - ) { - return _spine_track_entry_get_mixing_to( - entry, - ); + spine_track_entry spine_track_entry_get_mixing_to(spine_track_entry entry) { + return _spine_track_entry_get_mixing_to(entry); } - late final _spine_track_entry_get_mixing_toPtr = _lookup< - ffi.NativeFunction>( - 'spine_track_entry_get_mixing_to'); - late final _spine_track_entry_get_mixing_to = - _spine_track_entry_get_mixing_toPtr - .asFunction(); + late final _spine_track_entry_get_mixing_toPtr = + _lookup>('spine_track_entry_get_mixing_to'); + late final _spine_track_entry_get_mixing_to = _spine_track_entry_get_mixing_toPtr + .asFunction(); - void spine_track_entry_reset_rotation_directions( - spine_track_entry entry, - ) { - return _spine_track_entry_reset_rotation_directions( - entry, - ); + void spine_track_entry_reset_rotation_directions(spine_track_entry entry) { + return _spine_track_entry_reset_rotation_directions(entry); } late final _spine_track_entry_reset_rotation_directionsPtr = - _lookup>( - 'spine_track_entry_reset_rotation_directions'); - late final _spine_track_entry_reset_rotation_directions = - _spine_track_entry_reset_rotation_directionsPtr - .asFunction(); + _lookup>('spine_track_entry_reset_rotation_directions'); + late final _spine_track_entry_reset_rotation_directions = _spine_track_entry_reset_rotation_directionsPtr + .asFunction(); - double spine_track_entry_get_track_complete( - spine_track_entry entry, - ) { - return _spine_track_entry_get_track_complete( - entry, - ); + double spine_track_entry_get_track_complete(spine_track_entry entry) { + return _spine_track_entry_get_track_complete(entry); } late final _spine_track_entry_get_track_completePtr = - _lookup>( - 'spine_track_entry_get_track_complete'); - late final _spine_track_entry_get_track_complete = - _spine_track_entry_get_track_completePtr - .asFunction(); + _lookup>('spine_track_entry_get_track_complete'); + late final _spine_track_entry_get_track_complete = _spine_track_entry_get_track_completePtr + .asFunction(); - int spine_track_entry_was_applied( - spine_track_entry entry, - ) { - return _spine_track_entry_was_applied( - entry, - ); + int spine_track_entry_was_applied(spine_track_entry entry) { + return _spine_track_entry_was_applied(entry); } - late final _spine_track_entry_was_appliedPtr = - _lookup>( - 'spine_track_entry_was_applied'); + late final _spine_track_entry_was_appliedPtr = _lookup>( + 'spine_track_entry_was_applied', + ); late final _spine_track_entry_was_applied = _spine_track_entry_was_appliedPtr .asFunction(); - int spine_track_entry_is_next_ready( - spine_track_entry entry, - ) { - return _spine_track_entry_is_next_ready( - entry, - ); + int spine_track_entry_is_next_ready(spine_track_entry entry) { + return _spine_track_entry_is_next_ready(entry); } - late final _spine_track_entry_is_next_readyPtr = - _lookup>( - 'spine_track_entry_is_next_ready'); - late final _spine_track_entry_is_next_ready = - _spine_track_entry_is_next_readyPtr - .asFunction(); + late final _spine_track_entry_is_next_readyPtr = _lookup>( + 'spine_track_entry_is_next_ready', + ); + late final _spine_track_entry_is_next_ready = _spine_track_entry_is_next_readyPtr + .asFunction(); /// OMITTED setListener() /// OMITTED setListener() - void spine_skeleton_update_cache( - spine_skeleton skeleton, - ) { - return _spine_skeleton_update_cache( - skeleton, - ); + void spine_skeleton_update_cache(spine_skeleton skeleton) { + return _spine_skeleton_update_cache(skeleton); } - late final _spine_skeleton_update_cachePtr = - _lookup>( - 'spine_skeleton_update_cache'); - late final _spine_skeleton_update_cache = _spine_skeleton_update_cachePtr - .asFunction(); + late final _spine_skeleton_update_cachePtr = _lookup>( + 'spine_skeleton_update_cache', + ); + late final _spine_skeleton_update_cache = _spine_skeleton_update_cachePtr.asFunction(); /// OMITTED printUpdateCache() - void spine_skeleton_update_world_transform( - spine_skeleton skeleton, - int physics, - ) { - return _spine_skeleton_update_world_transform( - skeleton, - physics, - ); + void spine_skeleton_update_world_transform(spine_skeleton skeleton, int physics) { + return _spine_skeleton_update_world_transform(skeleton, physics); } late final _spine_skeleton_update_world_transformPtr = _lookup>( - 'spine_skeleton_update_world_transform'); - late final _spine_skeleton_update_world_transform = - _spine_skeleton_update_world_transformPtr - .asFunction(); + 'spine_skeleton_update_world_transform', + ); + late final _spine_skeleton_update_world_transform = _spine_skeleton_update_world_transformPtr + .asFunction(); - void spine_skeleton_update_world_transform_bone( - spine_skeleton skeleton, - int physics, - spine_bone parent, - ) { - return _spine_skeleton_update_world_transform_bone( - skeleton, - physics, - parent, - ); + void spine_skeleton_update_world_transform_bone(spine_skeleton skeleton, int physics, spine_bone parent) { + return _spine_skeleton_update_world_transform_bone(skeleton, physics, parent); } - late final _spine_skeleton_update_world_transform_bonePtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_skeleton, ffi.Int32, - spine_bone)>>('spine_skeleton_update_world_transform_bone'); - late final _spine_skeleton_update_world_transform_bone = - _spine_skeleton_update_world_transform_bonePtr - .asFunction(); + late final _spine_skeleton_update_world_transform_bonePtr = + _lookup>( + 'spine_skeleton_update_world_transform_bone', + ); + late final _spine_skeleton_update_world_transform_bone = _spine_skeleton_update_world_transform_bonePtr + .asFunction(); - void spine_skeleton_set_to_setup_pose( - spine_skeleton skeleton, - ) { - return _spine_skeleton_set_to_setup_pose( - skeleton, - ); + void spine_skeleton_set_to_setup_pose(spine_skeleton skeleton) { + return _spine_skeleton_set_to_setup_pose(skeleton); } - late final _spine_skeleton_set_to_setup_posePtr = - _lookup>( - 'spine_skeleton_set_to_setup_pose'); - late final _spine_skeleton_set_to_setup_pose = - _spine_skeleton_set_to_setup_posePtr - .asFunction(); + late final _spine_skeleton_set_to_setup_posePtr = _lookup>( + 'spine_skeleton_set_to_setup_pose', + ); + late final _spine_skeleton_set_to_setup_pose = _spine_skeleton_set_to_setup_posePtr + .asFunction(); - void spine_skeleton_set_bones_to_setup_pose( - spine_skeleton skeleton, - ) { - return _spine_skeleton_set_bones_to_setup_pose( - skeleton, - ); + void spine_skeleton_set_bones_to_setup_pose(spine_skeleton skeleton) { + return _spine_skeleton_set_bones_to_setup_pose(skeleton); } late final _spine_skeleton_set_bones_to_setup_posePtr = - _lookup>( - 'spine_skeleton_set_bones_to_setup_pose'); - late final _spine_skeleton_set_bones_to_setup_pose = - _spine_skeleton_set_bones_to_setup_posePtr - .asFunction(); + _lookup>('spine_skeleton_set_bones_to_setup_pose'); + late final _spine_skeleton_set_bones_to_setup_pose = _spine_skeleton_set_bones_to_setup_posePtr + .asFunction(); - void spine_skeleton_set_slots_to_setup_pose( - spine_skeleton skeleton, - ) { - return _spine_skeleton_set_slots_to_setup_pose( - skeleton, - ); + void spine_skeleton_set_slots_to_setup_pose(spine_skeleton skeleton) { + return _spine_skeleton_set_slots_to_setup_pose(skeleton); } late final _spine_skeleton_set_slots_to_setup_posePtr = - _lookup>( - 'spine_skeleton_set_slots_to_setup_pose'); - late final _spine_skeleton_set_slots_to_setup_pose = - _spine_skeleton_set_slots_to_setup_posePtr - .asFunction(); + _lookup>('spine_skeleton_set_slots_to_setup_pose'); + late final _spine_skeleton_set_slots_to_setup_pose = _spine_skeleton_set_slots_to_setup_posePtr + .asFunction(); - spine_bone spine_skeleton_find_bone( - spine_skeleton skeleton, - ffi.Pointer boneName, - ) { - return _spine_skeleton_find_bone( - skeleton, - boneName, - ); + spine_bone spine_skeleton_find_bone(spine_skeleton skeleton, ffi.Pointer boneName) { + return _spine_skeleton_find_bone(skeleton, boneName); } - late final _spine_skeleton_find_bonePtr = _lookup< - ffi.NativeFunction< - spine_bone Function( - spine_skeleton, ffi.Pointer)>>('spine_skeleton_find_bone'); + late final _spine_skeleton_find_bonePtr = + _lookup)>>('spine_skeleton_find_bone'); late final _spine_skeleton_find_bone = _spine_skeleton_find_bonePtr .asFunction)>(); - spine_slot spine_skeleton_find_slot( - spine_skeleton skeleton, - ffi.Pointer slotName, - ) { - return _spine_skeleton_find_slot( - skeleton, - slotName, - ); + spine_slot spine_skeleton_find_slot(spine_skeleton skeleton, ffi.Pointer slotName) { + return _spine_skeleton_find_slot(skeleton, slotName); } - late final _spine_skeleton_find_slotPtr = _lookup< - ffi.NativeFunction< - spine_slot Function( - spine_skeleton, ffi.Pointer)>>('spine_skeleton_find_slot'); + late final _spine_skeleton_find_slotPtr = + _lookup)>>('spine_skeleton_find_slot'); late final _spine_skeleton_find_slot = _spine_skeleton_find_slotPtr .asFunction)>(); - void spine_skeleton_set_skin_by_name( - spine_skeleton skeleton, - ffi.Pointer skinName, - ) { - return _spine_skeleton_set_skin_by_name( - skeleton, - skinName, - ); + void spine_skeleton_set_skin_by_name(spine_skeleton skeleton, ffi.Pointer skinName) { + return _spine_skeleton_set_skin_by_name(skeleton, skinName); } - late final _spine_skeleton_set_skin_by_namePtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_skeleton, - ffi.Pointer)>>('spine_skeleton_set_skin_by_name'); - late final _spine_skeleton_set_skin_by_name = - _spine_skeleton_set_skin_by_namePtr - .asFunction)>(); + late final _spine_skeleton_set_skin_by_namePtr = + _lookup)>>( + 'spine_skeleton_set_skin_by_name', + ); + late final _spine_skeleton_set_skin_by_name = _spine_skeleton_set_skin_by_namePtr + .asFunction)>(); - void spine_skeleton_set_skin( - spine_skeleton skeleton, - spine_skin skin, - ) { - return _spine_skeleton_set_skin( - skeleton, - skin, - ); + void spine_skeleton_set_skin(spine_skeleton skeleton, spine_skin skin) { + return _spine_skeleton_set_skin(skeleton, skin); } - late final _spine_skeleton_set_skinPtr = _lookup< - ffi.NativeFunction>( - 'spine_skeleton_set_skin'); + late final _spine_skeleton_set_skinPtr = _lookup>( + 'spine_skeleton_set_skin', + ); late final _spine_skeleton_set_skin = _spine_skeleton_set_skinPtr .asFunction(); @@ -2925,1910 +1877,1196 @@ class SpineFlutterBindings { ffi.Pointer slotName, ffi.Pointer attachmentName, ) { - return _spine_skeleton_get_attachment_by_name( - skeleton, - slotName, - attachmentName, - ); + return _spine_skeleton_get_attachment_by_name(skeleton, slotName, attachmentName); } - late final _spine_skeleton_get_attachment_by_namePtr = _lookup< - ffi.NativeFunction< - spine_attachment Function(spine_skeleton, ffi.Pointer, - ffi.Pointer)>>('spine_skeleton_get_attachment_by_name'); - late final _spine_skeleton_get_attachment_by_name = - _spine_skeleton_get_attachment_by_namePtr.asFunction< - spine_attachment Function( - spine_skeleton, ffi.Pointer, ffi.Pointer)>(); + late final _spine_skeleton_get_attachment_by_namePtr = + _lookup, ffi.Pointer)>>( + 'spine_skeleton_get_attachment_by_name', + ); + late final _spine_skeleton_get_attachment_by_name = _spine_skeleton_get_attachment_by_namePtr + .asFunction, ffi.Pointer)>(); spine_attachment spine_skeleton_get_attachment( spine_skeleton skeleton, int slotIndex, ffi.Pointer attachmentName, ) { - return _spine_skeleton_get_attachment( - skeleton, - slotIndex, - attachmentName, - ); + return _spine_skeleton_get_attachment(skeleton, slotIndex, attachmentName); } - late final _spine_skeleton_get_attachmentPtr = _lookup< - ffi.NativeFunction< - spine_attachment Function(spine_skeleton, ffi.Int32, - ffi.Pointer)>>('spine_skeleton_get_attachment'); - late final _spine_skeleton_get_attachment = - _spine_skeleton_get_attachmentPtr.asFunction< - spine_attachment Function(spine_skeleton, int, ffi.Pointer)>(); + late final _spine_skeleton_get_attachmentPtr = + _lookup)>>( + 'spine_skeleton_get_attachment', + ); + late final _spine_skeleton_get_attachment = _spine_skeleton_get_attachmentPtr + .asFunction)>(); void spine_skeleton_set_attachment( spine_skeleton skeleton, ffi.Pointer slotName, ffi.Pointer attachmentName, ) { - return _spine_skeleton_set_attachment( - skeleton, - slotName, - attachmentName, - ); + return _spine_skeleton_set_attachment(skeleton, slotName, attachmentName); } - late final _spine_skeleton_set_attachmentPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_skeleton, ffi.Pointer, - ffi.Pointer)>>('spine_skeleton_set_attachment'); - late final _spine_skeleton_set_attachment = - _spine_skeleton_set_attachmentPtr.asFunction< - void Function( - spine_skeleton, ffi.Pointer, ffi.Pointer)>(); + late final _spine_skeleton_set_attachmentPtr = + _lookup, ffi.Pointer)>>( + 'spine_skeleton_set_attachment', + ); + late final _spine_skeleton_set_attachment = _spine_skeleton_set_attachmentPtr + .asFunction, ffi.Pointer)>(); - spine_ik_constraint spine_skeleton_find_ik_constraint( - spine_skeleton skeleton, - ffi.Pointer constraintName, - ) { - return _spine_skeleton_find_ik_constraint( - skeleton, - constraintName, - ); + spine_ik_constraint spine_skeleton_find_ik_constraint(spine_skeleton skeleton, ffi.Pointer constraintName) { + return _spine_skeleton_find_ik_constraint(skeleton, constraintName); } - late final _spine_skeleton_find_ik_constraintPtr = _lookup< - ffi.NativeFunction< - spine_ik_constraint Function(spine_skeleton, - ffi.Pointer)>>('spine_skeleton_find_ik_constraint'); - late final _spine_skeleton_find_ik_constraint = - _spine_skeleton_find_ik_constraintPtr.asFunction< - spine_ik_constraint Function(spine_skeleton, ffi.Pointer)>(); + late final _spine_skeleton_find_ik_constraintPtr = + _lookup)>>( + 'spine_skeleton_find_ik_constraint', + ); + late final _spine_skeleton_find_ik_constraint = _spine_skeleton_find_ik_constraintPtr + .asFunction)>(); spine_transform_constraint spine_skeleton_find_transform_constraint( spine_skeleton skeleton, ffi.Pointer constraintName, ) { - return _spine_skeleton_find_transform_constraint( - skeleton, - constraintName, - ); + return _spine_skeleton_find_transform_constraint(skeleton, constraintName); } - late final _spine_skeleton_find_transform_constraintPtr = _lookup< - ffi.NativeFunction< - spine_transform_constraint Function(spine_skeleton, - ffi.Pointer)>>('spine_skeleton_find_transform_constraint'); - late final _spine_skeleton_find_transform_constraint = - _spine_skeleton_find_transform_constraintPtr.asFunction< - spine_transform_constraint Function( - spine_skeleton, ffi.Pointer)>(); + late final _spine_skeleton_find_transform_constraintPtr = + _lookup)>>( + 'spine_skeleton_find_transform_constraint', + ); + late final _spine_skeleton_find_transform_constraint = _spine_skeleton_find_transform_constraintPtr + .asFunction)>(); - spine_path_constraint spine_skeleton_find_path_constraint( - spine_skeleton skeleton, - ffi.Pointer constraintName, - ) { - return _spine_skeleton_find_path_constraint( - skeleton, - constraintName, - ); + spine_path_constraint spine_skeleton_find_path_constraint(spine_skeleton skeleton, ffi.Pointer constraintName) { + return _spine_skeleton_find_path_constraint(skeleton, constraintName); } - late final _spine_skeleton_find_path_constraintPtr = _lookup< - ffi.NativeFunction< - spine_path_constraint Function(spine_skeleton, - ffi.Pointer)>>('spine_skeleton_find_path_constraint'); - late final _spine_skeleton_find_path_constraint = - _spine_skeleton_find_path_constraintPtr.asFunction< - spine_path_constraint Function(spine_skeleton, ffi.Pointer)>(); + late final _spine_skeleton_find_path_constraintPtr = + _lookup)>>( + 'spine_skeleton_find_path_constraint', + ); + late final _spine_skeleton_find_path_constraint = _spine_skeleton_find_path_constraintPtr + .asFunction)>(); spine_physics_constraint spine_skeleton_find_physics_constraint( spine_skeleton skeleton, ffi.Pointer constraintName, ) { - return _spine_skeleton_find_physics_constraint( - skeleton, - constraintName, - ); + return _spine_skeleton_find_physics_constraint(skeleton, constraintName); } - late final _spine_skeleton_find_physics_constraintPtr = _lookup< - ffi.NativeFunction< - spine_physics_constraint Function(spine_skeleton, - ffi.Pointer)>>('spine_skeleton_find_physics_constraint'); - late final _spine_skeleton_find_physics_constraint = - _spine_skeleton_find_physics_constraintPtr.asFunction< - spine_physics_constraint Function( - spine_skeleton, ffi.Pointer)>(); + late final _spine_skeleton_find_physics_constraintPtr = + _lookup)>>( + 'spine_skeleton_find_physics_constraint', + ); + late final _spine_skeleton_find_physics_constraint = _spine_skeleton_find_physics_constraintPtr + .asFunction)>(); - spine_bounds spine_skeleton_get_bounds( - spine_skeleton skeleton, - ) { - return _spine_skeleton_get_bounds( - skeleton, - ); + spine_bounds spine_skeleton_get_bounds(spine_skeleton skeleton) { + return _spine_skeleton_get_bounds(skeleton); } - late final _spine_skeleton_get_boundsPtr = - _lookup>( - 'spine_skeleton_get_bounds'); + late final _spine_skeleton_get_boundsPtr = _lookup>( + 'spine_skeleton_get_bounds', + ); late final _spine_skeleton_get_bounds = _spine_skeleton_get_boundsPtr .asFunction(); - spine_bone spine_skeleton_get_root_bone( - spine_skeleton skeleton, - ) { - return _spine_skeleton_get_root_bone( - skeleton, - ); + spine_bone spine_skeleton_get_root_bone(spine_skeleton skeleton) { + return _spine_skeleton_get_root_bone(skeleton); } - late final _spine_skeleton_get_root_bonePtr = - _lookup>( - 'spine_skeleton_get_root_bone'); + late final _spine_skeleton_get_root_bonePtr = _lookup>( + 'spine_skeleton_get_root_bone', + ); late final _spine_skeleton_get_root_bone = _spine_skeleton_get_root_bonePtr .asFunction(); - spine_skeleton_data spine_skeleton_get_data( - spine_skeleton skeleton, - ) { - return _spine_skeleton_get_data( - skeleton, - ); + spine_skeleton_data spine_skeleton_get_data(spine_skeleton skeleton) { + return _spine_skeleton_get_data(skeleton); } - late final _spine_skeleton_get_dataPtr = - _lookup>( - 'spine_skeleton_get_data'); + late final _spine_skeleton_get_dataPtr = _lookup>( + 'spine_skeleton_get_data', + ); late final _spine_skeleton_get_data = _spine_skeleton_get_dataPtr .asFunction(); - int spine_skeleton_get_num_bones( - spine_skeleton skeleton, - ) { - return _spine_skeleton_get_num_bones( - skeleton, - ); + int spine_skeleton_get_num_bones(spine_skeleton skeleton) { + return _spine_skeleton_get_num_bones(skeleton); } - late final _spine_skeleton_get_num_bonesPtr = - _lookup>( - 'spine_skeleton_get_num_bones'); + late final _spine_skeleton_get_num_bonesPtr = _lookup>( + 'spine_skeleton_get_num_bones', + ); late final _spine_skeleton_get_num_bones = _spine_skeleton_get_num_bonesPtr .asFunction(); - ffi.Pointer spine_skeleton_get_bones( - spine_skeleton skeleton, - ) { - return _spine_skeleton_get_bones( - skeleton, - ); + ffi.Pointer spine_skeleton_get_bones(spine_skeleton skeleton) { + return _spine_skeleton_get_bones(skeleton); } - late final _spine_skeleton_get_bonesPtr = _lookup< - ffi.NativeFunction Function(spine_skeleton)>>( - 'spine_skeleton_get_bones'); + late final _spine_skeleton_get_bonesPtr = + _lookup Function(spine_skeleton)>>('spine_skeleton_get_bones'); late final _spine_skeleton_get_bones = _spine_skeleton_get_bonesPtr .asFunction Function(spine_skeleton)>(); /// OMITTED getUpdateCacheList() - int spine_skeleton_get_num_slots( - spine_skeleton skeleton, - ) { - return _spine_skeleton_get_num_slots( - skeleton, - ); + int spine_skeleton_get_num_slots(spine_skeleton skeleton) { + return _spine_skeleton_get_num_slots(skeleton); } - late final _spine_skeleton_get_num_slotsPtr = - _lookup>( - 'spine_skeleton_get_num_slots'); + late final _spine_skeleton_get_num_slotsPtr = _lookup>( + 'spine_skeleton_get_num_slots', + ); late final _spine_skeleton_get_num_slots = _spine_skeleton_get_num_slotsPtr .asFunction(); - ffi.Pointer spine_skeleton_get_slots( - spine_skeleton skeleton, - ) { - return _spine_skeleton_get_slots( - skeleton, - ); + ffi.Pointer spine_skeleton_get_slots(spine_skeleton skeleton) { + return _spine_skeleton_get_slots(skeleton); } - late final _spine_skeleton_get_slotsPtr = _lookup< - ffi.NativeFunction Function(spine_skeleton)>>( - 'spine_skeleton_get_slots'); + late final _spine_skeleton_get_slotsPtr = + _lookup Function(spine_skeleton)>>('spine_skeleton_get_slots'); late final _spine_skeleton_get_slots = _spine_skeleton_get_slotsPtr .asFunction Function(spine_skeleton)>(); - int spine_skeleton_get_num_draw_order( - spine_skeleton skeleton, - ) { - return _spine_skeleton_get_num_draw_order( - skeleton, - ); + int spine_skeleton_get_num_draw_order(spine_skeleton skeleton) { + return _spine_skeleton_get_num_draw_order(skeleton); } - late final _spine_skeleton_get_num_draw_orderPtr = - _lookup>( - 'spine_skeleton_get_num_draw_order'); - late final _spine_skeleton_get_num_draw_order = - _spine_skeleton_get_num_draw_orderPtr - .asFunction(); + late final _spine_skeleton_get_num_draw_orderPtr = _lookup>( + 'spine_skeleton_get_num_draw_order', + ); + late final _spine_skeleton_get_num_draw_order = _spine_skeleton_get_num_draw_orderPtr + .asFunction(); - ffi.Pointer spine_skeleton_get_draw_order( - spine_skeleton skeleton, - ) { - return _spine_skeleton_get_draw_order( - skeleton, - ); + ffi.Pointer spine_skeleton_get_draw_order(spine_skeleton skeleton) { + return _spine_skeleton_get_draw_order(skeleton); } - late final _spine_skeleton_get_draw_orderPtr = _lookup< - ffi.NativeFunction Function(spine_skeleton)>>( - 'spine_skeleton_get_draw_order'); + late final _spine_skeleton_get_draw_orderPtr = + _lookup Function(spine_skeleton)>>('spine_skeleton_get_draw_order'); late final _spine_skeleton_get_draw_order = _spine_skeleton_get_draw_orderPtr .asFunction Function(spine_skeleton)>(); - int spine_skeleton_get_num_ik_constraints( - spine_skeleton skeleton, - ) { - return _spine_skeleton_get_num_ik_constraints( - skeleton, - ); + int spine_skeleton_get_num_ik_constraints(spine_skeleton skeleton) { + return _spine_skeleton_get_num_ik_constraints(skeleton); } late final _spine_skeleton_get_num_ik_constraintsPtr = - _lookup>( - 'spine_skeleton_get_num_ik_constraints'); - late final _spine_skeleton_get_num_ik_constraints = - _spine_skeleton_get_num_ik_constraintsPtr - .asFunction(); + _lookup>('spine_skeleton_get_num_ik_constraints'); + late final _spine_skeleton_get_num_ik_constraints = _spine_skeleton_get_num_ik_constraintsPtr + .asFunction(); - ffi.Pointer spine_skeleton_get_ik_constraints( - spine_skeleton skeleton, - ) { - return _spine_skeleton_get_ik_constraints( - skeleton, - ); + ffi.Pointer spine_skeleton_get_ik_constraints(spine_skeleton skeleton) { + return _spine_skeleton_get_ik_constraints(skeleton); } - late final _spine_skeleton_get_ik_constraintsPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_skeleton)>>('spine_skeleton_get_ik_constraints'); - late final _spine_skeleton_get_ik_constraints = - _spine_skeleton_get_ik_constraintsPtr.asFunction< - ffi.Pointer Function(spine_skeleton)>(); + late final _spine_skeleton_get_ik_constraintsPtr = + _lookup Function(spine_skeleton)>>( + 'spine_skeleton_get_ik_constraints', + ); + late final _spine_skeleton_get_ik_constraints = _spine_skeleton_get_ik_constraintsPtr + .asFunction Function(spine_skeleton)>(); - int spine_skeleton_get_num_transform_constraints( - spine_skeleton skeleton, - ) { - return _spine_skeleton_get_num_transform_constraints( - skeleton, - ); + int spine_skeleton_get_num_transform_constraints(spine_skeleton skeleton) { + return _spine_skeleton_get_num_transform_constraints(skeleton); } late final _spine_skeleton_get_num_transform_constraintsPtr = - _lookup>( - 'spine_skeleton_get_num_transform_constraints'); - late final _spine_skeleton_get_num_transform_constraints = - _spine_skeleton_get_num_transform_constraintsPtr - .asFunction(); + _lookup>('spine_skeleton_get_num_transform_constraints'); + late final _spine_skeleton_get_num_transform_constraints = _spine_skeleton_get_num_transform_constraintsPtr + .asFunction(); - ffi.Pointer - spine_skeleton_get_transform_constraints( - spine_skeleton skeleton, - ) { - return _spine_skeleton_get_transform_constraints( - skeleton, - ); + ffi.Pointer spine_skeleton_get_transform_constraints(spine_skeleton skeleton) { + return _spine_skeleton_get_transform_constraints(skeleton); } - late final _spine_skeleton_get_transform_constraintsPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_skeleton)>>('spine_skeleton_get_transform_constraints'); - late final _spine_skeleton_get_transform_constraints = - _spine_skeleton_get_transform_constraintsPtr.asFunction< - ffi.Pointer Function(spine_skeleton)>(); + late final _spine_skeleton_get_transform_constraintsPtr = + _lookup Function(spine_skeleton)>>( + 'spine_skeleton_get_transform_constraints', + ); + late final _spine_skeleton_get_transform_constraints = _spine_skeleton_get_transform_constraintsPtr + .asFunction Function(spine_skeleton)>(); - int spine_skeleton_get_num_path_constraints( - spine_skeleton skeleton, - ) { - return _spine_skeleton_get_num_path_constraints( - skeleton, - ); + int spine_skeleton_get_num_path_constraints(spine_skeleton skeleton) { + return _spine_skeleton_get_num_path_constraints(skeleton); } late final _spine_skeleton_get_num_path_constraintsPtr = - _lookup>( - 'spine_skeleton_get_num_path_constraints'); - late final _spine_skeleton_get_num_path_constraints = - _spine_skeleton_get_num_path_constraintsPtr - .asFunction(); + _lookup>('spine_skeleton_get_num_path_constraints'); + late final _spine_skeleton_get_num_path_constraints = _spine_skeleton_get_num_path_constraintsPtr + .asFunction(); - ffi.Pointer spine_skeleton_get_path_constraints( - spine_skeleton skeleton, - ) { - return _spine_skeleton_get_path_constraints( - skeleton, - ); + ffi.Pointer spine_skeleton_get_path_constraints(spine_skeleton skeleton) { + return _spine_skeleton_get_path_constraints(skeleton); } - late final _spine_skeleton_get_path_constraintsPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_skeleton)>>('spine_skeleton_get_path_constraints'); - late final _spine_skeleton_get_path_constraints = - _spine_skeleton_get_path_constraintsPtr.asFunction< - ffi.Pointer Function(spine_skeleton)>(); + late final _spine_skeleton_get_path_constraintsPtr = + _lookup Function(spine_skeleton)>>( + 'spine_skeleton_get_path_constraints', + ); + late final _spine_skeleton_get_path_constraints = _spine_skeleton_get_path_constraintsPtr + .asFunction Function(spine_skeleton)>(); - int spine_skeleton_get_num_physics_constraints( - spine_skeleton skeleton, - ) { - return _spine_skeleton_get_num_physics_constraints( - skeleton, - ); + int spine_skeleton_get_num_physics_constraints(spine_skeleton skeleton) { + return _spine_skeleton_get_num_physics_constraints(skeleton); } late final _spine_skeleton_get_num_physics_constraintsPtr = - _lookup>( - 'spine_skeleton_get_num_physics_constraints'); - late final _spine_skeleton_get_num_physics_constraints = - _spine_skeleton_get_num_physics_constraintsPtr - .asFunction(); + _lookup>('spine_skeleton_get_num_physics_constraints'); + late final _spine_skeleton_get_num_physics_constraints = _spine_skeleton_get_num_physics_constraintsPtr + .asFunction(); - ffi.Pointer spine_skeleton_get_physics_constraints( - spine_skeleton skeleton, - ) { - return _spine_skeleton_get_physics_constraints( - skeleton, - ); + ffi.Pointer spine_skeleton_get_physics_constraints(spine_skeleton skeleton) { + return _spine_skeleton_get_physics_constraints(skeleton); } - late final _spine_skeleton_get_physics_constraintsPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_skeleton)>>('spine_skeleton_get_physics_constraints'); - late final _spine_skeleton_get_physics_constraints = - _spine_skeleton_get_physics_constraintsPtr.asFunction< - ffi.Pointer Function(spine_skeleton)>(); + late final _spine_skeleton_get_physics_constraintsPtr = + _lookup Function(spine_skeleton)>>( + 'spine_skeleton_get_physics_constraints', + ); + late final _spine_skeleton_get_physics_constraints = _spine_skeleton_get_physics_constraintsPtr + .asFunction Function(spine_skeleton)>(); - spine_skin spine_skeleton_get_skin( - spine_skeleton skeleton, - ) { - return _spine_skeleton_get_skin( - skeleton, - ); + spine_skin spine_skeleton_get_skin(spine_skeleton skeleton) { + return _spine_skeleton_get_skin(skeleton); } - late final _spine_skeleton_get_skinPtr = - _lookup>( - 'spine_skeleton_get_skin'); - late final _spine_skeleton_get_skin = _spine_skeleton_get_skinPtr - .asFunction(); + late final _spine_skeleton_get_skinPtr = _lookup>( + 'spine_skeleton_get_skin', + ); + late final _spine_skeleton_get_skin = _spine_skeleton_get_skinPtr.asFunction(); - spine_color spine_skeleton_get_color( - spine_skeleton skeleton, - ) { - return _spine_skeleton_get_color( - skeleton, - ); + spine_color spine_skeleton_get_color(spine_skeleton skeleton) { + return _spine_skeleton_get_color(skeleton); } - late final _spine_skeleton_get_colorPtr = - _lookup>( - 'spine_skeleton_get_color'); + late final _spine_skeleton_get_colorPtr = _lookup>( + 'spine_skeleton_get_color', + ); late final _spine_skeleton_get_color = _spine_skeleton_get_colorPtr .asFunction(); - void spine_skeleton_set_color( - spine_skeleton skeleton, - double r, - double g, - double b, - double a, - ) { - return _spine_skeleton_set_color( - skeleton, - r, - g, - b, - a, - ); + void spine_skeleton_set_color(spine_skeleton skeleton, double r, double g, double b, double a) { + return _spine_skeleton_set_color(skeleton, r, g, b, a); } - late final _spine_skeleton_set_colorPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_skeleton, ffi.Float, ffi.Float, ffi.Float, - ffi.Float)>>('spine_skeleton_set_color'); - late final _spine_skeleton_set_color = - _spine_skeleton_set_colorPtr.asFunction< - void Function(spine_skeleton, double, double, double, double)>(); + late final _spine_skeleton_set_colorPtr = + _lookup>( + 'spine_skeleton_set_color', + ); + late final _spine_skeleton_set_color = _spine_skeleton_set_colorPtr + .asFunction(); - void spine_skeleton_set_position( - spine_skeleton skeleton, - double x, - double y, - ) { - return _spine_skeleton_set_position( - skeleton, - x, - y, - ); + void spine_skeleton_set_position(spine_skeleton skeleton, double x, double y) { + return _spine_skeleton_set_position(skeleton, x, y); } - late final _spine_skeleton_set_positionPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_skeleton, ffi.Float, - ffi.Float)>>('spine_skeleton_set_position'); + late final _spine_skeleton_set_positionPtr = + _lookup>( + 'spine_skeleton_set_position', + ); late final _spine_skeleton_set_position = _spine_skeleton_set_positionPtr .asFunction(); - double spine_skeleton_get_x( - spine_skeleton skeleton, - ) { - return _spine_skeleton_get_x( - skeleton, - ); + double spine_skeleton_get_x(spine_skeleton skeleton) { + return _spine_skeleton_get_x(skeleton); } - late final _spine_skeleton_get_xPtr = - _lookup>( - 'spine_skeleton_get_x'); - late final _spine_skeleton_get_x = - _spine_skeleton_get_xPtr.asFunction(); + late final _spine_skeleton_get_xPtr = _lookup>( + 'spine_skeleton_get_x', + ); + late final _spine_skeleton_get_x = _spine_skeleton_get_xPtr.asFunction(); - void spine_skeleton_set_x( - spine_skeleton skeleton, - double x, - ) { - return _spine_skeleton_set_x( - skeleton, - x, - ); + void spine_skeleton_set_x(spine_skeleton skeleton, double x) { + return _spine_skeleton_set_x(skeleton, x); } - late final _spine_skeleton_set_xPtr = - _lookup>( - 'spine_skeleton_set_x'); - late final _spine_skeleton_set_x = _spine_skeleton_set_xPtr - .asFunction(); + late final _spine_skeleton_set_xPtr = _lookup>( + 'spine_skeleton_set_x', + ); + late final _spine_skeleton_set_x = _spine_skeleton_set_xPtr.asFunction(); - double spine_skeleton_get_y( - spine_skeleton skeleton, - ) { - return _spine_skeleton_get_y( - skeleton, - ); + double spine_skeleton_get_y(spine_skeleton skeleton) { + return _spine_skeleton_get_y(skeleton); } - late final _spine_skeleton_get_yPtr = - _lookup>( - 'spine_skeleton_get_y'); - late final _spine_skeleton_get_y = - _spine_skeleton_get_yPtr.asFunction(); + late final _spine_skeleton_get_yPtr = _lookup>( + 'spine_skeleton_get_y', + ); + late final _spine_skeleton_get_y = _spine_skeleton_get_yPtr.asFunction(); - void spine_skeleton_set_y( - spine_skeleton skeleton, - double y, - ) { - return _spine_skeleton_set_y( - skeleton, - y, - ); + void spine_skeleton_set_y(spine_skeleton skeleton, double y) { + return _spine_skeleton_set_y(skeleton, y); } - late final _spine_skeleton_set_yPtr = - _lookup>( - 'spine_skeleton_set_y'); - late final _spine_skeleton_set_y = _spine_skeleton_set_yPtr - .asFunction(); + late final _spine_skeleton_set_yPtr = _lookup>( + 'spine_skeleton_set_y', + ); + late final _spine_skeleton_set_y = _spine_skeleton_set_yPtr.asFunction(); - double spine_skeleton_get_scale_x( - spine_skeleton skeleton, - ) { - return _spine_skeleton_get_scale_x( - skeleton, - ); + double spine_skeleton_get_scale_x(spine_skeleton skeleton) { + return _spine_skeleton_get_scale_x(skeleton); } - late final _spine_skeleton_get_scale_xPtr = - _lookup>( - 'spine_skeleton_get_scale_x'); - late final _spine_skeleton_get_scale_x = _spine_skeleton_get_scale_xPtr - .asFunction(); + late final _spine_skeleton_get_scale_xPtr = _lookup>( + 'spine_skeleton_get_scale_x', + ); + late final _spine_skeleton_get_scale_x = _spine_skeleton_get_scale_xPtr.asFunction(); - void spine_skeleton_set_scale_x( - spine_skeleton skeleton, - double scaleX, - ) { - return _spine_skeleton_set_scale_x( - skeleton, - scaleX, - ); + void spine_skeleton_set_scale_x(spine_skeleton skeleton, double scaleX) { + return _spine_skeleton_set_scale_x(skeleton, scaleX); } - late final _spine_skeleton_set_scale_xPtr = - _lookup>( - 'spine_skeleton_set_scale_x'); + late final _spine_skeleton_set_scale_xPtr = _lookup>( + 'spine_skeleton_set_scale_x', + ); late final _spine_skeleton_set_scale_x = _spine_skeleton_set_scale_xPtr .asFunction(); - double spine_skeleton_get_scale_y( - spine_skeleton skeleton, - ) { - return _spine_skeleton_get_scale_y( - skeleton, - ); + double spine_skeleton_get_scale_y(spine_skeleton skeleton) { + return _spine_skeleton_get_scale_y(skeleton); } - late final _spine_skeleton_get_scale_yPtr = - _lookup>( - 'spine_skeleton_get_scale_y'); - late final _spine_skeleton_get_scale_y = _spine_skeleton_get_scale_yPtr - .asFunction(); + late final _spine_skeleton_get_scale_yPtr = _lookup>( + 'spine_skeleton_get_scale_y', + ); + late final _spine_skeleton_get_scale_y = _spine_skeleton_get_scale_yPtr.asFunction(); - void spine_skeleton_set_scale_y( - spine_skeleton skeleton, - double scaleY, - ) { - return _spine_skeleton_set_scale_y( - skeleton, - scaleY, - ); + void spine_skeleton_set_scale_y(spine_skeleton skeleton, double scaleY) { + return _spine_skeleton_set_scale_y(skeleton, scaleY); } - late final _spine_skeleton_set_scale_yPtr = - _lookup>( - 'spine_skeleton_set_scale_y'); + late final _spine_skeleton_set_scale_yPtr = _lookup>( + 'spine_skeleton_set_scale_y', + ); late final _spine_skeleton_set_scale_y = _spine_skeleton_set_scale_yPtr .asFunction(); - double spine_skeleton_get_time( - spine_skeleton skeleton, - ) { - return _spine_skeleton_get_time( - skeleton, - ); + double spine_skeleton_get_time(spine_skeleton skeleton) { + return _spine_skeleton_get_time(skeleton); } - late final _spine_skeleton_get_timePtr = - _lookup>( - 'spine_skeleton_get_time'); - late final _spine_skeleton_get_time = - _spine_skeleton_get_timePtr.asFunction(); + late final _spine_skeleton_get_timePtr = _lookup>( + 'spine_skeleton_get_time', + ); + late final _spine_skeleton_get_time = _spine_skeleton_get_timePtr.asFunction(); - void spine_skeleton_set_time( - spine_skeleton skeleton, - double time, - ) { - return _spine_skeleton_set_time( - skeleton, - time, - ); + void spine_skeleton_set_time(spine_skeleton skeleton, double time) { + return _spine_skeleton_set_time(skeleton, time); } - late final _spine_skeleton_set_timePtr = - _lookup>( - 'spine_skeleton_set_time'); - late final _spine_skeleton_set_time = _spine_skeleton_set_timePtr - .asFunction(); + late final _spine_skeleton_set_timePtr = _lookup>( + 'spine_skeleton_set_time', + ); + late final _spine_skeleton_set_time = _spine_skeleton_set_timePtr.asFunction(); - void spine_skeleton_update( - spine_skeleton skeleton, - double delta, - ) { - return _spine_skeleton_update( - skeleton, - delta, - ); + void spine_skeleton_update(spine_skeleton skeleton, double delta) { + return _spine_skeleton_update(skeleton, delta); } - late final _spine_skeleton_updatePtr = - _lookup>( - 'spine_skeleton_update'); - late final _spine_skeleton_update = _spine_skeleton_updatePtr - .asFunction(); + late final _spine_skeleton_updatePtr = _lookup>( + 'spine_skeleton_update', + ); + late final _spine_skeleton_update = _spine_skeleton_updatePtr.asFunction(); - ffi.Pointer spine_event_data_get_name( - spine_event_data event, - ) { - return _spine_event_data_get_name( - event, - ); + ffi.Pointer spine_event_data_get_name(spine_event_data event) { + return _spine_event_data_get_name(event); } - late final _spine_event_data_get_namePtr = - _lookup Function(spine_event_data)>>( - 'spine_event_data_get_name'); + late final _spine_event_data_get_namePtr = _lookup Function(spine_event_data)>>( + 'spine_event_data_get_name', + ); late final _spine_event_data_get_name = _spine_event_data_get_namePtr .asFunction Function(spine_event_data)>(); - int spine_event_data_get_int_value( - spine_event_data event, - ) { - return _spine_event_data_get_int_value( - event, - ); + int spine_event_data_get_int_value(spine_event_data event) { + return _spine_event_data_get_int_value(event); } - late final _spine_event_data_get_int_valuePtr = - _lookup>( - 'spine_event_data_get_int_value'); - late final _spine_event_data_get_int_value = - _spine_event_data_get_int_valuePtr - .asFunction(); + late final _spine_event_data_get_int_valuePtr = _lookup>( + 'spine_event_data_get_int_value', + ); + late final _spine_event_data_get_int_value = _spine_event_data_get_int_valuePtr + .asFunction(); - void spine_event_data_set_int_value( - spine_event_data event, - int value, - ) { - return _spine_event_data_set_int_value( - event, - value, - ); + void spine_event_data_set_int_value(spine_event_data event, int value) { + return _spine_event_data_set_int_value(event, value); } - late final _spine_event_data_set_int_valuePtr = _lookup< - ffi.NativeFunction>( - 'spine_event_data_set_int_value'); - late final _spine_event_data_set_int_value = - _spine_event_data_set_int_valuePtr - .asFunction(); + late final _spine_event_data_set_int_valuePtr = + _lookup>('spine_event_data_set_int_value'); + late final _spine_event_data_set_int_value = _spine_event_data_set_int_valuePtr + .asFunction(); - double spine_event_data_get_float_value( - spine_event_data event, - ) { - return _spine_event_data_get_float_value( - event, - ); + double spine_event_data_get_float_value(spine_event_data event) { + return _spine_event_data_get_float_value(event); } - late final _spine_event_data_get_float_valuePtr = - _lookup>( - 'spine_event_data_get_float_value'); - late final _spine_event_data_get_float_value = - _spine_event_data_get_float_valuePtr - .asFunction(); + late final _spine_event_data_get_float_valuePtr = _lookup>( + 'spine_event_data_get_float_value', + ); + late final _spine_event_data_get_float_value = _spine_event_data_get_float_valuePtr + .asFunction(); - void spine_event_data_set_float_value( - spine_event_data event, - double value, - ) { - return _spine_event_data_set_float_value( - event, - value, - ); + void spine_event_data_set_float_value(spine_event_data event, double value) { + return _spine_event_data_set_float_value(event, value); } - late final _spine_event_data_set_float_valuePtr = _lookup< - ffi.NativeFunction>( - 'spine_event_data_set_float_value'); - late final _spine_event_data_set_float_value = - _spine_event_data_set_float_valuePtr - .asFunction(); + late final _spine_event_data_set_float_valuePtr = + _lookup>('spine_event_data_set_float_value'); + late final _spine_event_data_set_float_value = _spine_event_data_set_float_valuePtr + .asFunction(); - ffi.Pointer spine_event_data_get_string_value( - spine_event_data event, - ) { - return _spine_event_data_get_string_value( - event, - ); + ffi.Pointer spine_event_data_get_string_value(spine_event_data event) { + return _spine_event_data_get_string_value(event); } late final _spine_event_data_get_string_valuePtr = - _lookup Function(spine_event_data)>>( - 'spine_event_data_get_string_value'); - late final _spine_event_data_get_string_value = - _spine_event_data_get_string_valuePtr - .asFunction Function(spine_event_data)>(); + _lookup Function(spine_event_data)>>('spine_event_data_get_string_value'); + late final _spine_event_data_get_string_value = _spine_event_data_get_string_valuePtr + .asFunction Function(spine_event_data)>(); - void spine_event_data_set_string_value( - spine_event_data event, - ffi.Pointer value, - ) { - return _spine_event_data_set_string_value( - event, - value, - ); + void spine_event_data_set_string_value(spine_event_data event, ffi.Pointer value) { + return _spine_event_data_set_string_value(event, value); } - late final _spine_event_data_set_string_valuePtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_event_data, - ffi.Pointer)>>('spine_event_data_set_string_value'); - late final _spine_event_data_set_string_value = - _spine_event_data_set_string_valuePtr - .asFunction)>(); + late final _spine_event_data_set_string_valuePtr = + _lookup)>>( + 'spine_event_data_set_string_value', + ); + late final _spine_event_data_set_string_value = _spine_event_data_set_string_valuePtr + .asFunction)>(); - ffi.Pointer spine_event_data_get_audio_path( - spine_event_data event, - ) { - return _spine_event_data_get_audio_path( - event, - ); + ffi.Pointer spine_event_data_get_audio_path(spine_event_data event) { + return _spine_event_data_get_audio_path(event); } late final _spine_event_data_get_audio_pathPtr = - _lookup Function(spine_event_data)>>( - 'spine_event_data_get_audio_path'); - late final _spine_event_data_get_audio_path = - _spine_event_data_get_audio_pathPtr - .asFunction Function(spine_event_data)>(); + _lookup Function(spine_event_data)>>('spine_event_data_get_audio_path'); + late final _spine_event_data_get_audio_path = _spine_event_data_get_audio_pathPtr + .asFunction Function(spine_event_data)>(); /// OMITTED setAudioPath() - double spine_event_data_get_volume( - spine_event_data event, - ) { - return _spine_event_data_get_volume( - event, - ); + double spine_event_data_get_volume(spine_event_data event) { + return _spine_event_data_get_volume(event); } - late final _spine_event_data_get_volumePtr = - _lookup>( - 'spine_event_data_get_volume'); + late final _spine_event_data_get_volumePtr = _lookup>( + 'spine_event_data_get_volume', + ); late final _spine_event_data_get_volume = _spine_event_data_get_volumePtr .asFunction(); - void spine_event_data_set_volume( - spine_event_data event, - double volume, - ) { - return _spine_event_data_set_volume( - event, - volume, - ); + void spine_event_data_set_volume(spine_event_data event, double volume) { + return _spine_event_data_set_volume(event, volume); } - late final _spine_event_data_set_volumePtr = _lookup< - ffi.NativeFunction>( - 'spine_event_data_set_volume'); + late final _spine_event_data_set_volumePtr = + _lookup>('spine_event_data_set_volume'); late final _spine_event_data_set_volume = _spine_event_data_set_volumePtr .asFunction(); - double spine_event_data_get_balance( - spine_event_data event, - ) { - return _spine_event_data_get_balance( - event, - ); + double spine_event_data_get_balance(spine_event_data event) { + return _spine_event_data_get_balance(event); } - late final _spine_event_data_get_balancePtr = - _lookup>( - 'spine_event_data_get_balance'); + late final _spine_event_data_get_balancePtr = _lookup>( + 'spine_event_data_get_balance', + ); late final _spine_event_data_get_balance = _spine_event_data_get_balancePtr .asFunction(); - void spine_event_data_set_balance( - spine_event_data event, - double balance, - ) { - return _spine_event_data_set_balance( - event, - balance, - ); + void spine_event_data_set_balance(spine_event_data event, double balance) { + return _spine_event_data_set_balance(event, balance); } - late final _spine_event_data_set_balancePtr = _lookup< - ffi.NativeFunction>( - 'spine_event_data_set_balance'); + late final _spine_event_data_set_balancePtr = + _lookup>('spine_event_data_set_balance'); late final _spine_event_data_set_balance = _spine_event_data_set_balancePtr .asFunction(); - spine_event_data spine_event_get_data( - spine_event event, - ) { - return _spine_event_get_data( - event, - ); + spine_event_data spine_event_get_data(spine_event event) { + return _spine_event_get_data(event); } - late final _spine_event_get_dataPtr = - _lookup>( - 'spine_event_get_data'); - late final _spine_event_get_data = _spine_event_get_dataPtr - .asFunction(); + late final _spine_event_get_dataPtr = _lookup>( + 'spine_event_get_data', + ); + late final _spine_event_get_data = _spine_event_get_dataPtr.asFunction(); - double spine_event_get_time( - spine_event event, - ) { - return _spine_event_get_time( - event, - ); + double spine_event_get_time(spine_event event) { + return _spine_event_get_time(event); } - late final _spine_event_get_timePtr = - _lookup>( - 'spine_event_get_time'); - late final _spine_event_get_time = - _spine_event_get_timePtr.asFunction(); + late final _spine_event_get_timePtr = _lookup>( + 'spine_event_get_time', + ); + late final _spine_event_get_time = _spine_event_get_timePtr.asFunction(); - int spine_event_get_int_value( - spine_event event, - ) { - return _spine_event_get_int_value( - event, - ); + int spine_event_get_int_value(spine_event event) { + return _spine_event_get_int_value(event); } - late final _spine_event_get_int_valuePtr = - _lookup>( - 'spine_event_get_int_value'); - late final _spine_event_get_int_value = - _spine_event_get_int_valuePtr.asFunction(); + late final _spine_event_get_int_valuePtr = _lookup>( + 'spine_event_get_int_value', + ); + late final _spine_event_get_int_value = _spine_event_get_int_valuePtr.asFunction(); - void spine_event_set_int_value( - spine_event event, - int value, - ) { - return _spine_event_set_int_value( - event, - value, - ); + void spine_event_set_int_value(spine_event event, int value) { + return _spine_event_set_int_value(event, value); } - late final _spine_event_set_int_valuePtr = - _lookup>( - 'spine_event_set_int_value'); - late final _spine_event_set_int_value = _spine_event_set_int_valuePtr - .asFunction(); + late final _spine_event_set_int_valuePtr = _lookup>( + 'spine_event_set_int_value', + ); + late final _spine_event_set_int_value = _spine_event_set_int_valuePtr.asFunction(); - double spine_event_get_float_value( - spine_event event, - ) { - return _spine_event_get_float_value( - event, - ); + double spine_event_get_float_value(spine_event event) { + return _spine_event_get_float_value(event); } - late final _spine_event_get_float_valuePtr = - _lookup>( - 'spine_event_get_float_value'); - late final _spine_event_get_float_value = _spine_event_get_float_valuePtr - .asFunction(); + late final _spine_event_get_float_valuePtr = _lookup>( + 'spine_event_get_float_value', + ); + late final _spine_event_get_float_value = _spine_event_get_float_valuePtr.asFunction(); - void spine_event_set_float_value( - spine_event event, - double value, - ) { - return _spine_event_set_float_value( - event, - value, - ); + void spine_event_set_float_value(spine_event event, double value) { + return _spine_event_set_float_value(event, value); } - late final _spine_event_set_float_valuePtr = - _lookup>( - 'spine_event_set_float_value'); + late final _spine_event_set_float_valuePtr = _lookup>( + 'spine_event_set_float_value', + ); late final _spine_event_set_float_value = _spine_event_set_float_valuePtr .asFunction(); - ffi.Pointer spine_event_get_string_value( - spine_event event, - ) { - return _spine_event_get_string_value( - event, - ); + ffi.Pointer spine_event_get_string_value(spine_event event) { + return _spine_event_get_string_value(event); } - late final _spine_event_get_string_valuePtr = - _lookup Function(spine_event)>>( - 'spine_event_get_string_value'); + late final _spine_event_get_string_valuePtr = _lookup Function(spine_event)>>( + 'spine_event_get_string_value', + ); late final _spine_event_get_string_value = _spine_event_get_string_valuePtr .asFunction Function(spine_event)>(); - void spine_event_set_string_value( - spine_event event, - ffi.Pointer value, - ) { - return _spine_event_set_string_value( - event, - value, - ); + void spine_event_set_string_value(spine_event event, ffi.Pointer value) { + return _spine_event_set_string_value(event, value); } - late final _spine_event_set_string_valuePtr = _lookup< - ffi - .NativeFunction)>>( - 'spine_event_set_string_value'); + late final _spine_event_set_string_valuePtr = + _lookup)>>('spine_event_set_string_value'); late final _spine_event_set_string_value = _spine_event_set_string_valuePtr .asFunction)>(); - double spine_event_get_volume( - spine_event event, - ) { - return _spine_event_get_volume( - event, - ); + double spine_event_get_volume(spine_event event) { + return _spine_event_get_volume(event); } - late final _spine_event_get_volumePtr = - _lookup>( - 'spine_event_get_volume'); - late final _spine_event_get_volume = - _spine_event_get_volumePtr.asFunction(); + late final _spine_event_get_volumePtr = _lookup>( + 'spine_event_get_volume', + ); + late final _spine_event_get_volume = _spine_event_get_volumePtr.asFunction(); - void spine_event_set_volume( - spine_event event, - double volume, - ) { - return _spine_event_set_volume( - event, - volume, - ); + void spine_event_set_volume(spine_event event, double volume) { + return _spine_event_set_volume(event, volume); } - late final _spine_event_set_volumePtr = - _lookup>( - 'spine_event_set_volume'); - late final _spine_event_set_volume = _spine_event_set_volumePtr - .asFunction(); + late final _spine_event_set_volumePtr = _lookup>( + 'spine_event_set_volume', + ); + late final _spine_event_set_volume = _spine_event_set_volumePtr.asFunction(); - double spine_event_get_balance( - spine_event event, - ) { - return _spine_event_get_balance( - event, - ); + double spine_event_get_balance(spine_event event) { + return _spine_event_get_balance(event); } - late final _spine_event_get_balancePtr = - _lookup>( - 'spine_event_get_balance'); - late final _spine_event_get_balance = - _spine_event_get_balancePtr.asFunction(); + late final _spine_event_get_balancePtr = _lookup>( + 'spine_event_get_balance', + ); + late final _spine_event_get_balance = _spine_event_get_balancePtr.asFunction(); - void spine_event_set_balance( - spine_event event, - double balance, - ) { - return _spine_event_set_balance( - event, - balance, - ); + void spine_event_set_balance(spine_event event, double balance) { + return _spine_event_set_balance(event, balance); } - late final _spine_event_set_balancePtr = - _lookup>( - 'spine_event_set_balance'); - late final _spine_event_set_balance = _spine_event_set_balancePtr - .asFunction(); + late final _spine_event_set_balancePtr = _lookup>( + 'spine_event_set_balance', + ); + late final _spine_event_set_balance = _spine_event_set_balancePtr.asFunction(); - int spine_slot_data_get_index( - spine_slot_data slot, - ) { - return _spine_slot_data_get_index( - slot, - ); + int spine_slot_data_get_index(spine_slot_data slot) { + return _spine_slot_data_get_index(slot); } - late final _spine_slot_data_get_indexPtr = - _lookup>( - 'spine_slot_data_get_index'); - late final _spine_slot_data_get_index = - _spine_slot_data_get_indexPtr.asFunction(); + late final _spine_slot_data_get_indexPtr = _lookup>( + 'spine_slot_data_get_index', + ); + late final _spine_slot_data_get_index = _spine_slot_data_get_indexPtr.asFunction(); - ffi.Pointer spine_slot_data_get_name( - spine_slot_data slot, - ) { - return _spine_slot_data_get_name( - slot, - ); + ffi.Pointer spine_slot_data_get_name(spine_slot_data slot) { + return _spine_slot_data_get_name(slot); } - late final _spine_slot_data_get_namePtr = - _lookup Function(spine_slot_data)>>( - 'spine_slot_data_get_name'); + late final _spine_slot_data_get_namePtr = _lookup Function(spine_slot_data)>>( + 'spine_slot_data_get_name', + ); late final _spine_slot_data_get_name = _spine_slot_data_get_namePtr .asFunction Function(spine_slot_data)>(); - spine_bone_data spine_slot_data_get_bone_data( - spine_slot_data slot, - ) { - return _spine_slot_data_get_bone_data( - slot, - ); + spine_bone_data spine_slot_data_get_bone_data(spine_slot_data slot) { + return _spine_slot_data_get_bone_data(slot); } - late final _spine_slot_data_get_bone_dataPtr = - _lookup>( - 'spine_slot_data_get_bone_data'); + late final _spine_slot_data_get_bone_dataPtr = _lookup>( + 'spine_slot_data_get_bone_data', + ); late final _spine_slot_data_get_bone_data = _spine_slot_data_get_bone_dataPtr .asFunction(); - spine_color spine_slot_data_get_color( - spine_slot_data slot, - ) { - return _spine_slot_data_get_color( - slot, - ); + spine_color spine_slot_data_get_color(spine_slot_data slot) { + return _spine_slot_data_get_color(slot); } - late final _spine_slot_data_get_colorPtr = - _lookup>( - 'spine_slot_data_get_color'); + late final _spine_slot_data_get_colorPtr = _lookup>( + 'spine_slot_data_get_color', + ); late final _spine_slot_data_get_color = _spine_slot_data_get_colorPtr .asFunction(); - void spine_slot_data_set_color( - spine_slot_data slot, - double r, - double g, - double b, - double a, - ) { - return _spine_slot_data_set_color( - slot, - r, - g, - b, - a, - ); + void spine_slot_data_set_color(spine_slot_data slot, double r, double g, double b, double a) { + return _spine_slot_data_set_color(slot, r, g, b, a); } - late final _spine_slot_data_set_colorPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_slot_data, ffi.Float, ffi.Float, ffi.Float, - ffi.Float)>>('spine_slot_data_set_color'); - late final _spine_slot_data_set_color = - _spine_slot_data_set_colorPtr.asFunction< - void Function(spine_slot_data, double, double, double, double)>(); + late final _spine_slot_data_set_colorPtr = + _lookup>( + 'spine_slot_data_set_color', + ); + late final _spine_slot_data_set_color = _spine_slot_data_set_colorPtr + .asFunction(); - spine_color spine_slot_data_get_dark_color( - spine_slot_data slot, - ) { - return _spine_slot_data_get_dark_color( - slot, - ); + spine_color spine_slot_data_get_dark_color(spine_slot_data slot) { + return _spine_slot_data_get_dark_color(slot); } - late final _spine_slot_data_get_dark_colorPtr = - _lookup>( - 'spine_slot_data_get_dark_color'); - late final _spine_slot_data_get_dark_color = - _spine_slot_data_get_dark_colorPtr - .asFunction(); + late final _spine_slot_data_get_dark_colorPtr = _lookup>( + 'spine_slot_data_get_dark_color', + ); + late final _spine_slot_data_get_dark_color = _spine_slot_data_get_dark_colorPtr + .asFunction(); - void spine_slot_data_set_dark_color( - spine_slot_data slot, - double r, - double g, - double b, - double a, - ) { - return _spine_slot_data_set_dark_color( - slot, - r, - g, - b, - a, - ); + void spine_slot_data_set_dark_color(spine_slot_data slot, double r, double g, double b, double a) { + return _spine_slot_data_set_dark_color(slot, r, g, b, a); } - late final _spine_slot_data_set_dark_colorPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_slot_data, ffi.Float, ffi.Float, ffi.Float, - ffi.Float)>>('spine_slot_data_set_dark_color'); - late final _spine_slot_data_set_dark_color = - _spine_slot_data_set_dark_colorPtr.asFunction< - void Function(spine_slot_data, double, double, double, double)>(); + late final _spine_slot_data_set_dark_colorPtr = + _lookup>( + 'spine_slot_data_set_dark_color', + ); + late final _spine_slot_data_set_dark_color = _spine_slot_data_set_dark_colorPtr + .asFunction(); - int spine_slot_data_has_dark_color( - spine_slot_data slot, - ) { - return _spine_slot_data_has_dark_color( - slot, - ); + int spine_slot_data_has_dark_color(spine_slot_data slot) { + return _spine_slot_data_has_dark_color(slot); } - late final _spine_slot_data_has_dark_colorPtr = - _lookup>( - 'spine_slot_data_has_dark_color'); - late final _spine_slot_data_has_dark_color = - _spine_slot_data_has_dark_colorPtr - .asFunction(); + late final _spine_slot_data_has_dark_colorPtr = _lookup>( + 'spine_slot_data_has_dark_color', + ); + late final _spine_slot_data_has_dark_color = _spine_slot_data_has_dark_colorPtr + .asFunction(); - void spine_slot_data_set_has_dark_color( - spine_slot_data slot, - int hasDarkColor, - ) { - return _spine_slot_data_set_has_dark_color( - slot, - hasDarkColor, - ); + void spine_slot_data_set_has_dark_color(spine_slot_data slot, int hasDarkColor) { + return _spine_slot_data_set_has_dark_color(slot, hasDarkColor); } - late final _spine_slot_data_set_has_dark_colorPtr = _lookup< - ffi.NativeFunction>( - 'spine_slot_data_set_has_dark_color'); - late final _spine_slot_data_set_has_dark_color = - _spine_slot_data_set_has_dark_colorPtr - .asFunction(); + late final _spine_slot_data_set_has_dark_colorPtr = + _lookup>('spine_slot_data_set_has_dark_color'); + late final _spine_slot_data_set_has_dark_color = _spine_slot_data_set_has_dark_colorPtr + .asFunction(); - ffi.Pointer spine_slot_data_get_attachment_name( - spine_slot_data slot, - ) { - return _spine_slot_data_get_attachment_name( - slot, - ); + ffi.Pointer spine_slot_data_get_attachment_name(spine_slot_data slot) { + return _spine_slot_data_get_attachment_name(slot); } late final _spine_slot_data_get_attachment_namePtr = - _lookup Function(spine_slot_data)>>( - 'spine_slot_data_get_attachment_name'); - late final _spine_slot_data_get_attachment_name = - _spine_slot_data_get_attachment_namePtr - .asFunction Function(spine_slot_data)>(); + _lookup Function(spine_slot_data)>>('spine_slot_data_get_attachment_name'); + late final _spine_slot_data_get_attachment_name = _spine_slot_data_get_attachment_namePtr + .asFunction Function(spine_slot_data)>(); - void spine_slot_data_set_attachment_name( - spine_slot_data slot, - ffi.Pointer attachmentName, - ) { - return _spine_slot_data_set_attachment_name( - slot, - attachmentName, - ); + void spine_slot_data_set_attachment_name(spine_slot_data slot, ffi.Pointer attachmentName) { + return _spine_slot_data_set_attachment_name(slot, attachmentName); } - late final _spine_slot_data_set_attachment_namePtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_slot_data, - ffi.Pointer)>>('spine_slot_data_set_attachment_name'); - late final _spine_slot_data_set_attachment_name = - _spine_slot_data_set_attachment_namePtr - .asFunction)>(); + late final _spine_slot_data_set_attachment_namePtr = + _lookup)>>( + 'spine_slot_data_set_attachment_name', + ); + late final _spine_slot_data_set_attachment_name = _spine_slot_data_set_attachment_namePtr + .asFunction)>(); - int spine_slot_data_get_blend_mode( - spine_slot_data slot, - ) { - return _spine_slot_data_get_blend_mode( - slot, - ); + int spine_slot_data_get_blend_mode(spine_slot_data slot) { + return _spine_slot_data_get_blend_mode(slot); } - late final _spine_slot_data_get_blend_modePtr = - _lookup>( - 'spine_slot_data_get_blend_mode'); - late final _spine_slot_data_get_blend_mode = - _spine_slot_data_get_blend_modePtr - .asFunction(); - - void spine_slot_data_set_blend_mode( - spine_slot_data slot, - int blendMode, - ) { - return _spine_slot_data_set_blend_mode( - slot, - blendMode, - ); - } - - late final _spine_slot_data_set_blend_modePtr = _lookup< - ffi.NativeFunction>( - 'spine_slot_data_set_blend_mode'); - late final _spine_slot_data_set_blend_mode = - _spine_slot_data_set_blend_modePtr - .asFunction(); - - int spine_slot_data_is_visible( - spine_slot_data slot, - ) { - return _spine_slot_data_is_visible( - slot, - ); - } - - late final _spine_slot_data_is_visiblePtr = - _lookup>( - 'spine_slot_data_is_visible'); - late final _spine_slot_data_is_visible = _spine_slot_data_is_visiblePtr + late final _spine_slot_data_get_blend_modePtr = _lookup>( + 'spine_slot_data_get_blend_mode', + ); + late final _spine_slot_data_get_blend_mode = _spine_slot_data_get_blend_modePtr .asFunction(); - void spine_slot_data_set_visible( - spine_slot_data slot, - int visible, - ) { - return _spine_slot_data_set_visible( - slot, - visible, - ); + void spine_slot_data_set_blend_mode(spine_slot_data slot, int blendMode) { + return _spine_slot_data_set_blend_mode(slot, blendMode); } - late final _spine_slot_data_set_visiblePtr = _lookup< - ffi.NativeFunction>( - 'spine_slot_data_set_visible'); + late final _spine_slot_data_set_blend_modePtr = + _lookup>('spine_slot_data_set_blend_mode'); + late final _spine_slot_data_set_blend_mode = _spine_slot_data_set_blend_modePtr + .asFunction(); + + int spine_slot_data_is_visible(spine_slot_data slot) { + return _spine_slot_data_is_visible(slot); + } + + late final _spine_slot_data_is_visiblePtr = _lookup>( + 'spine_slot_data_is_visible', + ); + late final _spine_slot_data_is_visible = _spine_slot_data_is_visiblePtr.asFunction(); + + void spine_slot_data_set_visible(spine_slot_data slot, int visible) { + return _spine_slot_data_set_visible(slot, visible); + } + + late final _spine_slot_data_set_visiblePtr = + _lookup>('spine_slot_data_set_visible'); late final _spine_slot_data_set_visible = _spine_slot_data_set_visiblePtr .asFunction(); /// OMITTED getPath()/setPath() - void spine_slot_set_to_setup_pose( - spine_slot slot, - ) { - return _spine_slot_set_to_setup_pose( - slot, - ); + void spine_slot_set_to_setup_pose(spine_slot slot) { + return _spine_slot_set_to_setup_pose(slot); } - late final _spine_slot_set_to_setup_posePtr = - _lookup>( - 'spine_slot_set_to_setup_pose'); - late final _spine_slot_set_to_setup_pose = - _spine_slot_set_to_setup_posePtr.asFunction(); + late final _spine_slot_set_to_setup_posePtr = _lookup>( + 'spine_slot_set_to_setup_pose', + ); + late final _spine_slot_set_to_setup_pose = _spine_slot_set_to_setup_posePtr.asFunction(); - spine_slot_data spine_slot_get_data( - spine_slot slot, - ) { - return _spine_slot_get_data( - slot, - ); + spine_slot_data spine_slot_get_data(spine_slot slot) { + return _spine_slot_get_data(slot); } - late final _spine_slot_get_dataPtr = - _lookup>( - 'spine_slot_get_data'); - late final _spine_slot_get_data = _spine_slot_get_dataPtr - .asFunction(); + late final _spine_slot_get_dataPtr = _lookup>( + 'spine_slot_get_data', + ); + late final _spine_slot_get_data = _spine_slot_get_dataPtr.asFunction(); - spine_bone spine_slot_get_bone( - spine_slot slot, - ) { - return _spine_slot_get_bone( - slot, - ); + spine_bone spine_slot_get_bone(spine_slot slot) { + return _spine_slot_get_bone(slot); } - late final _spine_slot_get_bonePtr = - _lookup>( - 'spine_slot_get_bone'); - late final _spine_slot_get_bone = - _spine_slot_get_bonePtr.asFunction(); + late final _spine_slot_get_bonePtr = _lookup>( + 'spine_slot_get_bone', + ); + late final _spine_slot_get_bone = _spine_slot_get_bonePtr.asFunction(); - spine_skeleton spine_slot_get_skeleton( - spine_slot slot, - ) { - return _spine_slot_get_skeleton( - slot, - ); + spine_skeleton spine_slot_get_skeleton(spine_slot slot) { + return _spine_slot_get_skeleton(slot); } - late final _spine_slot_get_skeletonPtr = - _lookup>( - 'spine_slot_get_skeleton'); - late final _spine_slot_get_skeleton = _spine_slot_get_skeletonPtr - .asFunction(); + late final _spine_slot_get_skeletonPtr = _lookup>( + 'spine_slot_get_skeleton', + ); + late final _spine_slot_get_skeleton = _spine_slot_get_skeletonPtr.asFunction(); - spine_color spine_slot_get_color( - spine_slot slot, - ) { - return _spine_slot_get_color( - slot, - ); + spine_color spine_slot_get_color(spine_slot slot) { + return _spine_slot_get_color(slot); } - late final _spine_slot_get_colorPtr = - _lookup>( - 'spine_slot_get_color'); - late final _spine_slot_get_color = - _spine_slot_get_colorPtr.asFunction(); + late final _spine_slot_get_colorPtr = _lookup>( + 'spine_slot_get_color', + ); + late final _spine_slot_get_color = _spine_slot_get_colorPtr.asFunction(); - void spine_slot_set_color( - spine_slot slot, - double r, - double g, - double b, - double a, - ) { - return _spine_slot_set_color( - slot, - r, - g, - b, - a, - ); + void spine_slot_set_color(spine_slot slot, double r, double g, double b, double a) { + return _spine_slot_set_color(slot, r, g, b, a); } - late final _spine_slot_set_colorPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_slot, ffi.Float, ffi.Float, ffi.Float, - ffi.Float)>>('spine_slot_set_color'); + late final _spine_slot_set_colorPtr = + _lookup>( + 'spine_slot_set_color', + ); late final _spine_slot_set_color = _spine_slot_set_colorPtr .asFunction(); - spine_color spine_slot_get_dark_color( - spine_slot slot, - ) { - return _spine_slot_get_dark_color( - slot, - ); + spine_color spine_slot_get_dark_color(spine_slot slot) { + return _spine_slot_get_dark_color(slot); } - late final _spine_slot_get_dark_colorPtr = - _lookup>( - 'spine_slot_get_dark_color'); - late final _spine_slot_get_dark_color = _spine_slot_get_dark_colorPtr - .asFunction(); + late final _spine_slot_get_dark_colorPtr = _lookup>( + 'spine_slot_get_dark_color', + ); + late final _spine_slot_get_dark_color = _spine_slot_get_dark_colorPtr.asFunction(); - void spine_slot_set_dark_color( - spine_slot slot, - double r, - double g, - double b, - double a, - ) { - return _spine_slot_set_dark_color( - slot, - r, - g, - b, - a, - ); + void spine_slot_set_dark_color(spine_slot slot, double r, double g, double b, double a) { + return _spine_slot_set_dark_color(slot, r, g, b, a); } - late final _spine_slot_set_dark_colorPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_slot, ffi.Float, ffi.Float, ffi.Float, - ffi.Float)>>('spine_slot_set_dark_color'); + late final _spine_slot_set_dark_colorPtr = + _lookup>( + 'spine_slot_set_dark_color', + ); late final _spine_slot_set_dark_color = _spine_slot_set_dark_colorPtr .asFunction(); - int spine_slot_has_dark_color( - spine_slot slot, - ) { - return _spine_slot_has_dark_color( - slot, - ); + int spine_slot_has_dark_color(spine_slot slot) { + return _spine_slot_has_dark_color(slot); } - late final _spine_slot_has_dark_colorPtr = - _lookup>( - 'spine_slot_has_dark_color'); - late final _spine_slot_has_dark_color = - _spine_slot_has_dark_colorPtr.asFunction(); + late final _spine_slot_has_dark_colorPtr = _lookup>( + 'spine_slot_has_dark_color', + ); + late final _spine_slot_has_dark_color = _spine_slot_has_dark_colorPtr.asFunction(); - spine_attachment spine_slot_get_attachment( - spine_slot slot, - ) { - return _spine_slot_get_attachment( - slot, - ); + spine_attachment spine_slot_get_attachment(spine_slot slot) { + return _spine_slot_get_attachment(slot); } - late final _spine_slot_get_attachmentPtr = - _lookup>( - 'spine_slot_get_attachment'); + late final _spine_slot_get_attachmentPtr = _lookup>( + 'spine_slot_get_attachment', + ); late final _spine_slot_get_attachment = _spine_slot_get_attachmentPtr .asFunction(); - void spine_slot_set_attachment( - spine_slot slot, - spine_attachment attachment, - ) { - return _spine_slot_set_attachment( - slot, - attachment, - ); + void spine_slot_set_attachment(spine_slot slot, spine_attachment attachment) { + return _spine_slot_set_attachment(slot, attachment); } - late final _spine_slot_set_attachmentPtr = _lookup< - ffi.NativeFunction>( - 'spine_slot_set_attachment'); + late final _spine_slot_set_attachmentPtr = + _lookup>('spine_slot_set_attachment'); late final _spine_slot_set_attachment = _spine_slot_set_attachmentPtr .asFunction(); /// OMITTED getDeform() - int spine_slot_get_sequence_index( - spine_slot slot, - ) { - return _spine_slot_get_sequence_index( - slot, - ); + int spine_slot_get_sequence_index(spine_slot slot) { + return _spine_slot_get_sequence_index(slot); } - late final _spine_slot_get_sequence_indexPtr = - _lookup>( - 'spine_slot_get_sequence_index'); - late final _spine_slot_get_sequence_index = - _spine_slot_get_sequence_indexPtr.asFunction(); + late final _spine_slot_get_sequence_indexPtr = _lookup>( + 'spine_slot_get_sequence_index', + ); + late final _spine_slot_get_sequence_index = _spine_slot_get_sequence_indexPtr.asFunction(); - void spine_slot_set_sequence_index( - spine_slot slot, - int sequenceIndex, - ) { - return _spine_slot_set_sequence_index( - slot, - sequenceIndex, - ); + void spine_slot_set_sequence_index(spine_slot slot, int sequenceIndex) { + return _spine_slot_set_sequence_index(slot, sequenceIndex); } - late final _spine_slot_set_sequence_indexPtr = - _lookup>( - 'spine_slot_set_sequence_index'); + late final _spine_slot_set_sequence_indexPtr = _lookup>( + 'spine_slot_set_sequence_index', + ); late final _spine_slot_set_sequence_index = _spine_slot_set_sequence_indexPtr .asFunction(); - int spine_bone_data_get_index( - spine_bone_data data, - ) { - return _spine_bone_data_get_index( - data, - ); + int spine_bone_data_get_index(spine_bone_data data) { + return _spine_bone_data_get_index(data); } - late final _spine_bone_data_get_indexPtr = - _lookup>( - 'spine_bone_data_get_index'); - late final _spine_bone_data_get_index = - _spine_bone_data_get_indexPtr.asFunction(); + late final _spine_bone_data_get_indexPtr = _lookup>( + 'spine_bone_data_get_index', + ); + late final _spine_bone_data_get_index = _spine_bone_data_get_indexPtr.asFunction(); - ffi.Pointer spine_bone_data_get_name( - spine_bone_data data, - ) { - return _spine_bone_data_get_name( - data, - ); + ffi.Pointer spine_bone_data_get_name(spine_bone_data data) { + return _spine_bone_data_get_name(data); } - late final _spine_bone_data_get_namePtr = - _lookup Function(spine_bone_data)>>( - 'spine_bone_data_get_name'); + late final _spine_bone_data_get_namePtr = _lookup Function(spine_bone_data)>>( + 'spine_bone_data_get_name', + ); late final _spine_bone_data_get_name = _spine_bone_data_get_namePtr .asFunction Function(spine_bone_data)>(); - spine_bone_data spine_bone_data_get_parent( - spine_bone_data data, - ) { - return _spine_bone_data_get_parent( - data, - ); + spine_bone_data spine_bone_data_get_parent(spine_bone_data data) { + return _spine_bone_data_get_parent(data); } - late final _spine_bone_data_get_parentPtr = - _lookup>( - 'spine_bone_data_get_parent'); + late final _spine_bone_data_get_parentPtr = _lookup>( + 'spine_bone_data_get_parent', + ); late final _spine_bone_data_get_parent = _spine_bone_data_get_parentPtr .asFunction(); - double spine_bone_data_get_length( - spine_bone_data data, - ) { - return _spine_bone_data_get_length( - data, - ); + double spine_bone_data_get_length(spine_bone_data data) { + return _spine_bone_data_get_length(data); } - late final _spine_bone_data_get_lengthPtr = - _lookup>( - 'spine_bone_data_get_length'); + late final _spine_bone_data_get_lengthPtr = _lookup>( + 'spine_bone_data_get_length', + ); late final _spine_bone_data_get_length = _spine_bone_data_get_lengthPtr .asFunction(); - void spine_bone_data_set_length( - spine_bone_data data, - double length, - ) { - return _spine_bone_data_set_length( - data, - length, - ); + void spine_bone_data_set_length(spine_bone_data data, double length) { + return _spine_bone_data_set_length(data, length); } - late final _spine_bone_data_set_lengthPtr = _lookup< - ffi.NativeFunction>( - 'spine_bone_data_set_length'); + late final _spine_bone_data_set_lengthPtr = + _lookup>('spine_bone_data_set_length'); late final _spine_bone_data_set_length = _spine_bone_data_set_lengthPtr .asFunction(); - double spine_bone_data_get_x( - spine_bone_data data, - ) { - return _spine_bone_data_get_x( - data, - ); + double spine_bone_data_get_x(spine_bone_data data) { + return _spine_bone_data_get_x(data); } - late final _spine_bone_data_get_xPtr = - _lookup>( - 'spine_bone_data_get_x'); - late final _spine_bone_data_get_x = - _spine_bone_data_get_xPtr.asFunction(); + late final _spine_bone_data_get_xPtr = _lookup>( + 'spine_bone_data_get_x', + ); + late final _spine_bone_data_get_x = _spine_bone_data_get_xPtr.asFunction(); - void spine_bone_data_set_x( - spine_bone_data data, - double x, - ) { - return _spine_bone_data_set_x( - data, - x, - ); + void spine_bone_data_set_x(spine_bone_data data, double x) { + return _spine_bone_data_set_x(data, x); } - late final _spine_bone_data_set_xPtr = _lookup< - ffi.NativeFunction>( - 'spine_bone_data_set_x'); - late final _spine_bone_data_set_x = _spine_bone_data_set_xPtr - .asFunction(); + late final _spine_bone_data_set_xPtr = _lookup>( + 'spine_bone_data_set_x', + ); + late final _spine_bone_data_set_x = _spine_bone_data_set_xPtr.asFunction(); - double spine_bone_data_get_y( - spine_bone_data data, - ) { - return _spine_bone_data_get_y( - data, - ); + double spine_bone_data_get_y(spine_bone_data data) { + return _spine_bone_data_get_y(data); } - late final _spine_bone_data_get_yPtr = - _lookup>( - 'spine_bone_data_get_y'); - late final _spine_bone_data_get_y = - _spine_bone_data_get_yPtr.asFunction(); + late final _spine_bone_data_get_yPtr = _lookup>( + 'spine_bone_data_get_y', + ); + late final _spine_bone_data_get_y = _spine_bone_data_get_yPtr.asFunction(); - void spine_bone_data_set_y( - spine_bone_data data, - double y, - ) { - return _spine_bone_data_set_y( - data, - y, - ); + void spine_bone_data_set_y(spine_bone_data data, double y) { + return _spine_bone_data_set_y(data, y); } - late final _spine_bone_data_set_yPtr = _lookup< - ffi.NativeFunction>( - 'spine_bone_data_set_y'); - late final _spine_bone_data_set_y = _spine_bone_data_set_yPtr - .asFunction(); + late final _spine_bone_data_set_yPtr = _lookup>( + 'spine_bone_data_set_y', + ); + late final _spine_bone_data_set_y = _spine_bone_data_set_yPtr.asFunction(); - double spine_bone_data_get_rotation( - spine_bone_data data, - ) { - return _spine_bone_data_get_rotation( - data, - ); + double spine_bone_data_get_rotation(spine_bone_data data) { + return _spine_bone_data_get_rotation(data); } - late final _spine_bone_data_get_rotationPtr = - _lookup>( - 'spine_bone_data_get_rotation'); + late final _spine_bone_data_get_rotationPtr = _lookup>( + 'spine_bone_data_get_rotation', + ); late final _spine_bone_data_get_rotation = _spine_bone_data_get_rotationPtr .asFunction(); - void spine_bone_data_set_rotation( - spine_bone_data data, - double rotation, - ) { - return _spine_bone_data_set_rotation( - data, - rotation, - ); + void spine_bone_data_set_rotation(spine_bone_data data, double rotation) { + return _spine_bone_data_set_rotation(data, rotation); } - late final _spine_bone_data_set_rotationPtr = _lookup< - ffi.NativeFunction>( - 'spine_bone_data_set_rotation'); + late final _spine_bone_data_set_rotationPtr = + _lookup>('spine_bone_data_set_rotation'); late final _spine_bone_data_set_rotation = _spine_bone_data_set_rotationPtr .asFunction(); - double spine_bone_data_get_scale_x( - spine_bone_data data, - ) { - return _spine_bone_data_get_scale_x( - data, - ); + double spine_bone_data_get_scale_x(spine_bone_data data) { + return _spine_bone_data_get_scale_x(data); } - late final _spine_bone_data_get_scale_xPtr = - _lookup>( - 'spine_bone_data_get_scale_x'); + late final _spine_bone_data_get_scale_xPtr = _lookup>( + 'spine_bone_data_get_scale_x', + ); late final _spine_bone_data_get_scale_x = _spine_bone_data_get_scale_xPtr .asFunction(); - void spine_bone_data_set_scale_x( - spine_bone_data data, - double scaleX, - ) { - return _spine_bone_data_set_scale_x( - data, - scaleX, - ); + void spine_bone_data_set_scale_x(spine_bone_data data, double scaleX) { + return _spine_bone_data_set_scale_x(data, scaleX); } - late final _spine_bone_data_set_scale_xPtr = _lookup< - ffi.NativeFunction>( - 'spine_bone_data_set_scale_x'); + late final _spine_bone_data_set_scale_xPtr = + _lookup>('spine_bone_data_set_scale_x'); late final _spine_bone_data_set_scale_x = _spine_bone_data_set_scale_xPtr .asFunction(); - double spine_bone_data_get_scale_y( - spine_bone_data data, - ) { - return _spine_bone_data_get_scale_y( - data, - ); + double spine_bone_data_get_scale_y(spine_bone_data data) { + return _spine_bone_data_get_scale_y(data); } - late final _spine_bone_data_get_scale_yPtr = - _lookup>( - 'spine_bone_data_get_scale_y'); + late final _spine_bone_data_get_scale_yPtr = _lookup>( + 'spine_bone_data_get_scale_y', + ); late final _spine_bone_data_get_scale_y = _spine_bone_data_get_scale_yPtr .asFunction(); - void spine_bone_data_set_scale_y( - spine_bone_data data, - double scaleY, - ) { - return _spine_bone_data_set_scale_y( - data, - scaleY, - ); + void spine_bone_data_set_scale_y(spine_bone_data data, double scaleY) { + return _spine_bone_data_set_scale_y(data, scaleY); } - late final _spine_bone_data_set_scale_yPtr = _lookup< - ffi.NativeFunction>( - 'spine_bone_data_set_scale_y'); + late final _spine_bone_data_set_scale_yPtr = + _lookup>('spine_bone_data_set_scale_y'); late final _spine_bone_data_set_scale_y = _spine_bone_data_set_scale_yPtr .asFunction(); - double spine_bone_data_get_shear_x( - spine_bone_data data, - ) { - return _spine_bone_data_get_shear_x( - data, - ); + double spine_bone_data_get_shear_x(spine_bone_data data) { + return _spine_bone_data_get_shear_x(data); } - late final _spine_bone_data_get_shear_xPtr = - _lookup>( - 'spine_bone_data_get_shear_x'); + late final _spine_bone_data_get_shear_xPtr = _lookup>( + 'spine_bone_data_get_shear_x', + ); late final _spine_bone_data_get_shear_x = _spine_bone_data_get_shear_xPtr .asFunction(); - void spine_bone_data_set_shear_x( - spine_bone_data data, - double shearx, - ) { - return _spine_bone_data_set_shear_x( - data, - shearx, - ); + void spine_bone_data_set_shear_x(spine_bone_data data, double shearx) { + return _spine_bone_data_set_shear_x(data, shearx); } - late final _spine_bone_data_set_shear_xPtr = _lookup< - ffi.NativeFunction>( - 'spine_bone_data_set_shear_x'); + late final _spine_bone_data_set_shear_xPtr = + _lookup>('spine_bone_data_set_shear_x'); late final _spine_bone_data_set_shear_x = _spine_bone_data_set_shear_xPtr .asFunction(); - double spine_bone_data_get_shear_y( - spine_bone_data data, - ) { - return _spine_bone_data_get_shear_y( - data, - ); + double spine_bone_data_get_shear_y(spine_bone_data data) { + return _spine_bone_data_get_shear_y(data); } - late final _spine_bone_data_get_shear_yPtr = - _lookup>( - 'spine_bone_data_get_shear_y'); + late final _spine_bone_data_get_shear_yPtr = _lookup>( + 'spine_bone_data_get_shear_y', + ); late final _spine_bone_data_get_shear_y = _spine_bone_data_get_shear_yPtr .asFunction(); - void spine_bone_data_set_shear_y( - spine_bone_data data, - double shearY, - ) { - return _spine_bone_data_set_shear_y( - data, - shearY, - ); + void spine_bone_data_set_shear_y(spine_bone_data data, double shearY) { + return _spine_bone_data_set_shear_y(data, shearY); } - late final _spine_bone_data_set_shear_yPtr = _lookup< - ffi.NativeFunction>( - 'spine_bone_data_set_shear_y'); + late final _spine_bone_data_set_shear_yPtr = + _lookup>('spine_bone_data_set_shear_y'); late final _spine_bone_data_set_shear_y = _spine_bone_data_set_shear_yPtr .asFunction(); - int spine_bone_data_get_inherit( - spine_bone_data data, - ) { - return _spine_bone_data_get_inherit( - data, - ); + int spine_bone_data_get_inherit(spine_bone_data data) { + return _spine_bone_data_get_inherit(data); } - late final _spine_bone_data_get_inheritPtr = - _lookup>( - 'spine_bone_data_get_inherit'); - late final _spine_bone_data_get_inherit = _spine_bone_data_get_inheritPtr - .asFunction(); + late final _spine_bone_data_get_inheritPtr = _lookup>( + 'spine_bone_data_get_inherit', + ); + late final _spine_bone_data_get_inherit = _spine_bone_data_get_inheritPtr.asFunction(); - void spine_bone_data_set_inherit( - spine_bone_data data, - int inherit, - ) { - return _spine_bone_data_set_inherit( - data, - inherit, - ); + void spine_bone_data_set_inherit(spine_bone_data data, int inherit) { + return _spine_bone_data_set_inherit(data, inherit); } - late final _spine_bone_data_set_inheritPtr = _lookup< - ffi.NativeFunction>( - 'spine_bone_data_set_inherit'); + late final _spine_bone_data_set_inheritPtr = + _lookup>('spine_bone_data_set_inherit'); late final _spine_bone_data_set_inherit = _spine_bone_data_set_inheritPtr .asFunction(); - int spine_bone_data_is_skin_required( - spine_bone_data data, - ) { - return _spine_bone_data_is_skin_required( - data, - ); + int spine_bone_data_is_skin_required(spine_bone_data data) { + return _spine_bone_data_is_skin_required(data); } - late final _spine_bone_data_is_skin_requiredPtr = - _lookup>( - 'spine_bone_data_is_skin_required'); - late final _spine_bone_data_is_skin_required = - _spine_bone_data_is_skin_requiredPtr - .asFunction(); + late final _spine_bone_data_is_skin_requiredPtr = _lookup>( + 'spine_bone_data_is_skin_required', + ); + late final _spine_bone_data_is_skin_required = _spine_bone_data_is_skin_requiredPtr + .asFunction(); - void spine_bone_data_set_is_skin_required( - spine_bone_data data, - int isSkinRequired, - ) { - return _spine_bone_data_set_is_skin_required( - data, - isSkinRequired, - ); + void spine_bone_data_set_is_skin_required(spine_bone_data data, int isSkinRequired) { + return _spine_bone_data_set_is_skin_required(data, isSkinRequired); } - late final _spine_bone_data_set_is_skin_requiredPtr = _lookup< - ffi.NativeFunction>( - 'spine_bone_data_set_is_skin_required'); - late final _spine_bone_data_set_is_skin_required = - _spine_bone_data_set_is_skin_requiredPtr - .asFunction(); + late final _spine_bone_data_set_is_skin_requiredPtr = + _lookup>( + 'spine_bone_data_set_is_skin_required', + ); + late final _spine_bone_data_set_is_skin_required = _spine_bone_data_set_is_skin_requiredPtr + .asFunction(); - spine_color spine_bone_data_get_color( - spine_bone_data data, - ) { - return _spine_bone_data_get_color( - data, - ); + spine_color spine_bone_data_get_color(spine_bone_data data) { + return _spine_bone_data_get_color(data); } - late final _spine_bone_data_get_colorPtr = - _lookup>( - 'spine_bone_data_get_color'); + late final _spine_bone_data_get_colorPtr = _lookup>( + 'spine_bone_data_get_color', + ); late final _spine_bone_data_get_color = _spine_bone_data_get_colorPtr .asFunction(); - void spine_bone_data_set_color( - spine_bone_data data, - double r, - double g, - double b, - double a, - ) { - return _spine_bone_data_set_color( - data, - r, - g, - b, - a, - ); + void spine_bone_data_set_color(spine_bone_data data, double r, double g, double b, double a) { + return _spine_bone_data_set_color(data, r, g, b, a); } - late final _spine_bone_data_set_colorPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_bone_data, ffi.Float, ffi.Float, ffi.Float, - ffi.Float)>>('spine_bone_data_set_color'); - late final _spine_bone_data_set_color = - _spine_bone_data_set_colorPtr.asFunction< - void Function(spine_bone_data, double, double, double, double)>(); + late final _spine_bone_data_set_colorPtr = + _lookup>( + 'spine_bone_data_set_color', + ); + late final _spine_bone_data_set_color = _spine_bone_data_set_colorPtr + .asFunction(); - int spine_bone_data_is_visible( - spine_bone_data data, - ) { - return _spine_bone_data_is_visible( - data, - ); + int spine_bone_data_is_visible(spine_bone_data data) { + return _spine_bone_data_is_visible(data); } - late final _spine_bone_data_is_visiblePtr = - _lookup>( - 'spine_bone_data_is_visible'); - late final _spine_bone_data_is_visible = _spine_bone_data_is_visiblePtr - .asFunction(); + late final _spine_bone_data_is_visiblePtr = _lookup>( + 'spine_bone_data_is_visible', + ); + late final _spine_bone_data_is_visible = _spine_bone_data_is_visiblePtr.asFunction(); - void spine_bone_data_set_visible( - spine_bone_data data, - int isVisible, - ) { - return _spine_bone_data_set_visible( - data, - isVisible, - ); + void spine_bone_data_set_visible(spine_bone_data data, int isVisible) { + return _spine_bone_data_set_visible(data, isVisible); } - late final _spine_bone_data_set_visiblePtr = _lookup< - ffi.NativeFunction>( - 'spine_bone_data_set_visible'); + late final _spine_bone_data_set_visiblePtr = + _lookup>('spine_bone_data_set_visible'); late final _spine_bone_data_set_visible = _spine_bone_data_set_visiblePtr .asFunction(); /// Omitted getIcon()/setIcon() - void spine_bone_set_is_y_down( - int yDown, - ) { - return _spine_bone_set_is_y_down( - yDown, - ); + void spine_bone_set_is_y_down(int yDown) { + return _spine_bone_set_is_y_down(yDown); } - late final _spine_bone_set_is_y_downPtr = - _lookup>( - 'spine_bone_set_is_y_down'); - late final _spine_bone_set_is_y_down = - _spine_bone_set_is_y_downPtr.asFunction(); + late final _spine_bone_set_is_y_downPtr = _lookup>( + 'spine_bone_set_is_y_down', + ); + late final _spine_bone_set_is_y_down = _spine_bone_set_is_y_downPtr.asFunction(); int spine_bone_get_is_y_down() { return _spine_bone_get_is_y_down(); } - late final _spine_bone_get_is_y_downPtr = - _lookup>( - 'spine_bone_get_is_y_down'); - late final _spine_bone_get_is_y_down = - _spine_bone_get_is_y_downPtr.asFunction(); + late final _spine_bone_get_is_y_downPtr = _lookup>( + 'spine_bone_get_is_y_down', + ); + late final _spine_bone_get_is_y_down = _spine_bone_get_is_y_downPtr.asFunction(); - void spine_bone_update( - spine_bone bone, - ) { - return _spine_bone_update( - bone, - ); + void spine_bone_update(spine_bone bone) { + return _spine_bone_update(bone); } - late final _spine_bone_updatePtr = - _lookup>( - 'spine_bone_update'); - late final _spine_bone_update = - _spine_bone_updatePtr.asFunction(); + late final _spine_bone_updatePtr = _lookup>('spine_bone_update'); + late final _spine_bone_update = _spine_bone_updatePtr.asFunction(); - void spine_bone_update_world_transform( - spine_bone bone, - ) { - return _spine_bone_update_world_transform( - bone, - ); + void spine_bone_update_world_transform(spine_bone bone) { + return _spine_bone_update_world_transform(bone); } - late final _spine_bone_update_world_transformPtr = - _lookup>( - 'spine_bone_update_world_transform'); - late final _spine_bone_update_world_transform = - _spine_bone_update_world_transformPtr - .asFunction(); + late final _spine_bone_update_world_transformPtr = _lookup>( + 'spine_bone_update_world_transform', + ); + late final _spine_bone_update_world_transform = _spine_bone_update_world_transformPtr + .asFunction(); void spine_bone_update_world_transform_with( spine_bone bone, @@ -4840,2197 +3078,1342 @@ class SpineFlutterBindings { double shearX, double shearY, ) { - return _spine_bone_update_world_transform_with( - bone, - x, - y, - rotation, - scaleX, - scaleY, - shearX, - shearY, - ); + return _spine_bone_update_world_transform_with(bone, x, y, rotation, scaleX, scaleY, shearX, shearY); } - late final _spine_bone_update_world_transform_withPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function( - spine_bone, - ffi.Float, - ffi.Float, - ffi.Float, - ffi.Float, - ffi.Float, - ffi.Float, - ffi.Float)>>('spine_bone_update_world_transform_with'); - late final _spine_bone_update_world_transform_with = - _spine_bone_update_world_transform_withPtr.asFunction< - void Function(spine_bone, double, double, double, double, double, - double, double)>(); + late final _spine_bone_update_world_transform_withPtr = + _lookup< + ffi.NativeFunction< + ffi.Void Function(spine_bone, ffi.Float, ffi.Float, ffi.Float, ffi.Float, ffi.Float, ffi.Float, ffi.Float) + > + >('spine_bone_update_world_transform_with'); + late final _spine_bone_update_world_transform_with = _spine_bone_update_world_transform_withPtr + .asFunction(); - void spine_bone_update_applied_transform( - spine_bone bone, - ) { - return _spine_bone_update_applied_transform( - bone, - ); + void spine_bone_update_applied_transform(spine_bone bone) { + return _spine_bone_update_applied_transform(bone); } - late final _spine_bone_update_applied_transformPtr = - _lookup>( - 'spine_bone_update_applied_transform'); - late final _spine_bone_update_applied_transform = - _spine_bone_update_applied_transformPtr - .asFunction(); + late final _spine_bone_update_applied_transformPtr = _lookup>( + 'spine_bone_update_applied_transform', + ); + late final _spine_bone_update_applied_transform = _spine_bone_update_applied_transformPtr + .asFunction(); - void spine_bone_set_to_setup_pose( - spine_bone bone, - ) { - return _spine_bone_set_to_setup_pose( - bone, - ); + void spine_bone_set_to_setup_pose(spine_bone bone) { + return _spine_bone_set_to_setup_pose(bone); } - late final _spine_bone_set_to_setup_posePtr = - _lookup>( - 'spine_bone_set_to_setup_pose'); - late final _spine_bone_set_to_setup_pose = - _spine_bone_set_to_setup_posePtr.asFunction(); + late final _spine_bone_set_to_setup_posePtr = _lookup>( + 'spine_bone_set_to_setup_pose', + ); + late final _spine_bone_set_to_setup_pose = _spine_bone_set_to_setup_posePtr.asFunction(); - spine_vector spine_bone_world_to_local( - spine_bone bone, - double worldX, - double worldY, - ) { - return _spine_bone_world_to_local( - bone, - worldX, - worldY, - ); + spine_vector spine_bone_world_to_local(spine_bone bone, double worldX, double worldY) { + return _spine_bone_world_to_local(bone, worldX, worldY); } - late final _spine_bone_world_to_localPtr = _lookup< - ffi.NativeFunction< - spine_vector Function( - spine_bone, ffi.Float, ffi.Float)>>('spine_bone_world_to_local'); + late final _spine_bone_world_to_localPtr = + _lookup>('spine_bone_world_to_local'); late final _spine_bone_world_to_local = _spine_bone_world_to_localPtr .asFunction(); - spine_vector spine_bone_world_to_parent( - spine_bone bone, - double worldX, - double worldY, - ) { - return _spine_bone_world_to_parent( - bone, - worldX, - worldY, - ); + spine_vector spine_bone_world_to_parent(spine_bone bone, double worldX, double worldY) { + return _spine_bone_world_to_parent(bone, worldX, worldY); } - late final _spine_bone_world_to_parentPtr = _lookup< - ffi.NativeFunction< - spine_vector Function( - spine_bone, ffi.Float, ffi.Float)>>('spine_bone_world_to_parent'); + late final _spine_bone_world_to_parentPtr = + _lookup>( + 'spine_bone_world_to_parent', + ); late final _spine_bone_world_to_parent = _spine_bone_world_to_parentPtr .asFunction(); - spine_vector spine_bone_local_to_world( - spine_bone bone, - double localX, - double localY, - ) { - return _spine_bone_local_to_world( - bone, - localX, - localY, - ); + spine_vector spine_bone_local_to_world(spine_bone bone, double localX, double localY) { + return _spine_bone_local_to_world(bone, localX, localY); } - late final _spine_bone_local_to_worldPtr = _lookup< - ffi.NativeFunction< - spine_vector Function( - spine_bone, ffi.Float, ffi.Float)>>('spine_bone_local_to_world'); + late final _spine_bone_local_to_worldPtr = + _lookup>('spine_bone_local_to_world'); late final _spine_bone_local_to_world = _spine_bone_local_to_worldPtr .asFunction(); - spine_vector spine_bone_parent_to_world( - spine_bone bone, - double localX, - double localY, - ) { - return _spine_bone_parent_to_world( - bone, - localX, - localY, - ); + spine_vector spine_bone_parent_to_world(spine_bone bone, double localX, double localY) { + return _spine_bone_parent_to_world(bone, localX, localY); } - late final _spine_bone_parent_to_worldPtr = _lookup< - ffi.NativeFunction< - spine_vector Function( - spine_bone, ffi.Float, ffi.Float)>>('spine_bone_parent_to_world'); + late final _spine_bone_parent_to_worldPtr = + _lookup>( + 'spine_bone_parent_to_world', + ); late final _spine_bone_parent_to_world = _spine_bone_parent_to_worldPtr .asFunction(); - double spine_bone_world_to_local_rotation( - spine_bone bone, - double worldRotation, - ) { - return _spine_bone_world_to_local_rotation( - bone, - worldRotation, - ); + double spine_bone_world_to_local_rotation(spine_bone bone, double worldRotation) { + return _spine_bone_world_to_local_rotation(bone, worldRotation); } late final _spine_bone_world_to_local_rotationPtr = - _lookup>( - 'spine_bone_world_to_local_rotation'); - late final _spine_bone_world_to_local_rotation = - _spine_bone_world_to_local_rotationPtr - .asFunction(); + _lookup>('spine_bone_world_to_local_rotation'); + late final _spine_bone_world_to_local_rotation = _spine_bone_world_to_local_rotationPtr + .asFunction(); - double spine_bone_local_to_world_rotation( - spine_bone bone, - double localRotation, - ) { - return _spine_bone_local_to_world_rotation( - bone, - localRotation, - ); + double spine_bone_local_to_world_rotation(spine_bone bone, double localRotation) { + return _spine_bone_local_to_world_rotation(bone, localRotation); } late final _spine_bone_local_to_world_rotationPtr = - _lookup>( - 'spine_bone_local_to_world_rotation'); - late final _spine_bone_local_to_world_rotation = - _spine_bone_local_to_world_rotationPtr - .asFunction(); + _lookup>('spine_bone_local_to_world_rotation'); + late final _spine_bone_local_to_world_rotation = _spine_bone_local_to_world_rotationPtr + .asFunction(); - void spine_bone_rotate_world( - spine_bone bone, - double degrees, - ) { - return _spine_bone_rotate_world( - bone, - degrees, - ); + void spine_bone_rotate_world(spine_bone bone, double degrees) { + return _spine_bone_rotate_world(bone, degrees); } - late final _spine_bone_rotate_worldPtr = - _lookup>( - 'spine_bone_rotate_world'); - late final _spine_bone_rotate_world = _spine_bone_rotate_worldPtr - .asFunction(); + late final _spine_bone_rotate_worldPtr = _lookup>( + 'spine_bone_rotate_world', + ); + late final _spine_bone_rotate_world = _spine_bone_rotate_worldPtr.asFunction(); - double spine_bone_get_world_to_local_rotation_x( - spine_bone bone, - ) { - return _spine_bone_get_world_to_local_rotation_x( - bone, - ); + double spine_bone_get_world_to_local_rotation_x(spine_bone bone) { + return _spine_bone_get_world_to_local_rotation_x(bone); } - late final _spine_bone_get_world_to_local_rotation_xPtr = - _lookup>( - 'spine_bone_get_world_to_local_rotation_x'); - late final _spine_bone_get_world_to_local_rotation_x = - _spine_bone_get_world_to_local_rotation_xPtr - .asFunction(); + late final _spine_bone_get_world_to_local_rotation_xPtr = _lookup>( + 'spine_bone_get_world_to_local_rotation_x', + ); + late final _spine_bone_get_world_to_local_rotation_x = _spine_bone_get_world_to_local_rotation_xPtr + .asFunction(); - double spine_bone_get_world_to_local_rotation_y( - spine_bone bone, - ) { - return _spine_bone_get_world_to_local_rotation_y( - bone, - ); + double spine_bone_get_world_to_local_rotation_y(spine_bone bone) { + return _spine_bone_get_world_to_local_rotation_y(bone); } - late final _spine_bone_get_world_to_local_rotation_yPtr = - _lookup>( - 'spine_bone_get_world_to_local_rotation_y'); - late final _spine_bone_get_world_to_local_rotation_y = - _spine_bone_get_world_to_local_rotation_yPtr - .asFunction(); + late final _spine_bone_get_world_to_local_rotation_yPtr = _lookup>( + 'spine_bone_get_world_to_local_rotation_y', + ); + late final _spine_bone_get_world_to_local_rotation_y = _spine_bone_get_world_to_local_rotation_yPtr + .asFunction(); - spine_bone_data spine_bone_get_data( - spine_bone bone, - ) { - return _spine_bone_get_data( - bone, - ); + spine_bone_data spine_bone_get_data(spine_bone bone) { + return _spine_bone_get_data(bone); } - late final _spine_bone_get_dataPtr = - _lookup>( - 'spine_bone_get_data'); - late final _spine_bone_get_data = _spine_bone_get_dataPtr - .asFunction(); + late final _spine_bone_get_dataPtr = _lookup>( + 'spine_bone_get_data', + ); + late final _spine_bone_get_data = _spine_bone_get_dataPtr.asFunction(); - spine_skeleton spine_bone_get_skeleton( - spine_bone bone, - ) { - return _spine_bone_get_skeleton( - bone, - ); + spine_skeleton spine_bone_get_skeleton(spine_bone bone) { + return _spine_bone_get_skeleton(bone); } - late final _spine_bone_get_skeletonPtr = - _lookup>( - 'spine_bone_get_skeleton'); - late final _spine_bone_get_skeleton = _spine_bone_get_skeletonPtr - .asFunction(); + late final _spine_bone_get_skeletonPtr = _lookup>( + 'spine_bone_get_skeleton', + ); + late final _spine_bone_get_skeleton = _spine_bone_get_skeletonPtr.asFunction(); - spine_bone spine_bone_get_parent( - spine_bone bone, - ) { - return _spine_bone_get_parent( - bone, - ); + spine_bone spine_bone_get_parent(spine_bone bone) { + return _spine_bone_get_parent(bone); } - late final _spine_bone_get_parentPtr = - _lookup>( - 'spine_bone_get_parent'); - late final _spine_bone_get_parent = - _spine_bone_get_parentPtr.asFunction(); + late final _spine_bone_get_parentPtr = _lookup>( + 'spine_bone_get_parent', + ); + late final _spine_bone_get_parent = _spine_bone_get_parentPtr.asFunction(); - int spine_bone_get_num_children( - spine_bone bone, - ) { - return _spine_bone_get_num_children( - bone, - ); + int spine_bone_get_num_children(spine_bone bone) { + return _spine_bone_get_num_children(bone); } - late final _spine_bone_get_num_childrenPtr = - _lookup>( - 'spine_bone_get_num_children'); - late final _spine_bone_get_num_children = - _spine_bone_get_num_childrenPtr.asFunction(); + late final _spine_bone_get_num_childrenPtr = _lookup>( + 'spine_bone_get_num_children', + ); + late final _spine_bone_get_num_children = _spine_bone_get_num_childrenPtr.asFunction(); - ffi.Pointer spine_bone_get_children( - spine_bone bone, - ) { - return _spine_bone_get_children( - bone, - ); + ffi.Pointer spine_bone_get_children(spine_bone bone) { + return _spine_bone_get_children(bone); } - late final _spine_bone_get_childrenPtr = - _lookup Function(spine_bone)>>( - 'spine_bone_get_children'); + late final _spine_bone_get_childrenPtr = _lookup Function(spine_bone)>>( + 'spine_bone_get_children', + ); late final _spine_bone_get_children = _spine_bone_get_childrenPtr .asFunction Function(spine_bone)>(); - double spine_bone_get_x( - spine_bone bone, - ) { - return _spine_bone_get_x( - bone, - ); + double spine_bone_get_x(spine_bone bone) { + return _spine_bone_get_x(bone); } - late final _spine_bone_get_xPtr = - _lookup>( - 'spine_bone_get_x'); - late final _spine_bone_get_x = - _spine_bone_get_xPtr.asFunction(); + late final _spine_bone_get_xPtr = _lookup>('spine_bone_get_x'); + late final _spine_bone_get_x = _spine_bone_get_xPtr.asFunction(); - void spine_bone_set_x( - spine_bone bone, - double x, - ) { - return _spine_bone_set_x( - bone, - x, - ); + void spine_bone_set_x(spine_bone bone, double x) { + return _spine_bone_set_x(bone, x); } - late final _spine_bone_set_xPtr = - _lookup>( - 'spine_bone_set_x'); - late final _spine_bone_set_x = - _spine_bone_set_xPtr.asFunction(); + late final _spine_bone_set_xPtr = _lookup>( + 'spine_bone_set_x', + ); + late final _spine_bone_set_x = _spine_bone_set_xPtr.asFunction(); - double spine_bone_get_y( - spine_bone bone, - ) { - return _spine_bone_get_y( - bone, - ); + double spine_bone_get_y(spine_bone bone) { + return _spine_bone_get_y(bone); } - late final _spine_bone_get_yPtr = - _lookup>( - 'spine_bone_get_y'); - late final _spine_bone_get_y = - _spine_bone_get_yPtr.asFunction(); + late final _spine_bone_get_yPtr = _lookup>('spine_bone_get_y'); + late final _spine_bone_get_y = _spine_bone_get_yPtr.asFunction(); - void spine_bone_set_y( - spine_bone bone, - double y, - ) { - return _spine_bone_set_y( - bone, - y, - ); + void spine_bone_set_y(spine_bone bone, double y) { + return _spine_bone_set_y(bone, y); } - late final _spine_bone_set_yPtr = - _lookup>( - 'spine_bone_set_y'); - late final _spine_bone_set_y = - _spine_bone_set_yPtr.asFunction(); + late final _spine_bone_set_yPtr = _lookup>( + 'spine_bone_set_y', + ); + late final _spine_bone_set_y = _spine_bone_set_yPtr.asFunction(); - double spine_bone_get_rotation( - spine_bone bone, - ) { - return _spine_bone_get_rotation( - bone, - ); + double spine_bone_get_rotation(spine_bone bone) { + return _spine_bone_get_rotation(bone); } - late final _spine_bone_get_rotationPtr = - _lookup>( - 'spine_bone_get_rotation'); - late final _spine_bone_get_rotation = - _spine_bone_get_rotationPtr.asFunction(); + late final _spine_bone_get_rotationPtr = _lookup>( + 'spine_bone_get_rotation', + ); + late final _spine_bone_get_rotation = _spine_bone_get_rotationPtr.asFunction(); - void spine_bone_set_rotation( - spine_bone bone, - double rotation, - ) { - return _spine_bone_set_rotation( - bone, - rotation, - ); + void spine_bone_set_rotation(spine_bone bone, double rotation) { + return _spine_bone_set_rotation(bone, rotation); } - late final _spine_bone_set_rotationPtr = - _lookup>( - 'spine_bone_set_rotation'); - late final _spine_bone_set_rotation = _spine_bone_set_rotationPtr - .asFunction(); + late final _spine_bone_set_rotationPtr = _lookup>( + 'spine_bone_set_rotation', + ); + late final _spine_bone_set_rotation = _spine_bone_set_rotationPtr.asFunction(); - double spine_bone_get_scale_x( - spine_bone bone, - ) { - return _spine_bone_get_scale_x( - bone, - ); + double spine_bone_get_scale_x(spine_bone bone) { + return _spine_bone_get_scale_x(bone); } - late final _spine_bone_get_scale_xPtr = - _lookup>( - 'spine_bone_get_scale_x'); - late final _spine_bone_get_scale_x = - _spine_bone_get_scale_xPtr.asFunction(); + late final _spine_bone_get_scale_xPtr = _lookup>( + 'spine_bone_get_scale_x', + ); + late final _spine_bone_get_scale_x = _spine_bone_get_scale_xPtr.asFunction(); - void spine_bone_set_scale_x( - spine_bone bone, - double scaleX, - ) { - return _spine_bone_set_scale_x( - bone, - scaleX, - ); + void spine_bone_set_scale_x(spine_bone bone, double scaleX) { + return _spine_bone_set_scale_x(bone, scaleX); } - late final _spine_bone_set_scale_xPtr = - _lookup>( - 'spine_bone_set_scale_x'); - late final _spine_bone_set_scale_x = _spine_bone_set_scale_xPtr - .asFunction(); + late final _spine_bone_set_scale_xPtr = _lookup>( + 'spine_bone_set_scale_x', + ); + late final _spine_bone_set_scale_x = _spine_bone_set_scale_xPtr.asFunction(); - double spine_bone_get_scale_y( - spine_bone bone, - ) { - return _spine_bone_get_scale_y( - bone, - ); + double spine_bone_get_scale_y(spine_bone bone) { + return _spine_bone_get_scale_y(bone); } - late final _spine_bone_get_scale_yPtr = - _lookup>( - 'spine_bone_get_scale_y'); - late final _spine_bone_get_scale_y = - _spine_bone_get_scale_yPtr.asFunction(); + late final _spine_bone_get_scale_yPtr = _lookup>( + 'spine_bone_get_scale_y', + ); + late final _spine_bone_get_scale_y = _spine_bone_get_scale_yPtr.asFunction(); - void spine_bone_set_scale_y( - spine_bone bone, - double scaleY, - ) { - return _spine_bone_set_scale_y( - bone, - scaleY, - ); + void spine_bone_set_scale_y(spine_bone bone, double scaleY) { + return _spine_bone_set_scale_y(bone, scaleY); } - late final _spine_bone_set_scale_yPtr = - _lookup>( - 'spine_bone_set_scale_y'); - late final _spine_bone_set_scale_y = _spine_bone_set_scale_yPtr - .asFunction(); + late final _spine_bone_set_scale_yPtr = _lookup>( + 'spine_bone_set_scale_y', + ); + late final _spine_bone_set_scale_y = _spine_bone_set_scale_yPtr.asFunction(); - double spine_bone_get_shear_x( - spine_bone bone, - ) { - return _spine_bone_get_shear_x( - bone, - ); + double spine_bone_get_shear_x(spine_bone bone) { + return _spine_bone_get_shear_x(bone); } - late final _spine_bone_get_shear_xPtr = - _lookup>( - 'spine_bone_get_shear_x'); - late final _spine_bone_get_shear_x = - _spine_bone_get_shear_xPtr.asFunction(); + late final _spine_bone_get_shear_xPtr = _lookup>( + 'spine_bone_get_shear_x', + ); + late final _spine_bone_get_shear_x = _spine_bone_get_shear_xPtr.asFunction(); - void spine_bone_set_shear_x( - spine_bone bone, - double shearX, - ) { - return _spine_bone_set_shear_x( - bone, - shearX, - ); + void spine_bone_set_shear_x(spine_bone bone, double shearX) { + return _spine_bone_set_shear_x(bone, shearX); } - late final _spine_bone_set_shear_xPtr = - _lookup>( - 'spine_bone_set_shear_x'); - late final _spine_bone_set_shear_x = _spine_bone_set_shear_xPtr - .asFunction(); + late final _spine_bone_set_shear_xPtr = _lookup>( + 'spine_bone_set_shear_x', + ); + late final _spine_bone_set_shear_x = _spine_bone_set_shear_xPtr.asFunction(); - double spine_bone_get_shear_y( - spine_bone bone, - ) { - return _spine_bone_get_shear_y( - bone, - ); + double spine_bone_get_shear_y(spine_bone bone) { + return _spine_bone_get_shear_y(bone); } - late final _spine_bone_get_shear_yPtr = - _lookup>( - 'spine_bone_get_shear_y'); - late final _spine_bone_get_shear_y = - _spine_bone_get_shear_yPtr.asFunction(); + late final _spine_bone_get_shear_yPtr = _lookup>( + 'spine_bone_get_shear_y', + ); + late final _spine_bone_get_shear_y = _spine_bone_get_shear_yPtr.asFunction(); - void spine_bone_set_shear_y( - spine_bone bone, - double shearY, - ) { - return _spine_bone_set_shear_y( - bone, - shearY, - ); + void spine_bone_set_shear_y(spine_bone bone, double shearY) { + return _spine_bone_set_shear_y(bone, shearY); } - late final _spine_bone_set_shear_yPtr = - _lookup>( - 'spine_bone_set_shear_y'); - late final _spine_bone_set_shear_y = _spine_bone_set_shear_yPtr - .asFunction(); + late final _spine_bone_set_shear_yPtr = _lookup>( + 'spine_bone_set_shear_y', + ); + late final _spine_bone_set_shear_y = _spine_bone_set_shear_yPtr.asFunction(); - double spine_bone_get_applied_rotation( - spine_bone bone, - ) { - return _spine_bone_get_applied_rotation( - bone, - ); + double spine_bone_get_applied_rotation(spine_bone bone) { + return _spine_bone_get_applied_rotation(bone); } - late final _spine_bone_get_applied_rotationPtr = - _lookup>( - 'spine_bone_get_applied_rotation'); - late final _spine_bone_get_applied_rotation = - _spine_bone_get_applied_rotationPtr - .asFunction(); + late final _spine_bone_get_applied_rotationPtr = _lookup>( + 'spine_bone_get_applied_rotation', + ); + late final _spine_bone_get_applied_rotation = _spine_bone_get_applied_rotationPtr + .asFunction(); - void spine_bone_set_applied_rotation( - spine_bone bone, - double rotation, - ) { - return _spine_bone_set_applied_rotation( - bone, - rotation, - ); + void spine_bone_set_applied_rotation(spine_bone bone, double rotation) { + return _spine_bone_set_applied_rotation(bone, rotation); } late final _spine_bone_set_applied_rotationPtr = - _lookup>( - 'spine_bone_set_applied_rotation'); - late final _spine_bone_set_applied_rotation = - _spine_bone_set_applied_rotationPtr - .asFunction(); - - double spine_bone_get_a_x( - spine_bone bone, - ) { - return _spine_bone_get_a_x( - bone, - ); - } - - late final _spine_bone_get_a_xPtr = - _lookup>( - 'spine_bone_get_a_x'); - late final _spine_bone_get_a_x = - _spine_bone_get_a_xPtr.asFunction(); - - void spine_bone_set_a_x( - spine_bone bone, - double x, - ) { - return _spine_bone_set_a_x( - bone, - x, - ); - } - - late final _spine_bone_set_a_xPtr = - _lookup>( - 'spine_bone_set_a_x'); - late final _spine_bone_set_a_x = - _spine_bone_set_a_xPtr.asFunction(); - - double spine_bone_get_a_y( - spine_bone bone, - ) { - return _spine_bone_get_a_y( - bone, - ); - } - - late final _spine_bone_get_a_yPtr = - _lookup>( - 'spine_bone_get_a_y'); - late final _spine_bone_get_a_y = - _spine_bone_get_a_yPtr.asFunction(); - - void spine_bone_set_a_y( - spine_bone bone, - double y, - ) { - return _spine_bone_set_a_y( - bone, - y, - ); - } - - late final _spine_bone_set_a_yPtr = - _lookup>( - 'spine_bone_set_a_y'); - late final _spine_bone_set_a_y = - _spine_bone_set_a_yPtr.asFunction(); - - double spine_bone_get_a_scale_x( - spine_bone bone, - ) { - return _spine_bone_get_a_scale_x( - bone, - ); - } - - late final _spine_bone_get_a_scale_xPtr = - _lookup>( - 'spine_bone_get_a_scale_x'); - late final _spine_bone_get_a_scale_x = - _spine_bone_get_a_scale_xPtr.asFunction(); - - void spine_bone_set_a_scale_x( - spine_bone bone, - double scaleX, - ) { - return _spine_bone_set_a_scale_x( - bone, - scaleX, - ); - } - - late final _spine_bone_set_a_scale_xPtr = - _lookup>( - 'spine_bone_set_a_scale_x'); - late final _spine_bone_set_a_scale_x = _spine_bone_set_a_scale_xPtr + _lookup>('spine_bone_set_applied_rotation'); + late final _spine_bone_set_applied_rotation = _spine_bone_set_applied_rotationPtr .asFunction(); - double spine_bone_get_a_scale_y( - spine_bone bone, - ) { - return _spine_bone_get_a_scale_y( - bone, - ); + double spine_bone_get_a_x(spine_bone bone) { + return _spine_bone_get_a_x(bone); } - late final _spine_bone_get_a_scale_yPtr = - _lookup>( - 'spine_bone_get_a_scale_y'); - late final _spine_bone_get_a_scale_y = - _spine_bone_get_a_scale_yPtr.asFunction(); + late final _spine_bone_get_a_xPtr = _lookup>('spine_bone_get_a_x'); + late final _spine_bone_get_a_x = _spine_bone_get_a_xPtr.asFunction(); - void spine_bone_set_a_scale_y( - spine_bone bone, - double scaleY, - ) { - return _spine_bone_set_a_scale_y( - bone, - scaleY, - ); + void spine_bone_set_a_x(spine_bone bone, double x) { + return _spine_bone_set_a_x(bone, x); } - late final _spine_bone_set_a_scale_yPtr = - _lookup>( - 'spine_bone_set_a_scale_y'); - late final _spine_bone_set_a_scale_y = _spine_bone_set_a_scale_yPtr - .asFunction(); + late final _spine_bone_set_a_xPtr = _lookup>( + 'spine_bone_set_a_x', + ); + late final _spine_bone_set_a_x = _spine_bone_set_a_xPtr.asFunction(); - double spine_bone_get_a_shear_x( - spine_bone bone, - ) { - return _spine_bone_get_a_shear_x( - bone, - ); + double spine_bone_get_a_y(spine_bone bone) { + return _spine_bone_get_a_y(bone); } - late final _spine_bone_get_a_shear_xPtr = - _lookup>( - 'spine_bone_get_a_shear_x'); - late final _spine_bone_get_a_shear_x = - _spine_bone_get_a_shear_xPtr.asFunction(); + late final _spine_bone_get_a_yPtr = _lookup>('spine_bone_get_a_y'); + late final _spine_bone_get_a_y = _spine_bone_get_a_yPtr.asFunction(); - void spine_bone_set_a_shear_x( - spine_bone bone, - double shearX, - ) { - return _spine_bone_set_a_shear_x( - bone, - shearX, - ); + void spine_bone_set_a_y(spine_bone bone, double y) { + return _spine_bone_set_a_y(bone, y); } - late final _spine_bone_set_a_shear_xPtr = - _lookup>( - 'spine_bone_set_a_shear_x'); - late final _spine_bone_set_a_shear_x = _spine_bone_set_a_shear_xPtr - .asFunction(); + late final _spine_bone_set_a_yPtr = _lookup>( + 'spine_bone_set_a_y', + ); + late final _spine_bone_set_a_y = _spine_bone_set_a_yPtr.asFunction(); - double spine_bone_get_a_shear_y( - spine_bone bone, - ) { - return _spine_bone_get_a_shear_y( - bone, - ); + double spine_bone_get_a_scale_x(spine_bone bone) { + return _spine_bone_get_a_scale_x(bone); } - late final _spine_bone_get_a_shear_yPtr = - _lookup>( - 'spine_bone_get_a_shear_y'); - late final _spine_bone_get_a_shear_y = - _spine_bone_get_a_shear_yPtr.asFunction(); + late final _spine_bone_get_a_scale_xPtr = _lookup>( + 'spine_bone_get_a_scale_x', + ); + late final _spine_bone_get_a_scale_x = _spine_bone_get_a_scale_xPtr.asFunction(); - void spine_bone_set_a_shear_y( - spine_bone bone, - double shearY, - ) { - return _spine_bone_set_a_shear_y( - bone, - shearY, - ); + void spine_bone_set_a_scale_x(spine_bone bone, double scaleX) { + return _spine_bone_set_a_scale_x(bone, scaleX); } - late final _spine_bone_set_a_shear_yPtr = - _lookup>( - 'spine_bone_set_a_shear_y'); - late final _spine_bone_set_a_shear_y = _spine_bone_set_a_shear_yPtr - .asFunction(); + late final _spine_bone_set_a_scale_xPtr = _lookup>( + 'spine_bone_set_a_scale_x', + ); + late final _spine_bone_set_a_scale_x = _spine_bone_set_a_scale_xPtr.asFunction(); - double spine_bone_get_a( - spine_bone bone, - ) { - return _spine_bone_get_a( - bone, - ); + double spine_bone_get_a_scale_y(spine_bone bone) { + return _spine_bone_get_a_scale_y(bone); } - late final _spine_bone_get_aPtr = - _lookup>( - 'spine_bone_get_a'); - late final _spine_bone_get_a = - _spine_bone_get_aPtr.asFunction(); + late final _spine_bone_get_a_scale_yPtr = _lookup>( + 'spine_bone_get_a_scale_y', + ); + late final _spine_bone_get_a_scale_y = _spine_bone_get_a_scale_yPtr.asFunction(); - void spine_bone_set_a( - spine_bone bone, - double a, - ) { - return _spine_bone_set_a( - bone, - a, - ); + void spine_bone_set_a_scale_y(spine_bone bone, double scaleY) { + return _spine_bone_set_a_scale_y(bone, scaleY); } - late final _spine_bone_set_aPtr = - _lookup>( - 'spine_bone_set_a'); - late final _spine_bone_set_a = - _spine_bone_set_aPtr.asFunction(); + late final _spine_bone_set_a_scale_yPtr = _lookup>( + 'spine_bone_set_a_scale_y', + ); + late final _spine_bone_set_a_scale_y = _spine_bone_set_a_scale_yPtr.asFunction(); - double spine_bone_get_b( - spine_bone bone, - ) { - return _spine_bone_get_b( - bone, - ); + double spine_bone_get_a_shear_x(spine_bone bone) { + return _spine_bone_get_a_shear_x(bone); } - late final _spine_bone_get_bPtr = - _lookup>( - 'spine_bone_get_b'); - late final _spine_bone_get_b = - _spine_bone_get_bPtr.asFunction(); + late final _spine_bone_get_a_shear_xPtr = _lookup>( + 'spine_bone_get_a_shear_x', + ); + late final _spine_bone_get_a_shear_x = _spine_bone_get_a_shear_xPtr.asFunction(); - void spine_bone_set_b( - spine_bone bone, - double b, - ) { - return _spine_bone_set_b( - bone, - b, - ); + void spine_bone_set_a_shear_x(spine_bone bone, double shearX) { + return _spine_bone_set_a_shear_x(bone, shearX); } - late final _spine_bone_set_bPtr = - _lookup>( - 'spine_bone_set_b'); - late final _spine_bone_set_b = - _spine_bone_set_bPtr.asFunction(); + late final _spine_bone_set_a_shear_xPtr = _lookup>( + 'spine_bone_set_a_shear_x', + ); + late final _spine_bone_set_a_shear_x = _spine_bone_set_a_shear_xPtr.asFunction(); - double spine_bone_get_c( - spine_bone bone, - ) { - return _spine_bone_get_c( - bone, - ); + double spine_bone_get_a_shear_y(spine_bone bone) { + return _spine_bone_get_a_shear_y(bone); } - late final _spine_bone_get_cPtr = - _lookup>( - 'spine_bone_get_c'); - late final _spine_bone_get_c = - _spine_bone_get_cPtr.asFunction(); + late final _spine_bone_get_a_shear_yPtr = _lookup>( + 'spine_bone_get_a_shear_y', + ); + late final _spine_bone_get_a_shear_y = _spine_bone_get_a_shear_yPtr.asFunction(); - void spine_bone_set_c( - spine_bone bone, - double c, - ) { - return _spine_bone_set_c( - bone, - c, - ); + void spine_bone_set_a_shear_y(spine_bone bone, double shearY) { + return _spine_bone_set_a_shear_y(bone, shearY); } - late final _spine_bone_set_cPtr = - _lookup>( - 'spine_bone_set_c'); - late final _spine_bone_set_c = - _spine_bone_set_cPtr.asFunction(); + late final _spine_bone_set_a_shear_yPtr = _lookup>( + 'spine_bone_set_a_shear_y', + ); + late final _spine_bone_set_a_shear_y = _spine_bone_set_a_shear_yPtr.asFunction(); - double spine_bone_get_d( - spine_bone bone, - ) { - return _spine_bone_get_d( - bone, - ); + double spine_bone_get_a(spine_bone bone) { + return _spine_bone_get_a(bone); } - late final _spine_bone_get_dPtr = - _lookup>( - 'spine_bone_get_d'); - late final _spine_bone_get_d = - _spine_bone_get_dPtr.asFunction(); + late final _spine_bone_get_aPtr = _lookup>('spine_bone_get_a'); + late final _spine_bone_get_a = _spine_bone_get_aPtr.asFunction(); - void spine_bone_set_d( - spine_bone bone, - double d, - ) { - return _spine_bone_set_d( - bone, - d, - ); + void spine_bone_set_a(spine_bone bone, double a) { + return _spine_bone_set_a(bone, a); } - late final _spine_bone_set_dPtr = - _lookup>( - 'spine_bone_set_d'); - late final _spine_bone_set_d = - _spine_bone_set_dPtr.asFunction(); + late final _spine_bone_set_aPtr = _lookup>( + 'spine_bone_set_a', + ); + late final _spine_bone_set_a = _spine_bone_set_aPtr.asFunction(); - double spine_bone_get_world_x( - spine_bone bone, - ) { - return _spine_bone_get_world_x( - bone, - ); + double spine_bone_get_b(spine_bone bone) { + return _spine_bone_get_b(bone); } - late final _spine_bone_get_world_xPtr = - _lookup>( - 'spine_bone_get_world_x'); - late final _spine_bone_get_world_x = - _spine_bone_get_world_xPtr.asFunction(); + late final _spine_bone_get_bPtr = _lookup>('spine_bone_get_b'); + late final _spine_bone_get_b = _spine_bone_get_bPtr.asFunction(); - void spine_bone_set_world_x( - spine_bone bone, - double worldX, - ) { - return _spine_bone_set_world_x( - bone, - worldX, - ); + void spine_bone_set_b(spine_bone bone, double b) { + return _spine_bone_set_b(bone, b); } - late final _spine_bone_set_world_xPtr = - _lookup>( - 'spine_bone_set_world_x'); - late final _spine_bone_set_world_x = _spine_bone_set_world_xPtr - .asFunction(); + late final _spine_bone_set_bPtr = _lookup>( + 'spine_bone_set_b', + ); + late final _spine_bone_set_b = _spine_bone_set_bPtr.asFunction(); - double spine_bone_get_world_y( - spine_bone bone, - ) { - return _spine_bone_get_world_y( - bone, - ); + double spine_bone_get_c(spine_bone bone) { + return _spine_bone_get_c(bone); } - late final _spine_bone_get_world_yPtr = - _lookup>( - 'spine_bone_get_world_y'); - late final _spine_bone_get_world_y = - _spine_bone_get_world_yPtr.asFunction(); + late final _spine_bone_get_cPtr = _lookup>('spine_bone_get_c'); + late final _spine_bone_get_c = _spine_bone_get_cPtr.asFunction(); - void spine_bone_set_world_y( - spine_bone bone, - double worldY, - ) { - return _spine_bone_set_world_y( - bone, - worldY, - ); + void spine_bone_set_c(spine_bone bone, double c) { + return _spine_bone_set_c(bone, c); } - late final _spine_bone_set_world_yPtr = - _lookup>( - 'spine_bone_set_world_y'); - late final _spine_bone_set_world_y = _spine_bone_set_world_yPtr - .asFunction(); + late final _spine_bone_set_cPtr = _lookup>( + 'spine_bone_set_c', + ); + late final _spine_bone_set_c = _spine_bone_set_cPtr.asFunction(); - double spine_bone_get_world_rotation_x( - spine_bone bone, - ) { - return _spine_bone_get_world_rotation_x( - bone, - ); + double spine_bone_get_d(spine_bone bone) { + return _spine_bone_get_d(bone); } - late final _spine_bone_get_world_rotation_xPtr = - _lookup>( - 'spine_bone_get_world_rotation_x'); - late final _spine_bone_get_world_rotation_x = - _spine_bone_get_world_rotation_xPtr - .asFunction(); + late final _spine_bone_get_dPtr = _lookup>('spine_bone_get_d'); + late final _spine_bone_get_d = _spine_bone_get_dPtr.asFunction(); - double spine_bone_get_world_rotation_y( - spine_bone bone, - ) { - return _spine_bone_get_world_rotation_y( - bone, - ); + void spine_bone_set_d(spine_bone bone, double d) { + return _spine_bone_set_d(bone, d); } - late final _spine_bone_get_world_rotation_yPtr = - _lookup>( - 'spine_bone_get_world_rotation_y'); - late final _spine_bone_get_world_rotation_y = - _spine_bone_get_world_rotation_yPtr - .asFunction(); + late final _spine_bone_set_dPtr = _lookup>( + 'spine_bone_set_d', + ); + late final _spine_bone_set_d = _spine_bone_set_dPtr.asFunction(); - double spine_bone_get_world_scale_x( - spine_bone bone, - ) { - return _spine_bone_get_world_scale_x( - bone, - ); + double spine_bone_get_world_x(spine_bone bone) { + return _spine_bone_get_world_x(bone); } - late final _spine_bone_get_world_scale_xPtr = - _lookup>( - 'spine_bone_get_world_scale_x'); - late final _spine_bone_get_world_scale_x = _spine_bone_get_world_scale_xPtr + late final _spine_bone_get_world_xPtr = _lookup>( + 'spine_bone_get_world_x', + ); + late final _spine_bone_get_world_x = _spine_bone_get_world_xPtr.asFunction(); + + void spine_bone_set_world_x(spine_bone bone, double worldX) { + return _spine_bone_set_world_x(bone, worldX); + } + + late final _spine_bone_set_world_xPtr = _lookup>( + 'spine_bone_set_world_x', + ); + late final _spine_bone_set_world_x = _spine_bone_set_world_xPtr.asFunction(); + + double spine_bone_get_world_y(spine_bone bone) { + return _spine_bone_get_world_y(bone); + } + + late final _spine_bone_get_world_yPtr = _lookup>( + 'spine_bone_get_world_y', + ); + late final _spine_bone_get_world_y = _spine_bone_get_world_yPtr.asFunction(); + + void spine_bone_set_world_y(spine_bone bone, double worldY) { + return _spine_bone_set_world_y(bone, worldY); + } + + late final _spine_bone_set_world_yPtr = _lookup>( + 'spine_bone_set_world_y', + ); + late final _spine_bone_set_world_y = _spine_bone_set_world_yPtr.asFunction(); + + double spine_bone_get_world_rotation_x(spine_bone bone) { + return _spine_bone_get_world_rotation_x(bone); + } + + late final _spine_bone_get_world_rotation_xPtr = _lookup>( + 'spine_bone_get_world_rotation_x', + ); + late final _spine_bone_get_world_rotation_x = _spine_bone_get_world_rotation_xPtr .asFunction(); - double spine_bone_get_world_scale_y( - spine_bone bone, - ) { - return _spine_bone_get_world_scale_y( - bone, - ); + double spine_bone_get_world_rotation_y(spine_bone bone) { + return _spine_bone_get_world_rotation_y(bone); } - late final _spine_bone_get_world_scale_yPtr = - _lookup>( - 'spine_bone_get_world_scale_y'); - late final _spine_bone_get_world_scale_y = _spine_bone_get_world_scale_yPtr + late final _spine_bone_get_world_rotation_yPtr = _lookup>( + 'spine_bone_get_world_rotation_y', + ); + late final _spine_bone_get_world_rotation_y = _spine_bone_get_world_rotation_yPtr .asFunction(); - int spine_bone_get_is_active( - spine_bone bone, - ) { - return _spine_bone_get_is_active( - bone, - ); + double spine_bone_get_world_scale_x(spine_bone bone) { + return _spine_bone_get_world_scale_x(bone); } - late final _spine_bone_get_is_activePtr = - _lookup>( - 'spine_bone_get_is_active'); - late final _spine_bone_get_is_active = - _spine_bone_get_is_activePtr.asFunction(); + late final _spine_bone_get_world_scale_xPtr = _lookup>( + 'spine_bone_get_world_scale_x', + ); + late final _spine_bone_get_world_scale_x = _spine_bone_get_world_scale_xPtr.asFunction(); - void spine_bone_set_is_active( - spine_bone bone, - int isActive, - ) { - return _spine_bone_set_is_active( - bone, - isActive, - ); + double spine_bone_get_world_scale_y(spine_bone bone) { + return _spine_bone_get_world_scale_y(bone); } - late final _spine_bone_set_is_activePtr = - _lookup>( - 'spine_bone_set_is_active'); - late final _spine_bone_set_is_active = - _spine_bone_set_is_activePtr.asFunction(); + late final _spine_bone_get_world_scale_yPtr = _lookup>( + 'spine_bone_get_world_scale_y', + ); + late final _spine_bone_get_world_scale_y = _spine_bone_get_world_scale_yPtr.asFunction(); - int spine_bone_get_inherit( - spine_bone data, - ) { - return _spine_bone_get_inherit( - data, - ); + int spine_bone_get_is_active(spine_bone bone) { + return _spine_bone_get_is_active(bone); } - late final _spine_bone_get_inheritPtr = - _lookup>( - 'spine_bone_get_inherit'); - late final _spine_bone_get_inherit = - _spine_bone_get_inheritPtr.asFunction(); + late final _spine_bone_get_is_activePtr = _lookup>( + 'spine_bone_get_is_active', + ); + late final _spine_bone_get_is_active = _spine_bone_get_is_activePtr.asFunction(); - void spine_bone_set_inherit( - spine_bone data, - int inherit, - ) { - return _spine_bone_set_inherit( - data, - inherit, - ); + void spine_bone_set_is_active(spine_bone bone, int isActive) { + return _spine_bone_set_is_active(bone, isActive); } - late final _spine_bone_set_inheritPtr = - _lookup>( - 'spine_bone_set_inherit'); - late final _spine_bone_set_inherit = - _spine_bone_set_inheritPtr.asFunction(); + late final _spine_bone_set_is_activePtr = _lookup>( + 'spine_bone_set_is_active', + ); + late final _spine_bone_set_is_active = _spine_bone_set_is_activePtr.asFunction(); - ffi.Pointer spine_attachment_get_name( - spine_attachment attachment, - ) { - return _spine_attachment_get_name( - attachment, - ); + int spine_bone_get_inherit(spine_bone data) { + return _spine_bone_get_inherit(data); } - late final _spine_attachment_get_namePtr = - _lookup Function(spine_attachment)>>( - 'spine_attachment_get_name'); + late final _spine_bone_get_inheritPtr = _lookup>( + 'spine_bone_get_inherit', + ); + late final _spine_bone_get_inherit = _spine_bone_get_inheritPtr.asFunction(); + + void spine_bone_set_inherit(spine_bone data, int inherit) { + return _spine_bone_set_inherit(data, inherit); + } + + late final _spine_bone_set_inheritPtr = _lookup>( + 'spine_bone_set_inherit', + ); + late final _spine_bone_set_inherit = _spine_bone_set_inheritPtr.asFunction(); + + ffi.Pointer spine_attachment_get_name(spine_attachment attachment) { + return _spine_attachment_get_name(attachment); + } + + late final _spine_attachment_get_namePtr = _lookup Function(spine_attachment)>>( + 'spine_attachment_get_name', + ); late final _spine_attachment_get_name = _spine_attachment_get_namePtr .asFunction Function(spine_attachment)>(); - int spine_attachment_get_type( - spine_attachment attachment, - ) { - return _spine_attachment_get_type( - attachment, - ); + int spine_attachment_get_type(spine_attachment attachment) { + return _spine_attachment_get_type(attachment); } - late final _spine_attachment_get_typePtr = - _lookup>( - 'spine_attachment_get_type'); - late final _spine_attachment_get_type = _spine_attachment_get_typePtr - .asFunction(); + late final _spine_attachment_get_typePtr = _lookup>( + 'spine_attachment_get_type', + ); + late final _spine_attachment_get_type = _spine_attachment_get_typePtr.asFunction(); - spine_attachment spine_attachment_copy( - spine_attachment attachment, - ) { - return _spine_attachment_copy( - attachment, - ); + spine_attachment spine_attachment_copy(spine_attachment attachment) { + return _spine_attachment_copy(attachment); } - late final _spine_attachment_copyPtr = - _lookup>( - 'spine_attachment_copy'); + late final _spine_attachment_copyPtr = _lookup>( + 'spine_attachment_copy', + ); late final _spine_attachment_copy = _spine_attachment_copyPtr .asFunction(); - void spine_attachment_dispose( - spine_attachment attachment, - ) { - return _spine_attachment_dispose( - attachment, - ); + void spine_attachment_dispose(spine_attachment attachment) { + return _spine_attachment_dispose(attachment); } - late final _spine_attachment_disposePtr = - _lookup>( - 'spine_attachment_dispose'); - late final _spine_attachment_dispose = _spine_attachment_disposePtr - .asFunction(); + late final _spine_attachment_disposePtr = _lookup>( + 'spine_attachment_dispose', + ); + late final _spine_attachment_dispose = _spine_attachment_disposePtr.asFunction(); - spine_vector spine_point_attachment_compute_world_position( - spine_point_attachment attachment, - spine_bone bone, - ) { - return _spine_point_attachment_compute_world_position( - attachment, - bone, - ); + spine_vector spine_point_attachment_compute_world_position(spine_point_attachment attachment, spine_bone bone) { + return _spine_point_attachment_compute_world_position(attachment, bone); } - late final _spine_point_attachment_compute_world_positionPtr = _lookup< - ffi.NativeFunction< - spine_vector Function(spine_point_attachment, - spine_bone)>>('spine_point_attachment_compute_world_position'); - late final _spine_point_attachment_compute_world_position = - _spine_point_attachment_compute_world_positionPtr.asFunction< - spine_vector Function(spine_point_attachment, spine_bone)>(); + late final _spine_point_attachment_compute_world_positionPtr = + _lookup>( + 'spine_point_attachment_compute_world_position', + ); + late final _spine_point_attachment_compute_world_position = _spine_point_attachment_compute_world_positionPtr + .asFunction(); - double spine_point_attachment_compute_world_rotation( - spine_point_attachment attachment, - spine_bone bone, - ) { - return _spine_point_attachment_compute_world_rotation( - attachment, - bone, - ); + double spine_point_attachment_compute_world_rotation(spine_point_attachment attachment, spine_bone bone) { + return _spine_point_attachment_compute_world_rotation(attachment, bone); } - late final _spine_point_attachment_compute_world_rotationPtr = _lookup< - ffi.NativeFunction< - ffi.Float Function(spine_point_attachment, - spine_bone)>>('spine_point_attachment_compute_world_rotation'); - late final _spine_point_attachment_compute_world_rotation = - _spine_point_attachment_compute_world_rotationPtr - .asFunction(); + late final _spine_point_attachment_compute_world_rotationPtr = + _lookup>( + 'spine_point_attachment_compute_world_rotation', + ); + late final _spine_point_attachment_compute_world_rotation = _spine_point_attachment_compute_world_rotationPtr + .asFunction(); - double spine_point_attachment_get_x( - spine_point_attachment attachment, - ) { - return _spine_point_attachment_get_x( - attachment, - ); + double spine_point_attachment_get_x(spine_point_attachment attachment) { + return _spine_point_attachment_get_x(attachment); } - late final _spine_point_attachment_get_xPtr = - _lookup>( - 'spine_point_attachment_get_x'); + late final _spine_point_attachment_get_xPtr = _lookup>( + 'spine_point_attachment_get_x', + ); late final _spine_point_attachment_get_x = _spine_point_attachment_get_xPtr .asFunction(); - void spine_point_attachment_set_x( - spine_point_attachment attachment, - double x, - ) { - return _spine_point_attachment_set_x( - attachment, - x, - ); + void spine_point_attachment_set_x(spine_point_attachment attachment, double x) { + return _spine_point_attachment_set_x(attachment, x); } - late final _spine_point_attachment_set_xPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_point_attachment, - ffi.Float)>>('spine_point_attachment_set_x'); + late final _spine_point_attachment_set_xPtr = + _lookup>('spine_point_attachment_set_x'); late final _spine_point_attachment_set_x = _spine_point_attachment_set_xPtr .asFunction(); - double spine_point_attachment_get_y( - spine_point_attachment attachment, - ) { - return _spine_point_attachment_get_y( - attachment, - ); + double spine_point_attachment_get_y(spine_point_attachment attachment) { + return _spine_point_attachment_get_y(attachment); } - late final _spine_point_attachment_get_yPtr = - _lookup>( - 'spine_point_attachment_get_y'); + late final _spine_point_attachment_get_yPtr = _lookup>( + 'spine_point_attachment_get_y', + ); late final _spine_point_attachment_get_y = _spine_point_attachment_get_yPtr .asFunction(); - void spine_point_attachment_set_y( - spine_point_attachment attachment, - double y, - ) { - return _spine_point_attachment_set_y( - attachment, - y, - ); + void spine_point_attachment_set_y(spine_point_attachment attachment, double y) { + return _spine_point_attachment_set_y(attachment, y); } - late final _spine_point_attachment_set_yPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_point_attachment, - ffi.Float)>>('spine_point_attachment_set_y'); + late final _spine_point_attachment_set_yPtr = + _lookup>('spine_point_attachment_set_y'); late final _spine_point_attachment_set_y = _spine_point_attachment_set_yPtr .asFunction(); - double spine_point_attachment_get_rotation( - spine_point_attachment attachment, - ) { - return _spine_point_attachment_get_rotation( - attachment, - ); + double spine_point_attachment_get_rotation(spine_point_attachment attachment) { + return _spine_point_attachment_get_rotation(attachment); } late final _spine_point_attachment_get_rotationPtr = - _lookup>( - 'spine_point_attachment_get_rotation'); - late final _spine_point_attachment_get_rotation = - _spine_point_attachment_get_rotationPtr - .asFunction(); + _lookup>('spine_point_attachment_get_rotation'); + late final _spine_point_attachment_get_rotation = _spine_point_attachment_get_rotationPtr + .asFunction(); - void spine_point_attachment_set_rotation( - spine_point_attachment attachment, - double rotation, - ) { - return _spine_point_attachment_set_rotation( - attachment, - rotation, - ); + void spine_point_attachment_set_rotation(spine_point_attachment attachment, double rotation) { + return _spine_point_attachment_set_rotation(attachment, rotation); } - late final _spine_point_attachment_set_rotationPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_point_attachment, - ffi.Float)>>('spine_point_attachment_set_rotation'); - late final _spine_point_attachment_set_rotation = - _spine_point_attachment_set_rotationPtr - .asFunction(); + late final _spine_point_attachment_set_rotationPtr = + _lookup>( + 'spine_point_attachment_set_rotation', + ); + late final _spine_point_attachment_set_rotation = _spine_point_attachment_set_rotationPtr + .asFunction(); - spine_color spine_point_attachment_get_color( - spine_point_attachment attachment, - ) { - return _spine_point_attachment_get_color( - attachment, - ); + spine_color spine_point_attachment_get_color(spine_point_attachment attachment) { + return _spine_point_attachment_get_color(attachment); } late final _spine_point_attachment_get_colorPtr = - _lookup>( - 'spine_point_attachment_get_color'); - late final _spine_point_attachment_get_color = - _spine_point_attachment_get_colorPtr - .asFunction(); + _lookup>('spine_point_attachment_get_color'); + late final _spine_point_attachment_get_color = _spine_point_attachment_get_colorPtr + .asFunction(); - void spine_point_attachment_set_color( - spine_point_attachment attachment, - double r, - double g, - double b, - double a, - ) { - return _spine_point_attachment_set_color( - attachment, - r, - g, - b, - a, - ); + void spine_point_attachment_set_color(spine_point_attachment attachment, double r, double g, double b, double a) { + return _spine_point_attachment_set_color(attachment, r, g, b, a); } - late final _spine_point_attachment_set_colorPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_point_attachment, ffi.Float, ffi.Float, - ffi.Float, ffi.Float)>>('spine_point_attachment_set_color'); - late final _spine_point_attachment_set_color = - _spine_point_attachment_set_colorPtr.asFunction< - void Function( - spine_point_attachment, double, double, double, double)>(); + late final _spine_point_attachment_set_colorPtr = + _lookup< + ffi.NativeFunction + >('spine_point_attachment_set_color'); + late final _spine_point_attachment_set_color = _spine_point_attachment_set_colorPtr + .asFunction(); - void spine_region_attachment_update_region( - spine_region_attachment attachment, - ) { - return _spine_region_attachment_update_region( - attachment, - ); + void spine_region_attachment_update_region(spine_region_attachment attachment) { + return _spine_region_attachment_update_region(attachment); } late final _spine_region_attachment_update_regionPtr = - _lookup>( - 'spine_region_attachment_update_region'); - late final _spine_region_attachment_update_region = - _spine_region_attachment_update_regionPtr - .asFunction(); + _lookup>('spine_region_attachment_update_region'); + late final _spine_region_attachment_update_region = _spine_region_attachment_update_regionPtr + .asFunction(); void spine_region_attachment_compute_world_vertices( spine_region_attachment attachment, spine_slot slot, ffi.Pointer worldVertices, ) { - return _spine_region_attachment_compute_world_vertices( - attachment, - slot, - worldVertices, - ); + return _spine_region_attachment_compute_world_vertices(attachment, slot, worldVertices); } - late final _spine_region_attachment_compute_world_verticesPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_region_attachment, spine_slot, - ffi.Pointer)>>( - 'spine_region_attachment_compute_world_vertices'); - late final _spine_region_attachment_compute_world_vertices = - _spine_region_attachment_compute_world_verticesPtr.asFunction< - void Function( - spine_region_attachment, spine_slot, ffi.Pointer)>(); + late final _spine_region_attachment_compute_world_verticesPtr = + _lookup)>>( + 'spine_region_attachment_compute_world_vertices', + ); + late final _spine_region_attachment_compute_world_vertices = _spine_region_attachment_compute_world_verticesPtr + .asFunction)>(); - double spine_region_attachment_get_x( - spine_region_attachment attachment, - ) { - return _spine_region_attachment_get_x( - attachment, - ); + double spine_region_attachment_get_x(spine_region_attachment attachment) { + return _spine_region_attachment_get_x(attachment); } late final _spine_region_attachment_get_xPtr = - _lookup>( - 'spine_region_attachment_get_x'); + _lookup>('spine_region_attachment_get_x'); late final _spine_region_attachment_get_x = _spine_region_attachment_get_xPtr .asFunction(); - void spine_region_attachment_set_x( - spine_region_attachment attachment, - double x, - ) { - return _spine_region_attachment_set_x( - attachment, - x, - ); + void spine_region_attachment_set_x(spine_region_attachment attachment, double x) { + return _spine_region_attachment_set_x(attachment, x); } - late final _spine_region_attachment_set_xPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_region_attachment, - ffi.Float)>>('spine_region_attachment_set_x'); + late final _spine_region_attachment_set_xPtr = + _lookup>( + 'spine_region_attachment_set_x', + ); late final _spine_region_attachment_set_x = _spine_region_attachment_set_xPtr .asFunction(); - double spine_region_attachment_get_y( - spine_region_attachment attachment, - ) { - return _spine_region_attachment_get_y( - attachment, - ); + double spine_region_attachment_get_y(spine_region_attachment attachment) { + return _spine_region_attachment_get_y(attachment); } late final _spine_region_attachment_get_yPtr = - _lookup>( - 'spine_region_attachment_get_y'); + _lookup>('spine_region_attachment_get_y'); late final _spine_region_attachment_get_y = _spine_region_attachment_get_yPtr .asFunction(); - void spine_region_attachment_set_y( - spine_region_attachment attachment, - double y, - ) { - return _spine_region_attachment_set_y( - attachment, - y, - ); + void spine_region_attachment_set_y(spine_region_attachment attachment, double y) { + return _spine_region_attachment_set_y(attachment, y); } - late final _spine_region_attachment_set_yPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_region_attachment, - ffi.Float)>>('spine_region_attachment_set_y'); + late final _spine_region_attachment_set_yPtr = + _lookup>( + 'spine_region_attachment_set_y', + ); late final _spine_region_attachment_set_y = _spine_region_attachment_set_yPtr .asFunction(); - double spine_region_attachment_get_rotation( - spine_region_attachment attachment, - ) { - return _spine_region_attachment_get_rotation( - attachment, - ); + double spine_region_attachment_get_rotation(spine_region_attachment attachment) { + return _spine_region_attachment_get_rotation(attachment); } late final _spine_region_attachment_get_rotationPtr = - _lookup>( - 'spine_region_attachment_get_rotation'); - late final _spine_region_attachment_get_rotation = - _spine_region_attachment_get_rotationPtr - .asFunction(); + _lookup>('spine_region_attachment_get_rotation'); + late final _spine_region_attachment_get_rotation = _spine_region_attachment_get_rotationPtr + .asFunction(); - void spine_region_attachment_set_rotation( - spine_region_attachment attachment, - double rotation, - ) { - return _spine_region_attachment_set_rotation( - attachment, - rotation, - ); + void spine_region_attachment_set_rotation(spine_region_attachment attachment, double rotation) { + return _spine_region_attachment_set_rotation(attachment, rotation); } - late final _spine_region_attachment_set_rotationPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_region_attachment, - ffi.Float)>>('spine_region_attachment_set_rotation'); - late final _spine_region_attachment_set_rotation = - _spine_region_attachment_set_rotationPtr - .asFunction(); + late final _spine_region_attachment_set_rotationPtr = + _lookup>( + 'spine_region_attachment_set_rotation', + ); + late final _spine_region_attachment_set_rotation = _spine_region_attachment_set_rotationPtr + .asFunction(); - double spine_region_attachment_get_scale_x( - spine_region_attachment attachment, - ) { - return _spine_region_attachment_get_scale_x( - attachment, - ); + double spine_region_attachment_get_scale_x(spine_region_attachment attachment) { + return _spine_region_attachment_get_scale_x(attachment); } late final _spine_region_attachment_get_scale_xPtr = - _lookup>( - 'spine_region_attachment_get_scale_x'); - late final _spine_region_attachment_get_scale_x = - _spine_region_attachment_get_scale_xPtr - .asFunction(); + _lookup>('spine_region_attachment_get_scale_x'); + late final _spine_region_attachment_get_scale_x = _spine_region_attachment_get_scale_xPtr + .asFunction(); - void spine_region_attachment_set_scale_x( - spine_region_attachment attachment, - double scaleX, - ) { - return _spine_region_attachment_set_scale_x( - attachment, - scaleX, - ); + void spine_region_attachment_set_scale_x(spine_region_attachment attachment, double scaleX) { + return _spine_region_attachment_set_scale_x(attachment, scaleX); } - late final _spine_region_attachment_set_scale_xPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_region_attachment, - ffi.Float)>>('spine_region_attachment_set_scale_x'); - late final _spine_region_attachment_set_scale_x = - _spine_region_attachment_set_scale_xPtr - .asFunction(); + late final _spine_region_attachment_set_scale_xPtr = + _lookup>( + 'spine_region_attachment_set_scale_x', + ); + late final _spine_region_attachment_set_scale_x = _spine_region_attachment_set_scale_xPtr + .asFunction(); - double spine_region_attachment_get_scale_y( - spine_region_attachment attachment, - ) { - return _spine_region_attachment_get_scale_y( - attachment, - ); + double spine_region_attachment_get_scale_y(spine_region_attachment attachment) { + return _spine_region_attachment_get_scale_y(attachment); } late final _spine_region_attachment_get_scale_yPtr = - _lookup>( - 'spine_region_attachment_get_scale_y'); - late final _spine_region_attachment_get_scale_y = - _spine_region_attachment_get_scale_yPtr - .asFunction(); + _lookup>('spine_region_attachment_get_scale_y'); + late final _spine_region_attachment_get_scale_y = _spine_region_attachment_get_scale_yPtr + .asFunction(); - void spine_region_attachment_set_scale_y( - spine_region_attachment attachment, - double scaleY, - ) { - return _spine_region_attachment_set_scale_y( - attachment, - scaleY, - ); + void spine_region_attachment_set_scale_y(spine_region_attachment attachment, double scaleY) { + return _spine_region_attachment_set_scale_y(attachment, scaleY); } - late final _spine_region_attachment_set_scale_yPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_region_attachment, - ffi.Float)>>('spine_region_attachment_set_scale_y'); - late final _spine_region_attachment_set_scale_y = - _spine_region_attachment_set_scale_yPtr - .asFunction(); + late final _spine_region_attachment_set_scale_yPtr = + _lookup>( + 'spine_region_attachment_set_scale_y', + ); + late final _spine_region_attachment_set_scale_y = _spine_region_attachment_set_scale_yPtr + .asFunction(); - double spine_region_attachment_get_width( - spine_region_attachment attachment, - ) { - return _spine_region_attachment_get_width( - attachment, - ); + double spine_region_attachment_get_width(spine_region_attachment attachment) { + return _spine_region_attachment_get_width(attachment); } late final _spine_region_attachment_get_widthPtr = - _lookup>( - 'spine_region_attachment_get_width'); - late final _spine_region_attachment_get_width = - _spine_region_attachment_get_widthPtr - .asFunction(); + _lookup>('spine_region_attachment_get_width'); + late final _spine_region_attachment_get_width = _spine_region_attachment_get_widthPtr + .asFunction(); - void spine_region_attachment_set_width( - spine_region_attachment attachment, - double width, - ) { - return _spine_region_attachment_set_width( - attachment, - width, - ); + void spine_region_attachment_set_width(spine_region_attachment attachment, double width) { + return _spine_region_attachment_set_width(attachment, width); } - late final _spine_region_attachment_set_widthPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_region_attachment, - ffi.Float)>>('spine_region_attachment_set_width'); - late final _spine_region_attachment_set_width = - _spine_region_attachment_set_widthPtr - .asFunction(); + late final _spine_region_attachment_set_widthPtr = + _lookup>( + 'spine_region_attachment_set_width', + ); + late final _spine_region_attachment_set_width = _spine_region_attachment_set_widthPtr + .asFunction(); - double spine_region_attachment_get_height( - spine_region_attachment attachment, - ) { - return _spine_region_attachment_get_height( - attachment, - ); + double spine_region_attachment_get_height(spine_region_attachment attachment) { + return _spine_region_attachment_get_height(attachment); } late final _spine_region_attachment_get_heightPtr = - _lookup>( - 'spine_region_attachment_get_height'); - late final _spine_region_attachment_get_height = - _spine_region_attachment_get_heightPtr - .asFunction(); + _lookup>('spine_region_attachment_get_height'); + late final _spine_region_attachment_get_height = _spine_region_attachment_get_heightPtr + .asFunction(); - void spine_region_attachment_set_height( - spine_region_attachment attachment, - double height, - ) { - return _spine_region_attachment_set_height( - attachment, - height, - ); + void spine_region_attachment_set_height(spine_region_attachment attachment, double height) { + return _spine_region_attachment_set_height(attachment, height); } - late final _spine_region_attachment_set_heightPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_region_attachment, - ffi.Float)>>('spine_region_attachment_set_height'); - late final _spine_region_attachment_set_height = - _spine_region_attachment_set_heightPtr - .asFunction(); + late final _spine_region_attachment_set_heightPtr = + _lookup>( + 'spine_region_attachment_set_height', + ); + late final _spine_region_attachment_set_height = _spine_region_attachment_set_heightPtr + .asFunction(); - spine_color spine_region_attachment_get_color( - spine_region_attachment attachment, - ) { - return _spine_region_attachment_get_color( - attachment, - ); + spine_color spine_region_attachment_get_color(spine_region_attachment attachment) { + return _spine_region_attachment_get_color(attachment); } - late final _spine_region_attachment_get_colorPtr = _lookup< - ffi.NativeFunction>( - 'spine_region_attachment_get_color'); - late final _spine_region_attachment_get_color = - _spine_region_attachment_get_colorPtr - .asFunction(); + late final _spine_region_attachment_get_colorPtr = + _lookup>('spine_region_attachment_get_color'); + late final _spine_region_attachment_get_color = _spine_region_attachment_get_colorPtr + .asFunction(); - void spine_region_attachment_set_color( - spine_region_attachment attachment, - double r, - double g, - double b, - double a, - ) { - return _spine_region_attachment_set_color( - attachment, - r, - g, - b, - a, - ); + void spine_region_attachment_set_color(spine_region_attachment attachment, double r, double g, double b, double a) { + return _spine_region_attachment_set_color(attachment, r, g, b, a); } - late final _spine_region_attachment_set_colorPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_region_attachment, ffi.Float, ffi.Float, - ffi.Float, ffi.Float)>>('spine_region_attachment_set_color'); - late final _spine_region_attachment_set_color = - _spine_region_attachment_set_colorPtr.asFunction< - void Function( - spine_region_attachment, double, double, double, double)>(); + late final _spine_region_attachment_set_colorPtr = + _lookup< + ffi.NativeFunction + >('spine_region_attachment_set_color'); + late final _spine_region_attachment_set_color = _spine_region_attachment_set_colorPtr + .asFunction(); - ffi.Pointer spine_region_attachment_get_path( - spine_region_attachment attachment, - ) { - return _spine_region_attachment_get_path( - attachment, - ); + ffi.Pointer spine_region_attachment_get_path(spine_region_attachment attachment) { + return _spine_region_attachment_get_path(attachment); } - late final _spine_region_attachment_get_pathPtr = _lookup< - ffi - .NativeFunction Function(spine_region_attachment)>>( - 'spine_region_attachment_get_path'); - late final _spine_region_attachment_get_path = - _spine_region_attachment_get_pathPtr - .asFunction Function(spine_region_attachment)>(); + late final _spine_region_attachment_get_pathPtr = + _lookup Function(spine_region_attachment)>>( + 'spine_region_attachment_get_path', + ); + late final _spine_region_attachment_get_path = _spine_region_attachment_get_pathPtr + .asFunction Function(spine_region_attachment)>(); /// OMITTED setPath() - spine_texture_region spine_region_attachment_get_region( - spine_region_attachment attachment, - ) { - return _spine_region_attachment_get_region( - attachment, - ); + spine_texture_region spine_region_attachment_get_region(spine_region_attachment attachment) { + return _spine_region_attachment_get_region(attachment); } - late final _spine_region_attachment_get_regionPtr = _lookup< - ffi.NativeFunction< - spine_texture_region Function( - spine_region_attachment)>>('spine_region_attachment_get_region'); - late final _spine_region_attachment_get_region = - _spine_region_attachment_get_regionPtr - .asFunction(); + late final _spine_region_attachment_get_regionPtr = + _lookup>( + 'spine_region_attachment_get_region', + ); + late final _spine_region_attachment_get_region = _spine_region_attachment_get_regionPtr + .asFunction(); /// OMITTED setRegion() - spine_sequence spine_region_attachment_get_sequence( - spine_region_attachment attachment, - ) { - return _spine_region_attachment_get_sequence( - attachment, - ); + spine_sequence spine_region_attachment_get_sequence(spine_region_attachment attachment) { + return _spine_region_attachment_get_sequence(attachment); } - late final _spine_region_attachment_get_sequencePtr = _lookup< - ffi.NativeFunction>( - 'spine_region_attachment_get_sequence'); - late final _spine_region_attachment_get_sequence = - _spine_region_attachment_get_sequencePtr - .asFunction(); + late final _spine_region_attachment_get_sequencePtr = + _lookup>( + 'spine_region_attachment_get_sequence', + ); + late final _spine_region_attachment_get_sequence = _spine_region_attachment_get_sequencePtr + .asFunction(); /// OMITTED setSequence() - int spine_region_attachment_get_num_offset( - spine_region_attachment attachment, - ) { - return _spine_region_attachment_get_num_offset( - attachment, - ); + int spine_region_attachment_get_num_offset(spine_region_attachment attachment) { + return _spine_region_attachment_get_num_offset(attachment); } late final _spine_region_attachment_get_num_offsetPtr = _lookup>( - 'spine_region_attachment_get_num_offset'); - late final _spine_region_attachment_get_num_offset = - _spine_region_attachment_get_num_offsetPtr - .asFunction(); + 'spine_region_attachment_get_num_offset', + ); + late final _spine_region_attachment_get_num_offset = _spine_region_attachment_get_num_offsetPtr + .asFunction(); - ffi.Pointer spine_region_attachment_get_offset( - spine_region_attachment attachment, - ) { - return _spine_region_attachment_get_offset( - attachment, - ); + ffi.Pointer spine_region_attachment_get_offset(spine_region_attachment attachment) { + return _spine_region_attachment_get_offset(attachment); } - late final _spine_region_attachment_get_offsetPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_region_attachment)>>('spine_region_attachment_get_offset'); - late final _spine_region_attachment_get_offset = - _spine_region_attachment_get_offsetPtr.asFunction< - ffi.Pointer Function(spine_region_attachment)>(); + late final _spine_region_attachment_get_offsetPtr = + _lookup Function(spine_region_attachment)>>( + 'spine_region_attachment_get_offset', + ); + late final _spine_region_attachment_get_offset = _spine_region_attachment_get_offsetPtr + .asFunction Function(spine_region_attachment)>(); - int spine_region_attachment_get_num_uvs( - spine_region_attachment attachment, - ) { - return _spine_region_attachment_get_num_uvs( - attachment, - ); + int spine_region_attachment_get_num_uvs(spine_region_attachment attachment) { + return _spine_region_attachment_get_num_uvs(attachment); } late final _spine_region_attachment_get_num_uvsPtr = - _lookup>( - 'spine_region_attachment_get_num_uvs'); - late final _spine_region_attachment_get_num_uvs = - _spine_region_attachment_get_num_uvsPtr - .asFunction(); + _lookup>('spine_region_attachment_get_num_uvs'); + late final _spine_region_attachment_get_num_uvs = _spine_region_attachment_get_num_uvsPtr + .asFunction(); - ffi.Pointer spine_region_attachment_get_uvs( - spine_region_attachment attachment, - ) { - return _spine_region_attachment_get_uvs( - attachment, - ); + ffi.Pointer spine_region_attachment_get_uvs(spine_region_attachment attachment) { + return _spine_region_attachment_get_uvs(attachment); } - late final _spine_region_attachment_get_uvsPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_region_attachment)>>('spine_region_attachment_get_uvs'); - late final _spine_region_attachment_get_uvs = - _spine_region_attachment_get_uvsPtr.asFunction< - ffi.Pointer Function(spine_region_attachment)>(); + late final _spine_region_attachment_get_uvsPtr = + _lookup Function(spine_region_attachment)>>( + 'spine_region_attachment_get_uvs', + ); + late final _spine_region_attachment_get_uvs = _spine_region_attachment_get_uvsPtr + .asFunction Function(spine_region_attachment)>(); - int spine_vertex_attachment_get_world_vertices_length( - spine_vertex_attachment attachment, - ) { - return _spine_vertex_attachment_get_world_vertices_length( - attachment, - ); + int spine_vertex_attachment_get_world_vertices_length(spine_vertex_attachment attachment) { + return _spine_vertex_attachment_get_world_vertices_length(attachment); } late final _spine_vertex_attachment_get_world_vertices_lengthPtr = _lookup>( - 'spine_vertex_attachment_get_world_vertices_length'); - late final _spine_vertex_attachment_get_world_vertices_length = - _spine_vertex_attachment_get_world_vertices_lengthPtr - .asFunction(); + 'spine_vertex_attachment_get_world_vertices_length', + ); + late final _spine_vertex_attachment_get_world_vertices_length = _spine_vertex_attachment_get_world_vertices_lengthPtr + .asFunction(); void spine_vertex_attachment_compute_world_vertices( spine_vertex_attachment attachment, spine_slot slot, ffi.Pointer worldVertices, ) { - return _spine_vertex_attachment_compute_world_vertices( - attachment, - slot, - worldVertices, - ); + return _spine_vertex_attachment_compute_world_vertices(attachment, slot, worldVertices); } - late final _spine_vertex_attachment_compute_world_verticesPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_vertex_attachment, spine_slot, - ffi.Pointer)>>( - 'spine_vertex_attachment_compute_world_vertices'); - late final _spine_vertex_attachment_compute_world_vertices = - _spine_vertex_attachment_compute_world_verticesPtr.asFunction< - void Function( - spine_vertex_attachment, spine_slot, ffi.Pointer)>(); + late final _spine_vertex_attachment_compute_world_verticesPtr = + _lookup)>>( + 'spine_vertex_attachment_compute_world_vertices', + ); + late final _spine_vertex_attachment_compute_world_vertices = _spine_vertex_attachment_compute_world_verticesPtr + .asFunction)>(); /// OMITTED getId() - int spine_vertex_attachment_get_num_bones( - spine_vertex_attachment attachment, - ) { - return _spine_vertex_attachment_get_num_bones( - attachment, - ); + int spine_vertex_attachment_get_num_bones(spine_vertex_attachment attachment) { + return _spine_vertex_attachment_get_num_bones(attachment); } late final _spine_vertex_attachment_get_num_bonesPtr = - _lookup>( - 'spine_vertex_attachment_get_num_bones'); - late final _spine_vertex_attachment_get_num_bones = - _spine_vertex_attachment_get_num_bonesPtr - .asFunction(); + _lookup>('spine_vertex_attachment_get_num_bones'); + late final _spine_vertex_attachment_get_num_bones = _spine_vertex_attachment_get_num_bonesPtr + .asFunction(); - ffi.Pointer spine_vertex_attachment_get_bones( - spine_vertex_attachment attachment, - ) { - return _spine_vertex_attachment_get_bones( - attachment, - ); + ffi.Pointer spine_vertex_attachment_get_bones(spine_vertex_attachment attachment) { + return _spine_vertex_attachment_get_bones(attachment); } - late final _spine_vertex_attachment_get_bonesPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_vertex_attachment)>>('spine_vertex_attachment_get_bones'); - late final _spine_vertex_attachment_get_bones = - _spine_vertex_attachment_get_bonesPtr.asFunction< - ffi.Pointer Function(spine_vertex_attachment)>(); + late final _spine_vertex_attachment_get_bonesPtr = + _lookup Function(spine_vertex_attachment)>>( + 'spine_vertex_attachment_get_bones', + ); + late final _spine_vertex_attachment_get_bones = _spine_vertex_attachment_get_bonesPtr + .asFunction Function(spine_vertex_attachment)>(); - int spine_vertex_attachment_get_num_vertices( - spine_vertex_attachment attachment, - ) { - return _spine_vertex_attachment_get_num_vertices( - attachment, - ); + int spine_vertex_attachment_get_num_vertices(spine_vertex_attachment attachment) { + return _spine_vertex_attachment_get_num_vertices(attachment); } late final _spine_vertex_attachment_get_num_verticesPtr = _lookup>( - 'spine_vertex_attachment_get_num_vertices'); - late final _spine_vertex_attachment_get_num_vertices = - _spine_vertex_attachment_get_num_verticesPtr - .asFunction(); + 'spine_vertex_attachment_get_num_vertices', + ); + late final _spine_vertex_attachment_get_num_vertices = _spine_vertex_attachment_get_num_verticesPtr + .asFunction(); - ffi.Pointer spine_vertex_attachment_get_vertices( - spine_vertex_attachment attachment, - ) { - return _spine_vertex_attachment_get_vertices( - attachment, - ); + ffi.Pointer spine_vertex_attachment_get_vertices(spine_vertex_attachment attachment) { + return _spine_vertex_attachment_get_vertices(attachment); } - late final _spine_vertex_attachment_get_verticesPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(spine_vertex_attachment)>>( - 'spine_vertex_attachment_get_vertices'); - late final _spine_vertex_attachment_get_vertices = - _spine_vertex_attachment_get_verticesPtr.asFunction< - ffi.Pointer Function(spine_vertex_attachment)>(); + late final _spine_vertex_attachment_get_verticesPtr = + _lookup Function(spine_vertex_attachment)>>( + 'spine_vertex_attachment_get_vertices', + ); + late final _spine_vertex_attachment_get_vertices = _spine_vertex_attachment_get_verticesPtr + .asFunction Function(spine_vertex_attachment)>(); - spine_attachment spine_vertex_attachment_get_timeline_attachment( - spine_vertex_attachment timelineAttachment, - ) { - return _spine_vertex_attachment_get_timeline_attachment( - timelineAttachment, - ); + spine_attachment spine_vertex_attachment_get_timeline_attachment(spine_vertex_attachment timelineAttachment) { + return _spine_vertex_attachment_get_timeline_attachment(timelineAttachment); } - late final _spine_vertex_attachment_get_timeline_attachmentPtr = _lookup< - ffi - .NativeFunction>( - 'spine_vertex_attachment_get_timeline_attachment'); - late final _spine_vertex_attachment_get_timeline_attachment = - _spine_vertex_attachment_get_timeline_attachmentPtr - .asFunction(); + late final _spine_vertex_attachment_get_timeline_attachmentPtr = + _lookup>( + 'spine_vertex_attachment_get_timeline_attachment', + ); + late final _spine_vertex_attachment_get_timeline_attachment = _spine_vertex_attachment_get_timeline_attachmentPtr + .asFunction(); void spine_vertex_attachment_set_timeline_attachment( spine_vertex_attachment attachment, spine_attachment timelineAttachment, ) { - return _spine_vertex_attachment_set_timeline_attachment( - attachment, - timelineAttachment, - ); + return _spine_vertex_attachment_set_timeline_attachment(attachment, timelineAttachment); } - late final _spine_vertex_attachment_set_timeline_attachmentPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_vertex_attachment, spine_attachment)>>( - 'spine_vertex_attachment_set_timeline_attachment'); - late final _spine_vertex_attachment_set_timeline_attachment = - _spine_vertex_attachment_set_timeline_attachmentPtr.asFunction< - void Function(spine_vertex_attachment, spine_attachment)>(); + late final _spine_vertex_attachment_set_timeline_attachmentPtr = + _lookup>( + 'spine_vertex_attachment_set_timeline_attachment', + ); + late final _spine_vertex_attachment_set_timeline_attachment = _spine_vertex_attachment_set_timeline_attachmentPtr + .asFunction(); /// OMITTED copyTo() - void spine_mesh_attachment_update_region( - spine_mesh_attachment attachment, - ) { - return _spine_mesh_attachment_update_region( - attachment, - ); + void spine_mesh_attachment_update_region(spine_mesh_attachment attachment) { + return _spine_mesh_attachment_update_region(attachment); } late final _spine_mesh_attachment_update_regionPtr = - _lookup>( - 'spine_mesh_attachment_update_region'); - late final _spine_mesh_attachment_update_region = - _spine_mesh_attachment_update_regionPtr - .asFunction(); + _lookup>('spine_mesh_attachment_update_region'); + late final _spine_mesh_attachment_update_region = _spine_mesh_attachment_update_regionPtr + .asFunction(); - int spine_mesh_attachment_get_hull_length( - spine_mesh_attachment attachment, - ) { - return _spine_mesh_attachment_get_hull_length( - attachment, - ); + int spine_mesh_attachment_get_hull_length(spine_mesh_attachment attachment) { + return _spine_mesh_attachment_get_hull_length(attachment); } late final _spine_mesh_attachment_get_hull_lengthPtr = - _lookup>( - 'spine_mesh_attachment_get_hull_length'); - late final _spine_mesh_attachment_get_hull_length = - _spine_mesh_attachment_get_hull_lengthPtr - .asFunction(); + _lookup>('spine_mesh_attachment_get_hull_length'); + late final _spine_mesh_attachment_get_hull_length = _spine_mesh_attachment_get_hull_lengthPtr + .asFunction(); - void spine_mesh_attachment_set_hull_length( - spine_mesh_attachment attachment, - int hullLength, - ) { - return _spine_mesh_attachment_set_hull_length( - attachment, - hullLength, - ); + void spine_mesh_attachment_set_hull_length(spine_mesh_attachment attachment, int hullLength) { + return _spine_mesh_attachment_set_hull_length(attachment, hullLength); } - late final _spine_mesh_attachment_set_hull_lengthPtr = _lookup< - ffi - .NativeFunction>( - 'spine_mesh_attachment_set_hull_length'); - late final _spine_mesh_attachment_set_hull_length = - _spine_mesh_attachment_set_hull_lengthPtr - .asFunction(); + late final _spine_mesh_attachment_set_hull_lengthPtr = + _lookup>( + 'spine_mesh_attachment_set_hull_length', + ); + late final _spine_mesh_attachment_set_hull_length = _spine_mesh_attachment_set_hull_lengthPtr + .asFunction(); - int spine_mesh_attachment_get_num_region_uvs( - spine_mesh_attachment attachment, - ) { - return _spine_mesh_attachment_get_num_region_uvs( - attachment, - ); + int spine_mesh_attachment_get_num_region_uvs(spine_mesh_attachment attachment) { + return _spine_mesh_attachment_get_num_region_uvs(attachment); } late final _spine_mesh_attachment_get_num_region_uvsPtr = _lookup>( - 'spine_mesh_attachment_get_num_region_uvs'); - late final _spine_mesh_attachment_get_num_region_uvs = - _spine_mesh_attachment_get_num_region_uvsPtr - .asFunction(); + 'spine_mesh_attachment_get_num_region_uvs', + ); + late final _spine_mesh_attachment_get_num_region_uvs = _spine_mesh_attachment_get_num_region_uvsPtr + .asFunction(); - ffi.Pointer spine_mesh_attachment_get_region_uvs( - spine_mesh_attachment attachment, - ) { - return _spine_mesh_attachment_get_region_uvs( - attachment, - ); + ffi.Pointer spine_mesh_attachment_get_region_uvs(spine_mesh_attachment attachment) { + return _spine_mesh_attachment_get_region_uvs(attachment); } - late final _spine_mesh_attachment_get_region_uvsPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_mesh_attachment)>>('spine_mesh_attachment_get_region_uvs'); - late final _spine_mesh_attachment_get_region_uvs = - _spine_mesh_attachment_get_region_uvsPtr - .asFunction Function(spine_mesh_attachment)>(); + late final _spine_mesh_attachment_get_region_uvsPtr = + _lookup Function(spine_mesh_attachment)>>( + 'spine_mesh_attachment_get_region_uvs', + ); + late final _spine_mesh_attachment_get_region_uvs = _spine_mesh_attachment_get_region_uvsPtr + .asFunction Function(spine_mesh_attachment)>(); - int spine_mesh_attachment_get_num_uvs( - spine_mesh_attachment attachment, - ) { - return _spine_mesh_attachment_get_num_uvs( - attachment, - ); + int spine_mesh_attachment_get_num_uvs(spine_mesh_attachment attachment) { + return _spine_mesh_attachment_get_num_uvs(attachment); } late final _spine_mesh_attachment_get_num_uvsPtr = - _lookup>( - 'spine_mesh_attachment_get_num_uvs'); - late final _spine_mesh_attachment_get_num_uvs = - _spine_mesh_attachment_get_num_uvsPtr - .asFunction(); + _lookup>('spine_mesh_attachment_get_num_uvs'); + late final _spine_mesh_attachment_get_num_uvs = _spine_mesh_attachment_get_num_uvsPtr + .asFunction(); - ffi.Pointer spine_mesh_attachment_get_uvs( - spine_mesh_attachment attachment, - ) { - return _spine_mesh_attachment_get_uvs( - attachment, - ); + ffi.Pointer spine_mesh_attachment_get_uvs(spine_mesh_attachment attachment) { + return _spine_mesh_attachment_get_uvs(attachment); } - late final _spine_mesh_attachment_get_uvsPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_mesh_attachment)>>('spine_mesh_attachment_get_uvs'); + late final _spine_mesh_attachment_get_uvsPtr = + _lookup Function(spine_mesh_attachment)>>( + 'spine_mesh_attachment_get_uvs', + ); late final _spine_mesh_attachment_get_uvs = _spine_mesh_attachment_get_uvsPtr .asFunction Function(spine_mesh_attachment)>(); - int spine_mesh_attachment_get_num_triangles( - spine_mesh_attachment attachment, - ) { - return _spine_mesh_attachment_get_num_triangles( - attachment, - ); + int spine_mesh_attachment_get_num_triangles(spine_mesh_attachment attachment) { + return _spine_mesh_attachment_get_num_triangles(attachment); } late final _spine_mesh_attachment_get_num_trianglesPtr = - _lookup>( - 'spine_mesh_attachment_get_num_triangles'); - late final _spine_mesh_attachment_get_num_triangles = - _spine_mesh_attachment_get_num_trianglesPtr - .asFunction(); + _lookup>('spine_mesh_attachment_get_num_triangles'); + late final _spine_mesh_attachment_get_num_triangles = _spine_mesh_attachment_get_num_trianglesPtr + .asFunction(); - ffi.Pointer spine_mesh_attachment_get_triangles( - spine_mesh_attachment attachment, - ) { - return _spine_mesh_attachment_get_triangles( - attachment, - ); + ffi.Pointer spine_mesh_attachment_get_triangles(spine_mesh_attachment attachment) { + return _spine_mesh_attachment_get_triangles(attachment); } - late final _spine_mesh_attachment_get_trianglesPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_mesh_attachment)>>('spine_mesh_attachment_get_triangles'); - late final _spine_mesh_attachment_get_triangles = - _spine_mesh_attachment_get_trianglesPtr.asFunction< - ffi.Pointer Function(spine_mesh_attachment)>(); + late final _spine_mesh_attachment_get_trianglesPtr = + _lookup Function(spine_mesh_attachment)>>( + 'spine_mesh_attachment_get_triangles', + ); + late final _spine_mesh_attachment_get_triangles = _spine_mesh_attachment_get_trianglesPtr + .asFunction Function(spine_mesh_attachment)>(); - spine_color spine_mesh_attachment_get_color( - spine_mesh_attachment attachment, - ) { - return _spine_mesh_attachment_get_color( - attachment, - ); + spine_color spine_mesh_attachment_get_color(spine_mesh_attachment attachment) { + return _spine_mesh_attachment_get_color(attachment); } late final _spine_mesh_attachment_get_colorPtr = - _lookup>( - 'spine_mesh_attachment_get_color'); - late final _spine_mesh_attachment_get_color = - _spine_mesh_attachment_get_colorPtr - .asFunction(); + _lookup>('spine_mesh_attachment_get_color'); + late final _spine_mesh_attachment_get_color = _spine_mesh_attachment_get_colorPtr + .asFunction(); - void spine_mesh_attachment_set_color( - spine_mesh_attachment attachment, - double r, - double g, - double b, - double a, - ) { - return _spine_mesh_attachment_set_color( - attachment, - r, - g, - b, - a, - ); + void spine_mesh_attachment_set_color(spine_mesh_attachment attachment, double r, double g, double b, double a) { + return _spine_mesh_attachment_set_color(attachment, r, g, b, a); } - late final _spine_mesh_attachment_set_colorPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_mesh_attachment, ffi.Float, ffi.Float, - ffi.Float, ffi.Float)>>('spine_mesh_attachment_set_color'); - late final _spine_mesh_attachment_set_color = - _spine_mesh_attachment_set_colorPtr.asFunction< - void Function( - spine_mesh_attachment, double, double, double, double)>(); + late final _spine_mesh_attachment_set_colorPtr = + _lookup>( + 'spine_mesh_attachment_set_color', + ); + late final _spine_mesh_attachment_set_color = _spine_mesh_attachment_set_colorPtr + .asFunction(); - ffi.Pointer spine_mesh_attachment_get_path( - spine_mesh_attachment attachment, - ) { - return _spine_mesh_attachment_get_path( - attachment, - ); + ffi.Pointer spine_mesh_attachment_get_path(spine_mesh_attachment attachment) { + return _spine_mesh_attachment_get_path(attachment); } - late final _spine_mesh_attachment_get_pathPtr = _lookup< - ffi - .NativeFunction Function(spine_mesh_attachment)>>( - 'spine_mesh_attachment_get_path'); - late final _spine_mesh_attachment_get_path = - _spine_mesh_attachment_get_pathPtr - .asFunction Function(spine_mesh_attachment)>(); + late final _spine_mesh_attachment_get_pathPtr = + _lookup Function(spine_mesh_attachment)>>('spine_mesh_attachment_get_path'); + late final _spine_mesh_attachment_get_path = _spine_mesh_attachment_get_pathPtr + .asFunction Function(spine_mesh_attachment)>(); /// OMITTED setPath() - spine_texture_region spine_mesh_attachment_get_region( - spine_mesh_attachment attachment, - ) { - return _spine_mesh_attachment_get_region( - attachment, - ); + spine_texture_region spine_mesh_attachment_get_region(spine_mesh_attachment attachment) { + return _spine_mesh_attachment_get_region(attachment); } - late final _spine_mesh_attachment_get_regionPtr = _lookup< - ffi.NativeFunction< - spine_texture_region Function( - spine_mesh_attachment)>>('spine_mesh_attachment_get_region'); - late final _spine_mesh_attachment_get_region = - _spine_mesh_attachment_get_regionPtr - .asFunction(); + late final _spine_mesh_attachment_get_regionPtr = + _lookup>( + 'spine_mesh_attachment_get_region', + ); + late final _spine_mesh_attachment_get_region = _spine_mesh_attachment_get_regionPtr + .asFunction(); /// OMITTED setRegion() - spine_sequence spine_mesh_attachment_get_sequence( - spine_mesh_attachment attachment, - ) { - return _spine_mesh_attachment_get_sequence( - attachment, - ); + spine_sequence spine_mesh_attachment_get_sequence(spine_mesh_attachment attachment) { + return _spine_mesh_attachment_get_sequence(attachment); } - late final _spine_mesh_attachment_get_sequencePtr = _lookup< - ffi.NativeFunction>( - 'spine_mesh_attachment_get_sequence'); - late final _spine_mesh_attachment_get_sequence = - _spine_mesh_attachment_get_sequencePtr - .asFunction(); + late final _spine_mesh_attachment_get_sequencePtr = + _lookup>('spine_mesh_attachment_get_sequence'); + late final _spine_mesh_attachment_get_sequence = _spine_mesh_attachment_get_sequencePtr + .asFunction(); /// OMITTED setSequence() - spine_mesh_attachment spine_mesh_attachment_get_parent_mesh( - spine_mesh_attachment attachment, - ) { - return _spine_mesh_attachment_get_parent_mesh( - attachment, - ); + spine_mesh_attachment spine_mesh_attachment_get_parent_mesh(spine_mesh_attachment attachment) { + return _spine_mesh_attachment_get_parent_mesh(attachment); } - late final _spine_mesh_attachment_get_parent_meshPtr = _lookup< - ffi.NativeFunction< - spine_mesh_attachment Function( - spine_mesh_attachment)>>('spine_mesh_attachment_get_parent_mesh'); - late final _spine_mesh_attachment_get_parent_mesh = - _spine_mesh_attachment_get_parent_meshPtr - .asFunction(); + late final _spine_mesh_attachment_get_parent_meshPtr = + _lookup>( + 'spine_mesh_attachment_get_parent_mesh', + ); + late final _spine_mesh_attachment_get_parent_mesh = _spine_mesh_attachment_get_parent_meshPtr + .asFunction(); - void spine_mesh_attachment_set_parent_mesh( - spine_mesh_attachment attachment, - spine_mesh_attachment parentMesh, - ) { - return _spine_mesh_attachment_set_parent_mesh( - attachment, - parentMesh, - ); + void spine_mesh_attachment_set_parent_mesh(spine_mesh_attachment attachment, spine_mesh_attachment parentMesh) { + return _spine_mesh_attachment_set_parent_mesh(attachment, parentMesh); } - late final _spine_mesh_attachment_set_parent_meshPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_mesh_attachment, - spine_mesh_attachment)>>('spine_mesh_attachment_set_parent_mesh'); - late final _spine_mesh_attachment_set_parent_mesh = - _spine_mesh_attachment_set_parent_meshPtr.asFunction< - void Function(spine_mesh_attachment, spine_mesh_attachment)>(); + late final _spine_mesh_attachment_set_parent_meshPtr = + _lookup>( + 'spine_mesh_attachment_set_parent_mesh', + ); + late final _spine_mesh_attachment_set_parent_mesh = _spine_mesh_attachment_set_parent_meshPtr + .asFunction(); - int spine_mesh_attachment_get_num_edges( - spine_mesh_attachment attachment, - ) { - return _spine_mesh_attachment_get_num_edges( - attachment, - ); + int spine_mesh_attachment_get_num_edges(spine_mesh_attachment attachment) { + return _spine_mesh_attachment_get_num_edges(attachment); } late final _spine_mesh_attachment_get_num_edgesPtr = - _lookup>( - 'spine_mesh_attachment_get_num_edges'); - late final _spine_mesh_attachment_get_num_edges = - _spine_mesh_attachment_get_num_edgesPtr - .asFunction(); + _lookup>('spine_mesh_attachment_get_num_edges'); + late final _spine_mesh_attachment_get_num_edges = _spine_mesh_attachment_get_num_edgesPtr + .asFunction(); - ffi.Pointer spine_mesh_attachment_get_edges( - spine_mesh_attachment attachment, - ) { - return _spine_mesh_attachment_get_edges( - attachment, - ); + ffi.Pointer spine_mesh_attachment_get_edges(spine_mesh_attachment attachment) { + return _spine_mesh_attachment_get_edges(attachment); } - late final _spine_mesh_attachment_get_edgesPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_mesh_attachment)>>('spine_mesh_attachment_get_edges'); - late final _spine_mesh_attachment_get_edges = - _spine_mesh_attachment_get_edgesPtr.asFunction< - ffi.Pointer Function(spine_mesh_attachment)>(); + late final _spine_mesh_attachment_get_edgesPtr = + _lookup Function(spine_mesh_attachment)>>( + 'spine_mesh_attachment_get_edges', + ); + late final _spine_mesh_attachment_get_edges = _spine_mesh_attachment_get_edgesPtr + .asFunction Function(spine_mesh_attachment)>(); - double spine_mesh_attachment_get_width( - spine_mesh_attachment attachment, - ) { - return _spine_mesh_attachment_get_width( - attachment, - ); + double spine_mesh_attachment_get_width(spine_mesh_attachment attachment) { + return _spine_mesh_attachment_get_width(attachment); } late final _spine_mesh_attachment_get_widthPtr = - _lookup>( - 'spine_mesh_attachment_get_width'); - late final _spine_mesh_attachment_get_width = - _spine_mesh_attachment_get_widthPtr - .asFunction(); + _lookup>('spine_mesh_attachment_get_width'); + late final _spine_mesh_attachment_get_width = _spine_mesh_attachment_get_widthPtr + .asFunction(); - void spine_mesh_attachment_set_width( - spine_mesh_attachment attachment, - double width, - ) { - return _spine_mesh_attachment_set_width( - attachment, - width, - ); + void spine_mesh_attachment_set_width(spine_mesh_attachment attachment, double width) { + return _spine_mesh_attachment_set_width(attachment, width); } - late final _spine_mesh_attachment_set_widthPtr = _lookup< - ffi - .NativeFunction>( - 'spine_mesh_attachment_set_width'); - late final _spine_mesh_attachment_set_width = - _spine_mesh_attachment_set_widthPtr - .asFunction(); + late final _spine_mesh_attachment_set_widthPtr = + _lookup>( + 'spine_mesh_attachment_set_width', + ); + late final _spine_mesh_attachment_set_width = _spine_mesh_attachment_set_widthPtr + .asFunction(); - double spine_mesh_attachment_get_height( - spine_mesh_attachment attachment, - ) { - return _spine_mesh_attachment_get_height( - attachment, - ); + double spine_mesh_attachment_get_height(spine_mesh_attachment attachment) { + return _spine_mesh_attachment_get_height(attachment); } late final _spine_mesh_attachment_get_heightPtr = - _lookup>( - 'spine_mesh_attachment_get_height'); - late final _spine_mesh_attachment_get_height = - _spine_mesh_attachment_get_heightPtr - .asFunction(); + _lookup>('spine_mesh_attachment_get_height'); + late final _spine_mesh_attachment_get_height = _spine_mesh_attachment_get_heightPtr + .asFunction(); - void spine_mesh_attachment_set_height( - spine_mesh_attachment attachment, - double height, - ) { - return _spine_mesh_attachment_set_height( - attachment, - height, - ); + void spine_mesh_attachment_set_height(spine_mesh_attachment attachment, double height) { + return _spine_mesh_attachment_set_height(attachment, height); } - late final _spine_mesh_attachment_set_heightPtr = _lookup< - ffi - .NativeFunction>( - 'spine_mesh_attachment_set_height'); - late final _spine_mesh_attachment_set_height = - _spine_mesh_attachment_set_heightPtr - .asFunction(); + late final _spine_mesh_attachment_set_heightPtr = + _lookup>( + 'spine_mesh_attachment_set_height', + ); + late final _spine_mesh_attachment_set_height = _spine_mesh_attachment_set_heightPtr + .asFunction(); /// OMITTED newLinkedMesh() - spine_slot_data spine_clipping_attachment_get_end_slot( - spine_clipping_attachment attachment, - ) { - return _spine_clipping_attachment_get_end_slot( - attachment, - ); + spine_slot_data spine_clipping_attachment_get_end_slot(spine_clipping_attachment attachment) { + return _spine_clipping_attachment_get_end_slot(attachment); } - late final _spine_clipping_attachment_get_end_slotPtr = _lookup< - ffi - .NativeFunction>( - 'spine_clipping_attachment_get_end_slot'); - late final _spine_clipping_attachment_get_end_slot = - _spine_clipping_attachment_get_end_slotPtr - .asFunction(); + late final _spine_clipping_attachment_get_end_slotPtr = + _lookup>( + 'spine_clipping_attachment_get_end_slot', + ); + late final _spine_clipping_attachment_get_end_slot = _spine_clipping_attachment_get_end_slotPtr + .asFunction(); - void spine_clipping_attachment_set_end_slot( - spine_clipping_attachment attachment, - spine_slot_data endSlot, - ) { - return _spine_clipping_attachment_set_end_slot( - attachment, - endSlot, - ); + void spine_clipping_attachment_set_end_slot(spine_clipping_attachment attachment, spine_slot_data endSlot) { + return _spine_clipping_attachment_set_end_slot(attachment, endSlot); } - late final _spine_clipping_attachment_set_end_slotPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_clipping_attachment, - spine_slot_data)>>('spine_clipping_attachment_set_end_slot'); - late final _spine_clipping_attachment_set_end_slot = - _spine_clipping_attachment_set_end_slotPtr.asFunction< - void Function(spine_clipping_attachment, spine_slot_data)>(); + late final _spine_clipping_attachment_set_end_slotPtr = + _lookup>( + 'spine_clipping_attachment_set_end_slot', + ); + late final _spine_clipping_attachment_set_end_slot = _spine_clipping_attachment_set_end_slotPtr + .asFunction(); - spine_color spine_clipping_attachment_get_color( - spine_clipping_attachment attachment, - ) { - return _spine_clipping_attachment_get_color( - attachment, - ); + spine_color spine_clipping_attachment_get_color(spine_clipping_attachment attachment) { + return _spine_clipping_attachment_get_color(attachment); } - late final _spine_clipping_attachment_get_colorPtr = _lookup< - ffi.NativeFunction>( - 'spine_clipping_attachment_get_color'); - late final _spine_clipping_attachment_get_color = - _spine_clipping_attachment_get_colorPtr - .asFunction(); + late final _spine_clipping_attachment_get_colorPtr = + _lookup>( + 'spine_clipping_attachment_get_color', + ); + late final _spine_clipping_attachment_get_color = _spine_clipping_attachment_get_colorPtr + .asFunction(); void spine_clipping_attachment_set_color( spine_clipping_attachment attachment, @@ -7039,39 +4422,26 @@ class SpineFlutterBindings { double b, double a, ) { - return _spine_clipping_attachment_set_color( - attachment, - r, - g, - b, - a, - ); + return _spine_clipping_attachment_set_color(attachment, r, g, b, a); } - late final _spine_clipping_attachment_set_colorPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_clipping_attachment, ffi.Float, ffi.Float, - ffi.Float, ffi.Float)>>('spine_clipping_attachment_set_color'); - late final _spine_clipping_attachment_set_color = - _spine_clipping_attachment_set_colorPtr.asFunction< - void Function( - spine_clipping_attachment, double, double, double, double)>(); + late final _spine_clipping_attachment_set_colorPtr = + _lookup< + ffi.NativeFunction + >('spine_clipping_attachment_set_color'); + late final _spine_clipping_attachment_set_color = _spine_clipping_attachment_set_colorPtr + .asFunction(); - spine_color spine_bounding_box_attachment_get_color( - spine_bounding_box_attachment attachment, - ) { - return _spine_bounding_box_attachment_get_color( - attachment, - ); + spine_color spine_bounding_box_attachment_get_color(spine_bounding_box_attachment attachment) { + return _spine_bounding_box_attachment_get_color(attachment); } - late final _spine_bounding_box_attachment_get_colorPtr = _lookup< - ffi - .NativeFunction>( - 'spine_bounding_box_attachment_get_color'); - late final _spine_bounding_box_attachment_get_color = - _spine_bounding_box_attachment_get_colorPtr - .asFunction(); + late final _spine_bounding_box_attachment_get_colorPtr = + _lookup>( + 'spine_bounding_box_attachment_get_color', + ); + late final _spine_bounding_box_attachment_get_color = _spine_bounding_box_attachment_get_colorPtr + .asFunction(); void spine_bounding_box_attachment_set_color( spine_bounding_box_attachment attachment, @@ -7080,1413 +4450,893 @@ class SpineFlutterBindings { double b, double a, ) { - return _spine_bounding_box_attachment_set_color( - attachment, - r, - g, - b, - a, - ); + return _spine_bounding_box_attachment_set_color(attachment, r, g, b, a); } - late final _spine_bounding_box_attachment_set_colorPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function( - spine_bounding_box_attachment, - ffi.Float, - ffi.Float, - ffi.Float, - ffi.Float)>>('spine_bounding_box_attachment_set_color'); - late final _spine_bounding_box_attachment_set_color = - _spine_bounding_box_attachment_set_colorPtr.asFunction< - void Function( - spine_bounding_box_attachment, double, double, double, double)>(); + late final _spine_bounding_box_attachment_set_colorPtr = + _lookup< + ffi.NativeFunction + >('spine_bounding_box_attachment_set_color'); + late final _spine_bounding_box_attachment_set_color = _spine_bounding_box_attachment_set_colorPtr + .asFunction(); - int spine_path_attachment_get_num_lengths( - spine_path_attachment attachment, - ) { - return _spine_path_attachment_get_num_lengths( - attachment, - ); + int spine_path_attachment_get_num_lengths(spine_path_attachment attachment) { + return _spine_path_attachment_get_num_lengths(attachment); } late final _spine_path_attachment_get_num_lengthsPtr = - _lookup>( - 'spine_path_attachment_get_num_lengths'); - late final _spine_path_attachment_get_num_lengths = - _spine_path_attachment_get_num_lengthsPtr - .asFunction(); + _lookup>('spine_path_attachment_get_num_lengths'); + late final _spine_path_attachment_get_num_lengths = _spine_path_attachment_get_num_lengthsPtr + .asFunction(); - ffi.Pointer spine_path_attachment_get_lengths( - spine_path_attachment attachment, - ) { - return _spine_path_attachment_get_lengths( - attachment, - ); + ffi.Pointer spine_path_attachment_get_lengths(spine_path_attachment attachment) { + return _spine_path_attachment_get_lengths(attachment); } - late final _spine_path_attachment_get_lengthsPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_path_attachment)>>('spine_path_attachment_get_lengths'); - late final _spine_path_attachment_get_lengths = - _spine_path_attachment_get_lengthsPtr - .asFunction Function(spine_path_attachment)>(); + late final _spine_path_attachment_get_lengthsPtr = + _lookup Function(spine_path_attachment)>>( + 'spine_path_attachment_get_lengths', + ); + late final _spine_path_attachment_get_lengths = _spine_path_attachment_get_lengthsPtr + .asFunction Function(spine_path_attachment)>(); - int spine_path_attachment_get_is_closed( - spine_path_attachment attachment, - ) { - return _spine_path_attachment_get_is_closed( - attachment, - ); + int spine_path_attachment_get_is_closed(spine_path_attachment attachment) { + return _spine_path_attachment_get_is_closed(attachment); } late final _spine_path_attachment_get_is_closedPtr = - _lookup>( - 'spine_path_attachment_get_is_closed'); - late final _spine_path_attachment_get_is_closed = - _spine_path_attachment_get_is_closedPtr - .asFunction(); + _lookup>('spine_path_attachment_get_is_closed'); + late final _spine_path_attachment_get_is_closed = _spine_path_attachment_get_is_closedPtr + .asFunction(); - void spine_path_attachment_set_is_closed( - spine_path_attachment attachment, - int isClosed, - ) { - return _spine_path_attachment_set_is_closed( - attachment, - isClosed, - ); + void spine_path_attachment_set_is_closed(spine_path_attachment attachment, int isClosed) { + return _spine_path_attachment_set_is_closed(attachment, isClosed); } - late final _spine_path_attachment_set_is_closedPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_path_attachment, - spine_bool)>>('spine_path_attachment_set_is_closed'); - late final _spine_path_attachment_set_is_closed = - _spine_path_attachment_set_is_closedPtr - .asFunction(); + late final _spine_path_attachment_set_is_closedPtr = + _lookup>( + 'spine_path_attachment_set_is_closed', + ); + late final _spine_path_attachment_set_is_closed = _spine_path_attachment_set_is_closedPtr + .asFunction(); - int spine_path_attachment_get_is_constant_speed( - spine_path_attachment attachment, - ) { - return _spine_path_attachment_get_is_constant_speed( - attachment, - ); + int spine_path_attachment_get_is_constant_speed(spine_path_attachment attachment) { + return _spine_path_attachment_get_is_constant_speed(attachment); } late final _spine_path_attachment_get_is_constant_speedPtr = _lookup>( - 'spine_path_attachment_get_is_constant_speed'); - late final _spine_path_attachment_get_is_constant_speed = - _spine_path_attachment_get_is_constant_speedPtr - .asFunction(); + 'spine_path_attachment_get_is_constant_speed', + ); + late final _spine_path_attachment_get_is_constant_speed = _spine_path_attachment_get_is_constant_speedPtr + .asFunction(); - void spine_path_attachment_set_is_constant_speed( - spine_path_attachment attachment, - int isConstantSpeed, - ) { - return _spine_path_attachment_set_is_constant_speed( - attachment, - isConstantSpeed, - ); + void spine_path_attachment_set_is_constant_speed(spine_path_attachment attachment, int isConstantSpeed) { + return _spine_path_attachment_set_is_constant_speed(attachment, isConstantSpeed); } - late final _spine_path_attachment_set_is_constant_speedPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_path_attachment, - spine_bool)>>('spine_path_attachment_set_is_constant_speed'); - late final _spine_path_attachment_set_is_constant_speed = - _spine_path_attachment_set_is_constant_speedPtr - .asFunction(); + late final _spine_path_attachment_set_is_constant_speedPtr = + _lookup>( + 'spine_path_attachment_set_is_constant_speed', + ); + late final _spine_path_attachment_set_is_constant_speed = _spine_path_attachment_set_is_constant_speedPtr + .asFunction(); - spine_color spine_path_attachment_get_color( - spine_path_attachment attachment, - ) { - return _spine_path_attachment_get_color( - attachment, - ); + spine_color spine_path_attachment_get_color(spine_path_attachment attachment) { + return _spine_path_attachment_get_color(attachment); } late final _spine_path_attachment_get_colorPtr = - _lookup>( - 'spine_path_attachment_get_color'); - late final _spine_path_attachment_get_color = - _spine_path_attachment_get_colorPtr - .asFunction(); + _lookup>('spine_path_attachment_get_color'); + late final _spine_path_attachment_get_color = _spine_path_attachment_get_colorPtr + .asFunction(); - void spine_path_attachment_set_color( - spine_path_attachment attachment, - double r, - double g, - double b, - double a, - ) { - return _spine_path_attachment_set_color( - attachment, - r, - g, - b, - a, - ); + void spine_path_attachment_set_color(spine_path_attachment attachment, double r, double g, double b, double a) { + return _spine_path_attachment_set_color(attachment, r, g, b, a); } - late final _spine_path_attachment_set_colorPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_path_attachment, ffi.Float, ffi.Float, - ffi.Float, ffi.Float)>>('spine_path_attachment_set_color'); - late final _spine_path_attachment_set_color = - _spine_path_attachment_set_colorPtr.asFunction< - void Function( - spine_path_attachment, double, double, double, double)>(); + late final _spine_path_attachment_set_colorPtr = + _lookup>( + 'spine_path_attachment_set_color', + ); + late final _spine_path_attachment_set_color = _spine_path_attachment_set_colorPtr + .asFunction(); - void spine_skin_set_attachment( - spine_skin skin, - int slotIndex, - ffi.Pointer name, - spine_attachment attachment, - ) { - return _spine_skin_set_attachment( - skin, - slotIndex, - name, - attachment, - ); + void spine_skin_set_attachment(spine_skin skin, int slotIndex, ffi.Pointer name, spine_attachment attachment) { + return _spine_skin_set_attachment(skin, slotIndex, name, attachment); } - late final _spine_skin_set_attachmentPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_skin, ffi.Int32, ffi.Pointer, - spine_attachment)>>('spine_skin_set_attachment'); - late final _spine_skin_set_attachment = - _spine_skin_set_attachmentPtr.asFunction< - void Function( - spine_skin, int, ffi.Pointer, spine_attachment)>(); + late final _spine_skin_set_attachmentPtr = + _lookup, spine_attachment)>>( + 'spine_skin_set_attachment', + ); + late final _spine_skin_set_attachment = _spine_skin_set_attachmentPtr + .asFunction, spine_attachment)>(); - spine_attachment spine_skin_get_attachment( - spine_skin skin, - int slotIndex, - ffi.Pointer name, - ) { - return _spine_skin_get_attachment( - skin, - slotIndex, - name, - ); + spine_attachment spine_skin_get_attachment(spine_skin skin, int slotIndex, ffi.Pointer name) { + return _spine_skin_get_attachment(skin, slotIndex, name); } - late final _spine_skin_get_attachmentPtr = _lookup< - ffi.NativeFunction< - spine_attachment Function(spine_skin, ffi.Int32, - ffi.Pointer)>>('spine_skin_get_attachment'); - late final _spine_skin_get_attachment = - _spine_skin_get_attachmentPtr.asFunction< - spine_attachment Function(spine_skin, int, ffi.Pointer)>(); + late final _spine_skin_get_attachmentPtr = + _lookup)>>( + 'spine_skin_get_attachment', + ); + late final _spine_skin_get_attachment = _spine_skin_get_attachmentPtr + .asFunction)>(); - void spine_skin_remove_attachment( - spine_skin skin, - int slotIndex, - ffi.Pointer name, - ) { - return _spine_skin_remove_attachment( - skin, - slotIndex, - name, - ); + void spine_skin_remove_attachment(spine_skin skin, int slotIndex, ffi.Pointer name) { + return _spine_skin_remove_attachment(skin, slotIndex, name); } - late final _spine_skin_remove_attachmentPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_skin, ffi.Int32, - ffi.Pointer)>>('spine_skin_remove_attachment'); + late final _spine_skin_remove_attachmentPtr = + _lookup)>>( + 'spine_skin_remove_attachment', + ); late final _spine_skin_remove_attachment = _spine_skin_remove_attachmentPtr .asFunction)>(); /// OMITTED findNamesForSlot() /// OMITTED findAttachmentsForSlot() /// OMITTED getColor() - ffi.Pointer spine_skin_get_name( - spine_skin skin, - ) { - return _spine_skin_get_name( - skin, - ); + ffi.Pointer spine_skin_get_name(spine_skin skin) { + return _spine_skin_get_name(skin); } - late final _spine_skin_get_namePtr = - _lookup Function(spine_skin)>>( - 'spine_skin_get_name'); - late final _spine_skin_get_name = _spine_skin_get_namePtr - .asFunction Function(spine_skin)>(); + late final _spine_skin_get_namePtr = _lookup Function(spine_skin)>>( + 'spine_skin_get_name', + ); + late final _spine_skin_get_name = _spine_skin_get_namePtr.asFunction Function(spine_skin)>(); - void spine_skin_add_skin( - spine_skin skin, - spine_skin other, - ) { - return _spine_skin_add_skin( - skin, - other, - ); + void spine_skin_add_skin(spine_skin skin, spine_skin other) { + return _spine_skin_add_skin(skin, other); } - late final _spine_skin_add_skinPtr = - _lookup>( - 'spine_skin_add_skin'); - late final _spine_skin_add_skin = _spine_skin_add_skinPtr - .asFunction(); + late final _spine_skin_add_skinPtr = _lookup>( + 'spine_skin_add_skin', + ); + late final _spine_skin_add_skin = _spine_skin_add_skinPtr.asFunction(); - void spine_skin_copy_skin( - spine_skin skin, - spine_skin other, - ) { - return _spine_skin_copy_skin( - skin, - other, - ); + void spine_skin_copy_skin(spine_skin skin, spine_skin other) { + return _spine_skin_copy_skin(skin, other); } - late final _spine_skin_copy_skinPtr = - _lookup>( - 'spine_skin_copy_skin'); - late final _spine_skin_copy_skin = _spine_skin_copy_skinPtr - .asFunction(); + late final _spine_skin_copy_skinPtr = _lookup>( + 'spine_skin_copy_skin', + ); + late final _spine_skin_copy_skin = _spine_skin_copy_skinPtr.asFunction(); - spine_skin_entries spine_skin_get_entries( - spine_skin skin, - ) { - return _spine_skin_get_entries( - skin, - ); + spine_skin_entries spine_skin_get_entries(spine_skin skin) { + return _spine_skin_get_entries(skin); } - late final _spine_skin_get_entriesPtr = - _lookup>( - 'spine_skin_get_entries'); - late final _spine_skin_get_entries = _spine_skin_get_entriesPtr - .asFunction(); + late final _spine_skin_get_entriesPtr = _lookup>( + 'spine_skin_get_entries', + ); + late final _spine_skin_get_entries = _spine_skin_get_entriesPtr.asFunction(); - int spine_skin_entries_get_num_entries( - spine_skin_entries entries, - ) { - return _spine_skin_entries_get_num_entries( - entries, - ); + int spine_skin_entries_get_num_entries(spine_skin_entries entries) { + return _spine_skin_entries_get_num_entries(entries); } late final _spine_skin_entries_get_num_entriesPtr = - _lookup>( - 'spine_skin_entries_get_num_entries'); - late final _spine_skin_entries_get_num_entries = - _spine_skin_entries_get_num_entriesPtr - .asFunction(); + _lookup>('spine_skin_entries_get_num_entries'); + late final _spine_skin_entries_get_num_entries = _spine_skin_entries_get_num_entriesPtr + .asFunction(); - spine_skin_entry spine_skin_entries_get_entry( - spine_skin_entries entries, - int index, - ) { - return _spine_skin_entries_get_entry( - entries, - index, - ); + spine_skin_entry spine_skin_entries_get_entry(spine_skin_entries entries, int index) { + return _spine_skin_entries_get_entry(entries, index); } - late final _spine_skin_entries_get_entryPtr = _lookup< - ffi.NativeFunction< - spine_skin_entry Function( - spine_skin_entries, ffi.Int32)>>('spine_skin_entries_get_entry'); + late final _spine_skin_entries_get_entryPtr = + _lookup>( + 'spine_skin_entries_get_entry', + ); late final _spine_skin_entries_get_entry = _spine_skin_entries_get_entryPtr .asFunction(); - void spine_skin_entries_dispose( - spine_skin_entries entries, - ) { - return _spine_skin_entries_dispose( - entries, - ); + void spine_skin_entries_dispose(spine_skin_entries entries) { + return _spine_skin_entries_dispose(entries); } - late final _spine_skin_entries_disposePtr = - _lookup>( - 'spine_skin_entries_dispose'); + late final _spine_skin_entries_disposePtr = _lookup>( + 'spine_skin_entries_dispose', + ); late final _spine_skin_entries_dispose = _spine_skin_entries_disposePtr .asFunction(); - int spine_skin_entry_get_slot_index( - spine_skin_entry entry, - ) { - return _spine_skin_entry_get_slot_index( - entry, - ); + int spine_skin_entry_get_slot_index(spine_skin_entry entry) { + return _spine_skin_entry_get_slot_index(entry); } - late final _spine_skin_entry_get_slot_indexPtr = - _lookup>( - 'spine_skin_entry_get_slot_index'); - late final _spine_skin_entry_get_slot_index = - _spine_skin_entry_get_slot_indexPtr - .asFunction(); + late final _spine_skin_entry_get_slot_indexPtr = _lookup>( + 'spine_skin_entry_get_slot_index', + ); + late final _spine_skin_entry_get_slot_index = _spine_skin_entry_get_slot_indexPtr + .asFunction(); - ffi.Pointer spine_skin_entry_get_name( - spine_skin_entry entry, - ) { - return _spine_skin_entry_get_name( - entry, - ); + ffi.Pointer spine_skin_entry_get_name(spine_skin_entry entry) { + return _spine_skin_entry_get_name(entry); } - late final _spine_skin_entry_get_namePtr = - _lookup Function(spine_skin_entry)>>( - 'spine_skin_entry_get_name'); + late final _spine_skin_entry_get_namePtr = _lookup Function(spine_skin_entry)>>( + 'spine_skin_entry_get_name', + ); late final _spine_skin_entry_get_name = _spine_skin_entry_get_namePtr .asFunction Function(spine_skin_entry)>(); - spine_attachment spine_skin_entry_get_attachment( - spine_skin_entry entry, - ) { - return _spine_skin_entry_get_attachment( - entry, - ); + spine_attachment spine_skin_entry_get_attachment(spine_skin_entry entry) { + return _spine_skin_entry_get_attachment(entry); } late final _spine_skin_entry_get_attachmentPtr = - _lookup>( - 'spine_skin_entry_get_attachment'); - late final _spine_skin_entry_get_attachment = - _spine_skin_entry_get_attachmentPtr - .asFunction(); + _lookup>('spine_skin_entry_get_attachment'); + late final _spine_skin_entry_get_attachment = _spine_skin_entry_get_attachmentPtr + .asFunction(); - int spine_skin_get_num_bones( - spine_skin skin, - ) { - return _spine_skin_get_num_bones( - skin, - ); + int spine_skin_get_num_bones(spine_skin skin) { + return _spine_skin_get_num_bones(skin); } - late final _spine_skin_get_num_bonesPtr = - _lookup>( - 'spine_skin_get_num_bones'); - late final _spine_skin_get_num_bones = - _spine_skin_get_num_bonesPtr.asFunction(); + late final _spine_skin_get_num_bonesPtr = _lookup>( + 'spine_skin_get_num_bones', + ); + late final _spine_skin_get_num_bones = _spine_skin_get_num_bonesPtr.asFunction(); - ffi.Pointer spine_skin_get_bones( - spine_skin skin, - ) { - return _spine_skin_get_bones( - skin, - ); + ffi.Pointer spine_skin_get_bones(spine_skin skin) { + return _spine_skin_get_bones(skin); } - late final _spine_skin_get_bonesPtr = _lookup< - ffi - .NativeFunction Function(spine_skin)>>( - 'spine_skin_get_bones'); + late final _spine_skin_get_bonesPtr = _lookup Function(spine_skin)>>( + 'spine_skin_get_bones', + ); late final _spine_skin_get_bones = _spine_skin_get_bonesPtr .asFunction Function(spine_skin)>(); - int spine_skin_get_num_constraints( - spine_skin skin, - ) { - return _spine_skin_get_num_constraints( - skin, - ); + int spine_skin_get_num_constraints(spine_skin skin) { + return _spine_skin_get_num_constraints(skin); } - late final _spine_skin_get_num_constraintsPtr = - _lookup>( - 'spine_skin_get_num_constraints'); - late final _spine_skin_get_num_constraints = - _spine_skin_get_num_constraintsPtr.asFunction(); + late final _spine_skin_get_num_constraintsPtr = _lookup>( + 'spine_skin_get_num_constraints', + ); + late final _spine_skin_get_num_constraints = _spine_skin_get_num_constraintsPtr + .asFunction(); - ffi.Pointer spine_skin_get_constraints( - spine_skin skin, - ) { - return _spine_skin_get_constraints( - skin, - ); + ffi.Pointer spine_skin_get_constraints(spine_skin skin) { + return _spine_skin_get_constraints(skin); } - late final _spine_skin_get_constraintsPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_skin)>>('spine_skin_get_constraints'); + late final _spine_skin_get_constraintsPtr = + _lookup Function(spine_skin)>>( + 'spine_skin_get_constraints', + ); late final _spine_skin_get_constraints = _spine_skin_get_constraintsPtr .asFunction Function(spine_skin)>(); - spine_skin spine_skin_create( - ffi.Pointer name, - ) { - return _spine_skin_create( - name, - ); + spine_skin spine_skin_create(ffi.Pointer name) { + return _spine_skin_create(name); } - late final _spine_skin_createPtr = - _lookup)>>( - 'spine_skin_create'); - late final _spine_skin_create = _spine_skin_createPtr - .asFunction)>(); + late final _spine_skin_createPtr = _lookup)>>( + 'spine_skin_create', + ); + late final _spine_skin_create = _spine_skin_createPtr.asFunction)>(); - void spine_skin_dispose( - spine_skin skin, - ) { - return _spine_skin_dispose( - skin, - ); + void spine_skin_dispose(spine_skin skin) { + return _spine_skin_dispose(skin); } - late final _spine_skin_disposePtr = - _lookup>( - 'spine_skin_dispose'); - late final _spine_skin_dispose = - _spine_skin_disposePtr.asFunction(); + late final _spine_skin_disposePtr = _lookup>('spine_skin_dispose'); + late final _spine_skin_dispose = _spine_skin_disposePtr.asFunction(); - int spine_constraint_data_get_type( - spine_constraint_data data, - ) { - return _spine_constraint_data_get_type( - data, - ); + int spine_constraint_data_get_type(spine_constraint_data data) { + return _spine_constraint_data_get_type(data); } late final _spine_constraint_data_get_typePtr = - _lookup>( - 'spine_constraint_data_get_type'); - late final _spine_constraint_data_get_type = - _spine_constraint_data_get_typePtr - .asFunction(); + _lookup>('spine_constraint_data_get_type'); + late final _spine_constraint_data_get_type = _spine_constraint_data_get_typePtr + .asFunction(); - ffi.Pointer spine_constraint_data_get_name( - spine_constraint_data data, - ) { - return _spine_constraint_data_get_name( - data, - ); + ffi.Pointer spine_constraint_data_get_name(spine_constraint_data data) { + return _spine_constraint_data_get_name(data); } - late final _spine_constraint_data_get_namePtr = _lookup< - ffi - .NativeFunction Function(spine_constraint_data)>>( - 'spine_constraint_data_get_name'); - late final _spine_constraint_data_get_name = - _spine_constraint_data_get_namePtr - .asFunction Function(spine_constraint_data)>(); + late final _spine_constraint_data_get_namePtr = + _lookup Function(spine_constraint_data)>>('spine_constraint_data_get_name'); + late final _spine_constraint_data_get_name = _spine_constraint_data_get_namePtr + .asFunction Function(spine_constraint_data)>(); - int spine_constraint_data_get_order( - spine_constraint_data data, - ) { - return _spine_constraint_data_get_order( - data, - ); + int spine_constraint_data_get_order(spine_constraint_data data) { + return _spine_constraint_data_get_order(data); } late final _spine_constraint_data_get_orderPtr = - _lookup>( - 'spine_constraint_data_get_order'); - late final _spine_constraint_data_get_order = - _spine_constraint_data_get_orderPtr - .asFunction(); + _lookup>('spine_constraint_data_get_order'); + late final _spine_constraint_data_get_order = _spine_constraint_data_get_orderPtr + .asFunction(); - void spine_constraint_data_set_order( - spine_constraint_data data, - int order, - ) { - return _spine_constraint_data_set_order( - data, - order, - ); + void spine_constraint_data_set_order(spine_constraint_data data, int order) { + return _spine_constraint_data_set_order(data, order); } - late final _spine_constraint_data_set_orderPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_constraint_data, - ffi.Uint64)>>('spine_constraint_data_set_order'); - late final _spine_constraint_data_set_order = - _spine_constraint_data_set_orderPtr - .asFunction(); + late final _spine_constraint_data_set_orderPtr = + _lookup>( + 'spine_constraint_data_set_order', + ); + late final _spine_constraint_data_set_order = _spine_constraint_data_set_orderPtr + .asFunction(); - int spine_constraint_data_get_is_skin_required( - spine_constraint_data data, - ) { - return _spine_constraint_data_get_is_skin_required( - data, - ); + int spine_constraint_data_get_is_skin_required(spine_constraint_data data) { + return _spine_constraint_data_get_is_skin_required(data); } late final _spine_constraint_data_get_is_skin_requiredPtr = _lookup>( - 'spine_constraint_data_get_is_skin_required'); - late final _spine_constraint_data_get_is_skin_required = - _spine_constraint_data_get_is_skin_requiredPtr - .asFunction(); + 'spine_constraint_data_get_is_skin_required', + ); + late final _spine_constraint_data_get_is_skin_required = _spine_constraint_data_get_is_skin_requiredPtr + .asFunction(); - void spine_constraint_data_set_is_skin_required( - spine_constraint_data data, - int isSkinRequired, - ) { - return _spine_constraint_data_set_is_skin_required( - data, - isSkinRequired, - ); + void spine_constraint_data_set_is_skin_required(spine_constraint_data data, int isSkinRequired) { + return _spine_constraint_data_set_is_skin_required(data, isSkinRequired); } - late final _spine_constraint_data_set_is_skin_requiredPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_constraint_data, - spine_bool)>>('spine_constraint_data_set_is_skin_required'); - late final _spine_constraint_data_set_is_skin_required = - _spine_constraint_data_set_is_skin_requiredPtr - .asFunction(); + late final _spine_constraint_data_set_is_skin_requiredPtr = + _lookup>( + 'spine_constraint_data_set_is_skin_required', + ); + late final _spine_constraint_data_set_is_skin_required = _spine_constraint_data_set_is_skin_requiredPtr + .asFunction(); - int spine_ik_constraint_data_get_num_bones( - spine_ik_constraint_data data, - ) { - return _spine_ik_constraint_data_get_num_bones( - data, - ); + int spine_ik_constraint_data_get_num_bones(spine_ik_constraint_data data) { + return _spine_ik_constraint_data_get_num_bones(data); } late final _spine_ik_constraint_data_get_num_bonesPtr = _lookup>( - 'spine_ik_constraint_data_get_num_bones'); - late final _spine_ik_constraint_data_get_num_bones = - _spine_ik_constraint_data_get_num_bonesPtr - .asFunction(); + 'spine_ik_constraint_data_get_num_bones', + ); + late final _spine_ik_constraint_data_get_num_bones = _spine_ik_constraint_data_get_num_bonesPtr + .asFunction(); - ffi.Pointer spine_ik_constraint_data_get_bones( - spine_ik_constraint_data data, - ) { - return _spine_ik_constraint_data_get_bones( - data, - ); + ffi.Pointer spine_ik_constraint_data_get_bones(spine_ik_constraint_data data) { + return _spine_ik_constraint_data_get_bones(data); } - late final _spine_ik_constraint_data_get_bonesPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_ik_constraint_data)>>('spine_ik_constraint_data_get_bones'); - late final _spine_ik_constraint_data_get_bones = - _spine_ik_constraint_data_get_bonesPtr.asFunction< - ffi.Pointer Function(spine_ik_constraint_data)>(); + late final _spine_ik_constraint_data_get_bonesPtr = + _lookup Function(spine_ik_constraint_data)>>( + 'spine_ik_constraint_data_get_bones', + ); + late final _spine_ik_constraint_data_get_bones = _spine_ik_constraint_data_get_bonesPtr + .asFunction Function(spine_ik_constraint_data)>(); - spine_bone_data spine_ik_constraint_data_get_target( - spine_ik_constraint_data data, - ) { - return _spine_ik_constraint_data_get_target( - data, - ); + spine_bone_data spine_ik_constraint_data_get_target(spine_ik_constraint_data data) { + return _spine_ik_constraint_data_get_target(data); } - late final _spine_ik_constraint_data_get_targetPtr = _lookup< - ffi - .NativeFunction>( - 'spine_ik_constraint_data_get_target'); - late final _spine_ik_constraint_data_get_target = - _spine_ik_constraint_data_get_targetPtr - .asFunction(); + late final _spine_ik_constraint_data_get_targetPtr = + _lookup>( + 'spine_ik_constraint_data_get_target', + ); + late final _spine_ik_constraint_data_get_target = _spine_ik_constraint_data_get_targetPtr + .asFunction(); - void spine_ik_constraint_data_set_target( - spine_ik_constraint_data data, - spine_bone_data target, - ) { - return _spine_ik_constraint_data_set_target( - data, - target, - ); + void spine_ik_constraint_data_set_target(spine_ik_constraint_data data, spine_bone_data target) { + return _spine_ik_constraint_data_set_target(data, target); } - late final _spine_ik_constraint_data_set_targetPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_ik_constraint_data, - spine_bone_data)>>('spine_ik_constraint_data_set_target'); - late final _spine_ik_constraint_data_set_target = - _spine_ik_constraint_data_set_targetPtr.asFunction< - void Function(spine_ik_constraint_data, spine_bone_data)>(); + late final _spine_ik_constraint_data_set_targetPtr = + _lookup>( + 'spine_ik_constraint_data_set_target', + ); + late final _spine_ik_constraint_data_set_target = _spine_ik_constraint_data_set_targetPtr + .asFunction(); - int spine_ik_constraint_data_get_bend_direction( - spine_ik_constraint_data data, - ) { - return _spine_ik_constraint_data_get_bend_direction( - data, - ); + int spine_ik_constraint_data_get_bend_direction(spine_ik_constraint_data data) { + return _spine_ik_constraint_data_get_bend_direction(data); } late final _spine_ik_constraint_data_get_bend_directionPtr = _lookup>( - 'spine_ik_constraint_data_get_bend_direction'); - late final _spine_ik_constraint_data_get_bend_direction = - _spine_ik_constraint_data_get_bend_directionPtr - .asFunction(); + 'spine_ik_constraint_data_get_bend_direction', + ); + late final _spine_ik_constraint_data_get_bend_direction = _spine_ik_constraint_data_get_bend_directionPtr + .asFunction(); - void spine_ik_constraint_data_set_bend_direction( - spine_ik_constraint_data data, - int bendDirection, - ) { - return _spine_ik_constraint_data_set_bend_direction( - data, - bendDirection, - ); + void spine_ik_constraint_data_set_bend_direction(spine_ik_constraint_data data, int bendDirection) { + return _spine_ik_constraint_data_set_bend_direction(data, bendDirection); } - late final _spine_ik_constraint_data_set_bend_directionPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_ik_constraint_data, - ffi.Int32)>>('spine_ik_constraint_data_set_bend_direction'); - late final _spine_ik_constraint_data_set_bend_direction = - _spine_ik_constraint_data_set_bend_directionPtr - .asFunction(); + late final _spine_ik_constraint_data_set_bend_directionPtr = + _lookup>( + 'spine_ik_constraint_data_set_bend_direction', + ); + late final _spine_ik_constraint_data_set_bend_direction = _spine_ik_constraint_data_set_bend_directionPtr + .asFunction(); - int spine_ik_constraint_data_get_compress( - spine_ik_constraint_data data, - ) { - return _spine_ik_constraint_data_get_compress( - data, - ); + int spine_ik_constraint_data_get_compress(spine_ik_constraint_data data) { + return _spine_ik_constraint_data_get_compress(data); } - late final _spine_ik_constraint_data_get_compressPtr = _lookup< - ffi.NativeFunction>( - 'spine_ik_constraint_data_get_compress'); - late final _spine_ik_constraint_data_get_compress = - _spine_ik_constraint_data_get_compressPtr - .asFunction(); + late final _spine_ik_constraint_data_get_compressPtr = + _lookup>( + 'spine_ik_constraint_data_get_compress', + ); + late final _spine_ik_constraint_data_get_compress = _spine_ik_constraint_data_get_compressPtr + .asFunction(); - void spine_ik_constraint_data_set_compress( - spine_ik_constraint_data data, - int compress, - ) { - return _spine_ik_constraint_data_set_compress( - data, - compress, - ); + void spine_ik_constraint_data_set_compress(spine_ik_constraint_data data, int compress) { + return _spine_ik_constraint_data_set_compress(data, compress); } - late final _spine_ik_constraint_data_set_compressPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_ik_constraint_data, - spine_bool)>>('spine_ik_constraint_data_set_compress'); - late final _spine_ik_constraint_data_set_compress = - _spine_ik_constraint_data_set_compressPtr - .asFunction(); + late final _spine_ik_constraint_data_set_compressPtr = + _lookup>( + 'spine_ik_constraint_data_set_compress', + ); + late final _spine_ik_constraint_data_set_compress = _spine_ik_constraint_data_set_compressPtr + .asFunction(); - int spine_ik_constraint_data_get_stretch( - spine_ik_constraint_data data, - ) { - return _spine_ik_constraint_data_get_stretch( - data, - ); + int spine_ik_constraint_data_get_stretch(spine_ik_constraint_data data) { + return _spine_ik_constraint_data_get_stretch(data); } - late final _spine_ik_constraint_data_get_stretchPtr = _lookup< - ffi.NativeFunction>( - 'spine_ik_constraint_data_get_stretch'); - late final _spine_ik_constraint_data_get_stretch = - _spine_ik_constraint_data_get_stretchPtr - .asFunction(); + late final _spine_ik_constraint_data_get_stretchPtr = + _lookup>( + 'spine_ik_constraint_data_get_stretch', + ); + late final _spine_ik_constraint_data_get_stretch = _spine_ik_constraint_data_get_stretchPtr + .asFunction(); - void spine_ik_constraint_data_set_stretch( - spine_ik_constraint_data data, - int stretch, - ) { - return _spine_ik_constraint_data_set_stretch( - data, - stretch, - ); + void spine_ik_constraint_data_set_stretch(spine_ik_constraint_data data, int stretch) { + return _spine_ik_constraint_data_set_stretch(data, stretch); } - late final _spine_ik_constraint_data_set_stretchPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_ik_constraint_data, - spine_bool)>>('spine_ik_constraint_data_set_stretch'); - late final _spine_ik_constraint_data_set_stretch = - _spine_ik_constraint_data_set_stretchPtr - .asFunction(); + late final _spine_ik_constraint_data_set_stretchPtr = + _lookup>( + 'spine_ik_constraint_data_set_stretch', + ); + late final _spine_ik_constraint_data_set_stretch = _spine_ik_constraint_data_set_stretchPtr + .asFunction(); - int spine_ik_constraint_data_get_uniform( - spine_ik_constraint_data data, - ) { - return _spine_ik_constraint_data_get_uniform( - data, - ); + int spine_ik_constraint_data_get_uniform(spine_ik_constraint_data data) { + return _spine_ik_constraint_data_get_uniform(data); } - late final _spine_ik_constraint_data_get_uniformPtr = _lookup< - ffi.NativeFunction>( - 'spine_ik_constraint_data_get_uniform'); - late final _spine_ik_constraint_data_get_uniform = - _spine_ik_constraint_data_get_uniformPtr - .asFunction(); + late final _spine_ik_constraint_data_get_uniformPtr = + _lookup>( + 'spine_ik_constraint_data_get_uniform', + ); + late final _spine_ik_constraint_data_get_uniform = _spine_ik_constraint_data_get_uniformPtr + .asFunction(); - void spine_ik_constraint_data_set_uniform( - spine_ik_constraint_data data, - int uniform, - ) { - return _spine_ik_constraint_data_set_uniform( - data, - uniform, - ); + void spine_ik_constraint_data_set_uniform(spine_ik_constraint_data data, int uniform) { + return _spine_ik_constraint_data_set_uniform(data, uniform); } - late final _spine_ik_constraint_data_set_uniformPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_ik_constraint_data, - spine_bool)>>('spine_ik_constraint_data_set_uniform'); - late final _spine_ik_constraint_data_set_uniform = - _spine_ik_constraint_data_set_uniformPtr - .asFunction(); + late final _spine_ik_constraint_data_set_uniformPtr = + _lookup>( + 'spine_ik_constraint_data_set_uniform', + ); + late final _spine_ik_constraint_data_set_uniform = _spine_ik_constraint_data_set_uniformPtr + .asFunction(); - double spine_ik_constraint_data_get_mix( - spine_ik_constraint_data data, - ) { - return _spine_ik_constraint_data_get_mix( - data, - ); + double spine_ik_constraint_data_get_mix(spine_ik_constraint_data data) { + return _spine_ik_constraint_data_get_mix(data); } late final _spine_ik_constraint_data_get_mixPtr = - _lookup>( - 'spine_ik_constraint_data_get_mix'); - late final _spine_ik_constraint_data_get_mix = - _spine_ik_constraint_data_get_mixPtr - .asFunction(); + _lookup>('spine_ik_constraint_data_get_mix'); + late final _spine_ik_constraint_data_get_mix = _spine_ik_constraint_data_get_mixPtr + .asFunction(); - void spine_ik_constraint_data_set_mix( - spine_ik_constraint_data data, - double mix, - ) { - return _spine_ik_constraint_data_set_mix( - data, - mix, - ); + void spine_ik_constraint_data_set_mix(spine_ik_constraint_data data, double mix) { + return _spine_ik_constraint_data_set_mix(data, mix); } - late final _spine_ik_constraint_data_set_mixPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_ik_constraint_data, - ffi.Float)>>('spine_ik_constraint_data_set_mix'); - late final _spine_ik_constraint_data_set_mix = - _spine_ik_constraint_data_set_mixPtr - .asFunction(); + late final _spine_ik_constraint_data_set_mixPtr = + _lookup>( + 'spine_ik_constraint_data_set_mix', + ); + late final _spine_ik_constraint_data_set_mix = _spine_ik_constraint_data_set_mixPtr + .asFunction(); - double spine_ik_constraint_data_get_softness( - spine_ik_constraint_data data, - ) { - return _spine_ik_constraint_data_get_softness( - data, - ); + double spine_ik_constraint_data_get_softness(spine_ik_constraint_data data) { + return _spine_ik_constraint_data_get_softness(data); } late final _spine_ik_constraint_data_get_softnessPtr = _lookup>( - 'spine_ik_constraint_data_get_softness'); - late final _spine_ik_constraint_data_get_softness = - _spine_ik_constraint_data_get_softnessPtr - .asFunction(); + 'spine_ik_constraint_data_get_softness', + ); + late final _spine_ik_constraint_data_get_softness = _spine_ik_constraint_data_get_softnessPtr + .asFunction(); - void spine_ik_constraint_data_set_softness( - spine_ik_constraint_data data, - double softness, - ) { - return _spine_ik_constraint_data_set_softness( - data, - softness, - ); + void spine_ik_constraint_data_set_softness(spine_ik_constraint_data data, double softness) { + return _spine_ik_constraint_data_set_softness(data, softness); } - late final _spine_ik_constraint_data_set_softnessPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_ik_constraint_data, - ffi.Float)>>('spine_ik_constraint_data_set_softness'); - late final _spine_ik_constraint_data_set_softness = - _spine_ik_constraint_data_set_softnessPtr - .asFunction(); + late final _spine_ik_constraint_data_set_softnessPtr = + _lookup>( + 'spine_ik_constraint_data_set_softness', + ); + late final _spine_ik_constraint_data_set_softness = _spine_ik_constraint_data_set_softnessPtr + .asFunction(); - void spine_ik_constraint_update( - spine_ik_constraint constraint, - ) { - return _spine_ik_constraint_update( - constraint, - ); + void spine_ik_constraint_update(spine_ik_constraint constraint) { + return _spine_ik_constraint_update(constraint); } - late final _spine_ik_constraint_updatePtr = - _lookup>( - 'spine_ik_constraint_update'); + late final _spine_ik_constraint_updatePtr = _lookup>( + 'spine_ik_constraint_update', + ); late final _spine_ik_constraint_update = _spine_ik_constraint_updatePtr .asFunction(); - int spine_ik_constraint_get_order( - spine_ik_constraint constraint, - ) { - return _spine_ik_constraint_get_order( - constraint, - ); + int spine_ik_constraint_get_order(spine_ik_constraint constraint) { + return _spine_ik_constraint_get_order(constraint); } - late final _spine_ik_constraint_get_orderPtr = - _lookup>( - 'spine_ik_constraint_get_order'); + late final _spine_ik_constraint_get_orderPtr = _lookup>( + 'spine_ik_constraint_get_order', + ); late final _spine_ik_constraint_get_order = _spine_ik_constraint_get_orderPtr .asFunction(); - spine_ik_constraint_data spine_ik_constraint_get_data( - spine_ik_constraint constraint, - ) { - return _spine_ik_constraint_get_data( - constraint, - ); + spine_ik_constraint_data spine_ik_constraint_get_data(spine_ik_constraint constraint) { + return _spine_ik_constraint_get_data(constraint); } - late final _spine_ik_constraint_get_dataPtr = _lookup< - ffi.NativeFunction< - spine_ik_constraint_data Function( - spine_ik_constraint)>>('spine_ik_constraint_get_data'); + late final _spine_ik_constraint_get_dataPtr = + _lookup>( + 'spine_ik_constraint_get_data', + ); late final _spine_ik_constraint_get_data = _spine_ik_constraint_get_dataPtr .asFunction(); - int spine_ik_constraint_get_num_bones( - spine_ik_constraint constraint, - ) { - return _spine_ik_constraint_get_num_bones( - constraint, - ); + int spine_ik_constraint_get_num_bones(spine_ik_constraint constraint) { + return _spine_ik_constraint_get_num_bones(constraint); } late final _spine_ik_constraint_get_num_bonesPtr = - _lookup>( - 'spine_ik_constraint_get_num_bones'); - late final _spine_ik_constraint_get_num_bones = - _spine_ik_constraint_get_num_bonesPtr - .asFunction(); + _lookup>('spine_ik_constraint_get_num_bones'); + late final _spine_ik_constraint_get_num_bones = _spine_ik_constraint_get_num_bonesPtr + .asFunction(); - ffi.Pointer spine_ik_constraint_get_bones( - spine_ik_constraint constraint, - ) { - return _spine_ik_constraint_get_bones( - constraint, - ); + ffi.Pointer spine_ik_constraint_get_bones(spine_ik_constraint constraint) { + return _spine_ik_constraint_get_bones(constraint); } - late final _spine_ik_constraint_get_bonesPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_ik_constraint)>>('spine_ik_constraint_get_bones'); + late final _spine_ik_constraint_get_bonesPtr = + _lookup Function(spine_ik_constraint)>>( + 'spine_ik_constraint_get_bones', + ); late final _spine_ik_constraint_get_bones = _spine_ik_constraint_get_bonesPtr .asFunction Function(spine_ik_constraint)>(); - spine_bone spine_ik_constraint_get_target( - spine_ik_constraint constraint, - ) { - return _spine_ik_constraint_get_target( - constraint, - ); + spine_bone spine_ik_constraint_get_target(spine_ik_constraint constraint) { + return _spine_ik_constraint_get_target(constraint); } - late final _spine_ik_constraint_get_targetPtr = - _lookup>( - 'spine_ik_constraint_get_target'); - late final _spine_ik_constraint_get_target = - _spine_ik_constraint_get_targetPtr - .asFunction(); + late final _spine_ik_constraint_get_targetPtr = _lookup>( + 'spine_ik_constraint_get_target', + ); + late final _spine_ik_constraint_get_target = _spine_ik_constraint_get_targetPtr + .asFunction(); - void spine_ik_constraint_set_target( - spine_ik_constraint constraint, - spine_bone target, - ) { - return _spine_ik_constraint_set_target( - constraint, - target, - ); + void spine_ik_constraint_set_target(spine_ik_constraint constraint, spine_bone target) { + return _spine_ik_constraint_set_target(constraint, target); } - late final _spine_ik_constraint_set_targetPtr = _lookup< - ffi - .NativeFunction>( - 'spine_ik_constraint_set_target'); - late final _spine_ik_constraint_set_target = - _spine_ik_constraint_set_targetPtr - .asFunction(); + late final _spine_ik_constraint_set_targetPtr = + _lookup>('spine_ik_constraint_set_target'); + late final _spine_ik_constraint_set_target = _spine_ik_constraint_set_targetPtr + .asFunction(); - int spine_ik_constraint_get_bend_direction( - spine_ik_constraint constraint, - ) { - return _spine_ik_constraint_get_bend_direction( - constraint, - ); + int spine_ik_constraint_get_bend_direction(spine_ik_constraint constraint) { + return _spine_ik_constraint_get_bend_direction(constraint); } late final _spine_ik_constraint_get_bend_directionPtr = - _lookup>( - 'spine_ik_constraint_get_bend_direction'); - late final _spine_ik_constraint_get_bend_direction = - _spine_ik_constraint_get_bend_directionPtr - .asFunction(); + _lookup>('spine_ik_constraint_get_bend_direction'); + late final _spine_ik_constraint_get_bend_direction = _spine_ik_constraint_get_bend_directionPtr + .asFunction(); - void spine_ik_constraint_set_bend_direction( - spine_ik_constraint constraint, - int bendDirection, - ) { - return _spine_ik_constraint_set_bend_direction( - constraint, - bendDirection, - ); + void spine_ik_constraint_set_bend_direction(spine_ik_constraint constraint, int bendDirection) { + return _spine_ik_constraint_set_bend_direction(constraint, bendDirection); } - late final _spine_ik_constraint_set_bend_directionPtr = _lookup< - ffi - .NativeFunction>( - 'spine_ik_constraint_set_bend_direction'); - late final _spine_ik_constraint_set_bend_direction = - _spine_ik_constraint_set_bend_directionPtr - .asFunction(); + late final _spine_ik_constraint_set_bend_directionPtr = + _lookup>( + 'spine_ik_constraint_set_bend_direction', + ); + late final _spine_ik_constraint_set_bend_direction = _spine_ik_constraint_set_bend_directionPtr + .asFunction(); - int spine_ik_constraint_get_compress( - spine_ik_constraint constraint, - ) { - return _spine_ik_constraint_get_compress( - constraint, - ); + int spine_ik_constraint_get_compress(spine_ik_constraint constraint) { + return _spine_ik_constraint_get_compress(constraint); } late final _spine_ik_constraint_get_compressPtr = - _lookup>( - 'spine_ik_constraint_get_compress'); - late final _spine_ik_constraint_get_compress = - _spine_ik_constraint_get_compressPtr - .asFunction(); + _lookup>('spine_ik_constraint_get_compress'); + late final _spine_ik_constraint_get_compress = _spine_ik_constraint_get_compressPtr + .asFunction(); - void spine_ik_constraint_set_compress( - spine_ik_constraint constraint, - int compress, - ) { - return _spine_ik_constraint_set_compress( - constraint, - compress, - ); + void spine_ik_constraint_set_compress(spine_ik_constraint constraint, int compress) { + return _spine_ik_constraint_set_compress(constraint, compress); } - late final _spine_ik_constraint_set_compressPtr = _lookup< - ffi - .NativeFunction>( - 'spine_ik_constraint_set_compress'); - late final _spine_ik_constraint_set_compress = - _spine_ik_constraint_set_compressPtr - .asFunction(); + late final _spine_ik_constraint_set_compressPtr = + _lookup>( + 'spine_ik_constraint_set_compress', + ); + late final _spine_ik_constraint_set_compress = _spine_ik_constraint_set_compressPtr + .asFunction(); - int spine_ik_constraint_get_stretch( - spine_ik_constraint constraint, - ) { - return _spine_ik_constraint_get_stretch( - constraint, - ); + int spine_ik_constraint_get_stretch(spine_ik_constraint constraint) { + return _spine_ik_constraint_get_stretch(constraint); } late final _spine_ik_constraint_get_stretchPtr = - _lookup>( - 'spine_ik_constraint_get_stretch'); - late final _spine_ik_constraint_get_stretch = - _spine_ik_constraint_get_stretchPtr - .asFunction(); + _lookup>('spine_ik_constraint_get_stretch'); + late final _spine_ik_constraint_get_stretch = _spine_ik_constraint_get_stretchPtr + .asFunction(); - void spine_ik_constraint_set_stretch( - spine_ik_constraint constraint, - int stretch, - ) { - return _spine_ik_constraint_set_stretch( - constraint, - stretch, - ); + void spine_ik_constraint_set_stretch(spine_ik_constraint constraint, int stretch) { + return _spine_ik_constraint_set_stretch(constraint, stretch); } - late final _spine_ik_constraint_set_stretchPtr = _lookup< - ffi - .NativeFunction>( - 'spine_ik_constraint_set_stretch'); - late final _spine_ik_constraint_set_stretch = - _spine_ik_constraint_set_stretchPtr - .asFunction(); + late final _spine_ik_constraint_set_stretchPtr = + _lookup>( + 'spine_ik_constraint_set_stretch', + ); + late final _spine_ik_constraint_set_stretch = _spine_ik_constraint_set_stretchPtr + .asFunction(); - double spine_ik_constraint_get_mix( - spine_ik_constraint constraint, - ) { - return _spine_ik_constraint_get_mix( - constraint, - ); + double spine_ik_constraint_get_mix(spine_ik_constraint constraint) { + return _spine_ik_constraint_get_mix(constraint); } - late final _spine_ik_constraint_get_mixPtr = - _lookup>( - 'spine_ik_constraint_get_mix'); + late final _spine_ik_constraint_get_mixPtr = _lookup>( + 'spine_ik_constraint_get_mix', + ); late final _spine_ik_constraint_get_mix = _spine_ik_constraint_get_mixPtr .asFunction(); - void spine_ik_constraint_set_mix( - spine_ik_constraint constraint, - double mix, - ) { - return _spine_ik_constraint_set_mix( - constraint, - mix, - ); + void spine_ik_constraint_set_mix(spine_ik_constraint constraint, double mix) { + return _spine_ik_constraint_set_mix(constraint, mix); } - late final _spine_ik_constraint_set_mixPtr = _lookup< - ffi - .NativeFunction>( - 'spine_ik_constraint_set_mix'); + late final _spine_ik_constraint_set_mixPtr = + _lookup>('spine_ik_constraint_set_mix'); late final _spine_ik_constraint_set_mix = _spine_ik_constraint_set_mixPtr .asFunction(); - double spine_ik_constraint_get_softness( - spine_ik_constraint constraint, - ) { - return _spine_ik_constraint_get_softness( - constraint, - ); + double spine_ik_constraint_get_softness(spine_ik_constraint constraint) { + return _spine_ik_constraint_get_softness(constraint); } late final _spine_ik_constraint_get_softnessPtr = - _lookup>( - 'spine_ik_constraint_get_softness'); - late final _spine_ik_constraint_get_softness = - _spine_ik_constraint_get_softnessPtr - .asFunction(); + _lookup>('spine_ik_constraint_get_softness'); + late final _spine_ik_constraint_get_softness = _spine_ik_constraint_get_softnessPtr + .asFunction(); - void spine_ik_constraint_set_softness( - spine_ik_constraint constraint, - double softness, - ) { - return _spine_ik_constraint_set_softness( - constraint, - softness, - ); + void spine_ik_constraint_set_softness(spine_ik_constraint constraint, double softness) { + return _spine_ik_constraint_set_softness(constraint, softness); } - late final _spine_ik_constraint_set_softnessPtr = _lookup< - ffi - .NativeFunction>( - 'spine_ik_constraint_set_softness'); - late final _spine_ik_constraint_set_softness = - _spine_ik_constraint_set_softnessPtr - .asFunction(); + late final _spine_ik_constraint_set_softnessPtr = + _lookup>( + 'spine_ik_constraint_set_softness', + ); + late final _spine_ik_constraint_set_softness = _spine_ik_constraint_set_softnessPtr + .asFunction(); - int spine_ik_constraint_get_is_active( - spine_ik_constraint constraint, - ) { - return _spine_ik_constraint_get_is_active( - constraint, - ); + int spine_ik_constraint_get_is_active(spine_ik_constraint constraint) { + return _spine_ik_constraint_get_is_active(constraint); } late final _spine_ik_constraint_get_is_activePtr = - _lookup>( - 'spine_ik_constraint_get_is_active'); - late final _spine_ik_constraint_get_is_active = - _spine_ik_constraint_get_is_activePtr - .asFunction(); + _lookup>('spine_ik_constraint_get_is_active'); + late final _spine_ik_constraint_get_is_active = _spine_ik_constraint_get_is_activePtr + .asFunction(); - void spine_ik_constraint_set_is_active( - spine_ik_constraint constraint, - int isActive, - ) { - return _spine_ik_constraint_set_is_active( - constraint, - isActive, - ); + void spine_ik_constraint_set_is_active(spine_ik_constraint constraint, int isActive) { + return _spine_ik_constraint_set_is_active(constraint, isActive); } - late final _spine_ik_constraint_set_is_activePtr = _lookup< - ffi - .NativeFunction>( - 'spine_ik_constraint_set_is_active'); - late final _spine_ik_constraint_set_is_active = - _spine_ik_constraint_set_is_activePtr - .asFunction(); + late final _spine_ik_constraint_set_is_activePtr = + _lookup>( + 'spine_ik_constraint_set_is_active', + ); + late final _spine_ik_constraint_set_is_active = _spine_ik_constraint_set_is_activePtr + .asFunction(); /// OMITTED setToSetupPose() - int spine_transform_constraint_data_get_num_bones( - spine_transform_constraint_data data, - ) { - return _spine_transform_constraint_data_get_num_bones( - data, - ); + int spine_transform_constraint_data_get_num_bones(spine_transform_constraint_data data) { + return _spine_transform_constraint_data_get_num_bones(data); } - late final _spine_transform_constraint_data_get_num_bonesPtr = _lookup< - ffi - .NativeFunction>( - 'spine_transform_constraint_data_get_num_bones'); - late final _spine_transform_constraint_data_get_num_bones = - _spine_transform_constraint_data_get_num_bonesPtr - .asFunction(); + late final _spine_transform_constraint_data_get_num_bonesPtr = + _lookup>( + 'spine_transform_constraint_data_get_num_bones', + ); + late final _spine_transform_constraint_data_get_num_bones = _spine_transform_constraint_data_get_num_bonesPtr + .asFunction(); - ffi.Pointer spine_transform_constraint_data_get_bones( - spine_transform_constraint_data data, - ) { - return _spine_transform_constraint_data_get_bones( - data, - ); + ffi.Pointer spine_transform_constraint_data_get_bones(spine_transform_constraint_data data) { + return _spine_transform_constraint_data_get_bones(data); } - late final _spine_transform_constraint_data_get_bonesPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_transform_constraint_data)>>( - 'spine_transform_constraint_data_get_bones'); - late final _spine_transform_constraint_data_get_bones = - _spine_transform_constraint_data_get_bonesPtr.asFunction< - ffi.Pointer Function( - spine_transform_constraint_data)>(); + late final _spine_transform_constraint_data_get_bonesPtr = + _lookup Function(spine_transform_constraint_data)>>( + 'spine_transform_constraint_data_get_bones', + ); + late final _spine_transform_constraint_data_get_bones = _spine_transform_constraint_data_get_bonesPtr + .asFunction Function(spine_transform_constraint_data)>(); - spine_bone_data spine_transform_constraint_data_get_target( - spine_transform_constraint_data data, - ) { - return _spine_transform_constraint_data_get_target( - data, - ); + spine_bone_data spine_transform_constraint_data_get_target(spine_transform_constraint_data data) { + return _spine_transform_constraint_data_get_target(data); } - late final _spine_transform_constraint_data_get_targetPtr = _lookup< - ffi.NativeFunction< - spine_bone_data Function(spine_transform_constraint_data)>>( - 'spine_transform_constraint_data_get_target'); - late final _spine_transform_constraint_data_get_target = - _spine_transform_constraint_data_get_targetPtr.asFunction< - spine_bone_data Function(spine_transform_constraint_data)>(); + late final _spine_transform_constraint_data_get_targetPtr = + _lookup>( + 'spine_transform_constraint_data_get_target', + ); + late final _spine_transform_constraint_data_get_target = _spine_transform_constraint_data_get_targetPtr + .asFunction(); - void spine_transform_constraint_data_set_target( - spine_transform_constraint_data data, - spine_bone_data target, - ) { - return _spine_transform_constraint_data_set_target( - data, - target, - ); + void spine_transform_constraint_data_set_target(spine_transform_constraint_data data, spine_bone_data target) { + return _spine_transform_constraint_data_set_target(data, target); } - late final _spine_transform_constraint_data_set_targetPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_transform_constraint_data, - spine_bone_data)>>('spine_transform_constraint_data_set_target'); - late final _spine_transform_constraint_data_set_target = - _spine_transform_constraint_data_set_targetPtr.asFunction< - void Function(spine_transform_constraint_data, spine_bone_data)>(); + late final _spine_transform_constraint_data_set_targetPtr = + _lookup>( + 'spine_transform_constraint_data_set_target', + ); + late final _spine_transform_constraint_data_set_target = _spine_transform_constraint_data_set_targetPtr + .asFunction(); - double spine_transform_constraint_data_get_mix_rotate( - spine_transform_constraint_data data, - ) { - return _spine_transform_constraint_data_get_mix_rotate( - data, - ); + double spine_transform_constraint_data_get_mix_rotate(spine_transform_constraint_data data) { + return _spine_transform_constraint_data_get_mix_rotate(data); } - late final _spine_transform_constraint_data_get_mix_rotatePtr = _lookup< - ffi - .NativeFunction>( - 'spine_transform_constraint_data_get_mix_rotate'); - late final _spine_transform_constraint_data_get_mix_rotate = - _spine_transform_constraint_data_get_mix_rotatePtr - .asFunction(); + late final _spine_transform_constraint_data_get_mix_rotatePtr = + _lookup>( + 'spine_transform_constraint_data_get_mix_rotate', + ); + late final _spine_transform_constraint_data_get_mix_rotate = _spine_transform_constraint_data_get_mix_rotatePtr + .asFunction(); - void spine_transform_constraint_data_set_mix_rotate( - spine_transform_constraint_data data, - double mixRotate, - ) { - return _spine_transform_constraint_data_set_mix_rotate( - data, - mixRotate, - ); + void spine_transform_constraint_data_set_mix_rotate(spine_transform_constraint_data data, double mixRotate) { + return _spine_transform_constraint_data_set_mix_rotate(data, mixRotate); } - late final _spine_transform_constraint_data_set_mix_rotatePtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_transform_constraint_data, - ffi.Float)>>('spine_transform_constraint_data_set_mix_rotate'); - late final _spine_transform_constraint_data_set_mix_rotate = - _spine_transform_constraint_data_set_mix_rotatePtr - .asFunction(); + late final _spine_transform_constraint_data_set_mix_rotatePtr = + _lookup>( + 'spine_transform_constraint_data_set_mix_rotate', + ); + late final _spine_transform_constraint_data_set_mix_rotate = _spine_transform_constraint_data_set_mix_rotatePtr + .asFunction(); - double spine_transform_constraint_data_get_mix_x( - spine_transform_constraint_data data, - ) { - return _spine_transform_constraint_data_get_mix_x( - data, - ); + double spine_transform_constraint_data_get_mix_x(spine_transform_constraint_data data) { + return _spine_transform_constraint_data_get_mix_x(data); } - late final _spine_transform_constraint_data_get_mix_xPtr = _lookup< - ffi - .NativeFunction>( - 'spine_transform_constraint_data_get_mix_x'); - late final _spine_transform_constraint_data_get_mix_x = - _spine_transform_constraint_data_get_mix_xPtr - .asFunction(); + late final _spine_transform_constraint_data_get_mix_xPtr = + _lookup>( + 'spine_transform_constraint_data_get_mix_x', + ); + late final _spine_transform_constraint_data_get_mix_x = _spine_transform_constraint_data_get_mix_xPtr + .asFunction(); - void spine_transform_constraint_data_set_mix_x( - spine_transform_constraint_data data, - double mixX, - ) { - return _spine_transform_constraint_data_set_mix_x( - data, - mixX, - ); + void spine_transform_constraint_data_set_mix_x(spine_transform_constraint_data data, double mixX) { + return _spine_transform_constraint_data_set_mix_x(data, mixX); } - late final _spine_transform_constraint_data_set_mix_xPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_transform_constraint_data, - ffi.Float)>>('spine_transform_constraint_data_set_mix_x'); - late final _spine_transform_constraint_data_set_mix_x = - _spine_transform_constraint_data_set_mix_xPtr - .asFunction(); + late final _spine_transform_constraint_data_set_mix_xPtr = + _lookup>( + 'spine_transform_constraint_data_set_mix_x', + ); + late final _spine_transform_constraint_data_set_mix_x = _spine_transform_constraint_data_set_mix_xPtr + .asFunction(); - double spine_transform_constraint_data_get_mix_y( - spine_transform_constraint_data data, - ) { - return _spine_transform_constraint_data_get_mix_y( - data, - ); + double spine_transform_constraint_data_get_mix_y(spine_transform_constraint_data data) { + return _spine_transform_constraint_data_get_mix_y(data); } - late final _spine_transform_constraint_data_get_mix_yPtr = _lookup< - ffi - .NativeFunction>( - 'spine_transform_constraint_data_get_mix_y'); - late final _spine_transform_constraint_data_get_mix_y = - _spine_transform_constraint_data_get_mix_yPtr - .asFunction(); + late final _spine_transform_constraint_data_get_mix_yPtr = + _lookup>( + 'spine_transform_constraint_data_get_mix_y', + ); + late final _spine_transform_constraint_data_get_mix_y = _spine_transform_constraint_data_get_mix_yPtr + .asFunction(); - void spine_transform_constraint_data_set_mix_y( - spine_transform_constraint_data data, - double mixY, - ) { - return _spine_transform_constraint_data_set_mix_y( - data, - mixY, - ); + void spine_transform_constraint_data_set_mix_y(spine_transform_constraint_data data, double mixY) { + return _spine_transform_constraint_data_set_mix_y(data, mixY); } - late final _spine_transform_constraint_data_set_mix_yPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_transform_constraint_data, - ffi.Float)>>('spine_transform_constraint_data_set_mix_y'); - late final _spine_transform_constraint_data_set_mix_y = - _spine_transform_constraint_data_set_mix_yPtr - .asFunction(); + late final _spine_transform_constraint_data_set_mix_yPtr = + _lookup>( + 'spine_transform_constraint_data_set_mix_y', + ); + late final _spine_transform_constraint_data_set_mix_y = _spine_transform_constraint_data_set_mix_yPtr + .asFunction(); - double spine_transform_constraint_data_get_mix_scale_x( - spine_transform_constraint_data data, - ) { - return _spine_transform_constraint_data_get_mix_scale_x( - data, - ); + double spine_transform_constraint_data_get_mix_scale_x(spine_transform_constraint_data data) { + return _spine_transform_constraint_data_get_mix_scale_x(data); } - late final _spine_transform_constraint_data_get_mix_scale_xPtr = _lookup< - ffi - .NativeFunction>( - 'spine_transform_constraint_data_get_mix_scale_x'); - late final _spine_transform_constraint_data_get_mix_scale_x = - _spine_transform_constraint_data_get_mix_scale_xPtr - .asFunction(); + late final _spine_transform_constraint_data_get_mix_scale_xPtr = + _lookup>( + 'spine_transform_constraint_data_get_mix_scale_x', + ); + late final _spine_transform_constraint_data_get_mix_scale_x = _spine_transform_constraint_data_get_mix_scale_xPtr + .asFunction(); - void spine_transform_constraint_data_set_mix_scale_x( - spine_transform_constraint_data data, - double mixScaleX, - ) { - return _spine_transform_constraint_data_set_mix_scale_x( - data, - mixScaleX, - ); + void spine_transform_constraint_data_set_mix_scale_x(spine_transform_constraint_data data, double mixScaleX) { + return _spine_transform_constraint_data_set_mix_scale_x(data, mixScaleX); } - late final _spine_transform_constraint_data_set_mix_scale_xPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_transform_constraint_data, - ffi.Float)>>('spine_transform_constraint_data_set_mix_scale_x'); - late final _spine_transform_constraint_data_set_mix_scale_x = - _spine_transform_constraint_data_set_mix_scale_xPtr - .asFunction(); + late final _spine_transform_constraint_data_set_mix_scale_xPtr = + _lookup>( + 'spine_transform_constraint_data_set_mix_scale_x', + ); + late final _spine_transform_constraint_data_set_mix_scale_x = _spine_transform_constraint_data_set_mix_scale_xPtr + .asFunction(); - double spine_transform_constraint_data_get_mix_scale_y( - spine_transform_constraint_data data, - ) { - return _spine_transform_constraint_data_get_mix_scale_y( - data, - ); + double spine_transform_constraint_data_get_mix_scale_y(spine_transform_constraint_data data) { + return _spine_transform_constraint_data_get_mix_scale_y(data); } - late final _spine_transform_constraint_data_get_mix_scale_yPtr = _lookup< - ffi - .NativeFunction>( - 'spine_transform_constraint_data_get_mix_scale_y'); - late final _spine_transform_constraint_data_get_mix_scale_y = - _spine_transform_constraint_data_get_mix_scale_yPtr - .asFunction(); + late final _spine_transform_constraint_data_get_mix_scale_yPtr = + _lookup>( + 'spine_transform_constraint_data_get_mix_scale_y', + ); + late final _spine_transform_constraint_data_get_mix_scale_y = _spine_transform_constraint_data_get_mix_scale_yPtr + .asFunction(); - void spine_transform_constraint_data_set_mix_scale_y( - spine_transform_constraint_data data, - double mixScaleY, - ) { - return _spine_transform_constraint_data_set_mix_scale_y( - data, - mixScaleY, - ); + void spine_transform_constraint_data_set_mix_scale_y(spine_transform_constraint_data data, double mixScaleY) { + return _spine_transform_constraint_data_set_mix_scale_y(data, mixScaleY); } - late final _spine_transform_constraint_data_set_mix_scale_yPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_transform_constraint_data, - ffi.Float)>>('spine_transform_constraint_data_set_mix_scale_y'); - late final _spine_transform_constraint_data_set_mix_scale_y = - _spine_transform_constraint_data_set_mix_scale_yPtr - .asFunction(); + late final _spine_transform_constraint_data_set_mix_scale_yPtr = + _lookup>( + 'spine_transform_constraint_data_set_mix_scale_y', + ); + late final _spine_transform_constraint_data_set_mix_scale_y = _spine_transform_constraint_data_set_mix_scale_yPtr + .asFunction(); - double spine_transform_constraint_data_get_mix_shear_y( - spine_transform_constraint_data data, - ) { - return _spine_transform_constraint_data_get_mix_shear_y( - data, - ); + double spine_transform_constraint_data_get_mix_shear_y(spine_transform_constraint_data data) { + return _spine_transform_constraint_data_get_mix_shear_y(data); } - late final _spine_transform_constraint_data_get_mix_shear_yPtr = _lookup< - ffi - .NativeFunction>( - 'spine_transform_constraint_data_get_mix_shear_y'); - late final _spine_transform_constraint_data_get_mix_shear_y = - _spine_transform_constraint_data_get_mix_shear_yPtr - .asFunction(); + late final _spine_transform_constraint_data_get_mix_shear_yPtr = + _lookup>( + 'spine_transform_constraint_data_get_mix_shear_y', + ); + late final _spine_transform_constraint_data_get_mix_shear_y = _spine_transform_constraint_data_get_mix_shear_yPtr + .asFunction(); - void spine_transform_constraint_data_set_mix_shear_y( - spine_transform_constraint_data data, - double mixShearY, - ) { - return _spine_transform_constraint_data_set_mix_shear_y( - data, - mixShearY, - ); + void spine_transform_constraint_data_set_mix_shear_y(spine_transform_constraint_data data, double mixShearY) { + return _spine_transform_constraint_data_set_mix_shear_y(data, mixShearY); } - late final _spine_transform_constraint_data_set_mix_shear_yPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_transform_constraint_data, - ffi.Float)>>('spine_transform_constraint_data_set_mix_shear_y'); - late final _spine_transform_constraint_data_set_mix_shear_y = - _spine_transform_constraint_data_set_mix_shear_yPtr - .asFunction(); + late final _spine_transform_constraint_data_set_mix_shear_yPtr = + _lookup>( + 'spine_transform_constraint_data_set_mix_shear_y', + ); + late final _spine_transform_constraint_data_set_mix_shear_y = _spine_transform_constraint_data_set_mix_shear_yPtr + .asFunction(); - double spine_transform_constraint_data_get_offset_rotation( - spine_transform_constraint_data data, - ) { - return _spine_transform_constraint_data_get_offset_rotation( - data, - ); + double spine_transform_constraint_data_get_offset_rotation(spine_transform_constraint_data data) { + return _spine_transform_constraint_data_get_offset_rotation(data); } - late final _spine_transform_constraint_data_get_offset_rotationPtr = _lookup< - ffi - .NativeFunction>( - 'spine_transform_constraint_data_get_offset_rotation'); + late final _spine_transform_constraint_data_get_offset_rotationPtr = + _lookup>( + 'spine_transform_constraint_data_get_offset_rotation', + ); late final _spine_transform_constraint_data_get_offset_rotation = _spine_transform_constraint_data_get_offset_rotationPtr .asFunction(); @@ -8495,3534 +5345,2265 @@ class SpineFlutterBindings { spine_transform_constraint_data data, double offsetRotation, ) { - return _spine_transform_constraint_data_set_offset_rotation( - data, - offsetRotation, - ); + return _spine_transform_constraint_data_set_offset_rotation(data, offsetRotation); } - late final _spine_transform_constraint_data_set_offset_rotationPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_transform_constraint_data, ffi.Float)>>( - 'spine_transform_constraint_data_set_offset_rotation'); + late final _spine_transform_constraint_data_set_offset_rotationPtr = + _lookup>( + 'spine_transform_constraint_data_set_offset_rotation', + ); late final _spine_transform_constraint_data_set_offset_rotation = _spine_transform_constraint_data_set_offset_rotationPtr .asFunction(); - double spine_transform_constraint_data_get_offset_x( - spine_transform_constraint_data data, - ) { - return _spine_transform_constraint_data_get_offset_x( - data, - ); + double spine_transform_constraint_data_get_offset_x(spine_transform_constraint_data data) { + return _spine_transform_constraint_data_get_offset_x(data); } - late final _spine_transform_constraint_data_get_offset_xPtr = _lookup< - ffi - .NativeFunction>( - 'spine_transform_constraint_data_get_offset_x'); - late final _spine_transform_constraint_data_get_offset_x = - _spine_transform_constraint_data_get_offset_xPtr - .asFunction(); + late final _spine_transform_constraint_data_get_offset_xPtr = + _lookup>( + 'spine_transform_constraint_data_get_offset_x', + ); + late final _spine_transform_constraint_data_get_offset_x = _spine_transform_constraint_data_get_offset_xPtr + .asFunction(); - void spine_transform_constraint_data_set_offset_x( - spine_transform_constraint_data data, - double offsetX, - ) { - return _spine_transform_constraint_data_set_offset_x( - data, - offsetX, - ); + void spine_transform_constraint_data_set_offset_x(spine_transform_constraint_data data, double offsetX) { + return _spine_transform_constraint_data_set_offset_x(data, offsetX); } - late final _spine_transform_constraint_data_set_offset_xPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_transform_constraint_data, - ffi.Float)>>('spine_transform_constraint_data_set_offset_x'); - late final _spine_transform_constraint_data_set_offset_x = - _spine_transform_constraint_data_set_offset_xPtr - .asFunction(); + late final _spine_transform_constraint_data_set_offset_xPtr = + _lookup>( + 'spine_transform_constraint_data_set_offset_x', + ); + late final _spine_transform_constraint_data_set_offset_x = _spine_transform_constraint_data_set_offset_xPtr + .asFunction(); - double spine_transform_constraint_data_get_offset_y( - spine_transform_constraint_data data, - ) { - return _spine_transform_constraint_data_get_offset_y( - data, - ); + double spine_transform_constraint_data_get_offset_y(spine_transform_constraint_data data) { + return _spine_transform_constraint_data_get_offset_y(data); } - late final _spine_transform_constraint_data_get_offset_yPtr = _lookup< - ffi - .NativeFunction>( - 'spine_transform_constraint_data_get_offset_y'); - late final _spine_transform_constraint_data_get_offset_y = - _spine_transform_constraint_data_get_offset_yPtr - .asFunction(); + late final _spine_transform_constraint_data_get_offset_yPtr = + _lookup>( + 'spine_transform_constraint_data_get_offset_y', + ); + late final _spine_transform_constraint_data_get_offset_y = _spine_transform_constraint_data_get_offset_yPtr + .asFunction(); - void spine_transform_constraint_data_set_offset_y( - spine_transform_constraint_data data, - double offsetY, - ) { - return _spine_transform_constraint_data_set_offset_y( - data, - offsetY, - ); + void spine_transform_constraint_data_set_offset_y(spine_transform_constraint_data data, double offsetY) { + return _spine_transform_constraint_data_set_offset_y(data, offsetY); } - late final _spine_transform_constraint_data_set_offset_yPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_transform_constraint_data, - ffi.Float)>>('spine_transform_constraint_data_set_offset_y'); - late final _spine_transform_constraint_data_set_offset_y = - _spine_transform_constraint_data_set_offset_yPtr - .asFunction(); + late final _spine_transform_constraint_data_set_offset_yPtr = + _lookup>( + 'spine_transform_constraint_data_set_offset_y', + ); + late final _spine_transform_constraint_data_set_offset_y = _spine_transform_constraint_data_set_offset_yPtr + .asFunction(); - double spine_transform_constraint_data_get_offset_scale_x( - spine_transform_constraint_data data, - ) { - return _spine_transform_constraint_data_get_offset_scale_x( - data, - ); + double spine_transform_constraint_data_get_offset_scale_x(spine_transform_constraint_data data) { + return _spine_transform_constraint_data_get_offset_scale_x(data); } - late final _spine_transform_constraint_data_get_offset_scale_xPtr = _lookup< - ffi - .NativeFunction>( - 'spine_transform_constraint_data_get_offset_scale_x'); + late final _spine_transform_constraint_data_get_offset_scale_xPtr = + _lookup>( + 'spine_transform_constraint_data_get_offset_scale_x', + ); late final _spine_transform_constraint_data_get_offset_scale_x = _spine_transform_constraint_data_get_offset_scale_xPtr .asFunction(); - void spine_transform_constraint_data_set_offset_scale_x( - spine_transform_constraint_data data, - double offsetScaleX, - ) { - return _spine_transform_constraint_data_set_offset_scale_x( - data, - offsetScaleX, - ); + void spine_transform_constraint_data_set_offset_scale_x(spine_transform_constraint_data data, double offsetScaleX) { + return _spine_transform_constraint_data_set_offset_scale_x(data, offsetScaleX); } - late final _spine_transform_constraint_data_set_offset_scale_xPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_transform_constraint_data, ffi.Float)>>( - 'spine_transform_constraint_data_set_offset_scale_x'); + late final _spine_transform_constraint_data_set_offset_scale_xPtr = + _lookup>( + 'spine_transform_constraint_data_set_offset_scale_x', + ); late final _spine_transform_constraint_data_set_offset_scale_x = _spine_transform_constraint_data_set_offset_scale_xPtr .asFunction(); - double spine_transform_constraint_data_get_offset_scale_y( - spine_transform_constraint_data data, - ) { - return _spine_transform_constraint_data_get_offset_scale_y( - data, - ); + double spine_transform_constraint_data_get_offset_scale_y(spine_transform_constraint_data data) { + return _spine_transform_constraint_data_get_offset_scale_y(data); } - late final _spine_transform_constraint_data_get_offset_scale_yPtr = _lookup< - ffi - .NativeFunction>( - 'spine_transform_constraint_data_get_offset_scale_y'); + late final _spine_transform_constraint_data_get_offset_scale_yPtr = + _lookup>( + 'spine_transform_constraint_data_get_offset_scale_y', + ); late final _spine_transform_constraint_data_get_offset_scale_y = _spine_transform_constraint_data_get_offset_scale_yPtr .asFunction(); - void spine_transform_constraint_data_set_offset_scale_y( - spine_transform_constraint_data data, - double offsetScaleY, - ) { - return _spine_transform_constraint_data_set_offset_scale_y( - data, - offsetScaleY, - ); + void spine_transform_constraint_data_set_offset_scale_y(spine_transform_constraint_data data, double offsetScaleY) { + return _spine_transform_constraint_data_set_offset_scale_y(data, offsetScaleY); } - late final _spine_transform_constraint_data_set_offset_scale_yPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_transform_constraint_data, ffi.Float)>>( - 'spine_transform_constraint_data_set_offset_scale_y'); + late final _spine_transform_constraint_data_set_offset_scale_yPtr = + _lookup>( + 'spine_transform_constraint_data_set_offset_scale_y', + ); late final _spine_transform_constraint_data_set_offset_scale_y = _spine_transform_constraint_data_set_offset_scale_yPtr .asFunction(); - double spine_transform_constraint_data_get_offset_shear_y( - spine_transform_constraint_data data, - ) { - return _spine_transform_constraint_data_get_offset_shear_y( - data, - ); + double spine_transform_constraint_data_get_offset_shear_y(spine_transform_constraint_data data) { + return _spine_transform_constraint_data_get_offset_shear_y(data); } - late final _spine_transform_constraint_data_get_offset_shear_yPtr = _lookup< - ffi - .NativeFunction>( - 'spine_transform_constraint_data_get_offset_shear_y'); + late final _spine_transform_constraint_data_get_offset_shear_yPtr = + _lookup>( + 'spine_transform_constraint_data_get_offset_shear_y', + ); late final _spine_transform_constraint_data_get_offset_shear_y = _spine_transform_constraint_data_get_offset_shear_yPtr .asFunction(); - void spine_transform_constraint_data_set_offset_shear_y( - spine_transform_constraint_data data, - double offsetShearY, - ) { - return _spine_transform_constraint_data_set_offset_shear_y( - data, - offsetShearY, - ); + void spine_transform_constraint_data_set_offset_shear_y(spine_transform_constraint_data data, double offsetShearY) { + return _spine_transform_constraint_data_set_offset_shear_y(data, offsetShearY); } - late final _spine_transform_constraint_data_set_offset_shear_yPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_transform_constraint_data, ffi.Float)>>( - 'spine_transform_constraint_data_set_offset_shear_y'); + late final _spine_transform_constraint_data_set_offset_shear_yPtr = + _lookup>( + 'spine_transform_constraint_data_set_offset_shear_y', + ); late final _spine_transform_constraint_data_set_offset_shear_y = _spine_transform_constraint_data_set_offset_shear_yPtr .asFunction(); - int spine_transform_constraint_data_get_is_relative( - spine_transform_constraint_data data, - ) { - return _spine_transform_constraint_data_get_is_relative( - data, - ); + int spine_transform_constraint_data_get_is_relative(spine_transform_constraint_data data) { + return _spine_transform_constraint_data_get_is_relative(data); } - late final _spine_transform_constraint_data_get_is_relativePtr = _lookup< - ffi.NativeFunction< - spine_bool Function(spine_transform_constraint_data)>>( - 'spine_transform_constraint_data_get_is_relative'); - late final _spine_transform_constraint_data_get_is_relative = - _spine_transform_constraint_data_get_is_relativePtr - .asFunction(); + late final _spine_transform_constraint_data_get_is_relativePtr = + _lookup>( + 'spine_transform_constraint_data_get_is_relative', + ); + late final _spine_transform_constraint_data_get_is_relative = _spine_transform_constraint_data_get_is_relativePtr + .asFunction(); - void spine_transform_constraint_data_set_is_relative( - spine_transform_constraint_data data, - int isRelative, - ) { - return _spine_transform_constraint_data_set_is_relative( - data, - isRelative, - ); + void spine_transform_constraint_data_set_is_relative(spine_transform_constraint_data data, int isRelative) { + return _spine_transform_constraint_data_set_is_relative(data, isRelative); } - late final _spine_transform_constraint_data_set_is_relativePtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_transform_constraint_data, - spine_bool)>>('spine_transform_constraint_data_set_is_relative'); - late final _spine_transform_constraint_data_set_is_relative = - _spine_transform_constraint_data_set_is_relativePtr - .asFunction(); + late final _spine_transform_constraint_data_set_is_relativePtr = + _lookup>( + 'spine_transform_constraint_data_set_is_relative', + ); + late final _spine_transform_constraint_data_set_is_relative = _spine_transform_constraint_data_set_is_relativePtr + .asFunction(); - int spine_transform_constraint_data_get_is_local( - spine_transform_constraint_data data, - ) { - return _spine_transform_constraint_data_get_is_local( - data, - ); + int spine_transform_constraint_data_get_is_local(spine_transform_constraint_data data) { + return _spine_transform_constraint_data_get_is_local(data); } - late final _spine_transform_constraint_data_get_is_localPtr = _lookup< - ffi.NativeFunction< - spine_bool Function(spine_transform_constraint_data)>>( - 'spine_transform_constraint_data_get_is_local'); - late final _spine_transform_constraint_data_get_is_local = - _spine_transform_constraint_data_get_is_localPtr - .asFunction(); + late final _spine_transform_constraint_data_get_is_localPtr = + _lookup>( + 'spine_transform_constraint_data_get_is_local', + ); + late final _spine_transform_constraint_data_get_is_local = _spine_transform_constraint_data_get_is_localPtr + .asFunction(); - void spine_transform_constraint_data_set_is_local( - spine_transform_constraint_data data, - int isLocal, - ) { - return _spine_transform_constraint_data_set_is_local( - data, - isLocal, - ); + void spine_transform_constraint_data_set_is_local(spine_transform_constraint_data data, int isLocal) { + return _spine_transform_constraint_data_set_is_local(data, isLocal); } - late final _spine_transform_constraint_data_set_is_localPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_transform_constraint_data, - spine_bool)>>('spine_transform_constraint_data_set_is_local'); - late final _spine_transform_constraint_data_set_is_local = - _spine_transform_constraint_data_set_is_localPtr - .asFunction(); + late final _spine_transform_constraint_data_set_is_localPtr = + _lookup>( + 'spine_transform_constraint_data_set_is_local', + ); + late final _spine_transform_constraint_data_set_is_local = _spine_transform_constraint_data_set_is_localPtr + .asFunction(); - void spine_transform_constraint_update( - spine_transform_constraint constraint, - ) { - return _spine_transform_constraint_update( - constraint, - ); + void spine_transform_constraint_update(spine_transform_constraint constraint) { + return _spine_transform_constraint_update(constraint); } - late final _spine_transform_constraint_updatePtr = _lookup< - ffi.NativeFunction>( - 'spine_transform_constraint_update'); - late final _spine_transform_constraint_update = - _spine_transform_constraint_updatePtr - .asFunction(); + late final _spine_transform_constraint_updatePtr = + _lookup>('spine_transform_constraint_update'); + late final _spine_transform_constraint_update = _spine_transform_constraint_updatePtr + .asFunction(); - int spine_transform_constraint_get_order( - spine_transform_constraint constraint, - ) { - return _spine_transform_constraint_get_order( - constraint, - ); + int spine_transform_constraint_get_order(spine_transform_constraint constraint) { + return _spine_transform_constraint_get_order(constraint); } - late final _spine_transform_constraint_get_orderPtr = _lookup< - ffi.NativeFunction>( - 'spine_transform_constraint_get_order'); - late final _spine_transform_constraint_get_order = - _spine_transform_constraint_get_orderPtr - .asFunction(); + late final _spine_transform_constraint_get_orderPtr = + _lookup>( + 'spine_transform_constraint_get_order', + ); + late final _spine_transform_constraint_get_order = _spine_transform_constraint_get_orderPtr + .asFunction(); - spine_transform_constraint_data spine_transform_constraint_get_data( - spine_transform_constraint constraint, - ) { - return _spine_transform_constraint_get_data( - constraint, - ); + spine_transform_constraint_data spine_transform_constraint_get_data(spine_transform_constraint constraint) { + return _spine_transform_constraint_get_data(constraint); } - late final _spine_transform_constraint_get_dataPtr = _lookup< - ffi.NativeFunction< - spine_transform_constraint_data Function( - spine_transform_constraint)>>( - 'spine_transform_constraint_get_data'); - late final _spine_transform_constraint_get_data = - _spine_transform_constraint_get_dataPtr.asFunction< - spine_transform_constraint_data Function( - spine_transform_constraint)>(); + late final _spine_transform_constraint_get_dataPtr = + _lookup>( + 'spine_transform_constraint_get_data', + ); + late final _spine_transform_constraint_get_data = _spine_transform_constraint_get_dataPtr + .asFunction(); - int spine_transform_constraint_get_num_bones( - spine_transform_constraint constraint, - ) { - return _spine_transform_constraint_get_num_bones( - constraint, - ); + int spine_transform_constraint_get_num_bones(spine_transform_constraint constraint) { + return _spine_transform_constraint_get_num_bones(constraint); } - late final _spine_transform_constraint_get_num_bonesPtr = _lookup< - ffi.NativeFunction>( - 'spine_transform_constraint_get_num_bones'); - late final _spine_transform_constraint_get_num_bones = - _spine_transform_constraint_get_num_bonesPtr - .asFunction(); + late final _spine_transform_constraint_get_num_bonesPtr = + _lookup>( + 'spine_transform_constraint_get_num_bones', + ); + late final _spine_transform_constraint_get_num_bones = _spine_transform_constraint_get_num_bonesPtr + .asFunction(); - ffi.Pointer spine_transform_constraint_get_bones( - spine_transform_constraint constraint, - ) { - return _spine_transform_constraint_get_bones( - constraint, - ); + ffi.Pointer spine_transform_constraint_get_bones(spine_transform_constraint constraint) { + return _spine_transform_constraint_get_bones(constraint); } - late final _spine_transform_constraint_get_bonesPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(spine_transform_constraint)>>( - 'spine_transform_constraint_get_bones'); - late final _spine_transform_constraint_get_bones = - _spine_transform_constraint_get_bonesPtr.asFunction< - ffi.Pointer Function(spine_transform_constraint)>(); + late final _spine_transform_constraint_get_bonesPtr = + _lookup Function(spine_transform_constraint)>>( + 'spine_transform_constraint_get_bones', + ); + late final _spine_transform_constraint_get_bones = _spine_transform_constraint_get_bonesPtr + .asFunction Function(spine_transform_constraint)>(); - spine_bone spine_transform_constraint_get_target( - spine_transform_constraint constraint, - ) { - return _spine_transform_constraint_get_target( - constraint, - ); + spine_bone spine_transform_constraint_get_target(spine_transform_constraint constraint) { + return _spine_transform_constraint_get_target(constraint); } - late final _spine_transform_constraint_get_targetPtr = _lookup< - ffi.NativeFunction>( - 'spine_transform_constraint_get_target'); - late final _spine_transform_constraint_get_target = - _spine_transform_constraint_get_targetPtr - .asFunction(); + late final _spine_transform_constraint_get_targetPtr = + _lookup>( + 'spine_transform_constraint_get_target', + ); + late final _spine_transform_constraint_get_target = _spine_transform_constraint_get_targetPtr + .asFunction(); - void spine_transform_constraint_set_target( - spine_transform_constraint constraint, - spine_bone target, - ) { - return _spine_transform_constraint_set_target( - constraint, - target, - ); + void spine_transform_constraint_set_target(spine_transform_constraint constraint, spine_bone target) { + return _spine_transform_constraint_set_target(constraint, target); } - late final _spine_transform_constraint_set_targetPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_transform_constraint, - spine_bone)>>('spine_transform_constraint_set_target'); - late final _spine_transform_constraint_set_target = - _spine_transform_constraint_set_targetPtr - .asFunction(); + late final _spine_transform_constraint_set_targetPtr = + _lookup>( + 'spine_transform_constraint_set_target', + ); + late final _spine_transform_constraint_set_target = _spine_transform_constraint_set_targetPtr + .asFunction(); - double spine_transform_constraint_get_mix_rotate( - spine_transform_constraint constraint, - ) { - return _spine_transform_constraint_get_mix_rotate( - constraint, - ); + double spine_transform_constraint_get_mix_rotate(spine_transform_constraint constraint) { + return _spine_transform_constraint_get_mix_rotate(constraint); } - late final _spine_transform_constraint_get_mix_rotatePtr = _lookup< - ffi.NativeFunction>( - 'spine_transform_constraint_get_mix_rotate'); - late final _spine_transform_constraint_get_mix_rotate = - _spine_transform_constraint_get_mix_rotatePtr - .asFunction(); + late final _spine_transform_constraint_get_mix_rotatePtr = + _lookup>( + 'spine_transform_constraint_get_mix_rotate', + ); + late final _spine_transform_constraint_get_mix_rotate = _spine_transform_constraint_get_mix_rotatePtr + .asFunction(); - void spine_transform_constraint_set_mix_rotate( - spine_transform_constraint constraint, - double mixRotate, - ) { - return _spine_transform_constraint_set_mix_rotate( - constraint, - mixRotate, - ); + void spine_transform_constraint_set_mix_rotate(spine_transform_constraint constraint, double mixRotate) { + return _spine_transform_constraint_set_mix_rotate(constraint, mixRotate); } - late final _spine_transform_constraint_set_mix_rotatePtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_transform_constraint, - ffi.Float)>>('spine_transform_constraint_set_mix_rotate'); - late final _spine_transform_constraint_set_mix_rotate = - _spine_transform_constraint_set_mix_rotatePtr - .asFunction(); + late final _spine_transform_constraint_set_mix_rotatePtr = + _lookup>( + 'spine_transform_constraint_set_mix_rotate', + ); + late final _spine_transform_constraint_set_mix_rotate = _spine_transform_constraint_set_mix_rotatePtr + .asFunction(); - double spine_transform_constraint_get_mix_x( - spine_transform_constraint constraint, - ) { - return _spine_transform_constraint_get_mix_x( - constraint, - ); + double spine_transform_constraint_get_mix_x(spine_transform_constraint constraint) { + return _spine_transform_constraint_get_mix_x(constraint); } - late final _spine_transform_constraint_get_mix_xPtr = _lookup< - ffi.NativeFunction>( - 'spine_transform_constraint_get_mix_x'); - late final _spine_transform_constraint_get_mix_x = - _spine_transform_constraint_get_mix_xPtr - .asFunction(); + late final _spine_transform_constraint_get_mix_xPtr = + _lookup>( + 'spine_transform_constraint_get_mix_x', + ); + late final _spine_transform_constraint_get_mix_x = _spine_transform_constraint_get_mix_xPtr + .asFunction(); - void spine_transform_constraint_set_mix_x( - spine_transform_constraint constraint, - double mixX, - ) { - return _spine_transform_constraint_set_mix_x( - constraint, - mixX, - ); + void spine_transform_constraint_set_mix_x(spine_transform_constraint constraint, double mixX) { + return _spine_transform_constraint_set_mix_x(constraint, mixX); } - late final _spine_transform_constraint_set_mix_xPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_transform_constraint, - ffi.Float)>>('spine_transform_constraint_set_mix_x'); - late final _spine_transform_constraint_set_mix_x = - _spine_transform_constraint_set_mix_xPtr - .asFunction(); + late final _spine_transform_constraint_set_mix_xPtr = + _lookup>( + 'spine_transform_constraint_set_mix_x', + ); + late final _spine_transform_constraint_set_mix_x = _spine_transform_constraint_set_mix_xPtr + .asFunction(); - double spine_transform_constraint_get_mix_y( - spine_transform_constraint constraint, - ) { - return _spine_transform_constraint_get_mix_y( - constraint, - ); + double spine_transform_constraint_get_mix_y(spine_transform_constraint constraint) { + return _spine_transform_constraint_get_mix_y(constraint); } - late final _spine_transform_constraint_get_mix_yPtr = _lookup< - ffi.NativeFunction>( - 'spine_transform_constraint_get_mix_y'); - late final _spine_transform_constraint_get_mix_y = - _spine_transform_constraint_get_mix_yPtr - .asFunction(); + late final _spine_transform_constraint_get_mix_yPtr = + _lookup>( + 'spine_transform_constraint_get_mix_y', + ); + late final _spine_transform_constraint_get_mix_y = _spine_transform_constraint_get_mix_yPtr + .asFunction(); - void spine_transform_constraint_set_mix_y( - spine_transform_constraint constraint, - double mixY, - ) { - return _spine_transform_constraint_set_mix_y( - constraint, - mixY, - ); + void spine_transform_constraint_set_mix_y(spine_transform_constraint constraint, double mixY) { + return _spine_transform_constraint_set_mix_y(constraint, mixY); } - late final _spine_transform_constraint_set_mix_yPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_transform_constraint, - ffi.Float)>>('spine_transform_constraint_set_mix_y'); - late final _spine_transform_constraint_set_mix_y = - _spine_transform_constraint_set_mix_yPtr - .asFunction(); + late final _spine_transform_constraint_set_mix_yPtr = + _lookup>( + 'spine_transform_constraint_set_mix_y', + ); + late final _spine_transform_constraint_set_mix_y = _spine_transform_constraint_set_mix_yPtr + .asFunction(); - double spine_transform_constraint_get_mix_scale_x( - spine_transform_constraint constraint, - ) { - return _spine_transform_constraint_get_mix_scale_x( - constraint, - ); + double spine_transform_constraint_get_mix_scale_x(spine_transform_constraint constraint) { + return _spine_transform_constraint_get_mix_scale_x(constraint); } - late final _spine_transform_constraint_get_mix_scale_xPtr = _lookup< - ffi.NativeFunction>( - 'spine_transform_constraint_get_mix_scale_x'); - late final _spine_transform_constraint_get_mix_scale_x = - _spine_transform_constraint_get_mix_scale_xPtr - .asFunction(); + late final _spine_transform_constraint_get_mix_scale_xPtr = + _lookup>( + 'spine_transform_constraint_get_mix_scale_x', + ); + late final _spine_transform_constraint_get_mix_scale_x = _spine_transform_constraint_get_mix_scale_xPtr + .asFunction(); - void spine_transform_constraint_set_mix_scale_x( - spine_transform_constraint constraint, - double mixScaleX, - ) { - return _spine_transform_constraint_set_mix_scale_x( - constraint, - mixScaleX, - ); + void spine_transform_constraint_set_mix_scale_x(spine_transform_constraint constraint, double mixScaleX) { + return _spine_transform_constraint_set_mix_scale_x(constraint, mixScaleX); } - late final _spine_transform_constraint_set_mix_scale_xPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_transform_constraint, - ffi.Float)>>('spine_transform_constraint_set_mix_scale_x'); - late final _spine_transform_constraint_set_mix_scale_x = - _spine_transform_constraint_set_mix_scale_xPtr - .asFunction(); + late final _spine_transform_constraint_set_mix_scale_xPtr = + _lookup>( + 'spine_transform_constraint_set_mix_scale_x', + ); + late final _spine_transform_constraint_set_mix_scale_x = _spine_transform_constraint_set_mix_scale_xPtr + .asFunction(); - double spine_transform_constraint_get_mix_scale_y( - spine_transform_constraint constraint, - ) { - return _spine_transform_constraint_get_mix_scale_y( - constraint, - ); + double spine_transform_constraint_get_mix_scale_y(spine_transform_constraint constraint) { + return _spine_transform_constraint_get_mix_scale_y(constraint); } - late final _spine_transform_constraint_get_mix_scale_yPtr = _lookup< - ffi.NativeFunction>( - 'spine_transform_constraint_get_mix_scale_y'); - late final _spine_transform_constraint_get_mix_scale_y = - _spine_transform_constraint_get_mix_scale_yPtr - .asFunction(); + late final _spine_transform_constraint_get_mix_scale_yPtr = + _lookup>( + 'spine_transform_constraint_get_mix_scale_y', + ); + late final _spine_transform_constraint_get_mix_scale_y = _spine_transform_constraint_get_mix_scale_yPtr + .asFunction(); - void spine_transform_constraint_set_mix_scale_y( - spine_transform_constraint constraint, - double mixScaleY, - ) { - return _spine_transform_constraint_set_mix_scale_y( - constraint, - mixScaleY, - ); + void spine_transform_constraint_set_mix_scale_y(spine_transform_constraint constraint, double mixScaleY) { + return _spine_transform_constraint_set_mix_scale_y(constraint, mixScaleY); } - late final _spine_transform_constraint_set_mix_scale_yPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_transform_constraint, - ffi.Float)>>('spine_transform_constraint_set_mix_scale_y'); - late final _spine_transform_constraint_set_mix_scale_y = - _spine_transform_constraint_set_mix_scale_yPtr - .asFunction(); + late final _spine_transform_constraint_set_mix_scale_yPtr = + _lookup>( + 'spine_transform_constraint_set_mix_scale_y', + ); + late final _spine_transform_constraint_set_mix_scale_y = _spine_transform_constraint_set_mix_scale_yPtr + .asFunction(); - double spine_transform_constraint_get_mix_shear_y( - spine_transform_constraint constraint, - ) { - return _spine_transform_constraint_get_mix_shear_y( - constraint, - ); + double spine_transform_constraint_get_mix_shear_y(spine_transform_constraint constraint) { + return _spine_transform_constraint_get_mix_shear_y(constraint); } - late final _spine_transform_constraint_get_mix_shear_yPtr = _lookup< - ffi.NativeFunction>( - 'spine_transform_constraint_get_mix_shear_y'); - late final _spine_transform_constraint_get_mix_shear_y = - _spine_transform_constraint_get_mix_shear_yPtr - .asFunction(); + late final _spine_transform_constraint_get_mix_shear_yPtr = + _lookup>( + 'spine_transform_constraint_get_mix_shear_y', + ); + late final _spine_transform_constraint_get_mix_shear_y = _spine_transform_constraint_get_mix_shear_yPtr + .asFunction(); - void spine_transform_constraint_set_mix_shear_y( - spine_transform_constraint constraint, - double mixShearY, - ) { - return _spine_transform_constraint_set_mix_shear_y( - constraint, - mixShearY, - ); + void spine_transform_constraint_set_mix_shear_y(spine_transform_constraint constraint, double mixShearY) { + return _spine_transform_constraint_set_mix_shear_y(constraint, mixShearY); } - late final _spine_transform_constraint_set_mix_shear_yPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_transform_constraint, - ffi.Float)>>('spine_transform_constraint_set_mix_shear_y'); - late final _spine_transform_constraint_set_mix_shear_y = - _spine_transform_constraint_set_mix_shear_yPtr - .asFunction(); + late final _spine_transform_constraint_set_mix_shear_yPtr = + _lookup>( + 'spine_transform_constraint_set_mix_shear_y', + ); + late final _spine_transform_constraint_set_mix_shear_y = _spine_transform_constraint_set_mix_shear_yPtr + .asFunction(); - int spine_transform_constraint_get_is_active( - spine_transform_constraint constraint, - ) { - return _spine_transform_constraint_get_is_active( - constraint, - ); + int spine_transform_constraint_get_is_active(spine_transform_constraint constraint) { + return _spine_transform_constraint_get_is_active(constraint); } - late final _spine_transform_constraint_get_is_activePtr = _lookup< - ffi.NativeFunction>( - 'spine_transform_constraint_get_is_active'); - late final _spine_transform_constraint_get_is_active = - _spine_transform_constraint_get_is_activePtr - .asFunction(); + late final _spine_transform_constraint_get_is_activePtr = + _lookup>( + 'spine_transform_constraint_get_is_active', + ); + late final _spine_transform_constraint_get_is_active = _spine_transform_constraint_get_is_activePtr + .asFunction(); - void spine_transform_constraint_set_is_active( - spine_transform_constraint constraint, - int isActive, - ) { - return _spine_transform_constraint_set_is_active( - constraint, - isActive, - ); + void spine_transform_constraint_set_is_active(spine_transform_constraint constraint, int isActive) { + return _spine_transform_constraint_set_is_active(constraint, isActive); } - late final _spine_transform_constraint_set_is_activePtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_transform_constraint, - spine_bool)>>('spine_transform_constraint_set_is_active'); - late final _spine_transform_constraint_set_is_active = - _spine_transform_constraint_set_is_activePtr - .asFunction(); + late final _spine_transform_constraint_set_is_activePtr = + _lookup>( + 'spine_transform_constraint_set_is_active', + ); + late final _spine_transform_constraint_set_is_active = _spine_transform_constraint_set_is_activePtr + .asFunction(); /// OMITTED setToSetupPose() - int spine_path_constraint_data_get_num_bones( - spine_path_constraint_data data, - ) { - return _spine_path_constraint_data_get_num_bones( - data, - ); + int spine_path_constraint_data_get_num_bones(spine_path_constraint_data data) { + return _spine_path_constraint_data_get_num_bones(data); } - late final _spine_path_constraint_data_get_num_bonesPtr = _lookup< - ffi.NativeFunction>( - 'spine_path_constraint_data_get_num_bones'); - late final _spine_path_constraint_data_get_num_bones = - _spine_path_constraint_data_get_num_bonesPtr - .asFunction(); + late final _spine_path_constraint_data_get_num_bonesPtr = + _lookup>( + 'spine_path_constraint_data_get_num_bones', + ); + late final _spine_path_constraint_data_get_num_bones = _spine_path_constraint_data_get_num_bonesPtr + .asFunction(); - ffi.Pointer spine_path_constraint_data_get_bones( - spine_path_constraint_data data, - ) { - return _spine_path_constraint_data_get_bones( - data, - ); + ffi.Pointer spine_path_constraint_data_get_bones(spine_path_constraint_data data) { + return _spine_path_constraint_data_get_bones(data); } - late final _spine_path_constraint_data_get_bonesPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_path_constraint_data)>>( - 'spine_path_constraint_data_get_bones'); - late final _spine_path_constraint_data_get_bones = - _spine_path_constraint_data_get_bonesPtr.asFunction< - ffi.Pointer Function(spine_path_constraint_data)>(); + late final _spine_path_constraint_data_get_bonesPtr = + _lookup Function(spine_path_constraint_data)>>( + 'spine_path_constraint_data_get_bones', + ); + late final _spine_path_constraint_data_get_bones = _spine_path_constraint_data_get_bonesPtr + .asFunction Function(spine_path_constraint_data)>(); - spine_slot_data spine_path_constraint_data_get_target( - spine_path_constraint_data data, - ) { - return _spine_path_constraint_data_get_target( - data, - ); + spine_slot_data spine_path_constraint_data_get_target(spine_path_constraint_data data) { + return _spine_path_constraint_data_get_target(data); } - late final _spine_path_constraint_data_get_targetPtr = _lookup< - ffi.NativeFunction< - spine_slot_data Function(spine_path_constraint_data)>>( - 'spine_path_constraint_data_get_target'); - late final _spine_path_constraint_data_get_target = - _spine_path_constraint_data_get_targetPtr - .asFunction(); + late final _spine_path_constraint_data_get_targetPtr = + _lookup>( + 'spine_path_constraint_data_get_target', + ); + late final _spine_path_constraint_data_get_target = _spine_path_constraint_data_get_targetPtr + .asFunction(); - void spine_path_constraint_data_set_target( - spine_path_constraint_data data, - spine_slot_data target, - ) { - return _spine_path_constraint_data_set_target( - data, - target, - ); + void spine_path_constraint_data_set_target(spine_path_constraint_data data, spine_slot_data target) { + return _spine_path_constraint_data_set_target(data, target); } - late final _spine_path_constraint_data_set_targetPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_path_constraint_data, - spine_slot_data)>>('spine_path_constraint_data_set_target'); - late final _spine_path_constraint_data_set_target = - _spine_path_constraint_data_set_targetPtr.asFunction< - void Function(spine_path_constraint_data, spine_slot_data)>(); + late final _spine_path_constraint_data_set_targetPtr = + _lookup>( + 'spine_path_constraint_data_set_target', + ); + late final _spine_path_constraint_data_set_target = _spine_path_constraint_data_set_targetPtr + .asFunction(); - int spine_path_constraint_data_get_position_mode( - spine_path_constraint_data data, - ) { - return _spine_path_constraint_data_get_position_mode( - data, - ); + int spine_path_constraint_data_get_position_mode(spine_path_constraint_data data) { + return _spine_path_constraint_data_get_position_mode(data); } - late final _spine_path_constraint_data_get_position_modePtr = _lookup< - ffi.NativeFunction>( - 'spine_path_constraint_data_get_position_mode'); - late final _spine_path_constraint_data_get_position_mode = - _spine_path_constraint_data_get_position_modePtr - .asFunction(); + late final _spine_path_constraint_data_get_position_modePtr = + _lookup>( + 'spine_path_constraint_data_get_position_mode', + ); + late final _spine_path_constraint_data_get_position_mode = _spine_path_constraint_data_get_position_modePtr + .asFunction(); - void spine_path_constraint_data_set_position_mode( - spine_path_constraint_data data, - int positionMode, - ) { - return _spine_path_constraint_data_set_position_mode( - data, - positionMode, - ); + void spine_path_constraint_data_set_position_mode(spine_path_constraint_data data, int positionMode) { + return _spine_path_constraint_data_set_position_mode(data, positionMode); } - late final _spine_path_constraint_data_set_position_modePtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_path_constraint_data, - ffi.Int32)>>('spine_path_constraint_data_set_position_mode'); - late final _spine_path_constraint_data_set_position_mode = - _spine_path_constraint_data_set_position_modePtr - .asFunction(); + late final _spine_path_constraint_data_set_position_modePtr = + _lookup>( + 'spine_path_constraint_data_set_position_mode', + ); + late final _spine_path_constraint_data_set_position_mode = _spine_path_constraint_data_set_position_modePtr + .asFunction(); - int spine_path_constraint_data_get_spacing_mode( - spine_path_constraint_data data, - ) { - return _spine_path_constraint_data_get_spacing_mode( - data, - ); + int spine_path_constraint_data_get_spacing_mode(spine_path_constraint_data data) { + return _spine_path_constraint_data_get_spacing_mode(data); } - late final _spine_path_constraint_data_get_spacing_modePtr = _lookup< - ffi.NativeFunction>( - 'spine_path_constraint_data_get_spacing_mode'); - late final _spine_path_constraint_data_get_spacing_mode = - _spine_path_constraint_data_get_spacing_modePtr - .asFunction(); + late final _spine_path_constraint_data_get_spacing_modePtr = + _lookup>( + 'spine_path_constraint_data_get_spacing_mode', + ); + late final _spine_path_constraint_data_get_spacing_mode = _spine_path_constraint_data_get_spacing_modePtr + .asFunction(); - void spine_path_constraint_data_set_spacing_mode( - spine_path_constraint_data data, - int spacingMode, - ) { - return _spine_path_constraint_data_set_spacing_mode( - data, - spacingMode, - ); + void spine_path_constraint_data_set_spacing_mode(spine_path_constraint_data data, int spacingMode) { + return _spine_path_constraint_data_set_spacing_mode(data, spacingMode); } - late final _spine_path_constraint_data_set_spacing_modePtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_path_constraint_data, - ffi.Int32)>>('spine_path_constraint_data_set_spacing_mode'); - late final _spine_path_constraint_data_set_spacing_mode = - _spine_path_constraint_data_set_spacing_modePtr - .asFunction(); + late final _spine_path_constraint_data_set_spacing_modePtr = + _lookup>( + 'spine_path_constraint_data_set_spacing_mode', + ); + late final _spine_path_constraint_data_set_spacing_mode = _spine_path_constraint_data_set_spacing_modePtr + .asFunction(); - int spine_path_constraint_data_get_rotate_mode( - spine_path_constraint_data data, - ) { - return _spine_path_constraint_data_get_rotate_mode( - data, - ); + int spine_path_constraint_data_get_rotate_mode(spine_path_constraint_data data) { + return _spine_path_constraint_data_get_rotate_mode(data); } - late final _spine_path_constraint_data_get_rotate_modePtr = _lookup< - ffi.NativeFunction>( - 'spine_path_constraint_data_get_rotate_mode'); - late final _spine_path_constraint_data_get_rotate_mode = - _spine_path_constraint_data_get_rotate_modePtr - .asFunction(); + late final _spine_path_constraint_data_get_rotate_modePtr = + _lookup>( + 'spine_path_constraint_data_get_rotate_mode', + ); + late final _spine_path_constraint_data_get_rotate_mode = _spine_path_constraint_data_get_rotate_modePtr + .asFunction(); - void spine_path_constraint_data_set_rotate_mode( - spine_path_constraint_data data, - int rotateMode, - ) { - return _spine_path_constraint_data_set_rotate_mode( - data, - rotateMode, - ); + void spine_path_constraint_data_set_rotate_mode(spine_path_constraint_data data, int rotateMode) { + return _spine_path_constraint_data_set_rotate_mode(data, rotateMode); } - late final _spine_path_constraint_data_set_rotate_modePtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_path_constraint_data, - ffi.Int32)>>('spine_path_constraint_data_set_rotate_mode'); - late final _spine_path_constraint_data_set_rotate_mode = - _spine_path_constraint_data_set_rotate_modePtr - .asFunction(); + late final _spine_path_constraint_data_set_rotate_modePtr = + _lookup>( + 'spine_path_constraint_data_set_rotate_mode', + ); + late final _spine_path_constraint_data_set_rotate_mode = _spine_path_constraint_data_set_rotate_modePtr + .asFunction(); - double spine_path_constraint_data_get_offset_rotation( - spine_path_constraint_data data, - ) { - return _spine_path_constraint_data_get_offset_rotation( - data, - ); + double spine_path_constraint_data_get_offset_rotation(spine_path_constraint_data data) { + return _spine_path_constraint_data_get_offset_rotation(data); } - late final _spine_path_constraint_data_get_offset_rotationPtr = _lookup< - ffi.NativeFunction>( - 'spine_path_constraint_data_get_offset_rotation'); - late final _spine_path_constraint_data_get_offset_rotation = - _spine_path_constraint_data_get_offset_rotationPtr - .asFunction(); + late final _spine_path_constraint_data_get_offset_rotationPtr = + _lookup>( + 'spine_path_constraint_data_get_offset_rotation', + ); + late final _spine_path_constraint_data_get_offset_rotation = _spine_path_constraint_data_get_offset_rotationPtr + .asFunction(); - void spine_path_constraint_data_set_offset_rotation( - spine_path_constraint_data data, - double offsetRotation, - ) { - return _spine_path_constraint_data_set_offset_rotation( - data, - offsetRotation, - ); + void spine_path_constraint_data_set_offset_rotation(spine_path_constraint_data data, double offsetRotation) { + return _spine_path_constraint_data_set_offset_rotation(data, offsetRotation); } - late final _spine_path_constraint_data_set_offset_rotationPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_path_constraint_data, - ffi.Float)>>('spine_path_constraint_data_set_offset_rotation'); - late final _spine_path_constraint_data_set_offset_rotation = - _spine_path_constraint_data_set_offset_rotationPtr - .asFunction(); + late final _spine_path_constraint_data_set_offset_rotationPtr = + _lookup>( + 'spine_path_constraint_data_set_offset_rotation', + ); + late final _spine_path_constraint_data_set_offset_rotation = _spine_path_constraint_data_set_offset_rotationPtr + .asFunction(); - double spine_path_constraint_data_get_position( - spine_path_constraint_data data, - ) { - return _spine_path_constraint_data_get_position( - data, - ); + double spine_path_constraint_data_get_position(spine_path_constraint_data data) { + return _spine_path_constraint_data_get_position(data); } - late final _spine_path_constraint_data_get_positionPtr = _lookup< - ffi.NativeFunction>( - 'spine_path_constraint_data_get_position'); - late final _spine_path_constraint_data_get_position = - _spine_path_constraint_data_get_positionPtr - .asFunction(); + late final _spine_path_constraint_data_get_positionPtr = + _lookup>( + 'spine_path_constraint_data_get_position', + ); + late final _spine_path_constraint_data_get_position = _spine_path_constraint_data_get_positionPtr + .asFunction(); - void spine_path_constraint_data_set_position( - spine_path_constraint_data data, - double position, - ) { - return _spine_path_constraint_data_set_position( - data, - position, - ); + void spine_path_constraint_data_set_position(spine_path_constraint_data data, double position) { + return _spine_path_constraint_data_set_position(data, position); } - late final _spine_path_constraint_data_set_positionPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_path_constraint_data, - ffi.Float)>>('spine_path_constraint_data_set_position'); - late final _spine_path_constraint_data_set_position = - _spine_path_constraint_data_set_positionPtr - .asFunction(); + late final _spine_path_constraint_data_set_positionPtr = + _lookup>( + 'spine_path_constraint_data_set_position', + ); + late final _spine_path_constraint_data_set_position = _spine_path_constraint_data_set_positionPtr + .asFunction(); - double spine_path_constraint_data_get_spacing( - spine_path_constraint_data data, - ) { - return _spine_path_constraint_data_get_spacing( - data, - ); + double spine_path_constraint_data_get_spacing(spine_path_constraint_data data) { + return _spine_path_constraint_data_get_spacing(data); } - late final _spine_path_constraint_data_get_spacingPtr = _lookup< - ffi.NativeFunction>( - 'spine_path_constraint_data_get_spacing'); - late final _spine_path_constraint_data_get_spacing = - _spine_path_constraint_data_get_spacingPtr - .asFunction(); + late final _spine_path_constraint_data_get_spacingPtr = + _lookup>( + 'spine_path_constraint_data_get_spacing', + ); + late final _spine_path_constraint_data_get_spacing = _spine_path_constraint_data_get_spacingPtr + .asFunction(); - void spine_path_constraint_data_set_spacing( - spine_path_constraint_data data, - double spacing, - ) { - return _spine_path_constraint_data_set_spacing( - data, - spacing, - ); + void spine_path_constraint_data_set_spacing(spine_path_constraint_data data, double spacing) { + return _spine_path_constraint_data_set_spacing(data, spacing); } - late final _spine_path_constraint_data_set_spacingPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_path_constraint_data, - ffi.Float)>>('spine_path_constraint_data_set_spacing'); - late final _spine_path_constraint_data_set_spacing = - _spine_path_constraint_data_set_spacingPtr - .asFunction(); + late final _spine_path_constraint_data_set_spacingPtr = + _lookup>( + 'spine_path_constraint_data_set_spacing', + ); + late final _spine_path_constraint_data_set_spacing = _spine_path_constraint_data_set_spacingPtr + .asFunction(); - double spine_path_constraint_data_get_mix_rotate( - spine_path_constraint_data data, - ) { - return _spine_path_constraint_data_get_mix_rotate( - data, - ); + double spine_path_constraint_data_get_mix_rotate(spine_path_constraint_data data) { + return _spine_path_constraint_data_get_mix_rotate(data); } - late final _spine_path_constraint_data_get_mix_rotatePtr = _lookup< - ffi.NativeFunction>( - 'spine_path_constraint_data_get_mix_rotate'); - late final _spine_path_constraint_data_get_mix_rotate = - _spine_path_constraint_data_get_mix_rotatePtr - .asFunction(); + late final _spine_path_constraint_data_get_mix_rotatePtr = + _lookup>( + 'spine_path_constraint_data_get_mix_rotate', + ); + late final _spine_path_constraint_data_get_mix_rotate = _spine_path_constraint_data_get_mix_rotatePtr + .asFunction(); - void spine_path_constraint_data_set_mix_rotate( - spine_path_constraint_data data, - double mixRotate, - ) { - return _spine_path_constraint_data_set_mix_rotate( - data, - mixRotate, - ); + void spine_path_constraint_data_set_mix_rotate(spine_path_constraint_data data, double mixRotate) { + return _spine_path_constraint_data_set_mix_rotate(data, mixRotate); } - late final _spine_path_constraint_data_set_mix_rotatePtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_path_constraint_data, - ffi.Float)>>('spine_path_constraint_data_set_mix_rotate'); - late final _spine_path_constraint_data_set_mix_rotate = - _spine_path_constraint_data_set_mix_rotatePtr - .asFunction(); + late final _spine_path_constraint_data_set_mix_rotatePtr = + _lookup>( + 'spine_path_constraint_data_set_mix_rotate', + ); + late final _spine_path_constraint_data_set_mix_rotate = _spine_path_constraint_data_set_mix_rotatePtr + .asFunction(); - double spine_path_constraint_data_get_mix_x( - spine_path_constraint_data data, - ) { - return _spine_path_constraint_data_get_mix_x( - data, - ); + double spine_path_constraint_data_get_mix_x(spine_path_constraint_data data) { + return _spine_path_constraint_data_get_mix_x(data); } - late final _spine_path_constraint_data_get_mix_xPtr = _lookup< - ffi.NativeFunction>( - 'spine_path_constraint_data_get_mix_x'); - late final _spine_path_constraint_data_get_mix_x = - _spine_path_constraint_data_get_mix_xPtr - .asFunction(); + late final _spine_path_constraint_data_get_mix_xPtr = + _lookup>( + 'spine_path_constraint_data_get_mix_x', + ); + late final _spine_path_constraint_data_get_mix_x = _spine_path_constraint_data_get_mix_xPtr + .asFunction(); - void spine_path_constraint_data_set_mix_x( - spine_path_constraint_data data, - double mixX, - ) { - return _spine_path_constraint_data_set_mix_x( - data, - mixX, - ); + void spine_path_constraint_data_set_mix_x(spine_path_constraint_data data, double mixX) { + return _spine_path_constraint_data_set_mix_x(data, mixX); } - late final _spine_path_constraint_data_set_mix_xPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_path_constraint_data, - ffi.Float)>>('spine_path_constraint_data_set_mix_x'); - late final _spine_path_constraint_data_set_mix_x = - _spine_path_constraint_data_set_mix_xPtr - .asFunction(); + late final _spine_path_constraint_data_set_mix_xPtr = + _lookup>( + 'spine_path_constraint_data_set_mix_x', + ); + late final _spine_path_constraint_data_set_mix_x = _spine_path_constraint_data_set_mix_xPtr + .asFunction(); - double spine_path_constraint_data_get_mix_y( - spine_path_constraint_data data, - ) { - return _spine_path_constraint_data_get_mix_y( - data, - ); + double spine_path_constraint_data_get_mix_y(spine_path_constraint_data data) { + return _spine_path_constraint_data_get_mix_y(data); } - late final _spine_path_constraint_data_get_mix_yPtr = _lookup< - ffi.NativeFunction>( - 'spine_path_constraint_data_get_mix_y'); - late final _spine_path_constraint_data_get_mix_y = - _spine_path_constraint_data_get_mix_yPtr - .asFunction(); + late final _spine_path_constraint_data_get_mix_yPtr = + _lookup>( + 'spine_path_constraint_data_get_mix_y', + ); + late final _spine_path_constraint_data_get_mix_y = _spine_path_constraint_data_get_mix_yPtr + .asFunction(); - void spine_path_constraint_data_set_mix_y( - spine_path_constraint_data data, - double mixY, - ) { - return _spine_path_constraint_data_set_mix_y( - data, - mixY, - ); + void spine_path_constraint_data_set_mix_y(spine_path_constraint_data data, double mixY) { + return _spine_path_constraint_data_set_mix_y(data, mixY); } - late final _spine_path_constraint_data_set_mix_yPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_path_constraint_data, - ffi.Float)>>('spine_path_constraint_data_set_mix_y'); - late final _spine_path_constraint_data_set_mix_y = - _spine_path_constraint_data_set_mix_yPtr - .asFunction(); + late final _spine_path_constraint_data_set_mix_yPtr = + _lookup>( + 'spine_path_constraint_data_set_mix_y', + ); + late final _spine_path_constraint_data_set_mix_y = _spine_path_constraint_data_set_mix_yPtr + .asFunction(); - void spine_path_constraint_update( - spine_path_constraint constraint, - ) { - return _spine_path_constraint_update( - constraint, - ); + void spine_path_constraint_update(spine_path_constraint constraint) { + return _spine_path_constraint_update(constraint); } - late final _spine_path_constraint_updatePtr = - _lookup>( - 'spine_path_constraint_update'); + late final _spine_path_constraint_updatePtr = _lookup>( + 'spine_path_constraint_update', + ); late final _spine_path_constraint_update = _spine_path_constraint_updatePtr .asFunction(); - int spine_path_constraint_get_order( - spine_path_constraint constraint, - ) { - return _spine_path_constraint_get_order( - constraint, - ); + int spine_path_constraint_get_order(spine_path_constraint constraint) { + return _spine_path_constraint_get_order(constraint); } late final _spine_path_constraint_get_orderPtr = - _lookup>( - 'spine_path_constraint_get_order'); - late final _spine_path_constraint_get_order = - _spine_path_constraint_get_orderPtr - .asFunction(); + _lookup>('spine_path_constraint_get_order'); + late final _spine_path_constraint_get_order = _spine_path_constraint_get_orderPtr + .asFunction(); - spine_path_constraint_data spine_path_constraint_get_data( - spine_path_constraint constraint, - ) { - return _spine_path_constraint_get_data( - constraint, - ); + spine_path_constraint_data spine_path_constraint_get_data(spine_path_constraint constraint) { + return _spine_path_constraint_get_data(constraint); } - late final _spine_path_constraint_get_dataPtr = _lookup< - ffi.NativeFunction< - spine_path_constraint_data Function( - spine_path_constraint)>>('spine_path_constraint_get_data'); - late final _spine_path_constraint_get_data = - _spine_path_constraint_get_dataPtr.asFunction< - spine_path_constraint_data Function(spine_path_constraint)>(); + late final _spine_path_constraint_get_dataPtr = + _lookup>( + 'spine_path_constraint_get_data', + ); + late final _spine_path_constraint_get_data = _spine_path_constraint_get_dataPtr + .asFunction(); - int spine_path_constraint_get_num_bones( - spine_path_constraint constraint, - ) { - return _spine_path_constraint_get_num_bones( - constraint, - ); + int spine_path_constraint_get_num_bones(spine_path_constraint constraint) { + return _spine_path_constraint_get_num_bones(constraint); } late final _spine_path_constraint_get_num_bonesPtr = - _lookup>( - 'spine_path_constraint_get_num_bones'); - late final _spine_path_constraint_get_num_bones = - _spine_path_constraint_get_num_bonesPtr - .asFunction(); + _lookup>('spine_path_constraint_get_num_bones'); + late final _spine_path_constraint_get_num_bones = _spine_path_constraint_get_num_bonesPtr + .asFunction(); - ffi.Pointer spine_path_constraint_get_bones( - spine_path_constraint constraint, - ) { - return _spine_path_constraint_get_bones( - constraint, - ); + ffi.Pointer spine_path_constraint_get_bones(spine_path_constraint constraint) { + return _spine_path_constraint_get_bones(constraint); } - late final _spine_path_constraint_get_bonesPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_path_constraint)>>('spine_path_constraint_get_bones'); - late final _spine_path_constraint_get_bones = - _spine_path_constraint_get_bonesPtr.asFunction< - ffi.Pointer Function(spine_path_constraint)>(); + late final _spine_path_constraint_get_bonesPtr = + _lookup Function(spine_path_constraint)>>( + 'spine_path_constraint_get_bones', + ); + late final _spine_path_constraint_get_bones = _spine_path_constraint_get_bonesPtr + .asFunction Function(spine_path_constraint)>(); - spine_slot spine_path_constraint_get_target( - spine_path_constraint constraint, - ) { - return _spine_path_constraint_get_target( - constraint, - ); + spine_slot spine_path_constraint_get_target(spine_path_constraint constraint) { + return _spine_path_constraint_get_target(constraint); } late final _spine_path_constraint_get_targetPtr = - _lookup>( - 'spine_path_constraint_get_target'); - late final _spine_path_constraint_get_target = - _spine_path_constraint_get_targetPtr - .asFunction(); + _lookup>('spine_path_constraint_get_target'); + late final _spine_path_constraint_get_target = _spine_path_constraint_get_targetPtr + .asFunction(); - void spine_path_constraint_set_target( - spine_path_constraint constraint, - spine_slot target, - ) { - return _spine_path_constraint_set_target( - constraint, - target, - ); + void spine_path_constraint_set_target(spine_path_constraint constraint, spine_slot target) { + return _spine_path_constraint_set_target(constraint, target); } - late final _spine_path_constraint_set_targetPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_path_constraint, - spine_slot)>>('spine_path_constraint_set_target'); - late final _spine_path_constraint_set_target = - _spine_path_constraint_set_targetPtr - .asFunction(); + late final _spine_path_constraint_set_targetPtr = + _lookup>( + 'spine_path_constraint_set_target', + ); + late final _spine_path_constraint_set_target = _spine_path_constraint_set_targetPtr + .asFunction(); - double spine_path_constraint_get_position( - spine_path_constraint constraint, - ) { - return _spine_path_constraint_get_position( - constraint, - ); + double spine_path_constraint_get_position(spine_path_constraint constraint) { + return _spine_path_constraint_get_position(constraint); } late final _spine_path_constraint_get_positionPtr = - _lookup>( - 'spine_path_constraint_get_position'); - late final _spine_path_constraint_get_position = - _spine_path_constraint_get_positionPtr - .asFunction(); + _lookup>('spine_path_constraint_get_position'); + late final _spine_path_constraint_get_position = _spine_path_constraint_get_positionPtr + .asFunction(); - void spine_path_constraint_set_position( - spine_path_constraint constraint, - double position, - ) { - return _spine_path_constraint_set_position( - constraint, - position, - ); + void spine_path_constraint_set_position(spine_path_constraint constraint, double position) { + return _spine_path_constraint_set_position(constraint, position); } - late final _spine_path_constraint_set_positionPtr = _lookup< - ffi - .NativeFunction>( - 'spine_path_constraint_set_position'); - late final _spine_path_constraint_set_position = - _spine_path_constraint_set_positionPtr - .asFunction(); + late final _spine_path_constraint_set_positionPtr = + _lookup>( + 'spine_path_constraint_set_position', + ); + late final _spine_path_constraint_set_position = _spine_path_constraint_set_positionPtr + .asFunction(); - double spine_path_constraint_get_spacing( - spine_path_constraint constraint, - ) { - return _spine_path_constraint_get_spacing( - constraint, - ); + double spine_path_constraint_get_spacing(spine_path_constraint constraint) { + return _spine_path_constraint_get_spacing(constraint); } late final _spine_path_constraint_get_spacingPtr = - _lookup>( - 'spine_path_constraint_get_spacing'); - late final _spine_path_constraint_get_spacing = - _spine_path_constraint_get_spacingPtr - .asFunction(); + _lookup>('spine_path_constraint_get_spacing'); + late final _spine_path_constraint_get_spacing = _spine_path_constraint_get_spacingPtr + .asFunction(); - void spine_path_constraint_set_spacing( - spine_path_constraint constraint, - double spacing, - ) { - return _spine_path_constraint_set_spacing( - constraint, - spacing, - ); + void spine_path_constraint_set_spacing(spine_path_constraint constraint, double spacing) { + return _spine_path_constraint_set_spacing(constraint, spacing); } - late final _spine_path_constraint_set_spacingPtr = _lookup< - ffi - .NativeFunction>( - 'spine_path_constraint_set_spacing'); - late final _spine_path_constraint_set_spacing = - _spine_path_constraint_set_spacingPtr - .asFunction(); + late final _spine_path_constraint_set_spacingPtr = + _lookup>( + 'spine_path_constraint_set_spacing', + ); + late final _spine_path_constraint_set_spacing = _spine_path_constraint_set_spacingPtr + .asFunction(); - double spine_path_constraint_get_mix_rotate( - spine_path_constraint constraint, - ) { - return _spine_path_constraint_get_mix_rotate( - constraint, - ); + double spine_path_constraint_get_mix_rotate(spine_path_constraint constraint) { + return _spine_path_constraint_get_mix_rotate(constraint); } late final _spine_path_constraint_get_mix_rotatePtr = - _lookup>( - 'spine_path_constraint_get_mix_rotate'); - late final _spine_path_constraint_get_mix_rotate = - _spine_path_constraint_get_mix_rotatePtr - .asFunction(); + _lookup>('spine_path_constraint_get_mix_rotate'); + late final _spine_path_constraint_get_mix_rotate = _spine_path_constraint_get_mix_rotatePtr + .asFunction(); - void spine_path_constraint_set_mix_rotate( - spine_path_constraint constraint, - double mixRotate, - ) { - return _spine_path_constraint_set_mix_rotate( - constraint, - mixRotate, - ); + void spine_path_constraint_set_mix_rotate(spine_path_constraint constraint, double mixRotate) { + return _spine_path_constraint_set_mix_rotate(constraint, mixRotate); } - late final _spine_path_constraint_set_mix_rotatePtr = _lookup< - ffi - .NativeFunction>( - 'spine_path_constraint_set_mix_rotate'); - late final _spine_path_constraint_set_mix_rotate = - _spine_path_constraint_set_mix_rotatePtr - .asFunction(); + late final _spine_path_constraint_set_mix_rotatePtr = + _lookup>( + 'spine_path_constraint_set_mix_rotate', + ); + late final _spine_path_constraint_set_mix_rotate = _spine_path_constraint_set_mix_rotatePtr + .asFunction(); - double spine_path_constraint_get_mix_x( - spine_path_constraint constraint, - ) { - return _spine_path_constraint_get_mix_x( - constraint, - ); + double spine_path_constraint_get_mix_x(spine_path_constraint constraint) { + return _spine_path_constraint_get_mix_x(constraint); } late final _spine_path_constraint_get_mix_xPtr = - _lookup>( - 'spine_path_constraint_get_mix_x'); - late final _spine_path_constraint_get_mix_x = - _spine_path_constraint_get_mix_xPtr - .asFunction(); + _lookup>('spine_path_constraint_get_mix_x'); + late final _spine_path_constraint_get_mix_x = _spine_path_constraint_get_mix_xPtr + .asFunction(); - void spine_path_constraint_set_mix_x( - spine_path_constraint constraint, - double mixX, - ) { - return _spine_path_constraint_set_mix_x( - constraint, - mixX, - ); + void spine_path_constraint_set_mix_x(spine_path_constraint constraint, double mixX) { + return _spine_path_constraint_set_mix_x(constraint, mixX); } - late final _spine_path_constraint_set_mix_xPtr = _lookup< - ffi - .NativeFunction>( - 'spine_path_constraint_set_mix_x'); - late final _spine_path_constraint_set_mix_x = - _spine_path_constraint_set_mix_xPtr - .asFunction(); + late final _spine_path_constraint_set_mix_xPtr = + _lookup>( + 'spine_path_constraint_set_mix_x', + ); + late final _spine_path_constraint_set_mix_x = _spine_path_constraint_set_mix_xPtr + .asFunction(); - double spine_path_constraint_get_mix_y( - spine_path_constraint constraint, - ) { - return _spine_path_constraint_get_mix_y( - constraint, - ); + double spine_path_constraint_get_mix_y(spine_path_constraint constraint) { + return _spine_path_constraint_get_mix_y(constraint); } late final _spine_path_constraint_get_mix_yPtr = - _lookup>( - 'spine_path_constraint_get_mix_y'); - late final _spine_path_constraint_get_mix_y = - _spine_path_constraint_get_mix_yPtr - .asFunction(); + _lookup>('spine_path_constraint_get_mix_y'); + late final _spine_path_constraint_get_mix_y = _spine_path_constraint_get_mix_yPtr + .asFunction(); - void spine_path_constraint_set_mix_y( - spine_path_constraint constraint, - double mixY, - ) { - return _spine_path_constraint_set_mix_y( - constraint, - mixY, - ); + void spine_path_constraint_set_mix_y(spine_path_constraint constraint, double mixY) { + return _spine_path_constraint_set_mix_y(constraint, mixY); } - late final _spine_path_constraint_set_mix_yPtr = _lookup< - ffi - .NativeFunction>( - 'spine_path_constraint_set_mix_y'); - late final _spine_path_constraint_set_mix_y = - _spine_path_constraint_set_mix_yPtr - .asFunction(); + late final _spine_path_constraint_set_mix_yPtr = + _lookup>( + 'spine_path_constraint_set_mix_y', + ); + late final _spine_path_constraint_set_mix_y = _spine_path_constraint_set_mix_yPtr + .asFunction(); - int spine_path_constraint_get_is_active( - spine_path_constraint constraint, - ) { - return _spine_path_constraint_get_is_active( - constraint, - ); + int spine_path_constraint_get_is_active(spine_path_constraint constraint) { + return _spine_path_constraint_get_is_active(constraint); } late final _spine_path_constraint_get_is_activePtr = - _lookup>( - 'spine_path_constraint_get_is_active'); - late final _spine_path_constraint_get_is_active = - _spine_path_constraint_get_is_activePtr - .asFunction(); + _lookup>('spine_path_constraint_get_is_active'); + late final _spine_path_constraint_get_is_active = _spine_path_constraint_get_is_activePtr + .asFunction(); - void spine_path_constraint_set_is_active( - spine_path_constraint constraint, - int isActive, - ) { - return _spine_path_constraint_set_is_active( - constraint, - isActive, - ); + void spine_path_constraint_set_is_active(spine_path_constraint constraint, int isActive) { + return _spine_path_constraint_set_is_active(constraint, isActive); } - late final _spine_path_constraint_set_is_activePtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_path_constraint, - spine_bool)>>('spine_path_constraint_set_is_active'); - late final _spine_path_constraint_set_is_active = - _spine_path_constraint_set_is_activePtr - .asFunction(); + late final _spine_path_constraint_set_is_activePtr = + _lookup>( + 'spine_path_constraint_set_is_active', + ); + late final _spine_path_constraint_set_is_active = _spine_path_constraint_set_is_activePtr + .asFunction(); /// OMITTED setToSetupPose() - void spine_physics_constraint_data_set_bone( - spine_physics_constraint_data data, - spine_bone_data bone, - ) { - return _spine_physics_constraint_data_set_bone( - data, - bone, - ); + void spine_physics_constraint_data_set_bone(spine_physics_constraint_data data, spine_bone_data bone) { + return _spine_physics_constraint_data_set_bone(data, bone); } - late final _spine_physics_constraint_data_set_bonePtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint_data, - spine_bone_data)>>('spine_physics_constraint_data_set_bone'); - late final _spine_physics_constraint_data_set_bone = - _spine_physics_constraint_data_set_bonePtr.asFunction< - void Function(spine_physics_constraint_data, spine_bone_data)>(); + late final _spine_physics_constraint_data_set_bonePtr = + _lookup>( + 'spine_physics_constraint_data_set_bone', + ); + late final _spine_physics_constraint_data_set_bone = _spine_physics_constraint_data_set_bonePtr + .asFunction(); - spine_bone_data spine_physics_constraint_data_get_bone( - spine_physics_constraint_data data, - ) { - return _spine_physics_constraint_data_get_bone( - data, - ); + spine_bone_data spine_physics_constraint_data_get_bone(spine_physics_constraint_data data) { + return _spine_physics_constraint_data_get_bone(data); } - late final _spine_physics_constraint_data_get_bonePtr = _lookup< - ffi.NativeFunction< - spine_bone_data Function(spine_physics_constraint_data)>>( - 'spine_physics_constraint_data_get_bone'); - late final _spine_physics_constraint_data_get_bone = - _spine_physics_constraint_data_get_bonePtr.asFunction< - spine_bone_data Function(spine_physics_constraint_data)>(); + late final _spine_physics_constraint_data_get_bonePtr = + _lookup>( + 'spine_physics_constraint_data_get_bone', + ); + late final _spine_physics_constraint_data_get_bone = _spine_physics_constraint_data_get_bonePtr + .asFunction(); - void spine_physics_constraint_data_set_x( - spine_physics_constraint_data data, - double x, - ) { - return _spine_physics_constraint_data_set_x( - data, - x, - ); + void spine_physics_constraint_data_set_x(spine_physics_constraint_data data, double x) { + return _spine_physics_constraint_data_set_x(data, x); } - late final _spine_physics_constraint_data_set_xPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint_data, - ffi.Float)>>('spine_physics_constraint_data_set_x'); - late final _spine_physics_constraint_data_set_x = - _spine_physics_constraint_data_set_xPtr - .asFunction(); + late final _spine_physics_constraint_data_set_xPtr = + _lookup>( + 'spine_physics_constraint_data_set_x', + ); + late final _spine_physics_constraint_data_set_x = _spine_physics_constraint_data_set_xPtr + .asFunction(); - double spine_physics_constraint_data_get_x( - spine_physics_constraint_data data, - ) { - return _spine_physics_constraint_data_get_x( - data, - ); + double spine_physics_constraint_data_get_x(spine_physics_constraint_data data) { + return _spine_physics_constraint_data_get_x(data); } - late final _spine_physics_constraint_data_get_xPtr = _lookup< - ffi - .NativeFunction>( - 'spine_physics_constraint_data_get_x'); - late final _spine_physics_constraint_data_get_x = - _spine_physics_constraint_data_get_xPtr - .asFunction(); + late final _spine_physics_constraint_data_get_xPtr = + _lookup>( + 'spine_physics_constraint_data_get_x', + ); + late final _spine_physics_constraint_data_get_x = _spine_physics_constraint_data_get_xPtr + .asFunction(); - void spine_physics_constraint_data_set_y( - spine_physics_constraint_data data, - double y, - ) { - return _spine_physics_constraint_data_set_y( - data, - y, - ); + void spine_physics_constraint_data_set_y(spine_physics_constraint_data data, double y) { + return _spine_physics_constraint_data_set_y(data, y); } - late final _spine_physics_constraint_data_set_yPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint_data, - ffi.Float)>>('spine_physics_constraint_data_set_y'); - late final _spine_physics_constraint_data_set_y = - _spine_physics_constraint_data_set_yPtr - .asFunction(); + late final _spine_physics_constraint_data_set_yPtr = + _lookup>( + 'spine_physics_constraint_data_set_y', + ); + late final _spine_physics_constraint_data_set_y = _spine_physics_constraint_data_set_yPtr + .asFunction(); - double spine_physics_constraint_data_get_y( - spine_physics_constraint_data data, - ) { - return _spine_physics_constraint_data_get_y( - data, - ); + double spine_physics_constraint_data_get_y(spine_physics_constraint_data data) { + return _spine_physics_constraint_data_get_y(data); } - late final _spine_physics_constraint_data_get_yPtr = _lookup< - ffi - .NativeFunction>( - 'spine_physics_constraint_data_get_y'); - late final _spine_physics_constraint_data_get_y = - _spine_physics_constraint_data_get_yPtr - .asFunction(); + late final _spine_physics_constraint_data_get_yPtr = + _lookup>( + 'spine_physics_constraint_data_get_y', + ); + late final _spine_physics_constraint_data_get_y = _spine_physics_constraint_data_get_yPtr + .asFunction(); - void spine_physics_constraint_data_set_rotate( - spine_physics_constraint_data data, - double rotate, - ) { - return _spine_physics_constraint_data_set_rotate( - data, - rotate, - ); + void spine_physics_constraint_data_set_rotate(spine_physics_constraint_data data, double rotate) { + return _spine_physics_constraint_data_set_rotate(data, rotate); } - late final _spine_physics_constraint_data_set_rotatePtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint_data, - ffi.Float)>>('spine_physics_constraint_data_set_rotate'); - late final _spine_physics_constraint_data_set_rotate = - _spine_physics_constraint_data_set_rotatePtr - .asFunction(); + late final _spine_physics_constraint_data_set_rotatePtr = + _lookup>( + 'spine_physics_constraint_data_set_rotate', + ); + late final _spine_physics_constraint_data_set_rotate = _spine_physics_constraint_data_set_rotatePtr + .asFunction(); - double spine_physics_constraint_data_get_rotate( - spine_physics_constraint_data data, - ) { - return _spine_physics_constraint_data_get_rotate( - data, - ); + double spine_physics_constraint_data_get_rotate(spine_physics_constraint_data data) { + return _spine_physics_constraint_data_get_rotate(data); } - late final _spine_physics_constraint_data_get_rotatePtr = _lookup< - ffi - .NativeFunction>( - 'spine_physics_constraint_data_get_rotate'); - late final _spine_physics_constraint_data_get_rotate = - _spine_physics_constraint_data_get_rotatePtr - .asFunction(); + late final _spine_physics_constraint_data_get_rotatePtr = + _lookup>( + 'spine_physics_constraint_data_get_rotate', + ); + late final _spine_physics_constraint_data_get_rotate = _spine_physics_constraint_data_get_rotatePtr + .asFunction(); - void spine_physics_constraint_data_set_scale_x( - spine_physics_constraint_data data, - double scaleX, - ) { - return _spine_physics_constraint_data_set_scale_x( - data, - scaleX, - ); + void spine_physics_constraint_data_set_scale_x(spine_physics_constraint_data data, double scaleX) { + return _spine_physics_constraint_data_set_scale_x(data, scaleX); } - late final _spine_physics_constraint_data_set_scale_xPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint_data, - ffi.Float)>>('spine_physics_constraint_data_set_scale_x'); - late final _spine_physics_constraint_data_set_scale_x = - _spine_physics_constraint_data_set_scale_xPtr - .asFunction(); + late final _spine_physics_constraint_data_set_scale_xPtr = + _lookup>( + 'spine_physics_constraint_data_set_scale_x', + ); + late final _spine_physics_constraint_data_set_scale_x = _spine_physics_constraint_data_set_scale_xPtr + .asFunction(); - double spine_physics_constraint_data_get_scale_x( - spine_physics_constraint_data data, - ) { - return _spine_physics_constraint_data_get_scale_x( - data, - ); + double spine_physics_constraint_data_get_scale_x(spine_physics_constraint_data data) { + return _spine_physics_constraint_data_get_scale_x(data); } - late final _spine_physics_constraint_data_get_scale_xPtr = _lookup< - ffi - .NativeFunction>( - 'spine_physics_constraint_data_get_scale_x'); - late final _spine_physics_constraint_data_get_scale_x = - _spine_physics_constraint_data_get_scale_xPtr - .asFunction(); + late final _spine_physics_constraint_data_get_scale_xPtr = + _lookup>( + 'spine_physics_constraint_data_get_scale_x', + ); + late final _spine_physics_constraint_data_get_scale_x = _spine_physics_constraint_data_get_scale_xPtr + .asFunction(); - void spine_physics_constraint_data_set_shear_x( - spine_physics_constraint_data data, - double shearX, - ) { - return _spine_physics_constraint_data_set_shear_x( - data, - shearX, - ); + void spine_physics_constraint_data_set_shear_x(spine_physics_constraint_data data, double shearX) { + return _spine_physics_constraint_data_set_shear_x(data, shearX); } - late final _spine_physics_constraint_data_set_shear_xPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint_data, - ffi.Float)>>('spine_physics_constraint_data_set_shear_x'); - late final _spine_physics_constraint_data_set_shear_x = - _spine_physics_constraint_data_set_shear_xPtr - .asFunction(); + late final _spine_physics_constraint_data_set_shear_xPtr = + _lookup>( + 'spine_physics_constraint_data_set_shear_x', + ); + late final _spine_physics_constraint_data_set_shear_x = _spine_physics_constraint_data_set_shear_xPtr + .asFunction(); - double spine_physics_constraint_data_get_shear_x( - spine_physics_constraint_data data, - ) { - return _spine_physics_constraint_data_get_shear_x( - data, - ); + double spine_physics_constraint_data_get_shear_x(spine_physics_constraint_data data) { + return _spine_physics_constraint_data_get_shear_x(data); } - late final _spine_physics_constraint_data_get_shear_xPtr = _lookup< - ffi - .NativeFunction>( - 'spine_physics_constraint_data_get_shear_x'); - late final _spine_physics_constraint_data_get_shear_x = - _spine_physics_constraint_data_get_shear_xPtr - .asFunction(); + late final _spine_physics_constraint_data_get_shear_xPtr = + _lookup>( + 'spine_physics_constraint_data_get_shear_x', + ); + late final _spine_physics_constraint_data_get_shear_x = _spine_physics_constraint_data_get_shear_xPtr + .asFunction(); - void spine_physics_constraint_data_set_limit( - spine_physics_constraint_data data, - double limit, - ) { - return _spine_physics_constraint_data_set_limit( - data, - limit, - ); + void spine_physics_constraint_data_set_limit(spine_physics_constraint_data data, double limit) { + return _spine_physics_constraint_data_set_limit(data, limit); } - late final _spine_physics_constraint_data_set_limitPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint_data, - ffi.Float)>>('spine_physics_constraint_data_set_limit'); - late final _spine_physics_constraint_data_set_limit = - _spine_physics_constraint_data_set_limitPtr - .asFunction(); + late final _spine_physics_constraint_data_set_limitPtr = + _lookup>( + 'spine_physics_constraint_data_set_limit', + ); + late final _spine_physics_constraint_data_set_limit = _spine_physics_constraint_data_set_limitPtr + .asFunction(); - double spine_physics_constraint_data_get_limit( - spine_physics_constraint_data data, - ) { - return _spine_physics_constraint_data_get_limit( - data, - ); + double spine_physics_constraint_data_get_limit(spine_physics_constraint_data data) { + return _spine_physics_constraint_data_get_limit(data); } - late final _spine_physics_constraint_data_get_limitPtr = _lookup< - ffi - .NativeFunction>( - 'spine_physics_constraint_data_get_limit'); - late final _spine_physics_constraint_data_get_limit = - _spine_physics_constraint_data_get_limitPtr - .asFunction(); + late final _spine_physics_constraint_data_get_limitPtr = + _lookup>( + 'spine_physics_constraint_data_get_limit', + ); + late final _spine_physics_constraint_data_get_limit = _spine_physics_constraint_data_get_limitPtr + .asFunction(); - void spine_physics_constraint_data_set_step( - spine_physics_constraint_data data, - double step, - ) { - return _spine_physics_constraint_data_set_step( - data, - step, - ); + void spine_physics_constraint_data_set_step(spine_physics_constraint_data data, double step) { + return _spine_physics_constraint_data_set_step(data, step); } - late final _spine_physics_constraint_data_set_stepPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint_data, - ffi.Float)>>('spine_physics_constraint_data_set_step'); - late final _spine_physics_constraint_data_set_step = - _spine_physics_constraint_data_set_stepPtr - .asFunction(); + late final _spine_physics_constraint_data_set_stepPtr = + _lookup>( + 'spine_physics_constraint_data_set_step', + ); + late final _spine_physics_constraint_data_set_step = _spine_physics_constraint_data_set_stepPtr + .asFunction(); - double spine_physics_constraint_data_get_step( - spine_physics_constraint_data data, - ) { - return _spine_physics_constraint_data_get_step( - data, - ); + double spine_physics_constraint_data_get_step(spine_physics_constraint_data data) { + return _spine_physics_constraint_data_get_step(data); } - late final _spine_physics_constraint_data_get_stepPtr = _lookup< - ffi - .NativeFunction>( - 'spine_physics_constraint_data_get_step'); - late final _spine_physics_constraint_data_get_step = - _spine_physics_constraint_data_get_stepPtr - .asFunction(); + late final _spine_physics_constraint_data_get_stepPtr = + _lookup>( + 'spine_physics_constraint_data_get_step', + ); + late final _spine_physics_constraint_data_get_step = _spine_physics_constraint_data_get_stepPtr + .asFunction(); - void spine_physics_constraint_data_set_inertia( - spine_physics_constraint_data data, - double inertia, - ) { - return _spine_physics_constraint_data_set_inertia( - data, - inertia, - ); + void spine_physics_constraint_data_set_inertia(spine_physics_constraint_data data, double inertia) { + return _spine_physics_constraint_data_set_inertia(data, inertia); } - late final _spine_physics_constraint_data_set_inertiaPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint_data, - ffi.Float)>>('spine_physics_constraint_data_set_inertia'); - late final _spine_physics_constraint_data_set_inertia = - _spine_physics_constraint_data_set_inertiaPtr - .asFunction(); + late final _spine_physics_constraint_data_set_inertiaPtr = + _lookup>( + 'spine_physics_constraint_data_set_inertia', + ); + late final _spine_physics_constraint_data_set_inertia = _spine_physics_constraint_data_set_inertiaPtr + .asFunction(); - double spine_physics_constraint_data_get_inertia( - spine_physics_constraint_data data, - ) { - return _spine_physics_constraint_data_get_inertia( - data, - ); + double spine_physics_constraint_data_get_inertia(spine_physics_constraint_data data) { + return _spine_physics_constraint_data_get_inertia(data); } - late final _spine_physics_constraint_data_get_inertiaPtr = _lookup< - ffi - .NativeFunction>( - 'spine_physics_constraint_data_get_inertia'); - late final _spine_physics_constraint_data_get_inertia = - _spine_physics_constraint_data_get_inertiaPtr - .asFunction(); + late final _spine_physics_constraint_data_get_inertiaPtr = + _lookup>( + 'spine_physics_constraint_data_get_inertia', + ); + late final _spine_physics_constraint_data_get_inertia = _spine_physics_constraint_data_get_inertiaPtr + .asFunction(); - void spine_physics_constraint_data_set_strength( - spine_physics_constraint_data data, - double strength, - ) { - return _spine_physics_constraint_data_set_strength( - data, - strength, - ); + void spine_physics_constraint_data_set_strength(spine_physics_constraint_data data, double strength) { + return _spine_physics_constraint_data_set_strength(data, strength); } - late final _spine_physics_constraint_data_set_strengthPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint_data, - ffi.Float)>>('spine_physics_constraint_data_set_strength'); - late final _spine_physics_constraint_data_set_strength = - _spine_physics_constraint_data_set_strengthPtr - .asFunction(); + late final _spine_physics_constraint_data_set_strengthPtr = + _lookup>( + 'spine_physics_constraint_data_set_strength', + ); + late final _spine_physics_constraint_data_set_strength = _spine_physics_constraint_data_set_strengthPtr + .asFunction(); - double spine_physics_constraint_data_get_strength( - spine_physics_constraint_data data, - ) { - return _spine_physics_constraint_data_get_strength( - data, - ); + double spine_physics_constraint_data_get_strength(spine_physics_constraint_data data) { + return _spine_physics_constraint_data_get_strength(data); } - late final _spine_physics_constraint_data_get_strengthPtr = _lookup< - ffi - .NativeFunction>( - 'spine_physics_constraint_data_get_strength'); - late final _spine_physics_constraint_data_get_strength = - _spine_physics_constraint_data_get_strengthPtr - .asFunction(); + late final _spine_physics_constraint_data_get_strengthPtr = + _lookup>( + 'spine_physics_constraint_data_get_strength', + ); + late final _spine_physics_constraint_data_get_strength = _spine_physics_constraint_data_get_strengthPtr + .asFunction(); - void spine_physics_constraint_data_set_damping( - spine_physics_constraint_data data, - double damping, - ) { - return _spine_physics_constraint_data_set_damping( - data, - damping, - ); + void spine_physics_constraint_data_set_damping(spine_physics_constraint_data data, double damping) { + return _spine_physics_constraint_data_set_damping(data, damping); } - late final _spine_physics_constraint_data_set_dampingPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint_data, - ffi.Float)>>('spine_physics_constraint_data_set_damping'); - late final _spine_physics_constraint_data_set_damping = - _spine_physics_constraint_data_set_dampingPtr - .asFunction(); + late final _spine_physics_constraint_data_set_dampingPtr = + _lookup>( + 'spine_physics_constraint_data_set_damping', + ); + late final _spine_physics_constraint_data_set_damping = _spine_physics_constraint_data_set_dampingPtr + .asFunction(); - double spine_physics_constraint_data_get_damping( - spine_physics_constraint_data data, - ) { - return _spine_physics_constraint_data_get_damping( - data, - ); + double spine_physics_constraint_data_get_damping(spine_physics_constraint_data data) { + return _spine_physics_constraint_data_get_damping(data); } - late final _spine_physics_constraint_data_get_dampingPtr = _lookup< - ffi - .NativeFunction>( - 'spine_physics_constraint_data_get_damping'); - late final _spine_physics_constraint_data_get_damping = - _spine_physics_constraint_data_get_dampingPtr - .asFunction(); + late final _spine_physics_constraint_data_get_dampingPtr = + _lookup>( + 'spine_physics_constraint_data_get_damping', + ); + late final _spine_physics_constraint_data_get_damping = _spine_physics_constraint_data_get_dampingPtr + .asFunction(); - void spine_physics_constraint_data_set_mass_inverse( - spine_physics_constraint_data data, - double massInverse, - ) { - return _spine_physics_constraint_data_set_mass_inverse( - data, - massInverse, - ); + void spine_physics_constraint_data_set_mass_inverse(spine_physics_constraint_data data, double massInverse) { + return _spine_physics_constraint_data_set_mass_inverse(data, massInverse); } - late final _spine_physics_constraint_data_set_mass_inversePtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint_data, - ffi.Float)>>('spine_physics_constraint_data_set_mass_inverse'); - late final _spine_physics_constraint_data_set_mass_inverse = - _spine_physics_constraint_data_set_mass_inversePtr - .asFunction(); + late final _spine_physics_constraint_data_set_mass_inversePtr = + _lookup>( + 'spine_physics_constraint_data_set_mass_inverse', + ); + late final _spine_physics_constraint_data_set_mass_inverse = _spine_physics_constraint_data_set_mass_inversePtr + .asFunction(); - double spine_physics_constraint_data_get_mass_inverse( - spine_physics_constraint_data data, - ) { - return _spine_physics_constraint_data_get_mass_inverse( - data, - ); + double spine_physics_constraint_data_get_mass_inverse(spine_physics_constraint_data data) { + return _spine_physics_constraint_data_get_mass_inverse(data); } - late final _spine_physics_constraint_data_get_mass_inversePtr = _lookup< - ffi - .NativeFunction>( - 'spine_physics_constraint_data_get_mass_inverse'); - late final _spine_physics_constraint_data_get_mass_inverse = - _spine_physics_constraint_data_get_mass_inversePtr - .asFunction(); + late final _spine_physics_constraint_data_get_mass_inversePtr = + _lookup>( + 'spine_physics_constraint_data_get_mass_inverse', + ); + late final _spine_physics_constraint_data_get_mass_inverse = _spine_physics_constraint_data_get_mass_inversePtr + .asFunction(); - void spine_physics_constraint_data_set_wind( - spine_physics_constraint_data data, - double wind, - ) { - return _spine_physics_constraint_data_set_wind( - data, - wind, - ); + void spine_physics_constraint_data_set_wind(spine_physics_constraint_data data, double wind) { + return _spine_physics_constraint_data_set_wind(data, wind); } - late final _spine_physics_constraint_data_set_windPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint_data, - ffi.Float)>>('spine_physics_constraint_data_set_wind'); - late final _spine_physics_constraint_data_set_wind = - _spine_physics_constraint_data_set_windPtr - .asFunction(); + late final _spine_physics_constraint_data_set_windPtr = + _lookup>( + 'spine_physics_constraint_data_set_wind', + ); + late final _spine_physics_constraint_data_set_wind = _spine_physics_constraint_data_set_windPtr + .asFunction(); - double spine_physics_constraint_data_get_wind( - spine_physics_constraint_data data, - ) { - return _spine_physics_constraint_data_get_wind( - data, - ); + double spine_physics_constraint_data_get_wind(spine_physics_constraint_data data) { + return _spine_physics_constraint_data_get_wind(data); } - late final _spine_physics_constraint_data_get_windPtr = _lookup< - ffi - .NativeFunction>( - 'spine_physics_constraint_data_get_wind'); - late final _spine_physics_constraint_data_get_wind = - _spine_physics_constraint_data_get_windPtr - .asFunction(); + late final _spine_physics_constraint_data_get_windPtr = + _lookup>( + 'spine_physics_constraint_data_get_wind', + ); + late final _spine_physics_constraint_data_get_wind = _spine_physics_constraint_data_get_windPtr + .asFunction(); - void spine_physics_constraint_data_set_gravity( - spine_physics_constraint_data data, - double gravity, - ) { - return _spine_physics_constraint_data_set_gravity( - data, - gravity, - ); + void spine_physics_constraint_data_set_gravity(spine_physics_constraint_data data, double gravity) { + return _spine_physics_constraint_data_set_gravity(data, gravity); } - late final _spine_physics_constraint_data_set_gravityPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint_data, - ffi.Float)>>('spine_physics_constraint_data_set_gravity'); - late final _spine_physics_constraint_data_set_gravity = - _spine_physics_constraint_data_set_gravityPtr - .asFunction(); + late final _spine_physics_constraint_data_set_gravityPtr = + _lookup>( + 'spine_physics_constraint_data_set_gravity', + ); + late final _spine_physics_constraint_data_set_gravity = _spine_physics_constraint_data_set_gravityPtr + .asFunction(); - double spine_physics_constraint_data_get_gravity( - spine_physics_constraint_data data, - ) { - return _spine_physics_constraint_data_get_gravity( - data, - ); + double spine_physics_constraint_data_get_gravity(spine_physics_constraint_data data) { + return _spine_physics_constraint_data_get_gravity(data); } - late final _spine_physics_constraint_data_get_gravityPtr = _lookup< - ffi - .NativeFunction>( - 'spine_physics_constraint_data_get_gravity'); - late final _spine_physics_constraint_data_get_gravity = - _spine_physics_constraint_data_get_gravityPtr - .asFunction(); + late final _spine_physics_constraint_data_get_gravityPtr = + _lookup>( + 'spine_physics_constraint_data_get_gravity', + ); + late final _spine_physics_constraint_data_get_gravity = _spine_physics_constraint_data_get_gravityPtr + .asFunction(); - void spine_physics_constraint_data_set_mix( - spine_physics_constraint_data data, - double mix, - ) { - return _spine_physics_constraint_data_set_mix( - data, - mix, - ); + void spine_physics_constraint_data_set_mix(spine_physics_constraint_data data, double mix) { + return _spine_physics_constraint_data_set_mix(data, mix); } - late final _spine_physics_constraint_data_set_mixPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint_data, - ffi.Float)>>('spine_physics_constraint_data_set_mix'); - late final _spine_physics_constraint_data_set_mix = - _spine_physics_constraint_data_set_mixPtr - .asFunction(); + late final _spine_physics_constraint_data_set_mixPtr = + _lookup>( + 'spine_physics_constraint_data_set_mix', + ); + late final _spine_physics_constraint_data_set_mix = _spine_physics_constraint_data_set_mixPtr + .asFunction(); - double spine_physics_constraint_data_get_mix( - spine_physics_constraint_data data, - ) { - return _spine_physics_constraint_data_get_mix( - data, - ); + double spine_physics_constraint_data_get_mix(spine_physics_constraint_data data) { + return _spine_physics_constraint_data_get_mix(data); } - late final _spine_physics_constraint_data_get_mixPtr = _lookup< - ffi - .NativeFunction>( - 'spine_physics_constraint_data_get_mix'); - late final _spine_physics_constraint_data_get_mix = - _spine_physics_constraint_data_get_mixPtr - .asFunction(); + late final _spine_physics_constraint_data_get_mixPtr = + _lookup>( + 'spine_physics_constraint_data_get_mix', + ); + late final _spine_physics_constraint_data_get_mix = _spine_physics_constraint_data_get_mixPtr + .asFunction(); - void spine_physics_constraint_data_set_inertia_global( - spine_physics_constraint_data data, - int inertiaGlobal, - ) { - return _spine_physics_constraint_data_set_inertia_global( - data, - inertiaGlobal, - ); + void spine_physics_constraint_data_set_inertia_global(spine_physics_constraint_data data, int inertiaGlobal) { + return _spine_physics_constraint_data_set_inertia_global(data, inertiaGlobal); } - late final _spine_physics_constraint_data_set_inertia_globalPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint_data, - spine_bool)>>('spine_physics_constraint_data_set_inertia_global'); - late final _spine_physics_constraint_data_set_inertia_global = - _spine_physics_constraint_data_set_inertia_globalPtr - .asFunction(); + late final _spine_physics_constraint_data_set_inertia_globalPtr = + _lookup>( + 'spine_physics_constraint_data_set_inertia_global', + ); + late final _spine_physics_constraint_data_set_inertia_global = _spine_physics_constraint_data_set_inertia_globalPtr + .asFunction(); - int spine_physics_constraint_data_is_inertia_global( - spine_physics_constraint_data data, - ) { - return _spine_physics_constraint_data_is_inertia_global( - data, - ); + int spine_physics_constraint_data_is_inertia_global(spine_physics_constraint_data data) { + return _spine_physics_constraint_data_is_inertia_global(data); } - late final _spine_physics_constraint_data_is_inertia_globalPtr = _lookup< - ffi - .NativeFunction>( - 'spine_physics_constraint_data_is_inertia_global'); - late final _spine_physics_constraint_data_is_inertia_global = - _spine_physics_constraint_data_is_inertia_globalPtr - .asFunction(); + late final _spine_physics_constraint_data_is_inertia_globalPtr = + _lookup>( + 'spine_physics_constraint_data_is_inertia_global', + ); + late final _spine_physics_constraint_data_is_inertia_global = _spine_physics_constraint_data_is_inertia_globalPtr + .asFunction(); - void spine_physics_constraint_data_set_strength_global( - spine_physics_constraint_data data, - int strengthGlobal, - ) { - return _spine_physics_constraint_data_set_strength_global( - data, - strengthGlobal, - ); + void spine_physics_constraint_data_set_strength_global(spine_physics_constraint_data data, int strengthGlobal) { + return _spine_physics_constraint_data_set_strength_global(data, strengthGlobal); } - late final _spine_physics_constraint_data_set_strength_globalPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint_data, spine_bool)>>( - 'spine_physics_constraint_data_set_strength_global'); - late final _spine_physics_constraint_data_set_strength_global = - _spine_physics_constraint_data_set_strength_globalPtr - .asFunction(); + late final _spine_physics_constraint_data_set_strength_globalPtr = + _lookup>( + 'spine_physics_constraint_data_set_strength_global', + ); + late final _spine_physics_constraint_data_set_strength_global = _spine_physics_constraint_data_set_strength_globalPtr + .asFunction(); - int spine_physics_constraint_data_is_strength_global( - spine_physics_constraint_data data, - ) { - return _spine_physics_constraint_data_is_strength_global( - data, - ); + int spine_physics_constraint_data_is_strength_global(spine_physics_constraint_data data) { + return _spine_physics_constraint_data_is_strength_global(data); } - late final _spine_physics_constraint_data_is_strength_globalPtr = _lookup< - ffi - .NativeFunction>( - 'spine_physics_constraint_data_is_strength_global'); - late final _spine_physics_constraint_data_is_strength_global = - _spine_physics_constraint_data_is_strength_globalPtr - .asFunction(); + late final _spine_physics_constraint_data_is_strength_globalPtr = + _lookup>( + 'spine_physics_constraint_data_is_strength_global', + ); + late final _spine_physics_constraint_data_is_strength_global = _spine_physics_constraint_data_is_strength_globalPtr + .asFunction(); - void spine_physics_constraint_data_set_damping_global( - spine_physics_constraint_data data, - int dampingGlobal, - ) { - return _spine_physics_constraint_data_set_damping_global( - data, - dampingGlobal, - ); + void spine_physics_constraint_data_set_damping_global(spine_physics_constraint_data data, int dampingGlobal) { + return _spine_physics_constraint_data_set_damping_global(data, dampingGlobal); } - late final _spine_physics_constraint_data_set_damping_globalPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint_data, - spine_bool)>>('spine_physics_constraint_data_set_damping_global'); - late final _spine_physics_constraint_data_set_damping_global = - _spine_physics_constraint_data_set_damping_globalPtr - .asFunction(); + late final _spine_physics_constraint_data_set_damping_globalPtr = + _lookup>( + 'spine_physics_constraint_data_set_damping_global', + ); + late final _spine_physics_constraint_data_set_damping_global = _spine_physics_constraint_data_set_damping_globalPtr + .asFunction(); - int spine_physics_constraint_data_is_damping_global( - spine_physics_constraint_data data, - ) { - return _spine_physics_constraint_data_is_damping_global( - data, - ); + int spine_physics_constraint_data_is_damping_global(spine_physics_constraint_data data) { + return _spine_physics_constraint_data_is_damping_global(data); } - late final _spine_physics_constraint_data_is_damping_globalPtr = _lookup< - ffi - .NativeFunction>( - 'spine_physics_constraint_data_is_damping_global'); - late final _spine_physics_constraint_data_is_damping_global = - _spine_physics_constraint_data_is_damping_globalPtr - .asFunction(); + late final _spine_physics_constraint_data_is_damping_globalPtr = + _lookup>( + 'spine_physics_constraint_data_is_damping_global', + ); + late final _spine_physics_constraint_data_is_damping_global = _spine_physics_constraint_data_is_damping_globalPtr + .asFunction(); - void spine_physics_constraint_data_set_mass_global( - spine_physics_constraint_data data, - int massGlobal, - ) { - return _spine_physics_constraint_data_set_mass_global( - data, - massGlobal, - ); + void spine_physics_constraint_data_set_mass_global(spine_physics_constraint_data data, int massGlobal) { + return _spine_physics_constraint_data_set_mass_global(data, massGlobal); } - late final _spine_physics_constraint_data_set_mass_globalPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint_data, - spine_bool)>>('spine_physics_constraint_data_set_mass_global'); - late final _spine_physics_constraint_data_set_mass_global = - _spine_physics_constraint_data_set_mass_globalPtr - .asFunction(); + late final _spine_physics_constraint_data_set_mass_globalPtr = + _lookup>( + 'spine_physics_constraint_data_set_mass_global', + ); + late final _spine_physics_constraint_data_set_mass_global = _spine_physics_constraint_data_set_mass_globalPtr + .asFunction(); - int spine_physics_constraint_data_is_mass_global( - spine_physics_constraint_data data, - ) { - return _spine_physics_constraint_data_is_mass_global( - data, - ); + int spine_physics_constraint_data_is_mass_global(spine_physics_constraint_data data) { + return _spine_physics_constraint_data_is_mass_global(data); } - late final _spine_physics_constraint_data_is_mass_globalPtr = _lookup< - ffi - .NativeFunction>( - 'spine_physics_constraint_data_is_mass_global'); - late final _spine_physics_constraint_data_is_mass_global = - _spine_physics_constraint_data_is_mass_globalPtr - .asFunction(); + late final _spine_physics_constraint_data_is_mass_globalPtr = + _lookup>( + 'spine_physics_constraint_data_is_mass_global', + ); + late final _spine_physics_constraint_data_is_mass_global = _spine_physics_constraint_data_is_mass_globalPtr + .asFunction(); - void spine_physics_constraint_data_set_wind_global( - spine_physics_constraint_data data, - int windGlobal, - ) { - return _spine_physics_constraint_data_set_wind_global( - data, - windGlobal, - ); + void spine_physics_constraint_data_set_wind_global(spine_physics_constraint_data data, int windGlobal) { + return _spine_physics_constraint_data_set_wind_global(data, windGlobal); } - late final _spine_physics_constraint_data_set_wind_globalPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint_data, - spine_bool)>>('spine_physics_constraint_data_set_wind_global'); - late final _spine_physics_constraint_data_set_wind_global = - _spine_physics_constraint_data_set_wind_globalPtr - .asFunction(); + late final _spine_physics_constraint_data_set_wind_globalPtr = + _lookup>( + 'spine_physics_constraint_data_set_wind_global', + ); + late final _spine_physics_constraint_data_set_wind_global = _spine_physics_constraint_data_set_wind_globalPtr + .asFunction(); - int spine_physics_constraint_data_is_wind_global( - spine_physics_constraint_data data, - ) { - return _spine_physics_constraint_data_is_wind_global( - data, - ); + int spine_physics_constraint_data_is_wind_global(spine_physics_constraint_data data) { + return _spine_physics_constraint_data_is_wind_global(data); } - late final _spine_physics_constraint_data_is_wind_globalPtr = _lookup< - ffi - .NativeFunction>( - 'spine_physics_constraint_data_is_wind_global'); - late final _spine_physics_constraint_data_is_wind_global = - _spine_physics_constraint_data_is_wind_globalPtr - .asFunction(); + late final _spine_physics_constraint_data_is_wind_globalPtr = + _lookup>( + 'spine_physics_constraint_data_is_wind_global', + ); + late final _spine_physics_constraint_data_is_wind_global = _spine_physics_constraint_data_is_wind_globalPtr + .asFunction(); - void spine_physics_constraint_data_set_gravity_global( - spine_physics_constraint_data data, - int gravityGlobal, - ) { - return _spine_physics_constraint_data_set_gravity_global( - data, - gravityGlobal, - ); + void spine_physics_constraint_data_set_gravity_global(spine_physics_constraint_data data, int gravityGlobal) { + return _spine_physics_constraint_data_set_gravity_global(data, gravityGlobal); } - late final _spine_physics_constraint_data_set_gravity_globalPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint_data, - spine_bool)>>('spine_physics_constraint_data_set_gravity_global'); - late final _spine_physics_constraint_data_set_gravity_global = - _spine_physics_constraint_data_set_gravity_globalPtr - .asFunction(); + late final _spine_physics_constraint_data_set_gravity_globalPtr = + _lookup>( + 'spine_physics_constraint_data_set_gravity_global', + ); + late final _spine_physics_constraint_data_set_gravity_global = _spine_physics_constraint_data_set_gravity_globalPtr + .asFunction(); - int spine_physics_constraint_data_is_gravity_global( - spine_physics_constraint_data data, - ) { - return _spine_physics_constraint_data_is_gravity_global( - data, - ); + int spine_physics_constraint_data_is_gravity_global(spine_physics_constraint_data data) { + return _spine_physics_constraint_data_is_gravity_global(data); } - late final _spine_physics_constraint_data_is_gravity_globalPtr = _lookup< - ffi - .NativeFunction>( - 'spine_physics_constraint_data_is_gravity_global'); - late final _spine_physics_constraint_data_is_gravity_global = - _spine_physics_constraint_data_is_gravity_globalPtr - .asFunction(); + late final _spine_physics_constraint_data_is_gravity_globalPtr = + _lookup>( + 'spine_physics_constraint_data_is_gravity_global', + ); + late final _spine_physics_constraint_data_is_gravity_global = _spine_physics_constraint_data_is_gravity_globalPtr + .asFunction(); - void spine_physics_constraint_data_set_mix_global( - spine_physics_constraint_data data, - int mixGlobal, - ) { - return _spine_physics_constraint_data_set_mix_global( - data, - mixGlobal, - ); + void spine_physics_constraint_data_set_mix_global(spine_physics_constraint_data data, int mixGlobal) { + return _spine_physics_constraint_data_set_mix_global(data, mixGlobal); } - late final _spine_physics_constraint_data_set_mix_globalPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint_data, - spine_bool)>>('spine_physics_constraint_data_set_mix_global'); - late final _spine_physics_constraint_data_set_mix_global = - _spine_physics_constraint_data_set_mix_globalPtr - .asFunction(); + late final _spine_physics_constraint_data_set_mix_globalPtr = + _lookup>( + 'spine_physics_constraint_data_set_mix_global', + ); + late final _spine_physics_constraint_data_set_mix_global = _spine_physics_constraint_data_set_mix_globalPtr + .asFunction(); - int spine_physics_constraint_data_is_mix_global( - spine_physics_constraint_data data, - ) { - return _spine_physics_constraint_data_is_mix_global( - data, - ); + int spine_physics_constraint_data_is_mix_global(spine_physics_constraint_data data) { + return _spine_physics_constraint_data_is_mix_global(data); } - late final _spine_physics_constraint_data_is_mix_globalPtr = _lookup< - ffi - .NativeFunction>( - 'spine_physics_constraint_data_is_mix_global'); - late final _spine_physics_constraint_data_is_mix_global = - _spine_physics_constraint_data_is_mix_globalPtr - .asFunction(); + late final _spine_physics_constraint_data_is_mix_globalPtr = + _lookup>( + 'spine_physics_constraint_data_is_mix_global', + ); + late final _spine_physics_constraint_data_is_mix_global = _spine_physics_constraint_data_is_mix_globalPtr + .asFunction(); - void spine_physics_constraint_set_bone( - spine_physics_constraint constraint, - spine_bone bone, - ) { - return _spine_physics_constraint_set_bone( - constraint, - bone, - ); + void spine_physics_constraint_set_bone(spine_physics_constraint constraint, spine_bone bone) { + return _spine_physics_constraint_set_bone(constraint, bone); } - late final _spine_physics_constraint_set_bonePtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint, - spine_bone)>>('spine_physics_constraint_set_bone'); - late final _spine_physics_constraint_set_bone = - _spine_physics_constraint_set_bonePtr - .asFunction(); + late final _spine_physics_constraint_set_bonePtr = + _lookup>( + 'spine_physics_constraint_set_bone', + ); + late final _spine_physics_constraint_set_bone = _spine_physics_constraint_set_bonePtr + .asFunction(); - spine_bone spine_physics_constraint_get_bone( - spine_physics_constraint constraint, - ) { - return _spine_physics_constraint_get_bone( - constraint, - ); + spine_bone spine_physics_constraint_get_bone(spine_physics_constraint constraint) { + return _spine_physics_constraint_get_bone(constraint); } - late final _spine_physics_constraint_get_bonePtr = _lookup< - ffi.NativeFunction>( - 'spine_physics_constraint_get_bone'); - late final _spine_physics_constraint_get_bone = - _spine_physics_constraint_get_bonePtr - .asFunction(); + late final _spine_physics_constraint_get_bonePtr = + _lookup>('spine_physics_constraint_get_bone'); + late final _spine_physics_constraint_get_bone = _spine_physics_constraint_get_bonePtr + .asFunction(); - void spine_physics_constraint_set_inertia( - spine_physics_constraint constraint, - double value, - ) { - return _spine_physics_constraint_set_inertia( - constraint, - value, - ); + void spine_physics_constraint_set_inertia(spine_physics_constraint constraint, double value) { + return _spine_physics_constraint_set_inertia(constraint, value); } - late final _spine_physics_constraint_set_inertiaPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint, - ffi.Float)>>('spine_physics_constraint_set_inertia'); - late final _spine_physics_constraint_set_inertia = - _spine_physics_constraint_set_inertiaPtr - .asFunction(); + late final _spine_physics_constraint_set_inertiaPtr = + _lookup>( + 'spine_physics_constraint_set_inertia', + ); + late final _spine_physics_constraint_set_inertia = _spine_physics_constraint_set_inertiaPtr + .asFunction(); - double spine_physics_constraint_get_inertia( - spine_physics_constraint constraint, - ) { - return _spine_physics_constraint_get_inertia( - constraint, - ); + double spine_physics_constraint_get_inertia(spine_physics_constraint constraint) { + return _spine_physics_constraint_get_inertia(constraint); } late final _spine_physics_constraint_get_inertiaPtr = - _lookup>( - 'spine_physics_constraint_get_inertia'); - late final _spine_physics_constraint_get_inertia = - _spine_physics_constraint_get_inertiaPtr - .asFunction(); + _lookup>('spine_physics_constraint_get_inertia'); + late final _spine_physics_constraint_get_inertia = _spine_physics_constraint_get_inertiaPtr + .asFunction(); - void spine_physics_constraint_set_strength( - spine_physics_constraint constraint, - double value, - ) { - return _spine_physics_constraint_set_strength( - constraint, - value, - ); + void spine_physics_constraint_set_strength(spine_physics_constraint constraint, double value) { + return _spine_physics_constraint_set_strength(constraint, value); } - late final _spine_physics_constraint_set_strengthPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint, - ffi.Float)>>('spine_physics_constraint_set_strength'); - late final _spine_physics_constraint_set_strength = - _spine_physics_constraint_set_strengthPtr - .asFunction(); + late final _spine_physics_constraint_set_strengthPtr = + _lookup>( + 'spine_physics_constraint_set_strength', + ); + late final _spine_physics_constraint_set_strength = _spine_physics_constraint_set_strengthPtr + .asFunction(); - double spine_physics_constraint_get_strength( - spine_physics_constraint constraint, - ) { - return _spine_physics_constraint_get_strength( - constraint, - ); + double spine_physics_constraint_get_strength(spine_physics_constraint constraint) { + return _spine_physics_constraint_get_strength(constraint); } late final _spine_physics_constraint_get_strengthPtr = _lookup>( - 'spine_physics_constraint_get_strength'); - late final _spine_physics_constraint_get_strength = - _spine_physics_constraint_get_strengthPtr - .asFunction(); + 'spine_physics_constraint_get_strength', + ); + late final _spine_physics_constraint_get_strength = _spine_physics_constraint_get_strengthPtr + .asFunction(); - void spine_physics_constraint_set_damping( - spine_physics_constraint constraint, - double value, - ) { - return _spine_physics_constraint_set_damping( - constraint, - value, - ); + void spine_physics_constraint_set_damping(spine_physics_constraint constraint, double value) { + return _spine_physics_constraint_set_damping(constraint, value); } - late final _spine_physics_constraint_set_dampingPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint, - ffi.Float)>>('spine_physics_constraint_set_damping'); - late final _spine_physics_constraint_set_damping = - _spine_physics_constraint_set_dampingPtr - .asFunction(); + late final _spine_physics_constraint_set_dampingPtr = + _lookup>( + 'spine_physics_constraint_set_damping', + ); + late final _spine_physics_constraint_set_damping = _spine_physics_constraint_set_dampingPtr + .asFunction(); - double spine_physics_constraint_get_damping( - spine_physics_constraint constraint, - ) { - return _spine_physics_constraint_get_damping( - constraint, - ); + double spine_physics_constraint_get_damping(spine_physics_constraint constraint) { + return _spine_physics_constraint_get_damping(constraint); } late final _spine_physics_constraint_get_dampingPtr = - _lookup>( - 'spine_physics_constraint_get_damping'); - late final _spine_physics_constraint_get_damping = - _spine_physics_constraint_get_dampingPtr - .asFunction(); + _lookup>('spine_physics_constraint_get_damping'); + late final _spine_physics_constraint_get_damping = _spine_physics_constraint_get_dampingPtr + .asFunction(); - void spine_physics_constraint_set_mass_inverse( - spine_physics_constraint constraint, - double value, - ) { - return _spine_physics_constraint_set_mass_inverse( - constraint, - value, - ); + void spine_physics_constraint_set_mass_inverse(spine_physics_constraint constraint, double value) { + return _spine_physics_constraint_set_mass_inverse(constraint, value); } - late final _spine_physics_constraint_set_mass_inversePtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint, - ffi.Float)>>('spine_physics_constraint_set_mass_inverse'); - late final _spine_physics_constraint_set_mass_inverse = - _spine_physics_constraint_set_mass_inversePtr - .asFunction(); + late final _spine_physics_constraint_set_mass_inversePtr = + _lookup>( + 'spine_physics_constraint_set_mass_inverse', + ); + late final _spine_physics_constraint_set_mass_inverse = _spine_physics_constraint_set_mass_inversePtr + .asFunction(); - double spine_physics_constraint_get_mass_inverse( - spine_physics_constraint constraint, - ) { - return _spine_physics_constraint_get_mass_inverse( - constraint, - ); + double spine_physics_constraint_get_mass_inverse(spine_physics_constraint constraint) { + return _spine_physics_constraint_get_mass_inverse(constraint); } late final _spine_physics_constraint_get_mass_inversePtr = _lookup>( - 'spine_physics_constraint_get_mass_inverse'); - late final _spine_physics_constraint_get_mass_inverse = - _spine_physics_constraint_get_mass_inversePtr - .asFunction(); + 'spine_physics_constraint_get_mass_inverse', + ); + late final _spine_physics_constraint_get_mass_inverse = _spine_physics_constraint_get_mass_inversePtr + .asFunction(); - void spine_physics_constraint_set_wind( - spine_physics_constraint constraint, - double value, - ) { - return _spine_physics_constraint_set_wind( - constraint, - value, - ); + void spine_physics_constraint_set_wind(spine_physics_constraint constraint, double value) { + return _spine_physics_constraint_set_wind(constraint, value); } - late final _spine_physics_constraint_set_windPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint, - ffi.Float)>>('spine_physics_constraint_set_wind'); - late final _spine_physics_constraint_set_wind = - _spine_physics_constraint_set_windPtr - .asFunction(); + late final _spine_physics_constraint_set_windPtr = + _lookup>( + 'spine_physics_constraint_set_wind', + ); + late final _spine_physics_constraint_set_wind = _spine_physics_constraint_set_windPtr + .asFunction(); - double spine_physics_constraint_get_wind( - spine_physics_constraint constraint, - ) { - return _spine_physics_constraint_get_wind( - constraint, - ); + double spine_physics_constraint_get_wind(spine_physics_constraint constraint) { + return _spine_physics_constraint_get_wind(constraint); } late final _spine_physics_constraint_get_windPtr = - _lookup>( - 'spine_physics_constraint_get_wind'); - late final _spine_physics_constraint_get_wind = - _spine_physics_constraint_get_windPtr - .asFunction(); + _lookup>('spine_physics_constraint_get_wind'); + late final _spine_physics_constraint_get_wind = _spine_physics_constraint_get_windPtr + .asFunction(); - void spine_physics_constraint_set_gravity( - spine_physics_constraint constraint, - double value, - ) { - return _spine_physics_constraint_set_gravity( - constraint, - value, - ); + void spine_physics_constraint_set_gravity(spine_physics_constraint constraint, double value) { + return _spine_physics_constraint_set_gravity(constraint, value); } - late final _spine_physics_constraint_set_gravityPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint, - ffi.Float)>>('spine_physics_constraint_set_gravity'); - late final _spine_physics_constraint_set_gravity = - _spine_physics_constraint_set_gravityPtr - .asFunction(); + late final _spine_physics_constraint_set_gravityPtr = + _lookup>( + 'spine_physics_constraint_set_gravity', + ); + late final _spine_physics_constraint_set_gravity = _spine_physics_constraint_set_gravityPtr + .asFunction(); - double spine_physics_constraint_get_gravity( - spine_physics_constraint constraint, - ) { - return _spine_physics_constraint_get_gravity( - constraint, - ); + double spine_physics_constraint_get_gravity(spine_physics_constraint constraint) { + return _spine_physics_constraint_get_gravity(constraint); } late final _spine_physics_constraint_get_gravityPtr = - _lookup>( - 'spine_physics_constraint_get_gravity'); - late final _spine_physics_constraint_get_gravity = - _spine_physics_constraint_get_gravityPtr - .asFunction(); + _lookup>('spine_physics_constraint_get_gravity'); + late final _spine_physics_constraint_get_gravity = _spine_physics_constraint_get_gravityPtr + .asFunction(); - void spine_physics_constraint_set_mix( - spine_physics_constraint constraint, - double value, - ) { - return _spine_physics_constraint_set_mix( - constraint, - value, - ); + void spine_physics_constraint_set_mix(spine_physics_constraint constraint, double value) { + return _spine_physics_constraint_set_mix(constraint, value); } - late final _spine_physics_constraint_set_mixPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint, - ffi.Float)>>('spine_physics_constraint_set_mix'); - late final _spine_physics_constraint_set_mix = - _spine_physics_constraint_set_mixPtr - .asFunction(); + late final _spine_physics_constraint_set_mixPtr = + _lookup>( + 'spine_physics_constraint_set_mix', + ); + late final _spine_physics_constraint_set_mix = _spine_physics_constraint_set_mixPtr + .asFunction(); - double spine_physics_constraint_get_mix( - spine_physics_constraint constraint, - ) { - return _spine_physics_constraint_get_mix( - constraint, - ); + double spine_physics_constraint_get_mix(spine_physics_constraint constraint) { + return _spine_physics_constraint_get_mix(constraint); } late final _spine_physics_constraint_get_mixPtr = - _lookup>( - 'spine_physics_constraint_get_mix'); - late final _spine_physics_constraint_get_mix = - _spine_physics_constraint_get_mixPtr - .asFunction(); + _lookup>('spine_physics_constraint_get_mix'); + late final _spine_physics_constraint_get_mix = _spine_physics_constraint_get_mixPtr + .asFunction(); - void spine_physics_constraint_set_reset( - spine_physics_constraint constraint, - int value, - ) { - return _spine_physics_constraint_set_reset( - constraint, - value, - ); + void spine_physics_constraint_set_reset(spine_physics_constraint constraint, int value) { + return _spine_physics_constraint_set_reset(constraint, value); } - late final _spine_physics_constraint_set_resetPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint, - spine_bool)>>('spine_physics_constraint_set_reset'); - late final _spine_physics_constraint_set_reset = - _spine_physics_constraint_set_resetPtr - .asFunction(); + late final _spine_physics_constraint_set_resetPtr = + _lookup>( + 'spine_physics_constraint_set_reset', + ); + late final _spine_physics_constraint_set_reset = _spine_physics_constraint_set_resetPtr + .asFunction(); - int spine_physics_constraint_get_reset( - spine_physics_constraint constraint, - ) { - return _spine_physics_constraint_get_reset( - constraint, - ); + int spine_physics_constraint_get_reset(spine_physics_constraint constraint) { + return _spine_physics_constraint_get_reset(constraint); } - late final _spine_physics_constraint_get_resetPtr = _lookup< - ffi.NativeFunction>( - 'spine_physics_constraint_get_reset'); - late final _spine_physics_constraint_get_reset = - _spine_physics_constraint_get_resetPtr - .asFunction(); + late final _spine_physics_constraint_get_resetPtr = + _lookup>('spine_physics_constraint_get_reset'); + late final _spine_physics_constraint_get_reset = _spine_physics_constraint_get_resetPtr + .asFunction(); - void spine_physics_constraint_set_ux( - spine_physics_constraint constraint, - double value, - ) { - return _spine_physics_constraint_set_ux( - constraint, - value, - ); + void spine_physics_constraint_set_ux(spine_physics_constraint constraint, double value) { + return _spine_physics_constraint_set_ux(constraint, value); } - late final _spine_physics_constraint_set_uxPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint, - ffi.Float)>>('spine_physics_constraint_set_ux'); - late final _spine_physics_constraint_set_ux = - _spine_physics_constraint_set_uxPtr - .asFunction(); + late final _spine_physics_constraint_set_uxPtr = + _lookup>( + 'spine_physics_constraint_set_ux', + ); + late final _spine_physics_constraint_set_ux = _spine_physics_constraint_set_uxPtr + .asFunction(); - double spine_physics_constraint_get_ux( - spine_physics_constraint constraint, - ) { - return _spine_physics_constraint_get_ux( - constraint, - ); + double spine_physics_constraint_get_ux(spine_physics_constraint constraint) { + return _spine_physics_constraint_get_ux(constraint); } late final _spine_physics_constraint_get_uxPtr = - _lookup>( - 'spine_physics_constraint_get_ux'); - late final _spine_physics_constraint_get_ux = - _spine_physics_constraint_get_uxPtr - .asFunction(); + _lookup>('spine_physics_constraint_get_ux'); + late final _spine_physics_constraint_get_ux = _spine_physics_constraint_get_uxPtr + .asFunction(); - void spine_physics_constraint_set_uy( - spine_physics_constraint constraint, - double value, - ) { - return _spine_physics_constraint_set_uy( - constraint, - value, - ); + void spine_physics_constraint_set_uy(spine_physics_constraint constraint, double value) { + return _spine_physics_constraint_set_uy(constraint, value); } - late final _spine_physics_constraint_set_uyPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint, - ffi.Float)>>('spine_physics_constraint_set_uy'); - late final _spine_physics_constraint_set_uy = - _spine_physics_constraint_set_uyPtr - .asFunction(); + late final _spine_physics_constraint_set_uyPtr = + _lookup>( + 'spine_physics_constraint_set_uy', + ); + late final _spine_physics_constraint_set_uy = _spine_physics_constraint_set_uyPtr + .asFunction(); - double spine_physics_constraint_get_uy( - spine_physics_constraint constraint, - ) { - return _spine_physics_constraint_get_uy( - constraint, - ); + double spine_physics_constraint_get_uy(spine_physics_constraint constraint) { + return _spine_physics_constraint_get_uy(constraint); } late final _spine_physics_constraint_get_uyPtr = - _lookup>( - 'spine_physics_constraint_get_uy'); - late final _spine_physics_constraint_get_uy = - _spine_physics_constraint_get_uyPtr - .asFunction(); + _lookup>('spine_physics_constraint_get_uy'); + late final _spine_physics_constraint_get_uy = _spine_physics_constraint_get_uyPtr + .asFunction(); - void spine_physics_constraint_set_cx( - spine_physics_constraint constraint, - double value, - ) { - return _spine_physics_constraint_set_cx( - constraint, - value, - ); + void spine_physics_constraint_set_cx(spine_physics_constraint constraint, double value) { + return _spine_physics_constraint_set_cx(constraint, value); } - late final _spine_physics_constraint_set_cxPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint, - ffi.Float)>>('spine_physics_constraint_set_cx'); - late final _spine_physics_constraint_set_cx = - _spine_physics_constraint_set_cxPtr - .asFunction(); + late final _spine_physics_constraint_set_cxPtr = + _lookup>( + 'spine_physics_constraint_set_cx', + ); + late final _spine_physics_constraint_set_cx = _spine_physics_constraint_set_cxPtr + .asFunction(); - double spine_physics_constraint_get_cx( - spine_physics_constraint constraint, - ) { - return _spine_physics_constraint_get_cx( - constraint, - ); + double spine_physics_constraint_get_cx(spine_physics_constraint constraint) { + return _spine_physics_constraint_get_cx(constraint); } late final _spine_physics_constraint_get_cxPtr = - _lookup>( - 'spine_physics_constraint_get_cx'); - late final _spine_physics_constraint_get_cx = - _spine_physics_constraint_get_cxPtr - .asFunction(); + _lookup>('spine_physics_constraint_get_cx'); + late final _spine_physics_constraint_get_cx = _spine_physics_constraint_get_cxPtr + .asFunction(); - void spine_physics_constraint_set_cy( - spine_physics_constraint constraint, - double value, - ) { - return _spine_physics_constraint_set_cy( - constraint, - value, - ); + void spine_physics_constraint_set_cy(spine_physics_constraint constraint, double value) { + return _spine_physics_constraint_set_cy(constraint, value); } - late final _spine_physics_constraint_set_cyPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint, - ffi.Float)>>('spine_physics_constraint_set_cy'); - late final _spine_physics_constraint_set_cy = - _spine_physics_constraint_set_cyPtr - .asFunction(); + late final _spine_physics_constraint_set_cyPtr = + _lookup>( + 'spine_physics_constraint_set_cy', + ); + late final _spine_physics_constraint_set_cy = _spine_physics_constraint_set_cyPtr + .asFunction(); - double spine_physics_constraint_get_cy( - spine_physics_constraint constraint, - ) { - return _spine_physics_constraint_get_cy( - constraint, - ); + double spine_physics_constraint_get_cy(spine_physics_constraint constraint) { + return _spine_physics_constraint_get_cy(constraint); } late final _spine_physics_constraint_get_cyPtr = - _lookup>( - 'spine_physics_constraint_get_cy'); - late final _spine_physics_constraint_get_cy = - _spine_physics_constraint_get_cyPtr - .asFunction(); + _lookup>('spine_physics_constraint_get_cy'); + late final _spine_physics_constraint_get_cy = _spine_physics_constraint_get_cyPtr + .asFunction(); - void spine_physics_constraint_set_tx( - spine_physics_constraint constraint, - double value, - ) { - return _spine_physics_constraint_set_tx( - constraint, - value, - ); + void spine_physics_constraint_set_tx(spine_physics_constraint constraint, double value) { + return _spine_physics_constraint_set_tx(constraint, value); } - late final _spine_physics_constraint_set_txPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint, - ffi.Float)>>('spine_physics_constraint_set_tx'); - late final _spine_physics_constraint_set_tx = - _spine_physics_constraint_set_txPtr - .asFunction(); + late final _spine_physics_constraint_set_txPtr = + _lookup>( + 'spine_physics_constraint_set_tx', + ); + late final _spine_physics_constraint_set_tx = _spine_physics_constraint_set_txPtr + .asFunction(); - double spine_physics_constraint_get_tx( - spine_physics_constraint constraint, - ) { - return _spine_physics_constraint_get_tx( - constraint, - ); + double spine_physics_constraint_get_tx(spine_physics_constraint constraint) { + return _spine_physics_constraint_get_tx(constraint); } late final _spine_physics_constraint_get_txPtr = - _lookup>( - 'spine_physics_constraint_get_tx'); - late final _spine_physics_constraint_get_tx = - _spine_physics_constraint_get_txPtr - .asFunction(); + _lookup>('spine_physics_constraint_get_tx'); + late final _spine_physics_constraint_get_tx = _spine_physics_constraint_get_txPtr + .asFunction(); - void spine_physics_constraint_set_ty( - spine_physics_constraint constraint, - double value, - ) { - return _spine_physics_constraint_set_ty( - constraint, - value, - ); + void spine_physics_constraint_set_ty(spine_physics_constraint constraint, double value) { + return _spine_physics_constraint_set_ty(constraint, value); } - late final _spine_physics_constraint_set_tyPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint, - ffi.Float)>>('spine_physics_constraint_set_ty'); - late final _spine_physics_constraint_set_ty = - _spine_physics_constraint_set_tyPtr - .asFunction(); + late final _spine_physics_constraint_set_tyPtr = + _lookup>( + 'spine_physics_constraint_set_ty', + ); + late final _spine_physics_constraint_set_ty = _spine_physics_constraint_set_tyPtr + .asFunction(); - double spine_physics_constraint_get_ty( - spine_physics_constraint constraint, - ) { - return _spine_physics_constraint_get_ty( - constraint, - ); + double spine_physics_constraint_get_ty(spine_physics_constraint constraint) { + return _spine_physics_constraint_get_ty(constraint); } late final _spine_physics_constraint_get_tyPtr = - _lookup>( - 'spine_physics_constraint_get_ty'); - late final _spine_physics_constraint_get_ty = - _spine_physics_constraint_get_tyPtr - .asFunction(); + _lookup>('spine_physics_constraint_get_ty'); + late final _spine_physics_constraint_get_ty = _spine_physics_constraint_get_tyPtr + .asFunction(); - void spine_physics_constraint_set_x_offset( - spine_physics_constraint constraint, - double value, - ) { - return _spine_physics_constraint_set_x_offset( - constraint, - value, - ); + void spine_physics_constraint_set_x_offset(spine_physics_constraint constraint, double value) { + return _spine_physics_constraint_set_x_offset(constraint, value); } - late final _spine_physics_constraint_set_x_offsetPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint, - ffi.Float)>>('spine_physics_constraint_set_x_offset'); - late final _spine_physics_constraint_set_x_offset = - _spine_physics_constraint_set_x_offsetPtr - .asFunction(); + late final _spine_physics_constraint_set_x_offsetPtr = + _lookup>( + 'spine_physics_constraint_set_x_offset', + ); + late final _spine_physics_constraint_set_x_offset = _spine_physics_constraint_set_x_offsetPtr + .asFunction(); - double spine_physics_constraint_get_x_offset( - spine_physics_constraint constraint, - ) { - return _spine_physics_constraint_get_x_offset( - constraint, - ); + double spine_physics_constraint_get_x_offset(spine_physics_constraint constraint) { + return _spine_physics_constraint_get_x_offset(constraint); } late final _spine_physics_constraint_get_x_offsetPtr = _lookup>( - 'spine_physics_constraint_get_x_offset'); - late final _spine_physics_constraint_get_x_offset = - _spine_physics_constraint_get_x_offsetPtr - .asFunction(); + 'spine_physics_constraint_get_x_offset', + ); + late final _spine_physics_constraint_get_x_offset = _spine_physics_constraint_get_x_offsetPtr + .asFunction(); - void spine_physics_constraint_set_x_velocity( - spine_physics_constraint constraint, - double value, - ) { - return _spine_physics_constraint_set_x_velocity( - constraint, - value, - ); + void spine_physics_constraint_set_x_velocity(spine_physics_constraint constraint, double value) { + return _spine_physics_constraint_set_x_velocity(constraint, value); } - late final _spine_physics_constraint_set_x_velocityPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint, - ffi.Float)>>('spine_physics_constraint_set_x_velocity'); - late final _spine_physics_constraint_set_x_velocity = - _spine_physics_constraint_set_x_velocityPtr - .asFunction(); + late final _spine_physics_constraint_set_x_velocityPtr = + _lookup>( + 'spine_physics_constraint_set_x_velocity', + ); + late final _spine_physics_constraint_set_x_velocity = _spine_physics_constraint_set_x_velocityPtr + .asFunction(); - double spine_physics_constraint_get_x_velocity( - spine_physics_constraint constraint, - ) { - return _spine_physics_constraint_get_x_velocity( - constraint, - ); + double spine_physics_constraint_get_x_velocity(spine_physics_constraint constraint) { + return _spine_physics_constraint_get_x_velocity(constraint); } late final _spine_physics_constraint_get_x_velocityPtr = _lookup>( - 'spine_physics_constraint_get_x_velocity'); - late final _spine_physics_constraint_get_x_velocity = - _spine_physics_constraint_get_x_velocityPtr - .asFunction(); + 'spine_physics_constraint_get_x_velocity', + ); + late final _spine_physics_constraint_get_x_velocity = _spine_physics_constraint_get_x_velocityPtr + .asFunction(); - void spine_physics_constraint_set_y_offset( - spine_physics_constraint constraint, - double value, - ) { - return _spine_physics_constraint_set_y_offset( - constraint, - value, - ); + void spine_physics_constraint_set_y_offset(spine_physics_constraint constraint, double value) { + return _spine_physics_constraint_set_y_offset(constraint, value); } - late final _spine_physics_constraint_set_y_offsetPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint, - ffi.Float)>>('spine_physics_constraint_set_y_offset'); - late final _spine_physics_constraint_set_y_offset = - _spine_physics_constraint_set_y_offsetPtr - .asFunction(); + late final _spine_physics_constraint_set_y_offsetPtr = + _lookup>( + 'spine_physics_constraint_set_y_offset', + ); + late final _spine_physics_constraint_set_y_offset = _spine_physics_constraint_set_y_offsetPtr + .asFunction(); - double spine_physics_constraint_get_y_offset( - spine_physics_constraint constraint, - ) { - return _spine_physics_constraint_get_y_offset( - constraint, - ); + double spine_physics_constraint_get_y_offset(spine_physics_constraint constraint) { + return _spine_physics_constraint_get_y_offset(constraint); } late final _spine_physics_constraint_get_y_offsetPtr = _lookup>( - 'spine_physics_constraint_get_y_offset'); - late final _spine_physics_constraint_get_y_offset = - _spine_physics_constraint_get_y_offsetPtr - .asFunction(); + 'spine_physics_constraint_get_y_offset', + ); + late final _spine_physics_constraint_get_y_offset = _spine_physics_constraint_get_y_offsetPtr + .asFunction(); - void spine_physics_constraint_set_y_velocity( - spine_physics_constraint constraint, - double value, - ) { - return _spine_physics_constraint_set_y_velocity( - constraint, - value, - ); + void spine_physics_constraint_set_y_velocity(spine_physics_constraint constraint, double value) { + return _spine_physics_constraint_set_y_velocity(constraint, value); } - late final _spine_physics_constraint_set_y_velocityPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint, - ffi.Float)>>('spine_physics_constraint_set_y_velocity'); - late final _spine_physics_constraint_set_y_velocity = - _spine_physics_constraint_set_y_velocityPtr - .asFunction(); + late final _spine_physics_constraint_set_y_velocityPtr = + _lookup>( + 'spine_physics_constraint_set_y_velocity', + ); + late final _spine_physics_constraint_set_y_velocity = _spine_physics_constraint_set_y_velocityPtr + .asFunction(); - double spine_physics_constraint_get_y_velocity( - spine_physics_constraint constraint, - ) { - return _spine_physics_constraint_get_y_velocity( - constraint, - ); + double spine_physics_constraint_get_y_velocity(spine_physics_constraint constraint) { + return _spine_physics_constraint_get_y_velocity(constraint); } late final _spine_physics_constraint_get_y_velocityPtr = _lookup>( - 'spine_physics_constraint_get_y_velocity'); - late final _spine_physics_constraint_get_y_velocity = - _spine_physics_constraint_get_y_velocityPtr - .asFunction(); + 'spine_physics_constraint_get_y_velocity', + ); + late final _spine_physics_constraint_get_y_velocity = _spine_physics_constraint_get_y_velocityPtr + .asFunction(); - void spine_physics_constraint_set_rotate_offset( - spine_physics_constraint constraint, - double value, - ) { - return _spine_physics_constraint_set_rotate_offset( - constraint, - value, - ); + void spine_physics_constraint_set_rotate_offset(spine_physics_constraint constraint, double value) { + return _spine_physics_constraint_set_rotate_offset(constraint, value); } - late final _spine_physics_constraint_set_rotate_offsetPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint, - ffi.Float)>>('spine_physics_constraint_set_rotate_offset'); - late final _spine_physics_constraint_set_rotate_offset = - _spine_physics_constraint_set_rotate_offsetPtr - .asFunction(); + late final _spine_physics_constraint_set_rotate_offsetPtr = + _lookup>( + 'spine_physics_constraint_set_rotate_offset', + ); + late final _spine_physics_constraint_set_rotate_offset = _spine_physics_constraint_set_rotate_offsetPtr + .asFunction(); - double spine_physics_constraint_get_rotate_offset( - spine_physics_constraint constraint, - ) { - return _spine_physics_constraint_get_rotate_offset( - constraint, - ); + double spine_physics_constraint_get_rotate_offset(spine_physics_constraint constraint) { + return _spine_physics_constraint_get_rotate_offset(constraint); } late final _spine_physics_constraint_get_rotate_offsetPtr = _lookup>( - 'spine_physics_constraint_get_rotate_offset'); - late final _spine_physics_constraint_get_rotate_offset = - _spine_physics_constraint_get_rotate_offsetPtr - .asFunction(); + 'spine_physics_constraint_get_rotate_offset', + ); + late final _spine_physics_constraint_get_rotate_offset = _spine_physics_constraint_get_rotate_offsetPtr + .asFunction(); - void spine_physics_constraint_set_rotate_velocity( - spine_physics_constraint constraint, - double value, - ) { - return _spine_physics_constraint_set_rotate_velocity( - constraint, - value, - ); + void spine_physics_constraint_set_rotate_velocity(spine_physics_constraint constraint, double value) { + return _spine_physics_constraint_set_rotate_velocity(constraint, value); } - late final _spine_physics_constraint_set_rotate_velocityPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint, - ffi.Float)>>('spine_physics_constraint_set_rotate_velocity'); - late final _spine_physics_constraint_set_rotate_velocity = - _spine_physics_constraint_set_rotate_velocityPtr - .asFunction(); + late final _spine_physics_constraint_set_rotate_velocityPtr = + _lookup>( + 'spine_physics_constraint_set_rotate_velocity', + ); + late final _spine_physics_constraint_set_rotate_velocity = _spine_physics_constraint_set_rotate_velocityPtr + .asFunction(); - double spine_physics_constraint_get_rotate_velocity( - spine_physics_constraint constraint, - ) { - return _spine_physics_constraint_get_rotate_velocity( - constraint, - ); + double spine_physics_constraint_get_rotate_velocity(spine_physics_constraint constraint) { + return _spine_physics_constraint_get_rotate_velocity(constraint); } late final _spine_physics_constraint_get_rotate_velocityPtr = _lookup>( - 'spine_physics_constraint_get_rotate_velocity'); - late final _spine_physics_constraint_get_rotate_velocity = - _spine_physics_constraint_get_rotate_velocityPtr - .asFunction(); + 'spine_physics_constraint_get_rotate_velocity', + ); + late final _spine_physics_constraint_get_rotate_velocity = _spine_physics_constraint_get_rotate_velocityPtr + .asFunction(); - void spine_physics_constraint_set_scale_offset( - spine_physics_constraint constraint, - double value, - ) { - return _spine_physics_constraint_set_scale_offset( - constraint, - value, - ); + void spine_physics_constraint_set_scale_offset(spine_physics_constraint constraint, double value) { + return _spine_physics_constraint_set_scale_offset(constraint, value); } - late final _spine_physics_constraint_set_scale_offsetPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint, - ffi.Float)>>('spine_physics_constraint_set_scale_offset'); - late final _spine_physics_constraint_set_scale_offset = - _spine_physics_constraint_set_scale_offsetPtr - .asFunction(); + late final _spine_physics_constraint_set_scale_offsetPtr = + _lookup>( + 'spine_physics_constraint_set_scale_offset', + ); + late final _spine_physics_constraint_set_scale_offset = _spine_physics_constraint_set_scale_offsetPtr + .asFunction(); - double spine_physics_constraint_get_scale_offset( - spine_physics_constraint constraint, - ) { - return _spine_physics_constraint_get_scale_offset( - constraint, - ); + double spine_physics_constraint_get_scale_offset(spine_physics_constraint constraint) { + return _spine_physics_constraint_get_scale_offset(constraint); } late final _spine_physics_constraint_get_scale_offsetPtr = _lookup>( - 'spine_physics_constraint_get_scale_offset'); - late final _spine_physics_constraint_get_scale_offset = - _spine_physics_constraint_get_scale_offsetPtr - .asFunction(); + 'spine_physics_constraint_get_scale_offset', + ); + late final _spine_physics_constraint_get_scale_offset = _spine_physics_constraint_get_scale_offsetPtr + .asFunction(); - void spine_physics_constraint_set_scale_velocity( - spine_physics_constraint constraint, - double value, - ) { - return _spine_physics_constraint_set_scale_velocity( - constraint, - value, - ); + void spine_physics_constraint_set_scale_velocity(spine_physics_constraint constraint, double value) { + return _spine_physics_constraint_set_scale_velocity(constraint, value); } - late final _spine_physics_constraint_set_scale_velocityPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint, - ffi.Float)>>('spine_physics_constraint_set_scale_velocity'); - late final _spine_physics_constraint_set_scale_velocity = - _spine_physics_constraint_set_scale_velocityPtr - .asFunction(); + late final _spine_physics_constraint_set_scale_velocityPtr = + _lookup>( + 'spine_physics_constraint_set_scale_velocity', + ); + late final _spine_physics_constraint_set_scale_velocity = _spine_physics_constraint_set_scale_velocityPtr + .asFunction(); - double spine_physics_constraint_get_scale_velocity( - spine_physics_constraint constraint, - ) { - return _spine_physics_constraint_get_scale_velocity( - constraint, - ); + double spine_physics_constraint_get_scale_velocity(spine_physics_constraint constraint) { + return _spine_physics_constraint_get_scale_velocity(constraint); } late final _spine_physics_constraint_get_scale_velocityPtr = _lookup>( - 'spine_physics_constraint_get_scale_velocity'); - late final _spine_physics_constraint_get_scale_velocity = - _spine_physics_constraint_get_scale_velocityPtr - .asFunction(); + 'spine_physics_constraint_get_scale_velocity', + ); + late final _spine_physics_constraint_get_scale_velocity = _spine_physics_constraint_get_scale_velocityPtr + .asFunction(); - void spine_physics_constraint_set_active( - spine_physics_constraint constraint, - int value, - ) { - return _spine_physics_constraint_set_active( - constraint, - value, - ); + void spine_physics_constraint_set_active(spine_physics_constraint constraint, int value) { + return _spine_physics_constraint_set_active(constraint, value); } - late final _spine_physics_constraint_set_activePtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint, - spine_bool)>>('spine_physics_constraint_set_active'); - late final _spine_physics_constraint_set_active = - _spine_physics_constraint_set_activePtr - .asFunction(); + late final _spine_physics_constraint_set_activePtr = + _lookup>( + 'spine_physics_constraint_set_active', + ); + late final _spine_physics_constraint_set_active = _spine_physics_constraint_set_activePtr + .asFunction(); - int spine_physics_constraint_is_active( - spine_physics_constraint constraint, - ) { - return _spine_physics_constraint_is_active( - constraint, - ); + int spine_physics_constraint_is_active(spine_physics_constraint constraint) { + return _spine_physics_constraint_is_active(constraint); } - late final _spine_physics_constraint_is_activePtr = _lookup< - ffi.NativeFunction>( - 'spine_physics_constraint_is_active'); - late final _spine_physics_constraint_is_active = - _spine_physics_constraint_is_activePtr - .asFunction(); + late final _spine_physics_constraint_is_activePtr = + _lookup>('spine_physics_constraint_is_active'); + late final _spine_physics_constraint_is_active = _spine_physics_constraint_is_activePtr + .asFunction(); - void spine_physics_constraint_set_remaining( - spine_physics_constraint constraint, - double value, - ) { - return _spine_physics_constraint_set_remaining( - constraint, - value, - ); + void spine_physics_constraint_set_remaining(spine_physics_constraint constraint, double value) { + return _spine_physics_constraint_set_remaining(constraint, value); } - late final _spine_physics_constraint_set_remainingPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint, - ffi.Float)>>('spine_physics_constraint_set_remaining'); - late final _spine_physics_constraint_set_remaining = - _spine_physics_constraint_set_remainingPtr - .asFunction(); + late final _spine_physics_constraint_set_remainingPtr = + _lookup>( + 'spine_physics_constraint_set_remaining', + ); + late final _spine_physics_constraint_set_remaining = _spine_physics_constraint_set_remainingPtr + .asFunction(); - double spine_physics_constraint_get_remaining( - spine_physics_constraint constraint, - ) { - return _spine_physics_constraint_get_remaining( - constraint, - ); + double spine_physics_constraint_get_remaining(spine_physics_constraint constraint) { + return _spine_physics_constraint_get_remaining(constraint); } late final _spine_physics_constraint_get_remainingPtr = _lookup>( - 'spine_physics_constraint_get_remaining'); - late final _spine_physics_constraint_get_remaining = - _spine_physics_constraint_get_remainingPtr - .asFunction(); + 'spine_physics_constraint_get_remaining', + ); + late final _spine_physics_constraint_get_remaining = _spine_physics_constraint_get_remainingPtr + .asFunction(); - void spine_physics_constraint_set_last_time( - spine_physics_constraint constraint, - double value, - ) { - return _spine_physics_constraint_set_last_time( - constraint, - value, - ); + void spine_physics_constraint_set_last_time(spine_physics_constraint constraint, double value) { + return _spine_physics_constraint_set_last_time(constraint, value); } - late final _spine_physics_constraint_set_last_timePtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint, - ffi.Float)>>('spine_physics_constraint_set_last_time'); - late final _spine_physics_constraint_set_last_time = - _spine_physics_constraint_set_last_timePtr - .asFunction(); + late final _spine_physics_constraint_set_last_timePtr = + _lookup>( + 'spine_physics_constraint_set_last_time', + ); + late final _spine_physics_constraint_set_last_time = _spine_physics_constraint_set_last_timePtr + .asFunction(); - double spine_physics_constraint_get_last_time( - spine_physics_constraint constraint, - ) { - return _spine_physics_constraint_get_last_time( - constraint, - ); + double spine_physics_constraint_get_last_time(spine_physics_constraint constraint) { + return _spine_physics_constraint_get_last_time(constraint); } late final _spine_physics_constraint_get_last_timePtr = _lookup>( - 'spine_physics_constraint_get_last_time'); - late final _spine_physics_constraint_get_last_time = - _spine_physics_constraint_get_last_timePtr - .asFunction(); + 'spine_physics_constraint_get_last_time', + ); + late final _spine_physics_constraint_get_last_time = _spine_physics_constraint_get_last_timePtr + .asFunction(); - void spine_physics_constraint_reset( - spine_physics_constraint constraint, - ) { - return _spine_physics_constraint_reset( - constraint, - ); + void spine_physics_constraint_reset(spine_physics_constraint constraint) { + return _spine_physics_constraint_reset(constraint); } late final _spine_physics_constraint_resetPtr = - _lookup>( - 'spine_physics_constraint_reset'); - late final _spine_physics_constraint_reset = - _spine_physics_constraint_resetPtr - .asFunction(); + _lookup>('spine_physics_constraint_reset'); + late final _spine_physics_constraint_reset = _spine_physics_constraint_resetPtr + .asFunction(); /// Omitted setToSetupPose() - void spine_physics_constraint_update( - spine_physics_constraint data, - int physics, - ) { - return _spine_physics_constraint_update( - data, - physics, - ); + void spine_physics_constraint_update(spine_physics_constraint data, int physics) { + return _spine_physics_constraint_update(data, physics); } - late final _spine_physics_constraint_updatePtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint, - ffi.Int32)>>('spine_physics_constraint_update'); - late final _spine_physics_constraint_update = - _spine_physics_constraint_updatePtr - .asFunction(); + late final _spine_physics_constraint_updatePtr = + _lookup>( + 'spine_physics_constraint_update', + ); + late final _spine_physics_constraint_update = _spine_physics_constraint_updatePtr + .asFunction(); - void spine_physics_constraint_translate( - spine_physics_constraint data, - double x, - double y, - ) { - return _spine_physics_constraint_translate( - data, - x, - y, - ); + void spine_physics_constraint_translate(spine_physics_constraint data, double x, double y) { + return _spine_physics_constraint_translate(data, x, y); } - late final _spine_physics_constraint_translatePtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint, ffi.Float, - ffi.Float)>>('spine_physics_constraint_translate'); - late final _spine_physics_constraint_translate = - _spine_physics_constraint_translatePtr.asFunction< - void Function(spine_physics_constraint, double, double)>(); + late final _spine_physics_constraint_translatePtr = + _lookup>( + 'spine_physics_constraint_translate', + ); + late final _spine_physics_constraint_translate = _spine_physics_constraint_translatePtr + .asFunction(); - void spine_physics_constraint_rotate( - spine_physics_constraint data, - double x, - double y, - double degrees, - ) { - return _spine_physics_constraint_rotate( - data, - x, - y, - degrees, - ); + void spine_physics_constraint_rotate(spine_physics_constraint data, double x, double y, double degrees) { + return _spine_physics_constraint_rotate(data, x, y, degrees); } - late final _spine_physics_constraint_rotatePtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_physics_constraint, ffi.Float, ffi.Float, - ffi.Float)>>('spine_physics_constraint_rotate'); - late final _spine_physics_constraint_rotate = - _spine_physics_constraint_rotatePtr.asFunction< - void Function(spine_physics_constraint, double, double, double)>(); + late final _spine_physics_constraint_rotatePtr = + _lookup>( + 'spine_physics_constraint_rotate', + ); + late final _spine_physics_constraint_rotate = _spine_physics_constraint_rotatePtr + .asFunction(); /// OMITTED copy() - void spine_sequence_apply( - spine_sequence sequence, - spine_slot slot, - spine_attachment attachment, - ) { - return _spine_sequence_apply( - sequence, - slot, - attachment, - ); + void spine_sequence_apply(spine_sequence sequence, spine_slot slot, spine_attachment attachment) { + return _spine_sequence_apply(sequence, slot, attachment); } - late final _spine_sequence_applyPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_sequence, spine_slot, - spine_attachment)>>('spine_sequence_apply'); - late final _spine_sequence_apply = _spine_sequence_applyPtr.asFunction< - void Function(spine_sequence, spine_slot, spine_attachment)>(); + late final _spine_sequence_applyPtr = + _lookup>( + 'spine_sequence_apply', + ); + late final _spine_sequence_apply = _spine_sequence_applyPtr + .asFunction(); - ffi.Pointer spine_sequence_get_path( - spine_sequence sequence, - ffi.Pointer basePath, - int index, - ) { - return _spine_sequence_get_path( - sequence, - basePath, - index, - ); + ffi.Pointer spine_sequence_get_path(spine_sequence sequence, ffi.Pointer basePath, int index) { + return _spine_sequence_get_path(sequence, basePath, index); } - late final _spine_sequence_get_pathPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(spine_sequence, ffi.Pointer, - ffi.Int32)>>('spine_sequence_get_path'); - late final _spine_sequence_get_path = _spine_sequence_get_pathPtr.asFunction< - ffi.Pointer Function(spine_sequence, ffi.Pointer, int)>(); + late final _spine_sequence_get_pathPtr = + _lookup Function(spine_sequence, ffi.Pointer, ffi.Int32)>>( + 'spine_sequence_get_path', + ); + late final _spine_sequence_get_path = _spine_sequence_get_pathPtr + .asFunction Function(spine_sequence, ffi.Pointer, int)>(); - int spine_sequence_get_id( - spine_sequence sequence, - ) { - return _spine_sequence_get_id( - sequence, - ); + int spine_sequence_get_id(spine_sequence sequence) { + return _spine_sequence_get_id(sequence); } - late final _spine_sequence_get_idPtr = - _lookup>( - 'spine_sequence_get_id'); - late final _spine_sequence_get_id = - _spine_sequence_get_idPtr.asFunction(); + late final _spine_sequence_get_idPtr = _lookup>( + 'spine_sequence_get_id', + ); + late final _spine_sequence_get_id = _spine_sequence_get_idPtr.asFunction(); - void spine_sequence_set_id( - spine_sequence sequence, - int id, - ) { - return _spine_sequence_set_id( - sequence, - id, - ); + void spine_sequence_set_id(spine_sequence sequence, int id) { + return _spine_sequence_set_id(sequence, id); } - late final _spine_sequence_set_idPtr = - _lookup>( - 'spine_sequence_set_id'); - late final _spine_sequence_set_id = _spine_sequence_set_idPtr - .asFunction(); + late final _spine_sequence_set_idPtr = _lookup>( + 'spine_sequence_set_id', + ); + late final _spine_sequence_set_id = _spine_sequence_set_idPtr.asFunction(); - int spine_sequence_get_start( - spine_sequence sequence, - ) { - return _spine_sequence_get_start( - sequence, - ); + int spine_sequence_get_start(spine_sequence sequence) { + return _spine_sequence_get_start(sequence); } - late final _spine_sequence_get_startPtr = - _lookup>( - 'spine_sequence_get_start'); - late final _spine_sequence_get_start = - _spine_sequence_get_startPtr.asFunction(); + late final _spine_sequence_get_startPtr = _lookup>( + 'spine_sequence_get_start', + ); + late final _spine_sequence_get_start = _spine_sequence_get_startPtr.asFunction(); - void spine_sequence_set_start( - spine_sequence sequence, - int start, - ) { - return _spine_sequence_set_start( - sequence, - start, - ); + void spine_sequence_set_start(spine_sequence sequence, int start) { + return _spine_sequence_set_start(sequence, start); } - late final _spine_sequence_set_startPtr = - _lookup>( - 'spine_sequence_set_start'); - late final _spine_sequence_set_start = _spine_sequence_set_startPtr - .asFunction(); + late final _spine_sequence_set_startPtr = _lookup>( + 'spine_sequence_set_start', + ); + late final _spine_sequence_set_start = _spine_sequence_set_startPtr.asFunction(); - int spine_sequence_get_digits( - spine_sequence sequence, - ) { - return _spine_sequence_get_digits( - sequence, - ); + int spine_sequence_get_digits(spine_sequence sequence) { + return _spine_sequence_get_digits(sequence); } - late final _spine_sequence_get_digitsPtr = - _lookup>( - 'spine_sequence_get_digits'); - late final _spine_sequence_get_digits = - _spine_sequence_get_digitsPtr.asFunction(); + late final _spine_sequence_get_digitsPtr = _lookup>( + 'spine_sequence_get_digits', + ); + late final _spine_sequence_get_digits = _spine_sequence_get_digitsPtr.asFunction(); - void spine_sequence_set_digits( - spine_sequence sequence, - int digits, - ) { - return _spine_sequence_set_digits( - sequence, - digits, - ); + void spine_sequence_set_digits(spine_sequence sequence, int digits) { + return _spine_sequence_set_digits(sequence, digits); } - late final _spine_sequence_set_digitsPtr = - _lookup>( - 'spine_sequence_set_digits'); + late final _spine_sequence_set_digitsPtr = _lookup>( + 'spine_sequence_set_digits', + ); late final _spine_sequence_set_digits = _spine_sequence_set_digitsPtr .asFunction(); - int spine_sequence_get_setup_index( - spine_sequence sequence, - ) { - return _spine_sequence_get_setup_index( - sequence, - ); + int spine_sequence_get_setup_index(spine_sequence sequence) { + return _spine_sequence_get_setup_index(sequence); } - late final _spine_sequence_get_setup_indexPtr = - _lookup>( - 'spine_sequence_get_setup_index'); - late final _spine_sequence_get_setup_index = - _spine_sequence_get_setup_indexPtr - .asFunction(); + late final _spine_sequence_get_setup_indexPtr = _lookup>( + 'spine_sequence_get_setup_index', + ); + late final _spine_sequence_get_setup_index = _spine_sequence_get_setup_indexPtr + .asFunction(); - void spine_sequence_set_setup_index( - spine_sequence sequence, - int setupIndex, - ) { - return _spine_sequence_set_setup_index( - sequence, - setupIndex, - ); + void spine_sequence_set_setup_index(spine_sequence sequence, int setupIndex) { + return _spine_sequence_set_setup_index(sequence, setupIndex); } late final _spine_sequence_set_setup_indexPtr = - _lookup>( - 'spine_sequence_set_setup_index'); - late final _spine_sequence_set_setup_index = - _spine_sequence_set_setup_indexPtr - .asFunction(); + _lookup>('spine_sequence_set_setup_index'); + late final _spine_sequence_set_setup_index = _spine_sequence_set_setup_indexPtr + .asFunction(); - int spine_sequence_get_num_regions( - spine_sequence sequence, - ) { - return _spine_sequence_get_num_regions( - sequence, - ); + int spine_sequence_get_num_regions(spine_sequence sequence) { + return _spine_sequence_get_num_regions(sequence); } - late final _spine_sequence_get_num_regionsPtr = - _lookup>( - 'spine_sequence_get_num_regions'); - late final _spine_sequence_get_num_regions = - _spine_sequence_get_num_regionsPtr - .asFunction(); + late final _spine_sequence_get_num_regionsPtr = _lookup>( + 'spine_sequence_get_num_regions', + ); + late final _spine_sequence_get_num_regions = _spine_sequence_get_num_regionsPtr + .asFunction(); - ffi.Pointer spine_sequence_get_regions( - spine_sequence sequence, - ) { - return _spine_sequence_get_regions( - sequence, - ); + ffi.Pointer spine_sequence_get_regions(spine_sequence sequence) { + return _spine_sequence_get_regions(sequence); } - late final _spine_sequence_get_regionsPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_sequence)>>('spine_sequence_get_regions'); + late final _spine_sequence_get_regionsPtr = + _lookup Function(spine_sequence)>>( + 'spine_sequence_get_regions', + ); late final _spine_sequence_get_regions = _spine_sequence_get_regionsPtr .asFunction Function(spine_sequence)>(); - ffi.Pointer spine_texture_region_get_texture( - spine_texture_region textureRegion, - ) { - return _spine_texture_region_get_texture( - textureRegion, - ); + ffi.Pointer spine_texture_region_get_texture(spine_texture_region textureRegion) { + return _spine_texture_region_get_texture(textureRegion); } - late final _spine_texture_region_get_texturePtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - spine_texture_region)>>('spine_texture_region_get_texture'); - late final _spine_texture_region_get_texture = - _spine_texture_region_get_texturePtr - .asFunction Function(spine_texture_region)>(); + late final _spine_texture_region_get_texturePtr = + _lookup Function(spine_texture_region)>>( + 'spine_texture_region_get_texture', + ); + late final _spine_texture_region_get_texture = _spine_texture_region_get_texturePtr + .asFunction Function(spine_texture_region)>(); - void spine_texture_region_set_texture( - spine_texture_region textureRegion, - ffi.Pointer texture, - ) { - return _spine_texture_region_set_texture( - textureRegion, - texture, - ); + void spine_texture_region_set_texture(spine_texture_region textureRegion, ffi.Pointer texture) { + return _spine_texture_region_set_texture(textureRegion, texture); } - late final _spine_texture_region_set_texturePtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(spine_texture_region, - ffi.Pointer)>>('spine_texture_region_set_texture'); - late final _spine_texture_region_set_texture = - _spine_texture_region_set_texturePtr.asFunction< - void Function(spine_texture_region, ffi.Pointer)>(); + late final _spine_texture_region_set_texturePtr = + _lookup)>>( + 'spine_texture_region_set_texture', + ); + late final _spine_texture_region_set_texture = _spine_texture_region_set_texturePtr + .asFunction)>(); - double spine_texture_region_get_u( - spine_texture_region textureRegion, - ) { - return _spine_texture_region_get_u( - textureRegion, - ); + double spine_texture_region_get_u(spine_texture_region textureRegion) { + return _spine_texture_region_get_u(textureRegion); } - late final _spine_texture_region_get_uPtr = - _lookup>( - 'spine_texture_region_get_u'); + late final _spine_texture_region_get_uPtr = _lookup>( + 'spine_texture_region_get_u', + ); late final _spine_texture_region_get_u = _spine_texture_region_get_uPtr .asFunction(); - void spine_texture_region_set_u( - spine_texture_region textureRegion, - double u, - ) { - return _spine_texture_region_set_u( - textureRegion, - u, - ); + void spine_texture_region_set_u(spine_texture_region textureRegion, double u) { + return _spine_texture_region_set_u(textureRegion, u); } - late final _spine_texture_region_set_uPtr = _lookup< - ffi - .NativeFunction>( - 'spine_texture_region_set_u'); + late final _spine_texture_region_set_uPtr = + _lookup>('spine_texture_region_set_u'); late final _spine_texture_region_set_u = _spine_texture_region_set_uPtr .asFunction(); - double spine_texture_region_get_v( - spine_texture_region textureRegion, - ) { - return _spine_texture_region_get_v( - textureRegion, - ); + double spine_texture_region_get_v(spine_texture_region textureRegion) { + return _spine_texture_region_get_v(textureRegion); } - late final _spine_texture_region_get_vPtr = - _lookup>( - 'spine_texture_region_get_v'); + late final _spine_texture_region_get_vPtr = _lookup>( + 'spine_texture_region_get_v', + ); late final _spine_texture_region_get_v = _spine_texture_region_get_vPtr .asFunction(); - void spine_texture_region_set_v( - spine_texture_region textureRegion, - double v, - ) { - return _spine_texture_region_set_v( - textureRegion, - v, - ); + void spine_texture_region_set_v(spine_texture_region textureRegion, double v) { + return _spine_texture_region_set_v(textureRegion, v); } - late final _spine_texture_region_set_vPtr = _lookup< - ffi - .NativeFunction>( - 'spine_texture_region_set_v'); + late final _spine_texture_region_set_vPtr = + _lookup>('spine_texture_region_set_v'); late final _spine_texture_region_set_v = _spine_texture_region_set_vPtr .asFunction(); - double spine_texture_region_get_u2( - spine_texture_region textureRegion, - ) { - return _spine_texture_region_get_u2( - textureRegion, - ); + double spine_texture_region_get_u2(spine_texture_region textureRegion) { + return _spine_texture_region_get_u2(textureRegion); } - late final _spine_texture_region_get_u2Ptr = - _lookup>( - 'spine_texture_region_get_u2'); + late final _spine_texture_region_get_u2Ptr = _lookup>( + 'spine_texture_region_get_u2', + ); late final _spine_texture_region_get_u2 = _spine_texture_region_get_u2Ptr .asFunction(); - void spine_texture_region_set_u2( - spine_texture_region textureRegion, - double u2, - ) { - return _spine_texture_region_set_u2( - textureRegion, - u2, - ); + void spine_texture_region_set_u2(spine_texture_region textureRegion, double u2) { + return _spine_texture_region_set_u2(textureRegion, u2); } - late final _spine_texture_region_set_u2Ptr = _lookup< - ffi - .NativeFunction>( - 'spine_texture_region_set_u2'); + late final _spine_texture_region_set_u2Ptr = + _lookup>('spine_texture_region_set_u2'); late final _spine_texture_region_set_u2 = _spine_texture_region_set_u2Ptr .asFunction(); - double spine_texture_region_get_v2( - spine_texture_region textureRegion, - ) { - return _spine_texture_region_get_v2( - textureRegion, - ); + double spine_texture_region_get_v2(spine_texture_region textureRegion) { + return _spine_texture_region_get_v2(textureRegion); } - late final _spine_texture_region_get_v2Ptr = - _lookup>( - 'spine_texture_region_get_v2'); + late final _spine_texture_region_get_v2Ptr = _lookup>( + 'spine_texture_region_get_v2', + ); late final _spine_texture_region_get_v2 = _spine_texture_region_get_v2Ptr .asFunction(); - void spine_texture_region_set_v2( - spine_texture_region textureRegion, - double v2, - ) { - return _spine_texture_region_set_v2( - textureRegion, - v2, - ); + void spine_texture_region_set_v2(spine_texture_region textureRegion, double v2) { + return _spine_texture_region_set_v2(textureRegion, v2); } - late final _spine_texture_region_set_v2Ptr = _lookup< - ffi - .NativeFunction>( - 'spine_texture_region_set_v2'); + late final _spine_texture_region_set_v2Ptr = + _lookup>('spine_texture_region_set_v2'); late final _spine_texture_region_set_v2 = _spine_texture_region_set_v2Ptr .asFunction(); - int spine_texture_region_get_degrees( - spine_texture_region textureRegion, - ) { - return _spine_texture_region_get_degrees( - textureRegion, - ); + int spine_texture_region_get_degrees(spine_texture_region textureRegion) { + return _spine_texture_region_get_degrees(textureRegion); } late final _spine_texture_region_get_degreesPtr = - _lookup>( - 'spine_texture_region_get_degrees'); - late final _spine_texture_region_get_degrees = - _spine_texture_region_get_degreesPtr - .asFunction(); + _lookup>('spine_texture_region_get_degrees'); + late final _spine_texture_region_get_degrees = _spine_texture_region_get_degreesPtr + .asFunction(); - void spine_texture_region_set_degrees( - spine_texture_region textureRegion, - int degrees, - ) { - return _spine_texture_region_set_degrees( - textureRegion, - degrees, - ); + void spine_texture_region_set_degrees(spine_texture_region textureRegion, int degrees) { + return _spine_texture_region_set_degrees(textureRegion, degrees); } - late final _spine_texture_region_set_degreesPtr = _lookup< - ffi - .NativeFunction>( - 'spine_texture_region_set_degrees'); - late final _spine_texture_region_set_degrees = - _spine_texture_region_set_degreesPtr - .asFunction(); + late final _spine_texture_region_set_degreesPtr = + _lookup>( + 'spine_texture_region_set_degrees', + ); + late final _spine_texture_region_set_degrees = _spine_texture_region_set_degreesPtr + .asFunction(); - double spine_texture_region_get_offset_x( - spine_texture_region textureRegion, - ) { - return _spine_texture_region_get_offset_x( - textureRegion, - ); + double spine_texture_region_get_offset_x(spine_texture_region textureRegion) { + return _spine_texture_region_get_offset_x(textureRegion); } late final _spine_texture_region_get_offset_xPtr = - _lookup>( - 'spine_texture_region_get_offset_x'); - late final _spine_texture_region_get_offset_x = - _spine_texture_region_get_offset_xPtr - .asFunction(); + _lookup>('spine_texture_region_get_offset_x'); + late final _spine_texture_region_get_offset_x = _spine_texture_region_get_offset_xPtr + .asFunction(); - void spine_texture_region_set_offset_x( - spine_texture_region textureRegion, - double offsetX, - ) { - return _spine_texture_region_set_offset_x( - textureRegion, - offsetX, - ); + void spine_texture_region_set_offset_x(spine_texture_region textureRegion, double offsetX) { + return _spine_texture_region_set_offset_x(textureRegion, offsetX); } - late final _spine_texture_region_set_offset_xPtr = _lookup< - ffi - .NativeFunction>( - 'spine_texture_region_set_offset_x'); - late final _spine_texture_region_set_offset_x = - _spine_texture_region_set_offset_xPtr - .asFunction(); + late final _spine_texture_region_set_offset_xPtr = + _lookup>( + 'spine_texture_region_set_offset_x', + ); + late final _spine_texture_region_set_offset_x = _spine_texture_region_set_offset_xPtr + .asFunction(); - double spine_texture_region_get_offset_y( - spine_texture_region textureRegion, - ) { - return _spine_texture_region_get_offset_y( - textureRegion, - ); + double spine_texture_region_get_offset_y(spine_texture_region textureRegion) { + return _spine_texture_region_get_offset_y(textureRegion); } late final _spine_texture_region_get_offset_yPtr = - _lookup>( - 'spine_texture_region_get_offset_y'); - late final _spine_texture_region_get_offset_y = - _spine_texture_region_get_offset_yPtr - .asFunction(); + _lookup>('spine_texture_region_get_offset_y'); + late final _spine_texture_region_get_offset_y = _spine_texture_region_get_offset_yPtr + .asFunction(); - void spine_texture_region_set_offset_y( - spine_texture_region textureRegion, - double offsetY, - ) { - return _spine_texture_region_set_offset_y( - textureRegion, - offsetY, - ); + void spine_texture_region_set_offset_y(spine_texture_region textureRegion, double offsetY) { + return _spine_texture_region_set_offset_y(textureRegion, offsetY); } - late final _spine_texture_region_set_offset_yPtr = _lookup< - ffi - .NativeFunction>( - 'spine_texture_region_set_offset_y'); - late final _spine_texture_region_set_offset_y = - _spine_texture_region_set_offset_yPtr - .asFunction(); + late final _spine_texture_region_set_offset_yPtr = + _lookup>( + 'spine_texture_region_set_offset_y', + ); + late final _spine_texture_region_set_offset_y = _spine_texture_region_set_offset_yPtr + .asFunction(); - int spine_texture_region_get_width( - spine_texture_region textureRegion, - ) { - return _spine_texture_region_get_width( - textureRegion, - ); + int spine_texture_region_get_width(spine_texture_region textureRegion) { + return _spine_texture_region_get_width(textureRegion); } - late final _spine_texture_region_get_widthPtr = - _lookup>( - 'spine_texture_region_get_width'); - late final _spine_texture_region_get_width = - _spine_texture_region_get_widthPtr - .asFunction(); + late final _spine_texture_region_get_widthPtr = _lookup>( + 'spine_texture_region_get_width', + ); + late final _spine_texture_region_get_width = _spine_texture_region_get_widthPtr + .asFunction(); - void spine_texture_region_set_width( - spine_texture_region textureRegion, - int width, - ) { - return _spine_texture_region_set_width( - textureRegion, - width, - ); + void spine_texture_region_set_width(spine_texture_region textureRegion, int width) { + return _spine_texture_region_set_width(textureRegion, width); } - late final _spine_texture_region_set_widthPtr = _lookup< - ffi - .NativeFunction>( - 'spine_texture_region_set_width'); - late final _spine_texture_region_set_width = - _spine_texture_region_set_widthPtr - .asFunction(); + late final _spine_texture_region_set_widthPtr = + _lookup>('spine_texture_region_set_width'); + late final _spine_texture_region_set_width = _spine_texture_region_set_widthPtr + .asFunction(); - int spine_texture_region_get_height( - spine_texture_region textureRegion, - ) { - return _spine_texture_region_get_height( - textureRegion, - ); + int spine_texture_region_get_height(spine_texture_region textureRegion) { + return _spine_texture_region_get_height(textureRegion); } late final _spine_texture_region_get_heightPtr = - _lookup>( - 'spine_texture_region_get_height'); - late final _spine_texture_region_get_height = - _spine_texture_region_get_heightPtr - .asFunction(); + _lookup>('spine_texture_region_get_height'); + late final _spine_texture_region_get_height = _spine_texture_region_get_heightPtr + .asFunction(); - void spine_texture_region_set_height( - spine_texture_region textureRegion, - int height, - ) { - return _spine_texture_region_set_height( - textureRegion, - height, - ); + void spine_texture_region_set_height(spine_texture_region textureRegion, int height) { + return _spine_texture_region_set_height(textureRegion, height); } - late final _spine_texture_region_set_heightPtr = _lookup< - ffi - .NativeFunction>( - 'spine_texture_region_set_height'); - late final _spine_texture_region_set_height = - _spine_texture_region_set_heightPtr - .asFunction(); + late final _spine_texture_region_set_heightPtr = + _lookup>( + 'spine_texture_region_set_height', + ); + late final _spine_texture_region_set_height = _spine_texture_region_set_heightPtr + .asFunction(); - int spine_texture_region_get_original_width( - spine_texture_region textureRegion, - ) { - return _spine_texture_region_get_original_width( - textureRegion, - ); + int spine_texture_region_get_original_width(spine_texture_region textureRegion) { + return _spine_texture_region_get_original_width(textureRegion); } late final _spine_texture_region_get_original_widthPtr = - _lookup>( - 'spine_texture_region_get_original_width'); - late final _spine_texture_region_get_original_width = - _spine_texture_region_get_original_widthPtr - .asFunction(); + _lookup>('spine_texture_region_get_original_width'); + late final _spine_texture_region_get_original_width = _spine_texture_region_get_original_widthPtr + .asFunction(); - void spine_texture_region_set_original_width( - spine_texture_region textureRegion, - int originalWidth, - ) { - return _spine_texture_region_set_original_width( - textureRegion, - originalWidth, - ); + void spine_texture_region_set_original_width(spine_texture_region textureRegion, int originalWidth) { + return _spine_texture_region_set_original_width(textureRegion, originalWidth); } - late final _spine_texture_region_set_original_widthPtr = _lookup< - ffi - .NativeFunction>( - 'spine_texture_region_set_original_width'); - late final _spine_texture_region_set_original_width = - _spine_texture_region_set_original_widthPtr - .asFunction(); + late final _spine_texture_region_set_original_widthPtr = + _lookup>( + 'spine_texture_region_set_original_width', + ); + late final _spine_texture_region_set_original_width = _spine_texture_region_set_original_widthPtr + .asFunction(); - int spine_texture_region_get_original_height( - spine_texture_region textureRegion, - ) { - return _spine_texture_region_get_original_height( - textureRegion, - ); + int spine_texture_region_get_original_height(spine_texture_region textureRegion) { + return _spine_texture_region_get_original_height(textureRegion); } late final _spine_texture_region_get_original_heightPtr = - _lookup>( - 'spine_texture_region_get_original_height'); - late final _spine_texture_region_get_original_height = - _spine_texture_region_get_original_heightPtr - .asFunction(); + _lookup>('spine_texture_region_get_original_height'); + late final _spine_texture_region_get_original_height = _spine_texture_region_get_original_heightPtr + .asFunction(); - void spine_texture_region_set_original_height( - spine_texture_region textureRegion, - int originalHeight, - ) { - return _spine_texture_region_set_original_height( - textureRegion, - originalHeight, - ); + void spine_texture_region_set_original_height(spine_texture_region textureRegion, int originalHeight) { + return _spine_texture_region_set_original_height(textureRegion, originalHeight); } - late final _spine_texture_region_set_original_heightPtr = _lookup< - ffi - .NativeFunction>( - 'spine_texture_region_set_original_height'); - late final _spine_texture_region_set_original_height = - _spine_texture_region_set_original_heightPtr - .asFunction(); + late final _spine_texture_region_set_original_heightPtr = + _lookup>( + 'spine_texture_region_set_original_height', + ); + late final _spine_texture_region_set_original_height = _spine_texture_region_set_original_heightPtr + .asFunction(); } class spine_skeleton_wrapper extends ffi.Opaque {} @@ -12190,51 +7771,40 @@ typedef spine_vector = ffi.Pointer; typedef spine_atlas = ffi.Pointer; typedef utf8 = ffi.Char; typedef Dartutf8 = int; -typedef spine_skeleton_data_result - = ffi.Pointer; +typedef spine_skeleton_data_result = ffi.Pointer; typedef spine_skeleton_data = ffi.Pointer; typedef spine_bone_data = ffi.Pointer; typedef spine_slot_data = ffi.Pointer; typedef spine_skin = ffi.Pointer; typedef spine_event_data = ffi.Pointer; typedef spine_animation = ffi.Pointer; -typedef spine_ik_constraint_data - = ffi.Pointer; -typedef spine_transform_constraint_data - = ffi.Pointer; -typedef spine_path_constraint_data - = ffi.Pointer; -typedef spine_physics_constraint_data - = ffi.Pointer; +typedef spine_ik_constraint_data = ffi.Pointer; +typedef spine_transform_constraint_data = ffi.Pointer; +typedef spine_path_constraint_data = ffi.Pointer; +typedef spine_physics_constraint_data = ffi.Pointer; typedef spine_skeleton_drawable = ffi.Pointer; typedef spine_render_command = ffi.Pointer; typedef spine_skeleton = ffi.Pointer; typedef spine_animation_state = ffi.Pointer; -typedef spine_animation_state_data - = ffi.Pointer; -typedef spine_animation_state_events - = ffi.Pointer; +typedef spine_animation_state_data = ffi.Pointer; +typedef spine_animation_state_events = ffi.Pointer; typedef spine_track_entry = ffi.Pointer; typedef spine_event = ffi.Pointer; typedef spine_bone = ffi.Pointer; typedef spine_slot = ffi.Pointer; typedef spine_attachment = ffi.Pointer; typedef spine_ik_constraint = ffi.Pointer; -typedef spine_transform_constraint - = ffi.Pointer; +typedef spine_transform_constraint = ffi.Pointer; typedef spine_path_constraint = ffi.Pointer; -typedef spine_physics_constraint - = ffi.Pointer; +typedef spine_physics_constraint = ffi.Pointer; typedef spine_point_attachment = ffi.Pointer; typedef spine_region_attachment = ffi.Pointer; typedef spine_texture_region = ffi.Pointer; typedef spine_sequence = ffi.Pointer; typedef spine_vertex_attachment = ffi.Pointer; typedef spine_mesh_attachment = ffi.Pointer; -typedef spine_clipping_attachment - = ffi.Pointer; -typedef spine_bounding_box_attachment - = ffi.Pointer; +typedef spine_clipping_attachment = ffi.Pointer; +typedef spine_bounding_box_attachment = ffi.Pointer; typedef spine_path_attachment = ffi.Pointer; typedef spine_skin_entries = ffi.Pointer; typedef spine_skin_entry = ffi.Pointer; diff --git a/spine-flutter/lib/spine_widget.dart b/spine-flutter/lib/spine_widget.dart index f5158964d..00c154974 100644 --- a/spine-flutter/lib/spine_widget.dart +++ b/spine-flutter/lib/spine_widget.dart @@ -74,8 +74,13 @@ class SpineWidgetController { /// Constructs a new [SpineWidget] controller. See the class documentation of [SpineWidgetController] for information on /// the optional arguments. - SpineWidgetController( - {this.onInitialized, this.onBeforeUpdateWorldTransforms, this.onAfterUpdateWorldTransforms, this.onBeforePaint, this.onAfterPaint}); + SpineWidgetController({ + this.onInitialized, + this.onBeforeUpdateWorldTransforms, + this.onAfterUpdateWorldTransforms, + this.onBeforePaint, + this.onAfterPaint, + }); void _initialize(SkeletonDrawable drawable) { var wasInitialized = _drawable != null; @@ -203,7 +208,7 @@ class SkinAndAnimationBounds extends BoundsProvider { /// The [stepTime], given in seconds, defines at what interval the bounds should be sampled /// across the entire animation. SkinAndAnimationBounds({List? skins, this.animation, this.stepTime = 0.1}) - : skins = skins == null || skins.isEmpty ? ["default"] : skins; + : skins = skins == null || skins.isEmpty ? ["default"] : skins; @override Bounds computeBounds(SkeletonDrawable drawable) { @@ -282,15 +287,23 @@ class SpineWidget extends StatefulWidget { /// are used. /// /// The widget can optionally by sized by the bounds provided by the [BoundsProvider] by passing `true` for [sizedByBounds]. - SpineWidget.fromAsset(this._atlasFile, this._skeletonFile, this._controller, - {AssetBundle? bundle, BoxFit? fit, Alignment? alignment, BoundsProvider? boundsProvider, bool? sizedByBounds, super.key}) - : _assetType = _AssetType.asset, - _fit = fit ?? BoxFit.contain, - _alignment = alignment ?? Alignment.center, - _boundsProvider = boundsProvider ?? const SetupPoseBounds(), - _sizedByBounds = sizedByBounds ?? false, - _drawable = null, - _bundle = bundle ?? rootBundle; + SpineWidget.fromAsset( + this._atlasFile, + this._skeletonFile, + this._controller, { + AssetBundle? bundle, + BoxFit? fit, + Alignment? alignment, + BoundsProvider? boundsProvider, + bool? sizedByBounds, + super.key, + }) : _assetType = _AssetType.asset, + _fit = fit ?? BoxFit.contain, + _alignment = alignment ?? Alignment.center, + _boundsProvider = boundsProvider ?? const SetupPoseBounds(), + _sizedByBounds = sizedByBounds ?? false, + _drawable = null, + _bundle = bundle ?? rootBundle; /// Constructs a new [SpineWidget] from files. The [_atlasFile] specifies the `.atlas` file to be loaded for the images used to render /// the skeleton. The [_skeletonFile] specifies either a Skeleton `.json` or `.skel` file containing the skeleton data. @@ -303,15 +316,22 @@ class SpineWidget extends StatefulWidget { /// are used. /// /// The widget can optionally by sized by the bounds provided by the [BoundsProvider] by passing `true` for [sizedByBounds]. - const SpineWidget.fromFile(this._atlasFile, this._skeletonFile, this._controller, - {BoxFit? fit, Alignment? alignment, BoundsProvider? boundsProvider, bool? sizedByBounds, super.key}) - : _assetType = _AssetType.file, - _bundle = null, - _fit = fit ?? BoxFit.contain, - _alignment = alignment ?? Alignment.center, - _boundsProvider = boundsProvider ?? const SetupPoseBounds(), - _sizedByBounds = sizedByBounds ?? false, - _drawable = null; + const SpineWidget.fromFile( + this._atlasFile, + this._skeletonFile, + this._controller, { + BoxFit? fit, + Alignment? alignment, + BoundsProvider? boundsProvider, + bool? sizedByBounds, + super.key, + }) : _assetType = _AssetType.file, + _bundle = null, + _fit = fit ?? BoxFit.contain, + _alignment = alignment ?? Alignment.center, + _boundsProvider = boundsProvider ?? const SetupPoseBounds(), + _sizedByBounds = sizedByBounds ?? false, + _drawable = null; /// Constructs a new [SpineWidget] from HTTP URLs. The [_atlasFile] specifies the `.atlas` file to be loaded for the images used to render /// the skeleton. The [_skeletonFile] specifies either a Skeleton `.json` or `.skel` file containing the skeleton data. @@ -324,15 +344,22 @@ class SpineWidget extends StatefulWidget { /// are used. /// /// The widget can optionally by sized by the bounds provided by the [BoundsProvider] by passing `true` for [sizedByBounds]. - const SpineWidget.fromHttp(this._atlasFile, this._skeletonFile, this._controller, - {BoxFit? fit, Alignment? alignment, BoundsProvider? boundsProvider, bool? sizedByBounds, super.key}) - : _assetType = _AssetType.http, - _bundle = null, - _fit = fit ?? BoxFit.contain, - _alignment = alignment ?? Alignment.center, - _boundsProvider = boundsProvider ?? const SetupPoseBounds(), - _sizedByBounds = sizedByBounds ?? false, - _drawable = null; + const SpineWidget.fromHttp( + this._atlasFile, + this._skeletonFile, + this._controller, { + BoxFit? fit, + Alignment? alignment, + BoundsProvider? boundsProvider, + bool? sizedByBounds, + super.key, + }) : _assetType = _AssetType.http, + _bundle = null, + _fit = fit ?? BoxFit.contain, + _alignment = alignment ?? Alignment.center, + _boundsProvider = boundsProvider ?? const SetupPoseBounds(), + _sizedByBounds = sizedByBounds ?? false, + _drawable = null; /// Constructs a new [SpineWidget] from a [SkeletonDrawable]. /// @@ -344,16 +371,22 @@ class SpineWidget extends StatefulWidget { /// are used. /// /// The widget can optionally by sized by the bounds provided by the [BoundsProvider] by passing `true` for [sizedByBounds]. - const SpineWidget.fromDrawable(this._drawable, this._controller, - {BoxFit? fit, Alignment? alignment, BoundsProvider? boundsProvider, bool? sizedByBounds, super.key}) - : _assetType = _AssetType.drawable, - _bundle = null, - _fit = fit ?? BoxFit.contain, - _alignment = alignment ?? Alignment.center, - _boundsProvider = boundsProvider ?? const SetupPoseBounds(), - _sizedByBounds = sizedByBounds ?? false, - _skeletonFile = null, - _atlasFile = null; + const SpineWidget.fromDrawable( + this._drawable, + this._controller, { + BoxFit? fit, + Alignment? alignment, + BoundsProvider? boundsProvider, + bool? sizedByBounds, + super.key, + }) : _assetType = _AssetType.drawable, + _bundle = null, + _fit = fit ?? BoxFit.contain, + _alignment = alignment ?? Alignment.center, + _boundsProvider = boundsProvider ?? const SetupPoseBounds(), + _sizedByBounds = sizedByBounds ?? false, + _skeletonFile = null, + _atlasFile = null; @override State createState() => _SpineWidgetState(); @@ -382,8 +415,7 @@ class _SpineWidgetState extends State { // loaded. bool hasChanged = true; if (oldWidget._assetType == widget._assetType) { - if (oldWidget._assetType == _AssetType.drawable && - oldWidget._drawable == widget._drawable) { + if (oldWidget._assetType == _AssetType.drawable && oldWidget._drawable == widget._drawable) { hasChanged = false; } else if (oldWidget._skeletonFile == widget._skeletonFile && oldWidget._atlasFile == widget._atlasFile && @@ -431,7 +463,13 @@ class _SpineWidgetState extends State { Widget build(BuildContext context) { if (_drawable != null) { return _SpineRenderObjectWidget( - _drawable!, widget._controller, widget._fit, widget._alignment, _computedBounds, widget._sizedByBounds); + _drawable!, + widget._controller, + widget._fit, + widget._alignment, + _computedBounds, + widget._sizedByBounds, + ); } else { return const SizedBox(); } @@ -452,7 +490,14 @@ class _SpineRenderObjectWidget extends LeafRenderObjectWidget { final Bounds _bounds; final bool _sizedByBounds; - const _SpineRenderObjectWidget(this._skeletonDrawable, this._controller, this._fit, this._alignment, this._bounds, this._sizedByBounds); + const _SpineRenderObjectWidget( + this._skeletonDrawable, + this._controller, + this._fit, + this._alignment, + this._bounds, + this._sizedByBounds, + ); @override RenderObject createRenderObject(BuildContext context) { @@ -481,7 +526,14 @@ class _SpineRenderObject extends RenderBox { bool _disposed = false; bool _firstUpdated = false; - _SpineRenderObject(this._skeletonDrawable, this._controller, this._fit, this._alignment, this._bounds, this._sizedByBounds); + _SpineRenderObject( + this._skeletonDrawable, + this._controller, + this._fit, + this._alignment, + this._bounds, + this._sizedByBounds, + ); set skeletonDrawable(SkeletonDrawable skeletonDrawable) { if (_skeletonDrawable == skeletonDrawable) return; diff --git a/spine-glfw/CMakePresets.json b/spine-glfw/CMakePresets.json new file mode 100644 index 000000000..97930d03f --- /dev/null +++ b/spine-glfw/CMakePresets.json @@ -0,0 +1,41 @@ +{ + "version": 3, + "cmakeMinimumRequired": { + "major": 3, + "minor": 20, + "patch": 0 + }, + "configurePresets": [ + { + "name": "debug", + "displayName": "Debug", + "description": "Debug build with compile commands", + "generator": "Ninja", + "binaryDir": "${sourceDir}/build/debug", + "cacheVariables": { + "CMAKE_BUILD_TYPE": "Debug", + "CMAKE_EXPORT_COMPILE_COMMANDS": "ON" + } + }, + { + "name": "release", + "displayName": "Release", + "description": "Release build", + "inherits": "debug", + "binaryDir": "${sourceDir}/build/release", + "cacheVariables": { + "CMAKE_BUILD_TYPE": "Release" + } + } + ], + "buildPresets": [ + { + "name": "debug", + "configurePreset": "debug" + }, + { + "name": "release", + "configurePreset": "release" + } + ] +} \ No newline at end of file diff --git a/spine-haxe/example/src/Main.hx b/spine-haxe/example/src/Main.hx index cfed97b92..9d05f1f17 100644 --- a/spine-haxe/example/src/Main.hx +++ b/spine-haxe/example/src/Main.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package; @@ -35,63 +35,61 @@ import starlingExamples.Scene.SceneManager; import starling.core.Starling; import flixel.FlxG; import flixel.FlxGame; - import openfl.display.Sprite; import openfl.text.TextField; import openfl.text.TextFormat; import openfl.events.MouseEvent; - import openfl.geom.Rectangle; import starling.events.Event; class Main extends Sprite { - private var background:Sprite; + private var background:Sprite; private var flixelButton:Sprite; - private var starlingButton:Sprite; + private var starlingButton:Sprite; private var uiContainer:Sprite; private static inline var ratio = 4; - private static inline var STAGE_WIDTH:Int = 100 * ratio; - private static inline var STAGE_HEIGHT:Int = 200 * ratio; - private static inline var BUTTON_WIDTH:Int = 80 * ratio; - private static inline var BUTTON_HEIGHT:Int = 40 * ratio; - private static inline var BUTTON_SPACING:Int = 20 * ratio; + private static inline var STAGE_WIDTH:Int = 100 * ratio; + private static inline var STAGE_HEIGHT:Int = 200 * ratio; + private static inline var BUTTON_WIDTH:Int = 80 * ratio; + private static inline var BUTTON_HEIGHT:Int = 40 * ratio; + private static inline var BUTTON_SPACING:Int = 20 * ratio; - public function new() { - super(); - addEventListener(Event.ADDED_TO_STAGE, onAddedToStage); - } + public function new() { + super(); + addEventListener(Event.ADDED_TO_STAGE, onAddedToStage); + } - private function onAddedToStage(e:Event):Void { - removeEventListener(Event.ADDED_TO_STAGE, onAddedToStage); - createUI(); - centerUI(); - stage.addEventListener(Event.RESIZE, onResize); - } + private function onAddedToStage(e:Event):Void { + removeEventListener(Event.ADDED_TO_STAGE, onAddedToStage); + createUI(); + centerUI(); + stage.addEventListener(Event.RESIZE, onResize); + } - private function createUI():Void { - uiContainer = new Sprite(); - addChild(uiContainer); + private function createUI():Void { + uiContainer = new Sprite(); + addChild(uiContainer); - background = new Sprite(); - background.graphics.beginFill(0xA2A2A2); - background.graphics.drawRect(0, 0, STAGE_WIDTH, STAGE_HEIGHT); - background.graphics.endFill(); - uiContainer.addChild(background); + background = new Sprite(); + background.graphics.beginFill(0xA2A2A2); + background.graphics.drawRect(0, 0, STAGE_WIDTH, STAGE_HEIGHT); + background.graphics.endFill(); + uiContainer.addChild(background); - flixelButton = createButton("Flixel", 0xFF0000); - uiContainer.addChild(flixelButton); + flixelButton = createButton("Flixel", 0xFF0000); + uiContainer.addChild(flixelButton); - starlingButton = createButton("Starling", 0x00FF00); - uiContainer.addChild(starlingButton); + starlingButton = createButton("Starling", 0x00FF00); + uiContainer.addChild(starlingButton); - positionButtons(); + positionButtons(); - flixelButton.addEventListener(MouseEvent.CLICK, onFlixelClick); - starlingButton.addEventListener(MouseEvent.CLICK, onStarlingClick); - } + flixelButton.addEventListener(MouseEvent.CLICK, onFlixelClick); + starlingButton.addEventListener(MouseEvent.CLICK, onStarlingClick); + } - private function createButton(label:String, color:Int):Sprite { + private function createButton(label:String, color:Int):Sprite { var button = new Sprite(); var g = button.graphics; @@ -116,53 +114,54 @@ class Main extends Sprite { return button; } - private function positionButtons():Void { - var totalHeight = (BUTTON_HEIGHT * 2) + BUTTON_SPACING; - var startY = (STAGE_HEIGHT - totalHeight) / 2; + private function positionButtons():Void { + var totalHeight = (BUTTON_HEIGHT * 2) + BUTTON_SPACING; + var startY = (STAGE_HEIGHT - totalHeight) / 2; - flixelButton.x = (STAGE_WIDTH - BUTTON_WIDTH) / 2; - flixelButton.y = startY + BUTTON_HEIGHT + BUTTON_SPACING; + flixelButton.x = (STAGE_WIDTH - BUTTON_WIDTH) / 2; + flixelButton.y = startY + BUTTON_HEIGHT + BUTTON_SPACING; - starlingButton.x = (STAGE_WIDTH - BUTTON_WIDTH) / 2; - starlingButton.y = startY; - } + starlingButton.x = (STAGE_WIDTH - BUTTON_WIDTH) / 2; + starlingButton.y = startY; + } private function centerUI():Void { - uiContainer.x = (stage.stageWidth - STAGE_WIDTH) / 2; - uiContainer.y = (stage.stageHeight - STAGE_HEIGHT) / 2; - } + uiContainer.x = (stage.stageWidth - STAGE_WIDTH) / 2; + uiContainer.y = (stage.stageHeight - STAGE_HEIGHT) / 2; + } - private function onResize(e:Event):Void { - centerUI(); - } + private function onResize(e:Event):Void { + centerUI(); + } - private function onFlixelClick(e:MouseEvent):Void { - trace("Launching Flixel game"); + private function onFlixelClick(e:MouseEvent):Void { + trace("Launching Flixel game"); destroyUI(); addChild(new FlxGame(640, 480, FlixelState)); FlxG.autoPause = false; - } + } private function destroyUI():Void { - flixelButton.removeEventListener(MouseEvent.CLICK, onFlixelClick); - starlingButton.removeEventListener(MouseEvent.CLICK, onStarlingClick); - stage.removeEventListener(Event.RESIZE, onResize); + flixelButton.removeEventListener(MouseEvent.CLICK, onFlixelClick); + starlingButton.removeEventListener(MouseEvent.CLICK, onStarlingClick); + stage.removeEventListener(Event.RESIZE, onResize); - removeChild(uiContainer); + removeChild(uiContainer); - background = null; - flixelButton = null; - starlingButton = null; - uiContainer = null; - } + background = null; + flixelButton = null; + starlingButton = null; + uiContainer = null; + } private var starlingSingleton:Starling; - private function onStarlingClick(e:MouseEvent):Void { - trace("Launching Starling game"); + + private function onStarlingClick(e:MouseEvent):Void { + trace("Launching Starling game"); starlingSingleton = new Starling(starling.display.Sprite, stage, new Rectangle(0, 0, 800, 600)); starlingSingleton.supportHighResolutions = true; starlingSingleton.addEventListener(Event.ROOT_CREATED, onStarlingRootCreated); - } + } private function onStarlingRootCreated(event:Event):Void { destroyUI(); diff --git a/spine-haxe/example/src/MainFlixel.hx b/spine-haxe/example/src/MainFlixel.hx index 024283217..24634cf2c 100644 --- a/spine-haxe/example/src/MainFlixel.hx +++ b/spine-haxe/example/src/MainFlixel.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package; @@ -34,10 +34,8 @@ import flixel.FlxG; import flixel.FlxGame; import openfl.display.Sprite; -class MainFlixel extends Sprite -{ - public function new() - { +class MainFlixel extends Sprite { + public function new() { super(); addChild(new FlxGame(640, 480, FlixelState)); FlxG.autoPause = false; diff --git a/spine-haxe/example/src/MainStarling.hx b/spine-haxe/example/src/MainStarling.hx index 10bb7620d..f6d83b89c 100644 --- a/spine-haxe/example/src/MainStarling.hx +++ b/spine-haxe/example/src/MainStarling.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package; diff --git a/spine-haxe/example/src/flixelExamples/AnimationBoundExample.hx b/spine-haxe/example/src/flixelExamples/AnimationBoundExample.hx index 385e888c0..3a8991e46 100644 --- a/spine-haxe/example/src/flixelExamples/AnimationBoundExample.hx +++ b/spine-haxe/example/src/flixelExamples/AnimationBoundExample.hx @@ -25,11 +25,10 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package flixelExamples; - import flixel.util.FlxColor; import flixel.text.FlxText; import spine.Skin; diff --git a/spine-haxe/example/src/flixelExamples/BasicExample.hx b/spine-haxe/example/src/flixelExamples/BasicExample.hx index 779e28b9e..5620f59aa 100644 --- a/spine-haxe/example/src/flixelExamples/BasicExample.hx +++ b/spine-haxe/example/src/flixelExamples/BasicExample.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package flixelExamples; @@ -43,6 +43,7 @@ class BasicExample extends FlxState { var loadBinary = true; var skeletonSprite:SkeletonSprite; + override public function create():Void { FlxG.cameras.bgColor = 0xffa1b2b0; @@ -66,22 +67,20 @@ class BasicExample extends FlxState { trace("loaded"); } - override public function update(elapsed:Float):Void - { - if (FlxG.keys.anyPressed([RIGHT])) { - skeletonSprite.x += 15; - } - if (FlxG.keys.anyPressed([LEFT])) { - skeletonSprite.x -= 15; - } - if (FlxG.keys.anyPressed([DOWN])) { - skeletonSprite.y += 15; - } - if (FlxG.keys.anyPressed([UP])) { - skeletonSprite.y -= 15; - } - - super.update(elapsed); + override public function update(elapsed:Float):Void { + if (FlxG.keys.anyPressed([RIGHT])) { + skeletonSprite.x += 15; + } + if (FlxG.keys.anyPressed([LEFT])) { + skeletonSprite.x -= 15; + } + if (FlxG.keys.anyPressed([DOWN])) { + skeletonSprite.y += 15; + } + if (FlxG.keys.anyPressed([UP])) { + skeletonSprite.y -= 15; } + super.update(elapsed); + } } diff --git a/spine-haxe/example/src/flixelExamples/CelestialCircusExample.hx b/spine-haxe/example/src/flixelExamples/CelestialCircusExample.hx index fcf5f179d..c9eb219ef 100644 --- a/spine-haxe/example/src/flixelExamples/CelestialCircusExample.hx +++ b/spine-haxe/example/src/flixelExamples/CelestialCircusExample.hx @@ -25,11 +25,10 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package flixelExamples; - import flixel.text.FlxText; import flixel.math.FlxPoint; import spine.Skin; @@ -47,6 +46,7 @@ class CelestialCircusExample extends FlxState { var loadBinary = true; var skeletonSprite:SkeletonSprite; + override public function create():Void { FlxG.cameras.bgColor = 0xffa1b2b0; @@ -55,7 +55,8 @@ class CelestialCircusExample extends FlxState { add(button); var atlas = new TextureAtlas(Assets.getText("assets/celestial-circus.atlas"), new FlixelTextureLoader("assets/celestial-circus.atlas")); - var data = SkeletonData.from(loadBinary ? Assets.getBytes("assets/celestial-circus-pro.skel") : Assets.getText("assets/celestial-circus-pro.json"), atlas, .15); + var data = SkeletonData.from(loadBinary ? Assets.getBytes("assets/celestial-circus-pro.skel") : Assets.getText("assets/celestial-circus-pro.json"), + atlas, .15); var animationStateData = new AnimationStateData(data); animationStateData.defaultMix = 0.25; @@ -73,32 +74,27 @@ class CelestialCircusExample extends FlxState { var dragging:Bool = false; var lastX:Float = 0; var lastY:Float = 0; - override public function update(elapsed:Float):Void - { + + override public function update(elapsed:Float):Void { super.update(elapsed); mousePosition = FlxG.mouse.getPosition(); - if (FlxG.mouse.justPressed && skeletonSprite.overlapsPoint(mousePosition)) - { + if (FlxG.mouse.justPressed && skeletonSprite.overlapsPoint(mousePosition)) { dragging = true; lastX = mousePosition.x; - lastY = mousePosition.y; + lastY = mousePosition.y; } - if (FlxG.mouse.justReleased) dragging = false; + if (FlxG.mouse.justReleased) + dragging = false; - if (dragging) - { + if (dragging) { skeletonSprite.x += mousePosition.x - lastX; skeletonSprite.y += mousePosition.y - lastY; - skeletonSprite.skeleton.physicsTranslate( - mousePosition.x - lastX, - mousePosition.y - lastY, - ); + skeletonSprite.skeleton.physicsTranslate(mousePosition.x - lastX, mousePosition.y - lastY,); lastX = mousePosition.x; - lastY = mousePosition.y; + lastY = mousePosition.y; } - } } diff --git a/spine-haxe/example/src/flixelExamples/CloudPotExample.hx b/spine-haxe/example/src/flixelExamples/CloudPotExample.hx index 092e4f4ee..10e261185 100644 --- a/spine-haxe/example/src/flixelExamples/CloudPotExample.hx +++ b/spine-haxe/example/src/flixelExamples/CloudPotExample.hx @@ -25,11 +25,10 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package flixelExamples; - import spine.Skin; import flixel.ui.FlxButton; import flixel.FlxG; diff --git a/spine-haxe/example/src/flixelExamples/ControlBonesExample.hx b/spine-haxe/example/src/flixelExamples/ControlBonesExample.hx index 19a5a1171..49c7c13d8 100644 --- a/spine-haxe/example/src/flixelExamples/ControlBonesExample.hx +++ b/spine-haxe/example/src/flixelExamples/ControlBonesExample.hx @@ -25,11 +25,10 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package flixelExamples; - import flixel.util.FlxSave; import flixel.math.FlxPoint; import flixel.util.FlxColor; @@ -49,7 +48,8 @@ class ControlBonesExample extends FlxState { var loadBinary = true; private var controlBones = []; - private var controls:Array = []; + private var controls:Array = []; + override public function create():Void { FlxG.cameras.bgColor = 0xffa1b2b0; @@ -92,7 +92,7 @@ class ControlBonesExample extends FlxState { } var point = [.0, .0]; - skeletonSprite.beforeUpdateWorldTransforms = function (go) { + skeletonSprite.beforeUpdateWorldTransforms = function(go) { for (i in 0...controls.length) { var bone = controlBones[i]; var control = controls[i]; @@ -101,7 +101,7 @@ class ControlBonesExample extends FlxState { go.haxeWorldCoordinatesToBone(point, bone); bone.pose.x = point[0]; bone.pose.y = point[1]; - } + } }; super.create(); @@ -111,25 +111,24 @@ class ControlBonesExample extends FlxState { var offsetX:Float = 0; var offsetY:Float = 0; var sprite:FlxSprite; - override public function update(elapsed:Float):Void - { + + override public function update(elapsed:Float):Void { super.update(elapsed); mousePosition = FlxG.mouse.getPosition(); for (control in controls) { - if (FlxG.mouse.justPressed && control.overlapsPoint(mousePosition)) - { + if (FlxG.mouse.justPressed && control.overlapsPoint(mousePosition)) { sprite = control; offsetX = mousePosition.x - sprite.x; offsetY = mousePosition.y - sprite.y; } } - if (FlxG.mouse.justReleased) sprite = null; + if (FlxG.mouse.justReleased) + sprite = null; - if (sprite != null) - { + if (sprite != null) { sprite.x = mousePosition.x - offsetX; sprite.y = mousePosition.y - offsetY; } diff --git a/spine-haxe/example/src/flixelExamples/EventsExample.hx b/spine-haxe/example/src/flixelExamples/EventsExample.hx index 9d57e0cad..861ca315c 100644 --- a/spine-haxe/example/src/flixelExamples/EventsExample.hx +++ b/spine-haxe/example/src/flixelExamples/EventsExample.hx @@ -25,11 +25,10 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package flixelExamples; - import flixel.text.FlxText; import flixel.ui.FlxButton; import flixel.FlxG; @@ -76,9 +75,7 @@ class EventsExample extends FlxState { skeletonSprite.skeleton.setupPoseBones(); add(skeletonSprite); - trackEntry.onEvent.add( - (entry, event) -> log('Custom event for ${entry.animation.name}: ${event.data.name}')); - + trackEntry.onEvent.add((entry, event) -> log('Custom event for ${entry.animation.name}: ${event.data.name}')); add(textContainer); super.create(); @@ -88,6 +85,7 @@ class EventsExample extends FlxState { private var logs = new Array(); private var logsNumber = 0; private var yOffset = 12; + private function log(text:String) { var length = logs.length; var newLog = new FlxText(250, 30, text); diff --git a/spine-haxe/example/src/flixelExamples/FlixelState.hx b/spine-haxe/example/src/flixelExamples/FlixelState.hx index 9d0215c94..eb3efe8ad 100644 --- a/spine-haxe/example/src/flixelExamples/FlixelState.hx +++ b/spine-haxe/example/src/flixelExamples/FlixelState.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package flixelExamples; @@ -43,8 +43,7 @@ import flixel.FlxG; import flixel.FlxState; import flixel.text.FlxText; -class FlixelState extends FlxState -{ +class FlixelState extends FlxState { var spineSprite:SkeletonSprite; var sprite:FlxSprite; var sprite2:FlxSprite; @@ -57,8 +56,7 @@ class FlixelState extends FlxState var scale = 4; var speed:Float; - override public function create():Void - { + override public function create():Void { FlxG.cameras.bgColor = 0xffa1b2b0; // setting speed of spineboy (450 is the speed to not let him slide) @@ -76,8 +74,8 @@ class FlixelState extends FlxState // creating the text to display overlapping state myText = new FlxText(0, 25, 150, "", 16); - myText.alignment = CENTER; - group.add(myText); + myText.alignment = CENTER; + group.add(myText); var button = new FlxButton(0, 0, "Next scene", () -> FlxG.switchState(() -> new BasicExample())); button.setPosition(FlxG.width * .75, FlxG.height / 10); @@ -92,14 +90,14 @@ class FlixelState extends FlxState // instructions var groupInstructions = new FlxSpriteGroup(); groupInstructions.setPosition(50, 405); - groupInstructions.add(new FlxText(0, 0, 200, "Left/Right - Move", 16)); - groupInstructions.add(new FlxText(0, 25, 150, "Space - Jump", 16)); - groupInstructions.add(new FlxText(200, 25, 400, "Click the button for the next example", 16)); + groupInstructions.add(new FlxText(0, 0, 200, "Left/Right - Move", 16)); + groupInstructions.add(new FlxText(0, 25, 150, "Space - Jump", 16)); + groupInstructions.add(new FlxText(200, 25, 400, "Click the button for the next example", 16)); add(groupInstructions); // loading spineboy var atlas = new TextureAtlas(Assets.getText("assets/spineboy.atlas"), new FlixelTextureLoader("assets/spineboy.atlas")); - var skeletondata = SkeletonData.from(Assets.getText("assets/spineboy-pro.json"), atlas, 1/scale); + var skeletondata = SkeletonData.from(Assets.getText("assets/spineboy-pro.json"), atlas, 1 / scale); var animationStateData = new AnimationStateData(skeletondata); spineSprite = new SkeletonSprite(skeletondata, animationStateData); @@ -166,8 +164,8 @@ class FlixelState extends FlxState } var justSetIdle = true; - override public function update(elapsed:Float):Void - { + + override public function update(elapsed:Float):Void { if (FlxG.overlap(spineSprite, group)) { myText.text = "Overlapping"; } else { @@ -191,11 +189,13 @@ class FlixelState extends FlxState var flipped = false; var deltaX; if (FlxG.keys.anyPressed([RIGHT])) { - if (spineSprite.flipX == true) flipped = true; + if (spineSprite.flipX == true) + flipped = true; spineSprite.flipX = false; } if (FlxG.keys.anyPressed([LEFT])) { - if (spineSprite.flipX == false) flipped = true; + if (spineSprite.flipX == false) + flipped = true; spineSprite.flipX = true; } @@ -211,14 +211,12 @@ class FlixelState extends FlxState spineSprite.state.setAnimationByName(0, "walk", true); } } - } else if (!jumping && !justSetIdle) { justSetWalking = false; justSetIdle = true; spineSprite.state.setAnimationByName(0, "idle", true); } - super.update(elapsed); } } diff --git a/spine-haxe/example/src/flixelExamples/MixAndMatchExample.hx b/spine-haxe/example/src/flixelExamples/MixAndMatchExample.hx index 5478faa93..6024ef0a2 100644 --- a/spine-haxe/example/src/flixelExamples/MixAndMatchExample.hx +++ b/spine-haxe/example/src/flixelExamples/MixAndMatchExample.hx @@ -25,11 +25,10 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package flixelExamples; - import spine.Skin; import flixel.ui.FlxButton; import flixel.FlxG; @@ -43,9 +42,10 @@ import spine.atlas.TextureAtlas; class MixAndMatchExample extends FlxState { var loadBinary = false; - // var loadBinary = true; + // var loadBinary = true; var skeletonSprite:SkeletonSprite; + override public function create():Void { FlxG.cameras.bgColor = 0xffa1b2b0; @@ -54,7 +54,8 @@ class MixAndMatchExample extends FlxState { add(button); var atlas = new TextureAtlas(Assets.getText("assets/mix-and-match.atlas"), new FlixelTextureLoader("assets/mix-and-match.atlas")); - var data = SkeletonData.from(loadBinary ? Assets.getBytes("assets/mix-and-match-pro.skel") : Assets.getText("assets/mix-and-match-pro.json"), atlas, .5); + var data = SkeletonData.from(loadBinary ? Assets.getBytes("assets/mix-and-match-pro.skel") : Assets.getText("assets/mix-and-match-pro.json"), atlas, + .5); var animationStateData = new AnimationStateData(data); animationStateData.defaultMix = 0.25; @@ -80,5 +81,4 @@ class MixAndMatchExample extends FlxState { super.create(); } - } diff --git a/spine-haxe/example/src/flixelExamples/SackExample.hx b/spine-haxe/example/src/flixelExamples/SackExample.hx index f0fccbe2c..d4b8be6b1 100644 --- a/spine-haxe/example/src/flixelExamples/SackExample.hx +++ b/spine-haxe/example/src/flixelExamples/SackExample.hx @@ -25,11 +25,10 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package flixelExamples; - import spine.Skin; import flixel.ui.FlxButton; import flixel.FlxG; diff --git a/spine-haxe/example/src/flixelExamples/SequenceExample.hx b/spine-haxe/example/src/flixelExamples/SequenceExample.hx index 839a20527..63b22766c 100644 --- a/spine-haxe/example/src/flixelExamples/SequenceExample.hx +++ b/spine-haxe/example/src/flixelExamples/SequenceExample.hx @@ -25,11 +25,10 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package flixelExamples; - import flixel.ui.FlxButton; import flixel.FlxG; import spine.flixel.SkeletonSprite; @@ -44,6 +43,7 @@ class SequenceExample extends FlxState { var loadBinary = true; var skeletonSprite:SkeletonSprite; + override public function create():Void { FlxG.cameras.bgColor = 0xffa1b2b0; @@ -64,5 +64,4 @@ class SequenceExample extends FlxState { add(skeletonSprite); super.create(); } - } diff --git a/spine-haxe/example/src/flixelExamples/SnowglobeExample.hx b/spine-haxe/example/src/flixelExamples/SnowglobeExample.hx index 185474ab8..4bde6bdaf 100644 --- a/spine-haxe/example/src/flixelExamples/SnowglobeExample.hx +++ b/spine-haxe/example/src/flixelExamples/SnowglobeExample.hx @@ -25,11 +25,10 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package flixelExamples; - import spine.Skin; import flixel.ui.FlxButton; import flixel.FlxG; diff --git a/spine-haxe/example/src/flixelExamples/TankExample.hx b/spine-haxe/example/src/flixelExamples/TankExample.hx index 7de108181..39c57890a 100644 --- a/spine-haxe/example/src/flixelExamples/TankExample.hx +++ b/spine-haxe/example/src/flixelExamples/TankExample.hx @@ -25,11 +25,10 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package flixelExamples; - import spine.Skin; import flixel.ui.FlxButton; import flixel.FlxG; diff --git a/spine-haxe/example/src/flixelExamples/VineExample.hx b/spine-haxe/example/src/flixelExamples/VineExample.hx index fa4091d6e..1c7431397 100644 --- a/spine-haxe/example/src/flixelExamples/VineExample.hx +++ b/spine-haxe/example/src/flixelExamples/VineExample.hx @@ -25,11 +25,10 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package flixelExamples; - import spine.Skin; import flixel.ui.FlxButton; import flixel.FlxG; diff --git a/spine-haxe/example/src/starlingExamples/AnimationBoundExample.hx b/spine-haxe/example/src/starlingExamples/AnimationBoundExample.hx index eac57cb4b..43a043187 100644 --- a/spine-haxe/example/src/starlingExamples/AnimationBoundExample.hx +++ b/spine-haxe/example/src/starlingExamples/AnimationBoundExample.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package starlingExamples; @@ -44,8 +44,9 @@ import starling.display.Quad; class AnimationBoundExample extends Scene { var loadBinary = false; - var skeletonSpriteClipping: SkeletonSprite; - var skeletonSpriteNoClipping: SkeletonSprite; + var skeletonSpriteClipping:SkeletonSprite; + var skeletonSpriteNoClipping:SkeletonSprite; + public function load():Void { background.color = 0x333333; var scale = .2; @@ -66,8 +67,8 @@ class AnimationBoundExample extends Scene { var animationClipping = skeletonSpriteClipping.state.setAnimationByName(0, "portal", true).animation; var animationBoundClipping = skeletonSpriteClipping.getAnimationBounds(animationClipping, true); var quad:Quad = new Quad(animationBoundClipping.width * scale, animationBoundClipping.height * scale, 0xc70000); - quad.x = skeletonSpriteClipping.x + animationBoundClipping.x * scale; - quad.y = skeletonSpriteClipping.y + animationBoundClipping.y * scale; + quad.x = skeletonSpriteClipping.x + animationBoundClipping.x * scale; + quad.y = skeletonSpriteClipping.y + animationBoundClipping.y * scale; var animationStateDataNoClipping = new AnimationStateData(skeletondata); animationStateDataNoClipping.defaultMix = 0.25; @@ -80,8 +81,8 @@ class AnimationBoundExample extends Scene { var animationNoClipping = skeletonSpriteNoClipping.state.setAnimationByName(0, "portal", true).animation; var animationBoundNoClipping = skeletonSpriteNoClipping.getAnimationBounds(animationNoClipping, false); var quadNoClipping:Quad = new Quad(animationBoundNoClipping.width * scale, animationBoundNoClipping.height * scale, 0xc70000); - quadNoClipping.x = skeletonSpriteNoClipping.x + animationBoundNoClipping.x * scale; - quadNoClipping.y = skeletonSpriteNoClipping.y + animationBoundNoClipping.y * scale; + quadNoClipping.x = skeletonSpriteNoClipping.x + animationBoundNoClipping.x * scale; + quadNoClipping.y = skeletonSpriteNoClipping.y + animationBoundNoClipping.y * scale; addChild(quad); addChild(quadNoClipping); diff --git a/spine-haxe/example/src/starlingExamples/BasicExample.hx b/spine-haxe/example/src/starlingExamples/BasicExample.hx index 51b7a370f..538fb3bde 100644 --- a/spine-haxe/example/src/starlingExamples/BasicExample.hx +++ b/spine-haxe/example/src/starlingExamples/BasicExample.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package starlingExamples; diff --git a/spine-haxe/example/src/starlingExamples/CelestialCircusExample.hx b/spine-haxe/example/src/starlingExamples/CelestialCircusExample.hx index e5886d5eb..5e7b24187 100644 --- a/spine-haxe/example/src/starlingExamples/CelestialCircusExample.hx +++ b/spine-haxe/example/src/starlingExamples/CelestialCircusExample.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package starlingExamples; @@ -52,7 +52,8 @@ class CelestialCircusExample extends Scene { background.color = 0x333333; var atlas = new TextureAtlas(Assets.getText("assets/celestial-circus.atlas"), new StarlingTextureLoader("assets/celestial-circus.atlas")); - var skeletondata = SkeletonData.from(loadBinary ? Assets.getBytes("assets/celestial-circus-pro.skel") : Assets.getText("assets/celestial-circus-pro.json"), atlas); + var skeletondata = SkeletonData.from(loadBinary ? Assets.getBytes("assets/celestial-circus-pro.skel") : Assets.getText("assets/celestial-circus-pro.json"), + atlas); var animationStateData = new AnimationStateData(skeletondata); animationStateData.defaultMix = 0.25; @@ -83,10 +84,7 @@ class CelestialCircusExample extends Scene { skeletonTouch.getMovement(this, movement); skeletonSprite.x += movement.x; skeletonSprite.y += movement.y; - skeletonSprite.skeleton.physicsTranslate( - movement.x / skeletonSprite.scale, - movement.y / skeletonSprite.scale, - ); + skeletonSprite.skeleton.physicsTranslate(movement.x / skeletonSprite.scale, movement.y / skeletonSprite.scale,); } } else { var sceneTouch = e.getTouch(this); @@ -94,8 +92,5 @@ class CelestialCircusExample extends Scene { SceneManager.getInstance().switchScene(new SnowglobeExample()); } } - - } - } diff --git a/spine-haxe/example/src/starlingExamples/CloudPotExample.hx b/spine-haxe/example/src/starlingExamples/CloudPotExample.hx index 6c9cb6a06..5d5fdb2e5 100644 --- a/spine-haxe/example/src/starlingExamples/CloudPotExample.hx +++ b/spine-haxe/example/src/starlingExamples/CloudPotExample.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package starlingExamples; @@ -58,7 +58,6 @@ class CloudPotExample extends Scene { skeletonSprite.skeleton.updateWorldTransform(Physics.update); var bounds = skeletonSprite.skeleton.getBounds(); - skeletonSprite.scale = 0.2; skeletonSprite.x = Starling.current.stage.stageWidth / 2; skeletonSprite.y = Starling.current.stage.stageHeight / 2; diff --git a/spine-haxe/example/src/starlingExamples/ControlBonesExample.hx b/spine-haxe/example/src/starlingExamples/ControlBonesExample.hx index a1539b799..26a95ae32 100644 --- a/spine-haxe/example/src/starlingExamples/ControlBonesExample.hx +++ b/spine-haxe/example/src/starlingExamples/ControlBonesExample.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package starlingExamples; @@ -48,11 +48,12 @@ class ControlBonesExample extends Scene { var skeletonSprite:SkeletonSprite; private var movement = new openfl.geom.Point(); private var controlBones = []; - private var controls = []; + private var controls = []; public function load():Void { var atlas = new TextureAtlas(Assets.getText("assets/stretchyman.atlas"), new StarlingTextureLoader("assets/stretchyman.atlas")); - var skeletondata = SkeletonData.from(loadBinary ? Assets.getBytes("assets/stretchyman-pro.skel") : Assets.getText("assets/stretchyman-pro.json"), atlas); + var skeletondata = SkeletonData.from(loadBinary ? Assets.getBytes("assets/stretchyman-pro.skel") : Assets.getText("assets/stretchyman-pro.json"), + atlas); var animationStateData = new AnimationStateData(skeletondata); animationStateData.defaultMix = 0.25; @@ -97,7 +98,7 @@ class ControlBonesExample extends Scene { } var point = [.0, .0]; - skeletonSprite.beforeUpdateWorldTransforms = function (go) { + skeletonSprite.beforeUpdateWorldTransforms = function(go) { for (i in 0...controls.length) { var bone = controlBones[i]; var control = controls[i]; @@ -106,7 +107,7 @@ class ControlBonesExample extends Scene { go.haxeWorldCoordinatesToBone(point, bone); bone.pose.x = point[0]; bone.pose.y = point[1]; - } + } }; addEventListener(TouchEvent.TOUCH, onTouch); diff --git a/spine-haxe/example/src/starlingExamples/EventsExample.hx b/spine-haxe/example/src/starlingExamples/EventsExample.hx index 5262acc7f..ee62155b3 100644 --- a/spine-haxe/example/src/starlingExamples/EventsExample.hx +++ b/spine-haxe/example/src/starlingExamples/EventsExample.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package starlingExamples; @@ -66,8 +66,7 @@ class EventsExample extends Scene { // add callback to the TrackEntry skeletonSprite.state.setAnimationByName(0, "walk", true); var trackEntry = skeletonSprite.state.addAnimationByName(0, "run", true, 3); - trackEntry.onEvent.add( - (entry, event) -> log('Custom event for ${entry.animation.name}: ${event.data.name}')); + trackEntry.onEvent.add((entry, event) -> log('Custom event for ${entry.animation.name}: ${event.data.name}')); addChild(skeletonSprite); juggler.add(skeletonSprite); @@ -83,6 +82,7 @@ class EventsExample extends Scene { private var logs = new Array(); private var logsNumber = 0; private var yOffset = 12; + private function log(text:String) { var length = logs.length; var newLog = new TextField(250, 30, text); diff --git a/spine-haxe/example/src/starlingExamples/MixAndMatchExample.hx b/spine-haxe/example/src/starlingExamples/MixAndMatchExample.hx index 454f74d19..749fc4c66 100644 --- a/spine-haxe/example/src/starlingExamples/MixAndMatchExample.hx +++ b/spine-haxe/example/src/starlingExamples/MixAndMatchExample.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package starlingExamples; diff --git a/spine-haxe/example/src/starlingExamples/SackExample.hx b/spine-haxe/example/src/starlingExamples/SackExample.hx index d14909260..99eb9196e 100644 --- a/spine-haxe/example/src/starlingExamples/SackExample.hx +++ b/spine-haxe/example/src/starlingExamples/SackExample.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package starlingExamples; @@ -58,7 +58,7 @@ class SackExample extends Scene { skeletonSprite.scale = 0.2; skeletonSprite.x = Starling.current.stage.stageWidth / 2; - skeletonSprite.y = Starling.current.stage.stageHeight/ 2; + skeletonSprite.y = Starling.current.stage.stageHeight / 2; skeletonSprite.state.setAnimationByName(0, "cape-follow-example", true); diff --git a/spine-haxe/example/src/starlingExamples/Scene.hx b/spine-haxe/example/src/starlingExamples/Scene.hx index 41ff43a2f..f5f09b725 100644 --- a/spine-haxe/example/src/starlingExamples/Scene.hx +++ b/spine-haxe/example/src/starlingExamples/Scene.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package starlingExamples; diff --git a/spine-haxe/example/src/starlingExamples/SequenceExample.hx b/spine-haxe/example/src/starlingExamples/SequenceExample.hx index a16b0cec2..2aa64d57e 100644 --- a/spine-haxe/example/src/starlingExamples/SequenceExample.hx +++ b/spine-haxe/example/src/starlingExamples/SequenceExample.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package starlingExamples; diff --git a/spine-haxe/example/src/starlingExamples/SnowglobeExample.hx b/spine-haxe/example/src/starlingExamples/SnowglobeExample.hx index 846cd5d48..47bd3fccb 100644 --- a/spine-haxe/example/src/starlingExamples/SnowglobeExample.hx +++ b/spine-haxe/example/src/starlingExamples/SnowglobeExample.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package starlingExamples; @@ -57,10 +57,9 @@ class SnowglobeExample extends Scene { skeletonSprite.skeleton.updateWorldTransform(Physics.update); var bounds = skeletonSprite.skeleton.getBounds(); - skeletonSprite.scale = 0.15; skeletonSprite.x = Starling.current.stage.stageWidth / 2; - skeletonSprite.y = Starling.current.stage.stageHeight/ 1.5; + skeletonSprite.y = Starling.current.stage.stageHeight / 1.5; skeletonSprite.state.setAnimationByName(0, "shake", true); diff --git a/spine-haxe/example/src/starlingExamples/TankExample.hx b/spine-haxe/example/src/starlingExamples/TankExample.hx index 9b09778db..708c51de2 100644 --- a/spine-haxe/example/src/starlingExamples/TankExample.hx +++ b/spine-haxe/example/src/starlingExamples/TankExample.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package starlingExamples; diff --git a/spine-haxe/example/src/starlingExamples/Test.hx b/spine-haxe/example/src/starlingExamples/Test.hx index 4d78b4e23..5a5e91a88 100644 --- a/spine-haxe/example/src/starlingExamples/Test.hx +++ b/spine-haxe/example/src/starlingExamples/Test.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package starlingExamples; diff --git a/spine-haxe/example/src/starlingExamples/VineExample.hx b/spine-haxe/example/src/starlingExamples/VineExample.hx index 41f1908ed..dd4ff1a6b 100644 --- a/spine-haxe/example/src/starlingExamples/VineExample.hx +++ b/spine-haxe/example/src/starlingExamples/VineExample.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package starlingExamples; diff --git a/spine-haxe/spine-haxe/spine/ArrayUtils.hx b/spine-haxe/spine-haxe/spine/ArrayUtils.hx index 3f127e56c..f0b040ffb 100644 --- a/spine-haxe/spine-haxe/spine/ArrayUtils.hx +++ b/spine-haxe/spine-haxe/spine/ArrayUtils.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; diff --git a/spine-haxe/spine-haxe/spine/BinaryInput.hx b/spine-haxe/spine-haxe/spine/BinaryInput.hx index 218d5dc78..f1d703fbc 100644 --- a/spine-haxe/spine-haxe/spine/BinaryInput.hx +++ b/spine-haxe/spine-haxe/spine/BinaryInput.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; diff --git a/spine-haxe/spine-haxe/spine/BlendMode.hx b/spine-haxe/spine-haxe/spine/BlendMode.hx index 1e230da35..35aea80df 100644 --- a/spine-haxe/spine-haxe/spine/BlendMode.hx +++ b/spine-haxe/spine-haxe/spine/BlendMode.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; diff --git a/spine-haxe/spine-haxe/spine/Bone.hx b/spine-haxe/spine-haxe/spine/Bone.hx index d4213caa7..ac46a3482 100644 --- a/spine-haxe/spine-haxe/spine/Bone.hx +++ b/spine-haxe/spine-haxe/spine/Bone.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; @@ -37,7 +37,8 @@ package spine; class Bone extends PosedActive { static public var yDown:Bool = false; static public var yDir(get, never):Int; - static private function get_yDir(): Int { + + static private function get_yDir():Int { return Bone.yDown ? -1 : 1; } @@ -49,7 +50,7 @@ class Bone extends PosedActive { public var sorted = false; - public function new (data:BoneData, parent:Bone) { + public function new(data:BoneData, parent:Bone) { super(data, new BonePose(), new BonePose()); this.parent = parent; applied.bone = this; diff --git a/spine-haxe/spine-haxe/spine/BoneData.hx b/spine-haxe/spine-haxe/spine/BoneData.hx index 5aed0ece7..51af260fa 100644 --- a/spine-haxe/spine-haxe/spine/BoneData.hx +++ b/spine-haxe/spine-haxe/spine/BoneData.hx @@ -25,13 +25,12 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; /** The setup pose for a bone. */ class BoneData extends PosedData { - /** The index of the bone in spine.Skeleton.getBones(). */ public final index:Int; @@ -41,6 +40,7 @@ class BoneData extends PosedData { public var length = 0.; // Nonessential. + /** The color of the bone as it was in Spine, or a default color if nonessential data was not exported. Bones are not usually * rendered at runtime. */ public var color = new Color(0, 0, 0, 0); @@ -51,10 +51,12 @@ class BoneData extends PosedData { /** False if the bone was hidden in Spine and nonessential data was exported. Does not affect runtime rendering. */ public var visible = false; - public function new (index:Int, name:String, parent:BoneData) { + public function new(index:Int, name:String, parent:BoneData) { super(name, new BoneLocal()); - if (index < 0) throw new SpineException("index must be >= 0."); - if (name == null) throw new SpineException("name cannot be null."); + if (index < 0) + throw new SpineException("index must be >= 0."); + if (name == null) + throw new SpineException("name cannot be null."); this.index = index; this.parent = parent; } diff --git a/spine-haxe/spine-haxe/spine/BoneLocal.hx b/spine-haxe/spine-haxe/spine/BoneLocal.hx index 4dabef224..887be4f45 100644 --- a/spine-haxe/spine-haxe/spine/BoneLocal.hx +++ b/spine-haxe/spine-haxe/spine/BoneLocal.hx @@ -25,13 +25,12 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; /** Stores a bone's local pose. */ class BoneLocal implements Pose { - /** The local x translation. */ public var x:Float = 0; @@ -55,17 +54,19 @@ class BoneLocal implements Pose { /** Determines how parent world transforms affect this bone. */ public var inherit(default, set):Inherit; - function set_inherit (value:Inherit):Inherit { - if (value == null) throw new SpineException("inherit cannot be null."); + + function set_inherit(value:Inherit):Inherit { + if (value == null) + throw new SpineException("inherit cannot be null."); inherit = value; return value; } - public function new () { - } + public function new() {} - public function set (pose:BoneLocal):Void { - if (pose == null) throw new SpineException("pose cannot be null."); + public function set(pose:BoneLocal):Void { + if (pose == null) + throw new SpineException("pose cannot be null."); x = pose.x; y = pose.y; rotation = pose.rotation; @@ -75,5 +76,4 @@ class BoneLocal implements Pose { shearY = pose.shearY; inherit = pose.inherit; } - } diff --git a/spine-haxe/spine-haxe/spine/BonePose.hx b/spine-haxe/spine-haxe/spine/BonePose.hx index 8bde03c36..dbed6bb9e 100644 --- a/spine-haxe/spine-haxe/spine/BonePose.hx +++ b/spine-haxe/spine-haxe/spine/BonePose.hx @@ -25,14 +25,13 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; /** The applied pose for a bone. This is the {@link Bone} pose with constraints applied and the world transform computed by * Skeleton.updateWorldTransform(Physics). */ class BonePose extends BoneLocal implements Update { - public var bone:Bone; /** Part of the world transform matrix for the X axis. If changed, updateAppliedTransform() should be called. */ @@ -61,14 +60,15 @@ class BonePose extends BoneLocal implements Update { // } /** Called by Skeleton.updateCache() to compute the world transform, if needed. */ - public function update (skeleton:Skeleton, physics:Physics):Void { - if (world != skeleton._update) updateWorldTransform(skeleton); + public function update(skeleton:Skeleton, physics:Physics):Void { + if (world != skeleton._update) + updateWorldTransform(skeleton); } /** Computes the world transform using the parent bone's applied pose and this pose. Child bones are not updated. - * - * @see https://esotericsoftware.com/spine-runtime-skeletons#World-transforms World transforms in the Spine Runtimes Guide - */ + * + * @see https://esotericsoftware.com/spine-runtime-skeletons#World-transforms World transforms in the Spine Runtimes Guide + */ public function updateWorldTransform(skeleton:Skeleton):Void { if (local == skeleton._update) updateLocalTransform(skeleton); @@ -139,15 +139,19 @@ class BonePose extends BoneLocal implements Update { c = pc * la + pd * lc; d = pc * lb + pd * ld; case Inherit.noScale, Inherit.noScaleOrReflection: - var r = rotation * MathUtils.degRad, cos = Math.cos(r), sin = Math.sin(r); + var r = rotation * MathUtils.degRad, + cos = Math.cos(r), + sin = Math.sin(r); var za = (pa * cos + pb * sin) / skeleton.scaleX; var zc = (pc * cos + pd * sin) / skeleton.scaleY; var s = Math.sqrt(za * za + zc * zc); - if (s > 0.00001) s = 1 / s; + if (s > 0.00001) + s = 1 / s; za *= s; zc *= s; s = Math.sqrt(za * za + zc * zc); - if (inherit == Inherit.noScale && ((pa * pd - pb * pc < 0) != ((skeleton.scaleX < 0) != (skeleton.scaleY < 0)))) s = -s; + if (inherit == Inherit.noScale && ((pa * pd - pb * pc < 0) != ((skeleton.scaleX < 0) != (skeleton.scaleY < 0)))) + s = -s; r = Math.PI / 2 + Math.atan2(zc, za); var zb:Float = Math.cos(r) * s; var zd:Float = Math.sin(r) * s; @@ -169,13 +173,13 @@ class BonePose extends BoneLocal implements Update { } /** Computes the applied transform values from the world transform. - * - * If the world transform is modified (by a constraint, rotateWorld(), etc) then this method should be called so - * the applied transform matches the world transform. The applied transform may be needed by other code (eg to apply another - * constraint). - * - * Some information is ambiguous in the world transform, such as -1,-1 scale versus 180 rotation. The applied transform after - * calling this method is equivalent to the local transform used to compute the world transform, but may not be identical. */ + * + * If the world transform is modified (by a constraint, rotateWorld(), etc) then this method should be called so + * the applied transform matches the world transform. The applied transform may be needed by other code (eg to apply another + * constraint). + * + * Some information is ambiguous in the world transform, such as -1,-1 scale versus 180 rotation. The applied transform after + * calling this method is equivalent to the local transform used to compute the world transform, but may not be identical. */ public function updateLocalTransform(skeleton:Skeleton):Void { local = 0; world = skeleton._update; @@ -215,15 +219,19 @@ class BonePose extends BoneLocal implements Update { ia = pd * pid; ib = pb * pid; case Inherit.noScale, Inherit.noScaleOrReflection: - var r = rotation * MathUtils.degRad, cos = Math.cos(rotation), sin = Math.sin(rotation); + var r = rotation * MathUtils.degRad, + cos = Math.cos(rotation), + sin = Math.sin(rotation); pa = (pa * cos + pb * sin) / skeleton.scaleX; pc = (pc * cos + pd * sin) / skeleton.scaleY; var s = Math.sqrt(pa * pa + pc * pc); - if (s > 0.00001) s = 1 / s; + if (s > 0.00001) + s = 1 / s; pa *= s; pc *= s; s = Math.sqrt(pa * pa + pc * pc); - if (inherit == Inherit.noScale && (pid < 0 != ((skeleton.scaleX < 0) != (skeleton.scaleY < 0)))) s = -s; + if (inherit == Inherit.noScale && (pid < 0 != ((skeleton.scaleX < 0) != (skeleton.scaleY < 0)))) + s = -s; r = MathUtils.PI / 2 + Math.atan2(pc, pa); pb = Math.cos(r) * s; pd = Math.sin(r) * s; @@ -255,24 +263,26 @@ class BonePose extends BoneLocal implements Update { } /** If the world transform has been modified and the local transform no longer matches, {@link #updateLocalTransform(Skeleton)} - * is called. */ - public function validateLocalTransform (skeleton: Skeleton) { - if (local == skeleton._update) updateLocalTransform(skeleton); + * is called. */ + public function validateLocalTransform(skeleton:Skeleton) { + if (local == skeleton._update) + updateLocalTransform(skeleton); } - public function modifyLocal (skeleton: Skeleton) { - if (local == skeleton._update) updateLocalTransform(skeleton); + public function modifyLocal(skeleton:Skeleton) { + if (local == skeleton._update) + updateLocalTransform(skeleton); world = 0; resetWorld(skeleton._update); } - public function modifyWorld (update:Int) { + public function modifyWorld(update:Int) { local = update; world = update; resetWorld(update); } - public function resetWorld (update:Int) { + public function resetWorld(update:Int) { var children = bone.children; for (i in 0...bone.children.length) { var child = children[i].applied; @@ -331,14 +341,14 @@ class BonePose extends BoneLocal implements Update { } /** Transforms a point from world coordinates to the parent bone's local coordinates. */ - public function worldToParent(world: Array):Array { + public function worldToParent(world:Array):Array { if (world == null) throw new SpineException("world cannot be null."); return bone.parent == null ? world : bone.parent.applied.worldToLocal(world); } /** Transforms a point from the parent bone's coordinates to world coordinates. */ - public function parentToWorld(world: Array):Array { + public function parentToWorld(world:Array):Array { if (world == null) throw new SpineException("world cannot be null."); return bone.parent == null ? world : bone.parent.applied.localToWorld(world); @@ -373,7 +383,7 @@ class BonePose extends BoneLocal implements Update { d = sin * rb + cos * d; } - public function toString ():String { + public function toString():String { return bone.data.name; } } diff --git a/spine-haxe/spine-haxe/spine/Color.hx b/spine-haxe/spine-haxe/spine/Color.hx index dc8d47683..511460e2d 100644 --- a/spine-haxe/spine-haxe/spine/Color.hx +++ b/spine-haxe/spine-haxe/spine/Color.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; diff --git a/spine-haxe/spine-haxe/spine/Constraint.hx b/spine-haxe/spine-haxe/spine/Constraint.hx index d79a66215..394630cd0 100644 --- a/spine-haxe/spine-haxe/spine/Constraint.hx +++ b/spine-haxe/spine-haxe/spine/Constraint.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; @@ -33,17 +33,16 @@ abstract class Constraint< // T:Constraint, // D:ConstraintData, // P:Pose> // - extends PosedActive implements Update { - - public function new (data:D, pose:P, constrained:P) { +extends PosedActive implements Update { + public function new(data:D, pose:P, constrained:P) { super(data, pose, constrained); } - public abstract function copy (skeleton:Skeleton):T; + public abstract function copy(skeleton:Skeleton):T; - public abstract function sort (skeleton:Skeleton):Void; + public abstract function sort(skeleton:Skeleton):Void; - public function isSourceActive ():Bool { + public function isSourceActive():Bool { return true; } -} \ No newline at end of file +} diff --git a/spine-haxe/spine-haxe/spine/ConstraintData.hx b/spine-haxe/spine-haxe/spine/ConstraintData.hx index ac7081da3..93dc080fe 100644 --- a/spine-haxe/spine-haxe/spine/ConstraintData.hx +++ b/spine-haxe/spine-haxe/spine/ConstraintData.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; @@ -33,11 +33,10 @@ package spine; abstract class ConstraintData< // T:Constraint, // P:Pose> // - extends PosedData

{ - +extends PosedData

{ function new(name:String, setup:P) { super(name, setup); } - public abstract function create (skeleton:Skeleton):T; + public abstract function create(skeleton:Skeleton):T; } diff --git a/spine-haxe/spine-haxe/spine/Event.hx b/spine-haxe/spine-haxe/spine/Event.hx index 48a8ee7a1..3cc3d0318 100644 --- a/spine-haxe/spine-haxe/spine/Event.hx +++ b/spine-haxe/spine-haxe/spine/Event.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; @@ -50,7 +50,8 @@ class Event { public var balance = 0.; public function new(time:Float, data:EventData) { - if (data == null) throw new SpineException("data cannot be null."); + if (data == null) + throw new SpineException("data cannot be null."); this.time = time; this.data = data; } diff --git a/spine-haxe/spine-haxe/spine/EventData.hx b/spine-haxe/spine-haxe/spine/EventData.hx index 1117cd492..017380e59 100644 --- a/spine-haxe/spine-haxe/spine/EventData.hx +++ b/spine-haxe/spine-haxe/spine/EventData.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; diff --git a/spine-haxe/spine-haxe/spine/HasTextureRegion.hx b/spine-haxe/spine-haxe/spine/HasTextureRegion.hx index cb289d14e..9a714de48 100644 --- a/spine-haxe/spine-haxe/spine/HasTextureRegion.hx +++ b/spine-haxe/spine-haxe/spine/HasTextureRegion.hx @@ -25,19 +25,23 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; interface HasTextureRegion { /** The name used to find the region. */ public var path:String; + /** Sets the region used to draw the attachment. After setting the region or if the region's properties are changed, * updateRegion() must be called. */ public var region:TextureRegion; + /** The color to tint the attachment. */ public var color:Color; + public var sequence:Sequence; + /** Updates any values the attachment calculates using the region. Must be called after setting the * region or if the region's properties are changed. */ public function updateRegion():Void; diff --git a/spine-haxe/spine-haxe/spine/IkConstraint.hx b/spine-haxe/spine-haxe/spine/IkConstraint.hx index 7dae6da21..c76364311 100644 --- a/spine-haxe/spine-haxe/spine/IkConstraint.hx +++ b/spine-haxe/spine-haxe/spine/IkConstraint.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; @@ -34,7 +34,6 @@ package spine; * * @see https://esotericsoftware.com/spine-ik-constraints IK constraints in the Spine User Guide */ class IkConstraint extends Constraint { - /** The 1 or 2 bones that will be modified by this IK constraint. */ public final bones:Array; @@ -43,7 +42,8 @@ class IkConstraint extends Constraint(); for (boneData in data.bones) @@ -51,24 +51,27 @@ class IkConstraint extends Constraint 1) skeleton.constrained(bones[1].bone); + if (bones.length > 1) + skeleton.constrained(bones[1].bone); } - override public function isSourceActive () { + override public function isSourceActive() { return target.active; } - public function set_target (target:Bone):Bone { - if (target == null) throw new SpineException("target cannot be null."); + public function set_target(target:Bone):Bone { + if (target == null) + throw new SpineException("target cannot be null."); this.target = target; return target; } /** Applies 1 bone IK. The target is specified in the world coordinate system. */ - static public function apply1(skeleton:Skeleton, bone:BonePose, targetX:Float, targetY:Float, compress:Bool, stretch:Bool, - uniform:Bool, mix:Float) { - - if (bone == null) throw new SpineException("bone cannot be null."); + static public function apply1(skeleton:Skeleton, bone:BonePose, targetX:Float, targetY:Float, compress:Bool, stretch:Bool, uniform:Bool, mix:Float) { + if (bone == null) + throw new SpineException("bone cannot be null."); bone.modifyLocal(skeleton); var p = bone.bone.parent.applied; var pa = p.a, pb = p.b, pc = p.c, pd = p.d; @@ -127,7 +131,8 @@ class IkConstraint extends Constraint 180) rotationIK -= 360; else if (rotationIK < -180) // @@ -139,13 +144,14 @@ class IkConstraint extends Constraint 0.0001) { - var dd = tx * tx + ty * ty; + var dd = tx * tx + ty * ty; if ((compress && dd < b * b) || (stretch && dd > b * b)) { var s = (Math.sqrt(dd) / b - 1) * mix + 1; bone.scaleX *= s; - if (uniform) bone.scaleY *= s; + if (uniform) + bone.scaleY *= s; } } } @@ -153,12 +159,14 @@ class IkConstraint extends Constraint { - /** The bones that are constrained by this IK constraint. */ public final bones:Array = new Array(); @@ -44,17 +43,17 @@ class IkConstraintData extends ConstraintData { * on both the X and Y axes. */ public var uniform = false; - public function new(name:String) { super(name, new IkConstraintPose()); } - public function create (skeleton:Skeleton):IkConstraint { + public function create(skeleton:Skeleton):IkConstraint { return new IkConstraint(this, skeleton); } - public function set_target (target:BoneData) { - if (target == null) throw new SpineException("target cannot be null."); + public function set_target(target:BoneData) { + if (target == null) + throw new SpineException("target cannot be null."); this.target = target; return target; } diff --git a/spine-haxe/spine-haxe/spine/IkConstraintPose.hx b/spine-haxe/spine-haxe/spine/IkConstraintPose.hx index ca3d74e77..cacfb0867 100644 --- a/spine-haxe/spine-haxe/spine/IkConstraintPose.hx +++ b/spine-haxe/spine-haxe/spine/IkConstraintPose.hx @@ -25,13 +25,12 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; /** Stores the current pose for an IK constraint. */ class IkConstraintPose implements Pose { - /** For two bone IK, controls the bend direction of the IK bones, either 1 or -1. */ public var bendDirection = 0; @@ -39,29 +38,27 @@ class IkConstraintPose implements Pose { public var compress:Bool = false; /** When true and the target is out of range, the parent bone is scaled to reach it. - * - * For two bone IK: 1) the child bone's local Y translation is set to 0, 2) stretch is not applied if softness is - * > 0, and 3) if the parent bone has local nonuniform scale, stretch is not applied. */ + * + * For two bone IK: 1) the child bone's local Y translation is set to 0, 2) stretch is not applied if softness is + * > 0, and 3) if the parent bone has local nonuniform scale, stretch is not applied. */ public var stretch:Bool = false; /** A percentage (0-1) that controls the mix between the constrained and unconstrained rotation. - * - * For two bone IK: if the parent bone has local nonuniform scale, the child bone's local Y translation is set to 0. */ + * + * For two bone IK: if the parent bone has local nonuniform scale, the child bone's local Y translation is set to 0. */ public var mix = 0.; /** For two bone IK, the target bone's distance from the maximum reach of the bones where rotation begins to slow. The bones - * will not straighten completely until the target is this far out of range. */ + * will not straighten completely until the target is this far out of range. */ public var softness = 0.; - public function new () { - } + public function new() {} - public function set (pose:IkConstraintPose) { + public function set(pose:IkConstraintPose) { mix = pose.mix; softness = pose.softness; bendDirection = pose.bendDirection; compress = pose.compress; stretch = pose.stretch; } - -} \ No newline at end of file +} diff --git a/spine-haxe/spine-haxe/spine/Inherit.hx b/spine-haxe/spine-haxe/spine/Inherit.hx index 90654c914..42f54f8dd 100644 --- a/spine-haxe/spine-haxe/spine/Inherit.hx +++ b/spine-haxe/spine-haxe/spine/Inherit.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; diff --git a/spine-haxe/spine-haxe/spine/MathUtils.hx b/spine-haxe/spine-haxe/spine/MathUtils.hx index bb116337f..e7b86260f 100644 --- a/spine-haxe/spine-haxe/spine/MathUtils.hx +++ b/spine-haxe/spine-haxe/spine/MathUtils.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; @@ -63,7 +63,7 @@ class MathUtils { * @param x The x-coordinate. * @return The arc tangent in degrees. */ - static public function atan2Deg (y:Float, x:Float):Float { + static public function atan2Deg(y:Float, x:Float):Float { return Math.atan2(y, x) * MathUtils.radDeg; } diff --git a/spine-haxe/spine-haxe/spine/PathConstraint.hx b/spine-haxe/spine-haxe/spine/PathConstraint.hx index 92868fc24..131b7793d 100644 --- a/spine-haxe/spine-haxe/spine/PathConstraint.hx +++ b/spine-haxe/spine-haxe/spine/PathConstraint.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; @@ -56,9 +56,10 @@ class PathConstraint extends Constraint(); private final segments = new Array(); - public function new (data:PathConstraintData, skeleton:Skeleton) { + public function new(data:PathConstraintData, skeleton:Skeleton) { super(data, new PathConstraintPose(), new PathConstraintPose()); - if (skeleton == null) throw new SpineException("skeleton cannot be null."); + if (skeleton == null) + throw new SpineException("skeleton cannot be null."); bones = new Array(); for (boneData in data.bones) @@ -76,18 +77,23 @@ class PathConstraint extends Constraint = positions, world = new Array(); var closed = path.closed; - var verticesLength = path.worldVerticesLength, curveCount = Std.int(verticesLength / 6), prevCurve = NONE; + var verticesLength = path.worldVerticesLength, + curveCount = Std.int(verticesLength / 6), + prevCurve = NONE; if (!path.constantSpeed) { var lengths = path.lengths; curveCount -= closed ? 1 : 2; var pathLength = lengths[curveCount]; - if (data.positionMode == PositionMode.percent) position *= pathLength; + if (data.positionMode == PositionMode.percent) + position *= pathLength; - var multiplier: Float; + var multiplier:Float; switch (data.spacingMode) { - case SpacingMode.percent: multiplier = pathLength; - case SpacingMode.proportional: multiplier = pathLength / spacesCount; - default: multiplier = 1; + case SpacingMode.percent: + multiplier = pathLength; + case SpacingMode.proportional: + multiplier = pathLength / spacesCount; + default: + multiplier = 1; } ArrayUtils.resize(world, 8, 0); @@ -234,7 +253,8 @@ class PathConstraint extends Constraint 0 && space == 0)); + addCurvePosition(p, world[0], world[1], world[2], world[3], world[4], world[5], world[6], world[7], out, o, tangents || (i > 0 && space == 0)); i++; o += 3; } @@ -341,13 +360,17 @@ class PathConstraint extends Constraint { - /** The position along the path. */ public var position = 0.; @@ -46,8 +45,7 @@ class PathConstraintPose implements Pose { /** A percentage (0-1) that controls the mix between the constrained and unconstrained translation Y. */ public var mixY = 0.; - public function new () { - } + public function new() {} public function set(pose:PathConstraintPose) { position = pose.position; diff --git a/spine-haxe/spine-haxe/spine/Physics.hx b/spine-haxe/spine-haxe/spine/Physics.hx index b179b0ae8..2a6607ef0 100644 --- a/spine-haxe/spine-haxe/spine/Physics.hx +++ b/spine-haxe/spine-haxe/spine/Physics.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; @@ -33,10 +33,13 @@ package spine; class Physics { /** Physics are not updated or applied. */ public static var none(default, never):Physics = new Physics("none"); + /** Physics are reset to the current pose. */ public static var reset(default, never):Physics = new Physics("reset"); + /** Physics are updated and the pose from physics is applied. */ public static var update(default, never):Physics = new Physics("update"); + /** Physics are not updated but the pose from physics is applied. */ public static var pose(default, never):Physics = new Physics("pose"); diff --git a/spine-haxe/spine-haxe/spine/PhysicsConstraint.hx b/spine-haxe/spine-haxe/spine/PhysicsConstraint.hx index f22fe56ac..58b5317a2 100644 --- a/spine-haxe/spine-haxe/spine/PhysicsConstraint.hx +++ b/spine-haxe/spine-haxe/spine/PhysicsConstraint.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; @@ -35,7 +35,6 @@ package spine; * @see https://esotericsoftware.com/spine-physics-constraints Physics constraints in the Spine User Guide */ class PhysicsConstraint extends Constraint { - /** The bone constrained by this physics constraint. */ public var bone:BonePose = null; @@ -62,9 +61,10 @@ class PhysicsConstraint extends Constraint 0, y = data.y > 0, rotateOrShearX = data.rotate > 0 || data.shearX > 0, scaleX = data.scaleX > 0; + var x = data.x > 0, + y = data.y > 0, + rotateOrShearX = data.rotate > 0 || data.shearX > 0, + scaleX = data.scaleX > 0; var l = bone.bone.data.length, t = data.step, z = 0.; switch (physics) { case Physics.none: return; case Physics.reset, Physics.update: - if (physics == Physics.reset) reset(skeleton); + if (physics == Physics.reset) + reset(skeleton); var delta = Math.max(skeleton.time - lastTime, 0), aa = remaining; remaining += delta; @@ -135,8 +142,8 @@ class PhysicsConstraint extends Constraint 0) scaleOffset += (dx * c + dy * s) * i / r; + if (r > 0) + scaleOffset += (dx * c + dy * s) * i / r; } } else { c = Math.cos(ca); s = Math.sin(ca); var r = l * bone.worldScaleX - scaleLag * Math.max(0, 1 - aa / t); - if (r > 0) scaleOffset += (dx * c + dy * s) * i / r; + if (r > 0) + scaleOffset += (dx * c + dy * s) * i / r; } if (a >= t) { if (d == -1) { d = Math.pow(p.damping, 60 * t); m = t * p.massInverse; e = p.strength; - var w = f * p.wind, g = f * p.gravity * Bone.yDir; + var w = f * p.wind, + g = f * p.gravity * Bone.yDir; ax = (w * skeleton.windX + g * skeleton.gravityX) * skeleton.scaleX; ay = (w * skeleton.windY + g * skeleton.gravityY) * skeleton.scaleY; } @@ -227,7 +239,8 @@ class PhysicsConstraint extends Constraint { - /** The bone constrained by this physics constraint. */ public var bone:BoneData; @@ -44,8 +43,10 @@ class PhysicsConstraintData extends ConstraintData { - public var inertia = 0.; public var strength = 0.; public var damping = 0.; public var massInverse = 0.; public var wind = 0.; public var gravity = 0.; + /** A percentage (0-1) that controls the mix between the constrained and unconstrained poses. */ public var mix = 0.; - public function new () { - } + public function new() {} - public function set (pose:PhysicsConstraintPose) { + public function set(pose:PhysicsConstraintPose) { inertia = pose.inertia; strength = pose.strength; damping = pose.damping; diff --git a/spine-haxe/spine-haxe/spine/Polygon.hx b/spine-haxe/spine-haxe/spine/Polygon.hx index 950b0ab22..6ce4becec 100644 --- a/spine-haxe/spine-haxe/spine/Polygon.hx +++ b/spine-haxe/spine-haxe/spine/Polygon.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; diff --git a/spine-haxe/spine-haxe/spine/Pool.hx b/spine-haxe/spine-haxe/spine/Pool.hx index 351155f6a..25c2feac0 100644 --- a/spine-haxe/spine-haxe/spine/Pool.hx +++ b/spine-haxe/spine-haxe/spine/Pool.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; diff --git a/spine-haxe/spine-haxe/spine/Poolable.hx b/spine-haxe/spine-haxe/spine/Poolable.hx index e087bc5a1..4c7e308a1 100644 --- a/spine-haxe/spine-haxe/spine/Poolable.hx +++ b/spine-haxe/spine-haxe/spine/Poolable.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; diff --git a/spine-haxe/spine-haxe/spine/Pose.hx b/spine-haxe/spine-haxe/spine/Pose.hx index 88da2ad71..6729a1f96 100644 --- a/spine-haxe/spine-haxe/spine/Pose.hx +++ b/spine-haxe/spine-haxe/spine/Pose.hx @@ -25,10 +25,10 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; interface Pose

{ - public function set (pose:P):Void; -} \ No newline at end of file + public function set(pose:P):Void; +} diff --git a/spine-haxe/spine-haxe/spine/Posed.hx b/spine-haxe/spine-haxe/spine/Posed.hx index 4bdad9cfb..3ba13d8d6 100644 --- a/spine-haxe/spine-haxe/spine/Posed.hx +++ b/spine-haxe/spine-haxe/spine/Posed.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; @@ -33,15 +33,16 @@ abstract class Posed< // D:PosedData

, // P:Pose, // A:P> { - /** The constraint's setup pose data. */ public final data:D; + public final pose:A; public final constrained:A; public var applied:A; - public function new (data:D, pose:A, constrained:A) { - if (data == null) throw new SpineException("data cannot be null."); + public function new(data:D, pose:A, constrained:A) { + if (data == null) + throw new SpineException("data cannot be null."); this.data = data; this.pose = pose; this.constrained = constrained; @@ -49,35 +50,35 @@ abstract class Posed< // } /** The constraint's setup pose data. */ - public function getData ():D { + public function getData():D { return data; } - public function getPose ():P { + public function getPose():P { return pose; } - public function getAppliedPose ():A { + public function getAppliedPose():A { return applied; } - public function setupPose ():Void { + public function setupPose():Void { pose.set(data.setup); } - public function usePose ():Void { // Port: usePose - reference runtime: pose() + public function usePose():Void { // Port: usePose - reference runtime: pose() applied = pose; } - public function useConstrained ():Void { // Port: useConstrained - reference runtime: constrained() + public function useConstrained():Void { // Port: useConstrained - reference runtime: constrained() applied = constrained; } - public function resetConstrained ():Void { // Port: resetConstrained - reference runtime: reset() + public function resetConstrained():Void { // Port: resetConstrained - reference runtime: reset() constrained.set(pose); } - public function toString ():String { + public function toString():String { return data.name; } } diff --git a/spine-haxe/spine-haxe/spine/PosedActive.hx b/spine-haxe/spine-haxe/spine/PosedActive.hx index 8c092d979..93a2d98d6 100644 --- a/spine-haxe/spine-haxe/spine/PosedActive.hx +++ b/spine-haxe/spine-haxe/spine/PosedActive.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; @@ -33,11 +33,10 @@ abstract class PosedActive< // D:PosedData

, // P:Pose, // A:P> // - extends Posed { - +extends Posed { public var active:Bool; - public function new (data:D, pose:A, constrained:A) { + public function new(data:D, pose:A, constrained:A) { super(data, pose, constrained); setupPose(); } @@ -49,7 +48,7 @@ abstract class PosedActive< // * @see Skin.getConstraints() * @see PosedData.getSkinRequired() * @see Skeleton.updateCache() */ - public function isActive ():Bool { + public function isActive():Bool { return active; } } diff --git a/spine-haxe/spine-haxe/spine/PosedData.hx b/spine-haxe/spine-haxe/spine/PosedData.hx index d42878b41..aaf69b10c 100644 --- a/spine-haxe/spine-haxe/spine/PosedData.hx +++ b/spine-haxe/spine-haxe/spine/PosedData.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; @@ -37,18 +37,19 @@ abstract class PosedData> { public final setup:P; /** When true, `Skeleton.updateWorldTransform(Physics)` only updates this constraint if the `Skeleton.getSkin()` - * contains this constraint. - * - * See `Skin.getConstraints()`. */ + * contains this constraint. + * + * See `Skin.getConstraints()`. */ public var skinRequired:Bool; - public function new (name:String, setup:P) { - if (name == null) throw new SpineException("name cannot be null."); + public function new(name:String, setup:P) { + if (name == null) + throw new SpineException("name cannot be null."); this.name = name; this.setup = setup; } - public function toString ():String { + public function toString():String { return name; } } diff --git a/spine-haxe/spine-haxe/spine/PositionMode.hx b/spine-haxe/spine-haxe/spine/PositionMode.hx index 4206cbbc3..dd8ac40c6 100644 --- a/spine-haxe/spine-haxe/spine/PositionMode.hx +++ b/spine-haxe/spine-haxe/spine/PositionMode.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; diff --git a/spine-haxe/spine-haxe/spine/Rectangle.hx b/spine-haxe/spine-haxe/spine/Rectangle.hx index 64b5ea95d..d85e70c1d 100644 --- a/spine-haxe/spine-haxe/spine/Rectangle.hx +++ b/spine-haxe/spine-haxe/spine/Rectangle.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; diff --git a/spine-haxe/spine-haxe/spine/RotateMode.hx b/spine-haxe/spine-haxe/spine/RotateMode.hx index 6bc2aae42..a679a25b9 100644 --- a/spine-haxe/spine-haxe/spine/RotateMode.hx +++ b/spine-haxe/spine-haxe/spine/RotateMode.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; @@ -35,6 +35,7 @@ package spine; class RotateMode { public static var tangent(default, never):RotateMode = new RotateMode("tangent"); public static var chain(default, never):RotateMode = new RotateMode("chain"); + /** When chain scale, constrained bones should all have the same parent. That way when the path constraint scales a bone, it * doesn't affect other constrained bones. */ public static var chainScale(default, never):RotateMode = new RotateMode("chainScale"); diff --git a/spine-haxe/spine-haxe/spine/Sequence.hx b/spine-haxe/spine-haxe/spine/Sequence.hx index 3974d00fc..d31d9037c 100644 --- a/spine-haxe/spine-haxe/spine/Sequence.hx +++ b/spine-haxe/spine-haxe/spine/Sequence.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; @@ -35,6 +35,7 @@ class Sequence { /** Returns a unique ID for this attachment. */ public var id = _nextID++; + public var regions:Array; public var start = 0; public var digits = 0; diff --git a/spine-haxe/spine-haxe/spine/SequenceMode.hx b/spine-haxe/spine-haxe/spine/SequenceMode.hx index 8ea02336d..134adefef 100644 --- a/spine-haxe/spine-haxe/spine/SequenceMode.hx +++ b/spine-haxe/spine-haxe/spine/SequenceMode.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; diff --git a/spine-haxe/spine-haxe/spine/Skeleton.hx b/spine-haxe/spine-haxe/spine/Skeleton.hx index 183033539..8e4a4a93c 100644 --- a/spine-haxe/spine-haxe/spine/Skeleton.hx +++ b/spine-haxe/spine-haxe/spine/Skeleton.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; @@ -65,7 +65,7 @@ class Skeleton { /** The list of bones and constraints, sorted in the order they should be updated, as computed by Skeleton.updateCache(). */ public final _updateCache = new Array(); - private final resetCache = new Array> (); + private final resetCache = new Array>(); /** The skeleton's current skin. */ public var skin(default, set):Skin = null; @@ -84,14 +84,15 @@ class Skeleton { public var y:Float = 0; /** Scales the entire skeleton on the X axis. - * - * Bones that do not inherit scale are still affected by this property. */ + * + * Bones that do not inherit scale are still affected by this property. */ public var scaleX:Float = 1; /** Scales the entire skeleton on the Y axis. - * - * Bones that do not inherit scale are still affected by this property. */ + * + * Bones that do not inherit scale are still affected by this property. */ public var scaleY(get, default):Float = 1; + function get_scaleY() { return scaleY * Bone.yDir; } @@ -110,7 +111,8 @@ class Skeleton { /** Creates a new skeleton with the specified skeleton data. */ public function new(data:SkeletonData) { - if (data == null) throw new SpineException("data cannot be null."); + if (data == null) + throw new SpineException("data cannot be null."); this.data = data; bones = new Array(); @@ -138,7 +140,8 @@ class Skeleton { constraints = new Array>(); for (constraintData in data.constraints) { var constraint = constraintData.create(this); - if (Std.isOfType(constraint, PhysicsConstraint)) physics.push(cast(constraint, PhysicsConstraint)); + if (Std.isOfType(constraint, PhysicsConstraint)) + physics.push(cast(constraint, PhysicsConstraint)); constraints.push(constraint); } @@ -180,7 +183,8 @@ class Skeleton { var constraint:Constraint = c; constraint.active = constraint.isSourceActive() && (!constraint.data.skinRequired || (skin != null && contains(skin.constraints, constraint.data))); - if (constraint.active) constraint.sort(this); + if (constraint.active) + constraint.sort(this); } for (bone in bones) @@ -201,7 +205,7 @@ class Skeleton { return list.indexOf(element) != -1; } - public function constrained (object:Posed) { + public function constrained(object:Posed) { if (object.pose == object.applied) { object.useConstrained(); resetCache.push(object); @@ -209,9 +213,11 @@ class Skeleton { } public function sortBone(bone:Bone):Void { - if (bone.sorted || !bone.active) return; + if (bone.sorted || !bone.active) + return; var parent = bone.parent; - if (parent != null) sortBone(parent); + if (parent != null) + sortBone(parent); bone.sorted = true; _updateCache.push(bone); } @@ -219,7 +225,8 @@ class Skeleton { public function sortReset(bones:Array):Void { for (bone in bones) { if (bone.active) { - if (bone.sorted) sortReset(bone.children); + if (bone.sorted) + sortReset(bone.children); bone.sorted = false; } } @@ -247,8 +254,10 @@ class Skeleton { /** Sets the bones and constraints to their setup pose values. */ public function setupPoseBones():Void { - for (bone in this.bones) bone.setupPose(); - for (constraint in this.constraints) constraint.setupPose(); + for (bone in this.bones) + bone.setupPose(); + for (constraint in this.constraints) + constraint.setupPose(); } /** Sets the slots and draw order to their setup pose values. */ @@ -270,18 +279,22 @@ class Skeleton { /** Finds a bone by comparing each bone's name. It is more efficient to cache the results of this method than to call it * repeatedly. */ public function findBone(boneName:String):Bone { - if (boneName == null) throw new SpineException("boneName cannot be null."); + if (boneName == null) + throw new SpineException("boneName cannot be null."); for (bone in bones) - if (bone.data.name == boneName) return bone; + if (bone.data.name == boneName) + return bone; return null; } /** @return -1 if the bone was not found. */ public function findBoneIndex(boneName:String):Int { - if (boneName == null) throw new SpineException("boneName cannot be null."); + if (boneName == null) + throw new SpineException("boneName cannot be null."); var i:Int = 0; for (bone in bones) { - if (bone.data.name == boneName) return i; + if (bone.data.name == boneName) + return i; i++; } return -1; @@ -290,9 +303,11 @@ class Skeleton { /** Finds a slot by comparing each slot's name. It is more efficient to cache the results of this method than to call it * repeatedly. */ public function findSlot(slotName:String):Slot { - if (slotName == null) throw new SpineException("slotName cannot be null."); + if (slotName == null) + throw new SpineException("slotName cannot be null."); for (slot in slots) - if (slot.data.name == slotName) return slot; + if (slot.data.name == slotName) + return slot; return null; } @@ -337,7 +352,8 @@ class Skeleton { var name:String = slot.data.attachmentName; if (name != null) { var attachment:Attachment = newSkin.getAttachment(i, name); - if (attachment != null) slot.pose.attachment = attachment; + if (attachment != null) + slot.pose.attachment = attachment; } i++; } @@ -399,10 +415,13 @@ class Skeleton { } public function findConstraint>(constraintName:String, type:Class):Null { - if (constraintName == null) throw new SpineException("constraintName cannot be null."); - if (type == null) throw new SpineException("type cannot be null."); + if (constraintName == null) + throw new SpineException("constraintName cannot be null."); + if (type == null) + throw new SpineException("type cannot be null."); for (constraint in constraints) - if (Std.isOfType(constraint, type) && constraint.data.name == constraintName) return Std.downcast(constraint, type); + if (Std.isOfType(constraint, type) && constraint.data.name == constraintName) + return Std.downcast(constraint, type); return null; } @@ -411,7 +430,7 @@ class Skeleton { /** Returns the axis aligned bounding box (AABB) of the region and mesh attachments for the current pose. Optionally applies * clipping. */ - public function getBounds(clipper: SkeletonClipping = null):Rectangle { + public function getBounds(clipper:SkeletonClipping = null):Rectangle { var minX = Math.POSITIVE_INFINITY; var minY = Math.POSITIVE_INFINITY; var maxX = Math.NEGATIVE_INFINITY; @@ -456,10 +475,12 @@ class Skeleton { ii += 2; } } - if (clipper != null) clipper.clipEnd(slot); + if (clipper != null) + clipper.clipEnd(slot); } } - if (clipper != null) clipper.clipEnd(); + if (clipper != null) + clipper.clipEnd(); _bounds.x = minX; _bounds.y = minY; _bounds.width = maxX - minX; @@ -468,18 +489,18 @@ class Skeleton { } /** Increments the skeleton's Skeleton.time. */ - public function update (delta:Float):Void { + public function update(delta:Float):Void { time += delta; } /** Calls spine.PhysicsConstraint.translate() for each physics constraint. */ - public function physicsTranslate (x:Float, y:Float):Void { + public function physicsTranslate(x:Float, y:Float):Void { for (physicsConstraint in physics) physicsConstraint.translate(x, y); } /** Calls spine.PhysicsConstraint.rotate() for each physics constraint. */ - public function physicsRotate (x:Float, y:Float, degrees:Float):Void { + public function physicsRotate(x:Float, y:Float, degrees:Float):Void { for (physicsConstraint in physics) physicsConstraint.rotate(x, y, degrees); } diff --git a/spine-haxe/spine-haxe/spine/SkeletonBinary.hx b/spine-haxe/spine-haxe/spine/SkeletonBinary.hx index cf24bf3b4..8108766e6 100644 --- a/spine-haxe/spine-haxe/spine/SkeletonBinary.hx +++ b/spine-haxe/spine-haxe/spine/SkeletonBinary.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; @@ -219,11 +219,13 @@ class SkeletonBinary { data.setup.color.setFromRgba8888(input.readInt32()); var darkColor = input.readInt32(); - if (darkColor != -1) data.setup.darkColor = new Color(0, 0, 0).setFromRgb888(darkColor); + if (darkColor != -1) + data.setup.darkColor = new Color(0, 0, 0).setFromRgb888(darkColor); data.attachmentName = input.readStringRef(); data.blendMode = BlendMode.values[input.readInt(true)]; - if (nonessential) data.visible = input.readBoolean(); + if (nonessential) + data.visible = input.readBoolean(); slots.push(data); } @@ -248,8 +250,10 @@ class SkeletonBinary { setup.bendDirection = (flags & 4) != 0 ? 1 : -1; setup.compress = (flags & 8) != 0; setup.stretch = (flags & 16) != 0; - if ((flags & 32) != 0) setup.mix = (flags & 64) != 0 ? input.readFloat() : 1; - if ((flags & 128) != 0) setup.softness = input.readFloat() * scale; + if ((flags & 32) != 0) + setup.mix = (flags & 64) != 0 ? input.readFloat() : 1; + if ((flags & 128) != 0) + setup.softness = input.readFloat() * scale; constraints[i] = data; case CONSTRAINT_TRANSFORM: var data = new TransformConstraintData(name); @@ -309,20 +313,32 @@ class SkeletonBinary { froms[ii] = from; } flags = input.readByte(); - if ((flags & 1) != 0) data.offsets[TransformConstraintData.ROTATION] = input.readFloat(); - if ((flags & 2) != 0) data.offsets[TransformConstraintData.X] = input.readFloat() * scale; - if ((flags & 4) != 0) data.offsets[TransformConstraintData.Y] = input.readFloat() * scale; - if ((flags & 8) != 0) data.offsets[TransformConstraintData.SCALEX] = input.readFloat(); - if ((flags & 16) != 0) data.offsets[TransformConstraintData.SCALEY] = input.readFloat(); - if ((flags & 32) != 0) data.offsets[TransformConstraintData.SHEARY] = input.readFloat(); + if ((flags & 1) != 0) + data.offsets[TransformConstraintData.ROTATION] = input.readFloat(); + if ((flags & 2) != 0) + data.offsets[TransformConstraintData.X] = input.readFloat() * scale; + if ((flags & 4) != 0) + data.offsets[TransformConstraintData.Y] = input.readFloat() * scale; + if ((flags & 8) != 0) + data.offsets[TransformConstraintData.SCALEX] = input.readFloat(); + if ((flags & 16) != 0) + data.offsets[TransformConstraintData.SCALEY] = input.readFloat(); + if ((flags & 32) != 0) + data.offsets[TransformConstraintData.SHEARY] = input.readFloat(); flags = input.readByte(); var setup = data.setup; - if ((flags & 1) != 0) setup.mixRotate = input.readFloat(); - if ((flags & 2) != 0) setup.mixX = input.readFloat(); - if ((flags & 4) != 0) setup.mixY = input.readFloat(); - if ((flags & 8) != 0) setup.mixScaleX = input.readFloat(); - if ((flags & 16) != 0) setup.mixScaleY = input.readFloat(); - if ((flags & 32) != 0) setup.mixShearY = input.readFloat(); + if ((flags & 1) != 0) + setup.mixRotate = input.readFloat(); + if ((flags & 2) != 0) + setup.mixX = input.readFloat(); + if ((flags & 4) != 0) + setup.mixY = input.readFloat(); + if ((flags & 8) != 0) + setup.mixScaleX = input.readFloat(); + if ((flags & 16) != 0) + setup.mixScaleY = input.readFloat(); + if ((flags & 32) != 0) + setup.mixShearY = input.readFloat(); constraints[i] = data; case CONSTRAINT_PATH: var data = new PathConstraintData(name); @@ -336,12 +352,15 @@ class SkeletonBinary { data.positionMode = PositionMode.values[(flags >> 1) & 2]; data.spacingMode = SpacingMode.values[(flags >> 2) & 3]; data.rotateMode = RotateMode.values[(flags >> 4) & 3]; - if ((flags & 128) != 0) data.offsetRotation = input.readFloat(); + if ((flags & 128) != 0) + data.offsetRotation = input.readFloat(); var setup = data.setup; setup.position = input.readFloat(); - if (data.positionMode == PositionMode.fixed) setup.position *= scale; + if (data.positionMode == PositionMode.fixed) + setup.position *= scale; setup.spacing = input.readFloat(); - if (data.spacingMode == SpacingMode.length || data.spacingMode == SpacingMode.fixed) setup.spacing *= scale; + if (data.spacingMode == SpacingMode.length || data.spacingMode == SpacingMode.fixed) + setup.spacing *= scale; setup.mixRotate = input.readFloat(); setup.mixX = input.readFloat(); setup.mixY = input.readFloat(); @@ -351,11 +370,16 @@ class SkeletonBinary { data.bone = bones[input.readInt(true)]; var flags = input.readByte(); data.skinRequired = (flags & 1) != 0; - if ((flags & 2) != 0) data.x = input.readFloat(); - if ((flags & 4) != 0) data.y = input.readFloat(); - if ((flags & 8) != 0) data.rotate = input.readFloat(); - if ((flags & 16) != 0) data.scaleX = input.readFloat(); - if ((flags & 32) != 0) data.shearX = input.readFloat(); + if ((flags & 2) != 0) + data.x = input.readFloat(); + if ((flags & 4) != 0) + data.y = input.readFloat(); + if ((flags & 8) != 0) + data.rotate = input.readFloat(); + if ((flags & 16) != 0) + data.scaleX = input.readFloat(); + if ((flags & 32) != 0) + data.shearX = input.readFloat(); data.limit = ((flags & 64) != 0 ? input.readFloat() : 5000) * scale; data.step = .1 / input.readUnsignedByte(); var setup = data.setup; @@ -366,13 +390,20 @@ class SkeletonBinary { setup.wind = input.readFloat(); setup.gravity = input.readFloat(); flags = input.readByte(); - if ((flags & 1) != 0) data.inertiaGlobal = true; - if ((flags & 2) != 0) data.strengthGlobal = true; - if ((flags & 4) != 0) data.dampingGlobal = true; - if ((flags & 8) != 0) data.massGlobal = true; - if ((flags & 16) != 0) data.windGlobal = true; - if ((flags & 32) != 0) data.gravityGlobal = true; - if ((flags & 64) != 0) data.mixGlobal = true; + if ((flags & 1) != 0) + data.inertiaGlobal = true; + if ((flags & 2) != 0) + data.strengthGlobal = true; + if ((flags & 4) != 0) + data.dampingGlobal = true; + if ((flags & 8) != 0) + data.massGlobal = true; + if ((flags & 16) != 0) + data.windGlobal = true; + if ((flags & 32) != 0) + data.gravityGlobal = true; + if ((flags & 64) != 0) + data.mixGlobal = true; setup.mix = (flags & 128) != 0 ? input.readFloat() : 1; constraints[i] = data; case CONSTRAINT_SLIDER: @@ -381,8 +412,10 @@ class SkeletonBinary { data.skinRequired = (flags & 1) != 0; data.loop = (flags & 2) != 0; data.additive = (flags & 4) != 0; - if ((flags & 8) != 0) data.setup.time = input.readFloat(); - if ((flags & 16) != 0) data.setup.mix = (flags & 32) != 0 ? input.readFloat() : 1; + if ((flags & 8) != 0) + data.setup.time = input.readFloat(); + if ((flags & 16) != 0) + data.setup.mix = (flags & 32) != 0 ? input.readFloat() : 1; if ((flags & 64) != 0) { data.local = (flags & 128) != 0; data.bone = bones[input.readInt(true)]; @@ -392,10 +425,10 @@ class SkeletonBinary { case 0: data.property = new FromRotate(); case 1: propertyScale = scale; - data.property = new FromX(); + data.property = new FromX(); case 2: propertyScale = scale; - data.property = new FromY(); + data.property = new FromY(); case 3: data.property = new FromScaleX(); case 4: data.property = new FromScaleY(); case 5: data.property = new FromShearY(); @@ -409,7 +442,6 @@ class SkeletonBinary { } } - // Default skin. var defaultSkin:Skin = readSkin(input, skeletonData, true, nonessential); if (defaultSkin != null) { @@ -462,7 +494,7 @@ class SkeletonBinary { animations[i] = readAnimation(input, input.readString(), skeletonData); for (i in 0...constraintCount) - if (Std.isOfType(constraints[i], SliderData)){ + if (Std.isOfType(constraints[i], SliderData)) { var data = cast(constraints[i], SliderData); data.animation = animations[input.readInt(true)]; }; @@ -481,7 +513,8 @@ class SkeletonBinary { } else { skin = new Skin(input.readString()); - if (nonessential) skin.color.setFromRgba8888(input.readInt32()); + if (nonessential) + skin.color.setFromRgba8888(input.readInt32()); var n:Int; var from1 = skeletonData.bones; @@ -622,7 +655,8 @@ class SkeletonBinary { return mesh; case AttachmentType.linkedmesh: path = (flags & 16) != 0 ? input.readStringRef() : name; - if (path == null) throw new SpineException("Path of linked mesh must not be null"); + if (path == null) + throw new SpineException("Path of linked mesh must not be null"); color = (flags & 32) != 0 ? input.readInt32() : 0xffffffff; var sequence = (flags & 64) != 0 ? this.readSequence(input) : null; var inheritTimelines:Bool = (flags & 128) != 0; @@ -757,11 +791,7 @@ class SkeletonBinary { var i:Int = 0, n:Int = 0, ii:Int = 0, nn:Int = 0; var index:Int, slotIndex:Int, timelineType:Int, timelineScale:Float; - var frameCount:Int, - frameLast:Int, - frame:Int, - bezierCount:Int, - bezier:Int; + var frameCount:Int, frameLast:Int, frame:Int, bezierCount:Int, bezier:Int; var time:Float, time2:Float; // Slot timelines. @@ -1009,19 +1039,26 @@ class SkeletonBinary { } bezierCount = input.readInt(true); switch (timelineType) { - case BONE_ROTATE: readTimeline(input, timelines, new RotateTimeline(frameCount, bezierCount, boneIndex), 1); + case BONE_ROTATE: + readTimeline(input, timelines, new RotateTimeline(frameCount, bezierCount, boneIndex), 1); case BONE_TRANSLATE: // readTimeline2(input, timelines, new TranslateTimeline(frameCount, bezierCount, boneIndex), scale); case BONE_TRANSLATEX: // readTimeline(input, timelines, new TranslateXTimeline(frameCount, bezierCount, boneIndex), scale); case BONE_TRANSLATEY: // readTimeline(input, timelines, new TranslateYTimeline(frameCount, bezierCount, boneIndex), scale); - case BONE_SCALE: readTimeline2(input, timelines, new ScaleTimeline(frameCount, bezierCount, boneIndex), 1); - case BONE_SCALEX: readTimeline(input, timelines, new ScaleXTimeline(frameCount, bezierCount, boneIndex), 1); - case BONE_SCALEY: readTimeline(input, timelines, new ScaleYTimeline(frameCount, bezierCount, boneIndex), 1); - case BONE_SHEAR: readTimeline2(input, timelines, new ShearTimeline(frameCount, bezierCount, boneIndex), 1); - case BONE_SHEARX: readTimeline(input, timelines, new ShearXTimeline(frameCount, bezierCount, boneIndex), 1); - case BONE_SHEARY: readTimeline(input, timelines, new ShearYTimeline(frameCount, bezierCount, boneIndex), 1); + case BONE_SCALE: + readTimeline2(input, timelines, new ScaleTimeline(frameCount, bezierCount, boneIndex), 1); + case BONE_SCALEX: + readTimeline(input, timelines, new ScaleXTimeline(frameCount, bezierCount, boneIndex), 1); + case BONE_SCALEY: + readTimeline(input, timelines, new ScaleYTimeline(frameCount, bezierCount, boneIndex), 1); + case BONE_SHEAR: + readTimeline2(input, timelines, new ShearTimeline(frameCount, bezierCount, boneIndex), 1); + case BONE_SHEARX: + readTimeline(input, timelines, new ShearXTimeline(frameCount, bezierCount, boneIndex), 1); + case BONE_SHEARY: + readTimeline(input, timelines, new ShearYTimeline(frameCount, bezierCount, boneIndex), 1); } } } @@ -1035,7 +1072,7 @@ class SkeletonBinary { var flags = input.readByte(); time = input.readFloat(); var mix:Float = (flags & 1) != 0 ? ((flags & 2) != 0 ? input.readFloat() : 1) : 0; - var softness:Float = (flags & 4) != 0 ? input.readFloat() * scale : 0; + var softness:Float = (flags & 4) != 0 ? input.readFloat() * scale : 0; frame = 0; bezier = 0; @@ -1046,7 +1083,7 @@ class SkeletonBinary { flags = input.readByte(); time2 = input.readFloat(); var mix2:Float = (flags & 1) != 0 ? ((flags & 2) != 0 ? input.readFloat() : 1) : 0; - var softness2:Float = (flags & 4) != 0 ? input.readFloat() * scale : 0; + var softness2:Float = (flags & 4) != 0 ? input.readFloat() * scale : 0; if ((flags & 64) != 0) { ikTimeline.setStepped(frame); } else if ((flags & 128) != 0) { @@ -1094,7 +1131,8 @@ class SkeletonBinary { mixScaleY2:Float = input.readFloat(), mixShearY2:Float = input.readFloat(); switch (input.readByte()) { - case CURVE_STEPPED: transformTimeline.setStepped(frame); + case CURVE_STEPPED: + transformTimeline.setStepped(frame); case CURVE_BEZIER: setBezier(input, transformTimeline, bezier++, frame, 0, time, time2, mixRotate, mixRotate2, 1); setBezier(input, transformTimeline, bezier++, frame, 1, time, time2, mixX, mixX2, 1); @@ -1122,15 +1160,16 @@ class SkeletonBinary { index = input.readInt(true); var data = cast(skeletonData.constraints[index], PathConstraintData); for (ii in 0...input.readInt(true)) { - var type:Int = input.readByte(), frameCount:Int = input.readInt(true), bezierCount:Int = input.readInt(true); + var type:Int = input.readByte(), + frameCount:Int = input.readInt(true), + bezierCount:Int = input.readInt(true); switch (type) { case PATH_POSITION: readTimeline(input, timelines, new PathConstraintPositionTimeline(frameCount, bezierCount, index), data.positionMode == PositionMode.fixed ? scale : 1); case PATH_SPACING: - readTimeline(input, timelines, new PathConstraintSpacingTimeline(frameCount, bezierCount, index), - data.spacingMode == SpacingMode.length - || data.spacingMode == SpacingMode.fixed ? scale : 1); + readTimeline(input, timelines, + new PathConstraintSpacingTimeline(frameCount, bezierCount, index), data.spacingMode == SpacingMode.length || data.spacingMode == SpacingMode.fixed ? scale : 1); case PATH_MIX: var mixTimeline:PathConstraintMixTimeline = new PathConstraintMixTimeline(frameCount, bezierCount, index); time = input.readFloat(); @@ -1172,7 +1211,8 @@ class SkeletonBinary { for (i in 0...input.readInt(true)) { var constraintIndex:Int = input.readInt(true) - 1; for (ii in 0...input.readInt(true)) { - var type:Int = input.readByte(), frameCount:Int = input.readInt(true); + var type:Int = input.readByte(), + frameCount:Int = input.readInt(true); if (type == PHYSICS_RESET) { var timeline:PhysicsConstraintResetTimeline = new PhysicsConstraintResetTimeline(frameCount, constraintIndex); for (frame in 0...frameCount) @@ -1183,14 +1223,22 @@ class SkeletonBinary { var bezierCount = input.readInt(true); var timeline:CurveTimeline1; switch (type) { - case PHYSICS_INERTIA: timeline = new PhysicsConstraintInertiaTimeline(frameCount, bezierCount, constraintIndex); - case PHYSICS_STRENGTH: timeline = new PhysicsConstraintStrengthTimeline(frameCount, bezierCount, constraintIndex); - case PHYSICS_DAMPING: timeline = new PhysicsConstraintDampingTimeline(frameCount, bezierCount, constraintIndex); - case PHYSICS_MASS: timeline = new PhysicsConstraintMassTimeline(frameCount, bezierCount, constraintIndex); - case PHYSICS_WIND: timeline = new PhysicsConstraintWindTimeline(frameCount, bezierCount, constraintIndex); - case PHYSICS_GRAVITY: timeline = new PhysicsConstraintGravityTimeline(frameCount, bezierCount, constraintIndex); - case PHYSICS_MIX: timeline = new PhysicsConstraintMixTimeline(frameCount, bezierCount, constraintIndex); - default: throw new SpineException("Unknown physics timeline type: " + type); + case PHYSICS_INERTIA: + timeline = new PhysicsConstraintInertiaTimeline(frameCount, bezierCount, constraintIndex); + case PHYSICS_STRENGTH: + timeline = new PhysicsConstraintStrengthTimeline(frameCount, bezierCount, constraintIndex); + case PHYSICS_DAMPING: + timeline = new PhysicsConstraintDampingTimeline(frameCount, bezierCount, constraintIndex); + case PHYSICS_MASS: + timeline = new PhysicsConstraintMassTimeline(frameCount, bezierCount, constraintIndex); + case PHYSICS_WIND: + timeline = new PhysicsConstraintWindTimeline(frameCount, bezierCount, constraintIndex); + case PHYSICS_GRAVITY: + timeline = new PhysicsConstraintGravityTimeline(frameCount, bezierCount, constraintIndex); + case PHYSICS_MIX: + timeline = new PhysicsConstraintMixTimeline(frameCount, bezierCount, constraintIndex); + default: + throw new SpineException("Unknown physics timeline type: " + type); } readTimeline(input, timelines, timeline, 1); } @@ -1200,12 +1248,17 @@ class SkeletonBinary { for (i in 0...input.readInt(true)) { var index = input.readInt(true); for (ii in 0...input.readInt(true)) { - var type = input.readByte(), frameCount = input.readInt(true), bezierCount = input.readInt(true); + var type = input.readByte(), + frameCount = input.readInt(true), + bezierCount = input.readInt(true); var timeline:CurveTimeline1; switch (type) { - case SLIDER_TIME: timeline = new SliderTimeline(frameCount, bezierCount, index); - case SLIDER_MIX: timeline = new SliderMixTimeline(frameCount, bezierCount, index); - default: throw new SpineException("Unknown slider timeline type: " + type); + case SLIDER_TIME: + timeline = new SliderTimeline(frameCount, bezierCount, index); + case SLIDER_MIX: + timeline = new SliderMixTimeline(frameCount, bezierCount, index); + default: + throw new SpineException("Unknown slider timeline type: " + type); } readTimeline(input, timelines, timeline, 1); } @@ -1350,7 +1403,8 @@ class SkeletonBinary { event.intValue = input.readInt(false); event.floatValue = input.readFloat(); event.stringValue = input.readString(); - if (event.stringValue == null) event.stringValue = eventData.stringValue; + if (event.stringValue == null) + event.stringValue = eventData.stringValue; if (event.data.audioPath != null) { event.volume = input.readFloat(); event.balance = input.readFloat(); @@ -1370,9 +1424,7 @@ class SkeletonBinary { var time:Float = input.readFloat(), value:Float = input.readFloat() * scale; - var frame:Int = 0, - bezier:Int = 0, - frameLast:Int = timeline.getFrameCount() - 1; + var frame:Int = 0, bezier:Int = 0, frameLast:Int = timeline.getFrameCount() - 1; while (true) { timeline.setFrame(frame, time, value); if (frame == frameLast) @@ -1381,8 +1433,10 @@ class SkeletonBinary { var time2:Float = input.readFloat(), value2:Float = input.readFloat() * scale; switch (input.readByte()) { - case CURVE_STEPPED: timeline.setStepped(frame); - case CURVE_BEZIER: setBezier(input, timeline, bezier++, frame, 0, time, time2, value, value2, scale); + case CURVE_STEPPED: + timeline.setStepped(frame); + case CURVE_BEZIER: + setBezier(input, timeline, bezier++, frame, 0, time, time2, value, value2, scale); } time = time2; value = value2; @@ -1397,9 +1451,7 @@ class SkeletonBinary { value1:Float = input.readFloat() * scale, value2:Float = input.readFloat() * scale; - var frame:Int = 0, - bezier:Int = 0, - frameLast:Int = timeline.getFrameCount() - 1; + var frame:Int = 0, bezier:Int = 0, frameLast:Int = timeline.getFrameCount() - 1; while (true) { timeline.setFrame(frame, time, value1, value2); if (frame == frameLast) @@ -1409,7 +1461,8 @@ class SkeletonBinary { nvalue1:Float = input.readFloat() * scale, nvalue2:Float = input.readFloat() * scale; switch (input.readByte()) { - case CURVE_STEPPED: timeline.setStepped(frame); + case CURVE_STEPPED: + timeline.setStepped(frame); case CURVE_BEZIER: setBezier(input, timeline, bezier++, frame, 0, time, time2, value1, nvalue1, scale); setBezier(input, timeline, bezier++, frame, 1, time, time2, value2, nvalue2, scale); diff --git a/spine-haxe/spine-haxe/spine/SkeletonClipping.hx b/spine-haxe/spine-haxe/spine/SkeletonClipping.hx index 1ec8b2733..9d126c2ca 100644 --- a/spine-haxe/spine-haxe/spine/SkeletonClipping.hx +++ b/spine-haxe/spine-haxe/spine/SkeletonClipping.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; @@ -48,9 +48,11 @@ class SkeletonClipping { public function new() {} public function clipStart(skeleton:Skeleton, slot:Slot, clip:ClippingAttachment):Int { - if (clipAttachment != null) return 0; + if (clipAttachment != null) + return 0; var n = clip.worldVerticesLength; - if (n < 6) return 0; + if (n < 6) + return 0; clipAttachment = clip; clippingPolygon.resize(n); @@ -66,7 +68,8 @@ class SkeletonClipping { } public function clipEnd(?slot:Slot):Void { - if (clipAttachment == null || (slot != null && clipAttachment.endSlot != slot.data)) return; + if (clipAttachment == null || (slot != null && clipAttachment.endSlot != slot.data)) + return; clipAttachment = null; clippingPolygons = null; clippedVertices.resize(0); @@ -203,7 +206,8 @@ class SkeletonClipping { var ii:Int = 0; while (ii < clipOutputLength) { - var x = clipOutputItems[ii], y = clipOutputItems[ii + 1]; + var x = clipOutputItems[ii], + y = clipOutputItems[ii + 1]; clippedVerticesItems[s] = x; clippedVerticesItems[s + 1] = y; var c0 = x - x3, c1 = y - y3; diff --git a/spine-haxe/spine-haxe/spine/SkeletonData.hx b/spine-haxe/spine-haxe/spine/SkeletonData.hx index b3ddf133e..3600a534f 100644 --- a/spine-haxe/spine-haxe/spine/SkeletonData.hx +++ b/spine-haxe/spine-haxe/spine/SkeletonData.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; @@ -91,6 +91,7 @@ class SkeletonData { public var hash:String; // Nonessential. + /** The dopesheet FPS in Spine, or zero if nonessential data was not exported. */ public var fps:Float = 0; @@ -123,9 +124,11 @@ class SkeletonData { * @param boneName The name of the bone to find. * @return May be null. */ public function findBone(boneName:String):BoneData { - if (boneName == null) throw new SpineException("boneName cannot be null."); + if (boneName == null) + throw new SpineException("boneName cannot be null."); for (bone in bones) - if (bone.name == boneName) return bone; + if (bone.name == boneName) + return bone; return null; } @@ -149,9 +152,11 @@ class SkeletonData { * @param slotName The name of the slot to find. * @return May be null. */ public function findSlot(slotName:String):SlotData { - if (slotName == null) throw new SpineException("slotName cannot be null."); + if (slotName == null) + throw new SpineException("slotName cannot be null."); for (slot in slots) - if (slot.name == slotName) return slot; + if (slot.name == slotName) + return slot; return null; } @@ -162,9 +167,11 @@ class SkeletonData { * @param skinName The name of the skin to find. * @return May be null. */ public function findSkin(skinName:String):Skin { - if (skinName == null) throw new SpineException("skinName cannot be null."); + if (skinName == null) + throw new SpineException("skinName cannot be null."); for (skin in skins) - if (skin.name == skinName) return skin; + if (skin.name == skinName) + return skin; return null; } @@ -175,9 +182,11 @@ class SkeletonData { * @param eventName The name of the event to find. * @return May be null. */ public function findEvent(eventName:String):EventData { - if (eventName == null) throw new SpineException("eventName cannot be null."); + if (eventName == null) + throw new SpineException("eventName cannot be null."); for (eventData in events) - if (eventData.name == eventName) return eventData; + if (eventData.name == eventName) + return eventData; return null; } @@ -188,17 +197,21 @@ class SkeletonData { * @param animationName The name of the animation to find. * @return May be null. */ public function findAnimation(animationName:String):Animation { - if (animationName == null) throw new SpineException("animationName cannot be null."); + if (animationName == null) + throw new SpineException("animationName cannot be null."); for (animation in animations) - if (animation.name == animationName) return animation; + if (animation.name == animationName) + return animation; return null; } // --- Constraints. public function findConstraint>(constraintName:String, type:Class):T { - if (constraintName == null) throw new SpineException("constraintName cannot be null."); - if (type == null) throw new SpineException("type cannot be null."); + if (constraintName == null) + throw new SpineException("constraintName cannot be null."); + if (type == null) + throw new SpineException("type cannot be null."); for (constraint in constraints) { if (Std.isOfType(constraint, type) && constraint.name == constraintName) diff --git a/spine-haxe/spine-haxe/spine/SkeletonJson.hx b/spine-haxe/spine-haxe/spine/SkeletonJson.hx index 2bbe0f2e6..81a219c84 100644 --- a/spine-haxe/spine-haxe/spine/SkeletonJson.hx +++ b/spine-haxe/spine-haxe/spine/SkeletonJson.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; @@ -140,7 +140,8 @@ class SkeletonJson { data.skinRequired = Reflect.hasField(boneMap, "skin") ? cast(Reflect.getProperty(boneMap, "skin"), Bool) : false; var color:String = Reflect.getProperty(boneMap, "color"); - if (color != null) data.color.setFromString(color); + if (color != null) + data.color.setFromString(color); skeletonData.bones.push(data); } @@ -150,15 +151,18 @@ class SkeletonJson { var slotName:String = Reflect.getProperty(slotMap, "name"); var boneName:String = Reflect.getProperty(slotMap, "bone"); var boneData = skeletonData.findBone(boneName); - if (boneData == null) throw new SpineException("Slot bone not found: " + boneName); + if (boneData == null) + throw new SpineException("Slot bone not found: " + boneName); var data = new SlotData(skeletonData.slots.length, slotName, boneData); var color:String = Reflect.getProperty(slotMap, "color"); - if (color != null) data.setup.color.setFromString(color); + if (color != null) + data.setup.color.setFromString(color); var dark:String = Reflect.getProperty(slotMap, "dark"); - if (dark != null) data.setup.darkColor = new Color(0, 0, 0).setFromString(dark); + if (dark != null) + data.setup.darkColor = new Color(0, 0, 0).setFromString(dark); data.attachmentName = Reflect.getProperty(slotMap, "attachment"); data.blendMode = Reflect.hasField(slotMap, "blend") ? BlendMode.fromName(Reflect.getProperty(slotMap, "blend")) : BlendMode.normal; @@ -179,20 +183,26 @@ class SkeletonJson { for (boneName in cast(Reflect.getProperty(constraintMap, "bones"), Array)) { var bone = skeletonData.findBone(boneName); - if (bone == null) throw new SpineException("IK constraint bone not found: " + boneName); + if (bone == null) + throw new SpineException("IK constraint bone not found: " + boneName); data.bones.push(bone); } data.target = skeletonData.findBone(Reflect.getProperty(constraintMap, "target")); - if (data.target == null) throw new SpineException("Target bone not found: " + Reflect.getProperty(constraintMap, "target")); + if (data.target == null) + throw new SpineException("Target bone not found: " + Reflect.getProperty(constraintMap, "target")); - data.uniform = (Reflect.hasField(constraintMap, "uniform") && cast(Reflect.getProperty(constraintMap, "uniform"), Bool)); + data.uniform = (Reflect.hasField(constraintMap, "uniform") + && cast(Reflect.getProperty(constraintMap, "uniform"), Bool)); var setup = data.setup; setup.mix = getFloat(constraintMap, "mix", 1); setup.softness = getFloat(constraintMap, "softness", 0) * scale; - setup.bendDirection = (!Reflect.hasField(constraintMap, "bendPositive") || cast(Reflect.getProperty(constraintMap, "bendPositive"), Bool)) ? 1 : -1; - setup.compress = (Reflect.hasField(constraintMap, "compress") && cast(Reflect.getProperty(constraintMap, "compress"), Bool)); - setup.stretch = (Reflect.hasField(constraintMap, "stretch") && cast(Reflect.getProperty(constraintMap, "stretch"), Bool)); + setup.bendDirection = (!Reflect.hasField(constraintMap, "bendPositive") + || cast(Reflect.getProperty(constraintMap, "bendPositive"), Bool)) ? 1 : -1; + setup.compress = (Reflect.hasField(constraintMap, "compress") + && cast(Reflect.getProperty(constraintMap, "compress"), Bool)); + setup.stretch = (Reflect.hasField(constraintMap, "stretch") + && cast(Reflect.getProperty(constraintMap, "stretch"), Bool)); skeletonData.constraints.push(data); case "transform": @@ -201,15 +211,19 @@ class SkeletonJson { for (boneName in cast(Reflect.getProperty(constraintMap, "bones"), Array)) { var bone = skeletonData.findBone(boneName); - if (bone == null) throw new SpineException("Transform constraint bone not found: " + boneName); + if (bone == null) + throw new SpineException("Transform constraint bone not found: " + boneName); data.bones.push(bone); } data.source = skeletonData.findBone(Reflect.getProperty(constraintMap, "source")); - if (data.source == null) throw new SpineException("Transform constraint source bone not found: " + Reflect.getProperty(constraintMap, "source")); + if (data.source == null) + throw new SpineException("Transform constraint source bone not found: " + Reflect.getProperty(constraintMap, "source")); - data.localSource = Reflect.hasField(constraintMap, "localSource") ? cast(Reflect.getProperty(constraintMap, "localSource"), Bool) : false; - data.localTarget = Reflect.hasField(constraintMap, "localTarget") ? cast(Reflect.getProperty(constraintMap, "localTarget"), Bool) : false; + data.localSource = Reflect.hasField(constraintMap, + "localSource") ? cast(Reflect.getProperty(constraintMap, "localSource"), Bool) : false; + data.localTarget = Reflect.hasField(constraintMap, + "localTarget") ? cast(Reflect.getProperty(constraintMap, "localTarget"), Bool) : false; data.additive = Reflect.hasField(constraintMap, "additive") ? cast(Reflect.getProperty(constraintMap, "additive"), Bool) : false; data.clamp = Reflect.hasField(constraintMap, "clamp") ? cast(Reflect.getProperty(constraintMap, "clamp"), Bool) : false; @@ -227,31 +241,31 @@ class SkeletonJson { var to:ToProperty; switch (name) { case "rotate": { - rotate = true; - to = new ToRotate(); - } + rotate = true; + to = new ToRotate(); + } case "x": { - x = true; - to = new ToX(); - toScale = scale; - } + x = true; + to = new ToX(); + toScale = scale; + } case "y": { - y = true; - to = new ToY(); - toScale = scale; - } + y = true; + to = new ToY(); + toScale = scale; + } case "scaleX": { - scaleX = true; - to = new ToScaleX(); - } + scaleX = true; + to = new ToScaleX(); + } case "scaleY": { - scaleY = true; - to = new ToScaleY(); - } + scaleY = true; + to = new ToScaleY(); + } case "shearY": { - shearY = true; - to = new ToShearY(); - } + shearY = true; + to = new ToShearY(); + } default: throw new SpineException("Invalid transform constraint to property: " + toEntry.name); } to.offset = getFloat(toEntry, "offset", 0) * toScale; @@ -259,7 +273,8 @@ class SkeletonJson { to.scale = getFloat(toEntry, "scale") * toScale / fromScale; from.to.push(to); } - if (from.to.length > 0) data.properties.push(from); + if (from.to.length > 0) + data.properties.push(from); } data.offsets[TransformConstraintData.ROTATION] = getFloat(constraintMap, "rotation", 0); @@ -270,12 +285,18 @@ class SkeletonJson { data.offsets[TransformConstraintData.SHEARY] = getFloat(constraintMap, "shearY", 0); var setup = data.setup; - if (rotate) setup.mixRotate = getFloat(constraintMap, "mixRotate", 1); - if (x) setup.mixX = getFloat(constraintMap, "mixX", 1); - if (y) setup.mixY = getFloat(constraintMap, "mixY", setup.mixX); - if (scaleX) setup.mixScaleX = getFloat(constraintMap, "mixScaleX", 1); - if (scaleY) setup.mixScaleY = getFloat(constraintMap, "mixScaleY", setup.mixScaleX); - if (shearY) setup.mixShearY = getFloat(constraintMap, "mixShearY", 1); + if (rotate) + setup.mixRotate = getFloat(constraintMap, "mixRotate", 1); + if (x) + setup.mixX = getFloat(constraintMap, "mixX", 1); + if (y) + setup.mixY = getFloat(constraintMap, "mixY", setup.mixX); + if (scaleX) + setup.mixScaleX = getFloat(constraintMap, "mixScaleX", 1); + if (scaleY) + setup.mixScaleY = getFloat(constraintMap, "mixScaleY", setup.mixScaleX); + if (shearY) + setup.mixShearY = getFloat(constraintMap, "mixShearY", 1); skeletonData.constraints.push(data); case "path": @@ -284,23 +305,30 @@ class SkeletonJson { for (boneName in cast(Reflect.getProperty(constraintMap, "bones"), Array)) { var bone = skeletonData.findBone(boneName); - if (bone == null) throw new SpineException("Path bone not found: " + boneName); + if (bone == null) + throw new SpineException("Path bone not found: " + boneName); data.bones.push(bone); } var slotName = getString(constraintMap, "slot", ""); data.slot = skeletonData.findSlot(slotName); - if (data.slot == null) throw new SpineException("Path slot not found: " + slotName); + if (data.slot == null) + throw new SpineException("Path slot not found: " + slotName); - data.positionMode = Reflect.hasField(constraintMap, "positionMode") ? PositionMode.fromName(Reflect.getProperty(constraintMap, "positionMode")) : PositionMode.percent; - data.spacingMode = Reflect.hasField(constraintMap, "spacingMode") ? SpacingMode.fromName(Reflect.getProperty(constraintMap, "spacingMode")) : SpacingMode.length; - data.rotateMode = Reflect.hasField(constraintMap, "rotateMode") ? RotateMode.fromName(Reflect.getProperty(constraintMap, "rotateMode")) : RotateMode.tangent; + data.positionMode = Reflect.hasField(constraintMap, + "positionMode") ? PositionMode.fromName(Reflect.getProperty(constraintMap, "positionMode")) : PositionMode.percent; + data.spacingMode = Reflect.hasField(constraintMap, + "spacingMode") ? SpacingMode.fromName(Reflect.getProperty(constraintMap, "spacingMode")) : SpacingMode.length; + data.rotateMode = Reflect.hasField(constraintMap, + "rotateMode") ? RotateMode.fromName(Reflect.getProperty(constraintMap, "rotateMode")) : RotateMode.tangent; data.offsetRotation = getFloat(constraintMap, "rotation", 0); var setup = data.setup; setup.position = getFloat(constraintMap, "position", 0); - if (data.positionMode == PositionMode.fixed) setup.position *= scale; + if (data.positionMode == PositionMode.fixed) + setup.position *= scale; setup.spacing = getFloat(constraintMap, "spacing", 0); - if (data.spacingMode == SpacingMode.length || data.spacingMode == SpacingMode.fixed) setup.spacing *= scale; + if (data.spacingMode == SpacingMode.length || data.spacingMode == SpacingMode.fixed) + setup.spacing *= scale; setup.mixRotate = getFloat(constraintMap, "mixRotate", 1); setup.mixX = getFloat(constraintMap, "mixX", 1); setup.mixY = getFloat(constraintMap, "mixY", setup.mixX); @@ -312,7 +340,8 @@ class SkeletonJson { var boneName:String = getString(constraintMap, "bone"); data.bone = skeletonData.findBone(boneName); - if (data.bone == null) throw new SpineException("Physics bone not found: " + boneName); + if (data.bone == null) + throw new SpineException("Physics bone not found: " + boneName); data.x = getFloat(constraintMap, "x"); data.y = getFloat(constraintMap, "y"); @@ -329,12 +358,17 @@ class SkeletonJson { setup.wind = getFloat(constraintMap, "wind", 0); setup.gravity = getFloat(constraintMap, "gravity", 0); setup.mix = getValue(constraintMap, "mix", 1); - data.inertiaGlobal = Reflect.hasField(constraintMap, "inertiaGlobal") ? cast(Reflect.getProperty(constraintMap, "inertiaGlobal"), Bool) : false; - data.strengthGlobal = Reflect.hasField(constraintMap, "strengthGlobal") ? cast(Reflect.getProperty(constraintMap, "strengthGlobal"), Bool) : false; - data.dampingGlobal = Reflect.hasField(constraintMap, "dampingGlobal") ? cast(Reflect.getProperty(constraintMap, "dampingGlobal"), Bool) : false; - data.dampingGlobal = Reflect.hasField(constraintMap, "dampingGlobal") ? cast(Reflect.getProperty(constraintMap, "dampingGlobal"), Bool) : false; + data.inertiaGlobal = Reflect.hasField(constraintMap, + "inertiaGlobal") ? cast(Reflect.getProperty(constraintMap, "inertiaGlobal"), Bool) : false; + data.strengthGlobal = Reflect.hasField(constraintMap, + "strengthGlobal") ? cast(Reflect.getProperty(constraintMap, "strengthGlobal"), Bool) : false; + data.dampingGlobal = Reflect.hasField(constraintMap, + "dampingGlobal") ? cast(Reflect.getProperty(constraintMap, "dampingGlobal"), Bool) : false; + data.dampingGlobal = Reflect.hasField(constraintMap, + "dampingGlobal") ? cast(Reflect.getProperty(constraintMap, "dampingGlobal"), Bool) : false; data.windGlobal = Reflect.hasField(constraintMap, "windGlobal") ? cast(Reflect.getProperty(constraintMap, "windGlobal"), Bool) : false; - data.gravityGlobal = Reflect.hasField(constraintMap, "gravityGlobal") ? cast(Reflect.getProperty(constraintMap, "gravityGlobal"), Bool) : false; + data.gravityGlobal = Reflect.hasField(constraintMap, + "gravityGlobal") ? cast(Reflect.getProperty(constraintMap, "gravityGlobal"), Bool) : false; data.mixGlobal = Reflect.hasField(constraintMap, "mixGlobal") ? cast(Reflect.getProperty(constraintMap, "mixGlobal"), Bool) : false; skeletonData.constraints.push(data); @@ -349,7 +383,8 @@ class SkeletonJson { var boneName = getString(constraintMap, "bone", null); if (boneName != null) { data.bone = skeletonData.findBone(boneName); - if (data.bone == null) throw new SpineException("Slider bone not found: " + boneName); + if (data.bone == null) + throw new SpineException("Slider bone not found: " + boneName); var property = getString(constraintMap, "property"); data.property = fromProperty(property); var propertyScale = propertyScale(property, scale); @@ -364,7 +399,6 @@ class SkeletonJson { } } - // Skins. if (Reflect.hasField(root, "skins")) { for (skinMap in cast(Reflect.getProperty(root, "skins"), Array)) { @@ -424,7 +458,8 @@ class SkeletonJson { var slider = cast(Reflect.getProperty(skinMap, "slider"), Array); for (ii in 0...slider.length) { var constraint = skeletonData.findConstraint(slider[ii], SliderData); - if (constraint == null) throw new SpineException("Skin slider constraint not found: " + slider[ii]); + if (constraint == null) + throw new SpineException("Skin slider constraint not found: " + slider[ii]); skin.constraints.push(constraint); } } @@ -495,7 +530,8 @@ class SkeletonJson { var data = skeletonData.findConstraint(getString(constraintMap, "name"), SliderData); var animationName = getString(constraintMap, "animation", ""); data.animation = skeletonData.findAnimation(animationName); - if (data.animation == null) throw new SpineException("Slider animation not found: " + animationName); + if (data.animation == null) + throw new SpineException("Slider animation not found: " + animationName); } } } @@ -503,25 +539,34 @@ class SkeletonJson { return skeletonData; } - private function fromProperty (type:String): FromProperty { + private function fromProperty(type:String):FromProperty { var property:FromProperty; switch (type) { - case "rotate": property = new FromRotate(); - case "x": property = new FromX(); - case "y": property = new FromY(); - case "scaleX": property = new FromScaleX(); - case "scaleY": property = new FromScaleY(); - case "shearY": property = new FromShearY(); - default: throw new SpineException("Invalid from property: " + type); + case "rotate": + property = new FromRotate(); + case "x": + property = new FromX(); + case "y": + property = new FromY(); + case "scaleX": + property = new FromScaleX(); + case "scaleY": + property = new FromScaleY(); + case "shearY": + property = new FromShearY(); + default: + throw new SpineException("Invalid from property: " + type); }; return property; } - private function propertyScale (type:String, scale:Float):Float { + private function propertyScale(type:String, scale:Float):Float { var scaleValue:Float; switch (type) { - case "x", "y": scaleValue = scale; - default: scaleValue = 1; + case "x", "y": + scaleValue = scale; + default: + scaleValue = 1; }; return scaleValue; } @@ -709,7 +754,8 @@ class SkeletonJson { slotIndex = skeletonData.findSlot(slotName).index; for (timelineName in Reflect.fields(slotMap)) { timelineMap = Reflect.field(slotMap, timelineName); - if (timelineMap == null) continue; + if (timelineMap == null) + continue; switch (timelineName) { case "attachment": @@ -782,7 +828,8 @@ class SkeletonJson { } timelines.push(rgbTimeline); - case "alpha": readTimeline(timelines, timelineMap, new AlphaTimeline(timelineMap.length, timelineMap.length, slotIndex), 0, 1); + case "alpha": + readTimeline(timelines, timelineMap, new AlphaTimeline(timelineMap.length, timelineMap.length, slotIndex), 0, 1); case "rgba2": var rgba2Timeline = new RGBA2Timeline(timelineMap.length, timelineMap.length * 7, slotIndex); @@ -862,7 +909,8 @@ class SkeletonJson { } timelines.push(rgb2Timeline); - default: throw new SpineException("Invalid timeline type for a slot: " + timelineName + " (" + slotName + ")"); + default: + throw new SpineException("Invalid timeline type for a slot: " + timelineName + " (" + slotName + ")"); } } } @@ -871,24 +919,36 @@ class SkeletonJson { var bones = Reflect.getProperty(map, "bones"); for (boneName in Reflect.fields(bones)) { var boneIndex:Int = skeletonData.findBoneIndex(boneName); - if (boneIndex == -1) throw new SpineException("Bone not found: " + boneName); + if (boneIndex == -1) + throw new SpineException("Bone not found: " + boneName); var boneMap:Dynamic = Reflect.field(bones, boneName); for (timelineName in Reflect.fields(boneMap)) { timelineMap = Reflect.field(boneMap, timelineName); var frames = timelineMap.length; - if (frames == 0) continue; + if (frames == 0) + continue; switch (timelineName) { - case "rotate": readTimeline(timelines, timelineMap, new RotateTimeline(frames, frames, boneIndex), 0, 1); - case "translate": readTimeline2(timelines, timelineMap, new TranslateTimeline(frames, frames << 1, boneIndex), "x", "y", 0, scale); - case "translatex": readTimeline(timelines, timelineMap, new TranslateXTimeline(frames, frames, boneIndex), 0, scale); - case "translatey": readTimeline(timelines, timelineMap, new TranslateYTimeline(frames, frames, boneIndex), 0, scale); - case "scale": readTimeline2(timelines, timelineMap, new ScaleTimeline(frames, frames << 1, boneIndex), "x", "y", 1, 1); - case "scalex": readTimeline(timelines, timelineMap, new ScaleXTimeline(frames, frames, boneIndex), 1, 1); - case "scaley": readTimeline(timelines, timelineMap, new ScaleYTimeline(frames, frames, boneIndex), 1, 1); - case "shear": readTimeline2(timelines, timelineMap, new ShearTimeline(frames, frames << 1, boneIndex), "x", "y", 0, 1); - case "shearx": readTimeline(timelines, timelineMap, new ShearXTimeline(frames, frames, boneIndex), 0, 1); - case "sheary": readTimeline(timelines, timelineMap, new ShearYTimeline(frames, frames, boneIndex), 0, 1); + case "rotate": + readTimeline(timelines, timelineMap, new RotateTimeline(frames, frames, boneIndex), 0, 1); + case "translate": + readTimeline2(timelines, timelineMap, new TranslateTimeline(frames, frames << 1, boneIndex), "x", "y", 0, scale); + case "translatex": + readTimeline(timelines, timelineMap, new TranslateXTimeline(frames, frames, boneIndex), 0, scale); + case "translatey": + readTimeline(timelines, timelineMap, new TranslateYTimeline(frames, frames, boneIndex), 0, scale); + case "scale": + readTimeline2(timelines, timelineMap, new ScaleTimeline(frames, frames << 1, boneIndex), "x", "y", 1, 1); + case "scalex": + readTimeline(timelines, timelineMap, new ScaleXTimeline(frames, frames, boneIndex), 1, 1); + case "scaley": + readTimeline(timelines, timelineMap, new ScaleYTimeline(frames, frames, boneIndex), 1, 1); + case "shear": + readTimeline2(timelines, timelineMap, new ShearTimeline(frames, frames << 1, boneIndex), "x", "y", 0, 1); + case "shearx": + readTimeline(timelines, timelineMap, new ShearXTimeline(frames, frames, boneIndex), 0, 1); + case "sheary": + readTimeline(timelines, timelineMap, new ShearYTimeline(frames, frames, boneIndex), 0, 1); case "inherit": var timeline = new InheritTimeline(frames, boneIndex); for (frame in 0...frames) { @@ -896,7 +956,8 @@ class SkeletonJson { timeline.setFrame(frame, getFloat(aFrame, "time"), Inherit.fromName(getValue(aFrame, "inherit", "Normal"))); } timelines.push(timeline); - default: throw new SpineException("Invalid timeline type for a bone: " + timelineName + " (" + boneName + ")"); + default: + throw new SpineException("Invalid timeline type for a bone: " + timelineName + " (" + boneName + ")"); } } } @@ -906,12 +967,13 @@ class SkeletonJson { for (ikConstraintName in Reflect.fields(iks)) { timelineMap = Reflect.field(iks, ikConstraintName); keyMap = timelineMap[0]; - if (keyMap == null) continue; + if (keyMap == null) + continue; var constraint = skeletonData.findConstraint(ikConstraintName, IkConstraintData); - if (constraint == null) throw new SpineException("IK constraint not found: " + ikConstraintName); - var timeline = new IkConstraintTimeline(timelineMap.length, timelineMap.length << 1, - skeletonData.constraints.indexOf(constraint)); + if (constraint == null) + throw new SpineException("IK constraint not found: " + ikConstraintName); + var timeline = new IkConstraintTimeline(timelineMap.length, timelineMap.length << 1, skeletonData.constraints.indexOf(constraint)); time = getFloat(keyMap, "time"); var mix:Float = getFloat(keyMap, "mix", 1); @@ -955,15 +1017,18 @@ class SkeletonJson { for (transformName in Reflect.fields(transforms)) { timelineMap = Reflect.field(transforms, transformName); keyMap = timelineMap[0]; - if (keyMap == null) continue; + if (keyMap == null) + continue; var constraint = skeletonData.findConstraint(transformName, TransformConstraintData); - if (constraint == null) throw new SpineException("Transform constraint not found: " + transformName); - var timeline = new TransformConstraintTimeline(timelineMap.length, timelineMap.length * 6, - skeletonData.constraints.indexOf(constraint)); + if (constraint == null) + throw new SpineException("Transform constraint not found: " + transformName); + var timeline = new TransformConstraintTimeline(timelineMap.length, timelineMap.length * 6, skeletonData.constraints.indexOf(constraint)); var time = getFloat(keyMap, "time", 0); var mixRotate = getFloat(keyMap, "mixRotate", 1); - var mixX = getFloat(keyMap, "mixX", 1), mixY = getFloat(keyMap, "mixY", mixX); - var mixScaleX:Float = getFloat(keyMap, "mixScaleX", 1), mixScaleY:Float = getFloat(keyMap, "mixScaleY", 1); + var mixX = getFloat(keyMap, "mixX", 1), + mixY = getFloat(keyMap, "mixY", mixX); + var mixScaleX:Float = getFloat(keyMap, "mixScaleX", 1), + mixScaleY:Float = getFloat(keyMap, "mixScaleY", 1); var mixShearY:Float = getFloat(keyMap, "mixShearY", 1); frame = 0; @@ -978,8 +1043,10 @@ class SkeletonJson { var time2 = getFloat(nextMap, "time", 0); var mixRotate2 = getFloat(nextMap, "mixRotate", 1); - var mixX2 = getFloat(nextMap, "mixX", 1), mixY2 = getFloat(nextMap, "mixY", mixX2); - var mixScaleX2:Float = getFloat(nextMap, "mixScaleX", 1), mixScaleY2:Float = getFloat(nextMap, "mixScaleY", 1); + var mixX2 = getFloat(nextMap, "mixX", 1), + mixY2 = getFloat(nextMap, "mixY", mixX2); + var mixScaleX2:Float = getFloat(nextMap, "mixScaleX", 1), + mixScaleY2:Float = getFloat(nextMap, "mixScaleY", 1); var mixShearY2:Float = getFloat(nextMap, "mixShearY", 1); var curve = keyMap.curve; if (curve != null) { @@ -1009,14 +1076,16 @@ class SkeletonJson { var paths:Dynamic = Reflect.getProperty(map, "path"); for (pathName in Reflect.fields(paths)) { var constraint = skeletonData.findConstraint(pathName, PathConstraintData); - if (constraint == null) throw new SpineException("Path constraint not found: " + pathName); + if (constraint == null) + throw new SpineException("Path constraint not found: " + pathName); var index = skeletonData.constraints.indexOf(constraint); var pathMap:Dynamic = Reflect.field(paths, pathName); for (timelineName in Reflect.fields(pathMap)) { timelineMap = Reflect.field(pathMap, timelineName); keyMap = timelineMap[0]; - if (keyMap == null) continue; + if (keyMap == null) + continue; switch (timelineName) { case "position": @@ -1024,8 +1093,8 @@ class SkeletonJson { readTimeline(timelines, timelineMap, timeline, 0, constraint.positionMode == PositionMode.fixed ? scale : 1); case "spacing": var timeline = new PathConstraintSpacingTimeline(timelineMap.length, timelineMap.length, index); - readTimeline(timelines, timelineMap, timeline, 0, - constraint.spacingMode == SpacingMode.length || constraint.spacingMode == SpacingMode.fixed ? scale : 1); + readTimeline(timelines, timelineMap, timeline, + 0, constraint.spacingMode == SpacingMode.length || constraint.spacingMode == SpacingMode.fixed ? scale : 1); case "mix": var timeline = new PathConstraintMixTimeline(timelineMap.length, timelineMap.length * 3, index); var time = getFloat(keyMap, "time"); @@ -1072,18 +1141,20 @@ class SkeletonJson { var index = -1; if (physicsName.length > 0) { var constraint = skeletonData.findConstraint(physicsName, PhysicsConstraintData); - if (constraint == null) throw new SpineException("Physics constraint not found: " + physicsName); + if (constraint == null) + throw new SpineException("Physics constraint not found: " + physicsName); index = skeletonData.constraints.indexOf(constraint); } var physicsMap:Dynamic = Reflect.field(physics, physicsName); for (timelineName in Reflect.fields(physicsMap)) { timelineMap = Reflect.field(physicsMap, timelineName); keyMap = timelineMap[0]; - if (keyMap == null) continue; + if (keyMap == null) + continue; var frames = timelineMap.length; - var timeline: CurveTimeline1; + var timeline:CurveTimeline1; var defaultValue = 0.; switch (timelineName) { case "reset": @@ -1092,17 +1163,25 @@ class SkeletonJson { resetTimeline.setFrame(frame, getFloat(keyMap, "time")); timelines.push(resetTimeline); continue; - case "inertia": timeline = new PhysicsConstraintInertiaTimeline(frames, frames, index); - case "strength": timeline = new PhysicsConstraintStrengthTimeline(frames, frames, index); - case "damping": timeline = new PhysicsConstraintDampingTimeline(frames, frames, index); - case "mass": timeline = new PhysicsConstraintMassTimeline(frames, frames, index); - case "wind": timeline = new PhysicsConstraintWindTimeline(frames, frames, index); - case "gravity": timeline = new PhysicsConstraintGravityTimeline(frames, frames, index); - case "mix": { - defaultValue = 1; - timeline = new PhysicsConstraintMixTimeline(frames, frames, index); - } - default: continue; + case "inertia": + timeline = new PhysicsConstraintInertiaTimeline(frames, frames, index); + case "strength": + timeline = new PhysicsConstraintStrengthTimeline(frames, frames, index); + case "damping": + timeline = new PhysicsConstraintDampingTimeline(frames, frames, index); + case "mass": + timeline = new PhysicsConstraintMassTimeline(frames, frames, index); + case "wind": + timeline = new PhysicsConstraintWindTimeline(frames, frames, index); + case "gravity": + timeline = new PhysicsConstraintGravityTimeline(frames, frames, index); + case "mix": + { + defaultValue = 1; + timeline = new PhysicsConstraintMixTimeline(frames, frames, index); + } + default: + continue; } readTimeline(timelines, timelineMap, timeline, defaultValue, 1); } @@ -1112,18 +1191,22 @@ class SkeletonJson { var sliders:Dynamic = Reflect.getProperty(map, "slider"); for (sliderName in Reflect.fields(sliders)) { var constraint = skeletonData.findConstraint(sliderName, SliderData); - if (constraint == null) throw new SpineException("Slider not found: " + sliderName); + if (constraint == null) + throw new SpineException("Slider not found: " + sliderName); var index = skeletonData.constraints.indexOf(constraint); var timelineMap:Dynamic = Reflect.field(sliders, sliderName); for (timelineName in Reflect.fields(timelineMap)) { timelineMap = Reflect.field(timelineMap, timelineName); keyMap = timelineMap[0]; - if (keyMap == null) continue; + if (keyMap == null) + continue; var frames = timelineMap.length; switch (timelineName) { - case "time": readTimeline(timelines, keyMap, new SliderTimeline(frames, frames, index), 1, 1); - case "mix": readTimeline(timelines, keyMap, new SliderMixTimeline(frames, frames, index), 1, 1); + case "time": + readTimeline(timelines, keyMap, new SliderTimeline(frames, frames, index), 1, 1); + case "mix": + readTimeline(timelines, keyMap, new SliderMixTimeline(frames, frames, index), 1, 1); } } } @@ -1344,8 +1427,8 @@ class SkeletonJson { } } - static private function readTimeline2(timelines:Array, keys:Array, timeline:BoneTimeline2, name1:String, name2:String, defaultValue:Float, - scale:Float) { + static private function readTimeline2(timelines:Array, keys:Array, timeline:BoneTimeline2, name1:String, name2:String, + defaultValue:Float, scale:Float) { var keyMap:Dynamic = keys[0]; var time:Float = getFloat(keyMap, "time"); var value1:Float = getFloat(keyMap, name1, defaultValue) * scale; diff --git a/spine-haxe/spine-haxe/spine/Skin.hx b/spine-haxe/spine-haxe/spine/Skin.hx index 48585fc3f..852351bd0 100644 --- a/spine-haxe/spine-haxe/spine/Skin.hx +++ b/spine-haxe/spine-haxe/spine/Skin.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; @@ -51,13 +51,15 @@ class Skin { public final color:Color = new Color(0.99607843, 0.61960787, 0.30980393, 1); // fe9e4fff public function new(name:String) { - if (name == null) throw new SpineException("name cannot be null."); + if (name == null) + throw new SpineException("name cannot be null."); this.name = name; } /** Adds an attachment to the skin for the specified slot index and name. */ public function setAttachment(slotIndex:Int, name:String, attachment:Attachment):Void { - if (attachment == null) throw new SpineException("attachment cannot be null."); + if (attachment == null) + throw new SpineException("attachment cannot be null."); if (slotIndex >= attachments.length) attachments.resize(slotIndex + 1); if (attachments[slotIndex] == null) @@ -218,7 +220,8 @@ class Skin { var skinAttachment:Attachment = dictionary.get(name); if (slotAttachment == skinAttachment) { var attachment:Attachment = getAttachment(slotIndex, name); - if (attachment != null) slot.attachment = attachment; + if (attachment != null) + slot.attachment = attachment; break; } } diff --git a/spine-haxe/spine-haxe/spine/SkinEntry.hx b/spine-haxe/spine-haxe/spine/SkinEntry.hx index e32083104..c390ef853 100644 --- a/spine-haxe/spine-haxe/spine/SkinEntry.hx +++ b/spine-haxe/spine-haxe/spine/SkinEntry.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; @@ -34,8 +34,10 @@ import spine.attachments.Attachment; /** Stores an entry in the skin consisting of the slot index and the attachment name. */ class SkinEntry { public var slotIndex:Int = 0; + /** The name the attachment is associated with, equivalent to the skin placeholder name in the Spine editor. */ public var name:String; + public var attachment:Attachment; public function new(slotIndex:Int, name:String, attachment:Attachment) { diff --git a/spine-haxe/spine-haxe/spine/Slider.hx b/spine-haxe/spine-haxe/spine/Slider.hx index 0c98901e8..1fdd39074 100644 --- a/spine-haxe/spine-haxe/spine/Slider.hx +++ b/spine-haxe/spine-haxe/spine/Slider.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; @@ -36,36 +36,40 @@ import spine.animation.MixDirection; import spine.animation.MixBlend; /** Stores the setup pose for a {@link PhysicsConstraint}. -*

-* See Physics constraints in the Spine User Guide. */ + *

+ * See Physics constraints in the Spine User Guide. */ class Slider extends Constraint { static private final offsets:Array = [for (i in 0...6) .0]; public var bone:Bone; - public function new (data:SliderData, skeleton:Skeleton) { + public function new(data:SliderData, skeleton:Skeleton) { super(data, new SliderPose(), new SliderPose()); - if (skeleton == null) throw new SpineException("skeleton cannot be null."); + if (skeleton == null) + throw new SpineException("skeleton cannot be null."); - if (data.bone != null) bone = skeleton.bones[data.bone.index]; + if (data.bone != null) + bone = skeleton.bones[data.bone.index]; } - public function copy (skeleton:Skeleton) { + public function copy(skeleton:Skeleton) { var copy = new Slider(data, skeleton); copy.pose.set(pose); return copy; } - public function update (skeleton:Skeleton, physics:Physics) { + public function update(skeleton:Skeleton, physics:Physics) { var p = applied; - if (p.mix == 0) return; + if (p.mix == 0) + return; var animation = data.animation; if (bone != null) { - if (!bone.active) return; - if (data.local) bone.applied.validateLocalTransform(skeleton); - p.time = data.offset - + (data.property.value(skeleton, bone.applied, data.local, offsets) - data.property.offset) * data.scale; + if (!bone.active) + return; + if (data.local) + bone.applied.validateLocalTransform(skeleton); + p.time = data.offset + (data.property.value(skeleton, bone.applied, data.local, offsets) - data.property.offset) * data.scale; if (data.loop) p.time = animation.duration + (p.time % animation.duration); else @@ -78,12 +82,12 @@ class Slider extends Constraint { while (i < n) bones[indices[i++]].applied.modifyLocal(skeleton); - animation.apply(skeleton, p.time, p.time, data.loop, null, p.mix, data.additive ? MixBlend.add : MixBlend.replace, - MixDirection.mixIn, true); + animation.apply(skeleton, p.time, p.time, data.loop, null, p.mix, data.additive ? MixBlend.add : MixBlend.replace, MixDirection.mixIn, true); } - function sort (skeleton:Skeleton) { - if (bone != null && !data.local) skeleton.sortBone(bone); + function sort(skeleton:Skeleton) { + if (bone != null && !data.local) + skeleton.sortBone(bone); skeleton._updateCache.push(this); var bones = skeleton.bones; diff --git a/spine-haxe/spine-haxe/spine/SliderData.hx b/spine-haxe/spine-haxe/spine/SliderData.hx index cca4b7dce..5d3e5406c 100644 --- a/spine-haxe/spine-haxe/spine/SliderData.hx +++ b/spine-haxe/spine-haxe/spine/SliderData.hx @@ -1,5 +1,3 @@ - - /****************************************************************************** * Spine Runtimes License Agreement * Last updated April 5, 2025. Replaces all prior versions. @@ -27,16 +25,16 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ - package spine; +package spine; import spine.TransformConstraintData.FromProperty; import spine.animation.Animation; /** Stores the setup pose for a PhysicsConstraint. -* -* See Physics constraints in the Spine User Guide. */ + * + * See Physics constraints in the Spine User Guide. */ class SliderData extends ConstraintData { public var animation:Animation; public var additive = false; @@ -47,11 +45,11 @@ class SliderData extends ConstraintData { public var offset = 0.; public var local = false; - public function new (name:String) { + public function new(name:String) { super(name, new SliderPose()); } - public function create (skeleton:Skeleton) { + public function create(skeleton:Skeleton) { return new Slider(this, skeleton); } } diff --git a/spine-haxe/spine-haxe/spine/SliderPose.hx b/spine-haxe/spine-haxe/spine/SliderPose.hx index 1311823a4..210b8a569 100644 --- a/spine-haxe/spine-haxe/spine/SliderPose.hx +++ b/spine-haxe/spine-haxe/spine/SliderPose.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; @@ -34,11 +34,10 @@ class SliderPose implements Pose { public var time = 0.; public var mix = 0.; - public function new () { - } + public function new() {} - public function set (pose:SliderPose) { + public function set(pose:SliderPose) { time = pose.time; mix = pose.mix; } -} \ No newline at end of file +} diff --git a/spine-haxe/spine-haxe/spine/Slot.hx b/spine-haxe/spine-haxe/spine/Slot.hx index 38be3f925..bfe7c096e 100644 --- a/spine-haxe/spine-haxe/spine/Slot.hx +++ b/spine-haxe/spine-haxe/spine/Slot.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; @@ -36,17 +36,17 @@ import spine.attachments.VertexAttachment; * state for an attachment. State cannot be stored in an attachment itself because attachments are stateless and may be shared * across multiple skeletons. */ class Slot extends Posed { - public var skeleton:Skeleton; /** The bone this slot belongs to. */ public var bone:Bone; - public var attachmentState:Int ; + public var attachmentState:Int; public function new(data:SlotData, skeleton:Skeleton) { super(data, new SlotPose(), new SlotPose()); - if (skeleton == null) throw new SpineException("skeleton cannot be null."); + if (skeleton == null) + throw new SpineException("skeleton cannot be null."); this.skeleton = skeleton; bone = skeleton.bones[data.boneData.index]; if (data.setup.darkColor != null) { @@ -59,8 +59,10 @@ class Slot extends Posed { /** Copy method. */ public function copy(slot:Slot, bone:Bone, skeleton:Skeleton):Slot { var copy = new Slot(slot.data, skeleton); - if (bone == null) throw new SpineException("bone cannot be null."); - if (skeleton == null) throw new SpineException("skeleton cannot be null."); + if (bone == null) + throw new SpineException("bone cannot be null."); + if (skeleton == null) + throw new SpineException("skeleton cannot be null."); this.bone = bone; if (data.setup.darkColor != null) { pose.darkColor = new Color(1, 1, 1, 1); @@ -73,7 +75,8 @@ class Slot extends Posed { /** Sets this slot to the setup pose. */ override public function setupPose():Void { pose.color.setFromColor(data.setup.color); - if (pose.darkColor != null) pose.darkColor.setFromColor(data.setup.darkColor); + if (pose.darkColor != null) + pose.darkColor.setFromColor(data.setup.darkColor); pose.sequenceIndex = data.setup.sequenceIndex; if (data.attachmentName == null) { pose.attachment = null; diff --git a/spine-haxe/spine-haxe/spine/SlotData.hx b/spine-haxe/spine-haxe/spine/SlotData.hx index fab240ac8..2b5e701fc 100644 --- a/spine-haxe/spine-haxe/spine/SlotData.hx +++ b/spine-haxe/spine-haxe/spine/SlotData.hx @@ -25,13 +25,12 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; /** Stores the setup pose for a spine.Slot. */ class SlotData extends PosedData { - /** The index of the slot in spine.Skeleton.getSlots(). */ public final index:Int; @@ -45,13 +44,16 @@ class SlotData extends PosedData { public var blendMode:BlendMode = BlendMode.normal; // Nonessential. + /** False if the slot was hidden in Spine and nonessential data was exported. Does not affect runtime rendering. */ public var visible:Bool = true; public function new(index:Int, name:String, boneData:BoneData) { super(name, new SlotPose()); - if (index < 0) throw new SpineException("index must be >= 0."); - if (boneData == null) throw new SpineException("boneData cannot be null."); + if (index < 0) + throw new SpineException("index must be >= 0."); + if (boneData == null) + throw new SpineException("boneData cannot be null."); this.index = index; this.boneData = boneData; } diff --git a/spine-haxe/spine-haxe/spine/SlotPose.hx b/spine-haxe/spine-haxe/spine/SlotPose.hx index 86397df4b..59386e98c 100644 --- a/spine-haxe/spine-haxe/spine/SlotPose.hx +++ b/spine-haxe/spine-haxe/spine/SlotPose.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; @@ -33,49 +33,52 @@ import spine.attachments.Attachment; import spine.attachments.VertexAttachment; /** Stores a slot's pose. Slots organize attachments for {@link Skeleton#drawOrder} purposes and provide a place to store state -* for an attachment. State cannot be stored in an attachment itself because attachments are stateless and may be shared across -* multiple skeletons. */ + * for an attachment. State cannot be stored in an attachment itself because attachments are stateless and may be shared across + * multiple skeletons. */ class SlotPose implements Pose { - /** The color used to tint the slot's attachment. If SlotData.darkColor is set, this is used as the light color for two - * color tinting. */ + * color tinting. */ public final color:Color = new Color(1, 1, 1, 1); /** The dark color used to tint the slot's attachment for two color tinting, or null if two color tinting is not used. The dark - * color's alpha is not used. */ + * color's alpha is not used. */ public var darkColor:Color = null; public var attachment(default, set):Attachment; // Not used in setup pose. /** The index of the texture region to display when the slot's attachment has a spine.attachments.Sequence. -1 represents the - * Sequence.getSetupIndex(). */ + * Sequence.getSetupIndex(). */ public var sequenceIndex = -1; /** Values to deform the slot's attachment. For an unweighted mesh, the entries are local positions for each vertex. For a - * weighted mesh, the entries are an offset for each vertex which will be added to the mesh's local vertex positions. - * @see spine.attachments.VertexAttachment.computeWorldVertices() - * @see spine.animation.DeformTimeline */ + * weighted mesh, the entries are an offset for each vertex which will be added to the mesh's local vertex positions. + * @see spine.attachments.VertexAttachment.computeWorldVertices() + * @see spine.animation.DeformTimeline */ public var deform:Array = new Array(); - public function new () { - } + public function new() {} - public function set (pose:SlotPose):Void { - if (pose == null) throw new SpineException("pose cannot be null."); + public function set(pose:SlotPose):Void { + if (pose == null) + throw new SpineException("pose cannot be null."); color.setFromColor(pose.color); - if (darkColor != null) darkColor.setFromColor(pose.darkColor); + if (darkColor != null) + darkColor.setFromColor(pose.darkColor); attachment = pose.attachment; sequenceIndex = pose.sequenceIndex; deform.resize(0); - for (e in pose.deform) deform.push(e); + for (e in pose.deform) + deform.push(e); } /** Sets the slot's attachment and, if the attachment changed, resets sequenceIndex and clears the deform. - * The deform is not cleared if the old attachment has the same spine.attachments.VertexAttachment.timelineAttachment as the - * specified attachment. */ + * The deform is not cleared if the old attachment has the same spine.attachments.VertexAttachment.timelineAttachment as the + * specified attachment. */ public function set_attachment(attachmentNew:Attachment):Attachment { - if (attachment == attachmentNew) return attachment; - if (!Std.isOfType(attachmentNew, VertexAttachment) || !Std.isOfType(attachment, VertexAttachment) + if (attachment == attachmentNew) + return attachment; + if (!Std.isOfType(attachmentNew, VertexAttachment) + || !Std.isOfType(attachment, VertexAttachment) || cast(attachmentNew, VertexAttachment).timelineAttachment != cast(attachment, VertexAttachment).timelineAttachment) { deform = new Array(); } @@ -83,5 +86,4 @@ class SlotPose implements Pose { sequenceIndex = -1; return attachment; } - -} \ No newline at end of file +} diff --git a/spine-haxe/spine-haxe/spine/SpacingMode.hx b/spine-haxe/spine-haxe/spine/SpacingMode.hx index 0a0d6df02..58d892d4b 100644 --- a/spine-haxe/spine-haxe/spine/SpacingMode.hx +++ b/spine-haxe/spine-haxe/spine/SpacingMode.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; diff --git a/spine-haxe/spine-haxe/spine/SpineException.hx b/spine-haxe/spine-haxe/spine/SpineException.hx index 1e4cacb92..d8db3e641 100644 --- a/spine-haxe/spine-haxe/spine/SpineException.hx +++ b/spine-haxe/spine-haxe/spine/SpineException.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; diff --git a/spine-haxe/spine-haxe/spine/TextureRegion.hx b/spine-haxe/spine-haxe/spine/TextureRegion.hx index c5e377717..2a33e51d4 100644 --- a/spine-haxe/spine-haxe/spine/TextureRegion.hx +++ b/spine-haxe/spine-haxe/spine/TextureRegion.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; diff --git a/spine-haxe/spine-haxe/spine/TransformConstraint.hx b/spine-haxe/spine-haxe/spine/TransformConstraint.hx index 3737c90ca..093e972fc 100644 --- a/spine-haxe/spine-haxe/spine/TransformConstraint.hx +++ b/spine-haxe/spine-haxe/spine/TransformConstraint.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; @@ -34,7 +34,6 @@ package spine; * * @see https://esotericsoftware.com/spine-transform-constraints Transform constraints in the Spine User Guide */ class TransformConstraint extends Constraint { - /** The bones that will be modified by this transform constraint. */ public final bones:Array; @@ -43,7 +42,8 @@ class TransformConstraint extends Constraint(); for (boneData in data.bones) @@ -60,12 +60,17 @@ class TransformConstraint extends Constraint(); /** Reads this property from the specified bone. */ - abstract public function value (skeleton:Skeleton, source:BonePose, local:Bool, offsets:Array):Float; + abstract public function value(skeleton:Skeleton, source:BonePose, local:Bool, offsets:Array):Float; } /** Constrained property for a TransformConstraint. */ abstract class ToProperty { - public function new () { - } + public function new() {} /** The value of this property that corresponds to FromProperty.offset. */ public var offset:Float; @@ -187,36 +191,43 @@ abstract class ToProperty { public var scale:Float; /** Reads the mix for this property from the specified pose. */ - abstract public function mix (pose:TransformConstraintPose):Float; + abstract public function mix(pose:TransformConstraintPose):Float; /** Applies the value to this property. */ - abstract public function apply (skeleton:Skeleton, pose:TransformConstraintPose, bone:BonePose, value:Float, local:Bool, additive:Bool):Void; + abstract public function apply(skeleton:Skeleton, pose:TransformConstraintPose, bone:BonePose, value:Float, local:Bool, additive:Bool):Void; } class FromRotate extends FromProperty { - public function value (skeleton:Skeleton, source:BonePose, local:Bool, offsets:Array):Float { - if (local) return source.rotation + offsets[TransformConstraintData.ROTATION]; + public function value(skeleton:Skeleton, source:BonePose, local:Bool, offsets:Array):Float { + if (local) + return source.rotation + offsets[TransformConstraintData.ROTATION]; var sx = skeleton.scaleX, sy = skeleton.scaleY; var value = Math.atan2(source.c / sy, source.a / sx) * MathUtils.radDeg - + ((source.a * source.d - source.b * source.c) * sx * sy > 0 ? offsets[TransformConstraintData.ROTATION] : -offsets[TransformConstraintData.ROTATION]); - if (value < 0) value += 360; + + ((source.a * source.d - source.b * source.c) * sx * sy > 0 ? offsets[TransformConstraintData.ROTATION] : + -offsets[TransformConstraintData.ROTATION]); + if (value < 0) + value += 360; return value; } } class ToRotate extends ToProperty { - public function mix (pose:TransformConstraintPose):Float { + public function mix(pose:TransformConstraintPose):Float { return pose.mixRotate; } - public function apply (skeleton:Skeleton, pose:TransformConstraintPose, bone:BonePose, value:Float, local:Bool, additive:Bool):Void { + public function apply(skeleton:Skeleton, pose:TransformConstraintPose, bone:BonePose, value:Float, local:Bool, additive:Bool):Void { if (local) bone.rotation += (additive ? value : value - bone.rotation) * pose.mixRotate; else { var sx = skeleton.scaleX, sy = skeleton.scaleY, ix = 1 / sx, iy = 1 / sy; - var a = bone.a * ix, b = bone.b * ix, c = bone.c * iy, d = bone.d * iy; + var a = bone.a * ix, + b = bone.b * ix, + c = bone.c * iy, + d = bone.d * iy; value *= MathUtils.degRad; - if (!additive) value -= Math.atan2(c, a); + if (!additive) + value -= Math.atan2(c, a); if (value > MathUtils.PI) value -= MathUtils.PI2; else if (value < -MathUtils.PI) // @@ -232,65 +243,66 @@ class ToRotate extends ToProperty { } class FromX extends FromProperty { - public function value (skeleton:Skeleton, source:BonePose, local:Bool, offsets:Array):Float { - return local - ? source.x + offsets[TransformConstraintData.X] - : (offsets[TransformConstraintData.X] * source.a + offsets[TransformConstraintData.Y] * source.b + source.worldX) / skeleton.scaleX; + public function value(skeleton:Skeleton, source:BonePose, local:Bool, offsets:Array):Float { + return local ? source.x + offsets[TransformConstraintData.X] : (offsets[TransformConstraintData.X] * source.a + + offsets[TransformConstraintData.Y] * source.b + source.worldX) / skeleton.scaleX; } } class ToX extends ToProperty { - public function mix (pose:TransformConstraintPose):Float { + public function mix(pose:TransformConstraintPose):Float { return pose.mixX; } - public function apply (skeleton:Skeleton, pose:TransformConstraintPose, bone:BonePose, value:Float, local:Bool, additive:Bool):Void { + public function apply(skeleton:Skeleton, pose:TransformConstraintPose, bone:BonePose, value:Float, local:Bool, additive:Bool):Void { if (local) bone.x += (additive ? value : value - bone.x) * pose.mixX; else { - if (!additive) value -= bone.worldX / skeleton.scaleX; + if (!additive) + value -= bone.worldX / skeleton.scaleX; bone.worldX += value * pose.mixX * skeleton.scaleX; } } } class FromY extends FromProperty { - public function value (skeleton:Skeleton, source:BonePose, local:Bool, offsets:Array):Float { - return local - ? source.y + offsets[TransformConstraintData.Y] - : (offsets[TransformConstraintData.X] * source.c + offsets[TransformConstraintData.Y] * source.d + source.worldY) / skeleton.scaleY; + public function value(skeleton:Skeleton, source:BonePose, local:Bool, offsets:Array):Float { + return local ? source.y + offsets[TransformConstraintData.Y] : (offsets[TransformConstraintData.X] * source.c + + offsets[TransformConstraintData.Y] * source.d + source.worldY) / skeleton.scaleY; } } class ToY extends ToProperty { - public function mix (pose:TransformConstraintPose):Float { + public function mix(pose:TransformConstraintPose):Float { return pose.mixY; } - public function apply (skeleton:Skeleton, pose:TransformConstraintPose, bone:BonePose, value:Float, local:Bool, additive:Bool):Void { + public function apply(skeleton:Skeleton, pose:TransformConstraintPose, bone:BonePose, value:Float, local:Bool, additive:Bool):Void { if (local) bone.y += (additive ? value : value - bone.y) * pose.mixY; else { - if (!additive) value -= bone.worldY / skeleton.scaleY; + if (!additive) + value -= bone.worldY / skeleton.scaleY; bone.worldY += value * pose.mixY * skeleton.scaleY; } } } class FromScaleX extends FromProperty { - public function value (skeleton:Skeleton, source:BonePose, local:Bool, offsets:Array):Float { - if (local) return source.scaleX + offsets[TransformConstraintData.SCALEX]; + public function value(skeleton:Skeleton, source:BonePose, local:Bool, offsets:Array):Float { + if (local) + return source.scaleX + offsets[TransformConstraintData.SCALEX]; var a = source.a / skeleton.scaleX, c = source.c / skeleton.scaleY; return Math.sqrt(a * a + c * c) + offsets[TransformConstraintData.SCALEX]; } } class ToScaleX extends ToProperty { - public function mix (pose:TransformConstraintPose):Float { + public function mix(pose:TransformConstraintPose):Float { return pose.mixScaleX; } - public function apply (skeleton:Skeleton, pose:TransformConstraintPose, bone:BonePose, value:Float, local:Bool, additive:Bool):Void { + public function apply(skeleton:Skeleton, pose:TransformConstraintPose, bone:BonePose, value:Float, local:Bool, additive:Bool):Void { if (local) { if (additive) bone.scaleX *= 1 + (value - 1) * pose.mixScaleX; @@ -301,7 +313,9 @@ class ToScaleX extends ToProperty { bone.a *= s; bone.c *= s; } else { - var a = bone.a / skeleton.scaleX, c = bone.c / skeleton.scaleY, s = Math.sqrt(a * a + c * c); + var a = bone.a / skeleton.scaleX, + c = bone.c / skeleton.scaleY, + s = Math.sqrt(a * a + c * c); if (s != 0) { s = 1 + (value - s) * pose.mixScaleX / s; bone.a *= s; @@ -312,19 +326,20 @@ class ToScaleX extends ToProperty { } class FromScaleY extends FromProperty { - public function value (skeleton:Skeleton, source:BonePose, local:Bool, offsets:Array):Float { - if (local) return source.scaleY + offsets[TransformConstraintData.SCALEY]; + public function value(skeleton:Skeleton, source:BonePose, local:Bool, offsets:Array):Float { + if (local) + return source.scaleY + offsets[TransformConstraintData.SCALEY]; var b = source.b / skeleton.scaleX, d = source.d / skeleton.scaleY; return Math.sqrt(b * b + d * d) + offsets[TransformConstraintData.SCALEY]; } } class ToScaleY extends ToProperty { - public function mix (pose:TransformConstraintPose):Float { + public function mix(pose:TransformConstraintPose):Float { return pose.mixScaleY; } - public function apply (skeleton:Skeleton, pose:TransformConstraintPose, bone:BonePose, value:Float, local:Bool, additive:Bool):Void { + public function apply(skeleton:Skeleton, pose:TransformConstraintPose, bone:BonePose, value:Float, local:Bool, additive:Bool):Void { if (local) { if (additive) bone.scaleY *= 1 + (value - 1) * pose.mixScaleY; @@ -335,7 +350,9 @@ class ToScaleY extends ToProperty { bone.b *= s; bone.d *= s; } else { - var b = bone.b / skeleton.scaleX, d = bone.d / skeleton.scaleY, s = Math.sqrt(b * b + d * d); + var b = bone.b / skeleton.scaleX, + d = bone.d / skeleton.scaleY, + s = Math.sqrt(b * b + d * d); if (s != 0) { s = 1 + (value - s) * pose.mixScaleY / s; bone.b *= s; @@ -346,25 +363,33 @@ class ToScaleY extends ToProperty { } class FromShearY extends FromProperty { - public function value (skeleton:Skeleton, source:BonePose, local:Bool, offsets:Array):Float { - if (local) return source.shearY + offsets[TransformConstraintData.SHEARY]; + public function value(skeleton:Skeleton, source:BonePose, local:Bool, offsets:Array):Float { + if (local) + return source.shearY + offsets[TransformConstraintData.SHEARY]; var sx = 1 / skeleton.scaleX, sy = 1 / skeleton.scaleY; - return (Math.atan2(source.d * sy, source.b * sx) - Math.atan2(source.c * sy, source.a * sx)) - * MathUtils.radDeg - 90 + offsets[TransformConstraintData.SHEARY]; + return (Math.atan2(source.d * sy, source.b * sx) + - Math.atan2(source.c * sy, source.a * sx)) * MathUtils.radDeg + - 90 + + offsets[TransformConstraintData.SHEARY]; } } class ToShearY extends ToProperty { - public function mix (pose:TransformConstraintPose):Float { + public function mix(pose:TransformConstraintPose):Float { return pose.mixShearY; } - public function apply (skeleton:Skeleton, pose:TransformConstraintPose, bone:BonePose, value:Float, local:Bool, additive:Bool):Void { + public function apply(skeleton:Skeleton, pose:TransformConstraintPose, bone:BonePose, value:Float, local:Bool, additive:Bool):Void { if (local) { - if (!additive) value -= bone.shearY; + if (!additive) + value -= bone.shearY; bone.shearY += value * pose.mixShearY; } else { - var sx = skeleton.scaleX, sy = skeleton.scaleY, b = bone.b / sx, d = bone.d / sy, by = Math.atan2(d, b); + var sx = skeleton.scaleX, + sy = skeleton.scaleY, + b = bone.b / sx, + d = bone.d / sy, + by = Math.atan2(d, b); value = (value + 90) * MathUtils.degRad; if (additive) value -= MathUtils.PI / 2; diff --git a/spine-haxe/spine-haxe/spine/TransformConstraintPose.hx b/spine-haxe/spine-haxe/spine/TransformConstraintPose.hx index ad56a544e..cae246fc2 100644 --- a/spine-haxe/spine-haxe/spine/TransformConstraintPose.hx +++ b/spine-haxe/spine-haxe/spine/TransformConstraintPose.hx @@ -25,35 +25,33 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; /** Stores a pose for a transform constraint. */ class TransformConstraintPose implements Pose { - /** A percentage (0-1) that controls the mix between the constrained and unconstrained rotation. */ public var mixRotate = 0.; + /** A percentage (0-1) that controls the mix between the constrained and unconstrained translation X. */ - public var mixX = 0.; + /** A percentage (0-1) that controls the mix between the constrained and unconstrained translation Y. */ - public var mixY = 0.; + /** A percentage (0-1) that controls the mix between the constrained and unconstrained scale X. */ - public var mixScaleX = 0.; + /** A percentage (0-1) that controls the mix between the constrained and unconstrained scale Y. */ - public var mixScaleY = 0.; - /** A percentage (0-1) that controls the mix between the constrained and unconstrained shear Y. */ + /** A percentage (0-1) that controls the mix between the constrained and unconstrained shear Y. */ public var mixShearY = 0.; - public function new () { - } + public function new() {} - public function set (pose:TransformConstraintPose) { + public function set(pose:TransformConstraintPose) { mixRotate = pose.mixRotate; mixX = pose.mixX; mixY = pose.mixY; @@ -61,5 +59,4 @@ class TransformConstraintPose implements Pose { mixScaleY = pose.mixScaleY; mixShearY = pose.mixShearY; } - -} \ No newline at end of file +} diff --git a/spine-haxe/spine-haxe/spine/Triangulator.hx b/spine-haxe/spine-haxe/spine/Triangulator.hx index 5e31f4e75..011655f73 100644 --- a/spine-haxe/spine-haxe/spine/Triangulator.hx +++ b/spine-haxe/spine-haxe/spine/Triangulator.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; diff --git a/spine-haxe/spine-haxe/spine/Update.hx b/spine-haxe/spine-haxe/spine/Update.hx index adf2a3c38..3d2479891 100644 --- a/spine-haxe/spine-haxe/spine/Update.hx +++ b/spine-haxe/spine-haxe/spine/Update.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; diff --git a/spine-haxe/spine-haxe/spine/Vertex.hx b/spine-haxe/spine-haxe/spine/Vertex.hx index de2eb1e9d..c5986ef85 100644 --- a/spine-haxe/spine-haxe/spine/Vertex.hx +++ b/spine-haxe/spine-haxe/spine/Vertex.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine; diff --git a/spine-haxe/spine-haxe/spine/animation/AlphaTimeline.hx b/spine-haxe/spine-haxe/spine/animation/AlphaTimeline.hx index 31593ee48..f1dac1675 100644 --- a/spine-haxe/spine-haxe/spine/animation/AlphaTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/AlphaTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -55,11 +55,11 @@ class AlphaTimeline extends CurveTimeline1 implements SlotTimeline { return slotIndex; } - public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, - blend:MixBlend, direction:MixDirection, appliedPose:Bool) { - + public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, blend:MixBlend, direction:MixDirection, + appliedPose:Bool) { var slot = skeleton.slots[slotIndex]; - if (!slot.bone.active) return; + if (!slot.bone.active) + return; var color = (appliedPose ? slot.applied : slot.pose).color; if (time < frames[0]) { diff --git a/spine-haxe/spine-haxe/spine/animation/Animation.hx b/spine-haxe/spine-haxe/spine/animation/Animation.hx index 55645e04b..36a95769e 100644 --- a/spine-haxe/spine-haxe/spine/animation/Animation.hx +++ b/spine-haxe/spine-haxe/spine/animation/Animation.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -36,12 +36,11 @@ import spine.Skeleton; /** Stores a list of timelines to animate a skeleton's pose over time. */ class Animation { - /** The animation's name, which is unique across all animations in the skeleton. */ public final name:String; /** The duration of the animation in seconds, which is usually the highest time of all frames in the timeline. The duration is - * used to know when it has completed and when it should loop back to the start. */ + * used to know when it has completed and when it should loop back to the start. */ public var duration:Float = 0; public var timelines:Array; @@ -49,7 +48,8 @@ class Animation { public final bones:Array; public function new(name:String, timelines:Array, duration:Float) { - if (name == null) throw new SpineException("name cannot be null."); + if (name == null) + throw new SpineException("name cannot be null."); this.name = name; this.duration = duration; var n = timelines.length << 1; @@ -59,7 +59,8 @@ class Animation { } public function setTimelines(timelines:Array) { - if (timelines == null) throw new SpineException("timelines cannot be null."); + if (timelines == null) + throw new SpineException("timelines cannot be null."); this.timelines = timelines; timelineIds.clear(); @@ -67,7 +68,8 @@ class Animation { var boneSet = new IntMap(); for (timeline in timelines) { var ids:Array = timeline.propertyIds; - for (id in ids) timelineIds.set(id, true); + for (id in ids) + timelineIds.set(id, true); if (Std.isOfType(timeline, BoneTimeline)) { var boneTimeline = cast(timeline, BoneTimeline); var boneIndex = boneTimeline.getBoneIndex(); @@ -108,13 +110,15 @@ class Animation { * @param blend Controls how mixing is applied when alpha < 1. * @param direction Indicates whether the timelines are mixing in or out. Used by timelines which perform instant transitions, * such as DrawOrderTimeline or AttachmentTimeline. */ - public function apply(skeleton:Skeleton, lastTime:Float, time:Float, loop:Bool, events:Array, alpha:Float, blend:MixBlend, - direction:MixDirection, appliedPose:Bool):Void { - if (skeleton == null) throw new SpineException("skeleton cannot be null."); + public function apply(skeleton:Skeleton, lastTime:Float, time:Float, loop:Bool, events:Array, alpha:Float, blend:MixBlend, direction:MixDirection, + appliedPose:Bool):Void { + if (skeleton == null) + throw new SpineException("skeleton cannot be null."); if (loop && duration != 0) { time %= duration; - if (lastTime > 0) lastTime %= duration; + if (lastTime > 0) + lastTime %= duration; } for (timeline in timelines) { diff --git a/spine-haxe/spine-haxe/spine/animation/AnimationState.hx b/spine-haxe/spine-haxe/spine/animation/AnimationState.hx index b331ab1d6..bc12cdb6b 100644 --- a/spine-haxe/spine-haxe/spine/animation/AnimationState.hx +++ b/spine-haxe/spine-haxe/spine/animation/AnimationState.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -47,12 +47,14 @@ class AnimationState { * Result: Mix from the current pose to the timeline pose. */ public static inline var SUBSEQUENT:Int = 0; + /** * 1) This is the first timeline to set this property. * 2) The next track entry applied after this one does not have a timeline to set this property. * Result: Mix from the setup pose to the timeline pose. */ public static inline var FIRST:Int = 1; + /** * 1) A previously applied timeline has set this property. * 2) The next track entry to be applied does have a timeline to set this property. @@ -61,6 +63,7 @@ class AnimationState { * animations that key the same property. A subsequent timeline will set this property using a mix. */ public static inline var HOLD_SUBSEQUENT:Int = 2; + /** * 1) This is the first timeline to set this property. * 2) The next track entry to be applied does have a timeline to set this property. @@ -69,6 +72,7 @@ class AnimationState { * that key the same property. A subsequent timeline will set this property using a mix. */ public static inline var HOLD_FIRST:Int = 3; + /** * 1) This is the first timeline to set this property. * 2) The next track entry to be applied does have a timeline to set this property. @@ -82,6 +86,7 @@ class AnimationState { * out position. */ public static inline var HOLD_MIX:Int = 4; + public static inline var SETUP:Int = 1; public static inline var CURRENT:Int = 2; @@ -203,7 +208,8 @@ class AnimationState { // Mixing is complete for all entries before the from entry or the mix is instantaneous. if (from.totalAlpha == 0 || to.mixDuration == 0) { to.mixingFrom = from.mixingFrom; - if (from.mixingFrom != null) from.mixingFrom.mixingTo = to; + if (from.mixingFrom != null) + from.mixingFrom.mixingTo = to; to.interruptAlpha = from.interruptAlpha; queue.end(from); } @@ -256,7 +262,8 @@ class AnimationState { var timelineCount:Int = timelines.length; var timeline:Timeline; if ((i == 0 && alpha == 1) || blend == MixBlend.add) { - if (i == 0) attachments = true; + if (i == 0) + attachments = true; for (timeline in timelines) { if (Std.isOfType(timeline, AttachmentTimeline)) { applyAttachmentTimeline(cast(timeline, AttachmentTimeline), skeleton, applyTime, blend, attachments); @@ -276,8 +283,8 @@ class AnimationState { var timeline:Timeline = timelines[ii]; var timelineBlend:MixBlend = timelineMode[ii] == SUBSEQUENT ? blend : MixBlend.setup; if (!shortestRotation && Std.isOfType(timeline, RotateTimeline)) { - this.applyRotateTimeline(cast(timeline, RotateTimeline), skeleton, applyTime, alpha, timelineBlend, current.timelinesRotation, ii << 1, - firstFrame); + this.applyRotateTimeline(cast(timeline, RotateTimeline), skeleton, applyTime, alpha, timelineBlend, current.timelinesRotation, + ii << 1, firstFrame); } else if (Std.isOfType(timeline, AttachmentTimeline)) { this.applyAttachmentTimeline(cast(timeline, AttachmentTimeline), skeleton, applyTime, blend, attachments); } else { @@ -387,7 +394,8 @@ class AnimationState { if (!shortestRotation && Std.isOfType(timeline, RotateTimeline)) { applyRotateTimeline(cast(timeline, RotateTimeline), skeleton, applyTime, alpha, timelineBlend, from.timelinesRotation, i << 1, firstFrame); } else if (Std.isOfType(timeline, AttachmentTimeline)) { - applyAttachmentTimeline(cast(timeline, AttachmentTimeline), skeleton, applyTime, timelineBlend, attachments && alpha >= from.alphaAttachmentThreshold); + applyAttachmentTimeline(cast(timeline, AttachmentTimeline), skeleton, applyTime, + timelineBlend, attachments && alpha >= from.alphaAttachmentThreshold); } else { if (drawOrder && Std.isOfType(timeline, DrawOrderTimeline) && timelineBlend == MixBlend.setup) direction = MixDirection.mixIn; @@ -534,7 +542,8 @@ class AnimationState { } } else complete = animationTime >= animationEnd && entry.animationLast < animationEnd; - if (complete) queue.complete(entry); + if (complete) + queue.complete(entry); // Queue events after complete. while (i < n) { @@ -699,11 +708,13 @@ class AnimationState { if (last == null) { setCurrent(trackIndex, entry, true); queue.drain(); - if (delay < 0) delay = 0; + if (delay < 0) + delay = 0; } else { last.next = entry; entry.previous = last; - if (delay <= 0) delay = Math.max(delay + last.getTrackComplete() - entry.mixDuration, 0); + if (delay <= 0) + delay = Math.max(delay + last.getTrackComplete() - entry.mixDuration, 0); } entry.delay = delay; @@ -753,7 +764,8 @@ class AnimationState { */ public function addEmptyAnimation(trackIndex:Int, mixDuration:Float, delay:Float):TrackEntry { var entry:TrackEntry = addAnimation(trackIndex, emptyAnimation, false, delay); - if (delay <= 0) entry.delay = Math.max(entry.delay + entry.mixDuration - mixDuration, 0); + if (delay <= 0) + entry.delay = Math.max(entry.delay + entry.mixDuration - mixDuration, 0); entry.mixDuration = mixDuration; entry.trackEnd = mixDuration; return entry; diff --git a/spine-haxe/spine-haxe/spine/animation/AnimationStateData.hx b/spine-haxe/spine-haxe/spine/animation/AnimationStateData.hx index 72934e7dc..76cbdfa50 100644 --- a/spine-haxe/spine-haxe/spine/animation/AnimationStateData.hx +++ b/spine-haxe/spine-haxe/spine/animation/AnimationStateData.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; diff --git a/spine-haxe/spine-haxe/spine/animation/AttachmentTimeline.hx b/spine-haxe/spine-haxe/spine/animation/AttachmentTimeline.hx index 3e726a3d0..75813b36e 100644 --- a/spine-haxe/spine-haxe/spine/animation/AttachmentTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/AttachmentTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -63,17 +63,19 @@ class AttachmentTimeline extends Timeline implements SlotTimeline { attachmentNames[frame] = attachmentName; } - public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, - blend:MixBlend, direction:MixDirection, appliedPose:Bool) { - + public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, blend:MixBlend, direction:MixDirection, + appliedPose:Bool) { var slot = skeleton.slots[slotIndex]; - if (!slot.bone.active) return; + if (!slot.bone.active) + return; var pose = appliedPose ? slot.applied : slot.pose; if (direction == MixDirection.mixOut) { - if (blend == MixBlend.setup) setAttachment(skeleton, pose, slot.data.attachmentName); + if (blend == MixBlend.setup) + setAttachment(skeleton, pose, slot.data.attachmentName); } else if (time < frames[0]) { - if (blend == MixBlend.setup || blend == MixBlend.first) setAttachment(skeleton, pose, slot.data.attachmentName); + if (blend == MixBlend.setup || blend == MixBlend.first) + setAttachment(skeleton, pose, slot.data.attachmentName); } else setAttachment(skeleton, pose, attachmentNames[Timeline.search1(frames, time)]); } diff --git a/spine-haxe/spine-haxe/spine/animation/BoneTimeline.hx b/spine-haxe/spine-haxe/spine/animation/BoneTimeline.hx index 4fe099978..4ff1ae9fb 100644 --- a/spine-haxe/spine-haxe/spine/animation/BoneTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/BoneTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; diff --git a/spine-haxe/spine-haxe/spine/animation/BoneTimeline1.hx b/spine-haxe/spine-haxe/spine/animation/BoneTimeline1.hx index fdb52bf33..e4a7841c0 100644 --- a/spine-haxe/spine-haxe/spine/animation/BoneTimeline1.hx +++ b/spine-haxe/spine-haxe/spine/animation/BoneTimeline1.hx @@ -25,11 +25,11 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ - package spine.animation; +package spine.animation; - abstract class BoneTimeline1 extends CurveTimeline1 implements BoneTimeline { +abstract class BoneTimeline1 extends CurveTimeline1 implements BoneTimeline { public final boneIndex:Int; public function new(frameCount:Int, bezierCount:Int, boneIndex:Int, property:Property) { @@ -37,16 +37,16 @@ this.boneIndex = boneIndex; } - public function getBoneIndex () { + public function getBoneIndex() { return boneIndex; } - public function apply (skeleton: Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, blend:MixBlend, - direction:MixDirection, appliedPose:Bool) { - + public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, blend:MixBlend, direction:MixDirection, + appliedPose:Bool) { var bone = skeleton.bones[boneIndex]; - if (bone.active) apply1(appliedPose ? bone.applied : bone.pose, bone.data.setup, time, alpha, blend, direction); + if (bone.active) + apply1(appliedPose ? bone.applied : bone.pose, bone.data.setup, time, alpha, blend, direction); } - abstract function apply1 (pose:BoneLocal, setup:BoneLocal, time:Float, alpha:Float, blend:MixBlend, direction:MixDirection):Void; + abstract function apply1(pose:BoneLocal, setup:BoneLocal, time:Float, alpha:Float, blend:MixBlend, direction:MixDirection):Void; } diff --git a/spine-haxe/spine-haxe/spine/animation/BoneTimeline2.hx b/spine-haxe/spine-haxe/spine/animation/BoneTimeline2.hx index 62450d0ef..87bb4e89a 100644 --- a/spine-haxe/spine-haxe/spine/animation/BoneTimeline2.hx +++ b/spine-haxe/spine-haxe/spine/animation/BoneTimeline2.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -57,16 +57,16 @@ abstract class BoneTimeline2 extends CurveTimeline implements BoneTimeline { frames[frame + VALUE2] = value2; } - public function getBoneIndex () { + public function getBoneIndex() { return boneIndex; } - public function apply (skeleton: Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, blend:MixBlend, - direction:MixDirection, appliedPose:Bool) { - + public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, blend:MixBlend, direction:MixDirection, + appliedPose:Bool) { var bone = skeleton.bones[boneIndex]; - if (bone.active) apply1(appliedPose ? bone.applied : bone.pose, bone.data.setup, time, alpha, blend, direction); + if (bone.active) + apply1(appliedPose ? bone.applied : bone.pose, bone.data.setup, time, alpha, blend, direction); } - abstract function apply1 (pose:BoneLocal, setup:BoneLocal, time:Float, alpha:Float, blend:MixBlend, direction:MixDirection):Void; + abstract function apply1(pose:BoneLocal, setup:BoneLocal, time:Float, alpha:Float, blend:MixBlend, direction:MixDirection):Void; } diff --git a/spine-haxe/spine-haxe/spine/animation/ConstraintTimeline.hx b/spine-haxe/spine-haxe/spine/animation/ConstraintTimeline.hx index 4b5882c89..751e243d2 100644 --- a/spine-haxe/spine-haxe/spine/animation/ConstraintTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/ConstraintTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; diff --git a/spine-haxe/spine-haxe/spine/animation/ConstraintTimeline1.hx b/spine-haxe/spine-haxe/spine/animation/ConstraintTimeline1.hx index bebb46cd7..a05be5d3b 100644 --- a/spine-haxe/spine-haxe/spine/animation/ConstraintTimeline1.hx +++ b/spine-haxe/spine-haxe/spine/animation/ConstraintTimeline1.hx @@ -25,19 +25,19 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; abstract class ConstraintTimeline1 extends CurveTimeline1 implements ConstraintTimeline { public final constraintIndex:Int; - public function new (frameCount:Int, bezierCount:Int, constraintIndex:Int, property:Property) { + public function new(frameCount:Int, bezierCount:Int, constraintIndex:Int, property:Property) { super(frameCount, bezierCount, property + "|" + constraintIndex); this.constraintIndex = constraintIndex; } - public function getConstraintIndex () { + public function getConstraintIndex() { return constraintIndex; } } diff --git a/spine-haxe/spine-haxe/spine/animation/CurveTimeline.hx b/spine-haxe/spine-haxe/spine/animation/CurveTimeline.hx index 88631937d..22290949e 100644 --- a/spine-haxe/spine-haxe/spine/animation/CurveTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/CurveTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; diff --git a/spine-haxe/spine-haxe/spine/animation/CurveTimeline1.hx b/spine-haxe/spine-haxe/spine/animation/CurveTimeline1.hx index deea375f0..c6c06c784 100644 --- a/spine-haxe/spine-haxe/spine/animation/CurveTimeline1.hx +++ b/spine-haxe/spine-haxe/spine/animation/CurveTimeline1.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -78,64 +78,86 @@ abstract class CurveTimeline1 extends CurveTimeline { } } - public function getRelativeValue (time:Float, alpha:Float, blend: MixBlend, current:Float, setup:Float):Float { + public function getRelativeValue(time:Float, alpha:Float, blend:MixBlend, current:Float, setup:Float):Float { if (time < frames[0]) { switch (blend) { - case MixBlend.setup: return setup; - case MixBlend.first: return current + (setup - current) * alpha; - default: return current; + case MixBlend.setup: + return setup; + case MixBlend.first: + return current + (setup - current) * alpha; + default: + return current; } } var value:Float = getCurveValue(time); switch (blend) { - case MixBlend.setup: return setup + value * alpha; - case MixBlend.first, MixBlend.replace: return current + (value + setup - current) * alpha; - default: return current + value * alpha; // MixBlend.add + case MixBlend.setup: + return setup + value * alpha; + case MixBlend.first, MixBlend.replace: + return current + (value + setup - current) * alpha; + default: + return current + value * alpha; // MixBlend.add } } - public function getAbsoluteValue (time:Float, alpha:Float, blend: MixBlend, current:Float, setup:Float):Float { + public function getAbsoluteValue(time:Float, alpha:Float, blend:MixBlend, current:Float, setup:Float):Float { if (time < frames[0]) { switch (blend) { - case MixBlend.setup: return setup; - case MixBlend.first: return current + (setup - current) * alpha; - default: return current; + case MixBlend.setup: + return setup; + case MixBlend.first: + return current + (setup - current) * alpha; + default: + return current; } } var value:Float = getCurveValue(time); switch (blend) { - case MixBlend.setup: return setup + (value - setup) * alpha; - case MixBlend.first, MixBlend.replace: return current + (value - current) * alpha; - default: return current + value * alpha; // MixBlend.add + case MixBlend.setup: + return setup + (value - setup) * alpha; + case MixBlend.first, MixBlend.replace: + return current + (value - current) * alpha; + default: + return current + value * alpha; // MixBlend.add } } - public function getAbsoluteValue2 (time:Float, alpha:Float, blend: MixBlend, current:Float, setup:Float, value:Float):Float { + public function getAbsoluteValue2(time:Float, alpha:Float, blend:MixBlend, current:Float, setup:Float, value:Float):Float { if (time < frames[0]) { switch (blend) { - case MixBlend.setup: return setup; - case MixBlend.first: return current + (setup - current) * alpha; - default: current; + case MixBlend.setup: + return setup; + case MixBlend.first: + return current + (setup - current) * alpha; + default: + current; } } switch (blend) { - case MixBlend.setup: return setup + (value - setup) * alpha; - case MixBlend.first, MixBlend.replace: return current + (value - current) * alpha; - default: return current + value * alpha; // MixBlend.add + case MixBlend.setup: + return setup + (value - setup) * alpha; + case MixBlend.first, MixBlend.replace: + return current + (value - current) * alpha; + default: + return current + value * alpha; // MixBlend.add } } - public function getScaleValue (time:Float, alpha:Float, blend: MixBlend, direction: MixDirection, current:Float, setup:Float):Float { + public function getScaleValue(time:Float, alpha:Float, blend:MixBlend, direction:MixDirection, current:Float, setup:Float):Float { var frames:Array = frames; if (time < frames[0]) { switch (blend) { - case MixBlend.setup: return setup; - case MixBlend.first: return current + (setup - current) * alpha; - default: return current; + case MixBlend.setup: + return setup; + case MixBlend.first: + return current + (setup - current) * alpha; + default: + return current; } } var value:Float = getCurveValue(time) * setup; - if (alpha == 1) return blend == MixBlend.add ? current + value - setup : value; + if (alpha == 1) + return blend == MixBlend.add ? current + value - setup : value; // Mixing out uses sign of setup or current pose, else use sign of key. if (direction == MixDirection.mixOut) { switch (blend) { diff --git a/spine-haxe/spine-haxe/spine/animation/DeformTimeline.hx b/spine-haxe/spine-haxe/spine/animation/DeformTimeline.hx index f669307b1..c2f057ade 100644 --- a/spine-haxe/spine-haxe/spine/animation/DeformTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/DeformTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -139,19 +139,23 @@ class DeformTimeline extends SlotCurveTimeline { return y + (1 - y) * (time - x) / (frames[frame + getFrameEntries()] - x); } - public function apply1 (slot:Slot, pose:SlotPose, time:Float, alpha:Float, blend:MixBlend) { - if (!Std.isOfType(pose.attachment, VertexAttachment)) return; + public function apply1(slot:Slot, pose:SlotPose, time:Float, alpha:Float, blend:MixBlend) { + if (!Std.isOfType(pose.attachment, VertexAttachment)) + return; var vertexAttachment = cast(pose.attachment, VertexAttachment); - if (vertexAttachment.timelineAttachment != attachment) return; + if (vertexAttachment.timelineAttachment != attachment) + return; var deform = pose.deform; - if (deform.length == 0) blend = MixBlend.setup; + if (deform.length == 0) + blend = MixBlend.setup; var vertexCount = vertices[0].length; if (time < frames[0]) { switch (blend) { - case MixBlend.setup: deform.resize(0); + case MixBlend.setup: + deform.resize(0); case MixBlend.first: if (alpha == 1) { deform.resize(0); @@ -253,7 +257,8 @@ class DeformTimeline extends SlotCurveTimeline { if (vertexAttachment.bones == null) { // Unweighted vertex positions, with alpha. var setupVertices = vertexAttachment.vertices; for (i in 0...vertexCount) { - var prev = prevVertices[i], setup = setupVertices[i]; + var prev = prevVertices[i], + setup = setupVertices[i]; deform[i] = setup + (prev + (nextVertices[i] - prev) * percent - setup) * alpha; } } else { // Weighted deform offsets, with alpha. diff --git a/spine-haxe/spine-haxe/spine/animation/DrawOrderTimeline.hx b/spine-haxe/spine-haxe/spine/animation/DrawOrderTimeline.hx index 69e1ef84a..c7cc519d1 100644 --- a/spine-haxe/spine-haxe/spine/animation/DrawOrderTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/DrawOrderTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -59,9 +59,8 @@ class DrawOrderTimeline extends Timeline { drawOrders[frame] = drawOrder; } - public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, - blend:MixBlend, direction:MixDirection, appliedPose:Bool) { - + public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, blend:MixBlend, direction:MixDirection, + appliedPose:Bool) { var drawOrder:Array = skeleton.drawOrder; var slots:Array = skeleton.slots; var i:Int = 0, n:Int = slots.length; diff --git a/spine-haxe/spine-haxe/spine/animation/EventQueue.hx b/spine-haxe/spine-haxe/spine/animation/EventQueue.hx index e6912baf7..4708d11e8 100644 --- a/spine-haxe/spine-haxe/spine/animation/EventQueue.hx +++ b/spine-haxe/spine-haxe/spine/animation/EventQueue.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -79,7 +79,8 @@ class EventQueue { } public function drain():Void { - if (drainDisabled) return; // Not reentrant. + if (drainDisabled) + return; // Not reentrant. drainDisabled = true; var i:Int = 0; diff --git a/spine-haxe/spine-haxe/spine/animation/EventTimeline.hx b/spine-haxe/spine-haxe/spine/animation/EventTimeline.hx index 0011a681e..6f8d966ee 100644 --- a/spine-haxe/spine-haxe/spine/animation/EventTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/EventTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -56,9 +56,10 @@ class EventTimeline extends Timeline { } /** Fires events for frames > lastTime and <= time. */ - public function apply(skeleton:Skeleton, lastTime:Float, time:Float, firedEvents:Array, alpha:Float, - blend:MixBlend, direction:MixDirection, appliedPose:Bool) { - if (firedEvents == null) return; + public function apply(skeleton:Skeleton, lastTime:Float, time:Float, firedEvents:Array, alpha:Float, blend:MixBlend, direction:MixDirection, + appliedPose:Bool) { + if (firedEvents == null) + return; var frameCount:Int = frames.length; @@ -67,7 +68,8 @@ class EventTimeline extends Timeline { lastTime = -1; } else if (lastTime >= frames[frameCount - 1]) // Last time is after last frame. return; - if (time < frames[0]) return; + if (time < frames[0]) + return; var frame:Int; var i:Int = 0; diff --git a/spine-haxe/spine-haxe/spine/animation/EventType.hx b/spine-haxe/spine-haxe/spine/animation/EventType.hx index 6d9a5ddb9..2ba127aa6 100644 --- a/spine-haxe/spine-haxe/spine/animation/EventType.hx +++ b/spine-haxe/spine-haxe/spine/animation/EventType.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; diff --git a/spine-haxe/spine-haxe/spine/animation/IkConstraintTimeline.hx b/spine-haxe/spine-haxe/spine/animation/IkConstraintTimeline.hx index 3899fa3c6..90d366756 100644 --- a/spine-haxe/spine-haxe/spine/animation/IkConstraintTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/IkConstraintTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -52,7 +52,7 @@ class IkConstraintTimeline extends CurveTimeline implements ConstraintTimeline { return ENTRIES; } - public function getConstraintIndex () { + public function getConstraintIndex() { return constraintIndex; } @@ -70,11 +70,11 @@ class IkConstraintTimeline extends CurveTimeline implements ConstraintTimeline { frames[frame + STRETCH] = stretch ? 1 : 0; } - public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, - blend:MixBlend, direction:MixDirection, appliedPose:Bool) { - + public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, blend:MixBlend, direction:MixDirection, + appliedPose:Bool) { var constraint = cast(skeleton.constraints[constraintIndex], IkConstraint); - if (!constraint.active) return; + if (!constraint.active) + return; var pose = appliedPose ? constraint.applied : constraint.pose; if (time < frames[0]) { @@ -129,12 +129,13 @@ class IkConstraintTimeline extends CurveTimeline implements ConstraintTimeline { case MixBlend.first, MixBlend.replace: pose.mix += (mix - pose.mix) * alpha; pose.softness += (softness - pose.softness) * alpha; - if (direction == MixDirection.mixOut) return; + if (direction == MixDirection.mixOut) + return; case MixBlend.add: pose.mix += mix * alpha; pose.softness += softness * alpha; - if (direction == MixDirection.mixOut) return; - + if (direction == MixDirection.mixOut) + return; } pose.bendDirection = Std.int(frames[i + BEND_DIRECTION]); pose.compress = frames[i + COMPRESS] != 0; diff --git a/spine-haxe/spine-haxe/spine/animation/InheritTimeline.hx b/spine-haxe/spine-haxe/spine/animation/InheritTimeline.hx index 35e77ca47..a5cc63b1a 100644 --- a/spine-haxe/spine-haxe/spine/animation/InheritTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/InheritTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -45,7 +45,7 @@ class InheritTimeline extends Timeline implements BoneTimeline { this.boneIndex = boneIndex; } - public function getBoneIndex () { + public function getBoneIndex() { return boneIndex; } @@ -56,27 +56,29 @@ class InheritTimeline extends Timeline implements BoneTimeline { /** Sets the transform mode for the specified frame. * @param frame Between 0 and frameCount, inclusive. * @param time The frame time in seconds. */ - public function setFrame(frame:Int, time:Float, inherit: Inherit):Void { + public function setFrame(frame:Int, time:Float, inherit:Inherit):Void { frame *= ENTRIES; frames[frame] = time; frames[frame + INHERIT] = inherit.ordinal; } - public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, - blend:MixBlend, direction:MixDirection, appliedPose:Bool):Void { - + public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, blend:MixBlend, direction:MixDirection, + appliedPose:Bool):Void { var bone:Bone = skeleton.bones[boneIndex]; - if (!bone.active) return; + if (!bone.active) + return; var pose = appliedPose ? bone.applied : bone.pose; if (direction == MixDirection.mixOut) { - if (blend == MixBlend.setup) pose.inherit = bone.data.setup.inherit; + if (blend == MixBlend.setup) + pose.inherit = bone.data.setup.inherit; return; } var frames:Array = frames; if (time < frames[0]) { - if (blend == MixBlend.setup || blend == MixBlend.first) pose.inherit = bone.data.setup.inherit; + if (blend == MixBlend.setup || blend == MixBlend.first) + pose.inherit = bone.data.setup.inherit; } else pose.inherit = Inherit.values[Std.int(frames[Timeline.search(frames, time, ENTRIES) + INHERIT])]; } diff --git a/spine-haxe/spine-haxe/spine/animation/Listeners.hx b/spine-haxe/spine-haxe/spine/animation/Listeners.hx index b86e057b3..807aa8f4d 100644 --- a/spine-haxe/spine-haxe/spine/animation/Listeners.hx +++ b/spine-haxe/spine-haxe/spine/animation/Listeners.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; diff --git a/spine-haxe/spine-haxe/spine/animation/MixBlend.hx b/spine-haxe/spine-haxe/spine/animation/MixBlend.hx index 1d2e250ed..5cba38a0e 100644 --- a/spine-haxe/spine-haxe/spine/animation/MixBlend.hx +++ b/spine-haxe/spine-haxe/spine/animation/MixBlend.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -41,28 +41,28 @@ class MixBlend { } /** Transitions between the setup and timeline values (the current value is not used). Before the first frame, the setup - * value is used. - * - * `setup` is intended to transition to or from the setup pose, not for animations layered on top of others. */ + * value is used. + * + * `setup` is intended to transition to or from the setup pose, not for animations layered on top of others. */ public static var setup(default, never):MixBlend = new MixBlend(0); /** Transitions between the current and timeline values. Before the first frame, transitions between the current and setup - * values. Timelines which perform instant transitions, such as {@link DrawOrderTimeline} or {@link AttachmentTimeline}, use - * the setup value before the first frame. - * - * `first` is intended for the first animations applied, not for animations layered on top of others. */ + * values. Timelines which perform instant transitions, such as {@link DrawOrderTimeline} or {@link AttachmentTimeline}, use + * the setup value before the first frame. + * + * `first` is intended for the first animations applied, not for animations layered on top of others. */ public static var first(default, never):MixBlend = new MixBlend(1); /** Transitions between the current and timeline values. No change is made before the first frame. - * - * `replace` is intended for animations layered on top of others, not for the first animations applied. */ + * + * `replace` is intended for animations layered on top of others, not for the first animations applied. */ public static var replace(default, never):MixBlend = new MixBlend(2); /** Transitions between the current value and the current plus timeline values. No change is made before the first frame. - * - * `add` is intended for animations layered on top of others, not for the first animations applied. - * - * Properties set by additive animations must be set manually or by another animation before applying the additive - * animations, else the property values will increase each time the additive animations are applied. */ + * + * `add` is intended for animations layered on top of others, not for the first animations applied. + * + * Properties set by additive animations must be set manually or by another animation before applying the additive + * animations, else the property values will increase each time the additive animations are applied. */ public static var add(default, never):MixBlend = new MixBlend(3); } diff --git a/spine-haxe/spine-haxe/spine/animation/MixDirection.hx b/spine-haxe/spine-haxe/spine/animation/MixDirection.hx index 5f87b7919..915987a6c 100644 --- a/spine-haxe/spine-haxe/spine/animation/MixDirection.hx +++ b/spine-haxe/spine-haxe/spine/animation/MixDirection.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; diff --git a/spine-haxe/spine-haxe/spine/animation/PathConstraintMixTimeline.hx b/spine-haxe/spine-haxe/spine/animation/PathConstraintMixTimeline.hx index fcc437755..9fb7e6646 100644 --- a/spine-haxe/spine-haxe/spine/animation/PathConstraintMixTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/PathConstraintMixTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -54,7 +54,7 @@ class PathConstraintMixTimeline extends CurveTimeline implements ConstraintTimel return ENTRIES; } - public function getConstraintIndex () { + public function getConstraintIndex() { return constraintIndex; } @@ -69,11 +69,11 @@ class PathConstraintMixTimeline extends CurveTimeline implements ConstraintTimel frames[frame + Y] = mixY; } - public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, - blend:MixBlend, direction:MixDirection, appliedPose:Bool) { - + public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, blend:MixBlend, direction:MixDirection, + appliedPose:Bool) { var constraint = cast(skeleton.constraints[constraintIndex], PathConstraint); - if (!constraint.active) return; + if (!constraint.active) + return; var pose = appliedPose ? constraint.applied : constraint.pose; if (time < frames[0]) { diff --git a/spine-haxe/spine-haxe/spine/animation/PathConstraintPositionTimeline.hx b/spine-haxe/spine-haxe/spine/animation/PathConstraintPositionTimeline.hx index 699e439b4..1b8434c86 100644 --- a/spine-haxe/spine-haxe/spine/animation/PathConstraintPositionTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/PathConstraintPositionTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -35,14 +35,12 @@ class PathConstraintPositionTimeline extends ConstraintTimeline1 { super(frameCount, bezierCount, constraintIndex, Property.pathConstraintPosition); } - public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, - blend:MixBlend, direction:MixDirection, appliedPose:Bool) { - + public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, blend:MixBlend, direction:MixDirection, + appliedPose:Bool) { var constraint = cast(skeleton.constraints[constraintIndex], PathConstraint); if (constraint.active) { var pose = appliedPose ? constraint.applied : constraint.pose; pose.position = getAbsoluteValue(time, alpha, blend, pose.position, constraint.data.setup.position); } - } } diff --git a/spine-haxe/spine-haxe/spine/animation/PathConstraintSpacingTimeline.hx b/spine-haxe/spine-haxe/spine/animation/PathConstraintSpacingTimeline.hx index 4b5ab5ba8..d089b3f15 100644 --- a/spine-haxe/spine-haxe/spine/animation/PathConstraintSpacingTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/PathConstraintSpacingTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -39,9 +39,8 @@ class PathConstraintSpacingTimeline extends ConstraintTimeline1 { super(frameCount, bezierCount, constraintIndex, Property.pathConstraintSpacing); } - public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, - blend:MixBlend, direction:MixDirection, appliedPose:Bool) { - + public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, blend:MixBlend, direction:MixDirection, + appliedPose:Bool) { var constraint = cast(skeleton.constraints[constraintIndex], PathConstraint); if (constraint.active) { var pose = appliedPose ? constraint.applied : constraint.pose; diff --git a/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintDampingTimeline.hx b/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintDampingTimeline.hx index 172a65de1..505b4cc9d 100644 --- a/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintDampingTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintDampingTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -35,16 +35,15 @@ class PhysicsConstraintDampingTimeline extends PhysicsConstraintTimeline { super(frameCount, bezierCount, constraintIndex, Property.physicsConstraintDamping); } - public function get (pose: PhysicsConstraintPose):Float { + public function get(pose:PhysicsConstraintPose):Float { return pose.damping; } - public function set (pose: PhysicsConstraintPose, value:Float):Void { + public function set(pose:PhysicsConstraintPose, value:Float):Void { pose.damping = value; } - public function global (constraint: PhysicsConstraintData):Bool { + public function global(constraint:PhysicsConstraintData):Bool { return constraint.dampingGlobal; } - } diff --git a/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintGravityTimeline.hx b/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintGravityTimeline.hx index c6399926b..df3362be1 100644 --- a/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintGravityTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintGravityTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -35,16 +35,15 @@ class PhysicsConstraintGravityTimeline extends PhysicsConstraintTimeline { super(frameCount, bezierCount, constraintIndex, Property.physicsConstraintGravity); } - public function get (pose: PhysicsConstraintPose):Float { + public function get(pose:PhysicsConstraintPose):Float { return pose.gravity; } - public function set (pose: PhysicsConstraintPose, value:Float):Void { + public function set(pose:PhysicsConstraintPose, value:Float):Void { pose.gravity = value; } - public function global (constraint: PhysicsConstraintData):Bool { + public function global(constraint:PhysicsConstraintData):Bool { return constraint.gravityGlobal; } - } diff --git a/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintInertiaTimeline.hx b/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintInertiaTimeline.hx index 32054adf8..2a6059c84 100644 --- a/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintInertiaTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintInertiaTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -35,16 +35,15 @@ class PhysicsConstraintInertiaTimeline extends PhysicsConstraintTimeline { super(frameCount, bezierCount, constraintIndex, Property.physicsConstraintInertia); } - public function get (pose: PhysicsConstraintPose):Float { + public function get(pose:PhysicsConstraintPose):Float { return pose.inertia; } - public function set (pose: PhysicsConstraintPose, value:Float):Void { + public function set(pose:PhysicsConstraintPose, value:Float):Void { pose.inertia = value; } - public function global (constraint: PhysicsConstraintData):Bool { + public function global(constraint:PhysicsConstraintData):Bool { return constraint.inertiaGlobal; } - } diff --git a/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintMassTimeline.hx b/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintMassTimeline.hx index bd47350a6..404fa5150 100644 --- a/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintMassTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintMassTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -35,16 +35,15 @@ class PhysicsConstraintMassTimeline extends PhysicsConstraintTimeline { super(frameCount, bezierCount, constraintIndex, Property.physicsConstraintMass); } - public function get (pose: PhysicsConstraintPose):Float { + public function get(pose:PhysicsConstraintPose):Float { return 1 / pose.massInverse; } - public function set (pose: PhysicsConstraintPose, value:Float):Void { + public function set(pose:PhysicsConstraintPose, value:Float):Void { pose.massInverse = 1 / value; } - public function global (constraint: PhysicsConstraintData):Bool { + public function global(constraint:PhysicsConstraintData):Bool { return constraint.massGlobal; } - } diff --git a/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintMixTimeline.hx b/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintMixTimeline.hx index 21e3211a3..b6a843b3d 100644 --- a/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintMixTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintMixTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -35,16 +35,15 @@ class PhysicsConstraintMixTimeline extends PhysicsConstraintTimeline { super(frameCount, bezierCount, constraintIndex, Property.physicsConstraintMix); } - public function get (pose: PhysicsConstraintPose):Float { + public function get(pose:PhysicsConstraintPose):Float { return pose.mix; } - public function set (pose: PhysicsConstraintPose, value:Float):Void { + public function set(pose:PhysicsConstraintPose, value:Float):Void { pose.mix = value; } - public function global (constraint: PhysicsConstraintData):Bool { + public function global(constraint:PhysicsConstraintData):Bool { return constraint.mixGlobal; } - } diff --git a/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintResetTimeline.hx b/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintResetTimeline.hx index 73ea745c4..33ec52100 100644 --- a/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintResetTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintResetTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -43,7 +43,7 @@ class PhysicsConstraintResetTimeline extends Timeline implements ConstraintTimel this.constraintIndex = constraintIndex; } - public function getConstraintIndex () { + public function getConstraintIndex() { return constraintIndex; } @@ -58,13 +58,13 @@ class PhysicsConstraintResetTimeline extends Timeline implements ConstraintTimel } /** Resets the physics constraint when frames > lastTime and <= time. */ - public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, - blend:MixBlend, direction:MixDirection, appliedPose:Bool) { - + public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, blend:MixBlend, direction:MixDirection, + appliedPose:Bool) { var constraint:PhysicsConstraint = null; if (constraintIndex != -1) { constraint = cast(skeleton.constraints[constraintIndex], PhysicsConstraint); - if (!constraint.active) return; + if (!constraint.active) + return; } var frames:Array = this.frames; @@ -74,14 +74,16 @@ class PhysicsConstraintResetTimeline extends Timeline implements ConstraintTimel lastTime = -1; } else if (lastTime >= frames[frames.length - 1]) // Last time is after last frame. return; - if (time < frames[0]) return; + if (time < frames[0]) + return; if (lastTime < frames[0] || time >= frames[Timeline.search1(frames, lastTime) + 1]) { if (constraint != null) constraint.reset(skeleton); else { for (constraint in skeleton.physics) { - if (constraint.active) constraint.reset(skeleton); + if (constraint.active) + constraint.reset(skeleton); } } } diff --git a/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintStrengthTimeline.hx b/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintStrengthTimeline.hx index e1ddd9e2a..65a73b4b6 100644 --- a/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintStrengthTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintStrengthTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -35,16 +35,15 @@ class PhysicsConstraintStrengthTimeline extends PhysicsConstraintTimeline { super(frameCount, bezierCount, constraintIndex, Property.physicsConstraintStrength); } - public function get (pose: PhysicsConstraintPose):Float { + public function get(pose:PhysicsConstraintPose):Float { return pose.strength; } - public function set (pose: PhysicsConstraintPose, value:Float):Void { + public function set(pose:PhysicsConstraintPose, value:Float):Void { pose.strength = value; } - public function global (constraint: PhysicsConstraintData):Bool { + public function global(constraint:PhysicsConstraintData):Bool { return constraint.strengthGlobal; } - } diff --git a/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintTimeline.hx b/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintTimeline.hx index d61c20422..01801adf8 100644 --- a/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -42,9 +42,8 @@ abstract class PhysicsConstraintTimeline extends ConstraintTimeline1 { super(frameCount, bezierCount, constraintIndex, property); } - public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, - blend:MixBlend, direction:MixDirection, appliedPose:Bool) { - + public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, blend:MixBlend, direction:MixDirection, + appliedPose:Bool) { if (constraintIndex == -1) { var value:Float = time >= frames[0] ? getCurveValue(time) : 0; for (constraint in skeleton.physics) { @@ -62,9 +61,9 @@ abstract class PhysicsConstraintTimeline extends ConstraintTimeline1 { } } - abstract public function get (pose: PhysicsConstraintPose):Float; + abstract public function get(pose:PhysicsConstraintPose):Float; - abstract public function set (pose: PhysicsConstraintPose, value:Float):Void; + abstract public function set(pose:PhysicsConstraintPose, value:Float):Void; - abstract public function global (constraint: PhysicsConstraintData):Bool; + abstract public function global(constraint:PhysicsConstraintData):Bool; } diff --git a/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintWindTimeline.hx b/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintWindTimeline.hx index 37590d5bb..a3cd7e117 100644 --- a/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintWindTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/PhysicsConstraintWindTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -35,16 +35,15 @@ class PhysicsConstraintWindTimeline extends PhysicsConstraintTimeline { super(frameCount, bezierCount, constraintIndex, Property.physicsConstraintWind); } - public function get (pose: PhysicsConstraintPose):Float { + public function get(pose:PhysicsConstraintPose):Float { return pose.wind; } - public function set (pose: PhysicsConstraintPose, value:Float):Void { + public function set(pose:PhysicsConstraintPose, value:Float):Void { pose.wind = value; } - public function global (constraint: PhysicsConstraintData):Bool { + public function global(constraint:PhysicsConstraintData):Bool { return constraint.windGlobal; } - } diff --git a/spine-haxe/spine-haxe/spine/animation/Property.hx b/spine-haxe/spine-haxe/spine/animation/Property.hx index 3a99febf8..306e989e7 100644 --- a/spine-haxe/spine-haxe/spine/animation/Property.hx +++ b/spine-haxe/spine-haxe/spine/animation/Property.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -72,4 +72,4 @@ enum abstract Property(String) from String to String { var sliderTime = "29"; var sliderMix = "30"; -} \ No newline at end of file +} diff --git a/spine-haxe/spine-haxe/spine/animation/RGB2Timeline.hx b/spine-haxe/spine-haxe/spine/animation/RGB2Timeline.hx index 6cba8d6e2..b79b692d5 100644 --- a/spine-haxe/spine-haxe/spine/animation/RGB2Timeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/RGB2Timeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -40,9 +40,7 @@ class RGB2Timeline extends SlotCurveTimeline { private static inline var B2:Int = 6; public function new(frameCount:Int, bezierCount:Int, slotIndex:Int) { - super(frameCount, bezierCount, slotIndex, - Property.rgb + "|" + slotIndex, - Property.rgb2 + "|" + slotIndex); + super(frameCount, bezierCount, slotIndex, Property.rgb + "|" + slotIndex, Property.rgb2 + "|" + slotIndex); } public override function getFrameEntries():Int { @@ -63,7 +61,7 @@ class RGB2Timeline extends SlotCurveTimeline { frames[frame + B2] = b2; } - public function apply1 (slot:Slot, pose:SlotPose, time:Float, alpha:Float, blend:MixBlend) { + public function apply1(slot:Slot, pose:SlotPose, time:Float, alpha:Float, blend:MixBlend) { var light:Color = pose.color, dark:Color = pose.darkColor; if (time < frames[0]) { var setup = slot.data.setup; diff --git a/spine-haxe/spine-haxe/spine/animation/RGBA2Timeline.hx b/spine-haxe/spine-haxe/spine/animation/RGBA2Timeline.hx index 26f5d37f1..e1ce8fea2 100644 --- a/spine-haxe/spine-haxe/spine/animation/RGBA2Timeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/RGBA2Timeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -41,11 +41,13 @@ class RGBA2Timeline extends SlotCurveTimeline { private static inline var B2:Int = 7; public function new(frameCount:Int, bezierCount:Int, slotIndex:Int) { - super(frameCount, bezierCount, slotIndex, - Property.rgb + "|" + slotIndex, - Property.alpha + "|" + slotIndex, - Property.rgb2 + "|" + slotIndex - ); + super(frameCount, bezierCount, slotIndex, Property.rgb + + "|" + + slotIndex, Property.alpha + + "|" + + slotIndex, Property.rgb2 + + "|" + + slotIndex); } public override function getFrameEntries():Int { @@ -67,7 +69,7 @@ class RGBA2Timeline extends SlotCurveTimeline { frames[frame + B2] = b2; } - public function apply1 (slot:Slot, pose:SlotPose, time:Float, alpha:Float, blend:MixBlend) { + public function apply1(slot:Slot, pose:SlotPose, time:Float, alpha:Float, blend:MixBlend) { var light = pose.color, dark = pose.darkColor; if (time < frames[0]) { var setup = slot.data.setup; diff --git a/spine-haxe/spine-haxe/spine/animation/RGBATimeline.hx b/spine-haxe/spine-haxe/spine/animation/RGBATimeline.hx index f51ac1039..9b65dd6a6 100644 --- a/spine-haxe/spine-haxe/spine/animation/RGBATimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/RGBATimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -38,9 +38,7 @@ class RGBATimeline extends SlotCurveTimeline { private static inline var A:Int = 4; public function new(frameCount:Int, bezierCount:Int, slotIndex:Int) { - super(frameCount, bezierCount, slotIndex, - Property.rgb + "|" + slotIndex, - Property.alpha + "|" + slotIndex); + super(frameCount, bezierCount, slotIndex, Property.rgb + "|" + slotIndex, Property.alpha + "|" + slotIndex); } public override function getFrameEntries():Int { @@ -59,7 +57,7 @@ class RGBATimeline extends SlotCurveTimeline { frames[frame + A] = a; } - public function apply1 (slot:Slot, pose:SlotPose, time:Float, alpha:Float, blend:MixBlend) { + public function apply1(slot:Slot, pose:SlotPose, time:Float, alpha:Float, blend:MixBlend) { var color = pose.color; if (time < frames[0]) { var setup:Color = slot.data.setup.color; diff --git a/spine-haxe/spine-haxe/spine/animation/RGBTimeline.hx b/spine-haxe/spine-haxe/spine/animation/RGBTimeline.hx index e4a9d7fbc..84fd65611 100644 --- a/spine-haxe/spine-haxe/spine/animation/RGBTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/RGBTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -55,7 +55,7 @@ class RGBTimeline extends SlotCurveTimeline { frames[frame + B] = b; } - public function apply1 (slot:Slot, pose:SlotPose, time:Float, alpha:Float, blend:MixBlend) { + public function apply1(slot:Slot, pose:SlotPose, time:Float, alpha:Float, blend:MixBlend) { var color = pose.color; if (time < frames[0]) { var setup = slot.data.setup.color; diff --git a/spine-haxe/spine-haxe/spine/animation/RotateTimeline.hx b/spine-haxe/spine-haxe/spine/animation/RotateTimeline.hx index 6ab957401..ab44ad827 100644 --- a/spine-haxe/spine-haxe/spine/animation/RotateTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/RotateTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -36,7 +36,7 @@ class RotateTimeline extends BoneTimeline1 { this.boneIndex = boneIndex; } - public function apply1 (pose:BoneLocal, setup:BoneLocal, time:Float, alpha:Float, blend:MixBlend, direction:MixDirection):Void { + public function apply1(pose:BoneLocal, setup:BoneLocal, time:Float, alpha:Float, blend:MixBlend, direction:MixDirection):Void { pose.rotation = getRelativeValue(time, alpha, blend, pose.rotation, setup.rotation); } } diff --git a/spine-haxe/spine-haxe/spine/animation/ScaleTimeline.hx b/spine-haxe/spine-haxe/spine/animation/ScaleTimeline.hx index 381d94f1c..26d618189 100644 --- a/spine-haxe/spine-haxe/spine/animation/ScaleTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/ScaleTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -40,7 +40,7 @@ class ScaleTimeline extends BoneTimeline2 { super(frameCount, bezierCount, boneIndex, Property.scaleX, Property.scaleY); } - public function apply1 (pose:BoneLocal, setup:BoneLocal, time:Float, alpha:Float, blend:MixBlend, direction:MixDirection) { + public function apply1(pose:BoneLocal, setup:BoneLocal, time:Float, alpha:Float, blend:MixBlend, direction:MixDirection) { if (time < frames[0]) { switch (blend) { case MixBlend.setup: diff --git a/spine-haxe/spine-haxe/spine/animation/ScaleXTimeline.hx b/spine-haxe/spine-haxe/spine/animation/ScaleXTimeline.hx index 6352e2182..7d85d58c3 100644 --- a/spine-haxe/spine-haxe/spine/animation/ScaleXTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/ScaleXTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -35,7 +35,7 @@ class ScaleXTimeline extends BoneTimeline1 { super(frameCount, bezierCount, boneIndex, Property.scaleX); } - public function apply1 (pose:BoneLocal, setup:BoneLocal, time:Float, alpha:Float, blend:MixBlend, direction:MixDirection) { + public function apply1(pose:BoneLocal, setup:BoneLocal, time:Float, alpha:Float, blend:MixBlend, direction:MixDirection) { pose.scaleX = getScaleValue(time, alpha, blend, direction, pose.scaleX, setup.scaleX); } } diff --git a/spine-haxe/spine-haxe/spine/animation/ScaleYTimeline.hx b/spine-haxe/spine-haxe/spine/animation/ScaleYTimeline.hx index 63b384a7a..92274794b 100644 --- a/spine-haxe/spine-haxe/spine/animation/ScaleYTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/ScaleYTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -35,7 +35,7 @@ class ScaleYTimeline extends BoneTimeline1 { super(frameCount, bezierCount, boneIndex, Property.scaleY); } - public function apply1 (pose:BoneLocal, setup:BoneLocal, time:Float, alpha:Float, blend:MixBlend, direction:MixDirection) { + public function apply1(pose:BoneLocal, setup:BoneLocal, time:Float, alpha:Float, blend:MixBlend, direction:MixDirection) { pose.scaleY = getScaleValue(time, alpha, blend, direction, pose.scaleY, setup.scaleY); } } diff --git a/spine-haxe/spine-haxe/spine/animation/SequenceTimeline.hx b/spine-haxe/spine-haxe/spine/animation/SequenceTimeline.hx index fca8b29f6..3ce3b49ad 100644 --- a/spine-haxe/spine-haxe/spine/animation/SequenceTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/SequenceTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -42,8 +42,7 @@ class SequenceTimeline extends Timeline implements SlotTimeline { var attachment:HasTextureRegion; public function new(frameCount:Int, slotIndex:Int, attachment:HasTextureRegion) { - super(frameCount, - Std.string(Property.sequence) + "|" + Std.string(slotIndex) + "|" + Std.string(attachment.sequence.id)); + super(frameCount, Std.string(Property.sequence) + "|" + Std.string(slotIndex) + "|" + Std.string(attachment.sequence.id)); this.slotIndex = slotIndex; this.attachment = attachment; } @@ -70,11 +69,11 @@ class SequenceTimeline extends Timeline implements SlotTimeline { frames[frame + SequenceTimeline.DELAY] = delay; } - public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, - blend:MixBlend, direction:MixDirection, appliedPose:Bool) { - + public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, blend:MixBlend, direction:MixDirection, + appliedPose:Bool) { var slot = skeleton.slots[this.slotIndex]; - if (!slot.bone.active) return; + if (!slot.bone.active) + return; var pose = appliedPose ? slot.applied : slot.pose; var slotAttachment = pose.attachment; @@ -85,12 +84,14 @@ class SequenceTimeline extends Timeline implements SlotTimeline { } if (direction == MixDirection.mixOut) { - if (blend == MixBlend.setup) pose.sequenceIndex = -1; + if (blend == MixBlend.setup) + pose.sequenceIndex = -1; return; } if (time < frames[0]) { - if (blend == MixBlend.setup || blend == MixBlend.first) pose.sequenceIndex = -1; + if (blend == MixBlend.setup || blend == MixBlend.first) + pose.sequenceIndex = -1; return; } diff --git a/spine-haxe/spine-haxe/spine/animation/ShearTimeline.hx b/spine-haxe/spine-haxe/spine/animation/ShearTimeline.hx index a2fb42c5c..929e5b87c 100644 --- a/spine-haxe/spine-haxe/spine/animation/ShearTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/ShearTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -35,7 +35,7 @@ class ShearTimeline extends BoneTimeline2 { super(frameCount, bezierCount, boneIndex, Property.shearX, Property.shearY); } - public function apply1 (pose:BoneLocal, setup:BoneLocal, time:Float, alpha:Float, blend:MixBlend, direction:MixDirection) { + public function apply1(pose:BoneLocal, setup:BoneLocal, time:Float, alpha:Float, blend:MixBlend, direction:MixDirection) { if (time < frames[0]) { switch (blend) { case MixBlend.setup: diff --git a/spine-haxe/spine-haxe/spine/animation/ShearXTimeline.hx b/spine-haxe/spine-haxe/spine/animation/ShearXTimeline.hx index 1d37533b5..17498802b 100644 --- a/spine-haxe/spine-haxe/spine/animation/ShearXTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/ShearXTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -35,7 +35,7 @@ class ShearXTimeline extends BoneTimeline1 { super(frameCount, bezierCount, boneIndex, Property.shearX); } - public function apply1 (pose:BoneLocal, setup:BoneLocal, time:Float, alpha:Float, blend:MixBlend, direction:MixDirection) { + public function apply1(pose:BoneLocal, setup:BoneLocal, time:Float, alpha:Float, blend:MixBlend, direction:MixDirection) { pose.shearX = getRelativeValue(time, alpha, blend, pose.shearX, setup.shearX); } } diff --git a/spine-haxe/spine-haxe/spine/animation/ShearYTimeline.hx b/spine-haxe/spine-haxe/spine/animation/ShearYTimeline.hx index ea046c054..f77e408bd 100644 --- a/spine-haxe/spine-haxe/spine/animation/ShearYTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/ShearYTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -35,7 +35,7 @@ class ShearYTimeline extends BoneTimeline1 { super(frameCount, bezierCount, boneIndex, Property.shearY); } - public function apply1 (pose:BoneLocal, setup:BoneLocal, time:Float, alpha:Float, blend:MixBlend, direction:MixDirection) { + public function apply1(pose:BoneLocal, setup:BoneLocal, time:Float, alpha:Float, blend:MixBlend, direction:MixDirection) { pose.shearY = getRelativeValue(time, alpha, blend, pose.shearY, setup.shearY); } } diff --git a/spine-haxe/spine-haxe/spine/animation/SliderMixTimeline.hx b/spine-haxe/spine-haxe/spine/animation/SliderMixTimeline.hx index 5468e0532..afbfb16eb 100644 --- a/spine-haxe/spine-haxe/spine/animation/SliderMixTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/SliderMixTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -33,13 +33,12 @@ import haxe.macro.Type.VarAccess; /** Changes a slider's spine.SliderPose.mix. */ class SliderMixTimeline extends ConstraintTimeline1 { - public function new (frameCount:Int, bezierCount:Int, constraintIndex:Int) { + public function new(frameCount:Int, bezierCount:Int, constraintIndex:Int) { super(frameCount, bezierCount, constraintIndex, Property.sliderMix); } - public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, - blend:MixBlend, direction:MixDirection, appliedPose:Bool) { - + public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, blend:MixBlend, direction:MixDirection, + appliedPose:Bool) { var constraint = cast(skeleton.constraints[constraintIndex], Slider); if (constraint.active) { var pose = appliedPose ? constraint.applied : constraint.pose; diff --git a/spine-haxe/spine-haxe/spine/animation/SliderTimeline.hx b/spine-haxe/spine-haxe/spine/animation/SliderTimeline.hx index eb80803b5..4815365ba 100644 --- a/spine-haxe/spine-haxe/spine/animation/SliderTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/SliderTimeline.hx @@ -25,19 +25,18 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; /** Changes a slider's spine.SliderPose.time. */ class SliderTimeline extends ConstraintTimeline1 { - public function new (frameCount:Int, bezierCount:Int, constraintIndex:Int) { + public function new(frameCount:Int, bezierCount:Int, constraintIndex:Int) { super(frameCount, bezierCount, constraintIndex, Property.sliderTime); } - public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, - blend:MixBlend, direction:MixDirection, appliedPose:Bool) { - + public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, blend:MixBlend, direction:MixDirection, + appliedPose:Bool) { var constraint = cast(skeleton.constraints[constraintIndex], Slider); if (constraint.active) { var pose = appliedPose ? constraint.applied : constraint.pose; diff --git a/spine-haxe/spine-haxe/spine/animation/SlotCurveTimeline.hx b/spine-haxe/spine-haxe/spine/animation/SlotCurveTimeline.hx index 226a901e9..303f71600 100644 --- a/spine-haxe/spine-haxe/spine/animation/SlotCurveTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/SlotCurveTimeline.hx @@ -25,28 +25,28 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; abstract class SlotCurveTimeline extends CurveTimeline implements SlotTimeline { public final slotIndex:Int; - public function new (frameCount:Int, bezierCount:Int, slotIndex:Int, propertyIds:...String) { + public function new(frameCount:Int, bezierCount:Int, slotIndex:Int, propertyIds:...String) { super(frameCount, bezierCount, ...propertyIds); this.slotIndex = slotIndex; } - public function getSlotIndex () { + public function getSlotIndex() { return slotIndex; } - public function apply (skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, blend:MixBlend, - direction:MixDirection, appliedPose:Bool) { - + public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, blend:MixBlend, direction:MixDirection, + appliedPose:Bool) { var slot = skeleton.slots[slotIndex]; - if (slot.bone.active) apply1(slot, appliedPose ? slot.applied : slot.pose, time, alpha, blend); + if (slot.bone.active) + apply1(slot, appliedPose ? slot.applied : slot.pose, time, alpha, blend); } - abstract function apply1 (slot:Slot, pose:SlotPose, time:Float, alpha:Float, blend:MixBlend):Void; + abstract function apply1(slot:Slot, pose:SlotPose, time:Float, alpha:Float, blend:MixBlend):Void; } diff --git a/spine-haxe/spine-haxe/spine/animation/SlotTimeline.hx b/spine-haxe/spine-haxe/spine/animation/SlotTimeline.hx index c98cdca26..9014828cf 100644 --- a/spine-haxe/spine-haxe/spine/animation/SlotTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/SlotTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; diff --git a/spine-haxe/spine-haxe/spine/animation/Timeline.hx b/spine-haxe/spine-haxe/spine/animation/Timeline.hx index 10f02a60e..080bd0ca4 100644 --- a/spine-haxe/spine-haxe/spine/animation/Timeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/Timeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -36,6 +36,7 @@ import spine.Skeleton; abstract class Timeline { /** Uniquely encodes both the type of this timeline and the skeleton properties that it affects. */ public var propertyIds:Array; + /** The time in seconds and any other values for each frame. */ public var frames:Array; @@ -83,8 +84,8 @@ abstract class Timeline { * @param direction Indicates whether the timeline is mixing in or out. Used by timelines which perform instant transitions, * such as spine.animation.DrawOrderTimeline or spine.animation.AttachmentTimeline, and others such as spine.animation.ScaleTimeline. * @param appliedPose True to to modify the applied pose. */ - abstract public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, - blend:MixBlend, direction:MixDirection, appliedPose:Bool):Void; + abstract public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, blend:MixBlend, direction:MixDirection, + appliedPose:Bool):Void; /** Linear search using a stride of 1. * @param time Must be >= the first value in frames. diff --git a/spine-haxe/spine-haxe/spine/animation/TrackEntry.hx b/spine-haxe/spine-haxe/spine/animation/TrackEntry.hx index 26d8fec74..6023b6c67 100644 --- a/spine-haxe/spine-haxe/spine/animation/TrackEntry.hx +++ b/spine-haxe/spine-haxe/spine/animation/TrackEntry.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -38,34 +38,43 @@ import spine.Poolable; class TrackEntry implements Poolable { /** The animation to apply for this track entry. */ public var animation:Animation; + /** The animation queued to start after this animation, or null if there is none. next makes up a doubly linked * list. * * See spine.animation.AnimationState.clearNext(TrackEntry) to truncate the list. */ public var next:TrackEntry; + /** The animation queued to play before this animation, or null. previous makes up a doubly linked list. */ public var previous:TrackEntry; + /** The track entry for the previous animation when mixing from the previous animation to this animation, or null if no * mixing is currently occurring. When mixing from multiple animations, mixingFrom makes up a linked list. */ public var mixingFrom:TrackEntry; + /** The track entry for the next animation when mixing from this animation to the next animation, or null if no mixing is * currently occurring. When mixing to multiple animations, mixingTo makes up a linked list. */ public var mixingTo:TrackEntry; + public var onStart:Listeners = new Listeners(); public var onInterrupt:Listeners = new Listeners(); public var onEnd:Listeners = new Listeners(); public var onDispose:Listeners = new Listeners(); public var onComplete:Listeners = new Listeners(); public var onEvent:EventListeners = new EventListeners(); + /** The index of the track where this track entry is either current or queued. * * See spine.animation.AnimationState.getCurrent(int). */ public var trackIndex:Int = 0; + /** If true, the animation will repeat. If false it will not, instead its last frame is applied if played beyond its * duration. */ public var loop:Bool = false; + /** If true, the animation will be applied in reverse. Events are not fired when an animation is applied in reverse. */ public var reverse:Bool = false; + /** If true, when mixing from the previous animation to this animation, the previous animation is applied as normal instead * of being mixed out. * @@ -78,55 +87,65 @@ class TrackEntry implements Poolable { * Snapping will occur if holdPrevious is true and this animation does not key all the same properties as the * previous animation. */ public var holdPrevious:Bool = false; + /** When the mix percentage (TrackEntry.getMixTime() / TrackEntry.getMixDuration()) is less than the * eventThreshold, event timelines are applied while this animation is being mixed out. Defaults to 0, so event * timelines are not applied while this animation is being mixed out. */ public var eventThreshold:Float = 0; + /** When the mix percentage (TrackEntry.getMixTime() / TrackEntry.getMixDuration()) is less than the * mixAttachmentThreshold, attachment timelines are applied while this animation is being mixed out. Defaults * to 0, so attachment timelines are not applied while this animation is being mixed out. */ public var mixAttachmentThreshold:Float = 0; + /** When TrackEntry.getAlpha() is greater than alphaAttachmentThreshold, attachment timelines are applied. * Defaults to 0, so attachment timelines are always applied. */ public var alphaAttachmentThreshold:Float = 0; + /** When the mix percentage (TrackEntry.getMixTime() / TrackEntry.getMixDuration()) is less than the * mixDrawOrderThreshold, draw order timelines are applied while this animation is being mixed out. Defaults to * 0, so draw order timelines are not applied while this animation is being mixed out. */ public var mixDrawOrderThreshold:Float = 0; + /** Seconds when this animation starts, both initially and after looping. Defaults to 0. * * When changing the animationStart time, it often makes sense to set TrackEntry.getAnimationLast() to the same * value to prevent timeline keys before the start time from triggering. */ public var animationStart:Float = 0; + /** Seconds for the last frame of this animation. Non-looping animations won't play past this time. Looping animations will * loop back to TrackEntry.getAnimationStart() at this time. Defaults to the animation spine.animation.Animation.duration. */ public var animationEnd:Float = 0; + /** The time in seconds this animation was last applied. Some timelines use this for one-time triggers. Eg, when this * animation is applied, event timelines will fire all events between the animationLast time (exclusive) and * animationTime (inclusive). Defaults to -1 to ensure triggers on frame 0 happen the first time this animation * is applied. */ public var animationLast:Float = 0; + public var nextAnimationLast:Float = 0; /** Seconds to postpone playing the animation. Must be >= 0. When this track entry is the current track entry, - * delay postpones incrementing the TrackEntry.getTrackTime(). When this track entry is queued, - * delay is the time from the start of the previous animation to when this track entry will become the current - * track entry (ie when the previous track entry TrackEntry.getTrackTime() >= this track entry's - * delay). - * - * TrackEntry.getTimeScale() affects the delay. - * - * When passing delay <= 0 to spine.animation.AnimationState.addAnimation(int, Animation, boolean, float) this - * delay is set using a mix duration from spine.animation.AnimationStateData. To change the TrackEntry.getMixDuration() - * afterward, use TrackEntry.setMixDuration(float, float) so this delay is adjusted. */ + * delay postpones incrementing the TrackEntry.getTrackTime(). When this track entry is queued, + * delay is the time from the start of the previous animation to when this track entry will become the current + * track entry (ie when the previous track entry TrackEntry.getTrackTime() >= this track entry's + * delay). + * + * TrackEntry.getTimeScale() affects the delay. + * + * When passing delay <= 0 to spine.animation.AnimationState.addAnimation(int, Animation, boolean, float) this + * delay is set using a mix duration from spine.animation.AnimationStateData. To change the TrackEntry.getMixDuration() + * afterward, use TrackEntry.setMixDuration(float, float) so this delay is adjusted. */ public var delay(default, set):Float = 0; /** Current time in seconds this track entry has been the current track entry. The track time determines * TrackEntry.getAnimationTime(). The track time can be set to start the animation at a time other than 0, without affecting * looping. */ public var trackTime:Float = 0; + public var trackLast:Float = 0; public var nextTrackLast:Float = 0; + /** The track time in seconds when this animation will be removed from the track. Defaults to the highest possible float * value, meaning the animation will be applied until a new animation is set or the track is cleared. If the track end time * is reached, no other animations are queued for playback, and mixing from any previous animations is complete, then the @@ -135,6 +154,7 @@ class TrackEntry implements Poolable { * It may be desired to use spine.animation.AnimationState.addEmptyAnimation(int, float, float) rather than have the animation * abruptly cease being applied. */ public var trackEnd:Float = 0; + /** Multiplier for the delta time when this track entry is updated, causing time for this animation to pass slower or * faster. Defaults to 1. * @@ -149,15 +169,18 @@ class TrackEntry implements Poolable { * * See AnimationState spine.animation.AnimationState.getTimeScale() for affecting all animations. */ public var timeScale:Float = 0; + /** Values < 1 mix this animation with the skeleton's current pose (usually the pose resulting from lower tracks). Defaults * to 1, which overwrites the skeleton's current pose with this animation. * * Typically track 0 is used to completely pose the skeleton, then alpha is used on higher tracks. It doesn't make sense to * use alpha on track 0 if the skeleton pose is from the last frame render. */ public var alpha:Float = 0; + /** Seconds from 0 to the TrackEntry.getMixDuration() when mixing from the previous animation to this animation. May be * slightly more than mixDuration when the mix is complete. */ public var mixTime:Float = 0; + /** Seconds for mixing from the previous animation to this animation. Defaults to the value provided by AnimationStateData * spine.animation.AnimationStateData.getMix(Animation, Animation) based on the animation before this animation (if any). * @@ -176,8 +199,10 @@ class TrackEntry implements Poolable { * Alternatively, TrackEntry.setMixDuration(float, float) can be used to recompute the delay: * entry.setMixDuration(0.25f, 0); */ public var mixDuration:Float = 0; + public var interruptAlpha:Float = 0; public var totalAlpha:Float = 0; + /** Controls how properties keyed in the animation are mixed with lower tracks. Defaults to spine.animation.MixBlend.replace. * * Track entries on track 0 ignore this setting and always use spine.animation.MixBlend.first. @@ -185,9 +210,11 @@ class TrackEntry implements Poolable { * The mixBlend can be set for a new track entry only before spine.animation.AnimationState.apply(Skeleton) is first * called. */ public var mixBlend:MixBlend = MixBlend.replace; + public var timelineMode:Array = new Array(); public var timelineHoldMix:Array = new Array(); public var timelinesRotation:Array = new Array(); + /** If true, mixing rotation between tracks always uses the shortest rotation direction. If the rotation is animated, the * shortest rotation direction may change during the mix. * @@ -196,7 +223,8 @@ class TrackEntry implements Poolable { public var shortestRotation = false; function set_delay(delay:Float):Float { - if (delay < 0) throw new SpineException("delay must be >= 0."); + if (delay < 0) + throw new SpineException("delay must be >= 0."); return this.delay = delay; } @@ -240,7 +268,7 @@ class TrackEntry implements Poolable { } /** Returns true if there is a TrackEntry.getNext() track entry and it will become the current track entry during the next - * spine.animation.AnimationState.update(float). */ + * spine.animation.AnimationState.update(float). */ public function isNextReady():Bool { return next != null && nextTrackLast - next.delay >= 0; } diff --git a/spine-haxe/spine-haxe/spine/animation/TransformConstraintTimeline.hx b/spine-haxe/spine-haxe/spine/animation/TransformConstraintTimeline.hx index 37b085555..2a86c303a 100644 --- a/spine-haxe/spine-haxe/spine/animation/TransformConstraintTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/TransformConstraintTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -54,7 +54,7 @@ class TransformConstraintTimeline extends CurveTimeline implements ConstraintTim return ENTRIES; } - public function getConstraintIndex () { + public function getConstraintIndex() { return constraintIndex; } @@ -72,11 +72,11 @@ class TransformConstraintTimeline extends CurveTimeline implements ConstraintTim frames[frame + SHEARY] = mixShearY; } - public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, - blend:MixBlend, direction:MixDirection, appliedPose:Bool) { - + public function apply(skeleton:Skeleton, lastTime:Float, time:Float, events:Array, alpha:Float, blend:MixBlend, direction:MixDirection, + appliedPose:Bool) { var constraint = cast(skeleton.constraints[constraintIndex], TransformConstraint); - if (!constraint.active) return; + if (!constraint.active) + return; var pose = appliedPose ? constraint.applied : constraint.pose; if (time < frames[0]) { diff --git a/spine-haxe/spine-haxe/spine/animation/TranslateTimeline.hx b/spine-haxe/spine-haxe/spine/animation/TranslateTimeline.hx index 14f9afc32..1ee08c6f6 100644 --- a/spine-haxe/spine-haxe/spine/animation/TranslateTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/TranslateTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -39,7 +39,7 @@ class TranslateTimeline extends BoneTimeline2 { super(frameCount, bezierCount, boneIndex, Property.x, Property.y); } - public function apply1 (pose:BoneLocal, setup:BoneLocal, time:Float, alpha:Float, blend:MixBlend, direction:MixDirection):Void { + public function apply1(pose:BoneLocal, setup:BoneLocal, time:Float, alpha:Float, blend:MixBlend, direction:MixDirection):Void { if (time < frames[0]) { switch (blend) { case MixBlend.setup: diff --git a/spine-haxe/spine-haxe/spine/animation/TranslateXTimeline.hx b/spine-haxe/spine-haxe/spine/animation/TranslateXTimeline.hx index 898d30423..f07535ef0 100644 --- a/spine-haxe/spine-haxe/spine/animation/TranslateXTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/TranslateXTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -40,7 +40,7 @@ class TranslateXTimeline extends BoneTimeline1 { this.boneIndex = boneIndex; } - public function apply1 (pose:BoneLocal, setup:BoneLocal, time:Float, alpha:Float, blend:MixBlend, direction:MixDirection) { + public function apply1(pose:BoneLocal, setup:BoneLocal, time:Float, alpha:Float, blend:MixBlend, direction:MixDirection) { pose.x = getRelativeValue(time, alpha, blend, pose.x, setup.x); } } diff --git a/spine-haxe/spine-haxe/spine/animation/TranslateYTimeline.hx b/spine-haxe/spine-haxe/spine/animation/TranslateYTimeline.hx index c85fe9e53..915bb62fb 100644 --- a/spine-haxe/spine-haxe/spine/animation/TranslateYTimeline.hx +++ b/spine-haxe/spine-haxe/spine/animation/TranslateYTimeline.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.animation; @@ -35,7 +35,7 @@ class TranslateYTimeline extends BoneTimeline1 { super(frameCount, bezierCount, boneIndex, Property.y); } - public function apply1 (pose:BoneLocal, setup:BoneLocal, time:Float, alpha:Float, blend:MixBlend, direction:MixDirection) { + public function apply1(pose:BoneLocal, setup:BoneLocal, time:Float, alpha:Float, blend:MixBlend, direction:MixDirection) { pose.y = getRelativeValue(time, alpha, blend, pose.y, setup.y); } } diff --git a/spine-haxe/spine-haxe/spine/atlas/Format.hx b/spine-haxe/spine-haxe/spine/atlas/Format.hx index 1049e7f30..92658dd1d 100644 --- a/spine-haxe/spine-haxe/spine/atlas/Format.hx +++ b/spine-haxe/spine-haxe/spine/atlas/Format.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.atlas; diff --git a/spine-haxe/spine-haxe/spine/atlas/TextureAtlas.hx b/spine-haxe/spine-haxe/spine/atlas/TextureAtlas.hx index d7c0e66bd..c138e97f3 100644 --- a/spine-haxe/spine-haxe/spine/atlas/TextureAtlas.hx +++ b/spine-haxe/spine-haxe/spine/atlas/TextureAtlas.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.atlas; diff --git a/spine-haxe/spine-haxe/spine/atlas/TextureAtlasPage.hx b/spine-haxe/spine-haxe/spine/atlas/TextureAtlasPage.hx index 07ea222d1..aa4e087ff 100644 --- a/spine-haxe/spine-haxe/spine/atlas/TextureAtlasPage.hx +++ b/spine-haxe/spine-haxe/spine/atlas/TextureAtlasPage.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.atlas; diff --git a/spine-haxe/spine-haxe/spine/atlas/TextureAtlasRegion.hx b/spine-haxe/spine-haxe/spine/atlas/TextureAtlasRegion.hx index ee93de1f1..450447cc3 100644 --- a/spine-haxe/spine-haxe/spine/atlas/TextureAtlasRegion.hx +++ b/spine-haxe/spine-haxe/spine/atlas/TextureAtlasRegion.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.atlas; diff --git a/spine-haxe/spine-haxe/spine/atlas/TextureFilter.hx b/spine-haxe/spine-haxe/spine/atlas/TextureFilter.hx index 00dfe54d9..a3d29f53c 100644 --- a/spine-haxe/spine-haxe/spine/atlas/TextureFilter.hx +++ b/spine-haxe/spine-haxe/spine/atlas/TextureFilter.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.atlas; diff --git a/spine-haxe/spine-haxe/spine/atlas/TextureLoader.hx b/spine-haxe/spine-haxe/spine/atlas/TextureLoader.hx index 04fd792bb..ccef44d05 100644 --- a/spine-haxe/spine-haxe/spine/atlas/TextureLoader.hx +++ b/spine-haxe/spine-haxe/spine/atlas/TextureLoader.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.atlas; diff --git a/spine-haxe/spine-haxe/spine/atlas/TextureWrap.hx b/spine-haxe/spine-haxe/spine/atlas/TextureWrap.hx index 014278e63..ef4692dc1 100644 --- a/spine-haxe/spine-haxe/spine/atlas/TextureWrap.hx +++ b/spine-haxe/spine-haxe/spine/atlas/TextureWrap.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.atlas; diff --git a/spine-haxe/spine-haxe/spine/attachments/AtlasAttachmentLoader.hx b/spine-haxe/spine-haxe/spine/attachments/AtlasAttachmentLoader.hx index b9e7a7e04..047c37924 100644 --- a/spine-haxe/spine-haxe/spine/attachments/AtlasAttachmentLoader.hx +++ b/spine-haxe/spine-haxe/spine/attachments/AtlasAttachmentLoader.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.attachments; diff --git a/spine-haxe/spine-haxe/spine/attachments/Attachment.hx b/spine-haxe/spine-haxe/spine/attachments/Attachment.hx index 81e3a7665..442bc7dff 100644 --- a/spine-haxe/spine-haxe/spine/attachments/Attachment.hx +++ b/spine-haxe/spine-haxe/spine/attachments/Attachment.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.attachments; diff --git a/spine-haxe/spine-haxe/spine/attachments/AttachmentLoader.hx b/spine-haxe/spine-haxe/spine/attachments/AttachmentLoader.hx index 147e124bb..ec4262e4f 100644 --- a/spine-haxe/spine-haxe/spine/attachments/AttachmentLoader.hx +++ b/spine-haxe/spine-haxe/spine/attachments/AttachmentLoader.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.attachments; diff --git a/spine-haxe/spine-haxe/spine/attachments/AttachmentType.hx b/spine-haxe/spine-haxe/spine/attachments/AttachmentType.hx index 52ca24857..ead1a92fa 100644 --- a/spine-haxe/spine-haxe/spine/attachments/AttachmentType.hx +++ b/spine-haxe/spine-haxe/spine/attachments/AttachmentType.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.attachments; diff --git a/spine-haxe/spine-haxe/spine/attachments/BoundingBoxAttachment.hx b/spine-haxe/spine-haxe/spine/attachments/BoundingBoxAttachment.hx index e799a6b4b..023d5c58a 100644 --- a/spine-haxe/spine-haxe/spine/attachments/BoundingBoxAttachment.hx +++ b/spine-haxe/spine-haxe/spine/attachments/BoundingBoxAttachment.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.attachments; diff --git a/spine-haxe/spine-haxe/spine/attachments/ClippingAttachment.hx b/spine-haxe/spine-haxe/spine/attachments/ClippingAttachment.hx index c2ff9604f..8d4022836 100644 --- a/spine-haxe/spine-haxe/spine/attachments/ClippingAttachment.hx +++ b/spine-haxe/spine-haxe/spine/attachments/ClippingAttachment.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.attachments; @@ -37,6 +37,7 @@ class ClippingAttachment extends VertexAttachment { /** Clipping is performed between the clipping attachment's slot and the end slot. If null clipping is done until the end of * the skeleton's rendering. */ public var endSlot:SlotData; + /** The color of the clipping attachment as it was in Spine, or a default color if nonessential data was not exported. Clipping * attachments are not usually rendered at runtime. */ public var color:Color = new Color(0.2275, 0.2275, 0.2275, 1); diff --git a/spine-haxe/spine-haxe/spine/attachments/MeshAttachment.hx b/spine-haxe/spine-haxe/spine/attachments/MeshAttachment.hx index 14e483d83..31d0285fa 100644 --- a/spine-haxe/spine-haxe/spine/attachments/MeshAttachment.hx +++ b/spine-haxe/spine-haxe/spine/attachments/MeshAttachment.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.attachments; @@ -40,23 +40,32 @@ import spine.atlas.TextureAtlasPage; class MeshAttachment extends VertexAttachment implements HasTextureRegion { public var region:TextureRegion; public var path:String; + /** The UV pair for each vertex, normalized within the texture region. */ public var regionUVs = new Array(); + /** The UV pair for each vertex, normalized within the entire texture. * See #updateRegion(). */ public var uvs = new Array(); + /** Triplets of vertex indices which describe the mesh's triangulation. */ public var triangles = new Array(); + public var color:Color = new Color(1, 1, 1, 1); + /** The width of the mesh's image, or zero if nonessential data was not exported. */ public var width:Float = 0; + /** The height of the mesh's image, or zero if nonessential data was not exported. */ public var height:Float = 0; + /** The number of entries at the beginning of #vertices that make up the mesh hull. */ public var hullLength:Int = 0; + /** Vertex index pairs describing edges for controlling triangulation, or null if nonessential data was not exported. Mesh * triangles will never cross edges. Triangulation is not performed at runtime. */ public var edges = new Array(); + public var rendererObject:Dynamic; public var sequence:Sequence; @@ -86,7 +95,8 @@ class MeshAttachment extends VertexAttachment implements HasTextureRegion { var n = uvs.length; var u = region.u, v = region.v, width:Float = 0, height:Float = 0; if (Std.isOfType(region, TextureAtlasRegion)) { - var atlasRegion:TextureAtlasRegion = cast(region, TextureAtlasRegion), page:TextureAtlasPage = atlasRegion.page; + var atlasRegion:TextureAtlasRegion = cast(region, TextureAtlasRegion), + page:TextureAtlasPage = atlasRegion.page; var textureWidth = page.width, textureHeight = page.height; switch (atlasRegion.degrees) { case 90: diff --git a/spine-haxe/spine-haxe/spine/attachments/PathAttachment.hx b/spine-haxe/spine-haxe/spine/attachments/PathAttachment.hx index 1843d4ccb..d007080fc 100644 --- a/spine-haxe/spine-haxe/spine/attachments/PathAttachment.hx +++ b/spine-haxe/spine-haxe/spine/attachments/PathAttachment.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.attachments; @@ -39,11 +39,14 @@ import spine.Color; class PathAttachment extends VertexAttachment { /** The lengths along the path in the setup pose from the start of the path to the end of each Bezier curve. */ public var lengths:Array; + /** If true, the start and end knots are connected. */ public var closed:Bool = false; + /** If true, additional calculations are performed to make computing positions along the path more accurate and movement along * the path have a constant speed. */ public var constantSpeed:Bool = false; + /** The color of the path as it was in Spine, or a default color if nonessential data was not exported. Paths are not usually * rendered at runtime. */ public var color:Color = new Color(0, 0, 0, 0); diff --git a/spine-haxe/spine-haxe/spine/attachments/PointAttachment.hx b/spine-haxe/spine-haxe/spine/attachments/PointAttachment.hx index 6e5872e66..7c1b677aa 100644 --- a/spine-haxe/spine-haxe/spine/attachments/PointAttachment.hx +++ b/spine-haxe/spine-haxe/spine/attachments/PointAttachment.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.attachments; @@ -42,6 +42,7 @@ class PointAttachment extends VertexAttachment { public var x:Float = 0; public var y:Float = 0; public var rotation:Float = 0; + /** The color of the point attachment as it was in Spine, or a default color if nonessential data was not exported. Point * attachments are not usually rendered at runtime. */ public var color:Color = new Color(0.38, 0.94, 0, 1); @@ -58,7 +59,9 @@ class PointAttachment extends VertexAttachment { } public function computeWorldRotation(bone:BonePose):Float { - var r:Float = this.rotation * MathUtils.degRad, cos:Float = Math.cos(r), sin:Float = Math.sin(r); + var r:Float = this.rotation * MathUtils.degRad, + cos:Float = Math.cos(r), + sin:Float = Math.sin(r); var x:Float = cos * bone.a + sin * bone.b; var y:Float = cos * bone.c + sin * bone.d; return MathUtils.atan2Deg(y, x); diff --git a/spine-haxe/spine-haxe/spine/attachments/RegionAttachment.hx b/spine-haxe/spine-haxe/spine/attachments/RegionAttachment.hx index cb1a867e1..332647118 100644 --- a/spine-haxe/spine-haxe/spine/attachments/RegionAttachment.hx +++ b/spine-haxe/spine-haxe/spine/attachments/RegionAttachment.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.attachments; @@ -47,18 +47,25 @@ class RegionAttachment extends Attachment implements HasTextureRegion { /** The local x translation. */ public var x:Float = 0; + /** The local y translation. */ public var y:Float = 0; + /** The local scaleX. */ public var scaleX:Float = 1; + /** The local scaleY. */ public var scaleY:Float = 1; + /** The local rotation. */ public var rotation:Float = 0; + /** The width of the region attachment in Spine. */ public var width:Float = 0; + /** The height of the region attachment in Spine. */ public var height:Float = 0; + public var color:Color = new Color(1, 1, 1, 1); public var path:String; public var rendererObject:Dynamic; @@ -150,7 +157,8 @@ class RegionAttachment extends Attachment implements HasTextureRegion { * @param offset The worldVertices index to begin writing values. * @param stride The number of worldVertices entries between the value pairs written. */ public function computeWorldVertices(slot:Slot, worldVertices:Array, offset:Int, stride:Int):Void { - if (sequence != null) sequence.apply(slot.applied, this); + if (sequence != null) + sequence.apply(slot.applied, this); var vertexOffset = this.offset; var bone = slot.bone.applied; diff --git a/spine-haxe/spine-haxe/spine/attachments/VertexAttachment.hx b/spine-haxe/spine-haxe/spine/attachments/VertexAttachment.hx index ffca2f6a9..ea2dfaf66 100644 --- a/spine-haxe/spine-haxe/spine/attachments/VertexAttachment.hx +++ b/spine-haxe/spine-haxe/spine/attachments/VertexAttachment.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.attachments; @@ -79,7 +79,8 @@ class VertexAttachment extends Attachment { var deform:Array = slot.applied.deform; var vertices = vertices; if (bones == null) { - if (deform.length > 0) vertices = deform; + if (deform.length > 0) + vertices = deform; var bone = slot.bone.applied; var x = bone.worldX, y = bone.worldY; var a = bone.a, b = bone.b, c = bone.c, d = bone.d; @@ -109,7 +110,9 @@ class VertexAttachment extends Attachment { n += v; while (v < n) { var bone = skeletonBones[bones[v]].applied; - var vx = vertices[b], vy = vertices[b + 1], weight = vertices[b + 2]; + var vx = vertices[b], + vy = vertices[b + 1], + weight = vertices[b + 2]; wx += (vx * bone.a + vy * bone.b + bone.worldX) * weight; wy += (vx * bone.c + vy * bone.d + bone.worldY) * weight; v++; @@ -127,7 +130,9 @@ class VertexAttachment extends Attachment { n += v; while (v < n) { var bone = skeletonBones[bones[v]].applied; - var vx = vertices[b] + deform[f], vy = vertices[b + 1] + deform[f + 1], weight = vertices[b + 2]; + var vx = vertices[b] + deform[f], + vy = vertices[b + 1] + deform[f + 1], + weight = vertices[b + 2]; wx += (vx * bone.a + vy * bone.b + bone.worldX) * weight; wy += (vx * bone.c + vy * bone.d + bone.worldY) * weight; v++; diff --git a/spine-haxe/spine-haxe/spine/flixel/FlixelTextureLoader.hx b/spine-haxe/spine-haxe/spine/flixel/FlixelTextureLoader.hx index 737fd91ad..3227e7f92 100644 --- a/spine-haxe/spine-haxe/spine/flixel/FlixelTextureLoader.hx +++ b/spine-haxe/spine-haxe/spine/flixel/FlixelTextureLoader.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.flixel; @@ -36,8 +36,7 @@ import spine.atlas.TextureAtlasRegion; import spine.atlas.TextureLoader; import spine.flixel.SpineTexture; -class FlixelTextureLoader implements TextureLoader -{ +class FlixelTextureLoader implements TextureLoader { private var basePath:String; public function new(prefix:String) { @@ -48,8 +47,7 @@ class FlixelTextureLoader implements TextureLoader } } - public function loadPage(page:TextureAtlasPage, path:String):Void - { + public function loadPage(page:TextureAtlasPage, path:String):Void { var bitmapData = openfl.utils.Assets.getBitmapData(basePath + "/" + path); if (bitmapData == null) { throw new SpineException("Could not load atlas page texture " + basePath + "/" + path); @@ -65,8 +63,7 @@ class FlixelTextureLoader implements TextureLoader region.texture = region.page.texture; } - public function unloadPage(page:TextureAtlasPage):Void - { + public function unloadPage(page:TextureAtlasPage):Void { FlxG.bitmap.remove(cast page.texture); } } diff --git a/spine-haxe/spine-haxe/spine/flixel/SkeletonMesh.hx b/spine-haxe/spine-haxe/spine/flixel/SkeletonMesh.hx index fffd5be30..461804b30 100644 --- a/spine-haxe/spine-haxe/spine/flixel/SkeletonMesh.hx +++ b/spine-haxe/spine-haxe/spine/flixel/SkeletonMesh.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.flixel; diff --git a/spine-haxe/spine-haxe/spine/flixel/SkeletonSprite.hx b/spine-haxe/spine-haxe/spine/flixel/SkeletonSprite.hx index 368de8653..7ee805b57 100644 --- a/spine-haxe/spine-haxe/spine/flixel/SkeletonSprite.hx +++ b/spine-haxe/spine-haxe/spine/flixel/SkeletonSprite.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.flixel; @@ -63,13 +63,13 @@ import spine.attachments.ClippingAttachment; import spine.flixel.SkeletonMesh; /** A FlxObject that draws a skeleton. The animation state and skeleton must be updated each frame. */ -class SkeletonSprite extends FlxObject -{ +class SkeletonSprite extends FlxObject { public var skeleton(default, null):Skeleton; public var state(default, null):AnimationState; public var stateData(default, null):AnimationStateData; - public var beforeUpdateWorldTransforms: SkeletonSprite -> Void = function(_) {}; - public var afterUpdateWorldTransforms: SkeletonSprite -> Void = function(_) {}; + public var beforeUpdateWorldTransforms:SkeletonSprite->Void = function(_) {}; + public var afterUpdateWorldTransforms:SkeletonSprite->Void = function(_) {}; + public static var clipper(default, never):SkeletonClipping = new SkeletonClipping(); public var offsetX = .0; @@ -93,9 +93,9 @@ class SkeletonSprite extends FlxObject private var _tempPoint = new Point(); private static var QUAD_INDICES:Array = [0, 1, 2, 2, 3, 0]; + /** Creates an uninitialized SkeletonSprite. The renderer, skeleton, and animation state must be set before use. */ - public function new(skeletonData:SkeletonData, animationStateData:AnimationStateData = null) - { + public function new(skeletonData:SkeletonData, animationStateData:AnimationStateData = null) { super(0, 0); Bone.yDown = true; skeleton = new Skeleton(skeletonData); @@ -114,17 +114,20 @@ class SkeletonSprite extends FlxObject } } - public function getAnimationBounds(animation:Animation, clip:Bool = true): lime.math.Rectangle { + public function getAnimationBounds(animation:Animation, clip:Bool = true):lime.math.Rectangle { var clipper = clip ? SkeletonSprite.clipper : null; skeleton.setupPose(); var steps = 100, time = 0.; var stepTime = animation.duration != 0 ? animation.duration / steps : 0; - var minX = 100000000., maxX = -100000000., minY = 100000000., maxY = -100000000.; + var minX = 100000000., + maxX = -100000000., + minY = 100000000., + maxY = -100000000.; var bounds = new lime.math.Rectangle(); for (i in 0...steps) { - animation.apply(skeleton, time , time, false, [], 1, MixBlend.setup, MixDirection.mixIn, false); + animation.apply(skeleton, time, time, false, [], 1, MixBlend.setup, MixDirection.mixIn, false); skeleton.updateWorldTransform(Physics.update); bounds = skeleton.getBounds(clipper); @@ -145,8 +148,7 @@ class SkeletonSprite extends FlxObject return bounds; } - override public function destroy():Void - { + override public function destroy():Void { state.clearListeners(); state = null; skeleton = null; @@ -157,15 +159,15 @@ class SkeletonSprite extends FlxObject _tempPoint = null; if (_meshes != null) { - for (mesh in _meshes) mesh.destroy(); + for (mesh in _meshes) + mesh.destroy(); _meshes = null; } super.destroy(); } - override public function update(elapsed:Float):Void - { + override public function update(elapsed:Float):Void { super.update(elapsed); state.update(elapsed); state.apply(skeleton); @@ -175,14 +177,15 @@ class SkeletonSprite extends FlxObject this.afterUpdateWorldTransforms(this); } - override public function draw():Void - { - if (alpha == 0) return; + override public function draw():Void { + if (alpha == 0) + return; renderMeshes(); #if FLX_DEBUG - if (FlxG.debugger.drawDebug) drawDebug(); + if (FlxG.debugger.drawDebug) + drawDebug(); #end } @@ -248,14 +251,10 @@ class SkeletonSprite extends FlxObject } if (mesh != null) { - // cannot use directly mesh.color.setRGBFloat otherwise the setter won't be called and transfor color not set - mesh.color = FlxColor.fromRGBFloat( - skeleton.color.r * pose.color.r * attachmentColor.r * color.redFloat, + mesh.color = FlxColor.fromRGBFloat(skeleton.color.r * pose.color.r * attachmentColor.r * color.redFloat, skeleton.color.g * pose.color.g * attachmentColor.g * color.greenFloat, - skeleton.color.b * pose.color.b * attachmentColor.b * color.blueFloat, - 1 - ); + skeleton.color.b * pose.color.b * attachmentColor.b * color.blueFloat, 1); mesh.alpha = skeleton.color.a * pose.color.a * attachmentColor.a * alpha; if (clipper.isClipping() && clipper.clipTriangles(worldVertices, triangles, triangles.length, uvs)) { @@ -273,7 +272,7 @@ class SkeletonSprite extends FlxObject _tempPoint = _tempMatrix.transformPoint(_tempPoint); mesh.vertices[i] = _tempPoint.x; mesh.vertices[i + 1] = _tempPoint.y; - i+=2; + i += 2; } } } else { @@ -320,7 +319,7 @@ class SkeletonSprite extends FlxObject _tempMatrix.identity(); // scale is connected to the skeleton scale - no need to rescale _tempMatrix.scale(1, 1); - _tempMatrix.rotate(angle * Math.PI / 180); + _tempMatrix.rotate(angle * Math.PI / 180); _tempMatrix.translate(x + offsetX, y + offsetY); return _tempMatrix; } @@ -333,10 +332,10 @@ class SkeletonSprite extends FlxObject d = transform.d, tx = transform.tx, ty = transform.ty; - var x = point[0]; - var y = point[1]; - point[0] = x * a + y * c + tx; - point[1] = x * b + y * d + ty; + var x = point[0]; + var y = point[1]; + point[0] = x * a + y * c + tx; + point[1] = x * b + y * d + ty; } public function haxeWorldCoordinatesToSkeleton(point:Array):Void { @@ -353,7 +352,7 @@ class SkeletonSprite extends FlxObject point[1] = x * b + y * d + ty; } - public function haxeWorldCoordinatesToBone(point:Array, bone: Bone):Void { + public function haxeWorldCoordinatesToBone(point:Array, bone:Bone):Void { this.haxeWorldCoordinatesToSkeleton(point); var parentBone = bone.parent; if (parentBone != null) { @@ -363,7 +362,7 @@ class SkeletonSprite extends FlxObject } } - private function getFlixelMeshFromRendererAttachment(region: RenderedAttachment) { + private function getFlixelMeshFromRendererAttachment(region:RenderedAttachment) { if (region.rendererObject == null) { var skeletonMesh = new SkeletonMesh(); region.rendererObject = skeletonMesh; @@ -373,15 +372,15 @@ class SkeletonSprite extends FlxObject return region.rendererObject; } - function set_flipX(value:Bool):Bool - { - if (value != flipX) skeleton.scaleX = -skeleton.scaleX; + function set_flipX(value:Bool):Bool { + if (value != flipX) + skeleton.scaleX = -skeleton.scaleX; return flipX = value; } - function set_flipY(value:Bool):Bool - { - if (value != flipY) skeleton.scaleY = -skeleton.scaleY; + function set_flipY(value:Bool):Bool { + if (value != flipY) + skeleton.scaleY = -skeleton.scaleY; return flipY = value; } @@ -404,7 +403,6 @@ class SkeletonSprite extends FlxObject function set_scaleY(value:Float):Float { return skeleton.scaleY = value; } - } typedef RenderedAttachment = { diff --git a/spine-haxe/spine-haxe/spine/flixel/SpineTexture.hx b/spine-haxe/spine-haxe/spine/flixel/SpineTexture.hx index 5aa5b964c..75b75bcaf 100644 --- a/spine-haxe/spine-haxe/spine/flixel/SpineTexture.hx +++ b/spine-haxe/spine-haxe/spine/flixel/SpineTexture.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.flixel; @@ -33,13 +33,12 @@ import flixel.FlxG; import flixel.graphics.FlxGraphic; import openfl.display.BlendMode; -class SpineTexture extends FlxGraphic -{ - public static function from(bitmapData: openfl.display.BitmapData): FlxGraphic { +class SpineTexture extends FlxGraphic { + public static function from(bitmapData:openfl.display.BitmapData):FlxGraphic { return FlxG.bitmap.add(bitmapData); } - public static function toFlixelBlending (blend: spine.BlendMode): BlendMode { + public static function toFlixelBlending(blend:spine.BlendMode):BlendMode { switch (blend) { case spine.BlendMode.normal: return BlendMode.NORMAL; @@ -55,5 +54,4 @@ class SpineTexture extends FlxGraphic } return BlendMode.NORMAL; } - } diff --git a/spine-haxe/spine-haxe/spine/starling/SkeletonMesh.hx b/spine-haxe/spine-haxe/spine/starling/SkeletonMesh.hx index 95d03777b..d7e56dfbe 100644 --- a/spine-haxe/spine-haxe/spine/starling/SkeletonMesh.hx +++ b/spine-haxe/spine-haxe/spine/starling/SkeletonMesh.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.starling; diff --git a/spine-haxe/spine-haxe/spine/starling/SkeletonSprite.hx b/spine-haxe/spine-haxe/spine/starling/SkeletonSprite.hx index dcee4a173..0cffae9b2 100644 --- a/spine-haxe/spine-haxe/spine/starling/SkeletonSprite.hx +++ b/spine-haxe/spine-haxe/spine/starling/SkeletonSprite.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.starling; @@ -76,8 +76,8 @@ class SkeletonSprite extends DisplayObject implements IAnimatable { private var tempLight:spine.Color = new spine.Color(0, 0, 0); private var tempDark:spine.Color = new spine.Color(0, 0, 0); - public var beforeUpdateWorldTransforms: SkeletonSprite -> Void = function(_) {}; - public var afterUpdateWorldTransforms: SkeletonSprite -> Void = function(_) {}; + public var beforeUpdateWorldTransforms:SkeletonSprite->Void = function(_) {}; + public var afterUpdateWorldTransforms:SkeletonSprite->Void = function(_) {}; /** Creates an uninitialized SkeletonSprite. The skeleton and animation state must be set before use. */ public function new(skeletonData:SkeletonData, animationStateData:AnimationStateData = null) { @@ -324,17 +324,20 @@ class SkeletonSprite extends DisplayObject implements IAnimatable { return resultRect; } - public function getAnimationBounds(animation:Animation, clip:Bool = true): Rectangle { + public function getAnimationBounds(animation:Animation, clip:Bool = true):Rectangle { var clipper = clip ? SkeletonSprite.clipper : null; _skeleton.setupPose(); var steps = 100, time = 0.; var stepTime = animation.duration != 0 ? animation.duration / steps : 0; - var minX = 100000000., maxX = -100000000., minY = 100000000., maxY = -100000000.; + var minX = 100000000., + maxX = -100000000., + minY = 100000000., + maxY = -100000000.; var bound:lime.math.Rectangle; for (i in 0...steps) { - animation.apply(_skeleton, time , time, false, [], 1, MixBlend.setup, MixDirection.mixIn, false); + animation.apply(_skeleton, time, time, false, [], 1, MixBlend.setup, MixDirection.mixIn, false); _skeleton.updateWorldTransform(Physics.update); bound = _skeleton.getBounds(clipper); @@ -392,10 +395,10 @@ class SkeletonSprite extends DisplayObject implements IAnimatable { d = transform.d, tx = transform.tx, ty = transform.ty; - var x = point[0]; - var y = point[1]; - point[0] = x * a + y * c + tx; - point[1] = x * b + y * d + ty; + var x = point[0]; + var y = point[1]; + point[0] = x * a + y * c + tx; + point[1] = x * b + y * d + ty; } public function haxeWorldCoordinatesToSkeleton(point:Array):Void { @@ -412,7 +415,7 @@ class SkeletonSprite extends DisplayObject implements IAnimatable { point[1] = x * b + y * d + ty; } - public function haxeWorldCoordinatesToBone(point:Array, bone: Bone):Void { + public function haxeWorldCoordinatesToBone(point:Array, bone:Bone):Void { this.haxeWorldCoordinatesToSkeleton(point); var parentBone = bone.parent; if (parentBone != null) { @@ -427,7 +430,8 @@ class SkeletonSprite extends DisplayObject implements IAnimatable { _state.clearListeners(); _state = null; } - if (_skeleton != null) _skeleton = null; + if (_skeleton != null) + _skeleton = null; dispatchEventWith(starling.events.Event.REMOVE_FROM_JUGGLER); removeFromParent(); diff --git a/spine-haxe/spine-haxe/spine/starling/StarlingTextureLoader.hx b/spine-haxe/spine-haxe/spine/starling/StarlingTextureLoader.hx index c3b04a08f..e243482c1 100644 --- a/spine-haxe/spine-haxe/spine/starling/StarlingTextureLoader.hx +++ b/spine-haxe/spine-haxe/spine/starling/StarlingTextureLoader.hx @@ -25,7 +25,7 @@ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - *****************************************************************************/ +*****************************************************************************/ package spine.starling; diff --git a/spine-libgdx/spine-libgdx-tests/src/com/esotericsoftware/spine/utils/SkeletonSerializer.java b/spine-libgdx/spine-libgdx-tests/src/com/esotericsoftware/spine/utils/SkeletonSerializer.java index 0987962e3..90b9bc51e 100644 --- a/spine-libgdx/spine-libgdx-tests/src/com/esotericsoftware/spine/utils/SkeletonSerializer.java +++ b/spine-libgdx/spine-libgdx-tests/src/com/esotericsoftware/spine/utils/SkeletonSerializer.java @@ -1,3 +1,4 @@ + package com.esotericsoftware.spine.utils; import com.esotericsoftware.spine.*; @@ -19,3847 +20,3847 @@ import java.util.Set; import java.util.HashSet; public class SkeletonSerializer { - private final Set visitedObjects = new HashSet<>(); - private JsonWriter json; - - public String serializeSkeletonData(SkeletonData data) { - visitedObjects.clear(); - json = new JsonWriter(); - writeSkeletonData(data); - json.close(); - return json.getString(); - } - - public String serializeSkeleton(Skeleton skeleton) { - visitedObjects.clear(); - json = new JsonWriter(); - writeSkeleton(skeleton); - json.close(); - return json.getString(); - } - - public String serializeAnimationState(AnimationState state) { - visitedObjects.clear(); - json = new JsonWriter(); - writeAnimationState(state); - json.close(); - return json.getString(); - } - - private void writeAnimation(Animation obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("Animation"); - - json.writeName("timelines"); - json.writeArrayStart(); - for (Timeline item : obj.getTimelines()) { - writeTimeline(item); - } - json.writeArrayEnd(); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeName("bones"); - writeIntArray(obj.getBones()); - - json.writeName("name"); - json.writeValue(obj.getName()); - - json.writeObjectEnd(); - } - - private void writeAlphaTimeline(Animation.AlphaTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("AlphaTimeline"); - - json.writeName("slotIndex"); - json.writeValue(obj.getSlotIndex()); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writeAttachmentTimeline(Animation.AttachmentTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("AttachmentTimeline"); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("slotIndex"); - json.writeValue(obj.getSlotIndex()); - - json.writeName("attachmentNames"); - json.writeArrayStart(); - for (String item : obj.getAttachmentNames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writeDeformTimeline(Animation.DeformTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("DeformTimeline"); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("attachment"); - writeVertexAttachment(obj.getAttachment()); - - json.writeName("vertices"); - json.writeArrayStart(); - for (float[] nestedArray : obj.getVertices()) { - json.writeArrayStart(); - for (float elem : nestedArray) { - json.writeValue(elem); - } - json.writeArrayEnd(); - } - json.writeArrayEnd(); - - json.writeName("slotIndex"); - json.writeValue(obj.getSlotIndex()); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writeDrawOrderTimeline(Animation.DrawOrderTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("DrawOrderTimeline"); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("drawOrders"); - json.writeArrayStart(); - for (int[] nestedArray : obj.getDrawOrders()) { - json.writeArrayStart(); - for (int elem : nestedArray) { - json.writeValue(elem); - } - json.writeArrayEnd(); - } - json.writeArrayEnd(); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writeEventTimeline(Animation.EventTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("EventTimeline"); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("events"); - json.writeArrayStart(); - for (Event item : obj.getEvents()) { - writeEvent(item); - } - json.writeArrayEnd(); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writeIkConstraintTimeline(Animation.IkConstraintTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("IkConstraintTimeline"); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("constraintIndex"); - json.writeValue(obj.getConstraintIndex()); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writeInheritTimeline(Animation.InheritTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("InheritTimeline"); - - json.writeName("boneIndex"); - json.writeValue(obj.getBoneIndex()); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writePathConstraintMixTimeline(Animation.PathConstraintMixTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("PathConstraintMixTimeline"); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("constraintIndex"); - json.writeValue(obj.getConstraintIndex()); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writePathConstraintPositionTimeline(Animation.PathConstraintPositionTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("PathConstraintPositionTimeline"); - - json.writeName("constraintIndex"); - json.writeValue(obj.getConstraintIndex()); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writePathConstraintSpacingTimeline(Animation.PathConstraintSpacingTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("PathConstraintSpacingTimeline"); - - json.writeName("constraintIndex"); - json.writeValue(obj.getConstraintIndex()); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writePhysicsConstraintDampingTimeline(Animation.PhysicsConstraintDampingTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("PhysicsConstraintDampingTimeline"); - - json.writeName("constraintIndex"); - json.writeValue(obj.getConstraintIndex()); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writePhysicsConstraintGravityTimeline(Animation.PhysicsConstraintGravityTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("PhysicsConstraintGravityTimeline"); - - json.writeName("constraintIndex"); - json.writeValue(obj.getConstraintIndex()); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writePhysicsConstraintInertiaTimeline(Animation.PhysicsConstraintInertiaTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("PhysicsConstraintInertiaTimeline"); - - json.writeName("constraintIndex"); - json.writeValue(obj.getConstraintIndex()); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writePhysicsConstraintMassTimeline(Animation.PhysicsConstraintMassTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("PhysicsConstraintMassTimeline"); - - json.writeName("constraintIndex"); - json.writeValue(obj.getConstraintIndex()); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writePhysicsConstraintMixTimeline(Animation.PhysicsConstraintMixTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("PhysicsConstraintMixTimeline"); - - json.writeName("constraintIndex"); - json.writeValue(obj.getConstraintIndex()); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writePhysicsConstraintResetTimeline(Animation.PhysicsConstraintResetTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("PhysicsConstraintResetTimeline"); - - json.writeName("constraintIndex"); - json.writeValue(obj.getConstraintIndex()); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writePhysicsConstraintStrengthTimeline(Animation.PhysicsConstraintStrengthTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("PhysicsConstraintStrengthTimeline"); - - json.writeName("constraintIndex"); - json.writeValue(obj.getConstraintIndex()); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writePhysicsConstraintWindTimeline(Animation.PhysicsConstraintWindTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("PhysicsConstraintWindTimeline"); - - json.writeName("constraintIndex"); - json.writeValue(obj.getConstraintIndex()); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writeRGB2Timeline(Animation.RGB2Timeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("RGB2Timeline"); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("slotIndex"); - json.writeValue(obj.getSlotIndex()); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writeRGBA2Timeline(Animation.RGBA2Timeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("RGBA2Timeline"); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("slotIndex"); - json.writeValue(obj.getSlotIndex()); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writeRGBATimeline(Animation.RGBATimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("RGBATimeline"); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("slotIndex"); - json.writeValue(obj.getSlotIndex()); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writeRGBTimeline(Animation.RGBTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("RGBTimeline"); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("slotIndex"); - json.writeValue(obj.getSlotIndex()); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writeRotateTimeline(Animation.RotateTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("RotateTimeline"); - - json.writeName("boneIndex"); - json.writeValue(obj.getBoneIndex()); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writeScaleTimeline(Animation.ScaleTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("ScaleTimeline"); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("boneIndex"); - json.writeValue(obj.getBoneIndex()); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writeScaleXTimeline(Animation.ScaleXTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("ScaleXTimeline"); - - json.writeName("boneIndex"); - json.writeValue(obj.getBoneIndex()); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writeScaleYTimeline(Animation.ScaleYTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("ScaleYTimeline"); - - json.writeName("boneIndex"); - json.writeValue(obj.getBoneIndex()); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writeSequenceTimeline(Animation.SequenceTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("SequenceTimeline"); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("slotIndex"); - json.writeValue(obj.getSlotIndex()); - - json.writeName("attachment"); - writeAttachment(obj.getAttachment()); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writeShearTimeline(Animation.ShearTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("ShearTimeline"); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("boneIndex"); - json.writeValue(obj.getBoneIndex()); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writeShearXTimeline(Animation.ShearXTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("ShearXTimeline"); - - json.writeName("boneIndex"); - json.writeValue(obj.getBoneIndex()); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writeShearYTimeline(Animation.ShearYTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("ShearYTimeline"); - - json.writeName("boneIndex"); - json.writeValue(obj.getBoneIndex()); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writeSliderMixTimeline(Animation.SliderMixTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("SliderMixTimeline"); - - json.writeName("constraintIndex"); - json.writeValue(obj.getConstraintIndex()); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writeSliderTimeline(Animation.SliderTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("SliderTimeline"); - - json.writeName("constraintIndex"); - json.writeValue(obj.getConstraintIndex()); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writeTimeline(Animation.Timeline obj) { - if (obj instanceof Animation.AlphaTimeline) { - writeAlphaTimeline((Animation.AlphaTimeline) obj); - } else if (obj instanceof Animation.AttachmentTimeline) { - writeAttachmentTimeline((Animation.AttachmentTimeline) obj); - } else if (obj instanceof Animation.DeformTimeline) { - writeDeformTimeline((Animation.DeformTimeline) obj); - } else if (obj instanceof Animation.DrawOrderTimeline) { - writeDrawOrderTimeline((Animation.DrawOrderTimeline) obj); - } else if (obj instanceof Animation.EventTimeline) { - writeEventTimeline((Animation.EventTimeline) obj); - } else if (obj instanceof Animation.IkConstraintTimeline) { - writeIkConstraintTimeline((Animation.IkConstraintTimeline) obj); - } else if (obj instanceof Animation.InheritTimeline) { - writeInheritTimeline((Animation.InheritTimeline) obj); - } else if (obj instanceof Animation.PathConstraintMixTimeline) { - writePathConstraintMixTimeline((Animation.PathConstraintMixTimeline) obj); - } else if (obj instanceof Animation.PathConstraintPositionTimeline) { - writePathConstraintPositionTimeline((Animation.PathConstraintPositionTimeline) obj); - } else if (obj instanceof Animation.PathConstraintSpacingTimeline) { - writePathConstraintSpacingTimeline((Animation.PathConstraintSpacingTimeline) obj); - } else if (obj instanceof Animation.PhysicsConstraintDampingTimeline) { - writePhysicsConstraintDampingTimeline((Animation.PhysicsConstraintDampingTimeline) obj); - } else if (obj instanceof Animation.PhysicsConstraintGravityTimeline) { - writePhysicsConstraintGravityTimeline((Animation.PhysicsConstraintGravityTimeline) obj); - } else if (obj instanceof Animation.PhysicsConstraintInertiaTimeline) { - writePhysicsConstraintInertiaTimeline((Animation.PhysicsConstraintInertiaTimeline) obj); - } else if (obj instanceof Animation.PhysicsConstraintMassTimeline) { - writePhysicsConstraintMassTimeline((Animation.PhysicsConstraintMassTimeline) obj); - } else if (obj instanceof Animation.PhysicsConstraintMixTimeline) { - writePhysicsConstraintMixTimeline((Animation.PhysicsConstraintMixTimeline) obj); - } else if (obj instanceof Animation.PhysicsConstraintResetTimeline) { - writePhysicsConstraintResetTimeline((Animation.PhysicsConstraintResetTimeline) obj); - } else if (obj instanceof Animation.PhysicsConstraintStrengthTimeline) { - writePhysicsConstraintStrengthTimeline((Animation.PhysicsConstraintStrengthTimeline) obj); - } else if (obj instanceof Animation.PhysicsConstraintWindTimeline) { - writePhysicsConstraintWindTimeline((Animation.PhysicsConstraintWindTimeline) obj); - } else if (obj instanceof Animation.RGB2Timeline) { - writeRGB2Timeline((Animation.RGB2Timeline) obj); - } else if (obj instanceof Animation.RGBA2Timeline) { - writeRGBA2Timeline((Animation.RGBA2Timeline) obj); - } else if (obj instanceof Animation.RGBATimeline) { - writeRGBATimeline((Animation.RGBATimeline) obj); - } else if (obj instanceof Animation.RGBTimeline) { - writeRGBTimeline((Animation.RGBTimeline) obj); - } else if (obj instanceof Animation.RotateTimeline) { - writeRotateTimeline((Animation.RotateTimeline) obj); - } else if (obj instanceof Animation.ScaleTimeline) { - writeScaleTimeline((Animation.ScaleTimeline) obj); - } else if (obj instanceof Animation.ScaleXTimeline) { - writeScaleXTimeline((Animation.ScaleXTimeline) obj); - } else if (obj instanceof Animation.ScaleYTimeline) { - writeScaleYTimeline((Animation.ScaleYTimeline) obj); - } else if (obj instanceof Animation.SequenceTimeline) { - writeSequenceTimeline((Animation.SequenceTimeline) obj); - } else if (obj instanceof Animation.ShearTimeline) { - writeShearTimeline((Animation.ShearTimeline) obj); - } else if (obj instanceof Animation.ShearXTimeline) { - writeShearXTimeline((Animation.ShearXTimeline) obj); - } else if (obj instanceof Animation.ShearYTimeline) { - writeShearYTimeline((Animation.ShearYTimeline) obj); - } else if (obj instanceof Animation.SliderMixTimeline) { - writeSliderMixTimeline((Animation.SliderMixTimeline) obj); - } else if (obj instanceof Animation.SliderTimeline) { - writeSliderTimeline((Animation.SliderTimeline) obj); - } else if (obj instanceof Animation.TransformConstraintTimeline) { - writeTransformConstraintTimeline((Animation.TransformConstraintTimeline) obj); - } else if (obj instanceof Animation.TranslateTimeline) { - writeTranslateTimeline((Animation.TranslateTimeline) obj); - } else if (obj instanceof Animation.TranslateXTimeline) { - writeTranslateXTimeline((Animation.TranslateXTimeline) obj); - } else if (obj instanceof Animation.TranslateYTimeline) { - writeTranslateYTimeline((Animation.TranslateYTimeline) obj); - } else { - throw new RuntimeException("Unknown Timeline type: " + obj.getClass().getName()); - } - } - - private void writeTransformConstraintTimeline(Animation.TransformConstraintTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("TransformConstraintTimeline"); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("constraintIndex"); - json.writeValue(obj.getConstraintIndex()); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writeTranslateTimeline(Animation.TranslateTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("TranslateTimeline"); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("boneIndex"); - json.writeValue(obj.getBoneIndex()); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writeTranslateXTimeline(Animation.TranslateXTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("TranslateXTimeline"); - - json.writeName("boneIndex"); - json.writeValue(obj.getBoneIndex()); - - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); - - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); - - json.writeName("duration"); - json.writeValue(obj.getDuration()); - - json.writeObjectEnd(); - } - - private void writeTranslateYTimeline(Animation.TranslateYTimeline obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("TranslateYTimeline"); + private final Set visitedObjects = new HashSet<>(); + private JsonWriter json; + + public String serializeSkeletonData (SkeletonData data) { + visitedObjects.clear(); + json = new JsonWriter(); + writeSkeletonData(data); + json.close(); + return json.getString(); + } + + public String serializeSkeleton (Skeleton skeleton) { + visitedObjects.clear(); + json = new JsonWriter(); + writeSkeleton(skeleton); + json.close(); + return json.getString(); + } + + public String serializeAnimationState (AnimationState state) { + visitedObjects.clear(); + json = new JsonWriter(); + writeAnimationState(state); + json.close(); + return json.getString(); + } + + private void writeAnimation (Animation obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("Animation"); + + json.writeName("timelines"); + json.writeArrayStart(); + for (Timeline item : obj.getTimelines()) { + writeTimeline(item); + } + json.writeArrayEnd(); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeName("bones"); + writeIntArray(obj.getBones()); + + json.writeName("name"); + json.writeValue(obj.getName()); + + json.writeObjectEnd(); + } + + private void writeAlphaTimeline (Animation.AlphaTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("AlphaTimeline"); + + json.writeName("slotIndex"); + json.writeValue(obj.getSlotIndex()); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writeAttachmentTimeline (Animation.AttachmentTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("AttachmentTimeline"); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("slotIndex"); + json.writeValue(obj.getSlotIndex()); + + json.writeName("attachmentNames"); + json.writeArrayStart(); + for (String item : obj.getAttachmentNames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writeDeformTimeline (Animation.DeformTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("DeformTimeline"); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("attachment"); + writeVertexAttachment(obj.getAttachment()); + + json.writeName("vertices"); + json.writeArrayStart(); + for (float[] nestedArray : obj.getVertices()) { + json.writeArrayStart(); + for (float elem : nestedArray) { + json.writeValue(elem); + } + json.writeArrayEnd(); + } + json.writeArrayEnd(); + + json.writeName("slotIndex"); + json.writeValue(obj.getSlotIndex()); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writeDrawOrderTimeline (Animation.DrawOrderTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("DrawOrderTimeline"); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("drawOrders"); + json.writeArrayStart(); + for (int[] nestedArray : obj.getDrawOrders()) { + json.writeArrayStart(); + for (int elem : nestedArray) { + json.writeValue(elem); + } + json.writeArrayEnd(); + } + json.writeArrayEnd(); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writeEventTimeline (Animation.EventTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("EventTimeline"); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("events"); + json.writeArrayStart(); + for (Event item : obj.getEvents()) { + writeEvent(item); + } + json.writeArrayEnd(); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writeIkConstraintTimeline (Animation.IkConstraintTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("IkConstraintTimeline"); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("constraintIndex"); + json.writeValue(obj.getConstraintIndex()); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writeInheritTimeline (Animation.InheritTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("InheritTimeline"); + + json.writeName("boneIndex"); + json.writeValue(obj.getBoneIndex()); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writePathConstraintMixTimeline (Animation.PathConstraintMixTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("PathConstraintMixTimeline"); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("constraintIndex"); + json.writeValue(obj.getConstraintIndex()); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writePathConstraintPositionTimeline (Animation.PathConstraintPositionTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("PathConstraintPositionTimeline"); + + json.writeName("constraintIndex"); + json.writeValue(obj.getConstraintIndex()); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writePathConstraintSpacingTimeline (Animation.PathConstraintSpacingTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("PathConstraintSpacingTimeline"); + + json.writeName("constraintIndex"); + json.writeValue(obj.getConstraintIndex()); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writePhysicsConstraintDampingTimeline (Animation.PhysicsConstraintDampingTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("PhysicsConstraintDampingTimeline"); + + json.writeName("constraintIndex"); + json.writeValue(obj.getConstraintIndex()); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writePhysicsConstraintGravityTimeline (Animation.PhysicsConstraintGravityTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("PhysicsConstraintGravityTimeline"); + + json.writeName("constraintIndex"); + json.writeValue(obj.getConstraintIndex()); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writePhysicsConstraintInertiaTimeline (Animation.PhysicsConstraintInertiaTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("PhysicsConstraintInertiaTimeline"); + + json.writeName("constraintIndex"); + json.writeValue(obj.getConstraintIndex()); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writePhysicsConstraintMassTimeline (Animation.PhysicsConstraintMassTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("PhysicsConstraintMassTimeline"); + + json.writeName("constraintIndex"); + json.writeValue(obj.getConstraintIndex()); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writePhysicsConstraintMixTimeline (Animation.PhysicsConstraintMixTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("PhysicsConstraintMixTimeline"); + + json.writeName("constraintIndex"); + json.writeValue(obj.getConstraintIndex()); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writePhysicsConstraintResetTimeline (Animation.PhysicsConstraintResetTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("PhysicsConstraintResetTimeline"); + + json.writeName("constraintIndex"); + json.writeValue(obj.getConstraintIndex()); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writePhysicsConstraintStrengthTimeline (Animation.PhysicsConstraintStrengthTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("PhysicsConstraintStrengthTimeline"); + + json.writeName("constraintIndex"); + json.writeValue(obj.getConstraintIndex()); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writePhysicsConstraintWindTimeline (Animation.PhysicsConstraintWindTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("PhysicsConstraintWindTimeline"); + + json.writeName("constraintIndex"); + json.writeValue(obj.getConstraintIndex()); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writeRGB2Timeline (Animation.RGB2Timeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("RGB2Timeline"); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("slotIndex"); + json.writeValue(obj.getSlotIndex()); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writeRGBA2Timeline (Animation.RGBA2Timeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("RGBA2Timeline"); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("slotIndex"); + json.writeValue(obj.getSlotIndex()); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writeRGBATimeline (Animation.RGBATimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("RGBATimeline"); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("slotIndex"); + json.writeValue(obj.getSlotIndex()); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writeRGBTimeline (Animation.RGBTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("RGBTimeline"); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("slotIndex"); + json.writeValue(obj.getSlotIndex()); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writeRotateTimeline (Animation.RotateTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("RotateTimeline"); + + json.writeName("boneIndex"); + json.writeValue(obj.getBoneIndex()); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writeScaleTimeline (Animation.ScaleTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("ScaleTimeline"); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("boneIndex"); + json.writeValue(obj.getBoneIndex()); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writeScaleXTimeline (Animation.ScaleXTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("ScaleXTimeline"); + + json.writeName("boneIndex"); + json.writeValue(obj.getBoneIndex()); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writeScaleYTimeline (Animation.ScaleYTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("ScaleYTimeline"); + + json.writeName("boneIndex"); + json.writeValue(obj.getBoneIndex()); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writeSequenceTimeline (Animation.SequenceTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("SequenceTimeline"); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("slotIndex"); + json.writeValue(obj.getSlotIndex()); + + json.writeName("attachment"); + writeAttachment(obj.getAttachment()); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writeShearTimeline (Animation.ShearTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("ShearTimeline"); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("boneIndex"); + json.writeValue(obj.getBoneIndex()); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writeShearXTimeline (Animation.ShearXTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("ShearXTimeline"); + + json.writeName("boneIndex"); + json.writeValue(obj.getBoneIndex()); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writeShearYTimeline (Animation.ShearYTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("ShearYTimeline"); + + json.writeName("boneIndex"); + json.writeValue(obj.getBoneIndex()); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writeSliderMixTimeline (Animation.SliderMixTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("SliderMixTimeline"); + + json.writeName("constraintIndex"); + json.writeValue(obj.getConstraintIndex()); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writeSliderTimeline (Animation.SliderTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("SliderTimeline"); + + json.writeName("constraintIndex"); + json.writeValue(obj.getConstraintIndex()); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writeTimeline (Animation.Timeline obj) { + if (obj instanceof Animation.AlphaTimeline) { + writeAlphaTimeline((Animation.AlphaTimeline)obj); + } else if (obj instanceof Animation.AttachmentTimeline) { + writeAttachmentTimeline((Animation.AttachmentTimeline)obj); + } else if (obj instanceof Animation.DeformTimeline) { + writeDeformTimeline((Animation.DeformTimeline)obj); + } else if (obj instanceof Animation.DrawOrderTimeline) { + writeDrawOrderTimeline((Animation.DrawOrderTimeline)obj); + } else if (obj instanceof Animation.EventTimeline) { + writeEventTimeline((Animation.EventTimeline)obj); + } else if (obj instanceof Animation.IkConstraintTimeline) { + writeIkConstraintTimeline((Animation.IkConstraintTimeline)obj); + } else if (obj instanceof Animation.InheritTimeline) { + writeInheritTimeline((Animation.InheritTimeline)obj); + } else if (obj instanceof Animation.PathConstraintMixTimeline) { + writePathConstraintMixTimeline((Animation.PathConstraintMixTimeline)obj); + } else if (obj instanceof Animation.PathConstraintPositionTimeline) { + writePathConstraintPositionTimeline((Animation.PathConstraintPositionTimeline)obj); + } else if (obj instanceof Animation.PathConstraintSpacingTimeline) { + writePathConstraintSpacingTimeline((Animation.PathConstraintSpacingTimeline)obj); + } else if (obj instanceof Animation.PhysicsConstraintDampingTimeline) { + writePhysicsConstraintDampingTimeline((Animation.PhysicsConstraintDampingTimeline)obj); + } else if (obj instanceof Animation.PhysicsConstraintGravityTimeline) { + writePhysicsConstraintGravityTimeline((Animation.PhysicsConstraintGravityTimeline)obj); + } else if (obj instanceof Animation.PhysicsConstraintInertiaTimeline) { + writePhysicsConstraintInertiaTimeline((Animation.PhysicsConstraintInertiaTimeline)obj); + } else if (obj instanceof Animation.PhysicsConstraintMassTimeline) { + writePhysicsConstraintMassTimeline((Animation.PhysicsConstraintMassTimeline)obj); + } else if (obj instanceof Animation.PhysicsConstraintMixTimeline) { + writePhysicsConstraintMixTimeline((Animation.PhysicsConstraintMixTimeline)obj); + } else if (obj instanceof Animation.PhysicsConstraintResetTimeline) { + writePhysicsConstraintResetTimeline((Animation.PhysicsConstraintResetTimeline)obj); + } else if (obj instanceof Animation.PhysicsConstraintStrengthTimeline) { + writePhysicsConstraintStrengthTimeline((Animation.PhysicsConstraintStrengthTimeline)obj); + } else if (obj instanceof Animation.PhysicsConstraintWindTimeline) { + writePhysicsConstraintWindTimeline((Animation.PhysicsConstraintWindTimeline)obj); + } else if (obj instanceof Animation.RGB2Timeline) { + writeRGB2Timeline((Animation.RGB2Timeline)obj); + } else if (obj instanceof Animation.RGBA2Timeline) { + writeRGBA2Timeline((Animation.RGBA2Timeline)obj); + } else if (obj instanceof Animation.RGBATimeline) { + writeRGBATimeline((Animation.RGBATimeline)obj); + } else if (obj instanceof Animation.RGBTimeline) { + writeRGBTimeline((Animation.RGBTimeline)obj); + } else if (obj instanceof Animation.RotateTimeline) { + writeRotateTimeline((Animation.RotateTimeline)obj); + } else if (obj instanceof Animation.ScaleTimeline) { + writeScaleTimeline((Animation.ScaleTimeline)obj); + } else if (obj instanceof Animation.ScaleXTimeline) { + writeScaleXTimeline((Animation.ScaleXTimeline)obj); + } else if (obj instanceof Animation.ScaleYTimeline) { + writeScaleYTimeline((Animation.ScaleYTimeline)obj); + } else if (obj instanceof Animation.SequenceTimeline) { + writeSequenceTimeline((Animation.SequenceTimeline)obj); + } else if (obj instanceof Animation.ShearTimeline) { + writeShearTimeline((Animation.ShearTimeline)obj); + } else if (obj instanceof Animation.ShearXTimeline) { + writeShearXTimeline((Animation.ShearXTimeline)obj); + } else if (obj instanceof Animation.ShearYTimeline) { + writeShearYTimeline((Animation.ShearYTimeline)obj); + } else if (obj instanceof Animation.SliderMixTimeline) { + writeSliderMixTimeline((Animation.SliderMixTimeline)obj); + } else if (obj instanceof Animation.SliderTimeline) { + writeSliderTimeline((Animation.SliderTimeline)obj); + } else if (obj instanceof Animation.TransformConstraintTimeline) { + writeTransformConstraintTimeline((Animation.TransformConstraintTimeline)obj); + } else if (obj instanceof Animation.TranslateTimeline) { + writeTranslateTimeline((Animation.TranslateTimeline)obj); + } else if (obj instanceof Animation.TranslateXTimeline) { + writeTranslateXTimeline((Animation.TranslateXTimeline)obj); + } else if (obj instanceof Animation.TranslateYTimeline) { + writeTranslateYTimeline((Animation.TranslateYTimeline)obj); + } else { + throw new RuntimeException("Unknown Timeline type: " + obj.getClass().getName()); + } + } + + private void writeTransformConstraintTimeline (Animation.TransformConstraintTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("TransformConstraintTimeline"); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("constraintIndex"); + json.writeValue(obj.getConstraintIndex()); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writeTranslateTimeline (Animation.TranslateTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("TranslateTimeline"); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("boneIndex"); + json.writeValue(obj.getBoneIndex()); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writeTranslateXTimeline (Animation.TranslateXTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("TranslateXTimeline"); + + json.writeName("boneIndex"); + json.writeValue(obj.getBoneIndex()); + + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); + + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); + + json.writeName("duration"); + json.writeValue(obj.getDuration()); + + json.writeObjectEnd(); + } + + private void writeTranslateYTimeline (Animation.TranslateYTimeline obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("TranslateYTimeline"); - json.writeName("boneIndex"); - json.writeValue(obj.getBoneIndex()); + json.writeName("boneIndex"); + json.writeValue(obj.getBoneIndex()); - json.writeName("frameEntries"); - json.writeValue(obj.getFrameEntries()); + json.writeName("frameEntries"); + json.writeValue(obj.getFrameEntries()); - json.writeName("propertyIds"); - json.writeArrayStart(); - for (String item : obj.getPropertyIds()) { - json.writeValue(item); - } - json.writeArrayEnd(); + json.writeName("propertyIds"); + json.writeArrayStart(); + for (String item : obj.getPropertyIds()) { + json.writeValue(item); + } + json.writeArrayEnd(); - json.writeName("frames"); - json.writeArrayStart(); - for (float item : obj.getFrames()) { - json.writeValue(item); - } - json.writeArrayEnd(); + json.writeName("frames"); + json.writeArrayStart(); + for (float item : obj.getFrames()) { + json.writeValue(item); + } + json.writeArrayEnd(); - json.writeName("frameCount"); - json.writeValue(obj.getFrameCount()); + json.writeName("frameCount"); + json.writeValue(obj.getFrameCount()); - json.writeName("duration"); - json.writeValue(obj.getDuration()); + json.writeName("duration"); + json.writeValue(obj.getDuration()); - json.writeObjectEnd(); - } - - private void writeAnimationState(AnimationState obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); + json.writeObjectEnd(); + } + + private void writeAnimationState (AnimationState obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("AnimationState"); + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("AnimationState"); - json.writeName("timeScale"); - json.writeValue(obj.getTimeScale()); + json.writeName("timeScale"); + json.writeValue(obj.getTimeScale()); - json.writeName("data"); - writeAnimationStateData(obj.getData()); + json.writeName("data"); + writeAnimationStateData(obj.getData()); - json.writeName("tracks"); - json.writeArrayStart(); - for (TrackEntry item : obj.getTracks()) { - writeTrackEntry(item); - } - json.writeArrayEnd(); - - json.writeObjectEnd(); - } + json.writeName("tracks"); + json.writeArrayStart(); + for (TrackEntry item : obj.getTracks()) { + writeTrackEntry(item); + } + json.writeArrayEnd(); + + json.writeObjectEnd(); + } - private void writeTrackEntry(AnimationState.TrackEntry obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); + private void writeTrackEntry (AnimationState.TrackEntry obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("TrackEntry"); + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("TrackEntry"); - json.writeName("trackIndex"); - json.writeValue(obj.getTrackIndex()); + json.writeName("trackIndex"); + json.writeValue(obj.getTrackIndex()); - json.writeName("animation"); - writeAnimation(obj.getAnimation()); + json.writeName("animation"); + writeAnimation(obj.getAnimation()); - json.writeName("loop"); - json.writeValue(obj.getLoop()); + json.writeName("loop"); + json.writeValue(obj.getLoop()); - json.writeName("delay"); - json.writeValue(obj.getDelay()); + json.writeName("delay"); + json.writeValue(obj.getDelay()); - json.writeName("trackTime"); - json.writeValue(obj.getTrackTime()); + json.writeName("trackTime"); + json.writeValue(obj.getTrackTime()); - json.writeName("trackEnd"); - json.writeValue(obj.getTrackEnd()); + json.writeName("trackEnd"); + json.writeValue(obj.getTrackEnd()); - json.writeName("trackComplete"); - json.writeValue(obj.getTrackComplete()); + json.writeName("trackComplete"); + json.writeValue(obj.getTrackComplete()); - json.writeName("animationStart"); - json.writeValue(obj.getAnimationStart()); + json.writeName("animationStart"); + json.writeValue(obj.getAnimationStart()); - json.writeName("animationEnd"); - json.writeValue(obj.getAnimationEnd()); + json.writeName("animationEnd"); + json.writeValue(obj.getAnimationEnd()); - json.writeName("animationLast"); - json.writeValue(obj.getAnimationLast()); - - json.writeName("animationTime"); - json.writeValue(obj.getAnimationTime()); - - json.writeName("timeScale"); - json.writeValue(obj.getTimeScale()); - - json.writeName("alpha"); - json.writeValue(obj.getAlpha()); - - json.writeName("eventThreshold"); - json.writeValue(obj.getEventThreshold()); - - json.writeName("alphaAttachmentThreshold"); - json.writeValue(obj.getAlphaAttachmentThreshold()); - - json.writeName("mixAttachmentThreshold"); - json.writeValue(obj.getMixAttachmentThreshold()); - - json.writeName("mixDrawOrderThreshold"); - json.writeValue(obj.getMixDrawOrderThreshold()); - - json.writeName("next"); - if (obj.getNext() == null) { - json.writeNull(); - } else { - writeTrackEntry(obj.getNext()); - } - - json.writeName("previous"); - if (obj.getPrevious() == null) { - json.writeNull(); - } else { - writeTrackEntry(obj.getPrevious()); - } - - json.writeName("mixTime"); - json.writeValue(obj.getMixTime()); - - json.writeName("mixDuration"); - json.writeValue(obj.getMixDuration()); - - json.writeName("mixBlend"); - json.writeValue(obj.getMixBlend().name()); - - json.writeName("mixingFrom"); - if (obj.getMixingFrom() == null) { - json.writeNull(); - } else { - writeTrackEntry(obj.getMixingFrom()); - } - - json.writeName("mixingTo"); - if (obj.getMixingTo() == null) { - json.writeNull(); - } else { - writeTrackEntry(obj.getMixingTo()); - } - - json.writeName("holdPrevious"); - json.writeValue(obj.getHoldPrevious()); - - json.writeName("shortestRotation"); - json.writeValue(obj.getShortestRotation()); - - json.writeName("reverse"); - json.writeValue(obj.getReverse()); - - json.writeObjectEnd(); - } - - private void writeAnimationStateData(AnimationStateData obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("AnimationStateData"); - - json.writeName("skeletonData"); - writeSkeletonData(obj.getSkeletonData()); - - json.writeName("defaultMix"); - json.writeValue(obj.getDefaultMix()); - - json.writeObjectEnd(); - } - - private void writeAttachment(Attachment obj) { - if (obj instanceof BoundingBoxAttachment) { - writeBoundingBoxAttachment((BoundingBoxAttachment) obj); - } else if (obj instanceof ClippingAttachment) { - writeClippingAttachment((ClippingAttachment) obj); - } else if (obj instanceof MeshAttachment) { - writeMeshAttachment((MeshAttachment) obj); - } else if (obj instanceof PathAttachment) { - writePathAttachment((PathAttachment) obj); - } else if (obj instanceof PointAttachment) { - writePointAttachment((PointAttachment) obj); - } else if (obj instanceof RegionAttachment) { - writeRegionAttachment((RegionAttachment) obj); - } else { - throw new RuntimeException("Unknown Attachment type: " + obj.getClass().getName()); - } - } - - private void writeBone(Bone obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("Bone"); - - json.writeName("parent"); - if (obj.getParent() == null) { - json.writeNull(); - } else { - writeBone(obj.getParent()); - } - - json.writeName("children"); - json.writeArrayStart(); - for (Bone item : obj.getChildren()) { - writeBone(item); - } - json.writeArrayEnd(); - - json.writeName("data"); - writeBoneData(obj.getData()); - - json.writeName("pose"); - writeBoneLocal(obj.getPose()); - - json.writeName("appliedPose"); - writeBonePose(obj.getAppliedPose()); - - json.writeObjectEnd(); - } - - private void writeBoneData(BoneData obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("BoneData"); - - json.writeName("index"); - json.writeValue(obj.getIndex()); - - json.writeName("parent"); - if (obj.getParent() == null) { - json.writeNull(); - } else { - writeBoneData(obj.getParent()); - } + json.writeName("animationLast"); + json.writeValue(obj.getAnimationLast()); + + json.writeName("animationTime"); + json.writeValue(obj.getAnimationTime()); + + json.writeName("timeScale"); + json.writeValue(obj.getTimeScale()); + + json.writeName("alpha"); + json.writeValue(obj.getAlpha()); + + json.writeName("eventThreshold"); + json.writeValue(obj.getEventThreshold()); + + json.writeName("alphaAttachmentThreshold"); + json.writeValue(obj.getAlphaAttachmentThreshold()); + + json.writeName("mixAttachmentThreshold"); + json.writeValue(obj.getMixAttachmentThreshold()); + + json.writeName("mixDrawOrderThreshold"); + json.writeValue(obj.getMixDrawOrderThreshold()); + + json.writeName("next"); + if (obj.getNext() == null) { + json.writeNull(); + } else { + writeTrackEntry(obj.getNext()); + } + + json.writeName("previous"); + if (obj.getPrevious() == null) { + json.writeNull(); + } else { + writeTrackEntry(obj.getPrevious()); + } + + json.writeName("mixTime"); + json.writeValue(obj.getMixTime()); + + json.writeName("mixDuration"); + json.writeValue(obj.getMixDuration()); + + json.writeName("mixBlend"); + json.writeValue(obj.getMixBlend().name()); + + json.writeName("mixingFrom"); + if (obj.getMixingFrom() == null) { + json.writeNull(); + } else { + writeTrackEntry(obj.getMixingFrom()); + } + + json.writeName("mixingTo"); + if (obj.getMixingTo() == null) { + json.writeNull(); + } else { + writeTrackEntry(obj.getMixingTo()); + } + + json.writeName("holdPrevious"); + json.writeValue(obj.getHoldPrevious()); + + json.writeName("shortestRotation"); + json.writeValue(obj.getShortestRotation()); + + json.writeName("reverse"); + json.writeValue(obj.getReverse()); + + json.writeObjectEnd(); + } + + private void writeAnimationStateData (AnimationStateData obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("AnimationStateData"); + + json.writeName("skeletonData"); + writeSkeletonData(obj.getSkeletonData()); + + json.writeName("defaultMix"); + json.writeValue(obj.getDefaultMix()); + + json.writeObjectEnd(); + } + + private void writeAttachment (Attachment obj) { + if (obj instanceof BoundingBoxAttachment) { + writeBoundingBoxAttachment((BoundingBoxAttachment)obj); + } else if (obj instanceof ClippingAttachment) { + writeClippingAttachment((ClippingAttachment)obj); + } else if (obj instanceof MeshAttachment) { + writeMeshAttachment((MeshAttachment)obj); + } else if (obj instanceof PathAttachment) { + writePathAttachment((PathAttachment)obj); + } else if (obj instanceof PointAttachment) { + writePointAttachment((PointAttachment)obj); + } else if (obj instanceof RegionAttachment) { + writeRegionAttachment((RegionAttachment)obj); + } else { + throw new RuntimeException("Unknown Attachment type: " + obj.getClass().getName()); + } + } + + private void writeBone (Bone obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("Bone"); + + json.writeName("parent"); + if (obj.getParent() == null) { + json.writeNull(); + } else { + writeBone(obj.getParent()); + } + + json.writeName("children"); + json.writeArrayStart(); + for (Bone item : obj.getChildren()) { + writeBone(item); + } + json.writeArrayEnd(); + + json.writeName("data"); + writeBoneData(obj.getData()); + + json.writeName("pose"); + writeBoneLocal(obj.getPose()); + + json.writeName("appliedPose"); + writeBonePose(obj.getAppliedPose()); + + json.writeObjectEnd(); + } + + private void writeBoneData (BoneData obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("BoneData"); + + json.writeName("index"); + json.writeValue(obj.getIndex()); + + json.writeName("parent"); + if (obj.getParent() == null) { + json.writeNull(); + } else { + writeBoneData(obj.getParent()); + } - json.writeName("length"); - json.writeValue(obj.getLength()); + json.writeName("length"); + json.writeValue(obj.getLength()); - json.writeName("color"); - writeColor(obj.getColor()); + json.writeName("color"); + writeColor(obj.getColor()); - json.writeName("icon"); - json.writeValue(obj.getIcon()); + json.writeName("icon"); + json.writeValue(obj.getIcon()); - json.writeName("visible"); - json.writeValue(obj.getVisible()); + json.writeName("visible"); + json.writeValue(obj.getVisible()); - json.writeName("name"); - json.writeValue(obj.getName()); + json.writeName("name"); + json.writeValue(obj.getName()); - json.writeName("setupPose"); - writeBoneLocal(obj.getSetupPose()); + json.writeName("setupPose"); + writeBoneLocal(obj.getSetupPose()); - json.writeName("skinRequired"); - json.writeValue(obj.getSkinRequired()); + json.writeName("skinRequired"); + json.writeValue(obj.getSkinRequired()); - json.writeObjectEnd(); - } + json.writeObjectEnd(); + } - private void writeBoneLocal(BoneLocal obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); + private void writeBoneLocal (BoneLocal obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("BoneLocal"); + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("BoneLocal"); - json.writeName("x"); - json.writeValue(obj.getX()); + json.writeName("x"); + json.writeValue(obj.getX()); - json.writeName("y"); - json.writeValue(obj.getY()); + json.writeName("y"); + json.writeValue(obj.getY()); - json.writeName("rotation"); - json.writeValue(obj.getRotation()); + json.writeName("rotation"); + json.writeValue(obj.getRotation()); - json.writeName("scaleX"); - json.writeValue(obj.getScaleX()); + json.writeName("scaleX"); + json.writeValue(obj.getScaleX()); - json.writeName("scaleY"); - json.writeValue(obj.getScaleY()); + json.writeName("scaleY"); + json.writeValue(obj.getScaleY()); - json.writeName("shearX"); - json.writeValue(obj.getShearX()); + json.writeName("shearX"); + json.writeValue(obj.getShearX()); - json.writeName("shearY"); - json.writeValue(obj.getShearY()); + json.writeName("shearY"); + json.writeValue(obj.getShearY()); - json.writeName("inherit"); - json.writeValue(obj.getInherit().name()); + json.writeName("inherit"); + json.writeValue(obj.getInherit().name()); - json.writeObjectEnd(); - } + json.writeObjectEnd(); + } - private void writeBonePose(BonePose obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); + private void writeBonePose (BonePose obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("BonePose"); + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("BonePose"); - json.writeName("a"); - json.writeValue(obj.getA()); + json.writeName("a"); + json.writeValue(obj.getA()); - json.writeName("b"); - json.writeValue(obj.getB()); + json.writeName("b"); + json.writeValue(obj.getB()); - json.writeName("c"); - json.writeValue(obj.getC()); + json.writeName("c"); + json.writeValue(obj.getC()); - json.writeName("d"); - json.writeValue(obj.getD()); + json.writeName("d"); + json.writeValue(obj.getD()); - json.writeName("worldX"); - json.writeValue(obj.getWorldX()); + json.writeName("worldX"); + json.writeValue(obj.getWorldX()); - json.writeName("worldY"); - json.writeValue(obj.getWorldY()); + json.writeName("worldY"); + json.writeValue(obj.getWorldY()); - json.writeName("worldRotationX"); - json.writeValue(obj.getWorldRotationX()); + json.writeName("worldRotationX"); + json.writeValue(obj.getWorldRotationX()); - json.writeName("worldRotationY"); - json.writeValue(obj.getWorldRotationY()); + json.writeName("worldRotationY"); + json.writeValue(obj.getWorldRotationY()); - json.writeName("worldScaleX"); - json.writeValue(obj.getWorldScaleX()); + json.writeName("worldScaleX"); + json.writeValue(obj.getWorldScaleX()); - json.writeName("worldScaleY"); - json.writeValue(obj.getWorldScaleY()); + json.writeName("worldScaleY"); + json.writeValue(obj.getWorldScaleY()); - json.writeName("x"); - json.writeValue(obj.getX()); + json.writeName("x"); + json.writeValue(obj.getX()); - json.writeName("y"); - json.writeValue(obj.getY()); + json.writeName("y"); + json.writeValue(obj.getY()); - json.writeName("rotation"); - json.writeValue(obj.getRotation()); + json.writeName("rotation"); + json.writeValue(obj.getRotation()); - json.writeName("scaleX"); - json.writeValue(obj.getScaleX()); + json.writeName("scaleX"); + json.writeValue(obj.getScaleX()); - json.writeName("scaleY"); - json.writeValue(obj.getScaleY()); + json.writeName("scaleY"); + json.writeValue(obj.getScaleY()); - json.writeName("shearX"); - json.writeValue(obj.getShearX()); + json.writeName("shearX"); + json.writeValue(obj.getShearX()); - json.writeName("shearY"); - json.writeValue(obj.getShearY()); + json.writeName("shearY"); + json.writeValue(obj.getShearY()); - json.writeName("inherit"); - json.writeValue(obj.getInherit().name()); - - json.writeObjectEnd(); - } + json.writeName("inherit"); + json.writeValue(obj.getInherit().name()); + + json.writeObjectEnd(); + } - private void writeBoundingBoxAttachment(BoundingBoxAttachment obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); + private void writeBoundingBoxAttachment (BoundingBoxAttachment obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("BoundingBoxAttachment"); + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("BoundingBoxAttachment"); - json.writeName("color"); - writeColor(obj.getColor()); - - json.writeName("bones"); - if (obj.getBones() == null) { - json.writeNull(); - } else { - json.writeArrayStart(); - for (int item : obj.getBones()) { - json.writeValue(item); - } - json.writeArrayEnd(); - } - - json.writeName("vertices"); - json.writeArrayStart(); - for (float item : obj.getVertices()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("worldVerticesLength"); - json.writeValue(obj.getWorldVerticesLength()); - - json.writeName("timelineAttachment"); - if (obj.getTimelineAttachment() == null) { - json.writeNull(); - } else { - writeAttachment(obj.getTimelineAttachment()); - } - - json.writeName("id"); - json.writeValue(obj.getId()); - - json.writeName("name"); - json.writeValue(obj.getName()); - - json.writeObjectEnd(); - } - - private void writeClippingAttachment(ClippingAttachment obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("ClippingAttachment"); - - json.writeName("endSlot"); - if (obj.getEndSlot() == null) { - json.writeNull(); - } else { - writeSlotData(obj.getEndSlot()); - } - - json.writeName("color"); - writeColor(obj.getColor()); - - json.writeName("bones"); - if (obj.getBones() == null) { - json.writeNull(); - } else { - json.writeArrayStart(); - for (int item : obj.getBones()) { - json.writeValue(item); - } - json.writeArrayEnd(); - } - - json.writeName("vertices"); - json.writeArrayStart(); - for (float item : obj.getVertices()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("worldVerticesLength"); - json.writeValue(obj.getWorldVerticesLength()); - - json.writeName("timelineAttachment"); - if (obj.getTimelineAttachment() == null) { - json.writeNull(); - } else { - writeAttachment(obj.getTimelineAttachment()); - } - - json.writeName("id"); - json.writeValue(obj.getId()); - - json.writeName("name"); - json.writeValue(obj.getName()); - - json.writeObjectEnd(); - } - - private void writeConstraint(Constraint obj) { - if (obj instanceof IkConstraint) { - writeIkConstraint((IkConstraint) obj); - } else if (obj instanceof PathConstraint) { - writePathConstraint((PathConstraint) obj); - } else if (obj instanceof PhysicsConstraint) { - writePhysicsConstraint((PhysicsConstraint) obj); - } else if (obj instanceof Slider) { - writeSlider((Slider) obj); - } else if (obj instanceof TransformConstraint) { - writeTransformConstraint((TransformConstraint) obj); - } else { - throw new RuntimeException("Unknown Constraint type: " + obj.getClass().getName()); - } - } - - private void writeConstraintData(ConstraintData obj) { - if (obj instanceof IkConstraintData) { - writeIkConstraintData((IkConstraintData) obj); - } else if (obj instanceof PathConstraintData) { - writePathConstraintData((PathConstraintData) obj); - } else if (obj instanceof PhysicsConstraintData) { - writePhysicsConstraintData((PhysicsConstraintData) obj); - } else if (obj instanceof SliderData) { - writeSliderData((SliderData) obj); - } else if (obj instanceof TransformConstraintData) { - writeTransformConstraintData((TransformConstraintData) obj); - } else { - throw new RuntimeException("Unknown ConstraintData type: " + obj.getClass().getName()); - } - } - - private void writeEvent(Event obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("Event"); - - json.writeName("int"); - json.writeValue(obj.getInt()); - - json.writeName("float"); - json.writeValue(obj.getFloat()); - - json.writeName("string"); - json.writeValue(obj.getString()); - - json.writeName("volume"); - json.writeValue(obj.getVolume()); - - json.writeName("balance"); - json.writeValue(obj.getBalance()); - - json.writeName("time"); - json.writeValue(obj.getTime()); - - json.writeName("data"); - writeEventData(obj.getData()); - - json.writeObjectEnd(); - } - - private void writeEventData(EventData obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("EventData"); - - json.writeName("int"); - json.writeValue(obj.getInt()); - - json.writeName("float"); - json.writeValue(obj.getFloat()); - - json.writeName("string"); - json.writeValue(obj.getString()); - - json.writeName("audioPath"); - json.writeValue(obj.getAudioPath()); - - json.writeName("volume"); - json.writeValue(obj.getVolume()); - - json.writeName("balance"); - json.writeValue(obj.getBalance()); - - json.writeName("name"); - json.writeValue(obj.getName()); - - json.writeObjectEnd(); - } - - private void writeIkConstraint(IkConstraint obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("IkConstraint"); - - json.writeName("bones"); - json.writeArrayStart(); - for (BonePose item : obj.getBones()) { - writeBonePose(item); - } - json.writeArrayEnd(); - - json.writeName("target"); - writeBone(obj.getTarget()); - - json.writeName("data"); - writeIkConstraintData(obj.getData()); + json.writeName("color"); + writeColor(obj.getColor()); + + json.writeName("bones"); + if (obj.getBones() == null) { + json.writeNull(); + } else { + json.writeArrayStart(); + for (int item : obj.getBones()) { + json.writeValue(item); + } + json.writeArrayEnd(); + } + + json.writeName("vertices"); + json.writeArrayStart(); + for (float item : obj.getVertices()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("worldVerticesLength"); + json.writeValue(obj.getWorldVerticesLength()); + + json.writeName("timelineAttachment"); + if (obj.getTimelineAttachment() == null) { + json.writeNull(); + } else { + writeAttachment(obj.getTimelineAttachment()); + } + + json.writeName("id"); + json.writeValue(obj.getId()); + + json.writeName("name"); + json.writeValue(obj.getName()); + + json.writeObjectEnd(); + } + + private void writeClippingAttachment (ClippingAttachment obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("ClippingAttachment"); + + json.writeName("endSlot"); + if (obj.getEndSlot() == null) { + json.writeNull(); + } else { + writeSlotData(obj.getEndSlot()); + } + + json.writeName("color"); + writeColor(obj.getColor()); + + json.writeName("bones"); + if (obj.getBones() == null) { + json.writeNull(); + } else { + json.writeArrayStart(); + for (int item : obj.getBones()) { + json.writeValue(item); + } + json.writeArrayEnd(); + } + + json.writeName("vertices"); + json.writeArrayStart(); + for (float item : obj.getVertices()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("worldVerticesLength"); + json.writeValue(obj.getWorldVerticesLength()); + + json.writeName("timelineAttachment"); + if (obj.getTimelineAttachment() == null) { + json.writeNull(); + } else { + writeAttachment(obj.getTimelineAttachment()); + } + + json.writeName("id"); + json.writeValue(obj.getId()); + + json.writeName("name"); + json.writeValue(obj.getName()); + + json.writeObjectEnd(); + } + + private void writeConstraint (Constraint obj) { + if (obj instanceof IkConstraint) { + writeIkConstraint((IkConstraint)obj); + } else if (obj instanceof PathConstraint) { + writePathConstraint((PathConstraint)obj); + } else if (obj instanceof PhysicsConstraint) { + writePhysicsConstraint((PhysicsConstraint)obj); + } else if (obj instanceof Slider) { + writeSlider((Slider)obj); + } else if (obj instanceof TransformConstraint) { + writeTransformConstraint((TransformConstraint)obj); + } else { + throw new RuntimeException("Unknown Constraint type: " + obj.getClass().getName()); + } + } + + private void writeConstraintData (ConstraintData obj) { + if (obj instanceof IkConstraintData) { + writeIkConstraintData((IkConstraintData)obj); + } else if (obj instanceof PathConstraintData) { + writePathConstraintData((PathConstraintData)obj); + } else if (obj instanceof PhysicsConstraintData) { + writePhysicsConstraintData((PhysicsConstraintData)obj); + } else if (obj instanceof SliderData) { + writeSliderData((SliderData)obj); + } else if (obj instanceof TransformConstraintData) { + writeTransformConstraintData((TransformConstraintData)obj); + } else { + throw new RuntimeException("Unknown ConstraintData type: " + obj.getClass().getName()); + } + } + + private void writeEvent (Event obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("Event"); + + json.writeName("int"); + json.writeValue(obj.getInt()); + + json.writeName("float"); + json.writeValue(obj.getFloat()); + + json.writeName("string"); + json.writeValue(obj.getString()); + + json.writeName("volume"); + json.writeValue(obj.getVolume()); + + json.writeName("balance"); + json.writeValue(obj.getBalance()); + + json.writeName("time"); + json.writeValue(obj.getTime()); + + json.writeName("data"); + writeEventData(obj.getData()); + + json.writeObjectEnd(); + } + + private void writeEventData (EventData obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("EventData"); + + json.writeName("int"); + json.writeValue(obj.getInt()); + + json.writeName("float"); + json.writeValue(obj.getFloat()); + + json.writeName("string"); + json.writeValue(obj.getString()); + + json.writeName("audioPath"); + json.writeValue(obj.getAudioPath()); + + json.writeName("volume"); + json.writeValue(obj.getVolume()); + + json.writeName("balance"); + json.writeValue(obj.getBalance()); + + json.writeName("name"); + json.writeValue(obj.getName()); + + json.writeObjectEnd(); + } + + private void writeIkConstraint (IkConstraint obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("IkConstraint"); + + json.writeName("bones"); + json.writeArrayStart(); + for (BonePose item : obj.getBones()) { + writeBonePose(item); + } + json.writeArrayEnd(); + + json.writeName("target"); + writeBone(obj.getTarget()); + + json.writeName("data"); + writeIkConstraintData(obj.getData()); - json.writeName("pose"); - writeIkConstraintPose(obj.getPose()); + json.writeName("pose"); + writeIkConstraintPose(obj.getPose()); - json.writeName("appliedPose"); - writeIkConstraintPose(obj.getAppliedPose()); + json.writeName("appliedPose"); + writeIkConstraintPose(obj.getAppliedPose()); - json.writeObjectEnd(); - } + json.writeObjectEnd(); + } - private void writeIkConstraintData(IkConstraintData obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); + private void writeIkConstraintData (IkConstraintData obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("IkConstraintData"); + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("IkConstraintData"); - json.writeName("bones"); - json.writeArrayStart(); - for (BoneData item : obj.getBones()) { - writeBoneData(item); - } - json.writeArrayEnd(); - - json.writeName("target"); - writeBoneData(obj.getTarget()); - - json.writeName("uniform"); - json.writeValue(obj.getUniform()); - - json.writeName("name"); - json.writeValue(obj.getName()); - - json.writeName("setupPose"); - writeIkConstraintPose(obj.getSetupPose()); - - json.writeName("skinRequired"); - json.writeValue(obj.getSkinRequired()); - - json.writeObjectEnd(); - } - - private void writeIkConstraintPose(IkConstraintPose obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("IkConstraintPose"); - - json.writeName("mix"); - json.writeValue(obj.getMix()); - - json.writeName("softness"); - json.writeValue(obj.getSoftness()); - - json.writeName("bendDirection"); - json.writeValue(obj.getBendDirection()); - - json.writeName("compress"); - json.writeValue(obj.getCompress()); - - json.writeName("stretch"); - json.writeValue(obj.getStretch()); - - json.writeObjectEnd(); - } - - private void writeMeshAttachment(MeshAttachment obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("MeshAttachment"); - - json.writeName("region"); - if (obj.getRegion() == null) { - json.writeNull(); - } else { - writeTextureRegion(obj.getRegion()); - } - - json.writeName("triangles"); - json.writeArrayStart(); - for (short item : obj.getTriangles()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("regionUVs"); - json.writeArrayStart(); - for (float item : obj.getRegionUVs()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("uVs"); - json.writeArrayStart(); - for (float item : obj.getUVs()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("color"); - writeColor(obj.getColor()); - - json.writeName("path"); - json.writeValue(obj.getPath()); - - json.writeName("hullLength"); - json.writeValue(obj.getHullLength()); - - json.writeName("edges"); - if (obj.getEdges() == null) { - json.writeNull(); - } else { - json.writeArrayStart(); - for (short item : obj.getEdges()) { - json.writeValue(item); - } - json.writeArrayEnd(); - } - - json.writeName("width"); - json.writeValue(obj.getWidth()); - - json.writeName("height"); - json.writeValue(obj.getHeight()); - - json.writeName("sequence"); - if (obj.getSequence() == null) { - json.writeNull(); - } else { - writeSequence(obj.getSequence()); - } - - json.writeName("parentMesh"); - if (obj.getParentMesh() == null) { - json.writeNull(); - } else { - writeMeshAttachment(obj.getParentMesh()); - } - - json.writeName("bones"); - if (obj.getBones() == null) { - json.writeNull(); - } else { - json.writeArrayStart(); - for (int item : obj.getBones()) { - json.writeValue(item); - } - json.writeArrayEnd(); - } - - json.writeName("vertices"); - json.writeArrayStart(); - for (float item : obj.getVertices()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("worldVerticesLength"); - json.writeValue(obj.getWorldVerticesLength()); - - json.writeName("timelineAttachment"); - if (obj.getTimelineAttachment() == null) { - json.writeNull(); - } else { - writeAttachment(obj.getTimelineAttachment()); - } - - json.writeName("id"); - json.writeValue(obj.getId()); - - json.writeName("name"); - json.writeValue(obj.getName()); - - json.writeObjectEnd(); - } - - private void writePathAttachment(PathAttachment obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("PathAttachment"); - - json.writeName("closed"); - json.writeValue(obj.getClosed()); - - json.writeName("constantSpeed"); - json.writeValue(obj.getConstantSpeed()); - - json.writeName("lengths"); - json.writeArrayStart(); - for (float item : obj.getLengths()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("color"); - writeColor(obj.getColor()); - - json.writeName("bones"); - if (obj.getBones() == null) { - json.writeNull(); - } else { - json.writeArrayStart(); - for (int item : obj.getBones()) { - json.writeValue(item); - } - json.writeArrayEnd(); - } - - json.writeName("vertices"); - json.writeArrayStart(); - for (float item : obj.getVertices()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("worldVerticesLength"); - json.writeValue(obj.getWorldVerticesLength()); - - json.writeName("timelineAttachment"); - if (obj.getTimelineAttachment() == null) { - json.writeNull(); - } else { - writeAttachment(obj.getTimelineAttachment()); - } - - json.writeName("id"); - json.writeValue(obj.getId()); - - json.writeName("name"); - json.writeValue(obj.getName()); - - json.writeObjectEnd(); - } - - private void writePathConstraint(PathConstraint obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("PathConstraint"); - - json.writeName("bones"); - json.writeArrayStart(); - for (BonePose item : obj.getBones()) { - writeBonePose(item); - } - json.writeArrayEnd(); - - json.writeName("slot"); - writeSlot(obj.getSlot()); - - json.writeName("data"); - writePathConstraintData(obj.getData()); - - json.writeName("pose"); - writePathConstraintPose(obj.getPose()); + json.writeName("bones"); + json.writeArrayStart(); + for (BoneData item : obj.getBones()) { + writeBoneData(item); + } + json.writeArrayEnd(); + + json.writeName("target"); + writeBoneData(obj.getTarget()); + + json.writeName("uniform"); + json.writeValue(obj.getUniform()); + + json.writeName("name"); + json.writeValue(obj.getName()); + + json.writeName("setupPose"); + writeIkConstraintPose(obj.getSetupPose()); + + json.writeName("skinRequired"); + json.writeValue(obj.getSkinRequired()); + + json.writeObjectEnd(); + } + + private void writeIkConstraintPose (IkConstraintPose obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("IkConstraintPose"); + + json.writeName("mix"); + json.writeValue(obj.getMix()); + + json.writeName("softness"); + json.writeValue(obj.getSoftness()); + + json.writeName("bendDirection"); + json.writeValue(obj.getBendDirection()); + + json.writeName("compress"); + json.writeValue(obj.getCompress()); + + json.writeName("stretch"); + json.writeValue(obj.getStretch()); + + json.writeObjectEnd(); + } + + private void writeMeshAttachment (MeshAttachment obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("MeshAttachment"); + + json.writeName("region"); + if (obj.getRegion() == null) { + json.writeNull(); + } else { + writeTextureRegion(obj.getRegion()); + } + + json.writeName("triangles"); + json.writeArrayStart(); + for (short item : obj.getTriangles()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("regionUVs"); + json.writeArrayStart(); + for (float item : obj.getRegionUVs()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("uVs"); + json.writeArrayStart(); + for (float item : obj.getUVs()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("color"); + writeColor(obj.getColor()); + + json.writeName("path"); + json.writeValue(obj.getPath()); + + json.writeName("hullLength"); + json.writeValue(obj.getHullLength()); + + json.writeName("edges"); + if (obj.getEdges() == null) { + json.writeNull(); + } else { + json.writeArrayStart(); + for (short item : obj.getEdges()) { + json.writeValue(item); + } + json.writeArrayEnd(); + } + + json.writeName("width"); + json.writeValue(obj.getWidth()); + + json.writeName("height"); + json.writeValue(obj.getHeight()); + + json.writeName("sequence"); + if (obj.getSequence() == null) { + json.writeNull(); + } else { + writeSequence(obj.getSequence()); + } + + json.writeName("parentMesh"); + if (obj.getParentMesh() == null) { + json.writeNull(); + } else { + writeMeshAttachment(obj.getParentMesh()); + } + + json.writeName("bones"); + if (obj.getBones() == null) { + json.writeNull(); + } else { + json.writeArrayStart(); + for (int item : obj.getBones()) { + json.writeValue(item); + } + json.writeArrayEnd(); + } + + json.writeName("vertices"); + json.writeArrayStart(); + for (float item : obj.getVertices()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("worldVerticesLength"); + json.writeValue(obj.getWorldVerticesLength()); + + json.writeName("timelineAttachment"); + if (obj.getTimelineAttachment() == null) { + json.writeNull(); + } else { + writeAttachment(obj.getTimelineAttachment()); + } + + json.writeName("id"); + json.writeValue(obj.getId()); + + json.writeName("name"); + json.writeValue(obj.getName()); + + json.writeObjectEnd(); + } + + private void writePathAttachment (PathAttachment obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("PathAttachment"); + + json.writeName("closed"); + json.writeValue(obj.getClosed()); + + json.writeName("constantSpeed"); + json.writeValue(obj.getConstantSpeed()); + + json.writeName("lengths"); + json.writeArrayStart(); + for (float item : obj.getLengths()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("color"); + writeColor(obj.getColor()); + + json.writeName("bones"); + if (obj.getBones() == null) { + json.writeNull(); + } else { + json.writeArrayStart(); + for (int item : obj.getBones()) { + json.writeValue(item); + } + json.writeArrayEnd(); + } + + json.writeName("vertices"); + json.writeArrayStart(); + for (float item : obj.getVertices()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("worldVerticesLength"); + json.writeValue(obj.getWorldVerticesLength()); + + json.writeName("timelineAttachment"); + if (obj.getTimelineAttachment() == null) { + json.writeNull(); + } else { + writeAttachment(obj.getTimelineAttachment()); + } + + json.writeName("id"); + json.writeValue(obj.getId()); + + json.writeName("name"); + json.writeValue(obj.getName()); + + json.writeObjectEnd(); + } + + private void writePathConstraint (PathConstraint obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("PathConstraint"); + + json.writeName("bones"); + json.writeArrayStart(); + for (BonePose item : obj.getBones()) { + writeBonePose(item); + } + json.writeArrayEnd(); + + json.writeName("slot"); + writeSlot(obj.getSlot()); + + json.writeName("data"); + writePathConstraintData(obj.getData()); + + json.writeName("pose"); + writePathConstraintPose(obj.getPose()); - json.writeName("appliedPose"); - writePathConstraintPose(obj.getAppliedPose()); + json.writeName("appliedPose"); + writePathConstraintPose(obj.getAppliedPose()); - json.writeObjectEnd(); - } + json.writeObjectEnd(); + } - private void writePathConstraintData(PathConstraintData obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("PathConstraintData"); - - json.writeName("bones"); - json.writeArrayStart(); - for (BoneData item : obj.getBones()) { - writeBoneData(item); - } - json.writeArrayEnd(); - - json.writeName("slot"); - writeSlotData(obj.getSlot()); - - json.writeName("positionMode"); - json.writeValue(obj.getPositionMode().name()); + private void writePathConstraintData (PathConstraintData obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("PathConstraintData"); + + json.writeName("bones"); + json.writeArrayStart(); + for (BoneData item : obj.getBones()) { + writeBoneData(item); + } + json.writeArrayEnd(); + + json.writeName("slot"); + writeSlotData(obj.getSlot()); + + json.writeName("positionMode"); + json.writeValue(obj.getPositionMode().name()); - json.writeName("spacingMode"); - json.writeValue(obj.getSpacingMode().name()); + json.writeName("spacingMode"); + json.writeValue(obj.getSpacingMode().name()); - json.writeName("rotateMode"); - json.writeValue(obj.getRotateMode().name()); + json.writeName("rotateMode"); + json.writeValue(obj.getRotateMode().name()); - json.writeName("offsetRotation"); - json.writeValue(obj.getOffsetRotation()); + json.writeName("offsetRotation"); + json.writeValue(obj.getOffsetRotation()); - json.writeName("name"); - json.writeValue(obj.getName()); + json.writeName("name"); + json.writeValue(obj.getName()); - json.writeName("setupPose"); - writePathConstraintPose(obj.getSetupPose()); + json.writeName("setupPose"); + writePathConstraintPose(obj.getSetupPose()); - json.writeName("skinRequired"); - json.writeValue(obj.getSkinRequired()); + json.writeName("skinRequired"); + json.writeValue(obj.getSkinRequired()); - json.writeObjectEnd(); - } + json.writeObjectEnd(); + } - private void writePathConstraintPose(PathConstraintPose obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); + private void writePathConstraintPose (PathConstraintPose obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("PathConstraintPose"); + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("PathConstraintPose"); - json.writeName("position"); - json.writeValue(obj.getPosition()); + json.writeName("position"); + json.writeValue(obj.getPosition()); - json.writeName("spacing"); - json.writeValue(obj.getSpacing()); + json.writeName("spacing"); + json.writeValue(obj.getSpacing()); - json.writeName("mixRotate"); - json.writeValue(obj.getMixRotate()); + json.writeName("mixRotate"); + json.writeValue(obj.getMixRotate()); - json.writeName("mixX"); - json.writeValue(obj.getMixX()); + json.writeName("mixX"); + json.writeValue(obj.getMixX()); - json.writeName("mixY"); - json.writeValue(obj.getMixY()); + json.writeName("mixY"); + json.writeValue(obj.getMixY()); - json.writeObjectEnd(); - } + json.writeObjectEnd(); + } - private void writePhysicsConstraint(PhysicsConstraint obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); + private void writePhysicsConstraint (PhysicsConstraint obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("PhysicsConstraint"); + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("PhysicsConstraint"); - json.writeName("bone"); - writeBonePose(obj.getBone()); + json.writeName("bone"); + writeBonePose(obj.getBone()); - json.writeName("data"); - writePhysicsConstraintData(obj.getData()); + json.writeName("data"); + writePhysicsConstraintData(obj.getData()); - json.writeName("pose"); - writePhysicsConstraintPose(obj.getPose()); + json.writeName("pose"); + writePhysicsConstraintPose(obj.getPose()); - json.writeName("appliedPose"); - writePhysicsConstraintPose(obj.getAppliedPose()); + json.writeName("appliedPose"); + writePhysicsConstraintPose(obj.getAppliedPose()); - json.writeObjectEnd(); - } + json.writeObjectEnd(); + } - private void writePhysicsConstraintData(PhysicsConstraintData obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); + private void writePhysicsConstraintData (PhysicsConstraintData obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("PhysicsConstraintData"); + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("PhysicsConstraintData"); - json.writeName("bone"); - writeBoneData(obj.getBone()); + json.writeName("bone"); + writeBoneData(obj.getBone()); - json.writeName("step"); - json.writeValue(obj.getStep()); + json.writeName("step"); + json.writeValue(obj.getStep()); - json.writeName("x"); - json.writeValue(obj.getX()); + json.writeName("x"); + json.writeValue(obj.getX()); - json.writeName("y"); - json.writeValue(obj.getY()); + json.writeName("y"); + json.writeValue(obj.getY()); - json.writeName("rotate"); - json.writeValue(obj.getRotate()); + json.writeName("rotate"); + json.writeValue(obj.getRotate()); - json.writeName("scaleX"); - json.writeValue(obj.getScaleX()); + json.writeName("scaleX"); + json.writeValue(obj.getScaleX()); - json.writeName("shearX"); - json.writeValue(obj.getShearX()); + json.writeName("shearX"); + json.writeValue(obj.getShearX()); - json.writeName("limit"); - json.writeValue(obj.getLimit()); + json.writeName("limit"); + json.writeValue(obj.getLimit()); - json.writeName("inertiaGlobal"); - json.writeValue(obj.getInertiaGlobal()); + json.writeName("inertiaGlobal"); + json.writeValue(obj.getInertiaGlobal()); - json.writeName("strengthGlobal"); - json.writeValue(obj.getStrengthGlobal()); + json.writeName("strengthGlobal"); + json.writeValue(obj.getStrengthGlobal()); - json.writeName("dampingGlobal"); - json.writeValue(obj.getDampingGlobal()); + json.writeName("dampingGlobal"); + json.writeValue(obj.getDampingGlobal()); - json.writeName("massGlobal"); - json.writeValue(obj.getMassGlobal()); + json.writeName("massGlobal"); + json.writeValue(obj.getMassGlobal()); - json.writeName("windGlobal"); - json.writeValue(obj.getWindGlobal()); + json.writeName("windGlobal"); + json.writeValue(obj.getWindGlobal()); - json.writeName("gravityGlobal"); - json.writeValue(obj.getGravityGlobal()); + json.writeName("gravityGlobal"); + json.writeValue(obj.getGravityGlobal()); - json.writeName("mixGlobal"); - json.writeValue(obj.getMixGlobal()); + json.writeName("mixGlobal"); + json.writeValue(obj.getMixGlobal()); - json.writeName("name"); - json.writeValue(obj.getName()); + json.writeName("name"); + json.writeValue(obj.getName()); - json.writeName("setupPose"); - writePhysicsConstraintPose(obj.getSetupPose()); + json.writeName("setupPose"); + writePhysicsConstraintPose(obj.getSetupPose()); - json.writeName("skinRequired"); - json.writeValue(obj.getSkinRequired()); + json.writeName("skinRequired"); + json.writeValue(obj.getSkinRequired()); - json.writeObjectEnd(); - } + json.writeObjectEnd(); + } - private void writePhysicsConstraintPose(PhysicsConstraintPose obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); + private void writePhysicsConstraintPose (PhysicsConstraintPose obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("PhysicsConstraintPose"); + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("PhysicsConstraintPose"); - json.writeName("inertia"); - json.writeValue(obj.getInertia()); + json.writeName("inertia"); + json.writeValue(obj.getInertia()); - json.writeName("strength"); - json.writeValue(obj.getStrength()); + json.writeName("strength"); + json.writeValue(obj.getStrength()); - json.writeName("damping"); - json.writeValue(obj.getDamping()); + json.writeName("damping"); + json.writeValue(obj.getDamping()); - json.writeName("massInverse"); - json.writeValue(obj.getMassInverse()); + json.writeName("massInverse"); + json.writeValue(obj.getMassInverse()); - json.writeName("wind"); - json.writeValue(obj.getWind()); + json.writeName("wind"); + json.writeValue(obj.getWind()); - json.writeName("gravity"); - json.writeValue(obj.getGravity()); + json.writeName("gravity"); + json.writeValue(obj.getGravity()); - json.writeName("mix"); - json.writeValue(obj.getMix()); + json.writeName("mix"); + json.writeValue(obj.getMix()); - json.writeObjectEnd(); - } + json.writeObjectEnd(); + } - private void writePointAttachment(PointAttachment obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); + private void writePointAttachment (PointAttachment obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("PointAttachment"); + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("PointAttachment"); - json.writeName("x"); - json.writeValue(obj.getX()); + json.writeName("x"); + json.writeValue(obj.getX()); - json.writeName("y"); - json.writeValue(obj.getY()); + json.writeName("y"); + json.writeValue(obj.getY()); - json.writeName("rotation"); - json.writeValue(obj.getRotation()); + json.writeName("rotation"); + json.writeValue(obj.getRotation()); - json.writeName("color"); - writeColor(obj.getColor()); + json.writeName("color"); + writeColor(obj.getColor()); - json.writeName("name"); - json.writeValue(obj.getName()); + json.writeName("name"); + json.writeValue(obj.getName()); - json.writeObjectEnd(); - } + json.writeObjectEnd(); + } - private void writeRegionAttachment(RegionAttachment obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); + private void writeRegionAttachment (RegionAttachment obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("RegionAttachment"); + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("RegionAttachment"); - json.writeName("region"); - if (obj.getRegion() == null) { - json.writeNull(); - } else { - writeTextureRegion(obj.getRegion()); - } + json.writeName("region"); + if (obj.getRegion() == null) { + json.writeNull(); + } else { + writeTextureRegion(obj.getRegion()); + } - json.writeName("offset"); - json.writeArrayStart(); - for (float item : obj.getOffset()) { - json.writeValue(item); - } - json.writeArrayEnd(); + json.writeName("offset"); + json.writeArrayStart(); + for (float item : obj.getOffset()) { + json.writeValue(item); + } + json.writeArrayEnd(); - json.writeName("uVs"); - json.writeArrayStart(); - for (float item : obj.getUVs()) { - json.writeValue(item); - } - json.writeArrayEnd(); - - json.writeName("x"); - json.writeValue(obj.getX()); - - json.writeName("y"); - json.writeValue(obj.getY()); - - json.writeName("scaleX"); - json.writeValue(obj.getScaleX()); - - json.writeName("scaleY"); - json.writeValue(obj.getScaleY()); - - json.writeName("rotation"); - json.writeValue(obj.getRotation()); - - json.writeName("width"); - json.writeValue(obj.getWidth()); - - json.writeName("height"); - json.writeValue(obj.getHeight()); - - json.writeName("color"); - writeColor(obj.getColor()); - - json.writeName("path"); - json.writeValue(obj.getPath()); - - json.writeName("sequence"); - if (obj.getSequence() == null) { - json.writeNull(); - } else { - writeSequence(obj.getSequence()); - } - - json.writeName("name"); - json.writeValue(obj.getName()); - - json.writeObjectEnd(); - } - - private void writeSequence(Sequence obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("Sequence"); - - json.writeName("start"); - json.writeValue(obj.getStart()); - - json.writeName("digits"); - json.writeValue(obj.getDigits()); - - json.writeName("setupIndex"); - json.writeValue(obj.getSetupIndex()); - - json.writeName("regions"); - json.writeArrayStart(); - for (TextureRegion item : obj.getRegions()) { - writeTextureRegion(item); - } - json.writeArrayEnd(); - - json.writeName("id"); - json.writeValue(obj.getId()); - - json.writeObjectEnd(); - } - - private void writeSkeleton(Skeleton obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("Skeleton"); - - json.writeName("data"); - writeSkeletonData(obj.getData()); - - json.writeName("bones"); - json.writeArrayStart(); - for (Bone item : obj.getBones()) { - writeBone(item); - } - json.writeArrayEnd(); - - json.writeName("updateCache"); - json.writeArrayStart(); - for (Update item : obj.getUpdateCache()) { - writeUpdate(item); - } - json.writeArrayEnd(); - - json.writeName("rootBone"); - writeBone(obj.getRootBone()); - - json.writeName("slots"); - json.writeArrayStart(); - for (Slot item : obj.getSlots()) { - writeSlot(item); - } - json.writeArrayEnd(); - - json.writeName("drawOrder"); - json.writeArrayStart(); - for (Slot item : obj.getDrawOrder()) { - writeSlot(item); - } - json.writeArrayEnd(); - - json.writeName("skin"); - if (obj.getSkin() == null) { - json.writeNull(); - } else { - writeSkin(obj.getSkin()); - } - - json.writeName("constraints"); - json.writeArrayStart(); - for (Constraint item : obj.getConstraints()) { - writeConstraint(item); - } - json.writeArrayEnd(); - - json.writeName("physicsConstraints"); - json.writeArrayStart(); - for (PhysicsConstraint item : obj.getPhysicsConstraints()) { - writePhysicsConstraint(item); - } - json.writeArrayEnd(); - - json.writeName("color"); - writeColor(obj.getColor()); - - json.writeName("scaleX"); - json.writeValue(obj.getScaleX()); - - json.writeName("scaleY"); - json.writeValue(obj.getScaleY()); - - json.writeName("x"); - json.writeValue(obj.getX()); - - json.writeName("y"); - json.writeValue(obj.getY()); - - json.writeName("windX"); - json.writeValue(obj.getWindX()); - - json.writeName("windY"); - json.writeValue(obj.getWindY()); - - json.writeName("gravityX"); - json.writeValue(obj.getGravityX()); - - json.writeName("gravityY"); - json.writeValue(obj.getGravityY()); - - json.writeName("time"); - json.writeValue(obj.getTime()); - - json.writeObjectEnd(); - } - - private void writeSkeletonData(SkeletonData obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("SkeletonData"); - - json.writeName("bones"); - json.writeArrayStart(); - for (BoneData item : obj.getBones()) { - writeBoneData(item); - } - json.writeArrayEnd(); - - json.writeName("slots"); - json.writeArrayStart(); - for (SlotData item : obj.getSlots()) { - writeSlotData(item); - } - json.writeArrayEnd(); - - json.writeName("defaultSkin"); - if (obj.getDefaultSkin() == null) { - json.writeNull(); - } else { - writeSkin(obj.getDefaultSkin()); - } - - json.writeName("skins"); - json.writeArrayStart(); - for (Skin item : obj.getSkins()) { - writeSkin(item); - } - json.writeArrayEnd(); - - json.writeName("events"); - json.writeArrayStart(); - for (EventData item : obj.getEvents()) { - writeEventData(item); - } - json.writeArrayEnd(); - - json.writeName("animations"); - json.writeArrayStart(); - for (Animation item : obj.getAnimations()) { - writeAnimation(item); - } - json.writeArrayEnd(); - - json.writeName("constraints"); - json.writeArrayStart(); - for (ConstraintData item : obj.getConstraints()) { - writeConstraintData(item); - } - json.writeArrayEnd(); - - json.writeName("name"); - json.writeValue(obj.getName()); - - json.writeName("x"); - json.writeValue(obj.getX()); - - json.writeName("y"); - json.writeValue(obj.getY()); - - json.writeName("width"); - json.writeValue(obj.getWidth()); - - json.writeName("height"); - json.writeValue(obj.getHeight()); - - json.writeName("referenceScale"); - json.writeValue(obj.getReferenceScale()); - - json.writeName("version"); - json.writeValue(obj.getVersion()); - - json.writeName("hash"); - json.writeValue(obj.getHash()); - - json.writeName("imagesPath"); - json.writeValue(obj.getImagesPath()); - - json.writeName("audioPath"); - json.writeValue(obj.getAudioPath()); - - json.writeName("fps"); - json.writeValue(obj.getFps()); - - json.writeObjectEnd(); - } - - private void writeSkin(Skin obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("Skin"); - - json.writeName("attachments"); - Array sortedAttachments = new Array<>(obj.getAttachments()); - sortedAttachments.sort((a, b) -> Integer.compare(a.getSlotIndex(), b.getSlotIndex())); - json.writeArrayStart(); - for (SkinEntry item : sortedAttachments) { - writeSkinEntry(item); - } - json.writeArrayEnd(); - - json.writeName("bones"); - json.writeArrayStart(); - for (BoneData item : obj.getBones()) { - writeBoneData(item); - } - json.writeArrayEnd(); - - json.writeName("constraints"); - json.writeArrayStart(); - for (ConstraintData item : obj.getConstraints()) { - writeConstraintData(item); - } - json.writeArrayEnd(); - - json.writeName("name"); - json.writeValue(obj.getName()); - - json.writeName("color"); - writeColor(obj.getColor()); - - json.writeObjectEnd(); - } - - private void writeSkinEntry(Skin.SkinEntry obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); + json.writeName("uVs"); + json.writeArrayStart(); + for (float item : obj.getUVs()) { + json.writeValue(item); + } + json.writeArrayEnd(); + + json.writeName("x"); + json.writeValue(obj.getX()); + + json.writeName("y"); + json.writeValue(obj.getY()); + + json.writeName("scaleX"); + json.writeValue(obj.getScaleX()); + + json.writeName("scaleY"); + json.writeValue(obj.getScaleY()); + + json.writeName("rotation"); + json.writeValue(obj.getRotation()); + + json.writeName("width"); + json.writeValue(obj.getWidth()); + + json.writeName("height"); + json.writeValue(obj.getHeight()); + + json.writeName("color"); + writeColor(obj.getColor()); + + json.writeName("path"); + json.writeValue(obj.getPath()); + + json.writeName("sequence"); + if (obj.getSequence() == null) { + json.writeNull(); + } else { + writeSequence(obj.getSequence()); + } + + json.writeName("name"); + json.writeValue(obj.getName()); + + json.writeObjectEnd(); + } + + private void writeSequence (Sequence obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("Sequence"); + + json.writeName("start"); + json.writeValue(obj.getStart()); + + json.writeName("digits"); + json.writeValue(obj.getDigits()); + + json.writeName("setupIndex"); + json.writeValue(obj.getSetupIndex()); + + json.writeName("regions"); + json.writeArrayStart(); + for (TextureRegion item : obj.getRegions()) { + writeTextureRegion(item); + } + json.writeArrayEnd(); + + json.writeName("id"); + json.writeValue(obj.getId()); + + json.writeObjectEnd(); + } + + private void writeSkeleton (Skeleton obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("Skeleton"); + + json.writeName("data"); + writeSkeletonData(obj.getData()); + + json.writeName("bones"); + json.writeArrayStart(); + for (Bone item : obj.getBones()) { + writeBone(item); + } + json.writeArrayEnd(); + + json.writeName("updateCache"); + json.writeArrayStart(); + for (Update item : obj.getUpdateCache()) { + writeUpdate(item); + } + json.writeArrayEnd(); + + json.writeName("rootBone"); + writeBone(obj.getRootBone()); + + json.writeName("slots"); + json.writeArrayStart(); + for (Slot item : obj.getSlots()) { + writeSlot(item); + } + json.writeArrayEnd(); + + json.writeName("drawOrder"); + json.writeArrayStart(); + for (Slot item : obj.getDrawOrder()) { + writeSlot(item); + } + json.writeArrayEnd(); + + json.writeName("skin"); + if (obj.getSkin() == null) { + json.writeNull(); + } else { + writeSkin(obj.getSkin()); + } + + json.writeName("constraints"); + json.writeArrayStart(); + for (Constraint item : obj.getConstraints()) { + writeConstraint(item); + } + json.writeArrayEnd(); + + json.writeName("physicsConstraints"); + json.writeArrayStart(); + for (PhysicsConstraint item : obj.getPhysicsConstraints()) { + writePhysicsConstraint(item); + } + json.writeArrayEnd(); + + json.writeName("color"); + writeColor(obj.getColor()); + + json.writeName("scaleX"); + json.writeValue(obj.getScaleX()); + + json.writeName("scaleY"); + json.writeValue(obj.getScaleY()); + + json.writeName("x"); + json.writeValue(obj.getX()); + + json.writeName("y"); + json.writeValue(obj.getY()); + + json.writeName("windX"); + json.writeValue(obj.getWindX()); + + json.writeName("windY"); + json.writeValue(obj.getWindY()); + + json.writeName("gravityX"); + json.writeValue(obj.getGravityX()); + + json.writeName("gravityY"); + json.writeValue(obj.getGravityY()); + + json.writeName("time"); + json.writeValue(obj.getTime()); + + json.writeObjectEnd(); + } + + private void writeSkeletonData (SkeletonData obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("SkeletonData"); + + json.writeName("bones"); + json.writeArrayStart(); + for (BoneData item : obj.getBones()) { + writeBoneData(item); + } + json.writeArrayEnd(); + + json.writeName("slots"); + json.writeArrayStart(); + for (SlotData item : obj.getSlots()) { + writeSlotData(item); + } + json.writeArrayEnd(); + + json.writeName("defaultSkin"); + if (obj.getDefaultSkin() == null) { + json.writeNull(); + } else { + writeSkin(obj.getDefaultSkin()); + } + + json.writeName("skins"); + json.writeArrayStart(); + for (Skin item : obj.getSkins()) { + writeSkin(item); + } + json.writeArrayEnd(); + + json.writeName("events"); + json.writeArrayStart(); + for (EventData item : obj.getEvents()) { + writeEventData(item); + } + json.writeArrayEnd(); + + json.writeName("animations"); + json.writeArrayStart(); + for (Animation item : obj.getAnimations()) { + writeAnimation(item); + } + json.writeArrayEnd(); + + json.writeName("constraints"); + json.writeArrayStart(); + for (ConstraintData item : obj.getConstraints()) { + writeConstraintData(item); + } + json.writeArrayEnd(); + + json.writeName("name"); + json.writeValue(obj.getName()); + + json.writeName("x"); + json.writeValue(obj.getX()); + + json.writeName("y"); + json.writeValue(obj.getY()); + + json.writeName("width"); + json.writeValue(obj.getWidth()); + + json.writeName("height"); + json.writeValue(obj.getHeight()); + + json.writeName("referenceScale"); + json.writeValue(obj.getReferenceScale()); + + json.writeName("version"); + json.writeValue(obj.getVersion()); + + json.writeName("hash"); + json.writeValue(obj.getHash()); + + json.writeName("imagesPath"); + json.writeValue(obj.getImagesPath()); + + json.writeName("audioPath"); + json.writeValue(obj.getAudioPath()); + + json.writeName("fps"); + json.writeValue(obj.getFps()); + + json.writeObjectEnd(); + } + + private void writeSkin (Skin obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("Skin"); + + json.writeName("attachments"); + Array sortedAttachments = new Array<>(obj.getAttachments()); + sortedAttachments.sort( (a, b) -> Integer.compare(a.getSlotIndex(), b.getSlotIndex())); + json.writeArrayStart(); + for (SkinEntry item : sortedAttachments) { + writeSkinEntry(item); + } + json.writeArrayEnd(); + + json.writeName("bones"); + json.writeArrayStart(); + for (BoneData item : obj.getBones()) { + writeBoneData(item); + } + json.writeArrayEnd(); + + json.writeName("constraints"); + json.writeArrayStart(); + for (ConstraintData item : obj.getConstraints()) { + writeConstraintData(item); + } + json.writeArrayEnd(); + + json.writeName("name"); + json.writeValue(obj.getName()); + + json.writeName("color"); + writeColor(obj.getColor()); + + json.writeObjectEnd(); + } + + private void writeSkinEntry (Skin.SkinEntry obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("SkinEntry"); + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("SkinEntry"); - json.writeName("slotIndex"); - json.writeValue(obj.getSlotIndex()); + json.writeName("slotIndex"); + json.writeValue(obj.getSlotIndex()); - json.writeName("name"); - json.writeValue(obj.getName()); + json.writeName("name"); + json.writeValue(obj.getName()); - json.writeName("attachment"); - writeAttachment(obj.getAttachment()); + json.writeName("attachment"); + writeAttachment(obj.getAttachment()); - json.writeObjectEnd(); - } + json.writeObjectEnd(); + } - private void writeSlider(Slider obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); + private void writeSlider (Slider obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("Slider"); - - json.writeName("bone"); - writeBone(obj.getBone()); - - json.writeName("data"); - writeSliderData(obj.getData()); - - json.writeName("pose"); - writeSliderPose(obj.getPose()); - - json.writeName("appliedPose"); - writeSliderPose(obj.getAppliedPose()); - - json.writeObjectEnd(); - } - - private void writeSliderData(SliderData obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("SliderData"); - - json.writeName("animation"); - writeAnimation(obj.getAnimation()); - - json.writeName("additive"); - json.writeValue(obj.getAdditive()); - - json.writeName("loop"); - json.writeValue(obj.getLoop()); - - json.writeName("bone"); - if (obj.getBone() == null) { - json.writeNull(); - } else { - writeBoneData(obj.getBone()); - } + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("Slider"); + + json.writeName("bone"); + writeBone(obj.getBone()); + + json.writeName("data"); + writeSliderData(obj.getData()); + + json.writeName("pose"); + writeSliderPose(obj.getPose()); + + json.writeName("appliedPose"); + writeSliderPose(obj.getAppliedPose()); + + json.writeObjectEnd(); + } + + private void writeSliderData (SliderData obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("SliderData"); + + json.writeName("animation"); + writeAnimation(obj.getAnimation()); + + json.writeName("additive"); + json.writeValue(obj.getAdditive()); + + json.writeName("loop"); + json.writeValue(obj.getLoop()); + + json.writeName("bone"); + if (obj.getBone() == null) { + json.writeNull(); + } else { + writeBoneData(obj.getBone()); + } - json.writeName("property"); - if (obj.getProperty() == null) { - json.writeNull(); - } else { - writeFromProperty(obj.getProperty()); - } + json.writeName("property"); + if (obj.getProperty() == null) { + json.writeNull(); + } else { + writeFromProperty(obj.getProperty()); + } - json.writeName("offset"); - json.writeValue(obj.getOffset()); + json.writeName("offset"); + json.writeValue(obj.getOffset()); - json.writeName("scale"); - json.writeValue(obj.getScale()); + json.writeName("scale"); + json.writeValue(obj.getScale()); - json.writeName("local"); - json.writeValue(obj.getLocal()); + json.writeName("local"); + json.writeValue(obj.getLocal()); - json.writeName("name"); - json.writeValue(obj.getName()); + json.writeName("name"); + json.writeValue(obj.getName()); - json.writeName("setupPose"); - writeSliderPose(obj.getSetupPose()); + json.writeName("setupPose"); + writeSliderPose(obj.getSetupPose()); - json.writeName("skinRequired"); - json.writeValue(obj.getSkinRequired()); + json.writeName("skinRequired"); + json.writeValue(obj.getSkinRequired()); - json.writeObjectEnd(); - } + json.writeObjectEnd(); + } - private void writeSliderPose(SliderPose obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); + private void writeSliderPose (SliderPose obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("SliderPose"); + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("SliderPose"); - json.writeName("time"); - json.writeValue(obj.getTime()); + json.writeName("time"); + json.writeValue(obj.getTime()); - json.writeName("mix"); - json.writeValue(obj.getMix()); + json.writeName("mix"); + json.writeValue(obj.getMix()); - json.writeObjectEnd(); - } + json.writeObjectEnd(); + } - private void writeSlot(Slot obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); + private void writeSlot (Slot obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("Slot"); + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("Slot"); - json.writeName("bone"); - writeBone(obj.getBone()); + json.writeName("bone"); + writeBone(obj.getBone()); - json.writeName("data"); - writeSlotData(obj.getData()); + json.writeName("data"); + writeSlotData(obj.getData()); - json.writeName("pose"); - writeSlotPose(obj.getPose()); + json.writeName("pose"); + writeSlotPose(obj.getPose()); - json.writeName("appliedPose"); - writeSlotPose(obj.getAppliedPose()); + json.writeName("appliedPose"); + writeSlotPose(obj.getAppliedPose()); - json.writeObjectEnd(); - } + json.writeObjectEnd(); + } - private void writeSlotData(SlotData obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); + private void writeSlotData (SlotData obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("SlotData"); + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("SlotData"); - json.writeName("index"); - json.writeValue(obj.getIndex()); + json.writeName("index"); + json.writeValue(obj.getIndex()); - json.writeName("boneData"); - writeBoneData(obj.getBoneData()); + json.writeName("boneData"); + writeBoneData(obj.getBoneData()); - json.writeName("attachmentName"); - json.writeValue(obj.getAttachmentName()); + json.writeName("attachmentName"); + json.writeValue(obj.getAttachmentName()); - json.writeName("blendMode"); - json.writeValue(obj.getBlendMode().name()); + json.writeName("blendMode"); + json.writeValue(obj.getBlendMode().name()); - json.writeName("visible"); - json.writeValue(obj.getVisible()); + json.writeName("visible"); + json.writeValue(obj.getVisible()); - json.writeName("name"); - json.writeValue(obj.getName()); + json.writeName("name"); + json.writeValue(obj.getName()); - json.writeName("setupPose"); - writeSlotPose(obj.getSetupPose()); + json.writeName("setupPose"); + writeSlotPose(obj.getSetupPose()); - json.writeName("skinRequired"); - json.writeValue(obj.getSkinRequired()); + json.writeName("skinRequired"); + json.writeValue(obj.getSkinRequired()); - json.writeObjectEnd(); - } + json.writeObjectEnd(); + } - private void writeSlotPose(SlotPose obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); + private void writeSlotPose (SlotPose obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("SlotPose"); + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("SlotPose"); - json.writeName("color"); - writeColor(obj.getColor()); + json.writeName("color"); + writeColor(obj.getColor()); - json.writeName("darkColor"); - if (obj.getDarkColor() == null) { - json.writeNull(); - } else { - writeColor(obj.getDarkColor()); - } + json.writeName("darkColor"); + if (obj.getDarkColor() == null) { + json.writeNull(); + } else { + writeColor(obj.getDarkColor()); + } - json.writeName("attachment"); - if (obj.getAttachment() == null) { - json.writeNull(); - } else { - writeAttachment(obj.getAttachment()); - } + json.writeName("attachment"); + if (obj.getAttachment() == null) { + json.writeNull(); + } else { + writeAttachment(obj.getAttachment()); + } - json.writeName("sequenceIndex"); - json.writeValue(obj.getSequenceIndex()); + json.writeName("sequenceIndex"); + json.writeValue(obj.getSequenceIndex()); - json.writeName("deform"); - writeFloatArray(obj.getDeform()); + json.writeName("deform"); + writeFloatArray(obj.getDeform()); - json.writeObjectEnd(); - } + json.writeObjectEnd(); + } - private void writeTransformConstraint(TransformConstraint obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); + private void writeTransformConstraint (TransformConstraint obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("TransformConstraint"); + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("TransformConstraint"); - json.writeName("bones"); - json.writeArrayStart(); - for (BonePose item : obj.getBones()) { - writeBonePose(item); - } - json.writeArrayEnd(); - - json.writeName("source"); - writeBone(obj.getSource()); - - json.writeName("data"); - writeTransformConstraintData(obj.getData()); - - json.writeName("pose"); - writeTransformConstraintPose(obj.getPose()); - - json.writeName("appliedPose"); - writeTransformConstraintPose(obj.getAppliedPose()); - - json.writeObjectEnd(); - } - - private void writeTransformConstraintData(TransformConstraintData obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("TransformConstraintData"); - - json.writeName("bones"); - json.writeArrayStart(); - for (BoneData item : obj.getBones()) { - writeBoneData(item); - } - json.writeArrayEnd(); - - json.writeName("source"); - writeBoneData(obj.getSource()); - - json.writeName("offsetRotation"); - json.writeValue(obj.getOffsetRotation()); - - json.writeName("offsetX"); - json.writeValue(obj.getOffsetX()); - - json.writeName("offsetY"); - json.writeValue(obj.getOffsetY()); - - json.writeName("offsetScaleX"); - json.writeValue(obj.getOffsetScaleX()); - - json.writeName("offsetScaleY"); - json.writeValue(obj.getOffsetScaleY()); - - json.writeName("offsetShearY"); - json.writeValue(obj.getOffsetShearY()); - - json.writeName("localSource"); - json.writeValue(obj.getLocalSource()); - - json.writeName("localTarget"); - json.writeValue(obj.getLocalTarget()); - - json.writeName("additive"); - json.writeValue(obj.getAdditive()); - - json.writeName("clamp"); - json.writeValue(obj.getClamp()); - - json.writeName("properties"); - json.writeArrayStart(); - for (FromProperty item : obj.getProperties()) { - writeFromProperty(item); - } - json.writeArrayEnd(); - - json.writeName("name"); - json.writeValue(obj.getName()); - - json.writeName("setupPose"); - writeTransformConstraintPose(obj.getSetupPose()); - - json.writeName("skinRequired"); - json.writeValue(obj.getSkinRequired()); - - json.writeObjectEnd(); - } - - private void writeFromProperty(TransformConstraintData.FromProperty obj) { - if (obj instanceof TransformConstraintData.FromRotate) { - writeFromRotate((TransformConstraintData.FromRotate) obj); - } else if (obj instanceof TransformConstraintData.FromScaleX) { - writeFromScaleX((TransformConstraintData.FromScaleX) obj); - } else if (obj instanceof TransformConstraintData.FromScaleY) { - writeFromScaleY((TransformConstraintData.FromScaleY) obj); - } else if (obj instanceof TransformConstraintData.FromShearY) { - writeFromShearY((TransformConstraintData.FromShearY) obj); - } else if (obj instanceof TransformConstraintData.FromX) { - writeFromX((TransformConstraintData.FromX) obj); - } else if (obj instanceof TransformConstraintData.FromY) { - writeFromY((TransformConstraintData.FromY) obj); - } else { - throw new RuntimeException("Unknown FromProperty type: " + obj.getClass().getName()); - } - } - - private void writeFromRotate(TransformConstraintData.FromRotate obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("FromRotate"); - - json.writeName("offset"); - json.writeValue(obj.offset); - - json.writeName("to"); - json.writeArrayStart(); - for (ToProperty item : obj.to) { - writeToProperty(item); - } - json.writeArrayEnd(); - - json.writeObjectEnd(); - } - - private void writeFromScaleX(TransformConstraintData.FromScaleX obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("FromScaleX"); - - json.writeName("offset"); - json.writeValue(obj.offset); - - json.writeName("to"); - json.writeArrayStart(); - for (ToProperty item : obj.to) { - writeToProperty(item); - } - json.writeArrayEnd(); - - json.writeObjectEnd(); - } - - private void writeFromScaleY(TransformConstraintData.FromScaleY obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("FromScaleY"); - - json.writeName("offset"); - json.writeValue(obj.offset); - - json.writeName("to"); - json.writeArrayStart(); - for (ToProperty item : obj.to) { - writeToProperty(item); - } - json.writeArrayEnd(); - - json.writeObjectEnd(); - } - - private void writeFromShearY(TransformConstraintData.FromShearY obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("FromShearY"); - - json.writeName("offset"); - json.writeValue(obj.offset); - - json.writeName("to"); - json.writeArrayStart(); - for (ToProperty item : obj.to) { - writeToProperty(item); - } - json.writeArrayEnd(); - - json.writeObjectEnd(); - } - - private void writeFromX(TransformConstraintData.FromX obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("FromX"); - - json.writeName("offset"); - json.writeValue(obj.offset); - - json.writeName("to"); - json.writeArrayStart(); - for (ToProperty item : obj.to) { - writeToProperty(item); - } - json.writeArrayEnd(); - - json.writeObjectEnd(); - } - - private void writeFromY(TransformConstraintData.FromY obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("FromY"); - - json.writeName("offset"); - json.writeValue(obj.offset); - - json.writeName("to"); - json.writeArrayStart(); - for (ToProperty item : obj.to) { - writeToProperty(item); - } - json.writeArrayEnd(); - - json.writeObjectEnd(); - } - - private void writeToProperty(TransformConstraintData.ToProperty obj) { - if (obj instanceof TransformConstraintData.ToRotate) { - writeToRotate((TransformConstraintData.ToRotate) obj); - } else if (obj instanceof TransformConstraintData.ToScaleX) { - writeToScaleX((TransformConstraintData.ToScaleX) obj); - } else if (obj instanceof TransformConstraintData.ToScaleY) { - writeToScaleY((TransformConstraintData.ToScaleY) obj); - } else if (obj instanceof TransformConstraintData.ToShearY) { - writeToShearY((TransformConstraintData.ToShearY) obj); - } else if (obj instanceof TransformConstraintData.ToX) { - writeToX((TransformConstraintData.ToX) obj); - } else if (obj instanceof TransformConstraintData.ToY) { - writeToY((TransformConstraintData.ToY) obj); - } else { - throw new RuntimeException("Unknown ToProperty type: " + obj.getClass().getName()); - } - } - - private void writeToRotate(TransformConstraintData.ToRotate obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("ToRotate"); - - json.writeName("offset"); - json.writeValue(obj.offset); - - json.writeName("max"); - json.writeValue(obj.max); - - json.writeName("scale"); - json.writeValue(obj.scale); - - json.writeObjectEnd(); - } - - private void writeToScaleX(TransformConstraintData.ToScaleX obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("ToScaleX"); - - json.writeName("offset"); - json.writeValue(obj.offset); - - json.writeName("max"); - json.writeValue(obj.max); - - json.writeName("scale"); - json.writeValue(obj.scale); - - json.writeObjectEnd(); - } - - private void writeToScaleY(TransformConstraintData.ToScaleY obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("ToScaleY"); - - json.writeName("offset"); - json.writeValue(obj.offset); - - json.writeName("max"); - json.writeValue(obj.max); - - json.writeName("scale"); - json.writeValue(obj.scale); - - json.writeObjectEnd(); - } - - private void writeToShearY(TransformConstraintData.ToShearY obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("ToShearY"); - - json.writeName("offset"); - json.writeValue(obj.offset); - - json.writeName("max"); - json.writeValue(obj.max); - - json.writeName("scale"); - json.writeValue(obj.scale); - - json.writeObjectEnd(); - } - - private void writeToX(TransformConstraintData.ToX obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("ToX"); - - json.writeName("offset"); - json.writeValue(obj.offset); - - json.writeName("max"); - json.writeValue(obj.max); - - json.writeName("scale"); - json.writeValue(obj.scale); - - json.writeObjectEnd(); - } - - private void writeToY(TransformConstraintData.ToY obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("ToY"); - - json.writeName("offset"); - json.writeValue(obj.offset); - - json.writeName("max"); - json.writeValue(obj.max); - - json.writeName("scale"); - json.writeValue(obj.scale); - - json.writeObjectEnd(); - } - - private void writeTransformConstraintPose(TransformConstraintPose obj) { - if (visitedObjects.contains(obj)) { - json.writeValue(""); - return; - } - visitedObjects.add(obj); - - json.writeObjectStart(); - json.writeName("type"); - json.writeValue("TransformConstraintPose"); - - json.writeName("mixRotate"); - json.writeValue(obj.getMixRotate()); - - json.writeName("mixX"); - json.writeValue(obj.getMixX()); - - json.writeName("mixY"); - json.writeValue(obj.getMixY()); - - json.writeName("mixScaleX"); - json.writeValue(obj.getMixScaleX()); - - json.writeName("mixScaleY"); - json.writeValue(obj.getMixScaleY()); - - json.writeName("mixShearY"); - json.writeValue(obj.getMixShearY()); - - json.writeObjectEnd(); - } - - private void writeUpdate(Update obj) { - if (obj instanceof BonePose) { - writeBonePose((BonePose) obj); - } else if (obj instanceof IkConstraint) { - writeIkConstraint((IkConstraint) obj); - } else if (obj instanceof PathConstraint) { - writePathConstraint((PathConstraint) obj); - } else if (obj instanceof PhysicsConstraint) { - writePhysicsConstraint((PhysicsConstraint) obj); - } else if (obj instanceof Slider) { - writeSlider((Slider) obj); - } else if (obj instanceof TransformConstraint) { - writeTransformConstraint((TransformConstraint) obj); - } else { - throw new RuntimeException("Unknown Update type: " + obj.getClass().getName()); - } - } - - private void writeVertexAttachment(VertexAttachment obj) { - if (obj instanceof BoundingBoxAttachment) { - writeBoundingBoxAttachment((BoundingBoxAttachment) obj); - } else if (obj instanceof ClippingAttachment) { - writeClippingAttachment((ClippingAttachment) obj); - } else if (obj instanceof MeshAttachment) { - writeMeshAttachment((MeshAttachment) obj); - } else if (obj instanceof PathAttachment) { - writePathAttachment((PathAttachment) obj); - } else { - throw new RuntimeException("Unknown VertexAttachment type: " + obj.getClass().getName()); - } - } - - private void writeColor(Color obj) { - if (obj == null) { - json.writeNull(); - } else { - json.writeObjectStart(); - json.writeName("r"); - json.writeValue(obj.r); - json.writeName("g"); - json.writeValue(obj.g); - json.writeName("b"); - json.writeValue(obj.b); - json.writeName("a"); - json.writeValue(obj.a); - json.writeObjectEnd(); - } - } - - private void writeTextureRegion(TextureRegion obj) { - if (obj == null) { - json.writeNull(); - } else { - json.writeObjectStart(); - json.writeName("u"); - json.writeValue(obj.getU()); - json.writeName("v"); - json.writeValue(obj.getV()); - json.writeName("u2"); - json.writeValue(obj.getU2()); - json.writeName("v2"); - json.writeValue(obj.getV2()); - json.writeName("width"); - json.writeValue(obj.getRegionWidth()); - json.writeName("height"); - json.writeValue(obj.getRegionHeight()); - json.writeObjectEnd(); - } - } - - private void writeIntArray(IntArray obj) { - if (obj == null) { - json.writeNull(); - } else { - json.writeArrayStart(); - for (int i = 0; i < obj.size; i++) { - json.writeValue(obj.get(i)); - } - json.writeArrayEnd(); - } - } - - private void writeFloatArray(FloatArray obj) { - if (obj == null) { - json.writeNull(); - } else { - json.writeArrayStart(); - for (int i = 0; i < obj.size; i++) { - json.writeValue(obj.get(i)); - } - json.writeArrayEnd(); - } - } -} \ No newline at end of file + json.writeName("bones"); + json.writeArrayStart(); + for (BonePose item : obj.getBones()) { + writeBonePose(item); + } + json.writeArrayEnd(); + + json.writeName("source"); + writeBone(obj.getSource()); + + json.writeName("data"); + writeTransformConstraintData(obj.getData()); + + json.writeName("pose"); + writeTransformConstraintPose(obj.getPose()); + + json.writeName("appliedPose"); + writeTransformConstraintPose(obj.getAppliedPose()); + + json.writeObjectEnd(); + } + + private void writeTransformConstraintData (TransformConstraintData obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("TransformConstraintData"); + + json.writeName("bones"); + json.writeArrayStart(); + for (BoneData item : obj.getBones()) { + writeBoneData(item); + } + json.writeArrayEnd(); + + json.writeName("source"); + writeBoneData(obj.getSource()); + + json.writeName("offsetRotation"); + json.writeValue(obj.getOffsetRotation()); + + json.writeName("offsetX"); + json.writeValue(obj.getOffsetX()); + + json.writeName("offsetY"); + json.writeValue(obj.getOffsetY()); + + json.writeName("offsetScaleX"); + json.writeValue(obj.getOffsetScaleX()); + + json.writeName("offsetScaleY"); + json.writeValue(obj.getOffsetScaleY()); + + json.writeName("offsetShearY"); + json.writeValue(obj.getOffsetShearY()); + + json.writeName("localSource"); + json.writeValue(obj.getLocalSource()); + + json.writeName("localTarget"); + json.writeValue(obj.getLocalTarget()); + + json.writeName("additive"); + json.writeValue(obj.getAdditive()); + + json.writeName("clamp"); + json.writeValue(obj.getClamp()); + + json.writeName("properties"); + json.writeArrayStart(); + for (FromProperty item : obj.getProperties()) { + writeFromProperty(item); + } + json.writeArrayEnd(); + + json.writeName("name"); + json.writeValue(obj.getName()); + + json.writeName("setupPose"); + writeTransformConstraintPose(obj.getSetupPose()); + + json.writeName("skinRequired"); + json.writeValue(obj.getSkinRequired()); + + json.writeObjectEnd(); + } + + private void writeFromProperty (TransformConstraintData.FromProperty obj) { + if (obj instanceof TransformConstraintData.FromRotate) { + writeFromRotate((TransformConstraintData.FromRotate)obj); + } else if (obj instanceof TransformConstraintData.FromScaleX) { + writeFromScaleX((TransformConstraintData.FromScaleX)obj); + } else if (obj instanceof TransformConstraintData.FromScaleY) { + writeFromScaleY((TransformConstraintData.FromScaleY)obj); + } else if (obj instanceof TransformConstraintData.FromShearY) { + writeFromShearY((TransformConstraintData.FromShearY)obj); + } else if (obj instanceof TransformConstraintData.FromX) { + writeFromX((TransformConstraintData.FromX)obj); + } else if (obj instanceof TransformConstraintData.FromY) { + writeFromY((TransformConstraintData.FromY)obj); + } else { + throw new RuntimeException("Unknown FromProperty type: " + obj.getClass().getName()); + } + } + + private void writeFromRotate (TransformConstraintData.FromRotate obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("FromRotate"); + + json.writeName("offset"); + json.writeValue(obj.offset); + + json.writeName("to"); + json.writeArrayStart(); + for (ToProperty item : obj.to) { + writeToProperty(item); + } + json.writeArrayEnd(); + + json.writeObjectEnd(); + } + + private void writeFromScaleX (TransformConstraintData.FromScaleX obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("FromScaleX"); + + json.writeName("offset"); + json.writeValue(obj.offset); + + json.writeName("to"); + json.writeArrayStart(); + for (ToProperty item : obj.to) { + writeToProperty(item); + } + json.writeArrayEnd(); + + json.writeObjectEnd(); + } + + private void writeFromScaleY (TransformConstraintData.FromScaleY obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("FromScaleY"); + + json.writeName("offset"); + json.writeValue(obj.offset); + + json.writeName("to"); + json.writeArrayStart(); + for (ToProperty item : obj.to) { + writeToProperty(item); + } + json.writeArrayEnd(); + + json.writeObjectEnd(); + } + + private void writeFromShearY (TransformConstraintData.FromShearY obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("FromShearY"); + + json.writeName("offset"); + json.writeValue(obj.offset); + + json.writeName("to"); + json.writeArrayStart(); + for (ToProperty item : obj.to) { + writeToProperty(item); + } + json.writeArrayEnd(); + + json.writeObjectEnd(); + } + + private void writeFromX (TransformConstraintData.FromX obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("FromX"); + + json.writeName("offset"); + json.writeValue(obj.offset); + + json.writeName("to"); + json.writeArrayStart(); + for (ToProperty item : obj.to) { + writeToProperty(item); + } + json.writeArrayEnd(); + + json.writeObjectEnd(); + } + + private void writeFromY (TransformConstraintData.FromY obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("FromY"); + + json.writeName("offset"); + json.writeValue(obj.offset); + + json.writeName("to"); + json.writeArrayStart(); + for (ToProperty item : obj.to) { + writeToProperty(item); + } + json.writeArrayEnd(); + + json.writeObjectEnd(); + } + + private void writeToProperty (TransformConstraintData.ToProperty obj) { + if (obj instanceof TransformConstraintData.ToRotate) { + writeToRotate((TransformConstraintData.ToRotate)obj); + } else if (obj instanceof TransformConstraintData.ToScaleX) { + writeToScaleX((TransformConstraintData.ToScaleX)obj); + } else if (obj instanceof TransformConstraintData.ToScaleY) { + writeToScaleY((TransformConstraintData.ToScaleY)obj); + } else if (obj instanceof TransformConstraintData.ToShearY) { + writeToShearY((TransformConstraintData.ToShearY)obj); + } else if (obj instanceof TransformConstraintData.ToX) { + writeToX((TransformConstraintData.ToX)obj); + } else if (obj instanceof TransformConstraintData.ToY) { + writeToY((TransformConstraintData.ToY)obj); + } else { + throw new RuntimeException("Unknown ToProperty type: " + obj.getClass().getName()); + } + } + + private void writeToRotate (TransformConstraintData.ToRotate obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("ToRotate"); + + json.writeName("offset"); + json.writeValue(obj.offset); + + json.writeName("max"); + json.writeValue(obj.max); + + json.writeName("scale"); + json.writeValue(obj.scale); + + json.writeObjectEnd(); + } + + private void writeToScaleX (TransformConstraintData.ToScaleX obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("ToScaleX"); + + json.writeName("offset"); + json.writeValue(obj.offset); + + json.writeName("max"); + json.writeValue(obj.max); + + json.writeName("scale"); + json.writeValue(obj.scale); + + json.writeObjectEnd(); + } + + private void writeToScaleY (TransformConstraintData.ToScaleY obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("ToScaleY"); + + json.writeName("offset"); + json.writeValue(obj.offset); + + json.writeName("max"); + json.writeValue(obj.max); + + json.writeName("scale"); + json.writeValue(obj.scale); + + json.writeObjectEnd(); + } + + private void writeToShearY (TransformConstraintData.ToShearY obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("ToShearY"); + + json.writeName("offset"); + json.writeValue(obj.offset); + + json.writeName("max"); + json.writeValue(obj.max); + + json.writeName("scale"); + json.writeValue(obj.scale); + + json.writeObjectEnd(); + } + + private void writeToX (TransformConstraintData.ToX obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("ToX"); + + json.writeName("offset"); + json.writeValue(obj.offset); + + json.writeName("max"); + json.writeValue(obj.max); + + json.writeName("scale"); + json.writeValue(obj.scale); + + json.writeObjectEnd(); + } + + private void writeToY (TransformConstraintData.ToY obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("ToY"); + + json.writeName("offset"); + json.writeValue(obj.offset); + + json.writeName("max"); + json.writeValue(obj.max); + + json.writeName("scale"); + json.writeValue(obj.scale); + + json.writeObjectEnd(); + } + + private void writeTransformConstraintPose (TransformConstraintPose obj) { + if (visitedObjects.contains(obj)) { + json.writeValue(""); + return; + } + visitedObjects.add(obj); + + json.writeObjectStart(); + json.writeName("type"); + json.writeValue("TransformConstraintPose"); + + json.writeName("mixRotate"); + json.writeValue(obj.getMixRotate()); + + json.writeName("mixX"); + json.writeValue(obj.getMixX()); + + json.writeName("mixY"); + json.writeValue(obj.getMixY()); + + json.writeName("mixScaleX"); + json.writeValue(obj.getMixScaleX()); + + json.writeName("mixScaleY"); + json.writeValue(obj.getMixScaleY()); + + json.writeName("mixShearY"); + json.writeValue(obj.getMixShearY()); + + json.writeObjectEnd(); + } + + private void writeUpdate (Update obj) { + if (obj instanceof BonePose) { + writeBonePose((BonePose)obj); + } else if (obj instanceof IkConstraint) { + writeIkConstraint((IkConstraint)obj); + } else if (obj instanceof PathConstraint) { + writePathConstraint((PathConstraint)obj); + } else if (obj instanceof PhysicsConstraint) { + writePhysicsConstraint((PhysicsConstraint)obj); + } else if (obj instanceof Slider) { + writeSlider((Slider)obj); + } else if (obj instanceof TransformConstraint) { + writeTransformConstraint((TransformConstraint)obj); + } else { + throw new RuntimeException("Unknown Update type: " + obj.getClass().getName()); + } + } + + private void writeVertexAttachment (VertexAttachment obj) { + if (obj instanceof BoundingBoxAttachment) { + writeBoundingBoxAttachment((BoundingBoxAttachment)obj); + } else if (obj instanceof ClippingAttachment) { + writeClippingAttachment((ClippingAttachment)obj); + } else if (obj instanceof MeshAttachment) { + writeMeshAttachment((MeshAttachment)obj); + } else if (obj instanceof PathAttachment) { + writePathAttachment((PathAttachment)obj); + } else { + throw new RuntimeException("Unknown VertexAttachment type: " + obj.getClass().getName()); + } + } + + private void writeColor (Color obj) { + if (obj == null) { + json.writeNull(); + } else { + json.writeObjectStart(); + json.writeName("r"); + json.writeValue(obj.r); + json.writeName("g"); + json.writeValue(obj.g); + json.writeName("b"); + json.writeValue(obj.b); + json.writeName("a"); + json.writeValue(obj.a); + json.writeObjectEnd(); + } + } + + private void writeTextureRegion (TextureRegion obj) { + if (obj == null) { + json.writeNull(); + } else { + json.writeObjectStart(); + json.writeName("u"); + json.writeValue(obj.getU()); + json.writeName("v"); + json.writeValue(obj.getV()); + json.writeName("u2"); + json.writeValue(obj.getU2()); + json.writeName("v2"); + json.writeValue(obj.getV2()); + json.writeName("width"); + json.writeValue(obj.getRegionWidth()); + json.writeName("height"); + json.writeValue(obj.getRegionHeight()); + json.writeObjectEnd(); + } + } + + private void writeIntArray (IntArray obj) { + if (obj == null) { + json.writeNull(); + } else { + json.writeArrayStart(); + for (int i = 0; i < obj.size; i++) { + json.writeValue(obj.get(i)); + } + json.writeArrayEnd(); + } + } + + private void writeFloatArray (FloatArray obj) { + if (obj == null) { + json.writeNull(); + } else { + json.writeArrayStart(); + for (int i = 0; i < obj.size; i++) { + json.writeValue(obj.get(i)); + } + json.writeArrayEnd(); + } + } +} diff --git a/spine-ts/package-lock.json b/spine-ts/package-lock.json index eac7b52dc..835a0c930 100644 --- a/spine-ts/package-lock.json +++ b/spine-ts/package-lock.json @@ -22,16 +22,181 @@ "spine-webcomponents" ], "devDependencies": { + "@biomejs/biome": "^2.1.1", "@types/offscreencanvas": "^2019.7.3", "alive-server": "^1.3.0", "concurrently": "^9.2.0", "copyfiles": "^2.4.1", "esbuild": "^0.25.6", "rimraf": "^6.0.1", + "tsx": "^4.19.2", "typescript": "^5.8.3", "typescript-formatter": "^7.2.2" } }, + "node_modules/@biomejs/biome": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/@biomejs/biome/-/biome-2.1.1.tgz", + "integrity": "sha512-HFGYkxG714KzG+8tvtXCJ1t1qXQMzgWzfvQaUjxN6UeKv+KvMEuliInnbZLJm6DXFXwqVi6446EGI0sGBLIYng==", + "dev": true, + "license": "MIT OR Apache-2.0", + "bin": { + "biome": "bin/biome" + }, + "engines": { + "node": ">=14.21.3" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/biome" + }, + "optionalDependencies": { + "@biomejs/cli-darwin-arm64": "2.1.1", + "@biomejs/cli-darwin-x64": "2.1.1", + "@biomejs/cli-linux-arm64": "2.1.1", + "@biomejs/cli-linux-arm64-musl": "2.1.1", + "@biomejs/cli-linux-x64": "2.1.1", + "@biomejs/cli-linux-x64-musl": "2.1.1", + "@biomejs/cli-win32-arm64": "2.1.1", + "@biomejs/cli-win32-x64": "2.1.1" + } + }, + "node_modules/@biomejs/cli-darwin-arm64": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/@biomejs/cli-darwin-arm64/-/cli-darwin-arm64-2.1.1.tgz", + "integrity": "sha512-2Muinu5ok4tWxq4nu5l19el48cwCY/vzvI7Vjbkf3CYIQkjxZLyj0Ad37Jv2OtlXYaLvv+Sfu1hFeXt/JwRRXQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT OR Apache-2.0", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=14.21.3" + } + }, + "node_modules/@biomejs/cli-darwin-x64": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/@biomejs/cli-darwin-x64/-/cli-darwin-x64-2.1.1.tgz", + "integrity": "sha512-cC8HM5lrgKQXLAK+6Iz2FrYW5A62pAAX6KAnRlEyLb+Q3+Kr6ur/sSuoIacqlp1yvmjHJqjYfZjPvHWnqxoEIA==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT OR Apache-2.0", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=14.21.3" + } + }, + "node_modules/@biomejs/cli-linux-arm64": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/@biomejs/cli-linux-arm64/-/cli-linux-arm64-2.1.1.tgz", + "integrity": "sha512-tw4BEbhAUkWPe4WBr6IX04DJo+2jz5qpPzpW/SWvqMjb9QuHY8+J0M23V8EPY/zWU4IG8Ui0XESapR1CB49Q7g==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT OR Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=14.21.3" + } + }, + "node_modules/@biomejs/cli-linux-arm64-musl": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/@biomejs/cli-linux-arm64-musl/-/cli-linux-arm64-musl-2.1.1.tgz", + "integrity": "sha512-/7FBLnTswu4jgV9ttI3AMIdDGqVEPIZd8I5u2D4tfCoj8rl9dnjrEQbAIDlWhUXdyWlFSz8JypH3swU9h9P+2A==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT OR Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=14.21.3" + } + }, + "node_modules/@biomejs/cli-linux-x64": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/@biomejs/cli-linux-x64/-/cli-linux-x64-2.1.1.tgz", + "integrity": "sha512-3WJ1GKjU7NzZb6RTbwLB59v9cTIlzjbiFLDB0z4376TkDqoNYilJaC37IomCr/aXwuU8QKkrYoHrgpSq5ffJ4Q==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT OR Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=14.21.3" + } + }, + "node_modules/@biomejs/cli-linux-x64-musl": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/@biomejs/cli-linux-x64-musl/-/cli-linux-x64-musl-2.1.1.tgz", + "integrity": "sha512-kUu+loNI3OCD2c12cUt7M5yaaSjDnGIksZwKnueubX6c/HWUyi/0mPbTBHR49Me3F0KKjWiKM+ZOjsmC+lUt9g==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT OR Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=14.21.3" + } + }, + "node_modules/@biomejs/cli-win32-arm64": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/@biomejs/cli-win32-arm64/-/cli-win32-arm64-2.1.1.tgz", + "integrity": "sha512-vEHK0v0oW+E6RUWLoxb2isI3rZo57OX9ZNyyGH701fZPj6Il0Rn1f5DMNyCmyflMwTnIQstEbs7n2BxYSqQx4Q==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT OR Apache-2.0", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=14.21.3" + } + }, + "node_modules/@biomejs/cli-win32-x64": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/@biomejs/cli-win32-x64/-/cli-win32-x64-2.1.1.tgz", + "integrity": "sha512-i2PKdn70kY++KEF/zkQFvQfX1e8SkA8hq4BgC+yE9dZqyLzB/XStY2MvwI3qswlRgnGpgncgqe0QYKVS1blksg==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT OR Apache-2.0", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=14.21.3" + } + }, "node_modules/@esbuild/aix-ppc64": { "version": "0.25.6", "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.25.6.tgz", @@ -986,18 +1151,6 @@ "node": ">=8" } }, - "node_modules/alive-server/node_modules/fsevents": { - "version": "2.3.3", - "dev": true, - "license": "MIT", - "optional": true, - "os": [ - "darwin" - ], - "engines": { - "node": "^8.16.0 || ^10.6.0 || >=11.0.0" - } - }, "node_modules/alive-server/node_modules/glob-parent": { "version": "5.1.2", "dev": true, @@ -1674,6 +1827,21 @@ "dev": true, "license": "ISC" }, + "node_modules/fsevents": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", + "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", + "dev": true, + "hasInstallScript": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^8.16.0 || ^10.6.0 || >=11.0.0" + } + }, "node_modules/function-bind": { "version": "1.1.2", "license": "MIT", @@ -1725,6 +1893,19 @@ "node": ">= 0.4" } }, + "node_modules/get-tsconfig": { + "version": "4.10.1", + "resolved": "https://registry.npmjs.org/get-tsconfig/-/get-tsconfig-4.10.1.tgz", + "integrity": "sha512-auHyJ4AgMz7vgS8Hp3N6HXSmlMdUyhSUrfBF16w153rxtLIEOE+HGqaBppczZvnHLqQJfiHotCYpNhl0lUROFQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "resolve-pkg-maps": "^1.0.0" + }, + "funding": { + "url": "https://github.com/privatenumber/get-tsconfig?sponsor=1" + } + }, "node_modules/gifuct-js": { "version": "2.1.2", "license": "MIT", @@ -2329,6 +2510,16 @@ "node": ">=0.10.0" } }, + "node_modules/resolve-pkg-maps": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/resolve-pkg-maps/-/resolve-pkg-maps-1.0.0.tgz", + "integrity": "sha512-seS2Tj26TBVOC2NIc2rOe2y2ZO7efxITtLZcGSOnHHNOQ7CkiUBfw0Iw2ck6xkIhPwLhKNLS8BO+hEpngQlqzw==", + "dev": true, + "license": "MIT", + "funding": { + "url": "https://github.com/privatenumber/resolve-pkg-maps?sponsor=1" + } + }, "node_modules/rimraf": { "version": "6.0.1", "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-6.0.1.tgz", @@ -2783,6 +2974,26 @@ "dev": true, "license": "0BSD" }, + "node_modules/tsx": { + "version": "4.20.3", + "resolved": "https://registry.npmjs.org/tsx/-/tsx-4.20.3.tgz", + "integrity": "sha512-qjbnuR9Tr+FJOMBqJCW5ehvIo/buZq7vH7qD7JziU98h6l3qGy0a/yPFjwO+y0/T7GFpNgNAvEcPPVfyT8rrPQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "esbuild": "~0.25.0", + "get-tsconfig": "^4.7.5" + }, + "bin": { + "tsx": "dist/cli.mjs" + }, + "engines": { + "node": ">=18.0.0" + }, + "optionalDependencies": { + "fsevents": "~2.3.3" + } + }, "node_modules/typescript": { "version": "5.8.3", "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.8.3.tgz", diff --git a/spine-ts/package.json b/spine-ts/package.json index 181587cdf..06c001ae1 100644 --- a/spine-ts/package.json +++ b/spine-ts/package.json @@ -10,7 +10,7 @@ "prepublish": "npm run clean && npm run build", "clean": "npx rimraf spine-core/dist spine-canvas/dist spine-canvaskit/dist spine-webgl/dist spine-phaser-v3/dist spine-phaser-v4/dist spine-player/dist spine-threejs/dist spine-pixi-v7/dist spine-pixi-v8/dist spine-webcomponents/dist", "build": "npm run clean && npm run build:modules && concurrently 'npm run build:core:iife' 'npm run build:core:esm' 'npm run build:canvas:iife' 'npm run build:canvas:esm' 'npm run build:canvaskit:iife' 'npm run build:canvaskit:esm' 'npm run build:webgl:iife' 'npm run build:webgl:esm' 'npm run build:phaser-v3:iife' 'npm run build:phaser-v4:iife' 'npm run build:phaser-v3:esm' 'npm run build:phaser-v4:esm' 'npm run build:player:iife' 'npm run build:player:esm' 'npm run build:player:css' 'npm run build:threejs:iife' 'npm run build:threejs:esm' 'npm run build:pixi-v7:iife' 'npm run build:pixi-v7:esm' 'npm run build:pixi-v8:iife' 'npm run build:pixi-v8:esm' 'npm run build:webcomponents:iife' 'npm run build:webcomponents:esm'", - "format": "npx tsx scripts/format.ts", + "format": "npx -y tsx scripts/format.ts", "lint": "npx biome lint .", "postbuild": "npm run minify", "build:modules": "npx tsc -b -clean && npx tsc -b", @@ -91,8 +91,6 @@ "alive-server": "^1.3.0", "rimraf": "^6.0.1", "typescript": "^5.8.3", - "typescript-formatter": "^7.2.2", - "@biomejs/biome": "^2.1.1", - "tsx": "^4.19.2" + "@biomejs/biome": "^2.1.1" } } diff --git a/spine-ts/spine-core/tests/HeadlessTest.ts b/spine-ts/spine-core/tests/HeadlessTest.ts index d5eaa3ac0..46fe360fe 100755 --- a/spine-ts/spine-core/tests/HeadlessTest.ts +++ b/spine-ts/spine-core/tests/HeadlessTest.ts @@ -1,4 +1,4 @@ -#!/usr/bin/env npx tsx +#!/usr/bin/env npx -y tsx /****************************************************************************** * Spine Runtimes License Agreement @@ -29,8 +29,8 @@ * THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. *****************************************************************************/ -import { promises as fs } from 'fs'; -import * as path from 'path'; +import { promises as fs } from 'node:fs'; +import * as path from 'node:path'; import { AnimationState, AnimationStateData, diff --git a/tests/generate-serializers.sh b/tests/generate-serializers.sh index ee9bf7c63..b365f999b 100755 --- a/tests/generate-serializers.sh +++ b/tests/generate-serializers.sh @@ -7,16 +7,16 @@ SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" pushd "$SCRIPT_DIR" > /dev/null echo "Analyzing Java API..." -npx tsx src/analyze-java-api.ts || { echo "Failed to analyze Java API"; exit 1; } +npx -y tsx src/analyze-java-api.ts || { echo "Failed to analyze Java API"; exit 1; } echo "Generating serializer IR..." -npx tsx src/generate-serializer-ir.ts || { echo "Failed to generate IR"; exit 1; } +npx -y tsx src/generate-serializer-ir.ts || { echo "Failed to generate IR"; exit 1; } echo "Generating Java SkeletonSerializer..." -npx tsx src/generate-java-serializer.ts || { echo "Failed to generate Java serializer"; exit 1; } +npx -y tsx src/generate-java-serializer.ts || { echo "Failed to generate Java serializer"; exit 1; } echo "Generating C++ SkeletonSerializer..." -npx tsx src/generate-cpp-serializer.ts || { echo "Failed to generate C++ serializer"; exit 1; } +npx -y tsx src/generate-cpp-serializer.ts || { echo "Failed to generate C++ serializer"; exit 1; } echo "Done." popd > /dev/null \ No newline at end of file diff --git a/tests/package-lock.json b/tests/package-lock.json index c5ef1c939..e17a40687 100644 --- a/tests/package-lock.json +++ b/tests/package-lock.json @@ -9,8 +9,173 @@ "@mariozechner/lsp-cli": "^0.1.3" }, "devDependencies": { + "@biomejs/biome": "^2.1.1", "@types/node": "^20.0.0", - "tsx": "^4.0.0" + "tsx": "^4.0.0", + "typescript-formatter": "^7.2.2" + } + }, + "node_modules/@biomejs/biome": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/@biomejs/biome/-/biome-2.1.1.tgz", + "integrity": "sha512-HFGYkxG714KzG+8tvtXCJ1t1qXQMzgWzfvQaUjxN6UeKv+KvMEuliInnbZLJm6DXFXwqVi6446EGI0sGBLIYng==", + "dev": true, + "license": "MIT OR Apache-2.0", + "bin": { + "biome": "bin/biome" + }, + "engines": { + "node": ">=14.21.3" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/biome" + }, + "optionalDependencies": { + "@biomejs/cli-darwin-arm64": "2.1.1", + "@biomejs/cli-darwin-x64": "2.1.1", + "@biomejs/cli-linux-arm64": "2.1.1", + "@biomejs/cli-linux-arm64-musl": "2.1.1", + "@biomejs/cli-linux-x64": "2.1.1", + "@biomejs/cli-linux-x64-musl": "2.1.1", + "@biomejs/cli-win32-arm64": "2.1.1", + "@biomejs/cli-win32-x64": "2.1.1" + } + }, + "node_modules/@biomejs/cli-darwin-arm64": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/@biomejs/cli-darwin-arm64/-/cli-darwin-arm64-2.1.1.tgz", + "integrity": "sha512-2Muinu5ok4tWxq4nu5l19el48cwCY/vzvI7Vjbkf3CYIQkjxZLyj0Ad37Jv2OtlXYaLvv+Sfu1hFeXt/JwRRXQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT OR Apache-2.0", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=14.21.3" + } + }, + "node_modules/@biomejs/cli-darwin-x64": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/@biomejs/cli-darwin-x64/-/cli-darwin-x64-2.1.1.tgz", + "integrity": "sha512-cC8HM5lrgKQXLAK+6Iz2FrYW5A62pAAX6KAnRlEyLb+Q3+Kr6ur/sSuoIacqlp1yvmjHJqjYfZjPvHWnqxoEIA==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT OR Apache-2.0", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=14.21.3" + } + }, + "node_modules/@biomejs/cli-linux-arm64": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/@biomejs/cli-linux-arm64/-/cli-linux-arm64-2.1.1.tgz", + "integrity": "sha512-tw4BEbhAUkWPe4WBr6IX04DJo+2jz5qpPzpW/SWvqMjb9QuHY8+J0M23V8EPY/zWU4IG8Ui0XESapR1CB49Q7g==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT OR Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=14.21.3" + } + }, + "node_modules/@biomejs/cli-linux-arm64-musl": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/@biomejs/cli-linux-arm64-musl/-/cli-linux-arm64-musl-2.1.1.tgz", + "integrity": "sha512-/7FBLnTswu4jgV9ttI3AMIdDGqVEPIZd8I5u2D4tfCoj8rl9dnjrEQbAIDlWhUXdyWlFSz8JypH3swU9h9P+2A==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT OR Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=14.21.3" + } + }, + "node_modules/@biomejs/cli-linux-x64": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/@biomejs/cli-linux-x64/-/cli-linux-x64-2.1.1.tgz", + "integrity": "sha512-3WJ1GKjU7NzZb6RTbwLB59v9cTIlzjbiFLDB0z4376TkDqoNYilJaC37IomCr/aXwuU8QKkrYoHrgpSq5ffJ4Q==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT OR Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=14.21.3" + } + }, + "node_modules/@biomejs/cli-linux-x64-musl": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/@biomejs/cli-linux-x64-musl/-/cli-linux-x64-musl-2.1.1.tgz", + "integrity": "sha512-kUu+loNI3OCD2c12cUt7M5yaaSjDnGIksZwKnueubX6c/HWUyi/0mPbTBHR49Me3F0KKjWiKM+ZOjsmC+lUt9g==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT OR Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=14.21.3" + } + }, + "node_modules/@biomejs/cli-win32-arm64": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/@biomejs/cli-win32-arm64/-/cli-win32-arm64-2.1.1.tgz", + "integrity": "sha512-vEHK0v0oW+E6RUWLoxb2isI3rZo57OX9ZNyyGH701fZPj6Il0Rn1f5DMNyCmyflMwTnIQstEbs7n2BxYSqQx4Q==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT OR Apache-2.0", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=14.21.3" + } + }, + "node_modules/@biomejs/cli-win32-x64": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/@biomejs/cli-win32-x64/-/cli-win32-x64-2.1.1.tgz", + "integrity": "sha512-i2PKdn70kY++KEF/zkQFvQfX1e8SkA8hq4BgC+yE9dZqyLzB/XStY2MvwI3qswlRgnGpgncgqe0QYKVS1blksg==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT OR Apache-2.0", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=14.21.3" } }, "node_modules/@esbuild/aix-ppc64": { @@ -511,6 +676,36 @@ "node": ">=16" } }, + "node_modules/commandpost": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/commandpost/-/commandpost-1.4.0.tgz", + "integrity": "sha512-aE2Y4MTFJ870NuB/+2z1cXBhSBBzRydVVjzhFC4gtenEhpnj15yu0qptWGJsO9YGrcPZ3ezX8AWb1VA391MKpQ==", + "dev": true, + "license": "MIT" + }, + "node_modules/editorconfig": { + "version": "0.15.3", + "resolved": "https://registry.npmjs.org/editorconfig/-/editorconfig-0.15.3.tgz", + "integrity": "sha512-M9wIMFx96vq0R4F+gRpY3o2exzb8hEj/n9S8unZtHSvYjibBp/iMufSzvmOcV/laG0ZtuTVGtiJggPOSW2r93g==", + "dev": true, + "license": "MIT", + "dependencies": { + "commander": "^2.19.0", + "lru-cache": "^4.1.5", + "semver": "^5.6.0", + "sigmund": "^1.0.1" + }, + "bin": { + "editorconfig": "bin/editorconfig" + } + }, + "node_modules/editorconfig/node_modules/commander": { + "version": "2.20.3", + "resolved": "https://registry.npmjs.org/commander/-/commander-2.20.3.tgz", + "integrity": "sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==", + "dev": true, + "license": "MIT" + }, "node_modules/esbuild": { "version": "0.25.6", "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.25.6.tgz", @@ -605,6 +800,24 @@ "url": "https://github.com/privatenumber/get-tsconfig?sponsor=1" } }, + "node_modules/lru-cache": { + "version": "4.1.5", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-4.1.5.tgz", + "integrity": "sha512-sWZlbEP2OsHNkXrMl5GYk/jKk70MBng6UU4YI/qGDYbgf6YbP4EvmqISbXCoJiRKs+1bSpFHVgQxvJ17F2li5g==", + "dev": true, + "license": "ISC", + "dependencies": { + "pseudomap": "^1.0.2", + "yallist": "^2.1.2" + } + }, + "node_modules/lru-cache/node_modules/yallist": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-2.1.2.tgz", + "integrity": "sha512-ncTzHV7NvsQZkYe1DW7cbDLm0YpzHmZF5r/iyP3ZnQtMiJ+pjzisCiMNI+Sj+xQF5pXhSHxSB3uDbsBTzY/c2A==", + "dev": true, + "license": "ISC" + }, "node_modules/minipass": { "version": "5.0.0", "resolved": "https://registry.npmjs.org/minipass/-/minipass-5.0.0.tgz", @@ -664,6 +877,13 @@ "url": "https://github.com/sponsors/antelle" } }, + "node_modules/pseudomap": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/pseudomap/-/pseudomap-1.0.2.tgz", + "integrity": "sha512-b/YwNhb8lk1Zz2+bXXpS/LK9OisiZZ1SNsSLxN1x2OXVEhW2Ckr/7mWE5vrC1ZTiJlD9g19jWszTmJsB+oEpFQ==", + "dev": true, + "license": "ISC" + }, "node_modules/resolve-pkg-maps": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/resolve-pkg-maps/-/resolve-pkg-maps-1.0.0.tgz", @@ -674,6 +894,23 @@ "url": "https://github.com/privatenumber/resolve-pkg-maps?sponsor=1" } }, + "node_modules/semver": { + "version": "5.7.2", + "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.2.tgz", + "integrity": "sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g==", + "dev": true, + "license": "ISC", + "bin": { + "semver": "bin/semver" + } + }, + "node_modules/sigmund": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/sigmund/-/sigmund-1.0.1.tgz", + "integrity": "sha512-fCvEXfh6NWpm+YSuY2bpXb/VIihqWA6hLsgboC+0nl71Q7N7o2eaCW8mJa/NLvQhs6jpd3VZV4UiUQlV6+lc8g==", + "dev": true, + "license": "ISC" + }, "node_modules/tar": { "version": "6.2.1", "resolved": "https://registry.npmjs.org/tar/-/tar-6.2.1.tgz", @@ -711,6 +948,41 @@ "fsevents": "~2.3.3" } }, + "node_modules/typescript": { + "version": "5.8.3", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.8.3.tgz", + "integrity": "sha512-p1diW6TqL9L07nNxvRMM7hMMw4c5XOo/1ibL4aAIGmSAt9slTE1Xgw5KWuof2uTOvCg9BY7ZRi+GaF+7sfgPeQ==", + "dev": true, + "license": "Apache-2.0", + "peer": true, + "bin": { + "tsc": "bin/tsc", + "tsserver": "bin/tsserver" + }, + "engines": { + "node": ">=14.17" + } + }, + "node_modules/typescript-formatter": { + "version": "7.2.2", + "resolved": "https://registry.npmjs.org/typescript-formatter/-/typescript-formatter-7.2.2.tgz", + "integrity": "sha512-V7vfI9XArVhriOTYHPzMU2WUnm5IMdu9X/CPxs8mIMGxmTBFpDABlbkBka64PZJ9/xgQeRpK8KzzAG4MPzxBDQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "commandpost": "^1.0.0", + "editorconfig": "^0.15.0" + }, + "bin": { + "tsfmt": "bin/tsfmt" + }, + "engines": { + "node": ">= 4.2.0" + }, + "peerDependencies": { + "typescript": "^2.1.6 || >=2.7.0-dev || >=2.8.0-dev || >=2.9.0-dev || >=3.0.0-dev" + } + }, "node_modules/undici-types": { "version": "6.21.0", "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.21.0.tgz", diff --git a/tests/test.sh b/tests/test.sh index 492adf61d..5850cdf24 100755 --- a/tests/test.sh +++ b/tests/test.sh @@ -20,4 +20,4 @@ if [ ! -d "node_modules" ]; then fi # Run the TypeScript headless test runner with all arguments -npx tsx src/headless-test-runner.ts "$@" \ No newline at end of file +npx -y tsx src/headless-test-runner.ts "$@" \ No newline at end of file