# \[Solved\]setSize not working on scaled sprites

**URL:** <https://phaser.discourse.group/t/solved-setsize-not-working-on-scaled-sprites/3714>\
**Category:** Phaser 3\
**Created:** [September 13, 2019, 2:44pm UTC](https://phaser.discourse.group/t/solved-setsize-not-working-on-scaled-sprites/3714 "2019-09-13T14:44:21Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![n3s7or](https://yyz2.discourse-cdn.com/free1/user_avatar/phaser.discourse.group/n3s7or/32/2043_2.png) [@n3s7or](https://phaser.discourse.group/u/n3s7or)\
**Post date:** [September 13, 2019, 2:44pm UTC](https://phaser.discourse.group/t/solved-setsize-not-working-on-scaled-sprites/3714/1 "2019-09-13T14:44:21Z")

</div>

Hello, after almost two years I decided to give me a try to Phaser again to create some silly games. The deal is that I need to set a different size for collision but it is not working. Look the code below and the picture.

![post](https://global.discourse-cdn.com/free1/uploads/phaser1/original/2X/d/dd58dc8e11aca537e9ab4c11bd5b6abf30cdfbce.png)

```
this.platform = this.physics.add.staticGroup();
this.platform.create( this.platformPos.x-140*.4, this.platformPos.y, 'pltf1')
			.setOrigin(0,1)
			.setSize(140,100)
			.setScale(.4)
			.refreshBody();
this.platform.create( this.platformPos.x, this.platformPos.y, 'pltf2')
			.setOrigin(0,1)
			.setSize(140,100)
			.setScale(.4)
			.refreshBody();
this.platform.create( this.platformPos.x+140*.4, this.platformPos.y, 'pltf3')
			.setOrigin(0,1)
			.setSize(140,100)
			.setScale(.4)
			.refreshBody();

```

Thanks in advance

---

<div class="post-metadata">

**Author:** ![BdR](https://yyz2.discourse-cdn.com/free1/user_avatar/phaser.discourse.group/bdr/32/2621_2.png) [@BdR](https://phaser.discourse.group/u/BdR)\
**Post date:** [September 13, 2019, 11:20pm UTC](https://phaser.discourse.group/t/solved-setsize-not-working-on-scaled-sprites/3714/2 "2019-09-13T23:20:09Z")

</div>

I think the problem is that you are doing the `setSize` on the sprite instead of on the body of the sprite.  
Try something like this:

```
this.platform = this.physics.add.staticGroup();

var mysprite1 = this.platform.create(this.platformPos.x-140*.4, this.platformPos.y, 'pltf1')
			.setOrigin(0,1)
			.setScale(.4)
			.refreshBody();

mysprite1.body.setSize(140,100);

var mysprite2 = this.platform.create( // ... etc.
```

---

<div class="post-metadata">

**Author:** ![n3s7or](https://yyz2.discourse-cdn.com/free1/user_avatar/phaser.discourse.group/n3s7or/32/2043_2.png) [@n3s7or](https://phaser.discourse.group/u/n3s7or)\
**Post date:** [September 14, 2019, 4:10pm UTC](https://phaser.discourse.group/t/solved-setsize-not-working-on-scaled-sprites/3714/3 "2019-09-14T16:10:04Z")

</div>

Thanks, it worked. It seems I misunderstood the docs.
