summaryrefslogtreecommitdiff
path: root/src/i_endoom.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/i_endoom.c')
-rw-r--r--src/i_endoom.c17
1 files changed, 15 insertions, 2 deletions
diff --git a/src/i_endoom.c b/src/i_endoom.c
index 08cfb99e..a05d1662 100644
--- a/src/i_endoom.c
+++ b/src/i_endoom.c
@@ -30,6 +30,9 @@
#include "txt_main.h"
+#define ENDOOM_W 80
+#define ENDOOM_H 25
+
//
// Displays the text mode ending screen after the game quits
//
@@ -37,15 +40,25 @@
void I_Endoom(byte *endoom_data)
{
unsigned char *screendata;
+ int y;
+ int indent;
// Set up text mode screen
TXT_Init();
// Write the data to the screen memory
-
+
screendata = TXT_GetScreenData();
- memcpy(screendata, endoom_data, 4000);
+
+ indent = (ENDOOM_W - TXT_SCREEN_W) / 2;
+
+ for (y=0; y<TXT_SCREEN_H; ++y)
+ {
+ memcpy(screendata + (y * TXT_SCREEN_W * 2),
+ endoom_data + (y * ENDOOM_W + indent) * 2,
+ TXT_SCREEN_W * 2);
+ }
// Wait for a keypress