2010-09-29 20:09:11 +00:00
|
|
|
// ======================================
|
2003-03-18 19:48:24 +00:00
|
|
|
//
|
|
|
|
// QuakeEd Project Management
|
|
|
|
//
|
2010-09-29 20:09:11 +00:00
|
|
|
// ======================================
|
2003-03-18 19:48:24 +00:00
|
|
|
|
2010-09-11 08:35:25 +00:00
|
|
|
#include <unistd.h>
|
|
|
|
|
2010-10-04 10:43:33 +00:00
|
|
|
#include "QF/qfplist.h"
|
2010-09-12 09:12:02 +00:00
|
|
|
#include "QF/quakefs.h"
|
2010-09-11 08:35:25 +00:00
|
|
|
#include "QF/sys.h"
|
2010-09-28 12:40:11 +00:00
|
|
|
#include "QF/va.h"
|
2010-09-11 08:35:25 +00:00
|
|
|
|
|
|
|
#include "Project.h"
|
|
|
|
#include "Map.h"
|
|
|
|
#include "QuakeEd.h"
|
|
|
|
#include "Preferences.h"
|
|
|
|
#include "Dict.h"
|
|
|
|
#include "Things.h"
|
|
|
|
#include "TexturePalette.h"
|
2003-03-18 19:48:24 +00:00
|
|
|
|
2010-09-29 20:09:11 +00:00
|
|
|
id project_i;
|
2003-03-18 19:48:24 +00:00
|
|
|
|
|
|
|
@implementation Project
|
|
|
|
|
2010-09-29 20:09:11 +00:00
|
|
|
- (id) init
|
2003-03-18 19:48:24 +00:00
|
|
|
{
|
|
|
|
project_i = self;
|
|
|
|
|
|
|
|
return self;
|
|
|
|
}
|
|
|
|
|
2010-09-29 20:09:11 +00:00
|
|
|
// ===========================================================
|
2003-03-18 19:48:24 +00:00
|
|
|
//
|
2010-09-11 10:03:41 +00:00
|
|
|
// Project code
|
2003-03-18 19:48:24 +00:00
|
|
|
//
|
2010-09-29 20:09:11 +00:00
|
|
|
// ===========================================================
|
|
|
|
- (id) initVars
|
2003-03-18 19:48:24 +00:00
|
|
|
{
|
2010-10-07 08:58:26 +00:00
|
|
|
NSString *ts;
|
2010-09-11 10:03:41 +00:00
|
|
|
|
2010-10-10 06:52:18 +00:00
|
|
|
ts = path_projectinfo;
|
2010-10-07 08:58:26 +00:00
|
|
|
ts = path_basepath = [[ts stringByDeletingLastPathComponent] retain];
|
2010-09-11 10:03:41 +00:00
|
|
|
|
2010-10-07 08:58:26 +00:00
|
|
|
path_progdir = [[ts stringByAppendingPathComponent: SUBDIR_ENT] retain];
|
2010-09-11 10:03:41 +00:00
|
|
|
|
2010-10-07 08:58:26 +00:00
|
|
|
path_mapdirectory = [[ts stringByAppendingPathComponent: SUBDIR_MAPS] retain];
|
|
|
|
path_finalmapdir = [[ts stringByAppendingPathComponent: SUBDIR_MAPS] retain];
|
2010-09-11 10:03:41 +00:00
|
|
|
|
2010-09-29 20:09:11 +00:00
|
|
|
// in Project Inspector
|
2010-10-07 08:58:26 +00:00
|
|
|
[basepathinfo_i setStringValue: ts];
|
2010-09-11 10:03:41 +00:00
|
|
|
|
2010-09-29 20:09:11 +00:00
|
|
|
#if 0 // FIXME: for "out-of-tree" projects ?
|
|
|
|
if ((s = [projectInfo getStringFor: BASEPATHKEY])) {
|
2010-09-11 10:03:41 +00:00
|
|
|
strcpy (path_basepath, s);
|
|
|
|
|
|
|
|
strcpy (path_progdir, s);
|
|
|
|
strcat (path_progdir, "/" SUBDIR_ENT);
|
|
|
|
|
|
|
|
strcpy (path_mapdirectory, s);
|
2010-09-29 20:09:11 +00:00
|
|
|
strcat (path_mapdirectory, "/" SUBDIR_MAPS); // source dir
|
2010-09-11 10:03:41 +00:00
|
|
|
|
|
|
|
strcpy (path_finalmapdir, s);
|
2010-09-29 20:09:11 +00:00
|
|
|
strcat (path_finalmapdir, "/" SUBDIR_MAPS); // dest dir
|
2010-09-11 10:03:41 +00:00
|
|
|
|
2010-09-29 20:09:11 +00:00
|
|
|
[basepathinfo_i setStringValue: s]; // in Project Inspector
|
2003-03-18 19:48:24 +00:00
|
|
|
}
|
2010-09-11 10:03:41 +00:00
|
|
|
#endif
|
|
|
|
|
2010-10-05 14:48:06 +00:00
|
|
|
string_fullvis = [projectInfo getStringFor: BSPFULLVIS];
|
|
|
|
string_fastvis = [projectInfo getStringFor: BSPFASTVIS];
|
|
|
|
string_novis = [projectInfo getStringFor: BSPNOVIS];
|
|
|
|
string_relight = [projectInfo getStringFor: BSPRELIGHT];
|
|
|
|
string_leaktest = [projectInfo getStringFor: BSPLEAKTEST];
|
|
|
|
string_entities = [projectInfo getStringFor: BSPENTITIES];
|
2003-03-18 19:48:24 +00:00
|
|
|
|
2010-09-29 20:09:11 +00:00
|
|
|
// Build list of wads
|
2010-10-04 10:43:33 +00:00
|
|
|
wadList = [projectInfo getArrayFor: WADSKEY];
|
2003-03-18 19:48:24 +00:00
|
|
|
|
2010-09-11 10:03:41 +00:00
|
|
|
// Build list of maps & descriptions
|
2010-10-04 10:43:33 +00:00
|
|
|
mapList = [projectInfo getArrayFor: MAPNAMESKEY];
|
|
|
|
descList = [projectInfo getArrayFor: DESCKEY];
|
2003-03-18 19:48:24 +00:00
|
|
|
|
|
|
|
[self initProjSettings];
|
|
|
|
|
|
|
|
return self;
|
|
|
|
}
|
|
|
|
|
2010-09-11 10:03:41 +00:00
|
|
|
// Init Project Settings fields
|
2010-09-29 20:09:11 +00:00
|
|
|
- (id) initProjSettings
|
2003-03-18 19:48:24 +00:00
|
|
|
{
|
2010-10-07 08:58:26 +00:00
|
|
|
[pis_basepath_i setStringValue: path_basepath];
|
2010-09-29 20:09:11 +00:00
|
|
|
[pis_fullvis_i setStringValue: [NSString stringWithCString: string_fullvis]];
|
|
|
|
[pis_fastvis_i setStringValue: [NSString stringWithCString: string_fastvis]];
|
|
|
|
[pis_novis_i setStringValue: [NSString stringWithCString: string_novis]];
|
|
|
|
[pis_relight_i setStringValue: [NSString stringWithCString: string_relight]];
|
|
|
|
[pis_leaktest_i setStringValue: [NSString stringWithCString: string_leaktest]];
|
2010-09-11 10:03:41 +00:00
|
|
|
|
2003-03-18 19:48:24 +00:00
|
|
|
return self;
|
|
|
|
}
|
|
|
|
|
2010-09-11 10:03:41 +00:00
|
|
|
// Add text to the BSP Output window
|
2010-09-29 20:09:11 +00:00
|
|
|
- (id) addToOutput: (const char *)string
|
2003-03-18 19:48:24 +00:00
|
|
|
{
|
2010-09-29 20:09:11 +00:00
|
|
|
int end;
|
2010-09-11 10:03:41 +00:00
|
|
|
|
2010-09-29 20:09:11 +00:00
|
|
|
end = [BSPoutput_i textLength];
|
|
|
|
[BSPoutput_i replaceCharactersInRange: NSMakeRange (end, 0)
|
|
|
|
withString: [NSString stringWithCString: string]];
|
2010-09-11 10:03:41 +00:00
|
|
|
|
2010-09-29 20:09:11 +00:00
|
|
|
end = [BSPoutput_i textLength];
|
|
|
|
[BSPoutput_i setSelectedRange: NSMakeRange (end, 0)];
|
2010-09-11 10:03:41 +00:00
|
|
|
// XXX [BSPoutput_i scrollSelToVisible];
|
|
|
|
|
2003-03-18 19:48:24 +00:00
|
|
|
return self;
|
|
|
|
}
|
|
|
|
|
2010-09-29 20:09:11 +00:00
|
|
|
- (id) clearBspOutput: sender
|
2003-03-18 19:48:24 +00:00
|
|
|
{
|
2010-09-29 20:09:11 +00:00
|
|
|
int end;
|
2010-09-11 10:03:41 +00:00
|
|
|
|
2010-09-29 20:09:11 +00:00
|
|
|
end = [BSPoutput_i textLength];
|
|
|
|
[BSPoutput_i replaceCharactersInRange: NSMakeRange (0, end) withString: @""];
|
2010-09-11 10:03:41 +00:00
|
|
|
|
2003-03-18 19:48:24 +00:00
|
|
|
return self;
|
|
|
|
}
|
|
|
|
|
2010-09-29 20:09:11 +00:00
|
|
|
- (id) print
|
2003-03-18 19:48:24 +00:00
|
|
|
{
|
2010-09-11 10:03:41 +00:00
|
|
|
// XXX [BSPoutput_i printPSCode:self];
|
2003-03-18 19:48:24 +00:00
|
|
|
return self;
|
|
|
|
}
|
|
|
|
|
2010-09-29 20:09:11 +00:00
|
|
|
- (id) initProject
|
2003-03-18 19:48:24 +00:00
|
|
|
{
|
|
|
|
[self parseProjectFile];
|
|
|
|
if (projectInfo == NULL)
|
|
|
|
return self;
|
|
|
|
[self initVars];
|
2010-09-29 20:09:11 +00:00
|
|
|
[mapbrowse_i setReusesColumns: YES];
|
2003-03-18 19:48:24 +00:00
|
|
|
[mapbrowse_i loadColumnZero];
|
2010-09-29 20:09:11 +00:00
|
|
|
[pis_wads_i setReusesColumns: YES];
|
2003-03-18 19:48:24 +00:00
|
|
|
[pis_wads_i loadColumnZero];
|
|
|
|
|
2010-09-11 10:03:41 +00:00
|
|
|
[things_i initEntities];
|
|
|
|
|
2003-03-18 19:48:24 +00:00
|
|
|
return self;
|
|
|
|
}
|
|
|
|
|
2010-09-11 10:03:41 +00:00
|
|
|
// Fill the QuakeEd Maps or wads browser
|
|
|
|
// (Delegate method - delegated in Interface Builder)
|
2010-09-29 20:09:11 +00:00
|
|
|
- (void) browser: sender createRowsForColumn: (int)column inMatrix: matrix
|
2003-03-18 19:48:24 +00:00
|
|
|
{
|
2010-10-04 10:43:33 +00:00
|
|
|
id cell;
|
|
|
|
plitem_t *list;
|
|
|
|
int max;
|
|
|
|
const char *name;
|
|
|
|
int i;
|
2003-03-18 19:48:24 +00:00
|
|
|
|
2010-09-29 20:09:11 +00:00
|
|
|
if (sender == mapbrowse_i) {
|
2003-03-18 19:48:24 +00:00
|
|
|
list = mapList;
|
2010-09-29 20:09:11 +00:00
|
|
|
} else if (sender == pis_wads_i) {
|
2003-03-18 19:48:24 +00:00
|
|
|
list = wadList;
|
2010-09-29 20:09:11 +00:00
|
|
|
} else {
|
2010-10-04 10:43:33 +00:00
|
|
|
list = 0;
|
2010-09-11 08:35:25 +00:00
|
|
|
Sys_Error ("Project: unknown browser to fill");
|
2003-03-18 19:48:24 +00:00
|
|
|
}
|
2010-09-11 10:03:41 +00:00
|
|
|
|
2010-10-04 10:43:33 +00:00
|
|
|
max = list ? PL_A_NumObjects (list) : 0;
|
2010-09-11 10:03:41 +00:00
|
|
|
for (i = 0; i < max; i++) {
|
2010-10-04 10:43:33 +00:00
|
|
|
name = PL_String (PL_ObjectAtIndex (list, i));
|
2003-03-18 19:48:24 +00:00
|
|
|
[matrix addRow];
|
2010-09-29 20:09:11 +00:00
|
|
|
cell = [matrix cellAtRow: i column: 0];
|
|
|
|
[cell setStringValue: [NSString stringWithCString: name]];
|
|
|
|
[cell setLeaf: YES];
|
|
|
|
[cell setLoaded: YES];
|
2003-03-18 19:48:24 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2010-09-11 10:03:41 +00:00
|
|
|
// Clicked on a map name or description!
|
2010-09-29 20:09:11 +00:00
|
|
|
- (id) clickedOnMap: sender
|
2003-03-18 19:48:24 +00:00
|
|
|
{
|
2010-09-29 20:09:11 +00:00
|
|
|
id matrix;
|
|
|
|
int row;
|
2010-10-07 08:58:26 +00:00
|
|
|
NSString *mapname;
|
|
|
|
NSString *fname;
|
2010-09-29 20:09:11 +00:00
|
|
|
id panel;
|
|
|
|
NSModalSession session;
|
|
|
|
|
|
|
|
matrix = [sender matrixInColumn: 0];
|
|
|
|
row = [matrix selectedRow];
|
2010-10-07 08:58:26 +00:00
|
|
|
mapname = [NSString stringWithCString:
|
|
|
|
PL_String (PL_ObjectAtIndex (mapList, row))];
|
|
|
|
fname = [[path_mapdirectory stringByAppendingPathComponent: mapname]
|
|
|
|
stringByAppendingPathExtension: @"map"];
|
2010-09-11 10:03:41 +00:00
|
|
|
|
|
|
|
panel = NSGetAlertPanel (@"Loading...",
|
2010-09-29 20:09:11 +00:00
|
|
|
@"Loading map. Please wait.", NULL, NULL, NULL);
|
2010-09-19 08:05:34 +00:00
|
|
|
|
|
|
|
session = [NSApp beginModalSessionForWindow: panel];
|
|
|
|
[NSApp runModalSession: session];
|
2003-03-18 19:48:24 +00:00
|
|
|
|
2010-09-29 20:09:11 +00:00
|
|
|
[quakeed_i doOpen: fname];
|
2003-03-18 19:48:24 +00:00
|
|
|
|
2010-09-19 08:05:34 +00:00
|
|
|
[NSApp endModalSession: session];
|
|
|
|
[panel close];
|
|
|
|
NSReleaseAlertPanel (panel);
|
2003-03-18 19:48:24 +00:00
|
|
|
return self;
|
|
|
|
}
|
|
|
|
|
2010-09-29 20:09:11 +00:00
|
|
|
- (id) setTextureWad: (const char *)wf
|
2003-03-18 19:48:24 +00:00
|
|
|
{
|
2010-09-11 10:03:41 +00:00
|
|
|
int i, c;
|
2010-09-29 20:09:11 +00:00
|
|
|
const char *name;
|
2010-09-11 10:03:41 +00:00
|
|
|
|
2010-09-12 02:13:35 +00:00
|
|
|
Sys_Printf ("loading %s\n", wf);
|
2003-03-18 19:48:24 +00:00
|
|
|
|
2010-10-11 12:11:33 +00:00
|
|
|
// set the row in the settings inspector wad browser
|
2010-10-04 10:43:33 +00:00
|
|
|
c = PL_A_NumObjects (wadList);
|
2010-09-11 10:03:41 +00:00
|
|
|
for (i = 0; i < c; i++) {
|
2010-10-04 10:43:33 +00:00
|
|
|
name = PL_String (PL_ObjectAtIndex (wadList, i));
|
2010-09-11 10:03:41 +00:00
|
|
|
if (!strcmp (name, wf)) {
|
2010-09-29 20:09:11 +00:00
|
|
|
[[pis_wads_i matrixInColumn: 0] selectCellAtRow: i column: 0];
|
2003-03-18 19:48:24 +00:00
|
|
|
break;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2010-10-11 12:11:33 +00:00
|
|
|
// update the texture inspector
|
2010-09-29 20:09:11 +00:00
|
|
|
[texturepalette_i initPaletteFromWadfile: wf];
|
|
|
|
[[map_i objectAtIndex: 0] setKey: "wad" toValue: wf];
|
2010-09-11 10:03:41 +00:00
|
|
|
// [inspcontrol_i changeInspectorTo:i_textures];
|
2003-03-18 19:48:24 +00:00
|
|
|
|
|
|
|
[quakeed_i updateAll];
|
|
|
|
|
|
|
|
return self;
|
|
|
|
}
|
|
|
|
|
2010-09-11 10:03:41 +00:00
|
|
|
// Clicked on a wad name
|
2010-09-29 20:09:11 +00:00
|
|
|
- (id) clickedOnWad: sender
|
2003-03-18 19:48:24 +00:00
|
|
|
{
|
2010-10-04 10:43:33 +00:00
|
|
|
id matrix;
|
|
|
|
int row;
|
|
|
|
const char *name;
|
2010-09-11 10:03:41 +00:00
|
|
|
|
2010-09-29 20:09:11 +00:00
|
|
|
matrix = [sender matrixInColumn: 0];
|
|
|
|
row = [matrix selectedRow];
|
2003-03-18 19:48:24 +00:00
|
|
|
|
2010-10-04 10:43:33 +00:00
|
|
|
name = PL_String (PL_ObjectAtIndex (wadList, row));
|
2010-09-29 20:09:11 +00:00
|
|
|
[self setTextureWad: name];
|
2010-09-11 10:03:41 +00:00
|
|
|
|
2003-03-18 19:48:24 +00:00
|
|
|
return self;
|
|
|
|
}
|
|
|
|
|
2010-09-11 10:03:41 +00:00
|
|
|
// Read in the <name>.QE_Project file
|
2010-09-29 20:09:11 +00:00
|
|
|
- (id) parseProjectFile
|
2003-03-18 19:48:24 +00:00
|
|
|
{
|
2010-10-09 00:49:35 +00:00
|
|
|
NSString *path;
|
2010-09-11 10:03:41 +00:00
|
|
|
int rtn;
|
2010-12-26 12:07:55 +00:00
|
|
|
NSFileManager *fm = [NSFileManager defaultManager];
|
2010-09-11 10:03:41 +00:00
|
|
|
|
2010-09-29 20:09:11 +00:00
|
|
|
path = [preferences_i getProjectPath];
|
2010-12-26 12:07:55 +00:00
|
|
|
if (![path length] || ![fm fileExistsAtPath: path]) {
|
2010-09-11 10:03:41 +00:00
|
|
|
rtn = NSRunAlertPanel (@"Project Error!",
|
2010-09-29 20:09:11 +00:00
|
|
|
@"A default project has not been found.\n",
|
|
|
|
@"Open Project", NULL, NULL);
|
|
|
|
if ([self openProject] == nil) {
|
|
|
|
while (1)
|
|
|
|
[NSApp terminate: self]; // can't run without a project
|
|
|
|
}
|
2010-09-11 10:03:41 +00:00
|
|
|
return self;
|
2003-03-18 19:48:24 +00:00
|
|
|
}
|
|
|
|
|
2010-10-09 00:49:35 +00:00
|
|
|
[self openProjectFile: path];
|
2003-03-18 19:48:24 +00:00
|
|
|
return self;
|
|
|
|
}
|
|
|
|
|
2010-09-11 10:03:41 +00:00
|
|
|
// Loads and parses a project file
|
2010-10-05 14:48:56 +00:00
|
|
|
- (id) openProjectFile: (NSString *)path
|
2010-09-11 10:03:41 +00:00
|
|
|
{
|
2010-09-29 20:09:11 +00:00
|
|
|
FILE *fp;
|
|
|
|
struct stat s;
|
|
|
|
|
2010-10-05 14:48:56 +00:00
|
|
|
Sys_Printf ("openProjectFile: %s\n", [path cString]);
|
|
|
|
[path retain];
|
|
|
|
[path_projectinfo release];
|
|
|
|
path_projectinfo = path;
|
2003-03-18 19:48:24 +00:00
|
|
|
|
|
|
|
projectInfo = NULL;
|
2010-10-05 14:48:56 +00:00
|
|
|
fp = fopen ([path cString], "r+t");
|
2003-03-18 19:48:24 +00:00
|
|
|
if (fp == NULL)
|
|
|
|
return self;
|
|
|
|
|
2010-10-05 14:48:56 +00:00
|
|
|
stat ([path cString], &s);
|
2003-03-18 19:48:24 +00:00
|
|
|
lastModified = s.st_mtime;
|
|
|
|
|
2010-09-29 20:09:11 +00:00
|
|
|
projectInfo = [(Dict *)[Dict alloc] initFromFile: fp];
|
2010-09-11 10:03:41 +00:00
|
|
|
fclose (fp);
|
|
|
|
|
2003-03-18 19:48:24 +00:00
|
|
|
return self;
|
|
|
|
}
|
|
|
|
|
2010-10-05 14:48:56 +00:00
|
|
|
- (NSString *) currentProjectFile
|
2003-03-18 19:48:24 +00:00
|
|
|
{
|
|
|
|
return path_projectinfo;
|
|
|
|
}
|
|
|
|
|
2010-09-11 10:03:41 +00:00
|
|
|
// Open a project file
|
2010-09-29 20:09:11 +00:00
|
|
|
- (id) openProject
|
2003-03-18 19:48:24 +00:00
|
|
|
{
|
2010-09-11 10:03:41 +00:00
|
|
|
id openpanel;
|
|
|
|
int rtn;
|
2010-09-29 20:09:11 +00:00
|
|
|
NSString *projtypes[] = {@"qpr"};
|
2010-10-05 14:48:56 +00:00
|
|
|
NSArray *projtypes_array;
|
2010-09-29 20:09:11 +00:00
|
|
|
NSArray *filenames;
|
2010-10-05 14:48:56 +00:00
|
|
|
NSString *path;
|
2010-09-29 20:09:11 +00:00
|
|
|
|
|
|
|
openpanel = [NSOpenPanel new];
|
2010-10-05 14:48:56 +00:00
|
|
|
[openpanel setAllowsMultipleSelection:NO];
|
|
|
|
[openpanel setCanChooseDirectories:NO];
|
|
|
|
projtypes_array = [NSArray arrayWithObjects: projtypes count: 1];
|
|
|
|
rtn = [openpanel runModalForTypes: projtypes_array];
|
2010-09-11 10:03:41 +00:00
|
|
|
if (rtn == NSOKButton) {
|
2010-09-29 20:09:11 +00:00
|
|
|
filenames = [openpanel filenames];
|
2010-10-05 14:48:56 +00:00
|
|
|
path = [filenames objectAtIndex: 0];
|
2010-09-29 20:09:11 +00:00
|
|
|
[self openProjectFile: path];
|
2010-09-11 10:03:41 +00:00
|
|
|
return self;
|
2003-03-18 19:48:24 +00:00
|
|
|
}
|
2010-09-11 10:03:41 +00:00
|
|
|
|
2003-03-18 19:48:24 +00:00
|
|
|
return nil;
|
|
|
|
}
|
|
|
|
|
2010-10-10 07:37:43 +00:00
|
|
|
- (NSString *) baseDirectoryPath
|
|
|
|
{
|
2010-10-10 07:55:01 +00:00
|
|
|
return path_basepath;
|
2010-10-10 07:37:43 +00:00
|
|
|
}
|
|
|
|
|
2010-10-07 08:58:26 +00:00
|
|
|
- (NSString *) getMapDirectory
|
2003-03-18 19:48:24 +00:00
|
|
|
{
|
|
|
|
return path_mapdirectory;
|
|
|
|
}
|
|
|
|
|
2010-10-07 08:58:26 +00:00
|
|
|
- (NSString *) getFinalMapDirectory
|
2003-03-18 19:48:24 +00:00
|
|
|
{
|
|
|
|
return path_finalmapdir;
|
|
|
|
}
|
|
|
|
|
2010-10-07 08:58:26 +00:00
|
|
|
- (NSString *) getProgDirectory
|
2003-03-18 19:48:24 +00:00
|
|
|
{
|
|
|
|
return path_progdir;
|
|
|
|
}
|
|
|
|
|
2010-09-11 10:03:41 +00:00
|
|
|
// Return the WAD name for cmd-8
|
2010-09-29 20:09:11 +00:00
|
|
|
- (const char *) getWAD8
|
2003-03-18 19:48:24 +00:00
|
|
|
{
|
|
|
|
if (!path_wad8[0])
|
|
|
|
return NULL;
|
2010-09-29 20:09:11 +00:00
|
|
|
|
2003-03-18 19:48:24 +00:00
|
|
|
return path_wad8;
|
|
|
|
}
|
|
|
|
|
2010-09-11 10:03:41 +00:00
|
|
|
// Return the WAD name for cmd-9
|
2010-09-29 20:09:11 +00:00
|
|
|
- (const char *) getWAD9
|
2003-03-18 19:48:24 +00:00
|
|
|
{
|
|
|
|
if (!path_wad9[0])
|
|
|
|
return NULL;
|
2010-09-29 20:09:11 +00:00
|
|
|
|
2003-03-18 19:48:24 +00:00
|
|
|
return path_wad9;
|
|
|
|
}
|
|
|
|
|
2010-09-11 10:03:41 +00:00
|
|
|
// Return the WAD name for cmd-0
|
2010-09-29 20:09:11 +00:00
|
|
|
- (const char *) getWAD0
|
2003-03-18 19:48:24 +00:00
|
|
|
{
|
|
|
|
if (!path_wad0[0])
|
|
|
|
return NULL;
|
2010-09-29 20:09:11 +00:00
|
|
|
|
2003-03-18 19:48:24 +00:00
|
|
|
return path_wad0;
|
|
|
|
}
|
|
|
|
|
2010-09-11 10:03:41 +00:00
|
|
|
// Return the FULLVIS cmd string
|
2010-09-29 20:09:11 +00:00
|
|
|
- (const char *) getFullVisCmd
|
2003-03-18 19:48:24 +00:00
|
|
|
{
|
|
|
|
if (!string_fullvis[0])
|
|
|
|
return NULL;
|
2010-09-29 20:09:11 +00:00
|
|
|
|
2003-03-18 19:48:24 +00:00
|
|
|
return string_fullvis;
|
|
|
|
}
|
|
|
|
|
2010-09-11 10:03:41 +00:00
|
|
|
// Return the FASTVIS cmd string
|
2010-09-29 20:09:11 +00:00
|
|
|
- (const char *) getFastVisCmd
|
2003-03-18 19:48:24 +00:00
|
|
|
{
|
|
|
|
if (!string_fastvis[0])
|
|
|
|
return NULL;
|
2010-09-29 20:09:11 +00:00
|
|
|
|
2003-03-18 19:48:24 +00:00
|
|
|
return string_fastvis;
|
|
|
|
}
|
|
|
|
|
2010-09-11 10:03:41 +00:00
|
|
|
// Return the NOVIS cmd string
|
2010-09-29 20:09:11 +00:00
|
|
|
- (const char *) getNoVisCmd
|
2003-03-18 19:48:24 +00:00
|
|
|
{
|
|
|
|
if (!string_novis[0])
|
|
|
|
return NULL;
|
2010-09-29 20:09:11 +00:00
|
|
|
|
2003-03-18 19:48:24 +00:00
|
|
|
return string_novis;
|
|
|
|
}
|
|
|
|
|
2010-09-11 10:03:41 +00:00
|
|
|
// Return the RELIGHT cmd string
|
2010-09-29 20:09:11 +00:00
|
|
|
- (const char *) getRelightCmd
|
2003-03-18 19:48:24 +00:00
|
|
|
{
|
|
|
|
if (!string_relight[0])
|
|
|
|
return NULL;
|
2010-09-29 20:09:11 +00:00
|
|
|
|
2003-03-18 19:48:24 +00:00
|
|
|
return string_relight;
|
|
|
|
}
|
|
|
|
|
2010-09-11 10:03:41 +00:00
|
|
|
// Return the LEAKTEST cmd string
|
2010-09-29 20:09:11 +00:00
|
|
|
- (const char *) getLeaktestCmd
|
2003-03-18 19:48:24 +00:00
|
|
|
{
|
|
|
|
if (!string_leaktest[0])
|
|
|
|
return NULL;
|
2010-09-29 20:09:11 +00:00
|
|
|
|
2003-03-18 19:48:24 +00:00
|
|
|
return string_leaktest;
|
|
|
|
}
|
|
|
|
|
2010-09-29 20:09:11 +00:00
|
|
|
- (const char *) getEntitiesCmd
|
2003-03-18 19:48:24 +00:00
|
|
|
{
|
|
|
|
if (!string_entities[0])
|
|
|
|
return NULL;
|
2010-09-29 20:09:11 +00:00
|
|
|
|
2003-03-18 19:48:24 +00:00
|
|
|
return string_entities;
|
|
|
|
}
|
|
|
|
|
|
|
|
@end
|