Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FlxG.camera.bgColor isn't reset on state switch #3254

Merged
merged 1 commit into from
Sep 19, 2024

Conversation

DetectiveBaldi
Copy link
Contributor

@DetectiveBaldi DetectiveBaldi commented Sep 18, 2024

Fixes #3252

We need to reset FlxG.camera to null when FlxG.cameras.reset is called, otherwise when resetting the state, the newly generated camera will have the previous FlxG.camera's bgColor.

This is a breaking change: more information here.

@Geokureli Geokureli added this to the 6.0.0 milestone Sep 19, 2024
@Geokureli Geokureli merged commit 6bc06aa into HaxeFlixel:release6 Sep 19, 2024
10 checks passed
@Geokureli
Copy link
Member

thx homie

@DetectiveBaldi DetectiveBaldi deleted the bgColorPatch branch September 19, 2024 19:11
Geokureli added a commit that referenced this pull request Jan 31, 2025
* Fix FlxSpriteGroup origin (#2981)

* update children origins relative to their positions

* add originTransform unit test

* Better framerate independant camera lerping (#2922)

* adjust lerp based on the current frame rate

* better framerate independant camera lerping

* fix error

* remove setter

* docs

* fix default lerp in follow()

* fix typo

* add #2981 and #2922

* Flxstate new (#2733)

* take FlxState constructor instead of FlxState

* add NextState type

* 4.0.5 fixes

* more 4.0.5 fixes

* fix deprecation warnings in unit tests

* take nextState in VCRFrontEnd

* remove @from Instance in InitialState

* use is operator

* improve docs

* rename method

* more docs

* more modular FlxSplash, set _gameJustStarted in FlxGame

* allow splash to be skipped by a switchState call

* touch-ups for #2733 (#3003)

* take FlxState constructor instead of FlxState

* add NextState type

* 4.0.5 fixes

* more 4.0.5 fixes

* fix deprecation warnings in unit tests

* take nextState in VCRFrontEnd

* remove @from Instance in InitialState

* use is operator

* improve docs

* rename method

* more docs

* more modular FlxSplash, set _gameJustStarted in FlxGame

* allow splash to be skipped by a switchState call

* touch-ups

* add #2733

* Remove deprecated features (#3048)

* remove deprecated features

* more removals

* Update FlxCamera.hx

* remove defaultCameras

* Default zoom (#2907)

* add bindScrollPos

* improve SCREEN_BY_SCREEN follow mode

* make cameras suck less when using FlxCamera.defaultZoom <> 1.0

* Replace references to FlxG.camera with this.getDefaultCamera (#3072)

* add getDefaultCamera, stop using FlxG.camera for everything

* more uses of getDefaultCamera

* fix flxpath

* changelog

* Calculate adjustedLerp only when necessary (#3106)

* Calculate adjustedLerp only when necessary

* Skip updateLerp on followLerp <= 0

* replace boundLerp with gt/lt checks

---------

Co-authored-by: George Kurelic <[email protected]>

* style

* 1 line patch? (#3254)

* update haxelib after merge

* Log pos (#3338)

* change logs to include posInfos

* fix flash errors

* D'oh

* update Changelog

* Add analog directional input to FlxVirtualPad (#3340)

* add overloaded scale

* add FlxReadOnlyPoint

* deprecate statusAnimations

* fix drawCircle centering

* Add analog stick to FlxVirtualPad

* fix code climate

* D'oh

* fix coverage

* fix flash

* add distance overloads

* add FlxMath.getFrameLerp

* honor camera in checkInput

* add FlxVirtualStick deprecate FlxAnalog

* rename to getElapsedLerp

* fix multi-touch

* D'oh!

* doc

* add FlxAnalogState helpers

* rename signals, add statuses

* add deadzone

* remove lerp constructor arg

* fix unit test warning

* overload more shit

* 5.10.0

* change 5.10->6

* Remove unused legacy code & defines (#3059)

* Remove legacy code & defines
- Removed `FLX_POST_PROCESS` define &  related code
- Removed references to `openfl_next`, `lime_legacy` &  `next` defines
- Removed Lime & OpenFL version checks that are always true/false due to the current minimum versions

* Removed `legacy` define being set in include.xml

* Re-added `#if !flash` check in `initRenderMethod`

I mistakenly removed the entire code due to it including `lime_legacy`.

* Brought back `undump()` & `canBeDumped` as `refreshBitmap()` & `canBeRefreshed` respectively (old ones are now deprecated)
- Also brought back `onAssetsReload()` & `getBitmapFromSystem()`

* Added missing line breaks

* remove old import

* Remove another deprecated define

* Restored mistakenly-removed define check

* Rename `refreshBitmap()` to `refresh()`

---------

Co-authored-by: George FunBook <[email protected]>

* FlxSave: Replace `FlxSaveStatus.ERROR` with SAVE_ERROR (#3294)

* replace `FlxSaveStatus.ERROR` with SAVE_ERROR

* update changelog

* add link

* Add deprecated  ERROR back

* remove implicit int casts to/from directions (#3308)

* remove implicit int casts to/from directions

* D'oh

* D'oh!

* deprecate operators and fix haxe 4.2.5

* order imports

* remove casts, add explicit cast functions

* fix not() and add tests

* Doc

* doc + tests

* update changelog

* finalize(?) changelog

* enable glsl3 (when openfl does) (#3347)

* update Changelog

* prepare for release

---------

Co-authored-by: 47rooks <[email protected]>
Co-authored-by: rich <[email protected]>
Co-authored-by: DetectiveBaldi <[email protected]>
Co-authored-by: Flainn <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants