4 * Created on: Sep 29, 2012
10 #include "../loader/TypeDescription.h"
12 using loader::FieldDescription;
13 using loader::TypeDescription;
24 void Tile::CreateTypeDescription() {
27 int imageId(TypeDescription::GetTypeId("Image"));
28 int numberId(TypeDescription::GetTypeId("Number"));
29 int vectorId(TypeDescription::GetTypeId("Vector"));
31 TypeDescription &td(TypeDescription::CreateOrGet("Tile"));
32 td.SetConstructor(&Construct);
33 td.SetSize(sizeof(Tile));
35 td.AddField("battlebg", FieldDescription(((char *)&t.battlebg) - ((char *)&t), imageId).SetReferenced());
36 td.AddField("t", FieldDescription(((char *)&t.offset) - ((char *)&t), vectorId));
37 td.AddField("flags", FieldDescription(((char *)&t.flags) - ((char *)&t), numberId));
41 void Tile::Construct(void *data) {