This issue was found by using GCC with option "-Wextra".
DrawText(x, y + 2 * tilesize, "active", font_nr);
}
-static void DrawAndroidElementArea(int element)
+static void DrawAndroidElementArea(void)
{
int id = ED_DRAWING_ID_ANDROID_CONTENT;
int num_elements = level.num_android_clone_elements;
MapDrawingArea(id);
}
-static void DrawGroupElementArea(int element)
+static void DrawGroupElementArea(void)
{
int id = ED_DRAWING_ID_GROUP_CONTENT;
int num_elements = group_element_info.num_elements;
MapCheckbuttonGadget(ED_CHECKBUTTON_ID_INITIAL_BALL_ACTIVE);
}
else if (properties_element == EL_EMC_ANDROID)
- DrawAndroidElementArea(properties_element);
+ DrawAndroidElementArea();
}
if (IS_PLAYER_ELEMENT(properties_element))
MapTextbuttonGadget(ED_TEXTBUTTON_ID_SAVE_AS_TEMPLATE_1);
// draw drawing area gadgets
- DrawGroupElementArea(properties_element);
+ DrawGroupElementArea();
// draw text input gadgets
MapTextInputGadget(ED_TEXTINPUT_ID_ELEMENT_NAME);
break;
case ED_COUNTER_ID_ANDROID_CONTENT:
- DrawAndroidElementArea(properties_element);
+ DrawAndroidElementArea();
break;
case ED_COUNTER_ID_GROUP_CONTENT:
- DrawGroupElementArea(properties_element);
+ DrawGroupElementArea();
CopyGroupElementPropertiesToGame(properties_element);
break;
void PlayLevelSound_EM(int, int, int, int);
void InitGraphicInfo_EM(void);
-boolean CheckSingleStepMode_EM(byte[MAX_PLAYERS], int, boolean, boolean, boolean);
+boolean CheckSingleStepMode_EM(int, boolean, boolean, boolean);
void SetGfxAnimation_EM(struct GraphicInfo_EM *, int, int, int, int);
void getGraphicSourceObjectExt_EM(struct GraphicInfo_EM *, int, int, int, int);
void CheckSingleStepMode_SP(boolean, boolean);
-void getGraphicSource_SP(struct GraphicInfo_SP *, int, int, int, int);
+void getGraphicSource_SP(struct GraphicInfo_SP *, int, int);
int getGraphicInfo_Delay(int);
boolean isNextAnimationFrame_SP(int, int);
return getMappedElement(element);
}
-static void LoadLevelFromFileStream_DC(File *file, struct LevelInfo *level,
- int nr)
+static void LoadLevelFromFileStream_DC(File *file, struct LevelInfo *level)
{
byte header[DC_LEVEL_HEADER_SIZE];
int envelope_size;
}
}
- LoadLevelFromFileStream_DC(file, level, level_file_info->nr);
+ LoadLevelFromFileStream_DC(file, level);
closeFile(file);
}
*sy = (sy1 + sy2) / 2;
}
-static void DrawRelocateScreen(int old_x, int old_y, int x, int y, int move_dir,
+static void DrawRelocateScreen(int old_x, int old_y, int x, int y,
boolean center_screen, boolean quick_relocation)
{
unsigned int frame_delay_value_old = GetVideoFrameDelay();
}
// only visually relocate centered player
- DrawRelocateScreen(old_jx, old_jy, player->jx, player->jy, player->MovDir,
+ DrawRelocateScreen(old_jx, old_jy, player->jx, player->jy,
FALSE, level.instant_relocation);
TestIfPlayerTouchesBadThing(jx, jy);
}
}
-static void ToggleSwitchgateSwitch(int x, int y)
+static void ToggleSwitchgateSwitch(void)
{
int xx, yy;
smashed == EL_DC_SWITCHGATE_SWITCH_UP ||
smashed == EL_DC_SWITCHGATE_SWITCH_DOWN)
{
- ToggleSwitchgateSwitch(x, y + 1);
+ ToggleSwitchgateSwitch();
}
else if (smashed == EL_LIGHT_SWITCH ||
smashed == EL_LIGHT_SWITCH_ACTIVE)
game.centered_player_nr = game.centered_player_nr_next;
game.set_centered_player = FALSE;
- DrawRelocateScreen(0, 0, sx, sy, MV_NONE, TRUE, setup.quick_switch);
+ DrawRelocateScreen(0, 0, sx, sy, TRUE, setup.quick_switch);
DrawGameDoorValues();
}
element == EL_DC_SWITCHGATE_SWITCH_UP ||
element == EL_DC_SWITCHGATE_SWITCH_DOWN)
{
- ToggleSwitchgateSwitch(x, y);
+ ToggleSwitchgateSwitch();
}
else if (element == EL_LIGHT_SWITCH ||
element == EL_LIGHT_SWITCH_ACTIVE)
if (level.game_engine_type == GAME_ENGINE_TYPE_SP)
SaveEngineSnapshotValues_SP(&buffers);
if (level.game_engine_type == GAME_ENGINE_TYPE_MM)
- SaveEngineSnapshotValues_MM(&buffers);
+ SaveEngineSnapshotValues_MM();
// save values stored in special snapshot structure
any_player_dropping = TRUE;
boolean single_step_mode_paused =
- CheckSingleStepMode_EM(action, frame, game_em.any_player_moving,
+ CheckSingleStepMode_EM(frame, game_em.any_player_moving,
game_em.any_player_snapping, any_player_dropping);
// draw wrapping around before going to single step pause mode
void RedrawPlayfield_MM(void);
void LoadEngineSnapshotValues_MM(void);
-void SaveEngineSnapshotValues_MM(ListNode **);
+void SaveEngineSnapshotValues_MM(void);
int getButtonFromTouchPosition(int, int, int, int);
}
}
-static void InitField(int x, int y, boolean init_game)
+static void InitField(int x, int y)
{
int element = Tile[x][y];
Frame[x][y] = 0;
Stop[x][y] = FALSE;
- InitField(x, y, TRUE);
+ InitField(x, y);
}
}
if (element == EL_EMPTY)
{
- if (!HitOnlyAnEdge(element, hit_mask))
+ if (!HitOnlyAnEdge(hit_mask))
break;
}
else if (element == EL_FUSE_ON)
boolean HitElement(int element, int hit_mask)
{
- if (HitOnlyAnEdge(element, hit_mask))
+ if (HitOnlyAnEdge(hit_mask))
return FALSE;
if (IS_MOVING(ELX, ELY) || IS_BLOCKED(ELX, ELY))
return TRUE;
}
-boolean HitOnlyAnEdge(int element, int hit_mask)
+boolean HitOnlyAnEdge(int hit_mask)
{
// check if the laser hit only the edge of an element and, if so, go on
boolean HitPolarizer(int element, int hit_mask)
{
- if (HitOnlyAnEdge(element, hit_mask))
+ if (HitOnlyAnEdge(hit_mask))
return FALSE;
if (IS_DF_GRID(element))
boolean HitLaserSource(int element, int hit_mask)
{
- if (HitOnlyAnEdge(element, hit_mask))
+ if (HitOnlyAnEdge(hit_mask))
return FALSE;
PlayLevelSound_MM(ELX, ELY, element, MM_ACTION_HITTING);
boolean HitLaserDestination(int element, int hit_mask)
{
- if (HitOnlyAnEdge(element, hit_mask))
+ if (HitOnlyAnEdge(hit_mask))
return FALSE;
if (element != EL_EXIT_OPEN &&
}
}
- if (!HitOnlyAnEdge(element, hit_mask))
+ if (!HitOnlyAnEdge(hit_mask))
{
laser.overloaded = TRUE;
boolean HitAbsorbingWalls(int element, int hit_mask)
{
- if (HitOnlyAnEdge(element, hit_mask))
+ if (HitOnlyAnEdge(hit_mask))
return FALSE;
if (ABS(XS) == 4 &&
Store[x][y] = Store2[x][y] = 0;
MovDir[x][y] = MovPos[x][y] = MovDelay[x][y] = 0;
- InitField(x, y, FALSE);
+ InitField(x, y);
DrawField_MM(x, y);
}
else if (!(phase % delay) && IN_SCR_FIELD(SCREENX(x), SCREENY(y)))
}
}
-static void GameActions_MM_Ext(struct MouseActionInfo action)
+static void GameActions_MM_Ext(void)
{
int element;
int x, y, i;
boolean element_clicked = ClickElement(action.lx, action.ly, action.button);
boolean button_released = (action.button == MB_RELEASED);
- GameActions_MM_Ext(action);
+ GameActions_MM_Ext();
CheckSingleStepMode_MM(element_clicked, button_released);
}
// Mirror Magic game engine snapshot handling functions
// ----------------------------------------------------------------------------
-void SaveEngineSnapshotValues_MM(ListNode **buffers)
+void SaveEngineSnapshotValues_MM(void)
{
int x, y;
void ScanLaser(void);
void DrawLaser(int, int);
boolean HitElement(int, int);
-boolean HitOnlyAnEdge(int, int);
+boolean HitOnlyAnEdge(int);
boolean HitPolarizer(int, int);
boolean HitBlock(int, int);
boolean HitLaserSource(int, int);
if (graphic < 0)
return;
- getGraphicSource_SP(&g, graphic, sync_frame, -1, -1);
+ getGraphicSource_SP(&g, graphic, sync_frame);
Blt(pX, pY, g.bitmap, g.src_x, g.src_y);
}
}
}
-static void CheckSaveEngineSnapshot_EM(byte action[MAX_PLAYERS], int frame,
+static void CheckSaveEngineSnapshot_EM(int frame,
boolean any_player_moving,
boolean any_player_snapping,
boolean any_player_dropping)
}
}
-boolean CheckSingleStepMode_EM(byte action[MAX_PLAYERS], int frame,
+boolean CheckSingleStepMode_EM(int frame,
boolean any_player_moving,
boolean any_player_snapping,
boolean any_player_dropping)
if (frame == 7 && !any_player_dropping && FrameCounter > 6)
TapeTogglePause(TAPE_TOGGLE_AUTOMATIC);
- CheckSaveEngineSnapshot_EM(action, frame, any_player_moving,
+ CheckSaveEngineSnapshot_EM(frame, any_player_moving,
any_player_snapping, any_player_dropping);
return tape.pausing;
}
void getGraphicSource_SP(struct GraphicInfo_SP *g_sp,
- int graphic, int sync_frame, int x, int y)
+ int graphic, int sync_frame)
{
int frame = getGraphicAnimationFrame(graphic, sync_frame);