# Specific expansions with plugins

**URL:** <https://discourse.mapeditor.org/t/specific-expansions-with-plugins/1325>\
**Category:** Suggestions\
**Created:** [May 2, 2016, 3:13pm UTC](https://discourse.mapeditor.org/t/specific-expansions-with-plugins/1325 "2016-05-02T15:13:02Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![shoxsz](https://avatars.discourse-cdn.com/v4/letter/s/f475e1/32.png) [@shoxsz](https://discourse.mapeditor.org/u/shoxsz)\
**Post date:** [May 2, 2016, 3:13pm UTC](https://discourse.mapeditor.org/t/specific-expansions-with-plugins/1325/1 "2016-05-02T15:13:02Z")

</div>

It is my first time using tiled and found the necessity to create graphs inside of a map, i did it using the object layer, so i thought: the editor could have it as a native functionality, because defining the connections of the nodes was kind hard and handy, and it gave me the idea that the tiled could suport plugins, so the user can supply some specific necessity he needs. A platform to list the plugins would also be good. Tell me what you guys think about that. Thanks for attention.

---

<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:** [May 2, 2016, 7:42pm UTC](https://discourse.mapeditor.org/t/specific-expansions-with-plugins/1325/2 "2016-05-02T19:42:50Z")

</div>

> [@shoxsz](#):
>
> It is my first time using tiled and found the necessity to create graphs inside of a map, i did it using the object layer, so i thought: the editor could have it as a native functionality, because defining the connections of the nodes was kind hard and handy

I think you mean a feature like described in the following GitHub issue:

> <https://github.com/mapeditor/tiled/issues/707>
>
> Currently looking through Tiled to see if I can use it for a couple of my projec…ts. I can get round most of my issues ( default properties on objects, easily creating objects of type ), but the one feature that would find very useful is the ability to connect two objects.
> 
> Sometimes you want to have a relationship between two objects, and you would like that relationship to by sticky. So it would be handy if you could select a connecting tool ( some combination of shift/alt/ctrl and select of object ) and drag a connection from one object to another.
> 
> You could have multiple connections from and to objects.
> 
> A connecting line would be visible on screen.
> 
> A connecting line could have name and properties to allow definition of the relationship.
> 
> Deleting an object would remove all connections on other objects.
> 
> For now workarounds are to place the name of an object into the properties of another object. But a visual process would be much nicer. I have looked at using the Polyline but not being able to resize is a pain, and not sticking to an object when you move it is more the real problem. Being able to meld the Polyline to objects would be a solution.
> 
> !\[screen-shot-2014-07-29-at-17 58 27\](https://cloud.githubusercontent.com/assets/8301416/3738618/bcefd016-1742-11e4-80d8-7f604233f127.png)
> 
> !\[screen-shot-2014-07-29-at-17 54\](https://cloud.githubusercontent.com/assets/8301416/3738613/b814916c-1742-11e4-9b9c-8f4e333aa361.png)

It’s indeed something that would be nice to add, and I’d like to add it later this year.

> [@shoxsz](#):
>
> tiled could suport plugins, so the user can supply some specific necessity he needs

Of course, Tiled already supports plugins, but currently only for adding support for additional map or tileset formats. I’d like to extend this functionality, but rather than by exposing more of the C++ code and interfaces to plugins, I want to make Tiled scriptable. This is also because from experience it seems that most users are not interested in compiling their own plugins, and it is tricky to make them binary compatible. Making Tiled scriptable is also something I want to do this year, and is covered by the following GitHub issue:

> <https://github.com/mapeditor/tiled/issues/949>
>
> Most people are not into C++ / Qt and compiling Tiled themselves, and as such sm…all additions that would benefit their productivity are often not even started on. There should be an easy way to write scripts to perform actions in Tiled. Examples of things that should be possible:
> \- Running some script explicitly that performs some action on the map
> \- Adding a custom tool
> \- Hooking up to events to perform certain actions automatically
> \- Adding a custom map reader / writer
> 
> At the moment I think JavaScript would be the best choice of scripting language, because a JavaScript engine is provided as part of Qt and because having a JavaScript Tiled API should help with the development of a QtQuick based version of Tiled.
> 
> Examples of where scripting would have been useful (also see issues referencing this issue below):
> 
> \* http://discourse.mapeditor.org/t/how-do-i-batch-automapping/3033
> \* http://discourse.mapeditor.org/t/selective-automapping/3093
> \* https://www.patreon.com/posts/22268925

---

<div class="post-metadata">

**Author:** ![shoxsz](https://avatars.discourse-cdn.com/v4/letter/s/f475e1/32.png) [@shoxsz](https://discourse.mapeditor.org/u/shoxsz)\
**Post date:** [May 2, 2016, 10:43pm UTC](https://discourse.mapeditor.org/t/specific-expansions-with-plugins/1325/3 "2016-05-02T22:43:19Z")

</div>

So this features are coming some day, good to know, thanks for the attention.
