# setCircle breaks isStatic?

**URL:** <https://phaser.discourse.group/t/setcircle-breaks-isstatic/5635>\
**Category:** Phaser 3\
**Created:** [March 25, 2020, 4:50pm UTC](https://phaser.discourse.group/t/setcircle-breaks-isstatic/5635 "2020-03-25T16:50:56Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![rorywalsh](https://yyz2.discourse-cdn.com/free1/user_avatar/phaser.discourse.group/rorywalsh/32/325_2.png) [@rorywalsh](https://phaser.discourse.group/u/rorywalsh)\
**Post date:** [March 25, 2020, 4:50pm UTC](https://phaser.discourse.group/t/setcircle-breaks-isstatic/5635/1 "2020-03-25T16:50:56Z")

</div>

In the following simple [demo](https://repl.it/@RoryWalsh1/PhaserMatterCircle) I create a matter image and set it to `isStatic`. As soon as I call `setCircle()` is falls through the air. Is this not possible? I would like to have a bunch of circular static objects…

---

<div class="post-metadata">

**Author:** ![rorywalsh](https://yyz2.discourse-cdn.com/free1/user_avatar/phaser.discourse.group/rorywalsh/32/325_2.png) [@rorywalsh](https://phaser.discourse.group/u/rorywalsh)\
**Post date:** [March 25, 2020, 7:56pm UTC](https://phaser.discourse.group/t/setcircle-breaks-isstatic/5635/2 "2020-03-25T19:56:49Z")

</div>

For future reference I was able to solve this by explicitly calling `setIgnoreGravity()` and `setStatic()`. I’d still like to know if this is a bug or expected behavior…

---

<div class="post-metadata">

**Author:** ![Telinc1](https://yyz2.discourse-cdn.com/free1/user_avatar/phaser.discourse.group/telinc1/32/60_2.png) [@Telinc1](https://phaser.discourse.group/u/Telinc1)\
**Post date:** [March 25, 2020, 8:52pm UTC](https://phaser.discourse.group/t/setcircle-breaks-isstatic/5635/3 "2020-03-25T20:52:11Z")

</div>

It looks like [`setCircle` recreates the body](https://github.com/photonstorm/phaser/blob/v3.22.0/src/physics/matter-js/components/SetBody.js#L43), which destroys the existing options. You should be able to work around this by declaring the body as a [static circle when you create it](https://photonstorm.github.io/phaser3-docs/Phaser.Physics.Matter.Image.html#Image) ([you can pass in a `shape`](https://github.com/photonstorm/phaser/blob/v3.22.0/src/physics/matter-js/MatterImage.js#L112), which doesn’t appear to be documented).

I don’t really work with Matter, so don’t quote me on any of this.

---

<div class="post-metadata">

**Author:** ![rorywalsh](https://yyz2.discourse-cdn.com/free1/user_avatar/phaser.discourse.group/rorywalsh/32/325_2.png) [@rorywalsh](https://phaser.discourse.group/u/rorywalsh)\
**Post date:** [March 25, 2020, 9:02pm UTC](https://phaser.discourse.group/t/setcircle-breaks-isstatic/5635/4 "2020-03-25T21:02:10Z")

</div>

Thanks @Telinc1, that makes sense. I’ll check out the `shape` option. 👍
