config.def.h (2313B)
1 /* See LICENSE file for copyright and license details. */ 2 3 Object objects[] = { 4 /* symbol z-index flags ontick argument */ 5 { VACUUM, 0, OF_OPEN, falling, {0} }, 6 [1] = {'o', 8, OF_PLAYER|OF_OPEN|OF_FALL, NULL, {.i = 2} }, 7 [2] = {'a', 8, OF_PLAYER|OF_OPEN|OF_FALL, NULL, {.i = 2} }, 8 {'_', 1, OF_OPEN|OF_STICK|OF_JUMPFROM, NULL, {0} }, 9 {'|', 1, 0, NULL, {0} }, 10 {'*', 2, OF_OPEN, earnenergy, {.i = 2} }, 11 {')', 9, OF_OPENLEFT|OF_STICK, finish, {0} }, 12 {'(', 9, OF_OPENRIGHT|OF_STICK, finish, {0} }, 13 {'t', 1, 0, cannon, {.v = &objects[11]} }, 14 {'j', 1, 0, cannon, {.v = &objects[12]} }, 15 [11] = {'.', 2, OF_OPEN|OF_AI, cannonball, {.i = +1} }, 16 [12] = {',', 2, OF_OPEN|OF_AI, cannonball, {.i = -1} }, 17 {'#', 2, OF_FALL|OF_PUSHABLE, NULL, {0} }, 18 {'@', 2, OF_FALL|OF_PUSHABLE, NULL, {0} }, 19 {'x', 8, OF_PLAYER|OF_AI|OF_OPEN|OF_FALL, zombie, {.i = 8} }, 20 }; 21 22 #include "levels.h" 23 24 Level levels[] = { 25 { "Reach the exit", lev0 }, 26 { "Reach the exit", lev1 }, 27 { "Reach the exit", lev2 }, 28 { "Run", lev3 }, 29 { "Climb up", lev4 }, 30 { "Steep fall", lev5 }, 31 { "Welcome to the arena", arena }, 32 }; 33 34 /* key definitions */ 35 static Key keys[] = { 36 /* key function argument */ 37 { 'q', quit, {.i = 1} }, 38 { CTRL('c'), quit, {.i = 0} }, 39 { 'h', walkleft, {.v = &objects[1]} }, 40 { 'n', walkright, {.v = &objects[1]} }, 41 { 'c', jump, {.v = &objects[1]} }, 42 { 'a', walkleft, {.v = &objects[2]} }, 43 { 'e', walkright, {.v = &objects[2]} }, 44 { ',', jump, {.v = &objects[2]} }, 45 { 'r', restart, {0} }, 46 };