« first day    last day (29 days later) » 

04:56
if ellipse.setCircledoesn't work it must be ellipse.body.setCircle. But I will write a small demo, and confirm this (in the next few). minutes
 
2 hours later…
06:47
@MohsinUddinAbir I updated my answer with a running demo, I hope this help. :)
 
1 hour later…
08:07
Thank you so much for your answer.
But I wanted more specifics, maybe I can do it by custom properties. Because, there have a lot of different types of objects, like trees, houses, etc, and collision shapes can be ellipses/rectangles/polygons, I wanted to place them with a loop.
 
10 hours later…
18:17
@MohsinUddinAbir You can use custom properties, but phaser already has the basic properties covered photonstorm.github.io/phaser3-docs/…
for rectangle, ellipse and point. As mentioned before. Arcade physics doesn't support any other geometric shape
You would only have to use if/else blocks if(obj.rectangle){ ... }else if(obj.ellipse){ ... }else if(obj.point){... } in the for-loop
18:32
@MohsinUddinAbir I updated my answer to show this.
 
1 hour later…
19:50
btw: the phaser documentation is pretty good photonstorm.github.io/phaser3-docs/Phaser.Tilemaps.Tilemap.html and also the official demo cover many points (like phaser.io/examples/v3/view/tilemap/tileset-collision-shapes ) just beware some examples use matter physics

« first day    last day (29 days later) »