[Scummvm-git-logs] scummvm master -> 924c1bc43743c373ef11c494360c5d00029087d3
dreammaster
noreply at scummvm.org
Fri Apr 24 02:12:21 UTC 2026
This automated email contains information about 2 new commits which have been
pushed to the 'scummvm' repo located at https://api.github.com/repos/scummvm/scummvm .
Summary:
f79dbd7be0 MADS: PHANTOM: Warning fixes
924c1bc437 MADS: PHANTOM: More warning fixes
Commit: f79dbd7be04d72d932b02c2088703deeb0821c72
https://github.com/scummvm/scummvm/commit/f79dbd7be04d72d932b02c2088703deeb0821c72
Author: Paul Gilbert (dreammaster at scummvm.org)
Date: 2026-04-24T12:01:53+10:00
Commit Message:
MADS: PHANTOM: Warning fixes
Changed paths:
engines/mads/madsv2/core/dialog.cpp
engines/mads/madsv2/core/env.cpp
engines/mads/madsv2/core/game.cpp
engines/mads/madsv2/core/game.h
engines/mads/madsv2/core/popup.cpp
diff --git a/engines/mads/madsv2/core/dialog.cpp b/engines/mads/madsv2/core/dialog.cpp
index 8e8c26abb74..14a5459b686 100644
--- a/engines/mads/madsv2/core/dialog.cpp
+++ b/engines/mads/madsv2/core/dialog.cpp
@@ -96,14 +96,6 @@ static char say_dialog_work[SAY_DIALOG_SIZE];
#define abort_option 0x02
#define fail_option 0x03
-Dialog crit_dialog;
-char crit_work[256];
-
-extern void dialog_24_server(void);
-
-static int dialog_server_installed = false;
-static dword dialog_old_24_server;
-
int dialog_read_dir_to_list(ListPtr target, const char *wild, int dirflag) {
warning("TODO: dialog_read_dir_to_list");
@@ -1209,13 +1201,17 @@ static void dialog_update_window(DialogPtr dialog, ItemPtr item) {
} else {
my_color = dialog->select_color;
}
- *screenptr++;
+
+ screenptr++;
+
if (*screenptr != (char)dialog->select_color) {
*(screenptr++) = (char)my_color;
} else {
screenptr++;
}
+
out_count = 0;
+
if (id < list->elements) {
while ((out_count < list->entry_width) && (*textptr != 0)) {
*(screenptr++) = *(textptr++);
@@ -1228,7 +1224,9 @@ static void dialog_update_window(DialogPtr dialog, ItemPtr item) {
*(screenptr++) = (char)my_color;
out_count++;
}
- *screenptr++;
+
+ screenptr++;
+
if (*screenptr != (char)dialog->select_color) {
*(screenptr++) = (char)my_color;
}
@@ -3705,16 +3703,10 @@ int dialog_get_number(DialogPtr dialog, ItemPtr item) {
return atoi(buf);
}
-static void dialog_critical_error_handler() {
- // No implementation in ScummVM
-}
-
void dialog_trap_critical() {
- dialog_server_installed = true;
}
void dialog_restore_critical(void) {
- dialog_server_installed = false;
}
} // namespace MADSV2
diff --git a/engines/mads/madsv2/core/env.cpp b/engines/mads/madsv2/core/env.cpp
index f044f3a8876..a96aa89f01a 100644
--- a/engines/mads/madsv2/core/env.cpp
+++ b/engines/mads/madsv2/core/env.cpp
@@ -738,22 +738,5 @@ done:
return error_flag;
}
-char *env_level_path(char *string, int first_level, int second_level) {
- int env_mode;
- int env_sect;
- int env_room = 0;
-
- if (second_level >= 0) {
- env_mode = ROOM;
- env_sect = first_level;
- env_room = second_level;
- } else {
- env_mode = SECTION;
- env_sect = first_level;
- }
-
- return env_fill_path(string, env_mode, env_room);
-}
-
} // namespace MADSV2
} // namespace MADS
diff --git a/engines/mads/madsv2/core/game.cpp b/engines/mads/madsv2/core/game.cpp
index 40fcd98594d..a946aa0a545 100644
--- a/engines/mads/madsv2/core/game.cpp
+++ b/engines/mads/madsv2/core/game.cpp
@@ -457,36 +457,6 @@ void problem() {
debug("\nA slight problem . . .\n\n");
}
-static void show_walk() {
- int y, x;
- int xx, yy;
- int ox, oy;
- byte *scan;
- int walk;
-
- for (y = 0; y < display_y; y++) {
- ox = picture_map.pan_base_x;
- oy = y + picture_map.pan_base_y;
- scan = buffer_pointer(&scr_orig, ox, oy);
- for (x = 0; x < video_x; x++) {
- xx = x + picture_view_x;
- yy = y + picture_view_y;
- walk = attr_walk(&scr_walk, xx, yy);
-
- if (walk) {
- *scan = 2;
- } else if (*scan == 2) {
- *scan = 0;
- }
-
- scan++;
- }
- }
-
- matte_refresh_work();
-}
-
-
static void game_fix_save_name() {
char *mark;
@@ -508,34 +478,16 @@ void game_save_name(int id) {
static void game_player_status() {
- int image, flags, count;
char work_buf[80];
char temp_buf_3[80];
- image = -1;
- flags = -9;
- for (count = 0; count < (int)image_marker; count++) {
- if (image_list[count].segment_id == KERNEL_SEGMENT_PLAYER) {
- if (image_list[count].flags >= flags) {
- image = count;
- flags = image_list[count].flags;
- }
- }
- }
Common::strcpy_s(temp_buf_3, "Room: ");
Common::strcat_s(temp_buf_3, mads_itoa(room_id, work_buf, 10));
Common::strcat_s(temp_buf_3, " (From: ");
Common::strcat_s(temp_buf_3, mads_itoa(previous_room, work_buf, 10));
Common::strcat_s(temp_buf_3, ")");
- popup_alert(20, "PLAYER GRAPHICS STATUS",
- " ",
- temp_buf_3,
- // temp_buf,
- // temp_buf_2,
- // temp_buf_4,
- // temp_buf_5,
- NULL);
+ popup_alert(20, "PLAYER GRAPHICS STATUS", " ", temp_buf_3, NULL);
}
@@ -1975,14 +1927,14 @@ static void game_main_loop() {
int temp_message_4 = 0;
long one_clock, two_clock;
static char temp_buf[20];
+
+#if 0
static char temp_buf_2[20];
static char temp_buf_3[20];
static char temp_buf_4[20];
-
-#if 0
- // these 3 are for the background efx
int yy;
long dif;
+
if (global[10]) { // please play the damn targets
// this is for the background sound efx
@@ -2747,7 +2699,6 @@ static void game_conversation() {
int my_status;
char temp_buf[80];
Conv *my_conv;
- ConvData *my_data;
if (conv_control.running != previous_running) {
game_debugger_reset();
@@ -2765,7 +2716,6 @@ static void game_conversation() {
}
my_conv = conv[conv_control.index];
- my_data = conv_data[conv_control.index];
temp_buf[0] = 0;
if (conv_control.status == CONV_STATUS_HOLDING) {
diff --git a/engines/mads/madsv2/core/game.h b/engines/mads/madsv2/core/game.h
index 572f713e912..7e1928ea449 100644
--- a/engines/mads/madsv2/core/game.h
+++ b/engines/mads/madsv2/core/game.h
@@ -137,10 +137,10 @@ enum {
#define GAME_MAX_SAVE_WIDTH 255 /* Max pixel width of save name*/
#define GAME_MAX_SAVES_ON_SCREEN 7 /* Max saves on screen at once */
-#define GAME_SAVE_SLOT_MEMORY (GAME_MAX_SAVE_SLOTS * (GAME_MAX_SAVE_LENGTH + 1))
-#define GAME_DIALOG_HEAP (4096 + sizeof(PopupItem) * GAME_MENU_MAX_ITEMS)
+#define GAME_SAVE_SLOT_MEMORY (long)(GAME_MAX_SAVE_SLOTS * (GAME_MAX_SAVE_LENGTH + 1))
+#define GAME_DIALOG_HEAP (long)(4096 + sizeof(PopupItem) * GAME_MENU_MAX_ITEMS)
#define GAME_FUDGE_FACTOR 256
-#define GAME_MENU_HEAP (GAME_SAVE_SLOT_MEMORY + GAME_DIALOG_HEAP + GAME_FUDGE_FACTOR)
+#define GAME_MENU_HEAP (long)(GAME_SAVE_SLOT_MEMORY + GAME_DIALOG_HEAP + GAME_FUDGE_FACTOR)
#define GAME_MENU_SCROLL_FIRST 20 /* Scrolling delays */
diff --git a/engines/mads/madsv2/core/popup.cpp b/engines/mads/madsv2/core/popup.cpp
index 16c08cbc561..beddf154e05 100644
--- a/engines/mads/madsv2/core/popup.cpp
+++ b/engines/mads/madsv2/core/popup.cpp
@@ -2742,7 +2742,6 @@ static int popup_savelist_mouse(PopupItem *item) {
}
} else {
-
if (in_main_range) {
y = mouse_y - (item->y + 2);
relative = y / list->list_ys;
Commit: 924c1bc43743c373ef11c494360c5d00029087d3
https://github.com/scummvm/scummvm/commit/924c1bc43743c373ef11c494360c5d00029087d3
Author: Paul Gilbert (dreammaster at scummvm.org)
Date: 2026-04-24T12:12:07+10:00
Commit Message:
MADS: PHANTOM: More warning fixes
Changed paths:
engines/mads/madsv2/core/inter.cpp
engines/mads/madsv2/core/kernel.cpp
diff --git a/engines/mads/madsv2/core/inter.cpp b/engines/mads/madsv2/core/inter.cpp
index a8ec0f74344..dd564823288 100644
--- a/engines/mads/madsv2/core/inter.cpp
+++ b/engines/mads/madsv2/core/inter.cpp
@@ -208,10 +208,6 @@ int paul_object_showing = -1;
#define OUAF_OBJECT_Y 5
-void inter_spin_object(int object_id);
-void inter_turn_off_object(void);
-
-
void VerbBuf::synchronize(Common::Serializer &s) {
s.syncAsUint16LE(id);
s.syncAsByte(verb_type);
diff --git a/engines/mads/madsv2/core/kernel.cpp b/engines/mads/madsv2/core/kernel.cpp
index 2c0f2821018..013a698713f 100644
--- a/engines/mads/madsv2/core/kernel.cpp
+++ b/engines/mads/madsv2/core/kernel.cpp
@@ -99,7 +99,7 @@ int kernel_screen_fade = 0;
Animation kernel_anim[KERNEL_MAX_ANIMATIONS];
-ShadowList kernel_shadow_main = { 0 };
+ShadowList kernel_shadow_main = { 0, { 0 } };
ShadowList kernel_shadow_inter = { 1, { 15 } };
int kernel_ok_to_fail_load = false;
@@ -153,8 +153,6 @@ int random_message_duration; /* Duration of messages */
char kernel_interface_loaded[40] = "";
-static char digital_name[12] = "digital.aga";
-
static void kernel_seq_image(SequencePtr sequence, ImagePtr image, int sequence_id);
static void kernel_reconstruct_screen(int anim_handle);
@@ -871,18 +869,6 @@ int kernel_seq_forward(int series_id, int mirror, word ticks, word interval_tick
start_ticks, expire));
}
-int kernel_seq_forward_scroll(int series_id, int mirror, word ticks, word interval_ticks,
- word start_ticks, int expire) {
- int depth = 0;
- SpritePtr sprite;
-
- sprite = &series_list[series_id]->index[0];
-
- return (kernel_seq_add(series_id, mirror, 1, 0, 0, AA_LINEAR, 1,
- depth, 100, true, 0, 0, ticks, interval_ticks,
- start_ticks, expire));
-}
-
int kernel_seq_pingpong(int series_id, int mirror,
word ticks, word interval_ticks,
word start_ticks,
@@ -901,20 +887,6 @@ int kernel_seq_pingpong(int series_id, int mirror,
start_ticks, expire));
}
-int kernel_seq_pingpong_scroll(int series_id, int mirror,
- word ticks, word interval_ticks,
- word start_ticks,
- int expire) {
- int depth = 0;
- SpritePtr sprite;
-
- sprite = &series_list[series_id]->index[0];
-
- return kernel_seq_add(series_id, mirror, 1, 0, 0, AA_PINGPONG, 1,
- depth, 100, true, 0, 0, ticks, interval_ticks,
- start_ticks, expire);
-}
-
int kernel_seq_backward(int series_id, int mirror, word ticks, word interval_ticks,
word start_ticks, int expire) {
int depth;
@@ -1066,17 +1038,6 @@ int kernel_seq_stamp(int series_id, int mirror, int sprite) {
return (id);
}
-int kernel_seq_stamp_scroll(int series_id, int mirror, int sprite) {
- int id;
-
- id = kernel_seq_forward_scroll(series_id, mirror, 32767, 0, 0, 0);
- if (id >= 0) {
- kernel_seq_range(id, sprite, sprite);
- sequence_list[id].loop_direction = AA_STAMP;
- }
- return (id);
-}
-
int kernel_seq_trigger(int sequence_id,
int trigger_type,
int trigger_sprite,
@@ -1447,7 +1408,6 @@ void kernel_animation_init() {
}
int kernel_run_animation(const char *name, int trigger_code) {
- int result = -1;
int found = -1;
int error_flag = true;
int count;
@@ -1526,7 +1486,6 @@ int kernel_run_animation(const char *name, int trigger_code) {
}
error_flag = false;
- result = found;
kernel_anim[found].last_frame = -1;
@@ -1821,7 +1780,7 @@ static void kernel_process_animation(int handle, int asynchronous) {
}
for (count = 0; count < kernel_anim[handle].anim->num_speech; count++) {
- if ((int)(kernel_anim[handle].anim->speech[count].flags) >= 0) {
+ if ((int16)(kernel_anim[handle].anim->speech[count].flags) >= 0) {
if ((kernel_anim[handle].frame < kernel_anim[handle].anim->speech[count].first_frame) ||
(kernel_anim[handle].frame > kernel_anim[handle].anim->speech[count].last_frame)) {
kernel_message_delete(kernel_anim[handle].anim->speech[count].flags);
@@ -1965,7 +1924,7 @@ void kernel_abort_animation(int handle) {
}
for (count = 0; count < kernel_anim[handle].anim->num_speech; count++) {
- if ((int)(kernel_anim[handle].anim->speech[count].flags) >= 0) {
+ if ((int16)(kernel_anim[handle].anim->speech[count].flags) >= 0) {
kernel_message_delete(kernel_anim[handle].anim->speech[count].flags);
}
}
More information about the Scummvm-git-logs
mailing list