Game Development Community

Tile Images not appearing in Tile Editor

by Jakob Berglund Rogert · in Torque Game Builder · 02/02/2006 (9:09 am) · 7 replies

Hi!
Since it says "ask away!" I'll do. I've been looking around every bit of reference and guide I could find on the Tile Editor since I tried the Strategy Tutorial and ran into an early problem.
When it says "start tile editor" I do, then I start up the Tile Editor, where a large list of graphic files are listed, even those I myself added to the ~/data/content/datablocks.cs. However, not one of my or the default graphics files appear when I select them in the list, thus I cannot seem to define a brush. I've tried loading them in the game.cs script as well, using this code both when trying with datablocks and game.cs:

datablock t2dImageMapDatablock(palmsImageMap)
{
imageName = "~/data/images/tile02";
imageMode = full;
};

As I mention above, the name of my block appears in the Tile-Editor list, but not a single image, which is slightly disturbing since the tutorials all presume images will appear.
I'm using the very latest Alpha4 1.1 and I would be very grateful for help.

I also noticed that the Strategy tutorial uses a completely different path (~/client/datablocks.cs) which seems to be the path to use if using the older alpha.
My only guess is that my images are in the wrong folder or that I missed some vital point. The console says it's compiling the documents where I've put the script as well and does not report images not found or anything like that. Again, would be grateful for any ideas on how to solve it.
(The graphics in the basic tutorial loaded just fine upon "run game"-command)

#1
02/02/2006 (9:17 am)
Update to previous post...
All the images loaded through "sampledatablocks.cs" which aren't file-type defined ("image" instead of "image.png") breaks during loading with the following result in the log:

ImageMap(chowClouds2) Error: 'Invalid Bitmap File!' (2)
Strategy/data/content/sampleDatablocks.cs (0): Register object failed for object chowClouds2 of class t2dImageMapDatablock.

However, this does not happen to the image i'm trying to load through my datablock.cs file (guess it's because I've specified file type).
#2
02/02/2006 (9:55 am)
This is a side effect of this bug. The fix is posted at the afore linked topic.

I was not able to reproduce the second problem. With or without file extensions, things are working on my end. The only thing I can think of is that you may be specifying the wrong file extension.
#3
02/02/2006 (10:31 am)
Well, thank you thank you for the very quick reply!
#4
02/06/2006 (8:01 pm)
I'm a new T2D user and I've also been having similar troubles when following several tutorials. No images show up in the library window within the tile map editor. I made the changes suggested within the other forum post that Adam linked to, but am still having the same problem. Any suggestions would be appreciated.
#5
02/07/2006 (6:40 am)
J Spraque:
You actually need to recompile the whole engine after doing some fixes to make the GUI work. There's a couple of ways to do this and if you, like me aren't used to recompiling whole engines, it's a bit challenging to say the least. Took me many many hours googling compile errors to make it work.
Anyway, I used the post above, by Adam Larson, to find my way to several guides which I used to recompile the engine correctly.
I was using Microsoft Visual C++ Express, which is available as a free download right now. But if you're not used to it, I'd recommend getting the help of someone who knows C++ very well.

It's definitely worth the time, though, since I learned lots about recompiling the engine, which might become a necessity once you have specified the needs for your game and realize you want to add functionality to the C++ code.

Jakob
#6
02/07/2006 (7:20 am)
Thanks Jakob, that's exactly what I needed to know.
#7
02/08/2006 (7:53 am)
I have the same problem :
Quote:I start up the Tile Editor, where a large list of graphic files are listed, even those I myself added to the ~/data/content/datablocks.cs. However, not one of my or the default graphics files appear when I select them in the list

I use the beta 1.1