import "ecere"
-BitmapResource peasantGfx { ":peasant.png" };
+BitmapResource knightGfx { ":knight.png" };
BitmapResource dragonGfx { ":dragon.png" };
BitmapResource mageGfx { ":mage.png" };
BitmapResource archerGfx { ":archer.png" };
BitmapResource castleGfx { ":castle.png" };
-Array<BitmapResource> gfxResources { [ peasantGfx, dragonGfx, mageGfx, archerGfx, castleGfx ] };
+Array<BitmapResource> gfxResources { [ knightGfx, dragonGfx, mageGfx, archerGfx, castleGfx ] };
class WorldObject
{
int x, y;
}
-class Peasant : WorldObject { res = peasantGfx; selectable = true; }
+class Knight : WorldObject { res = knightGfx; selectable = true; }
class Dragon : WorldObject { res = dragonGfx; }
class Mage : WorldObject { res = mageGfx; selectable = true; }
class Archer : WorldObject { res = archerGfx; selectable = true; }
Castle { 180, 150 },
Mage { 50, 50 },
Archer { 150, 250 },
- Peasant { 380, 290 },
- Peasant { 120, 150 },
+ Knight { 380, 290 },
+ Knight { 120, 150 },
Dragon { 320, 50 }
] };
"../res/castle.png",
"../res/dragon.png",
"../res/mage.png",
- "../res/peasant.png"
+ "../res/knight.png"
]
}
import "ecere"
-BitmapResource peasantGfx { ":peasant.png" };
+BitmapResource knightGfx { ":knight.png" };
BitmapResource dragonGfx { ":dragon.png" };
BitmapResource mageGfx { ":mage.png" };
BitmapResource archerGfx { ":archer.png" };
BitmapResource castleGfx { ":castle.png" };
-Array<BitmapResource> gfxResources { [ peasantGfx, dragonGfx, mageGfx, archerGfx, castleGfx ] };
+Array<BitmapResource> gfxResources { [ knightGfx, dragonGfx, mageGfx, archerGfx, castleGfx ] };
class WorldObject
{
int x, y;
}
-class Peasant : WorldObject { res = peasantGfx; selectable = true; }
+class Knight : WorldObject { res = knightGfx; selectable = true; }
class Dragon : WorldObject { res = dragonGfx; }
class Mage : WorldObject { res = mageGfx; selectable = true; }
class Archer : WorldObject { res = archerGfx; selectable = true; }
Castle { 180, 150 },
Mage { 50, 50 },
Archer { 150, 250 },
- Peasant { 380, 290 },
- Peasant { 120, 150 },
+ Knight { 380, 290 },
+ Knight { 120, 150 },
Dragon { 320, 50 }
] };
"../res/castle.png",
"../res/dragon.png",
"../res/mage.png",
- "../res/peasant.png"
+ "../res/knight.png"
]
}
import "ecere"
-BitmapResource peasantGfx { ":peasant.png" };
+BitmapResource knightGfx { ":knight.png" };
BitmapResource dragonGfx { ":dragon.png" };
BitmapResource mageGfx { ":mage.png" };
BitmapResource archerGfx { ":archer.png" };
BitmapResource castleGfx { ":castle.png" };
-Array<BitmapResource> gfxResources { [ peasantGfx, dragonGfx, mageGfx, archerGfx, castleGfx ] };
+Array<BitmapResource> gfxResources { [ knightGfx, dragonGfx, mageGfx, archerGfx, castleGfx ] };
class WorldObject
{
int x, y;
}
-class Peasant : WorldObject { res = peasantGfx; selectable = true; }
+class Knight : WorldObject { res = knightGfx; selectable = true; }
class Dragon : WorldObject { res = dragonGfx; }
class Mage : WorldObject { res = mageGfx; selectable = true; }
class Archer : WorldObject { res = archerGfx; selectable = true; }
Castle { 180, 150 },
Mage { 50, 50 },
Archer { 150, 250 },
- Peasant { 380, 290 },
- Peasant { 120, 150 },
+ Knight { 380, 290 },
+ Knight { 120, 150 },
Dragon { 320, 50 }
] };
"../res/castle.png",
"../res/dragon.png",
"../res/mage.png",
- "../res/peasant.png"
+ "../res/knight.png"
]
}
import "ecere"
-BitmapResource peasantGfx { ":peasant.png" };
+BitmapResource knightGfx { ":knight.png" };
BitmapResource dragonGfx { ":dragon.png" };
BitmapResource mageGfx { ":mage.png" };
BitmapResource archerGfx { ":archer.png" };
BitmapResource castleGfx { ":castle.png" };
-Array<BitmapResource> gfxResources { [ peasantGfx, dragonGfx, mageGfx, archerGfx, castleGfx ] };
+Array<BitmapResource> gfxResources { [ knightGfx, dragonGfx, mageGfx, archerGfx, castleGfx ] };
class WorldObject
{
int x, y;
}
-class Peasant : WorldObject { res = peasantGfx; }
+class Knight : WorldObject { res = knightGfx; }
class Dragon : WorldObject { res = dragonGfx; }
class Mage : WorldObject { res = mageGfx; }
class Archer : WorldObject { res = archerGfx; }
Castle { 180, 150 },
Mage { 50, 50 },
Archer { 150, 250 },
- Peasant { 380, 290 },
- Peasant { 120, 150 },
+ Knight { 380, 290 },
+ Knight { 120, 150 },
Dragon { 320, 50 }
] };
class MainWindow : Window
{
- text = "A World of Objects";
+ caption = $"A World of Objects";
background = black;
borderStyle = sizable;
hasMaximize = true;
"../res/castle.png",
"../res/dragon.png",
"../res/mage.png",
- "../res/peasant.png"
+ "../res/knight.png"
]
}