# Polyline coordinates

**URL:** <https://discourse.mapeditor.org/t/polyline-coordinates/3322>\
**Category:** Questions\
**Created:** [July 27, 2018, 12:29pm UTC](https://discourse.mapeditor.org/t/polyline-coordinates/3322 "2018-07-27T12:29:10Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Shahjada\_Ahmed](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.mapeditor.org/shahjada_ahmed/32/2073_2.png) [@Shahjada\_Ahmed](https://discourse.mapeditor.org/u/Shahjada_Ahmed)\
**Post date:** [July 27, 2018, 12:29pm UTC](https://discourse.mapeditor.org/t/polyline-coordinates/3322/1 "2018-07-27T12:29:10Z")

</div>

I have a query about polyline coordinates.  
How can I obtain the polyline coordinates from Tiled map editor?  
I know the coordinate information reside inside map.json file.  
Is there a way it can be passed on to corona lua code?

I can see an offset in the simulator for the whole polyline and I would like to correct it using code.  
Image link : [https://goo.gl/P6PzNR](https://goo.gl/P6PzNR)

---

<div class="post-metadata">

**Author:** ![bjorn](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.mapeditor.org/bjorn/32/1599_2.png) [@bjorn](https://discourse.mapeditor.org/u/bjorn)\
**Post date:** [July 27, 2018, 12:58pm UTC](https://discourse.mapeditor.org/t/polyline-coordinates/3322/2 "2018-07-27T12:58:53Z")

</div>

> [@Shahjada\_Ahmed](#):
>
> How can I obtain the polyline coordinates from Tiled map editor?

The coordinates of the points of each polygon are stored relative to the position of the polygon object. As long as you did not rotate the object, that means to get the absolute positions of the points on the polygon, you’d just need to add the x/y position of the object to the x/y position of each polygon point.

If you do sometimes rotate your objects, you’d need to apply this rotation as well to get absolute positions. Rotation happens around the position of the object.

If you applied an offset to your object layer, then you should take that into account as well.

---

<div class="post-metadata">

**Author:** ![Shahjada\_Ahmed](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.mapeditor.org/shahjada_ahmed/32/2073_2.png) [@Shahjada\_Ahmed](https://discourse.mapeditor.org/u/Shahjada_Ahmed)\
**Post date:** [July 27, 2018, 2:35pm UTC](https://discourse.mapeditor.org/t/polyline-coordinates/3322/3 "2018-07-27T14:35:08Z")

</div>

Thanks for the response.  
My question was : programmatically how I can extract these points from Tiled map so that I can manipulate/adjust them. Do I need to extract them from map.json file?  
Thanks.

---

<div class="post-metadata">

**Author:** ![Shahjada\_Ahmed](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.mapeditor.org/shahjada_ahmed/32/2073_2.png) [@Shahjada\_Ahmed](https://discourse.mapeditor.org/u/Shahjada_Ahmed)\
**Post date:** [July 30, 2018, 11:47am UTC](https://discourse.mapeditor.org/t/polyline-coordinates/3322/4 "2018-07-30T11:47:33Z")

</div>

This thread can be resolved now. There was an issue with Berry Tiled loader regarding polylines appearance in corona simulator, which was resolved yesterday
