[PLUGIN] TMX importer

0 favourites
From the Asset Store
The I18N (Translation) is a Construct plugin created to translate text in game.
  • rexrainbow

    Hey there! I'm trying to load an external TMX file (uncompressed Base64) using your plugin, but it doesn't seem to load anything; however, if I open the .tmx file in notepad and replace the quotation (") marks with an apostrophe (') and paste the data into the tmx string in C2, it loads the data just fine. I'm guessing the plugin is designed be able to load .tmx files through AJAX without manually having to modify the file to do so - is there something I'm doing wrong?

    Thanks in advance for any help you can provide.

  • digitalsoapbox

    The limitation comes from C2 editor. As you said, user need to replace the " to ', or replace " to "" (double ").

  • digitalsoapbox I load .tmx files via AJAX just fine. Maybe try another format? I use CSV.

  • Hmm, maybe I'm doing something wrong then.

    I've put the .capx here, if anyone has a moment to take a look and let me know what I'm doing wrong, that'd be extremely helpful. I've tried loading the .tmx w/ AJAX and replacing any instance of quotes with apostrophes after load using replace().

    dropbox.com/s/kg5a6jgixsxjgx3/test_schmup.capx

    Thanks!

  • Delete the first action in event 3 and change the first action in event 4 from Currentleveldata to Ajax.LastData.

  • Yep, that (sort of) worked - I'd tried doing it directly with a different .tmx and ended up with a blank screen. It's still only loading one layer of tiles, though the other layers are present in C2 (and named the same as in the .tmx).

    *EDIT: started new Tiled map, new one loads fine.

  • rexrainbow

    I managed to get my tmx map coming in (I just had to start a new map from scratch and it all seemed to behave properly after), but there still seems to be an error in rotating + mirroring a tile image.

    In the image below, you can see my tiles in Tiled (on the left), how they look when placed on a map (rotated 90dg, or pressing "Z" once) and mirrored horizontally ("X"). The image in the yellow box is how the tile rotation & mirroring shows up in C2.

    <img src="http://pixelmetal.com/temp/testschmup/tmx_error.jpg" border="0" />

    Rotation & mirror/flip seem to work fine separately, but they're not playing together very nicely.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • For multiple Tilesets in 1 Sprite:

    In order to do this I made the TileSet name in Tiled Map Editor = to an animation name in the tile itself. And then proceed to set the animation = to the TMXImporter.TilesetName and animation frame = to TMXImporter.Frame.

    For example in the animation I have it named Outside_B and in Tiled the tileset is named Outside_B.

    After that my code ends up like this:

    <img src="https://dl.dropboxusercontent.com/u/73299017/Various/TMXImporter-MultipleTilesets.png" border="0" />

    The code is just a test, not my actual code as I am still developing the Map Generation as of now, paused everything for a while lol.

    That simple :)

    I recommend this be added to the post if you find this efficient as this will help ALOT of people trying to use Tiled Map Editor making RMVX styled games.

    NOTE: I am using Pacman tutorial for movement hence the Spawn [] Solid on layer Self.LayerNumber (This is not needed, just what I am doing).

  • Equinox80 Yeah I've been doing that for a while...Problem is it results in reeeeally long load times if you have a lot of tilesets.

    Scirra mentioned thety are working on a tilemap editor so this plugin might be obsolete soon ^^;

    Unless you need to dynamically load your levels for a metroidvania or something...but even then you're better off using your own editor.

  • Ah okay. Figured I'd give it to people now.

    Haven't tried it beyond 1600x1600px layout. No load time through that so far (50x50 tiles going at 32x32 pixels) and 3 tilesets 512x512, 512,512, 512x384.

    Although a Scirra Construct 2 TileMap editor, that works with RPG Maker, or at least a customizable (would be better for compatibility) Map Editor would be AWESOME.

    Edit: Then again not everybody has an intel i7 processor and 16 gb ddr3 ram. So longer load times I suppose on other devices.

  • Can anyone post a video tutorial?

    Please! :)

  • rexrainbow

    I couldn't find any mention of it, but are external tilesets currently supported? As in, can I export my tilesets so that all tilemaps can reference them (since they may change in the future and it's easier to manage updates that way outside of C2 and in Tiled)? I've tried importing the .tsx files into my C2 project, but just end up with a blank screen.

  • Here is the next version of tmx importer.

  • Just wanted to thanks for the plugin! It's working great once I got a hang of it

  • samur

    Use rex_tmx_importerv2, this plugin did not maintain any more.

Jump to:
Active Users
There are 2 visitors browsing this topic (0 users and 2 guests)