diff --git a/README.md b/README.md index 6714334..054eb88 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ ![GitHub Workflow Status](https://img.shields.io/github/workflow/status/Ayfri/PIXI-Kotlin/Kotlin%20CI?style=flat-square) ![Sonatype Nexus (Releases)](https://img.shields.io/nexus/r/io.github.ayfri/PIXI-Kotlin?server=https%3A%2F%2Fs01.oss.sonatype.org&style=flat-square&label=Latest%20Version) -![PIXI.js Version](https://img.shields.io/badge/pixi.js-6.2.2-blue?style=flat-square&logo=npm) +![PIXI.js Version](https://img.shields.io/badge/pixi.js-6.5.2-blue?style=flat-square&logo=npm) # PIXI-Kotlin @@ -8,7 +8,7 @@ This is a simple example of what a [PIXI.js](https://github.com/pixijs/pixijs) t For now, there are all the classes, interfaces, enums, functions, type aliases, and objects. The private members are not present. -The types are from [`PIXI 6.2.2`](https://github.com/pixijs/pixijs/releases/tag/v6.2.2). +The types are from [`PIXI 6.5.2`](https://github.com/pixijs/pixijs/releases/tag/v6.5.2). ## Usage @@ -28,7 +28,7 @@ dependencies { If you want to add optional PIXI modules, you have to implement them in your project. ```kotlin -const val PIXI_KOTLIN_VERSION = "0.5.0" +const val PIXI_KOTLIN_VERSION = "VERSION" dependencies { implementation("io.github.ayfri:PIXI-Kotlin:PIXI_KOTLIN_VERSION") @@ -42,13 +42,13 @@ Simple application with a sprite, size change when clicking. ```kotlin fun main() { - val app = Application { + val app = application { backgroundColor = Color(120, 200, 230) resizeTo = window } app.addToBody() - val bunny = Sprite.from("bunny.png").apply { + val bunny = sprite("bunny.png") { setPositionFromWindow(0.5, 0.5) anchor.set(0.5) interactive = true @@ -69,17 +69,17 @@ Application with keymap and test if sprite sticks out of area. ```kotlin fun main() { - val app = Application { + val app = application { resizeTo = window } app.addToBody() val speed = 10.0 - val sprite = Sprite(generateBlankTexture(app) { + val sprite = sprite(generateBlankTexture(app) { width = 300.0 height = 300.0 color = Color(255, 0, 0) - }).apply { + }) { addToApplication(app) anchor.set(0.5) setPositionFromApplication(app, 0.5, 0.5)