From 298bc9496b7bda261a6b37b24b7277b0a7a78ea3 Mon Sep 17 00:00:00 2001 From: Hyper_ Date: Sun, 22 Sep 2024 18:05:25 -0300 Subject: [PATCH 1/4] Upgrade API versions --- example_mods/introMod/_polymod_meta.json | 2 +- example_mods/testing123/_polymod_meta.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/example_mods/introMod/_polymod_meta.json b/example_mods/introMod/_polymod_meta.json index 4dc0cd804..74c4a2504 100644 --- a/example_mods/introMod/_polymod_meta.json +++ b/example_mods/introMod/_polymod_meta.json @@ -6,7 +6,7 @@ "name": "EliteMasterEric" } ], - "api_version": "0.1.0", + "api_version": "0.5.0", "mod_version": "1.0.0", "license": "Apache-2.0" } diff --git a/example_mods/testing123/_polymod_meta.json b/example_mods/testing123/_polymod_meta.json index 0a2ed042c..b8fc60b11 100644 --- a/example_mods/testing123/_polymod_meta.json +++ b/example_mods/testing123/_polymod_meta.json @@ -6,7 +6,7 @@ "name": "EliteMasterEric" } ], - "api_version": "0.1.0", + "api_version": "0.5.0", "mod_version": "1.0.0", "license": "Apache-2.0" } From ffd76963bd736195ce23f2526acdbbbea6513da1 Mon Sep 17 00:00:00 2001 From: Abnormal <86753001+AbnormalPoof@users.noreply.github.com> Date: Thu, 26 Sep 2024 21:04:23 +0000 Subject: [PATCH 2/4] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index b1e16f6de..34ec930f6 100644 --- a/README.md +++ b/README.md @@ -19,7 +19,7 @@ Please check out our [Contributor's guide](./CONTRIBUTORS.md) on how you can act # Credits and Special Thanks -Full credits can be found in-game, or wherever the credits.json file is. +Full credits can be found in-game, or in the `credits.json` file which is located [here](https://github.com/FunkinCrew/funkin.assets/blob/main/exclude/data/credits.json). ## Programming - [ninjamuffin99](https://twitter.com/ninja_muffin99) - Lead Programmer From cd2b458da2ed2eeea46893dfccbb289f34ee8415 Mon Sep 17 00:00:00 2001 From: AbnormalPoof Date: Fri, 27 Sep 2024 15:15:35 -0500 Subject: [PATCH 3/4] add flipx and flipy --- source/funkin/data/stage/StageData.hx | 16 ++++++++++++++++ source/funkin/play/stage/Stage.hx | 3 +++ 2 files changed, 19 insertions(+) diff --git a/source/funkin/data/stage/StageData.hx b/source/funkin/data/stage/StageData.hx index eda8e3148..1e9172b00 100644 --- a/source/funkin/data/stage/StageData.hx +++ b/source/funkin/data/stage/StageData.hx @@ -118,6 +118,22 @@ typedef StageDataProp = @:default(false) var isPixel:Bool; + /** + * If set to true, the prop will be flipped horizontally. + * @default false + */ + @:optional + @:default(false) + var flipX:Bool; + + /** + * If set to true, the prop will be flipped vertically. + * @default false + */ + @:optional + @:default(false) + var flipY:Bool; + /** * Either the scale of the prop as a float, or the [w, h] scale as an array of two floats. * Pro tip: On pixel-art levels, save the sprite small and set this value to 6 or so to save memory. diff --git a/source/funkin/play/stage/Stage.hx b/source/funkin/play/stage/Stage.hx index c42e41cad..c237005cf 100644 --- a/source/funkin/play/stage/Stage.hx +++ b/source/funkin/play/stage/Stage.hx @@ -258,6 +258,9 @@ class Stage extends FlxSpriteGroup implements IPlayStateScriptedClass implements propSprite.zIndex = dataProp.zIndex; + propSprite.flipX = dataProp.flipX; + propSprite.flipY = dataProp.flipY; + switch (dataProp.animType) { case 'packer': From 7ce7d7839ea296dad3d8abd3909dfdbf1592131f Mon Sep 17 00:00:00 2001 From: EliteMasterEric Date: Sat, 28 Sep 2024 09:51:41 -0400 Subject: [PATCH 4/4] Update stage data version after adding new values. --- source/funkin/data/stage/CHANGELOG.md | 4 ++++ source/funkin/data/stage/StageRegistry.hx | 4 ++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/source/funkin/data/stage/CHANGELOG.md b/source/funkin/data/stage/CHANGELOG.md index 879139db5..bf9d750cc 100644 --- a/source/funkin/data/stage/CHANGELOG.md +++ b/source/funkin/data/stage/CHANGELOG.md @@ -5,6 +5,10 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [1.0.2] +### Added +- Added the ability to specify `flipX` and `flipY` on stage props to horizontally or vertically flip, respectively. + ## [1.0.1] ### Added - Added the ability to specify a hexadecimal color in the `assetPath` field instead of a texture key. diff --git a/source/funkin/data/stage/StageRegistry.hx b/source/funkin/data/stage/StageRegistry.hx index 87113ef05..e11166bdd 100644 --- a/source/funkin/data/stage/StageRegistry.hx +++ b/source/funkin/data/stage/StageRegistry.hx @@ -11,9 +11,9 @@ class StageRegistry extends BaseRegistry * Handle breaking changes by incrementing this value * and adding migration to the `migrateStageData()` function. */ - public static final STAGE_DATA_VERSION:thx.semver.Version = "1.0.0"; + public static final STAGE_DATA_VERSION:thx.semver.Version = "1.0.2"; - public static final STAGE_DATA_VERSION_RULE:thx.semver.VersionRule = "1.0.x"; + public static final STAGE_DATA_VERSION_RULE:thx.semver.VersionRule = ">=1.0.0 <=1.0.2"; public static var instance(get, never):StageRegistry; static var _instance:Null = null;