diff --git a/map_edit/m1.c b/map_edit/m1.c index 1f78c25..76a8a13 100644 --- a/map_edit/m1.c +++ b/map_edit/m1.c @@ -7,17 +7,14 @@ #include #include #include -#include #include #include -#include #include -#include -#include #include #include "ack3d.h" #include "ackeng.h" #include "m1.h" +#include "mapedit.h" extern UCHAR colordat[]; extern char *smFont; @@ -2611,7 +2608,7 @@ while (!done) } } -AckSetTextmode(); +AckSetTextMode(); return 0; } diff --git a/map_edit/m1.h b/map_edit/m1.h index d987ee1..d87b103 100644 --- a/map_edit/m1.h +++ b/map_edit/m1.h @@ -2,6 +2,8 @@ // Author: Lary Myers // Copyright (c) 1994 +#ifndef M1_H_INCLUDED +#define M1_H_INCLUDED #define RES_SMFONT 0 // Resource ID's #define RES_MDFONT 1 @@ -220,3 +222,5 @@ int QueryBox(int x,int y,char *Msg); //----------------------------------------------------------------------------- short LoadDescFile(char *fName); +#endif + diff --git a/map_edit/m1read.c b/map_edit/m1read.c index 292e967..30db36f 100644 --- a/map_edit/m1read.c +++ b/map_edit/m1read.c @@ -7,13 +7,9 @@ #include #include #include -#include #include #include -#include #include -#include -#include #include #include "ack3d.h" #include "ackeng.h" @@ -85,7 +81,7 @@ if (LoadType) } -bmp = malloc(4096); +bmp = (unsigned char*)malloc(4096); if (bmp == NULL) { ReadErrorCode = ERR_NOMEMORY; diff --git a/map_edit/m1util.c b/map_edit/m1util.c index e764cc1..ecff4e4 100644 --- a/map_edit/m1util.c +++ b/map_edit/m1util.c @@ -3,18 +3,11 @@ // Author: Lary Myers // Copyright (c) 1994 -#include #include +#include #include #include -#include -#include -#include -#include #include -#include -#include -#include #include "ack3d.h" #include "ackeng.h" #include "m1.h" @@ -50,7 +43,7 @@ short LoadSmallFont(void) int len; ht = 2; -smFont = AckReadiff((char *)RES_SMFONT); // "spfont.bbm"); +smFont = (char*)AckReadiff((char *)RES_SMFONT); // "spfont.bbm"); if (smFont == NULL) return(-1); @@ -71,7 +64,7 @@ short LoadMedFont(void) int len; ht = 2; -mdFont = AckReadiff((char *)RES_MDFONT); // "font6x9.bbm"); +mdFont = (char*)AckReadiff((char *)RES_MDFONT); // "font6x9.bbm"); if (mdFont == NULL) return(-1); diff --git a/map_edit/mapedit.h b/map_edit/mapedit.h index 765642e..e97994b 100644 --- a/map_edit/mapedit.h +++ b/map_edit/mapedit.h @@ -1,5 +1,8 @@ /* Header file for ACK-3D Map Editor */ +#ifndef MAPEDIT_H_INCLUDED +#define MAPEDIT_H_INCLUDED + #define CURRENT_SQUAREX 161 #define CURRENT_SQUAREY 4 @@ -50,3 +53,5 @@ unsigned short inkey(void); void SetVGAmode(void); void SetTextMode(void); +#endif + diff --git a/map_edit/measm.asm b/map_edit/measm.asm index ac6747f..36faa0d 100644 --- a/map_edit/measm.asm +++ b/map_edit/measm.asm @@ -1,21 +1,19 @@ - IDEAL - JUMPS - include "prologue.mac" - P386 ; 386 specific opcodes and shit allowed. - P387 ; Allow 386 processor +IDEAL +JUMPS +include "prologue.mac" +P386 ; 386 specific opcodes and shit allowed. +P387 ; Allow 386 processor +model flat - MASM - .MODEL FLAT ;32-bit OS/2 model - .CODE - IDEAL +codeseg - PUBLIC SetPalette2_ - PUBLIC SetVGAmode_ - PUBLIC SetTextMode_ - PUBLIC inkey_ - PUBLIC PutHex_ +PUBLIC SetPalette2_ +PUBLIC SetVGAmode_ +PUBLIC SetTextMode_ +PUBLIC inkey_ +PUBLIC PutHex_ ;============================================================================== ; void SetPalette2(unsigned char *PalBuf,short count); @@ -119,5 +117,6 @@ Proc PutHex_ near pop edi ret endp + end diff --git a/map_edit/mouse.c b/map_edit/mouse.c index 6460ace..738c9e0 100644 --- a/map_edit/mouse.c +++ b/map_edit/mouse.c @@ -6,7 +6,7 @@ #include #include -#include +#include int MouseModifier = 2;