Commit 72272502 authored by Steven Fuller's avatar Steven Fuller

Forgot about wl_text...

parent 8e70f4b8
...@@ -6,7 +6,8 @@ CFLAGS = -g -DUSEVGA ...@@ -6,7 +6,8 @@ CFLAGS = -g -DUSEVGA
#CFLAGS = -g -pg -DDEBUG #CFLAGS = -g -pg -DDEBUG
OBJS = objs.o misc.o id_ca.o id_in.o id_sd.o id_vl.o id_vh.o id_us.o \ OBJS = objs.o misc.o id_ca.o id_in.o id_sd.o id_vl.o id_vh.o id_us.o \
wl_scale.o wl_draw.o wl_act1.o wl_act2.o wl_agent.o wl_game.o \ wl_scale.o wl_draw.o wl_act1.o wl_act2.o wl_agent.o wl_game.o \
wl_inter.o wl_menu.o wl_play.o wl_state.o wl_main.o wl_debug.o wl_inter.o wl_menu.o wl_play.o wl_state.o wl_text.o wl_main.o \
wl_debug.o
#LFLAGS = -lm -lvga -pg #LFLAGS = -lm -lvga -pg
LFLAGS = -lm -lvga LFLAGS = -lm -lvga
......
...@@ -89,14 +89,6 @@ typedef byte ScanCode; ...@@ -89,14 +89,6 @@ typedef byte ScanCode;
#define key_Tab 0x09 #define key_Tab 0x09
#define key_Delete 0x7f #define key_Delete 0x7f
// Stuff for the mouse
#define MReset 0
#define MButtons 3
#define MDelta 11
#define MouseInt 0x33
#define Mouse(x) _AX = x,geninterrupt(MouseInt)
typedef enum { typedef enum {
ctrl_Keyboard, ctrl_Keyboard,
ctrl_Joystick, ctrl_Joystick,
......
// WL_TEXT.C /* wl_text.c */
#include "WL_DEF.H" #include "wl_def.h"
#pragma hdrstop
/* /*
============================================================================= =============================================================================
...@@ -351,28 +350,28 @@ void HandleCtrls (void) ...@@ -351,28 +350,28 @@ void HandleCtrls (void)
void HandleWord (void) void HandleWord (void)
{ {
char word[WORDLIMIT]; char words[WORDLIMIT];
int i,wordindex; int i, wordindex;
unsigned wwidth,wheight,newpos; word wwidth,wheight,newpos;
// //
// copy the next word into [word] // copy the next word into words[]
// //
word[0] = *text++; words[0] = *text++;
wordindex = 1; wordindex = 1;
while (*text>32) while (*text>32)
{ {
word[wordindex] = *text++; words[wordindex] = *text++;
if (++wordindex == WORDLIMIT) if (++wordindex == WORDLIMIT)
Quit ("PageLayout: Word limit exceeded"); Quit ("PageLayout: Word limit exceeded");
} }
word[wordindex] = 0; // stick a null at end for C words[wordindex] = 0; // stick a null at end for C
// //
// see if it fits on this line // see if it fits on this line
// //
VW_MeasurePropString (word,&wwidth,&wheight); VW_MeasurePropString (words, &wwidth, &wheight);
while (px+wwidth > rightmargin[rowon]) while (px+wwidth > rightmargin[rowon])
{ {
...@@ -385,7 +384,7 @@ void HandleWord (void) ...@@ -385,7 +384,7 @@ void HandleWord (void)
// print it // print it
// //
newpos = px+wwidth; newpos = px+wwidth;
VWB_DrawPropString (word); VWB_DrawPropString (words);
px = newpos; px = newpos;
// //
...@@ -796,8 +795,6 @@ void EndText (void) ...@@ -796,8 +795,6 @@ void EndText (void)
SETFONTCOLOR(0,15); SETFONTCOLOR(0,15);
IN_ClearKeysDown(); IN_ClearKeysDown();
if (MousePresent)
Mouse(MDelta); // Clear accumulated mouse movement
FreeMusic (); FreeMusic ();
CA_DownLevel (); CA_DownLevel ();
...@@ -816,8 +813,6 @@ void EndText (void) ...@@ -816,8 +813,6 @@ void EndText (void)
VW_FadeOut(); VW_FadeOut();
SETFONTCOLOR(0,15); SETFONTCOLOR(0,15);
IN_ClearKeysDown(); IN_ClearKeysDown();
if (MousePresent)
Mouse(MDelta); // Clear accumulated mouse movement
FreeMusic (); FreeMusic ();
CA_DownLevel (); CA_DownLevel ();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment