# Adding new C++ export plugin

**URL:** <https://discourse.mapeditor.org/t/adding-new-c-export-plugin/185>\
**Category:** Questions\
**Created:** [January 21, 2015, 10:31am UTC](https://discourse.mapeditor.org/t/adding-new-c-export-plugin/185 "2015-01-21T10:31:16Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![NanoWar](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.mapeditor.org/nanowar/32/84_2.png) [@NanoWar](https://discourse.mapeditor.org/u/NanoWar)\
**Post date:** [January 21, 2015, 10:31am UTC](https://discourse.mapeditor.org/t/adding-new-c-export-plugin/185/1 "2015-01-21T10:31:16Z")

</div>

Hey, I’m currently programming a new export plugin that exports in a z80 assembly format. I have VS2012 and QT and am able to build. I thought, since the DLLs are loaded on runtime, I could simply put them in the folder of my installed TILED version instead of recompiling the whole thing. But in the export menu the new extension doesn’t show up. Also when I compile the existing CsvPlugin and switch out the DLLs, it doesn’t show \*.csv anymore as an option. Why? Something wrong with my compilation? I’m on Win7 64bit, but all compiles are with 32bit. The working csv plugin is 1 KB smaller than my compiled version (?). Ideas?

---

<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:** [January 21, 2015, 11:02am UTC](https://discourse.mapeditor.org/t/adding-new-c-export-plugin/185/2 "2015-01-21T11:02:23Z")

</div>

The current Windows releases are built with MinGW 4.9 + Qt 5.4.0. If you use something else it could very well be that the plugin loading fails due to incompatibilities.

One of the things I’d still like to add is a Plugins window where one could see which plugins are loaded and which ones failed, and with what error message.

---

<div class="post-metadata">

**Author:** ![NanoWar](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.mapeditor.org/nanowar/32/84_2.png) [@NanoWar](https://discourse.mapeditor.org/u/NanoWar)\
**Post date:** [January 21, 2015, 11:07am UTC](https://discourse.mapeditor.org/t/adding-new-c-export-plugin/185/3 "2015-01-21T11:07:23Z")

</div>

Ok, I run QT 5.3.0. May the upgrading fun begin … 😉

---

<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:** [January 21, 2015, 12:08pm UTC](https://discourse.mapeditor.org/t/adding-new-c-export-plugin/185/4 "2015-01-21T12:08:58Z")

</div>

Just as a warning, I was unable to compile Tiled against Qt 5.4 with `qmake`, where there was some strange problem causing the wrong compiler flags to be used while compiling some files. If you’re lucky you won’t encounter them, but if you do then you could try to use Qbs instead.

---

<div class="post-metadata">

**Author:** ![NanoWar](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.mapeditor.org/nanowar/32/84_2.png) [@NanoWar](https://discourse.mapeditor.org/u/NanoWar)\
**Post date:** [January 21, 2015, 1:11pm UTC](https://discourse.mapeditor.org/t/adding-new-c-export-plugin/185/5 "2015-01-21T13:11:14Z")

</div>

I can compile and it works now, thanks!

---

<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:** [January 21, 2015, 2:31pm UTC](https://discourse.mapeditor.org/t/adding-new-c-export-plugin/185/6 "2015-01-21T14:31:06Z")

</div>

That’s great! I’m curious now, what is your setup? Did you manage to use `qmake` or did you use Qbs now?

---

<div class="post-metadata">

**Author:** ![NanoWar](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.mapeditor.org/nanowar/32/84_2.png) [@NanoWar](https://discourse.mapeditor.org/u/NanoWar)\
**Post date:** [January 21, 2015, 3:30pm UTC](https://discourse.mapeditor.org/t/adding-new-c-export-plugin/185/7 "2015-01-21T15:30:53Z")

</div>

Oh sorry, the setup is simply QtCreator, I guess that is qmake. I use the online installer to get it with qt 5.4.0 and mingw 4.9.1. I had to compile libtiled to get the tiled.lib file that gets linked with the plugins. It’s pretty neat! Good job!
