mirror of
https://gitlab.com/drummyfish/anarch.git
synced 2024-11-22 00:42:16 -05:00
Format
This commit is contained in:
parent
350ecf5c91
commit
f0a538e557
376
levels.h
376
levels.h
@ -162,9 +162,12 @@ static inline SFG_TileDefinition SFG_getMapTile
|
|||||||
return level->tileDictionary[tile & 0x3f];
|
return level->tileDictionary[tile & 0x3f];
|
||||||
}
|
}
|
||||||
|
|
||||||
SFG_PROGRAM_MEMORY SFG_Level SFG_level0 =
|
#define SFG_NUMBER_OF_LEVELS 2
|
||||||
|
|
||||||
|
SFG_PROGRAM_MEMORY SFG_Level SFG_levels[SFG_NUMBER_OF_LEVELS] =
|
||||||
{
|
{
|
||||||
{ // mapArray
|
{ // level 0
|
||||||
|
{ // mapArray
|
||||||
#define o 0
|
#define o 0
|
||||||
#define AA (0x09 | SFG_TILE_PROPERTY_ELEVATOR)
|
#define AA (0x09 | SFG_TILE_PROPERTY_ELEVATOR)
|
||||||
#define BB (0x0f | SFG_TILE_PROPERTY_ELEVATOR)
|
#define BB (0x0f | SFG_TILE_PROPERTY_ELEVATOR)
|
||||||
@ -246,102 +249,100 @@ SFG_PROGRAM_MEMORY SFG_Level SFG_level0 =
|
|||||||
#undef DD
|
#undef DD
|
||||||
#undef FF
|
#undef FF
|
||||||
#undef GG
|
#undef GG
|
||||||
|
},
|
||||||
|
{ // tileDictionary
|
||||||
|
SFG_TD(10,31,4,0),SFG_TD(30,31,1,0),SFG_TD(0 ,31,4,0),SFG_TD(14,31,3,0), // 0
|
||||||
|
SFG_TD(15,31,4,0),SFG_TD(14,31,4,0),SFG_TD(13,31,4,0),SFG_TD(12,31,4,0), // 4
|
||||||
|
SFG_TD(11,31,4,0),SFG_TD(10,30,2,0),SFG_TD(14, 5,5,1),SFG_TD(20,31,5,0), // 8
|
||||||
|
SFG_TD(30,31,6,0),SFG_TD(17,31,4,0),SFG_TD(26,31,1,0),SFG_TD(0 ,10,0,0), // 12
|
||||||
|
SFG_TD(10, 5,1,1),SFG_TD(10,26,0,0),SFG_TD(14,31,0,0),SFG_TD(18,31,1,0), // 16
|
||||||
|
SFG_TD(15,31,1,0),SFG_TD(14,31,1,0),SFG_TD(30,31,5,0),SFG_TD(12, 7,5,1), // 20
|
||||||
|
SFG_TD(13, 6,5,1),SFG_TD(25,31,5,0),SFG_TD(13,31,5,0),SFG_TD(4 ,31,4,0), // 24
|
||||||
|
SFG_TD(20,31,3,0),SFG_TD(30,0 ,1,1),SFG_TD(30,0 ,5,1),SFG_TD(14,30,0,0), // 28
|
||||||
|
SFG_TD(28,31,1,0),SFG_TD(29,31,4,0),SFG_TD(18, 0,1,1),SFG_TD(14, 0,1,1), // 32
|
||||||
|
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 36
|
||||||
|
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 40
|
||||||
|
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 44
|
||||||
|
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 48
|
||||||
|
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 52
|
||||||
|
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 56
|
||||||
|
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0) // 60
|
||||||
|
},
|
||||||
|
{0, 1, 2, 6, 3, 12, 10}, // textureIndices
|
||||||
|
13, // doorTextureIndex
|
||||||
|
10, // floorColor
|
||||||
|
32, // ceilingColor
|
||||||
|
{8,19,0}, // player start: x, y, direction
|
||||||
|
0, // backgroundImage
|
||||||
|
{ // elements
|
||||||
|
{SFG_LEVEL_ELEMENT_BARREL, {9, 1}}, {SFG_LEVEL_ELEMENT_BARREL, {9, 13}},
|
||||||
|
{SFG_LEVEL_ELEMENT_HEALTH, {12, 4}}, {SFG_LEVEL_ELEMENT_HEALTH, {15, 4}},
|
||||||
|
{SFG_LEVEL_ELEMENT_BARREL, {24, 10}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_BARREL, {13, 4}}, {SFG_LEVEL_ELEMENT_BARREL, {12, 6}},
|
||||||
|
{SFG_LEVEL_ELEMENT_MONSTER_ENDER, {23, 10}}, {SFG_LEVEL_ELEMENT_MONSTER_SPIDER, {16, 8}},
|
||||||
|
{SFG_LEVEL_ELEMENT_MONSTER_DESTROYER, {16, 7}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_MONSTER_WARRIOR, {18, 31}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_MONSTER_PLASMABOT, {19, 31}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_MONSTER_TURRET, {5, 24}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_MONSTER_EXPLODER, {22, 18}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_BULLETS, {2, 56}}, {SFG_LEVEL_ELEMENT_BULLETS, {3, 56}},
|
||||||
|
{SFG_LEVEL_ELEMENT_BARREL, {9, 37}}, {SFG_LEVEL_ELEMENT_BARREL, {9, 38}},
|
||||||
|
{SFG_LEVEL_ELEMENT_BARREL, {9, 39}}, {SFG_LEVEL_ELEMENT_BARREL, {9, 40}},
|
||||||
|
{SFG_LEVEL_ELEMENT_BARREL, {9, 41}}, {SFG_LEVEL_ELEMENT_BARREL, {9, 42}},
|
||||||
|
{SFG_LEVEL_ELEMENT_BARREL, {9, 43}}, {SFG_LEVEL_ELEMENT_BARREL, {9, 44}},
|
||||||
|
{SFG_LEVEL_ELEMENT_BARREL, {8, 45}}, {SFG_LEVEL_ELEMENT_BARREL, {9, 46}},
|
||||||
|
{SFG_LEVEL_ELEMENT_ROCKETS, {4, 56}}, {SFG_LEVEL_ELEMENT_ROCKETS, {5, 56}},
|
||||||
|
{SFG_LEVEL_ELEMENT_PLASMA, {3, 57}}, {SFG_LEVEL_ELEMENT_PLASMA, {3, 58}},
|
||||||
|
{SFG_LEVEL_ELEMENT_TREE, {16, 44}}, {SFG_LEVEL_ELEMENT_TREE, {16, 45}},
|
||||||
|
{SFG_LEVEL_ELEMENT_TREE, {16, 46}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_CARD0, {13, 20}}, {SFG_LEVEL_ELEMENT_CARD1, {14, 20}},
|
||||||
|
{SFG_LEVEL_ELEMENT_CARD2, {13, 21}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_LOCK1, {3, 21}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_FINISH, {8, 44}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_TELEPORT, {11, 12}}, {SFG_LEVEL_ELEMENT_TELEPORT, {17, 20}},
|
||||||
|
{SFG_LEVEL_ELEMENT_TELEPORT, {20, 40}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}}
|
||||||
|
}
|
||||||
},
|
},
|
||||||
{ // tileDictionary
|
{ // level 1
|
||||||
SFG_TD(10,31,4,0),SFG_TD(30,31,1,0),SFG_TD(0 ,31,4,0),SFG_TD(14,31,3,0), // 0
|
{ // mapArray
|
||||||
SFG_TD(15,31,4,0),SFG_TD(14,31,4,0),SFG_TD(13,31,4,0),SFG_TD(12,31,4,0), // 4
|
|
||||||
SFG_TD(11,31,4,0),SFG_TD(10,30,2,0),SFG_TD(14, 5,5,1),SFG_TD(20,31,5,0), // 8
|
|
||||||
SFG_TD(30,31,6,0),SFG_TD(17,31,4,0),SFG_TD(26,31,1,0),SFG_TD(0 ,10,0,0), // 12
|
|
||||||
SFG_TD(10, 5,1,1),SFG_TD(10,26,0,0),SFG_TD(14,31,0,0),SFG_TD(18,31,1,0), // 16
|
|
||||||
SFG_TD(15,31,1,0),SFG_TD(14,31,1,0),SFG_TD(30,31,5,0),SFG_TD(12, 7,5,1), // 20
|
|
||||||
SFG_TD(13, 6,5,1),SFG_TD(25,31,5,0),SFG_TD(13,31,5,0),SFG_TD(4 ,31,4,0), // 24
|
|
||||||
SFG_TD(20,31,3,0),SFG_TD(30,0 ,1,1),SFG_TD(30,0 ,5,1),SFG_TD(14,30,0,0), // 28
|
|
||||||
SFG_TD(28,31,1,0),SFG_TD(29,31,4,0),SFG_TD(18, 0,1,1),SFG_TD(14, 0,1,1), // 32
|
|
||||||
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 36
|
|
||||||
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 40
|
|
||||||
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 44
|
|
||||||
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 48
|
|
||||||
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 52
|
|
||||||
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 56
|
|
||||||
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0) // 60
|
|
||||||
},
|
|
||||||
{0, 1, 2, 6, 3, 12, 10}, // textureIndices
|
|
||||||
13, // doorTextureIndex
|
|
||||||
10, // floorColor
|
|
||||||
32, // ceilingColor
|
|
||||||
{8,19,0}, // player start: x, y, direction
|
|
||||||
0, // backgroundImage
|
|
||||||
{ // elements
|
|
||||||
{SFG_LEVEL_ELEMENT_BARREL, {9, 1}}, {SFG_LEVEL_ELEMENT_BARREL, {9, 13}},
|
|
||||||
{SFG_LEVEL_ELEMENT_HEALTH, {12, 4}}, {SFG_LEVEL_ELEMENT_HEALTH, {15, 4}},
|
|
||||||
{SFG_LEVEL_ELEMENT_BARREL, {24, 10}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_BARREL, {13, 4}}, {SFG_LEVEL_ELEMENT_BARREL, {12, 6}},
|
|
||||||
{SFG_LEVEL_ELEMENT_MONSTER_ENDER, {23, 10}}, {SFG_LEVEL_ELEMENT_MONSTER_SPIDER, {16, 8}},
|
|
||||||
{SFG_LEVEL_ELEMENT_MONSTER_DESTROYER, {16, 7}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_MONSTER_WARRIOR, {18, 31}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_MONSTER_PLASMABOT, {19, 31}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_MONSTER_TURRET, {5, 24}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_MONSTER_EXPLODER, {22, 18}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_BULLETS, {2, 56}}, {SFG_LEVEL_ELEMENT_BULLETS, {3, 56}},
|
|
||||||
{SFG_LEVEL_ELEMENT_BARREL, {9, 37}}, {SFG_LEVEL_ELEMENT_BARREL, {9, 38}},
|
|
||||||
{SFG_LEVEL_ELEMENT_BARREL, {9, 39}}, {SFG_LEVEL_ELEMENT_BARREL, {9, 40}},
|
|
||||||
{SFG_LEVEL_ELEMENT_BARREL, {9, 41}}, {SFG_LEVEL_ELEMENT_BARREL, {9, 42}},
|
|
||||||
{SFG_LEVEL_ELEMENT_BARREL, {9, 43}}, {SFG_LEVEL_ELEMENT_BARREL, {9, 44}},
|
|
||||||
{SFG_LEVEL_ELEMENT_BARREL, {8, 45}}, {SFG_LEVEL_ELEMENT_BARREL, {9, 46}},
|
|
||||||
{SFG_LEVEL_ELEMENT_ROCKETS, {4, 56}}, {SFG_LEVEL_ELEMENT_ROCKETS, {5, 56}},
|
|
||||||
{SFG_LEVEL_ELEMENT_PLASMA, {3, 57}}, {SFG_LEVEL_ELEMENT_PLASMA, {3, 58}},
|
|
||||||
{SFG_LEVEL_ELEMENT_TREE, {16, 44}}, {SFG_LEVEL_ELEMENT_TREE, {16, 45}},
|
|
||||||
{SFG_LEVEL_ELEMENT_TREE, {16, 46}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_CARD0, {13, 20}}, {SFG_LEVEL_ELEMENT_CARD1, {14, 20}},
|
|
||||||
{SFG_LEVEL_ELEMENT_CARD2, {13, 21}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_LOCK1, {3, 21}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_FINISH, {8, 44}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_TELEPORT, {11, 12}}, {SFG_LEVEL_ELEMENT_TELEPORT, {17, 20}},
|
|
||||||
{SFG_LEVEL_ELEMENT_TELEPORT, {20, 40}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}}
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
SFG_PROGRAM_MEMORY SFG_Level SFG_level1 =
|
|
||||||
{
|
|
||||||
{ // mapArray
|
|
||||||
#define o 0
|
#define o 0
|
||||||
#define AA (0x09 | SFG_TILE_PROPERTY_ELEVATOR)
|
#define AA (0x09 | SFG_TILE_PROPERTY_ELEVATOR)
|
||||||
#define BB (0x0f | SFG_TILE_PROPERTY_ELEVATOR)
|
#define BB (0x0f | SFG_TILE_PROPERTY_ELEVATOR)
|
||||||
@ -423,96 +424,97 @@ SFG_PROGRAM_MEMORY SFG_Level SFG_level1 =
|
|||||||
#undef DD
|
#undef DD
|
||||||
#undef FF
|
#undef FF
|
||||||
#undef GG
|
#undef GG
|
||||||
},
|
},
|
||||||
{ // tileDictionary
|
{ // tileDictionary
|
||||||
SFG_TD(14,31,0,0),SFG_TD(18,31,0,0),SFG_TD(26,31,0,0),SFG_TD(16,31,0,0), // 0
|
SFG_TD(14,31,0,0),SFG_TD(18,31,0,0),SFG_TD(26,31,0,0),SFG_TD(16,31,0,0), // 0
|
||||||
SFG_TD(18, 8,0,0),SFG_TD(26, 0,0,0),SFG_TD(18,31,4,0),SFG_TD(12,12,0,5), // 4
|
SFG_TD(18, 8,0,0),SFG_TD(26, 0,0,0),SFG_TD(18,31,4,0),SFG_TD(12,12,0,5), // 4
|
||||||
SFG_TD(26, 0,4,0),SFG_TD(15,31,2,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 8
|
SFG_TD(26, 0,4,0),SFG_TD(15,31,2,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 8
|
||||||
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 12
|
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 12
|
||||||
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 16
|
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 16
|
||||||
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 20
|
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 20
|
||||||
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 24
|
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 24
|
||||||
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 28
|
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 28
|
||||||
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 32
|
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 32
|
||||||
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 36
|
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 36
|
||||||
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 40
|
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 40
|
||||||
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 44
|
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 44
|
||||||
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 48
|
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 48
|
||||||
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 52
|
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 52
|
||||||
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 56
|
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0), // 56
|
||||||
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0) // 60
|
SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0),SFG_TD(0 ,31,0,0) // 60
|
||||||
},
|
},
|
||||||
{0, 2, 4, 5, 11, 14, 15}, // textureIndices
|
{0, 2, 4, 5, 11, 14, 15}, // textureIndices
|
||||||
13, // doorTextureIndex
|
13, // doorTextureIndex
|
||||||
102, // floorColor
|
102, // floorColor
|
||||||
32, // ceilingColor
|
32, // ceilingColor
|
||||||
{10,10,64}, // player start: x, y, direction
|
{10,10,64}, // player start: x, y, direction
|
||||||
1, // backgroundImage
|
1, // backgroundImage
|
||||||
{ // elements
|
{ // elements
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}},
|
||||||
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}}
|
{SFG_LEVEL_ELEMENT_NONE, {0, 0}}, {SFG_LEVEL_ELEMENT_NONE, {0, 0}}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
97
main.c
97
main.c
@ -566,7 +566,8 @@ static inline void SFG_setGamePixel(uint16_t x, uint16_t y, uint8_t colorIndex)
|
|||||||
|
|
||||||
void SFG_recompurePLayerDirection()
|
void SFG_recompurePLayerDirection()
|
||||||
{
|
{
|
||||||
SFG_player.camera.direction = RCL_wrap(SFG_player.camera.direction,RCL_UNITS_PER_SQUARE);
|
SFG_player.camera.direction =
|
||||||
|
RCL_wrap(SFG_player.camera.direction,RCL_UNITS_PER_SQUARE);
|
||||||
|
|
||||||
SFG_player.direction = RCL_angleToDirection(SFG_player.camera.direction);
|
SFG_player.direction = RCL_angleToDirection(SFG_player.camera.direction);
|
||||||
|
|
||||||
@ -923,7 +924,9 @@ RCL_Unit SFG_texturesAt(int16_t x, int16_t y)
|
|||||||
{
|
{
|
||||||
uint8_t p;
|
uint8_t p;
|
||||||
|
|
||||||
SFG_TileDefinition tile = SFG_getMapTile(SFG_currentLevel.levelPointer,x,y,&p);
|
SFG_TileDefinition tile =
|
||||||
|
SFG_getMapTile(SFG_currentLevel.levelPointer,x,y,&p);
|
||||||
|
|
||||||
return
|
return
|
||||||
SFG_TILE_FLOOR_TEXTURE(tile) | (SFG_TILE_CEILING_TEXTURE(tile) << 3) | p;
|
SFG_TILE_FLOOR_TEXTURE(tile) | (SFG_TILE_CEILING_TEXTURE(tile) << 3) | p;
|
||||||
// ^ store both textures (floor and ceiling) and properties in one number
|
// ^ store both textures (floor and ceiling) and properties in one number
|
||||||
@ -1131,7 +1134,8 @@ void SFG_setAndInitLevel(const SFG_Level *level)
|
|||||||
&(SFG_currentLevel.monsterRecords[SFG_currentLevel.monsterRecordCount]);
|
&(SFG_currentLevel.monsterRecords[SFG_currentLevel.monsterRecordCount]);
|
||||||
|
|
||||||
monster->stateType = e->type | SFG_MONSTER_STATE_INACTIVE;
|
monster->stateType = e->type | SFG_MONSTER_STATE_INACTIVE;
|
||||||
monster->health = SFG_GET_MONSTER_MAX_HEALTH(SFG_MONSTER_TYPE_TO_INDEX(e->type));
|
monster->health =
|
||||||
|
SFG_GET_MONSTER_MAX_HEALTH(SFG_MONSTER_TYPE_TO_INDEX(e->type));
|
||||||
|
|
||||||
monster->coords[0] = e->coords[0] * 4 + 2;
|
monster->coords[0] = e->coords[0] * 4 + 2;
|
||||||
monster->coords[1] = e->coords[1] * 4 + 2;
|
monster->coords[1] = e->coords[1] * 4 + 2;
|
||||||
@ -1361,7 +1365,8 @@ uint8_t SFG_pushAway(
|
|||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
uint8_t SFG_pushPlayerAway(RCL_Unit centerX, RCL_Unit centerY, RCL_Unit distance)
|
uint8_t SFG_pushPlayerAway(
|
||||||
|
RCL_Unit centerX, RCL_Unit centerY, RCL_Unit distance)
|
||||||
{
|
{
|
||||||
RCL_Unit p[3];
|
RCL_Unit p[3];
|
||||||
|
|
||||||
@ -1750,8 +1755,10 @@ void SFG_monsterPerformAI(SFG_MonsterRecord *monster)
|
|||||||
SFG_TileDefinition tile =
|
SFG_TileDefinition tile =
|
||||||
SFG_getMapTile(SFG_currentLevel.levelPointer,mX,mY,&properties);
|
SFG_getMapTile(SFG_currentLevel.levelPointer,mX,mY,&properties);
|
||||||
|
|
||||||
SFG_createExplosion(mX * RCL_UNITS_PER_SQUARE ,mY * RCL_UNITS_PER_SQUARE,
|
SFG_createExplosion(mX * RCL_UNITS_PER_SQUARE,
|
||||||
SFG_TILE_FLOOR_HEIGHT(tile) * SFG_WALL_HEIGHT_STEP + SFG_WALL_HEIGHT_STEP);
|
mY * RCL_UNITS_PER_SQUARE,
|
||||||
|
SFG_TILE_FLOOR_HEIGHT(tile) * SFG_WALL_HEIGHT_STEP +
|
||||||
|
SFG_WALL_HEIGHT_STEP);
|
||||||
|
|
||||||
monster->health = 0;
|
monster->health = 0;
|
||||||
}
|
}
|
||||||
@ -2126,7 +2133,8 @@ void SFG_gameStepPlaying()
|
|||||||
{
|
{
|
||||||
if (SFG_keyJustPressed(SFG_KEY_LEFT) || SFG_keyJustPressed(SFG_KEY_A))
|
if (SFG_keyJustPressed(SFG_KEY_LEFT) || SFG_keyJustPressed(SFG_KEY_A))
|
||||||
SFG_playerRotateWeapon(0);
|
SFG_playerRotateWeapon(0);
|
||||||
else if (SFG_keyJustPressed(SFG_KEY_RIGHT) || SFG_keyJustPressed(SFG_KEY_B))
|
else if (SFG_keyJustPressed(SFG_KEY_RIGHT) ||
|
||||||
|
SFG_keyJustPressed(SFG_KEY_B))
|
||||||
SFG_playerRotateWeapon(1);
|
SFG_playerRotateWeapon(1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -2147,9 +2155,11 @@ void SFG_gameStepPlaying()
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (SFG_keyJustPressed(SFG_KEY_LEFT) | SFG_keyJustPressed(SFG_KEY_A))
|
if (SFG_keyJustPressed(SFG_KEY_LEFT) ||
|
||||||
|
SFG_keyJustPressed(SFG_KEY_A))
|
||||||
SFG_playerRotateWeapon(0);
|
SFG_playerRotateWeapon(0);
|
||||||
else if (SFG_keyJustPressed(SFG_KEY_RIGHT) | SFG_keyJustPressed(SFG_KEY_B))
|
else if (SFG_keyJustPressed(SFG_KEY_RIGHT) ||
|
||||||
|
SFG_keyJustPressed(SFG_KEY_B))
|
||||||
SFG_playerRotateWeapon(1);
|
SFG_playerRotateWeapon(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2811,7 +2821,7 @@ void SFG_gameStepMenu()
|
|||||||
switch (item)
|
switch (item)
|
||||||
{
|
{
|
||||||
case SFG_MENU_ITEM_PLAY:
|
case SFG_MENU_ITEM_PLAY:
|
||||||
SFG_setAndInitLevel(&SFG_level0);
|
SFG_setAndInitLevel(&SFG_levels[SFG_game.selectedLevel]);
|
||||||
SFG_game.state = SFG_GAME_STATE_PLAYING;
|
SFG_game.state = SFG_GAME_STATE_PLAYING;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
@ -2821,7 +2831,8 @@ void SFG_gameStepMenu()
|
|||||||
}
|
}
|
||||||
else if (item == SFG_MENU_ITEM_PLAY)
|
else if (item == SFG_MENU_ITEM_PLAY)
|
||||||
{
|
{
|
||||||
if (SFG_keyRegisters(SFG_KEY_RIGHT) && SFG_game.selectedLevel < 9)
|
if (SFG_keyRegisters(SFG_KEY_RIGHT) &&
|
||||||
|
(SFG_game.selectedLevel < SFG_NUMBER_OF_LEVELS - 1))
|
||||||
{
|
{
|
||||||
SFG_game.selectedLevel++;
|
SFG_game.selectedLevel++;
|
||||||
SFG_playSoundSafe(3,64);
|
SFG_playSoundSafe(3,64);
|
||||||
@ -3087,7 +3098,8 @@ void SFG_drawWeapon(int16_t bobOffset)
|
|||||||
uint32_t shotAnimationFrame =
|
uint32_t shotAnimationFrame =
|
||||||
SFG_game.frame - SFG_player.weaponCooldownStartFrame;
|
SFG_game.frame - SFG_player.weaponCooldownStartFrame;
|
||||||
|
|
||||||
uint32_t animationLength = SFG_GET_WEAPON_FIRE_COOLDOWN_FRAMES(SFG_player.weapon);
|
uint32_t animationLength =
|
||||||
|
SFG_GET_WEAPON_FIRE_COOLDOWN_FRAMES(SFG_player.weapon);
|
||||||
|
|
||||||
bobOffset -= SFG_HUD_BAR_HEIGHT;
|
bobOffset -= SFG_HUD_BAR_HEIGHT;
|
||||||
|
|
||||||
@ -3112,7 +3124,8 @@ void SFG_drawWeapon(int16_t bobOffset)
|
|||||||
shotAnimationFrame < animationLength / 2)
|
shotAnimationFrame < animationLength / 2)
|
||||||
SFG_blitImage(SFG_effectSprites[0],
|
SFG_blitImage(SFG_effectSprites[0],
|
||||||
SFG_WEAPON_IMAGE_POSITION_X,
|
SFG_WEAPON_IMAGE_POSITION_X,
|
||||||
SFG_WEAPON_IMAGE_POSITION_Y - (SFG_TEXTURE_SIZE / 3) * SFG_WEAPON_IMAGE_SCALE + bobOffset,
|
SFG_WEAPON_IMAGE_POSITION_Y -
|
||||||
|
(SFG_TEXTURE_SIZE / 3) * SFG_WEAPON_IMAGE_SCALE + bobOffset,
|
||||||
SFG_WEAPON_IMAGE_SCALE);
|
SFG_WEAPON_IMAGE_SCALE);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -3150,66 +3163,58 @@ void SFG_drawMenu()
|
|||||||
SFG_getTexel(SFG_backgroundImages[0],((x + scroll) / BACKGROUND_SCALE)
|
SFG_getTexel(SFG_backgroundImages[0],((x + scroll) / BACKGROUND_SCALE)
|
||||||
% SFG_TEXTURE_SIZE,y / BACKGROUND_SCALE));
|
% SFG_TEXTURE_SIZE,y / BACKGROUND_SCALE));
|
||||||
|
|
||||||
uint16_t y = CHAR_SIZE;
|
uint16_t y = CHAR_SIZE;
|
||||||
|
|
||||||
SFG_blitImage(SFG_logoImage,
|
SFG_blitImage(SFG_logoImage,
|
||||||
SFG_GAME_RESOLUTION_X / 2 - 16 * SFG_FONT_SIZE_MEDIUM,y,SFG_FONT_SIZE_MEDIUM);
|
SFG_GAME_RESOLUTION_X / 2 - 16 * SFG_FONT_SIZE_MEDIUM,y,
|
||||||
|
SFG_FONT_SIZE_MEDIUM);
|
||||||
|
|
||||||
y += 32 * SFG_FONT_SIZE_MEDIUM + CHAR_SIZE;
|
y += 32 * SFG_FONT_SIZE_MEDIUM + CHAR_SIZE;
|
||||||
|
|
||||||
uint8_t i = 0;
|
uint8_t i = 0;
|
||||||
|
|
||||||
while (1)
|
while (1)
|
||||||
{
|
{
|
||||||
uint8_t item = SFG_getMenuItem(i);
|
uint8_t item = SFG_getMenuItem(i);
|
||||||
|
|
||||||
if (item == SFG_MENU_ITEM_NONE)
|
if (item == SFG_MENU_ITEM_NONE)
|
||||||
break;
|
break;
|
||||||
|
|
||||||
const char *text = SFG_menuItemTexts[item];
|
const char *text = SFG_menuItemTexts[item];
|
||||||
|
|
||||||
uint8_t textLen = 0;
|
uint8_t textLen = 0;
|
||||||
|
|
||||||
while (text[textLen] != 0)
|
while (text[textLen] != 0)
|
||||||
textLen++;
|
textLen++;
|
||||||
|
|
||||||
|
|
||||||
uint16_t drawX = (SFG_GAME_RESOLUTION_X - textLen * CHAR_SIZE) / 2;
|
uint16_t drawX = (SFG_GAME_RESOLUTION_X - textLen * CHAR_SIZE) / 2;
|
||||||
|
uint8_t textColor = 7;
|
||||||
|
|
||||||
|
if (i != SFG_game.selectedMenuItem)
|
||||||
|
{
|
||||||
|
textColor = 23;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
|
||||||
|
for (uint16_t l = y - SFG_FONT_SIZE_MEDIUM; l < y + CHAR_SIZE; ++l)
|
||||||
|
for (uint16_t k = SELECTION_START_X;
|
||||||
|
k < SFG_GAME_RESOLUTION_X - SELECTION_START_X; ++k)
|
||||||
uint8_t textColor = 7;
|
SFG_setGamePixel(k,l,2);
|
||||||
|
}
|
||||||
if (i != SFG_game.selectedMenuItem)
|
|
||||||
{
|
|
||||||
textColor = 23;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
|
|
||||||
for (uint16_t l = y - SFG_FONT_SIZE_MEDIUM; l < y + CHAR_SIZE; ++l)
|
|
||||||
for (uint16_t k = SELECTION_START_X; k < SFG_GAME_RESOLUTION_X - SELECTION_START_X; ++k)
|
|
||||||
SFG_setGamePixel(k,l,2);
|
|
||||||
}
|
|
||||||
|
|
||||||
SFG_drawText(text,drawX,y,SFG_FONT_SIZE_MEDIUM,textColor);
|
SFG_drawText(text,drawX,y,SFG_FONT_SIZE_MEDIUM,textColor);
|
||||||
|
|
||||||
if (item == SFG_MENU_ITEM_PLAY)
|
|
||||||
SFG_drawNumber((SFG_game.selectedLevel + 1),
|
|
||||||
drawX + CHAR_SIZE * (textLen + 1) ,y,SFG_FONT_SIZE_MEDIUM,93);
|
|
||||||
|
|
||||||
|
if (item == SFG_MENU_ITEM_PLAY)
|
||||||
|
SFG_drawNumber((SFG_game.selectedLevel + 1),
|
||||||
|
drawX + CHAR_SIZE * (textLen + 1) ,y,SFG_FONT_SIZE_MEDIUM,93);
|
||||||
|
|
||||||
y += CHAR_SIZE + SFG_FONT_SIZE_MEDIUM;
|
y += CHAR_SIZE + SFG_FONT_SIZE_MEDIUM;
|
||||||
i++;
|
i++;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
SFG_drawText("0.7 CC0",SFG_HUD_MARGIN,SFG_GAME_RESOLUTION_Y - SFG_HUD_MARGIN
|
||||||
|
- SFG_FONT_SIZE_SMALL * SFG_FONT_CHARACTER_SIZE,SFG_FONT_SIZE_SMALL,4);
|
||||||
SFG_drawText("0.7 CC0",SFG_HUD_MARGIN,SFG_GAME_RESOLUTION_Y - SFG_HUD_MARGIN
|
|
||||||
- SFG_FONT_SIZE_SMALL * SFG_FONT_CHARACTER_SIZE,
|
|
||||||
SFG_FONT_SIZE_SMALL,4);
|
|
||||||
|
|
||||||
#undef CHAR_SIZE
|
#undef CHAR_SIZE
|
||||||
#undef MAX_ITEMS
|
#undef MAX_ITEMS
|
||||||
|
Loading…
Reference in New Issue
Block a user