Reverting doc rename
@ -1,7 +1,6 @@
|
|||||||
# CHANGELOG
|
# CHANGELOG
|
||||||
|
|
||||||
## [next]
|
## 0.21.0
|
||||||
- Updated the doc structure and minor language fixes
|
|
||||||
- Adding AssetsCache.readBinaryFile
|
- Adding AssetsCache.readBinaryFile
|
||||||
- Splitting debugMode from recordFps mode
|
- Splitting debugMode from recordFps mode
|
||||||
- Adding support for multi touch tap and drag events
|
- Adding support for multi touch tap and drag events
|
||||||
|
|||||||
@ -61,9 +61,9 @@ We also offer a curated list of Games, Libraries and Articles over at [awesome-f
|
|||||||
|
|
||||||
## Documentation
|
## Documentation
|
||||||
|
|
||||||
The complete documentation can be found [here](docs/README.md).
|
The complete documentation can be found [here](doc/README.md).
|
||||||
|
|
||||||
A lot of examples of different features can be found [here](docs/examples) and a good starting example can be found [here](./example).
|
A lot of examples of different features can be found [here](doc/examples) and a good starting example can be found [here](./example).
|
||||||
|
|
||||||
A very cool docs site can be found [here](https://flame-engine.org/).
|
A very cool docs site can be found [here](https://flame-engine.org/).
|
||||||
|
|
||||||
|
|||||||
@ -18,7 +18,7 @@ Put the pub package as your dependency by dropping the following in your `pubspe
|
|||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
dependencies:
|
dependencies:
|
||||||
flame: ^0.20.2
|
flame: ^0.21.0
|
||||||
```
|
```
|
||||||
|
|
||||||
And start using it!
|
And start using it!
|
||||||
@ -144,4 +144,4 @@ Already thinking about the neat graphics you'll add to your apps? Be sure to che
|
|||||||
|
|
||||||
This whole example is inside the examples folder for flame, and you can see [the source code](https://github.com/luanpotter/flame/tree/master/doc/examples/animation_widget), if you have any doubts or wanna test or run yourself. Also, the article is [committed as well](https://github.com/luanpotter/flame/tree/master/doc/animation_widget_article).
|
This whole example is inside the examples folder for flame, and you can see [the source code](https://github.com/luanpotter/flame/tree/master/doc/examples/animation_widget), if you have any doubts or wanna test or run yourself. Also, the article is [committed as well](https://github.com/luanpotter/flame/tree/master/doc/animation_widget_article).
|
||||||
|
|
||||||
If you liked Flame, leave your clap, star on GitHub, and please check out our [repository](https://github.com/luanpotter/flame) with full docs, examples, and issues you can ask. Also, for more in-depth questions, be sure to check our [Discord channel](https://discord.gg/pxrBmy4), where we try to answer questions and solve problems.
|
If you liked Flame, leave your clap, star on GitHub, and please check out our [repository](https://github.com/luanpotter/flame) with full doc, examples, and issues you can ask. Also, for more in-depth questions, be sure to check our [Discord channel](https://discord.gg/pxrBmy4), where we try to answer questions and solve problems.
|
||||||
|
Before Width: | Height: | Size: 3.4 MiB After Width: | Height: | Size: 3.4 MiB |
|
Before Width: | Height: | Size: 43 KiB After Width: | Height: | Size: 43 KiB |
|
Before Width: | Height: | Size: 229 KiB After Width: | Height: | Size: 229 KiB |
|
Before Width: | Height: | Size: 4.0 KiB After Width: | Height: | Size: 4.0 KiB |
|
Before Width: | Height: | Size: 1.5 MiB After Width: | Height: | Size: 1.5 MiB |
|
Before Width: | Height: | Size: 14 MiB After Width: | Height: | Size: 14 MiB |
|
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 1.3 KiB |
|
Before Width: | Height: | Size: 1.6 KiB After Width: | Height: | Size: 1.6 KiB |
@ -6,7 +6,7 @@ The source of the bundled box2d on Flame can be found [here](https://github.com/
|
|||||||
|
|
||||||
There is a simple example game [here](https://github.com/feroult/haunt) that can be used as reference of how to use box2d on Flame, although it is a little bit outdated and doesn't use `Box2DGame`.
|
There is a simple example game [here](https://github.com/feroult/haunt) that can be used as reference of how to use box2d on Flame, although it is a little bit outdated and doesn't use `Box2DGame`.
|
||||||
|
|
||||||
There are some updated examples of how to use it [here](/docs/examples/box2d), but they are not full game implementations.
|
There are some updated examples of how to use it [here](/doc/examples/box2d), but they are not full game implementations.
|
||||||
|
|
||||||
## BaseGame extension
|
## BaseGame extension
|
||||||
|
|
||||||
@ -14,7 +14,7 @@ If you are going to use Box2D in your project it can be a good idea to use the B
|
|||||||
|
|
||||||
It is called `Box2DGame` and it will control the adding and removal of Box2D's BodyComponents from your root `Box2DComponent`.
|
It is called `Box2DGame` and it will control the adding and removal of Box2D's BodyComponents from your root `Box2DComponent`.
|
||||||
|
|
||||||
A simple `Box2DGame` implementation example can be seen in the [examples folder](/docs/examples/box2d/simple).
|
A simple `Box2DGame` implementation example can be seen in the [examples folder](/doc/examples/box2d/simple).
|
||||||
|
|
||||||
## Contact callbacks
|
## Contact callbacks
|
||||||
|
|
||||||
@ -61,4 +61,4 @@ If you want an object to interact with all other bodies, put `BodyComponent` as
|
|||||||
|
|
||||||
`class BallAnythingCallback implements ContactCallback<Ball, BodyComponent> ...`
|
`class BallAnythingCallback implements ContactCallback<Ball, BodyComponent> ...`
|
||||||
|
|
||||||
An implementation example can be seen in the [examples folder](/docs/examples/box2d/contact_callbacks).
|
An implementation example can be seen in the [examples folder](/doc/examples/box2d/contact_callbacks).
|
||||||
@ -43,14 +43,14 @@ The `onDestroy` method can be overridden to run code before the component is rem
|
|||||||
|
|
||||||
There are also other implementations:
|
There are also other implementations:
|
||||||
|
|
||||||
* The `AnimationComponent` takes an `Animation` object and renders a cyclic animated sprite (more details about Animations [here](/docs/images.md#Animation))
|
* The `AnimationComponent` takes an `Animation` object and renders a cyclic animated sprite (more details about Animations [here](/doc/images.md#Animation))
|
||||||
* The `SvgComponent` takes an `Svg` object and renders the SVG on the game
|
* The `SvgComponent` takes an `Svg` object and renders the SVG on the game
|
||||||
* The `ParallaxComponent` can render a parallax background with several frames
|
* The `ParallaxComponent` can render a parallax background with several frames
|
||||||
* The `Box2DComponent`, that has a physics engine built-in (using the [Box2D](https://github.com/google/box2d.dart) port for Dart)
|
* The `Box2DComponent`, that has a physics engine built-in (using the [Box2D](https://github.com/google/box2d.dart) port for Dart)
|
||||||
|
|
||||||
## Animation Component
|
## Animation Component
|
||||||
|
|
||||||
This component uses an instance of the [Animation](/docs/images.md#Animation) class to represent a Component that has a sprite that runs a single cyclic animation.
|
This component uses an instance of the [Animation](/doc/images.md#Animation) class to represent a Component that has a sprite that runs a single cyclic animation.
|
||||||
|
|
||||||
This will create a simple three frame animation
|
This will create a simple three frame animation
|
||||||
|
|
||||||
@ -59,7 +59,7 @@ This will create a simple three frame animation
|
|||||||
this.player = AnimationComponent(64.0, 64.0, new Animation.spriteList(sprites, stepTime: 0.01));
|
this.player = AnimationComponent(64.0, 64.0, new Animation.spriteList(sprites, stepTime: 0.01));
|
||||||
```
|
```
|
||||||
|
|
||||||
If you have a sprite sheet, you can use the `sequenced` constructor, identical to the one provided by the `Animation` class (check more details in [the appropriate section](/docs/images.md#Animation)):
|
If you have a sprite sheet, you can use the `sequenced` constructor, identical to the one provided by the `Animation` class (check more details in [the appropriate section](/doc/images.md#Animation)):
|
||||||
|
|
||||||
```dart
|
```dart
|
||||||
this.player = AnimationComponent.sequenced(64.0, 64.0, 'player.png', 2);
|
this.player = AnimationComponent.sequenced(64.0, 64.0, 'player.png', 2);
|
||||||
@ -80,7 +80,7 @@ This component uses an instance of `Svg` class to represent a Component that has
|
|||||||
|
|
||||||
## FlareAnimation Component
|
## FlareAnimation Component
|
||||||
|
|
||||||
This component wraps an instance of the [FlareAnimation](/docs/images.md#FlareAnimation), it receives the filename of the Flare animation file, which animation from that file you want to use, and the `width` and `height` of the rendered animation.
|
This component wraps an instance of the [FlareAnimation](/doc/images.md#FlareAnimation), it receives the filename of the Flare animation file, which animation from that file you want to use, and the `width` and `height` of the rendered animation.
|
||||||
|
|
||||||
```dart
|
```dart
|
||||||
final fileName = "assets/Bob_Minion.flr";
|
final fileName = "assets/Bob_Minion.flr";
|
||||||
@ -96,7 +96,7 @@ This component wraps an instance of the [FlareAnimation](/docs/images.md#FlareAn
|
|||||||
|
|
||||||
You can also change the current playing animation using the `updateAnimation` method.
|
You can also change the current playing animation using the `updateAnimation` method.
|
||||||
|
|
||||||
For a working example, check this [source file](/docs/examples/flare/lib/main_component.dart).
|
For a working example, check this [source file](/doc/examples/flare/lib/main_component.dart).
|
||||||
|
|
||||||
## Composed component
|
## Composed component
|
||||||
|
|
||||||
@ -179,7 +179,7 @@ Once you are done with setting the parameters to your needs, render the Parallax
|
|||||||
Like the AnimationComponent, even if your parallax is static, you must call update on this component, so it runs its animation.
|
Like the AnimationComponent, even if your parallax is static, you must call update on this component, so it runs its animation.
|
||||||
Also, don't forget to add you images to the `pubspec.yaml` file as assets or they wont be found.
|
Also, don't forget to add you images to the `pubspec.yaml` file as assets or they wont be found.
|
||||||
|
|
||||||
An example implementation can be found in the [examples directory](/docs/examples/parallax).
|
An example implementation can be found in the [examples directory](/doc/examples/parallax).
|
||||||
|
|
||||||
## Box2D Component
|
## Box2D Component
|
||||||
|
|
||||||
@ -191,13 +191,13 @@ So you can have HUD and other non-physics-related components in your game list,
|
|||||||
|
|
||||||
You can see a more complete example of box2d usage on [this WIP game](https://github.com/feroult/haunt) made by @feroult (beware, though, it uses 0.6.x version of flame, but the Box2D related apis are unchanged).
|
You can see a more complete example of box2d usage on [this WIP game](https://github.com/feroult/haunt) made by @feroult (beware, though, it uses 0.6.x version of flame, but the Box2D related apis are unchanged).
|
||||||
|
|
||||||
More information about Box2D can be found [here](/docs/box2d.md).
|
More information about Box2D can be found [here](/doc/box2d.md).
|
||||||
|
|
||||||
## Tiled Component
|
## Tiled Component
|
||||||
|
|
||||||
Currently we have a very basic implementation of a Tiled component. This API uses the lib [Tiled](https://github.com/feroult/tiled.dart) to parse map files and render visible layers.
|
Currently we have a very basic implementation of a Tiled component. This API uses the lib [Tiled](https://github.com/feroult/tiled.dart) to parse map files and render visible layers.
|
||||||
|
|
||||||
An example of how to use the API can be found [here](/docs/examples/tiled).
|
An example of how to use the API can be found [here](/doc/examples/tiled).
|
||||||
|
|
||||||
# Nine Tile Box Component
|
# Nine Tile Box Component
|
||||||
|
|
||||||
@ -213,6 +213,6 @@ Check the example app `nine_tile_box` details on how to use it.
|
|||||||
|
|
||||||
## Effects
|
## Effects
|
||||||
|
|
||||||
Flame provides a set of effects that can be applied to a certain type of components, these effects can be used to animate some properties of your components, like position or dimensions. You can check the list of those effects [here](/docs/effects.md)
|
Flame provides a set of effects that can be applied to a certain type of components, these effects can be used to animate some properties of your components, like position or dimensions. You can check the list of those effects [here](/doc/effects.md)
|
||||||
|
|
||||||
Examples of the running effects can be found [here](/docs/examples/effects.md);
|
Examples of the running effects can be found [here](/doc/examples/effects.md);
|
||||||
@ -4,4 +4,4 @@ Flame provides some features for debugging, these features are enabled when the
|
|||||||
|
|
||||||
In addition to the debugMode, you can also ask BaseGame to record the fps, that is enabled by overriding the `recordFps` method to return `true`, by doing so, you can access the current fps by using the method `fps`.
|
In addition to the debugMode, you can also ask BaseGame to record the fps, that is enabled by overriding the `recordFps` method to return `true`, by doing so, you can access the current fps by using the method `fps`.
|
||||||
|
|
||||||
To see a working example of the debugging features, [check this example](/docs/examples/debug).
|
To see a working example of the debugging features, [check this example](/doc/examples/debug).
|
||||||
@ -48,4 +48,4 @@ square.addEffect(ScaleEffect(
|
|||||||
|
|
||||||
# Examples
|
# Examples
|
||||||
|
|
||||||
Full examples can be found [here](/docs/examples/effects/simple) and [here](/docs/examples/effects/infinite_effects).
|
Full examples can be found [here](/doc/examples/effects/simple) and [here](/doc/examples/effects/infinite_effects).
|
||||||
|
Before Width: | Height: | Size: 4.0 KiB After Width: | Height: | Size: 4.0 KiB |
|
Before Width: | Height: | Size: 1.7 KiB After Width: | Height: | Size: 1.7 KiB |
|
Before Width: | Height: | Size: 92 KiB After Width: | Height: | Size: 92 KiB |
|
Before Width: | Height: | Size: 1.7 KiB After Width: | Height: | Size: 1.7 KiB |
|
Before Width: | Height: | Size: 471 B After Width: | Height: | Size: 471 B |