static struct
{
+ int gadget_type_id;
int x, y;
int min_value, max_value;
int gadget_id_down, gadget_id_up;
// ---------- current level number ------------------------------------------
{
+ ED_COUNTER_ID_SELECT_LEVEL,
-1, -1, // these values are not constant, but can change at runtime
1, 100,
GADGET_ID_SELECT_LEVEL_DOWN, GADGET_ID_SELECT_LEVEL_UP,
// ---------- level and editor settings -------------------------------------
{
+ ED_COUNTER_ID_LEVEL_XSIZE,
ED_LEVEL_SETTINGS_XPOS(0), ED_LEVEL_SETTINGS_YPOS(4),
MIN_LEV_FIELDX, MAX_LEV_FIELDX,
GADGET_ID_LEVEL_XSIZE_DOWN, GADGET_ID_LEVEL_XSIZE_UP,
"playfield size:", NULL, "width",
},
{
+ ED_COUNTER_ID_LEVEL_YSIZE,
-1, ED_LEVEL_SETTINGS_YPOS(4),
MIN_LEV_FIELDY, MAX_LEV_FIELDY,
GADGET_ID_LEVEL_YSIZE_DOWN, GADGET_ID_LEVEL_YSIZE_UP,
NULL, " ", "height",
},
{
+ ED_COUNTER_ID_LEVEL_GEMSLIMIT,
ED_LEVEL_SETTINGS_XPOS(0), ED_LEVEL_SETTINGS_YPOS(5),
0, 999,
GADGET_ID_LEVEL_GEMSLIMIT_DOWN, GADGET_ID_LEVEL_GEMSLIMIT_UP,
NULL, "number of gems to collect:", NULL
},
{
+ ED_COUNTER_ID_LEVEL_TIMELIMIT,
ED_LEVEL_SETTINGS_XPOS(0), ED_LEVEL_SETTINGS_YPOS(8),
0, 9999,
GADGET_ID_LEVEL_TIMELIMIT_DOWN, GADGET_ID_LEVEL_TIMELIMIT_UP,
"time or step limit to solve level:", NULL, NULL
},
{
+ ED_COUNTER_ID_LEVEL_TIMESCORE,
ED_LEVEL_SETTINGS_XPOS(0), ED_LEVEL_SETTINGS_YPOS(10),
0, 999,
GADGET_ID_LEVEL_TIMESCORE_DOWN, GADGET_ID_LEVEL_TIMESCORE_UP,
"score for time or steps left:", NULL, NULL
},
{
+ ED_COUNTER_ID_LEVEL_RANDOM_SEED,
ED_LEVEL_SETTINGS_XPOS(0), ED_LEVEL_SETTINGS_YPOS(13),
0, 9999,
GADGET_ID_LEVEL_RANDOM_SEED_DOWN, GADGET_ID_LEVEL_RANDOM_SEED_UP,
NULL, "random seed:", "(0 => random)"
},
{
+ ED_COUNTER_ID_LEVELSET_NUM_LEVELS,
ED_LEVEL_SETTINGS_XPOS(0), ED_LEVEL_SETTINGS_YPOS(4),
1, MAX_LEVELS,
GADGET_ID_LEVELSET_NUM_LEVELS_DOWN, GADGET_ID_LEVELSET_NUM_LEVELS_UP,
"number of levels:", NULL, NULL,
},
{
+ ED_COUNTER_ID_LEVEL_RANDOM,
ED_LEVEL_SETTINGS_XPOS(0), ED_LEVEL_SETTINGS_YPOS(0),
1, 100,
GADGET_ID_LEVEL_RANDOM_DOWN, GADGET_ID_LEVEL_RANDOM_UP,
// ---------- element settings: configure (various elements) ----------------
{
+ ED_COUNTER_ID_ELEMENT_VALUE1,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(0),
MIN_SCORE, MAX_SCORE,
GADGET_ID_ELEMENT_VALUE1_DOWN, GADGET_ID_ELEMENT_VALUE1_UP,
NULL, NULL, NULL
},
{
+ ED_COUNTER_ID_ELEMENT_VALUE2,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(1),
MIN_SCORE, MAX_SCORE,
GADGET_ID_ELEMENT_VALUE2_DOWN, GADGET_ID_ELEMENT_VALUE2_UP,
NULL, NULL, NULL
},
{
+ ED_COUNTER_ID_ELEMENT_VALUE3,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(2),
MIN_SCORE, MAX_SCORE,
GADGET_ID_ELEMENT_VALUE3_DOWN, GADGET_ID_ELEMENT_VALUE3_UP,
NULL, NULL, NULL
},
{
+ ED_COUNTER_ID_ELEMENT_VALUE4,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(3),
MIN_SCORE, MAX_SCORE,
GADGET_ID_ELEMENT_VALUE4_DOWN, GADGET_ID_ELEMENT_VALUE4_UP,
NULL, NULL, NULL
},
{
+ ED_COUNTER_ID_YAMYAM_CONTENT,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(3),
MIN_ELEMENT_CONTENTS, MAX_ELEMENT_CONTENTS,
GADGET_ID_YAMYAM_CONTENT_DOWN, GADGET_ID_YAMYAM_CONTENT_UP,
NULL, NULL, "number of content areas"
},
{
+ ED_COUNTER_ID_BALL_CONTENT,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(4),
MIN_ELEMENT_CONTENTS, MAX_ELEMENT_CONTENTS,
GADGET_ID_BALL_CONTENT_DOWN, GADGET_ID_BALL_CONTENT_UP,
NULL, NULL, "number of content areas"
},
{
+ ED_COUNTER_ID_ANDROID_CONTENT,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(4),
MIN_ANDROID_ELEMENTS, MAX_ANDROID_ELEMENTS,
GADGET_ID_ANDROID_CONTENT_DOWN, GADGET_ID_ANDROID_CONTENT_UP,
NULL, NULL, "number of clonable elements"
},
{
+ ED_COUNTER_ID_ENVELOPE_XSIZE,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(0),
MIN_ENVELOPE_XSIZE, MAX_ENVELOPE_XSIZE,
GADGET_ID_ENVELOPE_XSIZE_DOWN, GADGET_ID_ENVELOPE_XSIZE_UP,
NULL, NULL, "width",
},
{
+ ED_COUNTER_ID_ENVELOPE_YSIZE,
-1, ED_ELEMENT_SETTINGS_YPOS(0),
MIN_ENVELOPE_YSIZE, MAX_ENVELOPE_YSIZE,
GADGET_ID_ENVELOPE_YSIZE_DOWN, GADGET_ID_ENVELOPE_YSIZE_UP,
NULL, " ", "height",
},
{
+ ED_COUNTER_ID_INVENTORY_SIZE,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(2),
MIN_INITIAL_INVENTORY_SIZE, MAX_INITIAL_INVENTORY_SIZE,
GADGET_ID_INVENTORY_SIZE_DOWN, GADGET_ID_INVENTORY_SIZE_UP,
NULL, NULL, "number of inventory elements"
},
{
+ ED_COUNTER_ID_MM_BALL_CONTENT,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(3),
MIN_ELEMENTS_IN_GROUP, MAX_MM_BALL_CONTENTS,
GADGET_ID_MM_BALL_CONTENT_DOWN, GADGET_ID_MM_BALL_CONTENT_UP,
// ---------- element settings: configure 1 (custom elements) ---------------
{
+ ED_COUNTER_ID_CUSTOM_SCORE,
ED_ELEMENT_SETTINGS_XPOS(1), ED_ELEMENT_SETTINGS_YPOS(5),
MIN_SCORE, MAX_SCORE,
GADGET_ID_CUSTOM_SCORE_DOWN, GADGET_ID_CUSTOM_SCORE_UP,
NULL, "CE score", " "
},
{
+ ED_COUNTER_ID_CUSTOM_GEMCOUNT,
-1, ED_ELEMENT_SETTINGS_YPOS(5),
MIN_COLLECT_COUNT, MAX_COLLECT_COUNT,
GADGET_ID_CUSTOM_GEMCOUNT_DOWN, GADGET_ID_CUSTOM_GEMCOUNT_UP,
NULL, "CE count", NULL
},
{
+ ED_COUNTER_ID_CUSTOM_VALUE_FIX,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(10),
0, 9999,
GADGET_ID_CUSTOM_VALUE_FIX_DOWN, GADGET_ID_CUSTOM_VALUE_FIX_UP,
NULL, "CE value", NULL
},
{
+ ED_COUNTER_ID_CUSTOM_VALUE_RND,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(10),
0, 9999,
GADGET_ID_CUSTOM_VALUE_RND_DOWN, GADGET_ID_CUSTOM_VALUE_RND_UP,
NULL, "+random", NULL
},
{
+ ED_COUNTER_ID_PUSH_DELAY_FIX,
ED_ELEMENT_SETTINGS_XPOS(1), ED_ELEMENT_SETTINGS_YPOS(6),
0, 999,
GADGET_ID_PUSH_DELAY_FIX_DOWN, GADGET_ID_PUSH_DELAY_FIX_UP,
NULL, "push delay", NULL
},
{
+ ED_COUNTER_ID_PUSH_DELAY_RND,
-1, ED_ELEMENT_SETTINGS_YPOS(6),
0, 999,
GADGET_ID_PUSH_DELAY_RND_DOWN, GADGET_ID_PUSH_DELAY_RND_UP,
NULL, "+random", NULL
},
{
+ ED_COUNTER_ID_DROP_DELAY_FIX,
ED_ELEMENT_SETTINGS_XPOS(1), ED_ELEMENT_SETTINGS_YPOS(7),
0, 999,
GADGET_ID_DROP_DELAY_FIX_DOWN, GADGET_ID_DROP_DELAY_FIX_UP,
NULL, "drop delay", NULL
},
{
+ ED_COUNTER_ID_DROP_DELAY_RND,
-1, ED_ELEMENT_SETTINGS_YPOS(7),
0, 999,
GADGET_ID_DROP_DELAY_RND_DOWN, GADGET_ID_DROP_DELAY_RND_UP,
// ---------- element settings: configure 2 (custom elements) ---------------
{
+ ED_COUNTER_ID_MOVE_DELAY_FIX,
ED_ELEMENT_SETTINGS_XPOS(1), ED_ELEMENT_SETTINGS_YPOS(5),
0, 999,
GADGET_ID_MOVE_DELAY_FIX_DOWN, GADGET_ID_MOVE_DELAY_FIX_UP,
NULL, "move delay", NULL
},
{
+ ED_COUNTER_ID_MOVE_DELAY_RND,
-1, ED_ELEMENT_SETTINGS_YPOS(5),
0, 999,
GADGET_ID_MOVE_DELAY_RND_DOWN, GADGET_ID_MOVE_DELAY_RND_UP,
NULL, "+random", NULL
},
{
+ ED_COUNTER_ID_STEP_DELAY_FIX,
ED_ELEMENT_SETTINGS_XPOS(1), ED_ELEMENT_SETTINGS_YPOS(6),
0, 999,
GADGET_ID_STEP_DELAY_FIX_DOWN, GADGET_ID_STEP_DELAY_FIX_UP,
NULL, "step delay", NULL
},
{
+ ED_COUNTER_ID_STEP_DELAY_RND,
-1, ED_ELEMENT_SETTINGS_YPOS(6),
0, 999,
GADGET_ID_STEP_DELAY_RND_DOWN, GADGET_ID_STEP_DELAY_RND_UP,
NULL, "+random", NULL
},
{
+ ED_COUNTER_ID_EXPLOSION_DELAY,
ED_ELEMENT_SETTINGS_XPOS(1), ED_ELEMENT_SETTINGS_YPOS(13),
0, 999,
GADGET_ID_EXPLOSION_DELAY_DOWN, GADGET_ID_EXPLOSION_DELAY_UP,
NULL, "explosion delay", NULL
},
{
+ ED_COUNTER_ID_IGNITION_DELAY,
ED_ELEMENT_SETTINGS_XPOS(1), ED_ELEMENT_SETTINGS_YPOS(14),
0, 999,
GADGET_ID_IGNITION_DELAY_DOWN, GADGET_ID_IGNITION_DELAY_UP,
// ---------- element settings: configure (group elements) ------------------
{
+ ED_COUNTER_ID_GROUP_CONTENT,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(3),
MIN_ELEMENTS_IN_GROUP, MAX_ELEMENTS_IN_GROUP,
GADGET_ID_GROUP_CONTENT_DOWN, GADGET_ID_GROUP_CONTENT_UP,
// ---------- element settings: advanced (custom elements) ------------------
{
+ ED_COUNTER_ID_CHANGE_DELAY_FIX,
ED_ELEMENT_SETTINGS_XPOS(2), ED_ELEMENT_SETTINGS_YPOS(2),
0, 999,
GADGET_ID_CHANGE_DELAY_FIX_DOWN, GADGET_ID_CHANGE_DELAY_FIX_UP,
NULL, "CE delay", NULL,
},
{
+ ED_COUNTER_ID_CHANGE_DELAY_RND,
-1, ED_ELEMENT_SETTINGS_YPOS(2),
0, 999,
GADGET_ID_CHANGE_DELAY_RND_DOWN, GADGET_ID_CHANGE_DELAY_RND_UP,
NULL, "+random", NULL
},
{
+ ED_COUNTER_ID_CHANGE_CONT_RND,
ED_ELEMENT_SETTINGS_XPOS(3), ED_ELEMENT_SETTINGS_YPOS(12),
0, 100,
GADGET_ID_CHANGE_CONT_RND_DOWN, GADGET_ID_CHANGE_CONT_RND_UP,
static struct
{
+ int gadget_type_id;
int x, y;
int gadget_id;
int size;
} textinput_info[ED_NUM_TEXTINPUT] =
{
{
+ ED_TEXTINPUT_ID_LEVEL_NAME,
ED_LEVEL_SETTINGS_XPOS(0), ED_LEVEL_SETTINGS_YPOS(0),
GADGET_ID_LEVEL_NAME,
MAX_LEVEL_NAME_LEN,
"Title:", "Title for this level"
},
{
+ ED_TEXTINPUT_ID_LEVEL_AUTHOR,
ED_LEVEL_SETTINGS_XPOS(0), ED_LEVEL_SETTINGS_YPOS(2),
GADGET_ID_LEVEL_AUTHOR,
MAX_LEVEL_AUTHOR_LEN,
"Author:", "Author for this level"
},
{
+ ED_TEXTINPUT_ID_LEVELSET_NAME,
ED_LEVEL_SETTINGS_XPOS(0), ED_LEVEL_SETTINGS_YPOS(0),
GADGET_ID_LEVELSET_NAME,
MAX_LEVEL_NAME_LEN,
"Title:", "Title for this or new level set"
},
{
+ ED_TEXTINPUT_ID_LEVELSET_AUTHOR,
ED_LEVEL_SETTINGS_XPOS(0), ED_LEVEL_SETTINGS_YPOS(2),
GADGET_ID_LEVELSET_AUTHOR,
MAX_LEVEL_AUTHOR_LEN,
"Author:", "Author for this or new level set"
},
{
+ ED_TEXTINPUT_ID_ELEMENT_NAME,
-1, -1, // these values are not constant, but can change at runtime
GADGET_ID_ELEMENT_NAME,
MAX_ELEMENT_NAME_LEN - 2, // currently 2 chars less editable
static struct
{
+ int gadget_type_id;
int x, y;
int gadget_id;
int xsize, ysize;
} textarea_info[ED_NUM_TEXTAREAS] =
{
{
+ ED_TEXTAREA_ID_ENVELOPE_INFO,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(3),
GADGET_ID_ENVELOPE_INFO,
MAX_ENVELOPE_XSIZE, MAX_ENVELOPE_YSIZE,
static struct
{
+ int gadget_type_id;
int x, y;
int gadget_id;
int gadget_id_align;
// ---------- level and editor settings -------------------------------------
{
+ ED_SELECTBOX_ID_TIME_OR_STEPS,
-1, ED_LEVEL_SETTINGS_YPOS(8),
GADGET_ID_TIME_OR_STEPS, GADGET_ID_LEVEL_TIMELIMIT_UP,
-1,
NULL, NULL, "(0 => no limit)", "time or step limit"
},
{
+ ED_SELECTBOX_ID_TIME_SCORE_BASE,
-1, ED_LEVEL_SETTINGS_YPOS(10),
GADGET_ID_TIME_SCORE_BASE, GADGET_ID_LEVEL_TIMESCORE_UP,
-1,
NULL, NULL, NULL, "time score for 1 or 10 seconds/steps"
},
{
+ ED_SELECTBOX_ID_GAME_ENGINE_TYPE,
ED_LEVEL_SETTINGS_XPOS(0), ED_LEVEL_SETTINGS_YPOS(12),
GADGET_ID_GAME_ENGINE_TYPE, GADGET_ID_NONE,
-1,
NULL, "game engine:", NULL, "game engine"
},
{
+ ED_SELECTBOX_ID_LEVELSET_SAVE_MODE,
ED_LEVEL_SETTINGS_XPOS(0), ED_LEVEL_SETTINGS_YPOS(10),
GADGET_ID_LEVELSET_SAVE_MODE, GADGET_ID_NONE,
-1,
// ---------- element settings: configure (several elements) ----------------
{
+ ED_SELECTBOX_ID_WIND_DIRECTION,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(0),
GADGET_ID_WIND_DIRECTION, GADGET_ID_NONE,
-1,
NULL, "initial wind direction:", NULL, "initial wind direction"
},
{
+ ED_SELECTBOX_ID_PLAYER_SPEED,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(7),
GADGET_ID_PLAYER_SPEED, GADGET_ID_NONE,
-1,
NULL, "initial player speed:", NULL, "initial player speed"
},
{
+ ED_SELECTBOX_ID_MM_BALL_CHOICE_MODE,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(4),
GADGET_ID_MM_BALL_CHOICE_MODE, GADGET_ID_NONE,
-1,
// ---------- element settings: configure 1 (custom elements) ---------------
{
+ ED_SELECTBOX_ID_CUSTOM_ACCESS_TYPE,
ED_ELEMENT_SETTINGS_XPOS(1), ED_ELEMENT_SETTINGS_YPOS(2),
GADGET_ID_CUSTOM_ACCESS_TYPE, GADGET_ID_NONE,
-1,
NULL, NULL, NULL, "type of access to this field"
},
{
+ ED_SELECTBOX_ID_CUSTOM_ACCESS_LAYER,
-1, ED_ELEMENT_SETTINGS_YPOS(2),
GADGET_ID_CUSTOM_ACCESS_LAYER, GADGET_ID_CUSTOM_ACCESS_TYPE,
-1,
NULL, NULL, NULL, "layer of access for this field"
},
{
+ ED_SELECTBOX_ID_CUSTOM_ACCESS_PROTECTED,
-1, ED_ELEMENT_SETTINGS_YPOS(2),
GADGET_ID_CUSTOM_ACCESS_PROTECTED, GADGET_ID_CUSTOM_ACCESS_LAYER,
-1,
NULL, NULL, NULL, "protected access for this field"
},
{
+ ED_SELECTBOX_ID_CUSTOM_ACCESS_DIRECTION,
ED_ELEMENT_SETTINGS_XPOS(1), ED_ELEMENT_SETTINGS_YPOS(3),
GADGET_ID_CUSTOM_ACCESS_DIRECTION, GADGET_ID_NONE,
-1,
NULL, "from", NULL, "access direction for this field"
},
{
+ ED_SELECTBOX_ID_CUSTOM_WALK_TO_ACTION,
ED_ELEMENT_SETTINGS_XPOS(1), ED_ELEMENT_SETTINGS_YPOS(4),
GADGET_ID_CUSTOM_WALK_TO_ACTION, GADGET_ID_NONE,
-1,
// ---------- element settings: configure 2 (custom elements) ---------------
{
+ ED_SELECTBOX_ID_CUSTOM_MOVE_PATTERN,
ED_ELEMENT_SETTINGS_XPOS(1), ED_ELEMENT_SETTINGS_YPOS(1),
GADGET_ID_CUSTOM_MOVE_PATTERN, GADGET_ID_NONE,
-1,
NULL, "can move", NULL, "element move pattern"
},
{
+ ED_SELECTBOX_ID_CUSTOM_MOVE_DIRECTION,
ED_ELEMENT_SETTINGS_XPOS(1), ED_ELEMENT_SETTINGS_YPOS(2),
GADGET_ID_CUSTOM_MOVE_DIRECTION, GADGET_ID_NONE,
-1,
NULL, "starts moving", NULL, "initial element move direction"
},
{
+ ED_SELECTBOX_ID_CUSTOM_MOVE_STEPSIZE,
ED_ELEMENT_SETTINGS_XPOS(1), ED_ELEMENT_SETTINGS_YPOS(4),
GADGET_ID_CUSTOM_MOVE_STEPSIZE, GADGET_ID_NONE,
-1,
NULL, "move/fall speed", NULL, "speed of element movement"
},
{
+ ED_SELECTBOX_ID_CUSTOM_MOVE_LEAVE_TYPE,
ED_ELEMENT_SETTINGS_XPOS(1), ED_ELEMENT_SETTINGS_YPOS(3),
GADGET_ID_CUSTOM_MOVE_LEAVE_TYPE, GADGET_ID_NONE,
-1,
NULL, " can", ":", "leave behind or change element"
},
{
+ ED_SELECTBOX_ID_CUSTOM_SMASH_TARGETS,
-1, ED_ELEMENT_SETTINGS_YPOS(8),
GADGET_ID_CUSTOM_SMASH_TARGETS, GADGET_ID_CUSTOM_CAN_SMASH,
-1,
NULL, "can smash", NULL, "elements that can be smashed"
},
{
+ ED_SELECTBOX_ID_CUSTOM_SLIPPERY_TYPE,
ED_ELEMENT_SETTINGS_XPOS(1), ED_ELEMENT_SETTINGS_YPOS(9),
GADGET_ID_CUSTOM_SLIPPERY_TYPE, GADGET_ID_NONE,
-1,
NULL, "slippery", NULL, "where other elements fall down"
},
{
+ ED_SELECTBOX_ID_CUSTOM_DEADLINESS,
ED_ELEMENT_SETTINGS_XPOS(1), ED_ELEMENT_SETTINGS_YPOS(10),
GADGET_ID_CUSTOM_DEADLINESS, GADGET_ID_NONE,
-1,
NULL, "deadly when", NULL, "deadliness of element"
},
{
+ ED_SELECTBOX_ID_CUSTOM_EXPLOSION_TYPE,
ED_ELEMENT_SETTINGS_XPOS(1), ED_ELEMENT_SETTINGS_YPOS(11),
GADGET_ID_CUSTOM_EXPLOSION_TYPE, GADGET_ID_NONE,
-1,
// ---------- element settings: advanced (custom elements) ------------------
{
+ ED_SELECTBOX_ID_CHANGE_TIME_UNITS,
ED_ELEMENT_SETTINGS_XPOS(2), ED_ELEMENT_SETTINGS_YPOS(3),
GADGET_ID_CHANGE_TIME_UNITS, GADGET_ID_NONE,
-1,
NULL, "delay time given in", NULL, "delay time units for change"
},
{
+ ED_SELECTBOX_ID_CHANGE_DIRECT_ACTION,
ED_ELEMENT_SETTINGS_XPOS(2), ED_ELEMENT_SETTINGS_YPOS(4),
GADGET_ID_CHANGE_DIRECT_ACTION, GADGET_ID_NONE,
-1,
NULL, NULL, NULL, "type of direct action"
},
{
+ ED_SELECTBOX_ID_CHANGE_OTHER_ACTION,
ED_ELEMENT_SETTINGS_XPOS(2), ED_ELEMENT_SETTINGS_YPOS(5),
GADGET_ID_CHANGE_OTHER_ACTION, GADGET_ID_NONE,
-1,
NULL, NULL, "element:", "type of other element action"
},
{
+ ED_SELECTBOX_ID_CHANGE_SIDE,
ED_ELEMENT_SETTINGS_XPOS(2), ED_ELEMENT_SETTINGS_YPOS(6),
GADGET_ID_CHANGE_SIDE, GADGET_ID_NONE,
-1,
NULL, "at", "side", "element side triggering change"
},
{
+ ED_SELECTBOX_ID_CHANGE_PLAYER,
ED_ELEMENT_SETTINGS_XPOS(2), ED_ELEMENT_SETTINGS_YPOS(7),
GADGET_ID_CHANGE_PLAYER, GADGET_ID_NONE,
-1,
NULL, "player:", " ", "player that causes change"
},
{
+ ED_SELECTBOX_ID_CHANGE_PAGE,
ED_ELEMENT_SETTINGS_XPOS(2), ED_ELEMENT_SETTINGS_YPOS(7),
GADGET_ID_CHANGE_PAGE, GADGET_ID_CHANGE_PLAYER,
-1,
NULL, "page:", NULL, "change page that causes change"
},
{
+ ED_SELECTBOX_ID_CHANGE_REPLACE_WHEN,
ED_ELEMENT_SETTINGS_XPOS(2), ED_ELEMENT_SETTINGS_YPOS(10),
GADGET_ID_CHANGE_REPLACE_WHEN, GADGET_ID_NONE,
-1,
NULL, "replace when", NULL, "which elements can be replaced"
},
{
+ ED_SELECTBOX_ID_ACTION_TYPE,
ED_ELEMENT_SETTINGS_XPOS(1), ED_ELEMENT_SETTINGS_YPOS(13),
GADGET_ID_ACTION_TYPE, GADGET_ID_NONE,
15,
NULL, NULL, NULL, "action on specified condition"
},
{
+ ED_SELECTBOX_ID_ACTION_MODE,
-1, ED_ELEMENT_SETTINGS_YPOS(13),
GADGET_ID_ACTION_MODE, GADGET_ID_ACTION_TYPE,
-1,
NULL, NULL, NULL, "action operator"
},
{
+ ED_SELECTBOX_ID_ACTION_ARG,
-1, ED_ELEMENT_SETTINGS_YPOS(13),
GADGET_ID_ACTION_ARG, GADGET_ID_ACTION_MODE,
-1,
NULL, NULL, NULL, "action parameter"
},
{
+ ED_SELECTBOX_ID_SELECT_CHANGE_PAGE,
ED_ELEMENT_SETTINGS_XPOS(1), ED_ELEMENT_SETTINGS_YPOS(14),
GADGET_ID_SELECT_CHANGE_PAGE, GADGET_ID_NONE,
3,
// ---------- element settings: configure (group elements) ------------------
{
+ ED_SELECTBOX_ID_GROUP_CHOICE_MODE,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(4),
GADGET_ID_GROUP_CHOICE_MODE, GADGET_ID_NONE,
-1,
static struct
{
+ int gadget_type_id;
int x, y;
int gadget_id;
int gadget_id_align;
// ---------- level and editor settings (tabs) ------------------------------
{
+ ED_TEXTBUTTON_ID_LEVELCONFIG_LEVEL,
ED_LEVEL_TABS_XPOS(0), ED_LEVEL_TABS_YPOS(0),
GADGET_ID_LEVELCONFIG_LEVEL, GADGET_ID_NONE,
8, "Level",
NULL, NULL, NULL, "Configure level settings"
},
{
+ ED_TEXTBUTTON_ID_LEVELCONFIG_LEVELSET,
-1, -1,
GADGET_ID_LEVELCONFIG_LEVELSET, GADGET_ID_LEVELCONFIG_LEVEL,
8, "Levelset",
NULL, NULL, NULL, "Update this or create new level set"
},
{
+ ED_TEXTBUTTON_ID_LEVELCONFIG_EDITOR,
-1, -1,
GADGET_ID_LEVELCONFIG_EDITOR, GADGET_ID_LEVELCONFIG_LEVELSET,
8, "Editor",
// ---------- element settings (tabs) ---------------------------------------
{
+ ED_TEXTBUTTON_ID_PROPERTIES_INFO,
ED_ELEMENT_TABS_XPOS(0), ED_ELEMENT_TABS_YPOS(0),
GADGET_ID_PROPERTIES_INFO, GADGET_ID_NONE,
8, "Info",
NULL, NULL, NULL, "Show information about element"
},
{
+ ED_TEXTBUTTON_ID_PROPERTIES_CONFIG,
-1, -1,
GADGET_ID_PROPERTIES_CONFIG, GADGET_ID_PROPERTIES_INFO,
8, "Config",
NULL, NULL, NULL, "Configure element properties"
},
{
+ ED_TEXTBUTTON_ID_PROPERTIES_CONFIG_1,
-1, -1,
GADGET_ID_PROPERTIES_CONFIG_1, GADGET_ID_PROPERTIES_INFO,
8, "Config 1",
NULL, NULL, NULL, "Configure element properties, part 1"
},
{
+ ED_TEXTBUTTON_ID_PROPERTIES_CONFIG_2,
-1, -1,
GADGET_ID_PROPERTIES_CONFIG_2, GADGET_ID_PROPERTIES_CONFIG_1,
8, "Config 2",
NULL, NULL, NULL, "Configure element properties, part 2"
},
{
+ ED_TEXTBUTTON_ID_PROPERTIES_CHANGE,
-1, -1,
GADGET_ID_PROPERTIES_CHANGE, GADGET_ID_PROPERTIES_CONFIG_2,
8, "Change",
// ---------- level and editor settings (buttons) ---------------------------
{
+ ED_TEXTBUTTON_ID_SAVE_LEVELSET,
ED_LEVEL_SETTINGS_XPOS(0), ED_LEVEL_SETTINGS_YPOS(10),
GADGET_ID_SAVE_LEVELSET, GADGET_ID_LEVELSET_SAVE_MODE,
-1, "Save",
NULL, NULL, NULL, "Update or create level set"
},
{
+ ED_TEXTBUTTON_ID_SAVE_AS_TEMPLATE_2,
ED_LEVEL_SETTINGS_XPOS(0), ED_LEVEL_SETTINGS_YPOS(6),
GADGET_ID_SAVE_AS_TEMPLATE_2, GADGET_ID_NONE,
-1, "Save",
// ---------- element settings (buttons) ------------------------------------
{
+ ED_TEXTBUTTON_ID_SAVE_AS_TEMPLATE_1,
-1, -1,
GADGET_ID_SAVE_AS_TEMPLATE_1, GADGET_ID_CUSTOM_USE_TEMPLATE_1,
-1, "Save",
"Save current settings as new template"
},
{
+ ED_TEXTBUTTON_ID_ADD_CHANGE_PAGE,
-1, -1,
GADGET_ID_ADD_CHANGE_PAGE, GADGET_ID_PASTE_CHANGE_PAGE,
-1, "New",
NULL, NULL, NULL, "Add new change page"
},
{
+ ED_TEXTBUTTON_ID_DEL_CHANGE_PAGE,
-1, -1,
GADGET_ID_DEL_CHANGE_PAGE, GADGET_ID_ADD_CHANGE_PAGE,
-1, "Delete",
static struct
{
+ int gadget_type_id;
int graphic;
int x, y;
int gadget_id;
} graphicbutton_info[ED_NUM_GRAPHICBUTTONS] =
{
{
+ ED_GRAPHICBUTTON_ID_PREV_CHANGE_PAGE,
IMG_EDITOR_COUNTER_DOWN,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(14),
GADGET_ID_PREV_CHANGE_PAGE, GADGET_ID_NONE,
NULL, NULL, "select previous change page"
},
{
+ ED_GRAPHICBUTTON_ID_NEXT_CHANGE_PAGE,
IMG_EDITOR_COUNTER_UP,
-1, ED_ELEMENT_SETTINGS_YPOS(14),
GADGET_ID_NEXT_CHANGE_PAGE, GADGET_ID_SELECT_CHANGE_PAGE,
NULL, "change page", "select next change page"
},
{
+ ED_GRAPHICBUTTON_ID_COPY_CHANGE_PAGE,
IMG_GFX_EDITOR_BUTTON_CP_COPY,
-1, ED_ELEMENT_SETTINGS_YPOS(14),
GADGET_ID_COPY_CHANGE_PAGE, GADGET_ID_NEXT_CHANGE_PAGE,
" ", NULL, "copy settings from this change page"
},
{
+ ED_GRAPHICBUTTON_ID_PASTE_CHANGE_PAGE,
IMG_GFX_EDITOR_BUTTON_CP_PASTE,
-1, ED_ELEMENT_SETTINGS_YPOS(14),
GADGET_ID_PASTE_CHANGE_PAGE, GADGET_ID_COPY_CHANGE_PAGE,
static struct
{
+ int gadget_type_id;
int graphic;
int gadget_id;
char *infotext;
} scrollbutton_info[ED_NUM_SCROLLBUTTONS] =
{
{
+ ED_SCROLLBUTTON_ID_AREA_UP,
IMG_EDITOR_PLAYFIELD_SCROLL_UP,
GADGET_ID_SCROLL_UP,
"scroll level editing area up"
},
{
+ ED_SCROLLBUTTON_ID_AREA_DOWN,
IMG_EDITOR_PLAYFIELD_SCROLL_DOWN,
GADGET_ID_SCROLL_DOWN,
"scroll level editing area down"
},
{
+ ED_SCROLLBUTTON_ID_AREA_LEFT,
IMG_EDITOR_PLAYFIELD_SCROLL_LEFT,
GADGET_ID_SCROLL_LEFT,
"scroll level editing area left"
},
{
+ ED_SCROLLBUTTON_ID_AREA_RIGHT,
IMG_EDITOR_PLAYFIELD_SCROLL_RIGHT,
GADGET_ID_SCROLL_RIGHT,
"scroll level editing area right"
},
{
+ ED_SCROLLBUTTON_ID_LIST_UP,
IMG_EDITOR_PALETTE_SCROLL_UP,
GADGET_ID_SCROLL_LIST_UP,
"scroll element list up ('Page Up')"
},
{
+ ED_SCROLLBUTTON_ID_LIST_DOWN,
IMG_EDITOR_PALETTE_SCROLL_DOWN,
GADGET_ID_SCROLL_LIST_DOWN,
"scroll element list down ('Page Down')"
static struct
{
+ int gadget_type_id;
int graphic;
int type;
int gadget_id;
} scrollbar_info[ED_NUM_SCROLLBARS] =
{
{
+ ED_SCROLLBAR_ID_AREA_HORIZONTAL,
IMG_EDITOR_PLAYFIELD_SCROLLBAR,
GD_TYPE_SCROLLBAR_HORIZONTAL,
GADGET_ID_SCROLL_HORIZONTAL,
"scroll level editing area horizontally"
},
{
+ ED_SCROLLBAR_ID_AREA_VERTICAL,
IMG_EDITOR_PLAYFIELD_SCROLLBAR,
GD_TYPE_SCROLLBAR_VERTICAL,
GADGET_ID_SCROLL_VERTICAL,
"scroll level editing area vertically"
},
{
+ ED_SCROLLBAR_ID_LIST_VERTICAL,
IMG_EDITOR_PALETTE_SCROLLBAR,
GD_TYPE_SCROLLBAR_VERTICAL,
GADGET_ID_SCROLL_LIST_VERTICAL,
static struct
{
+ int gadget_type_id;
int x, y;
int gadget_id;
int gadget_id_align;
} radiobutton_info[ED_NUM_RADIOBUTTONS] =
{
{
+ ED_RADIOBUTTON_ID_PERCENTAGE,
-1, ED_LEVEL_SETTINGS_YPOS(0),
GADGET_ID_RANDOM_PERCENTAGE, GADGET_ID_LEVEL_RANDOM_UP,
RADIO_NR_RANDOM_ELEMENTS,
" ", "percentage", "use percentage for random elements"
},
{
+ ED_RADIOBUTTON_ID_QUANTITY,
-1, ED_LEVEL_SETTINGS_YPOS(0),
GADGET_ID_RANDOM_QUANTITY, GADGET_ID_RANDOM_PERCENTAGE,
RADIO_NR_RANDOM_ELEMENTS,
static struct
{
+ int gadget_type_id;
int x, y;
int gadget_id;
int gadget_id_align;
// ---------- level and editor settings -------------------------------------
{
+ ED_CHECKBUTTON_ID_AUTO_COUNT_GEMS,
ED_LEVEL_SETTINGS_XPOS(0), ED_LEVEL_SETTINGS_YPOS(6),
GADGET_ID_AUTO_COUNT_GEMS, GADGET_ID_NONE,
&level.auto_count_gems,
"automatically count gems needed", "set counter to number of gems"
},
{
+ ED_CHECKBUTTON_ID_RATE_TIME_OVER_SCORE,
ED_LEVEL_SETTINGS_XPOS(0), ED_LEVEL_SETTINGS_YPOS(11),
GADGET_ID_RATE_TIME_OVER_SCORE, GADGET_ID_NONE,
&level.rate_time_over_score,
"rate time/steps used over score", "sort high scores by playing time/steps"
},
{
+ ED_CHECKBUTTON_ID_USE_LEVELSET_ARTWORK,
ED_LEVEL_SETTINGS_XPOS(0), ED_LEVEL_SETTINGS_YPOS(7),
GADGET_ID_USE_LEVELSET_ARTWORK, GADGET_ID_NONE,
&levelset_use_levelset_artwork,
"use current custom artwork", "use custom artwork of this level set"
},
{
+ ED_CHECKBUTTON_ID_COPY_LEVEL_TEMPLATE,
ED_LEVEL_SETTINGS_XPOS(0), ED_LEVEL_SETTINGS_YPOS(8),
GADGET_ID_COPY_LEVEL_TEMPLATE, GADGET_ID_NONE,
&levelset_copy_level_template,
"copy current level template", "copy level template of this level set"
},
{
+ ED_CHECKBUTTON_ID_RANDOM_RESTRICTED,
ED_LEVEL_SETTINGS_XPOS(0), ED_LEVEL_SETTINGS_YPOS(1),
GADGET_ID_RANDOM_RESTRICTED, GADGET_ID_NONE,
&random_placement_background_restricted,
"restrict random placement to:", "set random placement restriction"
},
{
+ ED_CHECKBUTTON_ID_CUSTOM_USE_TEMPLATE_3,
ED_LEVEL_SETTINGS_XPOS(0), ED_LEVEL_SETTINGS_YPOS(4),
GADGET_ID_CUSTOM_USE_TEMPLATE_3, GADGET_ID_NONE,
&setup.editor.use_template_for_new_levels,
"use template for new levels", "use template for level properties"
},
{
+ ED_CHECKBUTTON_ID_CUSTOM_USE_TEMPLATE_2,
ED_LEVEL_SETTINGS_XPOS(0), ED_LEVEL_SETTINGS_YPOS(5),
GADGET_ID_CUSTOM_USE_TEMPLATE_2, GADGET_ID_NONE,
&level.use_custom_template,
// ---------- element settings: configure (various elements) ----------------
{
+ ED_CHECKBUTTON_ID_STICK_ELEMENT,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(0),
GADGET_ID_STICK_ELEMENT, GADGET_ID_NONE,
&stick_element_properties_window,
"stick this screen to edit content","stick this screen to edit content"
},
{
+ ED_CHECKBUTTON_ID_EM_SLIPPERY_GEMS,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(1),
GADGET_ID_EM_SLIPPERY_GEMS, GADGET_ID_NONE,
&level.em_slippery_gems,
"slip down from certain flat walls","use EM/DC style slipping behaviour"
},
{
+ ED_CHECKBUTTON_ID_EM_EXPLODES_BY_FIRE,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(1),
GADGET_ID_EM_EXPLODES_BY_FIRE, GADGET_ID_NONE,
&level.em_explodes_by_fire,
"explodes with chain reaction", "use R'n'D style explosion behaviour"
},
{
+ ED_CHECKBUTTON_ID_USE_SPRING_BUG,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(2),
GADGET_ID_USE_SPRING_BUG, GADGET_ID_NONE,
&level.use_spring_bug,
"use spring pushing bug", "use odd spring pushing behaviour"
},
{
+ ED_CHECKBUTTON_ID_USE_TIME_ORB_BUG,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(1),
GADGET_ID_USE_TIME_ORB_BUG, GADGET_ID_NONE,
&level.use_time_orb_bug,
"use time orb bug", "use odd time orb behaviour"
},
{
+ ED_CHECKBUTTON_ID_USE_LIFE_BUGS,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(5),
GADGET_ID_USE_LIFE_BUGS, GADGET_ID_NONE,
&level.use_life_bugs,
"use buggy element behaviour", "use odd (historic) element behaviour"
},
{
+ ED_CHECKBUTTON_ID_RANDOM_BALL_CONTENT,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(2),
GADGET_ID_RANDOM_BALL_CONTENT, GADGET_ID_NONE,
&level.ball_random,
"create single random element", "only create one element from content"
},
{
+ ED_CHECKBUTTON_ID_INITIAL_BALL_ACTIVE,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(1),
GADGET_ID_INITIAL_BALL_ACTIVE, GADGET_ID_NONE,
&level.ball_active_initial,
"magic ball initially activated", "activate magic ball after level start"
},
{
+ ED_CHECKBUTTON_ID_GROW_INTO_DIGGABLE,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(0),
GADGET_ID_GROW_INTO_DIGGABLE, GADGET_ID_NONE,
&level.grow_into_diggable,
"can grow into anything diggable", "grow into more than just sand"
},
{
+ ED_CHECKBUTTON_ID_SB_FIELDS_NEEDED,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(0),
GADGET_ID_SB_FIELDS_NEEDED, GADGET_ID_NONE,
&level.sb_fields_needed,
"all fields need to be filled", "require all SB fields to be solved"
},
{
+ ED_CHECKBUTTON_ID_SB_OBJECTS_NEEDED,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(0),
GADGET_ID_SB_OBJECTS_NEEDED, GADGET_ID_NONE,
&level.sb_objects_needed,
"all objects need to be placed", "require all SB objects to be solved"
},
{
+ ED_CHECKBUTTON_ID_AUTO_EXIT_SOKOBAN,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(1),
GADGET_ID_AUTO_EXIT_SOKOBAN, GADGET_ID_NONE,
&level.auto_exit_sokoban,
"exit level if all tasks solved", "automatically finish Sokoban levels"
},
{
+ ED_CHECKBUTTON_ID_SOLVED_BY_ONE_PLAYER,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(14),
GADGET_ID_SOLVED_BY_ONE_PLAYER, GADGET_ID_NONE,
&level.solved_by_one_player,
"only one player must enter exit", "level solved by first player in exit"
},
{
+ ED_CHECKBUTTON_ID_FINISH_DIG_COLLECT,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(3),
GADGET_ID_FINISH_DIG_COLLECT, GADGET_ID_NONE,
&level.finish_dig_collect,
"CE action on finished dig/collect", "only finished dig/collect triggers CE"
},
{
+ ED_CHECKBUTTON_ID_KEEP_WALKABLE_CE,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(4),
GADGET_ID_KEEP_WALKABLE_CE, GADGET_ID_NONE,
&level.keep_walkable_ce,
"keep walkable CE changed to player", "keep CE changing to player if walkable"
},
{
+ ED_CHECKBUTTON_ID_CONTINUOUS_SNAPPING,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(9),
GADGET_ID_CONTINUOUS_SNAPPING, GADGET_ID_NONE,
&level.continuous_snapping,
"continuous snapping", "use snapping without releasing key"
},
{
+ ED_CHECKBUTTON_ID_BLOCK_SNAP_FIELD,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(8),
GADGET_ID_BLOCK_SNAP_FIELD, GADGET_ID_NONE,
&level.block_snap_field,
"block snapped field when snapping", "use snapping delay to show animation"
},
{
+ ED_CHECKBUTTON_ID_BLOCK_LAST_FIELD,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(2),
GADGET_ID_BLOCK_LAST_FIELD, GADGET_ID_NONE,
&level.block_last_field,
"block last field when moving", "player blocks last field when moving"
},
{
+ ED_CHECKBUTTON_ID_SP_BLOCK_LAST_FIELD,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(2),
GADGET_ID_SP_BLOCK_LAST_FIELD, GADGET_ID_NONE,
&level.sp_block_last_field,
"block last field when moving", "player blocks last field when moving"
},
{
+ ED_CHECKBUTTON_ID_INSTANT_RELOCATION,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(3),
GADGET_ID_INSTANT_RELOCATION, GADGET_ID_NONE,
&level.instant_relocation,
"no scrolling when relocating", "player gets relocated without delay"
},
{
+ ED_CHECKBUTTON_ID_SHIFTED_RELOCATION,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(4),
GADGET_ID_SHIFTED_RELOCATION, GADGET_ID_NONE,
&level.shifted_relocation,
"no centering when relocating", "level not centered after relocation"
},
{
+ ED_CHECKBUTTON_ID_LAZY_RELOCATION,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(5),
GADGET_ID_LAZY_RELOCATION, GADGET_ID_NONE,
&level.lazy_relocation,
"only redraw off-screen relocation","no redraw if relocation target visible"
},
{
+ ED_CHECKBUTTON_ID_USE_START_ELEMENT,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(10),
GADGET_ID_USE_START_ELEMENT, GADGET_ID_NONE,
&level.use_start_element[0],
"use level start element:", "start level at this element's position"
},
{
+ ED_CHECKBUTTON_ID_USE_ARTWORK_ELEMENT,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(11),
GADGET_ID_USE_ARTWORK_ELEMENT, GADGET_ID_NONE,
&level.use_artwork_element[0],
"use artwork from element:", "use player artwork from other element"
},
{
+ ED_CHECKBUTTON_ID_USE_EXPLOSION_ELEMENT,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(12),
GADGET_ID_USE_EXPLOSION_ELEMENT, GADGET_ID_NONE,
&level.use_explosion_element[0],
"use explosion from element:", "use explosion properties from element"
},
{
+ ED_CHECKBUTTON_ID_INITIAL_GRAVITY,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(13),
GADGET_ID_INITIAL_GRAVITY, GADGET_ID_NONE,
&level.initial_player_gravity[0],
"use initial gravity", "set initial player gravity"
},
{
+ ED_CHECKBUTTON_ID_USE_INITIAL_INVENTORY,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(1),
GADGET_ID_USE_INITIAL_INVENTORY, GADGET_ID_NONE,
&level.use_initial_inventory[0],
"use initial inventory:", "use collected elements on level start"
},
{
+ ED_CHECKBUTTON_ID_CAN_PASS_TO_WALKABLE,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(6),
GADGET_ID_CAN_PASS_TO_WALKABLE, GADGET_ID_NONE,
&level.can_pass_to_walkable,
"can pass to walkable element", "player can pass to empty or walkable"
},
{
+ ED_CHECKBUTTON_ID_CAN_FALL_INTO_ACID,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(1),
GADGET_ID_CAN_FALL_INTO_ACID, GADGET_ID_NONE,
&custom_element_properties[EP_CAN_MOVE_INTO_ACID],
"can fall into acid (with gravity)","player can fall into acid pool"
},
{
+ ED_CHECKBUTTON_ID_CAN_MOVE_INTO_ACID,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(0),
GADGET_ID_CAN_MOVE_INTO_ACID, GADGET_ID_NONE,
&custom_element_properties[EP_CAN_MOVE_INTO_ACID],
"can move into acid", "element can move into acid pool"
},
{
+ ED_CHECKBUTTON_ID_DONT_COLLIDE_WITH,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(1),
GADGET_ID_DONT_COLLIDE_WITH, GADGET_ID_NONE,
&custom_element_properties[EP_DONT_COLLIDE_WITH],
"deadly when colliding with", "element is deadly when hitting player"
},
{
+ ED_CHECKBUTTON_ID_BD_DIAGONAL_MOVEMENTS,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(0),
GADGET_ID_BD_DIAGONAL_MOVEMENTS, GADGET_ID_NONE,
&level.bd_diagonal_movements,
"can move diagonally", "player can move diagonally"
},
{
+ ED_CHECKBUTTON_ID_ENVELOPE_AUTOWRAP,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(1),
GADGET_ID_ENVELOPE_AUTOWRAP, GADGET_ID_NONE,
&level.envelope[0].autowrap,
"auto-wrap", "automatically wrap envelope text"
},
{
+ ED_CHECKBUTTON_ID_ENVELOPE_CENTERED,
-1, ED_ELEMENT_SETTINGS_YPOS(1),
GADGET_ID_ENVELOPE_CENTERED, GADGET_ID_ENVELOPE_AUTOWRAP,
&level.envelope[0].centered,
"centered", "automatically center envelope text"
},
{
+ ED_CHECKBUTTON_ID_MM_LASER_RED,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(1),
GADGET_ID_MM_LASER_RED, GADGET_ID_NONE,
&level.mm_laser_red,
"red", "use red color components in laser"
},
{
+ ED_CHECKBUTTON_ID_MM_LASER_GREEN,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(2),
GADGET_ID_MM_LASER_GREEN, GADGET_ID_NONE,
&level.mm_laser_green,
"green", "use green color components in laser"
},
{
+ ED_CHECKBUTTON_ID_MM_LASER_BLUE,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(3),
GADGET_ID_MM_LASER_BLUE, GADGET_ID_NONE,
&level.mm_laser_blue,
"blue", "use blue color components in laser"
},
{
+ ED_CHECKBUTTON_ID_DF_LASER_RED,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(1),
GADGET_ID_DF_LASER_RED, GADGET_ID_NONE,
&level.df_laser_red,
"red", "use red color components in laser"
},
{
+ ED_CHECKBUTTON_ID_DF_LASER_GREEN,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(2),
GADGET_ID_DF_LASER_GREEN, GADGET_ID_NONE,
&level.df_laser_green,
"green", "use green color components in laser"
},
{
+ ED_CHECKBUTTON_ID_DF_LASER_BLUE,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(3),
GADGET_ID_DF_LASER_BLUE, GADGET_ID_NONE,
&level.df_laser_blue,
"blue", "use blue color components in laser"
},
{
+ ED_CHECKBUTTON_ID_ROTATE_MM_BALL_CONTENT,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(5),
GADGET_ID_ROTATE_MM_BALL_CONTENT, GADGET_ID_NONE,
&level.rotate_mm_ball_content,
"randomly rotate created content", "randomly rotate newly created content"
},
{
+ ED_CHECKBUTTON_ID_EXPLODE_MM_BALL,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(6),
GADGET_ID_EXPLODE_MM_BALL, GADGET_ID_NONE,
&level.explode_mm_ball,
// ---------- element settings: configure 1 (custom elements) ---------------
{
+ ED_CHECKBUTTON_ID_CUSTOM_USE_GRAPHIC,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(1),
GADGET_ID_CUSTOM_USE_GRAPHIC, GADGET_ID_NONE,
&custom_element.use_gfx_element,
"use graphic of element:", "use existing element graphic"
},
{
+ ED_CHECKBUTTON_ID_CUSTOM_USE_TEMPLATE_1,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(14),
GADGET_ID_CUSTOM_USE_TEMPLATE_1, GADGET_ID_NONE,
&level.use_custom_template,
"use template", "use template for custom properties"
},
{
+ ED_CHECKBUTTON_ID_CUSTOM_ACCESSIBLE,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(2),
GADGET_ID_CUSTOM_ACCESSIBLE, GADGET_ID_NONE,
&custom_element_properties[EP_ACCESSIBLE],
NULL, "player can walk to or pass this field"
},
{
+ ED_CHECKBUTTON_ID_CUSTOM_GRAV_REACHABLE,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(9),
GADGET_ID_CUSTOM_GRAV_REACHABLE, GADGET_ID_NONE,
&custom_element_properties[EP_GRAVITY_REACHABLE],
"reachable despite gravity", "player can walk/dig despite gravity"
},
{
+ ED_CHECKBUTTON_ID_CUSTOM_USE_LAST_VALUE,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(11),
GADGET_ID_CUSTOM_USE_LAST_VALUE, GADGET_ID_NONE,
&custom_element.use_last_ce_value,
"use last CE value after change", "use last CE value after change"
},
{
+ ED_CHECKBUTTON_ID_CUSTOM_WALK_TO_OBJECT,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(4),
GADGET_ID_CUSTOM_WALK_TO_OBJECT, GADGET_ID_NONE,
&custom_element_properties[EP_WALK_TO_OBJECT],
NULL, "player can dig/collect/push element"
},
{
+ ED_CHECKBUTTON_ID_CUSTOM_INDESTRUCTIBLE,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(8),
GADGET_ID_CUSTOM_INDESTRUCTIBLE, GADGET_ID_NONE,
&custom_element_properties[EP_INDESTRUCTIBLE],
// ---------- element settings: configure 2 (custom elements) ---------------
{
+ ED_CHECKBUTTON_ID_CUSTOM_CAN_MOVE,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(1),
GADGET_ID_CUSTOM_CAN_MOVE, GADGET_ID_NONE,
&custom_element_properties[EP_CAN_MOVE],
NULL, "element can move with some pattern"
},
{
+ ED_CHECKBUTTON_ID_CUSTOM_CAN_FALL,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(8),
GADGET_ID_CUSTOM_CAN_FALL, GADGET_ID_NONE,
&custom_element_properties[EP_CAN_FALL],
"can fall", "element can fall down"
},
{
+ ED_CHECKBUTTON_ID_CUSTOM_CAN_SMASH,
-1, ED_ELEMENT_SETTINGS_YPOS(8),
GADGET_ID_CUSTOM_CAN_SMASH, GADGET_ID_CUSTOM_CAN_FALL,
&custom_element_properties[EP_CAN_SMASH],
NULL, "element can smash other elements"
},
{
+ ED_CHECKBUTTON_ID_CUSTOM_SLIPPERY,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(9),
GADGET_ID_CUSTOM_SLIPPERY, GADGET_ID_NONE,
&custom_element_properties[EP_SLIPPERY],
NULL, "other elements can fall down from it"
},
{
+ ED_CHECKBUTTON_ID_CUSTOM_DEADLY,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(10),
GADGET_ID_CUSTOM_DEADLY, GADGET_ID_NONE,
&custom_element_properties[EP_DEADLY],
NULL, "element can kill the player"
},
{
+ ED_CHECKBUTTON_ID_CUSTOM_CAN_EXPLODE,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(11),
GADGET_ID_CUSTOM_CAN_EXPLODE, GADGET_ID_NONE,
&custom_element_properties[EP_CAN_EXPLODE],
NULL, "element can explode"
},
{
+ ED_CHECKBUTTON_ID_CUSTOM_EXPLODE_FIRE,
ED_ELEMENT_SETTINGS_XPOS(1), ED_ELEMENT_SETTINGS_YPOS(12),
GADGET_ID_CUSTOM_EXPLODE_FIRE, GADGET_ID_NONE,
&custom_element_properties[EP_EXPLODES_BY_FIRE],
"by fire", "element can explode by fire/explosion"
},
{
+ ED_CHECKBUTTON_ID_CUSTOM_EXPLODE_SMASH,
-1, ED_ELEMENT_SETTINGS_YPOS(12),
GADGET_ID_CUSTOM_EXPLODE_SMASH, GADGET_ID_CUSTOM_EXPLODE_FIRE,
&custom_element_properties[EP_EXPLODES_SMASHED],
"smashed", "element can explode when smashed"
},
{
+ ED_CHECKBUTTON_ID_CUSTOM_EXPLODE_IMPACT,
-1, ED_ELEMENT_SETTINGS_YPOS(12),
GADGET_ID_CUSTOM_EXPLODE_IMPACT, GADGET_ID_CUSTOM_EXPLODE_SMASH,
&custom_element_properties[EP_EXPLODES_IMPACT],
// ---------- element settings: advanced (custom elements) ------------------
{
+ ED_CHECKBUTTON_ID_CUSTOM_CAN_CHANGE,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(1),
GADGET_ID_CUSTOM_CAN_CHANGE, GADGET_ID_NONE,
&custom_element_change.can_change,
"element changes to:", "change element on specified condition"
},
{
+ ED_CHECKBUTTON_ID_CHANGE_DELAY,
ED_ELEMENT_SETTINGS_XPOS(1), ED_ELEMENT_SETTINGS_YPOS(2),
GADGET_ID_CHANGE_DELAY, GADGET_ID_NONE,
&custom_element_change_events[CE_DELAY],
NULL, "element changes after delay"
},
{
+ ED_CHECKBUTTON_ID_CHANGE_BY_DIRECT_ACT,
ED_ELEMENT_SETTINGS_XPOS(1), ED_ELEMENT_SETTINGS_YPOS(4),
GADGET_ID_CHANGE_BY_DIRECT_ACT, GADGET_ID_NONE,
&custom_element_change_events[CE_BY_DIRECT_ACTION],
NULL, "element changes by direct action"
},
{
+ ED_CHECKBUTTON_ID_CHANGE_BY_OTHER_ACT,
ED_ELEMENT_SETTINGS_XPOS(1), ED_ELEMENT_SETTINGS_YPOS(5),
GADGET_ID_CHANGE_BY_OTHER_ACT, GADGET_ID_NONE,
&custom_element_change_events[CE_BY_OTHER_ACTION],
NULL, "element changes by other element"
},
{
+ ED_CHECKBUTTON_ID_CHANGE_USE_EXPLOSION,
ED_ELEMENT_SETTINGS_XPOS(1), ED_ELEMENT_SETTINGS_YPOS(8),
GADGET_ID_CHANGE_USE_EXPLOSION, GADGET_ID_NONE,
&custom_element_change.explode,
"explode instead of change", "element explodes instead of change"
},
{
+ ED_CHECKBUTTON_ID_CHANGE_USE_CONTENT,
ED_ELEMENT_SETTINGS_XPOS(1), ED_ELEMENT_SETTINGS_YPOS(9),
GADGET_ID_CHANGE_USE_CONTENT, GADGET_ID_NONE,
&custom_element_change.use_target_content,
"use extended change target:", "element changes to more elements"
},
{
+ ED_CHECKBUTTON_ID_CHANGE_ONLY_COMPLETE,
ED_ELEMENT_SETTINGS_XPOS(2), ED_ELEMENT_SETTINGS_YPOS(11),
GADGET_ID_CHANGE_ONLY_COMPLETE, GADGET_ID_NONE,
&custom_element_change.only_if_complete,
"replace all or nothing", "only replace when all can be changed"
},
{
+ ED_CHECKBUTTON_ID_CHANGE_USE_RANDOM,
ED_ELEMENT_SETTINGS_XPOS(2), ED_ELEMENT_SETTINGS_YPOS(12),
GADGET_ID_CHANGE_USE_RANDOM, GADGET_ID_NONE,
&custom_element_change.use_random_replace,
NULL, "use percentage for random replace"
},
{
+ ED_CHECKBUTTON_ID_CHANGE_HAS_ACTION,
ED_ELEMENT_SETTINGS_XPOS(0), ED_ELEMENT_SETTINGS_YPOS(13),
GADGET_ID_CHANGE_HAS_ACTION, GADGET_ID_NONE,
&custom_element_change.has_action,
static struct
{
+ int gadget_type_id;
int x, y;
int xoffset, yoffset;
int gadget_id;
// ---------- level playfield content ---------------------------------------
{
+ ED_DRAWING_ID_DRAWING_LEVEL,
0, 0,
0, 0,
GADGET_ID_DRAWING_LEVEL, GADGET_ID_NONE,
// ---------- yam yam content -----------------------------------------------
{
+ ED_DRAWING_ID_YAMYAM_CONTENT_0,
ED_AREA_YAMYAM_CONTENT_XPOS, ED_AREA_YAMYAM_CONTENT_YPOS,
ED_AREA_YAMYAM_CONTENT_XOFF(0), ED_AREA_YAMYAM_CONTENT_YOFF(0),
GADGET_ID_YAMYAM_CONTENT_0, GADGET_ID_NONE,
NULL, NULL, NULL, "1", NULL
},
{
+ ED_DRAWING_ID_YAMYAM_CONTENT_1,
ED_AREA_YAMYAM_CONTENT_XPOS, ED_AREA_YAMYAM_CONTENT_YPOS,
ED_AREA_YAMYAM_CONTENT_XOFF(1), ED_AREA_YAMYAM_CONTENT_YOFF(1),
GADGET_ID_YAMYAM_CONTENT_1, GADGET_ID_NONE,
NULL, NULL, NULL, "2", NULL
},
{
+ ED_DRAWING_ID_YAMYAM_CONTENT_2,
ED_AREA_YAMYAM_CONTENT_XPOS, ED_AREA_YAMYAM_CONTENT_YPOS,
ED_AREA_YAMYAM_CONTENT_XOFF(2), ED_AREA_YAMYAM_CONTENT_YOFF(2),
GADGET_ID_YAMYAM_CONTENT_2, GADGET_ID_NONE,
NULL, NULL, NULL, "3", NULL
},
{
+ ED_DRAWING_ID_YAMYAM_CONTENT_3,
ED_AREA_YAMYAM_CONTENT_XPOS, ED_AREA_YAMYAM_CONTENT_YPOS,
ED_AREA_YAMYAM_CONTENT_XOFF(3), ED_AREA_YAMYAM_CONTENT_YOFF(3),
GADGET_ID_YAMYAM_CONTENT_3, GADGET_ID_NONE,
NULL, NULL, NULL, "4", NULL
},
{
+ ED_DRAWING_ID_YAMYAM_CONTENT_4,
ED_AREA_YAMYAM_CONTENT_XPOS, ED_AREA_YAMYAM_CONTENT_YPOS,
ED_AREA_YAMYAM_CONTENT_XOFF(4), ED_AREA_YAMYAM_CONTENT_YOFF(4),
GADGET_ID_YAMYAM_CONTENT_4, GADGET_ID_NONE,
NULL, NULL, NULL, "5", NULL
},
{
+ ED_DRAWING_ID_YAMYAM_CONTENT_5,
ED_AREA_YAMYAM_CONTENT_XPOS, ED_AREA_YAMYAM_CONTENT_YPOS,
ED_AREA_YAMYAM_CONTENT_XOFF(5), ED_AREA_YAMYAM_CONTENT_YOFF(5),
GADGET_ID_YAMYAM_CONTENT_5, GADGET_ID_NONE,
NULL, NULL, NULL, "6", NULL
},
{
+ ED_DRAWING_ID_YAMYAM_CONTENT_6,
ED_AREA_YAMYAM_CONTENT_XPOS, ED_AREA_YAMYAM_CONTENT_YPOS,
ED_AREA_YAMYAM_CONTENT_XOFF(6), ED_AREA_YAMYAM_CONTENT_YOFF(6),
GADGET_ID_YAMYAM_CONTENT_6, GADGET_ID_NONE,
NULL, NULL, NULL, "7", NULL
},
{
+ ED_DRAWING_ID_YAMYAM_CONTENT_7,
ED_AREA_YAMYAM_CONTENT_XPOS, ED_AREA_YAMYAM_CONTENT_YPOS,
ED_AREA_YAMYAM_CONTENT_XOFF(7), ED_AREA_YAMYAM_CONTENT_YOFF(7),
GADGET_ID_YAMYAM_CONTENT_7, GADGET_ID_NONE,
// ---------- magic ball content --------------------------------------------
{
+ ED_DRAWING_ID_MAGIC_BALL_CONTENT_0,
ED_AREA_MAGIC_BALL_CONTENT_XPOS, ED_AREA_MAGIC_BALL_CONTENT_YPOS,
ED_AREA_MAGIC_BALL_CONTENT_XOFF(0), ED_AREA_MAGIC_BALL_CONTENT_YOFF(0),
GADGET_ID_MAGIC_BALL_CONTENT_0, GADGET_ID_NONE,
NULL, NULL, NULL, "1", NULL
},
{
+ ED_DRAWING_ID_MAGIC_BALL_CONTENT_1,
ED_AREA_MAGIC_BALL_CONTENT_XPOS, ED_AREA_MAGIC_BALL_CONTENT_YPOS,
ED_AREA_MAGIC_BALL_CONTENT_XOFF(1), ED_AREA_MAGIC_BALL_CONTENT_YOFF(1),
GADGET_ID_MAGIC_BALL_CONTENT_1, GADGET_ID_NONE,
NULL, NULL, NULL, "2", NULL
},
{
+ ED_DRAWING_ID_MAGIC_BALL_CONTENT_2,
ED_AREA_MAGIC_BALL_CONTENT_XPOS, ED_AREA_MAGIC_BALL_CONTENT_YPOS,
ED_AREA_MAGIC_BALL_CONTENT_XOFF(2), ED_AREA_MAGIC_BALL_CONTENT_YOFF(2),
GADGET_ID_MAGIC_BALL_CONTENT_2, GADGET_ID_NONE,
NULL, NULL, NULL, "3", NULL
},
{
+ ED_DRAWING_ID_MAGIC_BALL_CONTENT_3,
ED_AREA_MAGIC_BALL_CONTENT_XPOS, ED_AREA_MAGIC_BALL_CONTENT_YPOS,
ED_AREA_MAGIC_BALL_CONTENT_XOFF(3), ED_AREA_MAGIC_BALL_CONTENT_YOFF(3),
GADGET_ID_MAGIC_BALL_CONTENT_3, GADGET_ID_NONE,
NULL, NULL, NULL, "4", NULL
},
{
+ ED_DRAWING_ID_MAGIC_BALL_CONTENT_4,
ED_AREA_MAGIC_BALL_CONTENT_XPOS, ED_AREA_MAGIC_BALL_CONTENT_YPOS,
ED_AREA_MAGIC_BALL_CONTENT_XOFF(4), ED_AREA_MAGIC_BALL_CONTENT_YOFF(4),
GADGET_ID_MAGIC_BALL_CONTENT_4, GADGET_ID_NONE,
NULL, NULL, NULL, "5", NULL
},
{
+ ED_DRAWING_ID_MAGIC_BALL_CONTENT_5,
ED_AREA_MAGIC_BALL_CONTENT_XPOS, ED_AREA_MAGIC_BALL_CONTENT_YPOS,
ED_AREA_MAGIC_BALL_CONTENT_XOFF(5), ED_AREA_MAGIC_BALL_CONTENT_YOFF(5),
GADGET_ID_MAGIC_BALL_CONTENT_5, GADGET_ID_NONE,
NULL, NULL, NULL, "6", NULL
},
{
+ ED_DRAWING_ID_MAGIC_BALL_CONTENT_6,
ED_AREA_MAGIC_BALL_CONTENT_XPOS, ED_AREA_MAGIC_BALL_CONTENT_YPOS,
ED_AREA_MAGIC_BALL_CONTENT_XOFF(6), ED_AREA_MAGIC_BALL_CONTENT_YOFF(6),
GADGET_ID_MAGIC_BALL_CONTENT_6, GADGET_ID_NONE,
NULL, NULL, NULL, "7", NULL
},
{
+ ED_DRAWING_ID_MAGIC_BALL_CONTENT_7,
ED_AREA_MAGIC_BALL_CONTENT_XPOS, ED_AREA_MAGIC_BALL_CONTENT_YPOS,
ED_AREA_MAGIC_BALL_CONTENT_XOFF(7), ED_AREA_MAGIC_BALL_CONTENT_YOFF(7),
GADGET_ID_MAGIC_BALL_CONTENT_7, GADGET_ID_NONE,
// ---------- android content -----------------------------------------------
{
+ ED_DRAWING_ID_ANDROID_CONTENT,
ED_AREA_1X1_SETTINGS_XPOS(0), ED_AREA_1X1_SETTINGS_YPOS(6),
ED_AREA_1X1_SETTINGS_XOFF, ED_AREA_1X1_SETTINGS_YOFF,
GADGET_ID_ANDROID_CONTENT, GADGET_ID_NONE,
// ---------- amoeba content ------------------------------------------------
{
+ ED_DRAWING_ID_AMOEBA_CONTENT,
ED_AREA_1X1_SETTINGS_XPOS(0), ED_AREA_1X1_SETTINGS_YPOS(3),
ED_AREA_1X1_SETTINGS_XOFF, ED_AREA_1X1_SETTINGS_YOFF,
GADGET_ID_AMOEBA_CONTENT, GADGET_ID_NONE,
// ---------- level start element -------------------------------------------
{
+ ED_DRAWING_ID_START_ELEMENT,
-1, ED_AREA_1X1_SETTINGS_YPOS(10),
0, ED_AREA_1X1_SETTINGS_YOFF,
GADGET_ID_START_ELEMENT, GADGET_ID_USE_START_ELEMENT,
// ---------- player artwork element ----------------------------------------
{
+ ED_DRAWING_ID_ARTWORK_ELEMENT,
-1, ED_AREA_1X1_SETTINGS_YPOS(11),
0, ED_AREA_1X1_SETTINGS_YOFF,
GADGET_ID_ARTWORK_ELEMENT, GADGET_ID_USE_ARTWORK_ELEMENT,
// ---------- player explosion element --------------------------------------
{
+ ED_DRAWING_ID_EXPLOSION_ELEMENT,
-1, ED_AREA_1X1_SETTINGS_YPOS(12),
0, ED_AREA_1X1_SETTINGS_YOFF,
GADGET_ID_EXPLOSION_ELEMENT, GADGET_ID_USE_EXPLOSION_ELEMENT,
// ---------- player initial inventory --------------------------------------
{
+ ED_DRAWING_ID_INVENTORY_CONTENT,
-1, ED_AREA_1X1_SETTINGS_YPOS(1),
0, ED_AREA_1X1_SETTINGS_YOFF,
GADGET_ID_INVENTORY_CONTENT, GADGET_ID_USE_INITIAL_INVENTORY,
// ---------- gray ball content -----------------------------------------
{
+ ED_DRAWING_ID_MM_BALL_CONTENT,
ED_AREA_1X1_SETTINGS_XPOS(0), ED_AREA_1X1_SETTINGS_YPOS(2),
ED_AREA_1X1_SETTINGS_XOFF, ED_AREA_1X1_SETTINGS_YOFF,
GADGET_ID_MM_BALL_CONTENT, GADGET_ID_NONE,
// ---------- custom graphic ------------------------------------------------
{
+ ED_DRAWING_ID_CUSTOM_GRAPHIC,
-1, ED_AREA_1X1_SETTINGS_YPOS(1),
0, ED_AREA_1X1_SETTINGS_YOFF,
GADGET_ID_CUSTOM_GRAPHIC, GADGET_ID_CUSTOM_USE_GRAPHIC,
// ---------- custom content (when exploding) -------------------------------
{
+ ED_DRAWING_ID_CUSTOM_CONTENT,
-1, ED_AREA_3X3_SETTINGS_YPOS(11),
0, ED_AREA_3X3_SETTINGS_YOFF,
GADGET_ID_CUSTOM_CONTENT, GADGET_ID_NONE, // align three rows
// ---------- custom enter and leave element (when moving) ------------------
{
+ ED_DRAWING_ID_CUSTOM_MOVE_ENTER,
ED_AREA_1X1_SETTINGS_XPOS(1), ED_AREA_1X1_SETTINGS_YPOS(3),
ED_AREA_1X1_SETTINGS_XOFF, ED_AREA_1X1_SETTINGS_YOFF,
GADGET_ID_CUSTOM_MOVE_ENTER, GADGET_ID_NONE,
"can dig:", " ", NULL, NULL, "element that can be digged/collected"
},
{
+ ED_DRAWING_ID_CUSTOM_MOVE_LEAVE,
-1, ED_AREA_1X1_SETTINGS_YPOS(3),
0, ED_AREA_1X1_SETTINGS_YOFF,
GADGET_ID_CUSTOM_MOVE_LEAVE, GADGET_ID_CUSTOM_MOVE_LEAVE_TYPE,
// ---------- custom change target ------------------------------------------
{
+ ED_DRAWING_ID_CUSTOM_CHANGE_TARGET,
-1, ED_AREA_1X1_SETTINGS_YPOS(1),
0, ED_AREA_1X1_SETTINGS_YOFF,
GADGET_ID_CUSTOM_CHANGE_TARGET, GADGET_ID_CUSTOM_CAN_CHANGE,
// ---------- custom change content (extended change target) ----------------
{
+ ED_DRAWING_ID_CUSTOM_CHANGE_CONTENT,
-1, ED_AREA_3X3_SETTINGS_YPOS(9),
0, ED_AREA_3X3_SETTINGS_YOFF,
GADGET_ID_CUSTOM_CHANGE_CONTENT, GADGET_ID_NONE, // align three rows
// ---------- custom change trigger (element causing change) ----------------
{
+ ED_DRAWING_ID_CUSTOM_CHANGE_TRIGGER,
-1, ED_AREA_1X1_SETTINGS_YPOS(5),
0, ED_AREA_1X1_SETTINGS_YOFF,
GADGET_ID_CUSTOM_CHANGE_TRIGGER, GADGET_ID_CHANGE_OTHER_ACTION,
// ---------- custom change action (element used for action) ----------------
{
+ ED_DRAWING_ID_CUSTOM_CHANGE_ACTION,
-1, ED_AREA_1X1_SETTINGS_YPOS(13),
0, ED_AREA_1X1_SETTINGS_YOFF,
GADGET_ID_CUSTOM_CHANGE_ACTION, GADGET_ID_ACTION_ARG,
// ---------- group element content -----------------------------------------
{
+ ED_DRAWING_ID_GROUP_CONTENT,
ED_AREA_1X1_SETTINGS_XPOS(0), ED_AREA_1X1_SETTINGS_YPOS(2),
ED_AREA_1X1_SETTINGS_XOFF, ED_AREA_1X1_SETTINGS_YOFF,
GADGET_ID_GROUP_CONTENT, GADGET_ID_NONE,
// ---------- random background (for random painting) -----------------------
{
+ ED_DRAWING_ID_RANDOM_BACKGROUND,
-1, ED_AREA_1X1_LSETTINGS_YPOS(1),
0, ED_AREA_1X1_LSETTINGS_YOFF,
GADGET_ID_RANDOM_BACKGROUND, GADGET_ID_RANDOM_RESTRICTED,
// create toolbox buttons
for (i = 0; i < ED_NUM_CTRL_BUTTONS; i++)
{
+ int type_id = controlbutton_info[i].gadget_id; // same as gadget ID here
int id = controlbutton_info[i].gadget_id;
int type = controlbutton_info[i].gadget_type;
int graphic = controlbutton_info[i].graphic;
int radio_button_nr = RADIO_NR_NONE;
boolean checked = FALSE;
+ if (type_id != i)
+ Fail("'controlbutton_info' structure corrupted at index %d -- please fix", i);
+
if (type == GD_TYPE_RADIO_BUTTON)
{
event_mask = GD_EVENT_PRESSED;
}
gi = CreateGadget(GDI_CUSTOM_ID, id,
- GDI_CUSTOM_TYPE_ID, i,
+ GDI_CUSTOM_TYPE_ID, type_id,
GDI_IMAGE_ID, graphic,
GDI_INFO_TEXT, controlbutton_info[i].infotext,
GDI_X, x,
for (i = 0; i < ED_NUM_SCROLLBUTTONS; i++)
{
int id = scrollbutton_info[i].gadget_id;
+ int type_id = scrollbutton_info[i].gadget_type_id;
int graphic = scrollbutton_info[i].graphic;
struct GraphicInfo *gd = &graphic_info[graphic];
Bitmap *gd_bitmap = gd->bitmap;
int y = scrollbutton_pos[i].y;
unsigned int event_mask = GD_EVENT_PRESSED | GD_EVENT_REPEATED;
+ if (type_id != i)
+ Fail("'scrollbutton_info' structure corrupted at index %d -- please fix", i);
+
if (id == GADGET_ID_SCROLL_LIST_UP ||
id == GADGET_ID_SCROLL_LIST_DOWN)
{
}
gi = CreateGadget(GDI_CUSTOM_ID, id,
- GDI_CUSTOM_TYPE_ID, i,
+ GDI_CUSTOM_TYPE_ID, type_id,
GDI_IMAGE_ID, graphic,
GDI_INFO_TEXT, scrollbutton_info[i].infotext,
GDI_X, x,
// create buttons for element list
for (i = 0; i < ED_NUM_ELEMENTLIST_BUTTONS; i++)
{
+ int type_id = i;
int id = GADGET_ID_ELEMENTLIST_FIRST + i;
int graphic = IMG_EDITOR_PALETTE_BUTTON;
struct GraphicInfo *gd = &graphic_info[graphic];
deco_ypos = (gd->height - tile_size) / 2;
gi = CreateGadget(GDI_CUSTOM_ID, id,
- GDI_CUSTOM_TYPE_ID, i,
+ GDI_CUSTOM_TYPE_ID, type_id,
GDI_IMAGE_ID, graphic,
GDI_INFO_TEXT, getElementInfoText(element),
GDI_X, x,
for (i = 0; i < ED_NUM_COUNTERBUTTONS; i++)
{
- int j;
+ int type_id = counterbutton_info[i].gadget_type_id;
int x = SX + ED_SETTINGS_X(counterbutton_info[i].x); // down count button
int y = SY + ED_SETTINGS_Y(counterbutton_info[i].y);
+ int j;
+
+ if (type_id != i)
+ Fail("'counterbutton_info' structure corrupted at index %d -- please fix", i);
// determine horizontal position to the right of specified gadget
if (counterbutton_info[i].gadget_id_align != GADGET_ID_NONE)
(j == 0 ? "decrease" : "increase"));
gi = CreateGadget(GDI_CUSTOM_ID, id,
- GDI_CUSTOM_TYPE_ID, i,
+ GDI_CUSTOM_TYPE_ID, type_id,
GDI_IMAGE_ID, graphic,
GDI_INFO_TEXT, infotext,
GDI_X, x,
gd_y2 = gd->src_y + gd->active_yoffset;
gi = CreateGadget(GDI_CUSTOM_ID, id,
- GDI_CUSTOM_TYPE_ID, i,
+ GDI_CUSTOM_TYPE_ID, type_id,
GDI_IMAGE_ID, graphic,
GDI_INFO_TEXT, "enter counter value",
GDI_X, x,
{
struct GadgetInfo *gi;
int id = drawingarea_info[i].gadget_id;
+ int type_id = drawingarea_info[i].gadget_type_id;
int x = SX + ED_AREA_SETTINGS_X(drawingarea_info[i]);
int y = SY + ED_AREA_SETTINGS_Y(drawingarea_info[i]);
int area_xsize = drawingarea_info[i].area_xsize;
GD_EVENT_PRESSED | GD_EVENT_RELEASED | GD_EVENT_MOVING |
GD_EVENT_OFF_BORDERS | GD_EVENT_PIXEL_PRECISE;
+ if (type_id != i)
+ Fail("'drawingarea_info' structure corrupted at index %d -- please fix", i);
+
// determine horizontal position to the right of specified gadget
if (drawingarea_info[i].gadget_id_align != GADGET_ID_NONE)
x = (right_gadget_border[drawingarea_info[i].gadget_id_align] +
x += getTextWidthForDrawingArea(drawingarea_info[i].text_left);
gi = CreateGadget(GDI_CUSTOM_ID, id,
- GDI_CUSTOM_TYPE_ID, i,
+ GDI_CUSTOM_TYPE_ID, type_id,
GDI_X, x,
GDI_Y, y,
GDI_TYPE, GD_TYPE_DRAWING_AREA,
unsigned int event_mask = GD_EVENT_TEXT_RETURN | GD_EVENT_TEXT_LEAVING;
char infotext[MAX_OUTPUT_LINESIZE + 1];
int id = textinput_info[i].gadget_id;
+ int type_id = textinput_info[i].gadget_type_id;
int x, y;
+ if (type_id != i)
+ Fail("'textinput_info' structure corrupted at index %d -- please fix", i);
+
if (i == ED_TEXTINPUT_ID_ELEMENT_NAME)
{
int element_border = graphic_info[IMG_EDITOR_ELEMENT_BORDER].border_size;
infotext[max_infotext_len] = '\0';
gi = CreateGadget(GDI_CUSTOM_ID, id,
- GDI_CUSTOM_TYPE_ID, i,
+ GDI_CUSTOM_TYPE_ID, type_id,
GDI_INFO_TEXT, infotext,
GDI_X, SX + x,
GDI_Y, SY + y,
unsigned int event_mask = GD_EVENT_TEXT_LEAVING;
char infotext[MAX_OUTPUT_LINESIZE + 1];
int id = textarea_info[i].gadget_id;
+ int type_id = textarea_info[i].gadget_type_id;
int area_xsize = textarea_info[i].xsize;
int area_ysize = textarea_info[i].ysize;
+ if (type_id != i)
+ Fail("'textarea_info' structure corrupted at index %d -- please fix", i);
+
sprintf(infotext, "Enter %s", textarea_info[i].infotext);
infotext[max_infotext_len] = '\0';
gi = CreateGadget(GDI_CUSTOM_ID, id,
- GDI_CUSTOM_TYPE_ID, i,
+ GDI_CUSTOM_TYPE_ID, type_id,
GDI_INFO_TEXT, infotext,
GDI_X, SX + ED_SETTINGS_X(textarea_info[i].x),
GDI_Y, SY + ED_SETTINGS_Y(textarea_info[i].y),
struct GadgetInfo *gi;
char infotext[MAX_OUTPUT_LINESIZE + 1];
int id = selectbox_info[i].gadget_id;
+ int type_id = selectbox_info[i].gadget_type_id;
int x = SX + ED_SETTINGS_X(selectbox_info[i].x);
int y = SY + ED_SETTINGS_Y(selectbox_info[i].y);
unsigned int event_mask =
GD_EVENT_RELEASED | GD_EVENT_TEXT_RETURN | GD_EVENT_TEXT_LEAVING;
+ if (type_id != i)
+ Fail("'selectbox_info' structure corrupted at index %d -- please fix", i);
+
if (selectbox_info[i].size == -1) // dynamically determine size
{
// (we cannot use -1 for uninitialized values if we directly compare
infotext[max_infotext_len] = '\0';
gi = CreateGadget(GDI_CUSTOM_ID, id,
- GDI_CUSTOM_TYPE_ID, i,
+ GDI_CUSTOM_TYPE_ID, type_id,
GDI_INFO_TEXT, infotext,
GDI_X, x,
GDI_Y, y,
for (i = 0; i < ED_NUM_TEXTBUTTONS; i++)
{
int id = textbutton_info[i].gadget_id;
+ int type_id = textbutton_info[i].gadget_type_id;
int is_tab_button =
((id >= GADGET_ID_LEVELCONFIG_LEVEL && id <= GADGET_ID_LEVELCONFIG_EDITOR) ||
(id >= GADGET_ID_PROPERTIES_INFO && id <= GADGET_ID_PROPERTIES_CHANGE));
int x = SX + ED_SETTINGS_X(textbutton_info[i].x);
int y = SY + ED_SETTINGS_Y(textbutton_info[i].y);
+ if (type_id != i)
+ Fail("'textbutton_info' structure corrupted at index %d -- please fix", i);
+
if (textbutton_info[i].size == -1) // dynamically determine size
textbutton_info[i].size = strlen(textbutton_info[i].text);
x += getTextWidthForGadget(textbutton_info[i].text_left);
gi = CreateGadget(GDI_CUSTOM_ID, id,
- GDI_CUSTOM_TYPE_ID, i,
+ GDI_CUSTOM_TYPE_ID, type_id,
GDI_IMAGE_ID, graphic,
GDI_INFO_TEXT, infotext,
GDI_X, x,
for (i = 0; i < ED_NUM_GRAPHICBUTTONS; i++)
{
int id = graphicbutton_info[i].gadget_id;
+ int type_id = graphicbutton_info[i].gadget_type_id;
int x = SX + ED_SETTINGS_X(graphicbutton_info[i].x);
int y = SY + ED_SETTINGS_Y(graphicbutton_info[i].y);
int graphic = graphicbutton_info[i].graphic;
int gd_y2 = gd->src_y + gd->pressed_yoffset;
unsigned int event_mask = GD_EVENT_RELEASED;
+ if (type_id != i)
+ Fail("'graphicbutton_info' structure corrupted at index %d -- please fix", i);
+
// determine horizontal position to the right of specified gadget
if (graphicbutton_info[i].gadget_id_align != GADGET_ID_NONE)
x = (right_gadget_border[graphicbutton_info[i].gadget_id_align] +
x += getTextWidthForGadget(graphicbutton_info[i].text_left);
gi = CreateGadget(GDI_CUSTOM_ID, id,
- GDI_CUSTOM_TYPE_ID, i,
+ GDI_CUSTOM_TYPE_ID, type_id,
GDI_IMAGE_ID, graphic,
GDI_INFO_TEXT, graphicbutton_info[i].infotext,
GDI_X, x,
for (i = 0; i < ED_NUM_SCROLLBARS; i++)
{
int id = scrollbar_info[i].gadget_id;
+ int type_id = scrollbar_info[i].gadget_type_id;
int graphic = scrollbar_info[i].graphic;
struct GraphicInfo *gd = &graphic_info[graphic];
int gd_x1 = gd->src_x;
int items_max, items_visible, item_position;
unsigned int event_mask = GD_EVENT_MOVING | GD_EVENT_OFF_BORDERS;
+ if (type_id != i)
+ Fail("'scrollbar_info' structure corrupted at index %d -- please fix", i);
+
if (i == ED_SCROLLBAR_ID_LIST_VERTICAL)
{
items_max = num_editor_elements / ED_ELEMENTLIST_BUTTONS_HORIZ;
}
gi = CreateGadget(GDI_CUSTOM_ID, id,
- GDI_CUSTOM_TYPE_ID, i,
+ GDI_CUSTOM_TYPE_ID, type_id,
GDI_IMAGE_ID, graphic,
GDI_INFO_TEXT, scrollbar_info[i].infotext,
GDI_X, scrollbar_pos[i].x,
for (i = 0; i < ED_NUM_CHECKBUTTONS; i++)
{
int id = checkbutton_info[i].gadget_id;
+ int type_id = checkbutton_info[i].gadget_type_id;
int graphic = (id == GADGET_ID_STICK_ELEMENT ? IMG_EDITOR_STICKYBUTTON :
IMG_EDITOR_CHECKBOX);
struct GraphicInfo *gd = &graphic_info[graphic];
int y = SY + ED_SETTINGS_Y(checkbutton_info[i].y);
unsigned int event_mask = GD_EVENT_PRESSED;
+ if (type_id != i)
+ Fail("'checkbutton_info' structure corrupted at index %d -- please fix", i);
+
// determine horizontal position to the right of specified gadget
if (checkbutton_info[i].gadget_id_align != GADGET_ID_NONE)
x = (right_gadget_border[checkbutton_info[i].gadget_id_align] +
x += getTextWidthForGadget(checkbutton_info[i].text_left);
gi = CreateGadget(GDI_CUSTOM_ID, id,
- GDI_CUSTOM_TYPE_ID, i,
+ GDI_CUSTOM_TYPE_ID, type_id,
GDI_IMAGE_ID, graphic,
GDI_INFO_TEXT, checkbutton_info[i].infotext,
GDI_X, x,
for (i = 0; i < ED_NUM_RADIOBUTTONS; i++)
{
int id = radiobutton_info[i].gadget_id;
+ int type_id = radiobutton_info[i].gadget_type_id;
int x = SX + ED_SETTINGS_X(radiobutton_info[i].x);
int y = SY + ED_SETTINGS_Y(radiobutton_info[i].y);
unsigned int event_mask = GD_EVENT_PRESSED;
+ if (type_id != i)
+ Fail("'radiobutton_info' structure corrupted at index %d -- please fix", i);
+
int checked =
(*radiobutton_info[i].value == radiobutton_info[i].checked_value);
x += getTextWidthForGadget(radiobutton_info[i].text_left);
gi = CreateGadget(GDI_CUSTOM_ID, id,
- GDI_CUSTOM_TYPE_ID, i,
+ GDI_CUSTOM_TYPE_ID, type_id,
GDI_IMAGE_ID, graphic,
GDI_INFO_TEXT, radiobutton_info[i].infotext,
GDI_X, x,