```
Package Name Current Version Updated Version Update Reason
flame 1.16.0 1.17.0 manual versioning
flame_forge2d 0.17.0 0.17.1 manual versioning
flame_oxygen 0.2.0 0.2.1 manual versioning
behavior_tree 0.1.0 0.1.1 updated with minor changes
flame_behavior_tree 0.1.0 0.1.1 updated with minor changes
flame_network_assets 0.3.0 0.3.1 updated with minor changes
flame_sprite_fusion 0.1.0 0.1.1 updated with minor changes
flame_texturepacker 3.1.0 3.2.0 updated with minor changes
flame_tiled 1.19.0 1.20.0 updated with minor changes
flame_test 1.16.0 1.16.1 dependency was updated
flame_isolate 0.6.0 0.6.0+1 dependency was updated
flame_fire_atlas 1.5.0 1.5.1 dependency was updated
flame_audio 2.10.0 2.10.1 dependency was updated
flame_spine 0.2.0 0.2.0+1 dependency was updated
flame_bloc 1.11.0 1.11.1 dependency was updated
flame_lottie 0.4.0 0.4.0+1 dependency was updated
flame_markdown 0.2.0 0.2.0+1 dependency was updated
flame_rive 1.10.0 1.10.1 dependency was updated
flame_noise 0.3.0 0.3.0+1 dependency was updated
flame_riverpod 5.4.0 5.4.1 dependency was updated
flame_svg 1.10.0 1.10.1 dependency was updated
```
```
The following 18 packages will be updated:
Package Name Current Version Updated Version Update Reason
flame 1.14.0 1.15.0 updated with minor changes
flame_isolate 0.5.0+7 0.5.1 updated with minor changes
flame_noise 0.1.1+12 0.2.0 updated with major changes
flame_riverpod 5.1.5 5.2.0 updated with minor changes
flame_test 1.15.3 1.15.4 updated with patch changes
flame_texturepacker 2.1.0 3.0.0 updated with major changes
flame_oxygen 0.1.9+7 0.1.9+8 dependency was updated
flame_tiled 1.18.3 1.18.4 dependency was updated
flame_fire_atlas 1.4.7 1.4.8 dependency was updated
flame_audio 2.1.7 2.1.8 dependency was updated
flame_spine 0.1.1+9 0.1.1+10 dependency was updated
flame_bloc 1.10.9 1.10.10 dependency was updated
flame_rive 1.9.10 1.9.11 dependency was updated
flame_lottie 0.3.0+7 0.3.0+8 dependency was updated
flame_markdown 0.1.1+7 0.1.1+8 dependency was updated
flame_forge2d 0.16.0+4 0.16.0+5 dependency was updated
flame_svg 1.8.9 1.8.10 dependency was updated
flame_network_assets 0.2.0+12 0.2.0+13 dependency was updated
```
```
The following 17 packages will be updated:
Package Name Current Version Updated Version Update Reason
flame 1.11.0 1.12.0 updated with minor changes
flame_riverpod 5.0.0 5.1.0 updated with minor changes
flame_test 1.15.0 1.15.1 dependency was updated
flame_tiled 1.18.0 1.18.1 dependency was updated
flame_oxygen 0.1.9+4 0.1.9+5 dependency was updated
flame_isolate 0.5.0+4 0.5.0+5 dependency was updated
flame_fire_atlas 1.4.4 1.4.5 dependency was updated
flame_audio 2.1.4 2.1.5 dependency was updated
flame_spine 0.1.1+6 0.1.1+7 dependency was updated
flame_bloc 1.10.6 1.10.7 dependency was updated
flame_lottie 0.3.0+4 0.3.0+5 dependency was updated
flame_markdown 0.1.1+4 0.1.1+5 dependency was updated
flame_rive 1.9.7 1.9.8 dependency was updated
flame_forge2d 0.16.0+1 0.16.0+2 dependency was updated
flame_noise 0.1.1+9 0.1.1+10 dependency was updated
flame_svg 1.8.6 1.8.7 dependency was updated
flame_network_assets 0.2.0+9 0.2.0+10 dependency was updated
```
This small PR adjusts:
1. some `backticks` (`) in the platformer tutorial in order to have a
proper highlight of the file names.
2. replaces backslash (`\`) with slash (`/`) in order to be consistent
with the other file paths used in the tutorial.
3. renames the variable `_xOffset` to `xOffset` in order to be
consistent with the rest of the code.
Co-authored-by: Rodrigo Castro <rodrigo.desouzacastro@bahag.com>
This is a first step towards enabling DCM for Flame. Though I have tested with all rules, and am working on selecting, assessing, and fixing violations, as a first step, we can merge the infrastructural changes to flame_lint to and GitHub actions.
As a proof of concept, I am enabling two rules for which we have no violations.
I will followup with enabling more rules, adding discussions for controversial changes, and fixing non-controversial violations.
The update method should end up with the code in this order, otherwise the velocity is never set to 0.
Probably obvious but the rest of the steps were precise on where to include these code blocks.
May wanna add this full block to the end of this step as well, I spent a few minutes trying to figure out why it wasn't working propely.
This PR adds the following lint rules to our list:
```
always_put_required_named_parameters_first
avoid_multiple_declarations_per_line
avoid_positional_boolean_parameters
avoid_returning_null_for_void
avoid_returning_this
avoid_unnecessary_containers
enable_null_safety
library_private_types_in_public_api
no_leading_underscores_for_library_prefixes
no_leading_underscores_for_local_identifiers
prefer_null_aware_method_calls
tighten_type_of_initializing_formals
unnecessary_late
use_setters_to_change_properties
```
And these rules were considered, and some changes were made according to
them as a clean-up, but in many places they didn't make sense
(`prefer_asserts_with_message` I would have included, but there were too
many places that needed to be changes):
```
collection_methods_unrelated_type
prefer_asserts_with_message
avoid_renaming_method_parameters
```
<!--
The title of your PR on the line above should start with a [Conventional
Commit] prefix
(`fix:`, `feat:`, `docs:`, `test:`, `chore:`, `refactor:`, `perf:`,
`build:`, `ci:`,
`style:`, `revert:`). This title will later become an entry in the
[CHANGELOG], so please
make sure that it summarizes the PR adequately.
-->
# Description
<!--
Provide a description of what this PR is doing.
If you're modifying existing behavior, describe the existing behavior,
how this PR is changing it,
and what motivated the change. If this is a breaking change, specify
explicitly which APIs were
changed.
-->
@eukleshnin identified issues with building the documents locally on a
Windows workstation. Namely, the following was occurring:
```
reading sources... [ 2%] flame/layout/align_component
Exception occurred:
FileNotFoundError: [WinError 2]
```
This was determined to be a combination of several things.
1. In `dart_domain.py`, the `subprocess.run` calling dartdoc_json did
not have the shell parameter set to true. This solves the error about
the file not being found. This then generates errors that subsequent
references to the `temp_file` did not exist.
2. This was due to the default setting with Python `tempfile` where when
it determines the temp file has been closed, it deletes it; however, it
was still needed, so by setting the `delete=False` parameter, the file
would still remain.
3. Unfortunately, because it still remains, it needs to be deleted once
it is no longer needed. Trying to use `finally:` with the `try` block
failed to produce the results desired, so the temp file name was
registered with the class so it can be deleted in the original calling
function if it exists. This proved successful.
4. Although not critical, the same temp file uses a suffix of `json` so
it was creating files `xxxxjson`. By adding the "." in the suffix, it
creates valid file names now. This doesn't actually fix anything, it
just seemed wrong, so I fixed it to be valid files if ever needed down
the road.
Now that the docs built, there were several warnings that could be
resolved:
1. `Overlays.md` was not referenced in the TOC tree.
2. Since overlays were removed in
https://github.com/flame-engine/flame/pull/2384, the Platformer tutorial
had a link to the old path and it needed to be updated.
Finally and open for discussion, during this process of debugging, I
upgraded all packages to the most current to see what impacts there
were. The following is the old and new potential `requirements.txt`:
```
----Old
linkify-it-py==2.0.0
myst-parser==0.18.1
Pygments==2.12.0
Sphinx==5.0.2
sphinxcontrib-mermaid==0.8.1
sphinx-autobuild==2021.3.14
jinja2==3.1.2
----- New
linkify-it-py==2.0.0
myst-parser==1.0.0
Pygments==2.14.0
Sphinx==6.1.3
sphinxcontrib-mermaid==0.8.1
sphinx-autobuild==2021.3.14
Jinja2==3.1.2
```
The only byproduct of this upgrade was a deprecated package warning for
`attrs_image` in `conf.py` which was updated to `attrs_inline`. I made
that change initially for this PR, but backed it out as I didn't know if
there was a desire to update the `requirements.txt` and felt some
discussion may be warranted.
Regardless, with everything upgraded or left as is, the other fixes
resolve the issues on Windows.
## Checklist
<!--
Before you create this PR confirm that it meets all requirements listed
below by checking the
relevant checkboxes with `[x]`. If some checkbox is not applicable, mark
it as `[-]`.
-->
- [X] I have followed the [Contributor Guide] when preparing my PR.
- [ ] I have updated/added tests for ALL new/updated/fixed
functionality.
- [X] I have updated/added relevant documentation in `docs` and added
dartdoc comments with `///`.
- [ ] I have updated/added relevant examples in `examples` or `docs`.
## Breaking Change?
<!--
Would your PR require Flame users to update their apps following your
change?
If yes, then the title of the PR should include "!" (for example,
`feat!:`, `fix!:`). See
[Conventional Commit] for details. Also, for a breaking PR uncomment and
fill in the "Migration
instructions" section below.
### Migration instructions
If the PR is breaking, uncomment this header and add instructions for
how to migrate from the
currently released version to the new proposed way.
-->
- [ ] Yes, this PR is a breaking change.
- [X] No, this PR is not a breaking change.
## Related Issues
<!--
Indicate which issues this PR resolves, if any. For example:
Closes#1234
!-->
<!-- Links -->
[Contributor Guide]:
https://github.com/flame-engine/flame/blob/main/CONTRIBUTING.md
[Conventional Commit]: https://conventionalcommits.org
[CHANGELOG]:
https://github.com/flame-engine/flame/blob/main/CHANGELOG.md
---------
Co-authored-by: Lukas Klingsbo <me@lukas.fyi>
# Description
This does two things:
## Use double quotes for SDK constraints
Standardize the usage of single or double quotes to specify sdk
constraints across pubspecs
I see no reason this should not be kept consistent
I also see no reason to prefer one over the other, so I searched the
code base and there are 7 instances of single quote vs 32 of double
quotes, so I favored the later
## Update all SDK constraints to 2.18
Let me know if there are any issues with it, but I believe we should
keep this consistent across all packages.
Also there is a pubspec on root which imply all should be on 2.18
anyway.
## Checklist
- [x] I have followed the [Contributor Guide] when preparing my PR.
- [x] I have updated/added tests for ALL new/updated/fixed
functionality.
- [x] I have updated/added relevant documentation in `docs` and added
dartdoc comments with `///`.
- [x] I have updated/added relevant examples in `examples` or `docs`.
## Breaking Change?
- [ ] Yes, this PR is a breaking change.
- [x] No, this PR is not a breaking change.
<!-- Links -->
[Contributor Guide]:
https://github.com/flame-engine/flame/blob/main/CONTRIBUTING.md
[Conventional Commit]: https://conventionalcommits.org/
[CHANGELOG]:
https://github.com/flame-engine/flame/blob/main/CHANGELOG.md
Co-authored-by: Lukas Klingsbo <me@lukas.fyi>
The grid position variable is non-private: gridPosition in the PlatformBlock class definition but was used as private: _gridPosition in the onLoad method.
This PR updates the grid position variable in the onLoad to gridPosition.
The root level .gitignore file already works for all sub-repositories, so they are all actually unnecessary.
This PR leaves only the gitignore at the root of the repo, removing all others.
As discussed previously, this PR moves the Space Shooter Tutorial to the tutorials folder for direct inclusion in the docs. A few things to note, other than basic grammar and formatting, nothing was changed other than migrating the information to the current tutorial format. This should allow the tutorials.flame-engine.org subdomain to be deleted.
Note: Upon moving this tutorial, I discovered it is incomplete and missing the majority of the game.
Also, I realized that I left the android folder and some files that weren't necessary for the platform tutorial and have deleted those.
This adds a platformer tutorial called Ember Quest. I hope I have done a service, because I am tired, lol. I am sure there will be comments. I just want to say, I did my best. I approached this as someone new to Flame, just like I was about 10 months ago. Are there concepts that can be improved, sure. We can always optimize code, but I didn't want any concepts to be super abstract. I had never coded a game before when I began my journey with Flame this year, so things might be a bit simple for experienced game developers, but for myself, I had never even thought about a game loop or animations, etc.