foxygit / doom Log in
commit 07bb5a69ef9f1240bf887585aa7162d854368d03
Author:     Simon Howard <fraggle@gmail.com>
AuthorDate: Sun Mar 6 22:58:02 2011 +0000
Commit:     Simon Howard <fraggle@gmail.com>
CommitDate: Sun Mar 6 22:58:02 2011 +0000

    Add Strife to OS X launcher.

    Subversion-branch: /branches/strife-branch
    Subversion-revision: 2294
---
 pkg/osx/GNUmakefile      |  2 ++
 pkg/osx/IWADController.h |  1 +
 pkg/osx/IWADController.m | 10 +++++++++-
 3 files changed, 12 insertions(+), 1 deletion(-)

diff --git a/pkg/osx/GNUmakefile b/pkg/osx/GNUmakefile
index aa31daf4..43922b5a 100644
--- a/pkg/osx/GNUmakefile
+++ b/pkg/osx/GNUmakefile
@@ -68,6 +68,8 @@ $(STAGING_DIR): launcher $(TOPLEVEL_DOCS)
 	$(STRIP) "$(APP_BIN_DIR)/$(PROGRAM_PREFIX)heretic"
 	./cp-with-libs $(TOPLEVEL)/src/$(PROGRAM_PREFIX)hexen "$(APP_BIN_DIR)"
 	$(STRIP) "$(APP_BIN_DIR)/$(PROGRAM_PREFIX)hexen"
+	./cp-with-libs $(TOPLEVEL)/src/$(PROGRAM_PREFIX)strife "$(APP_BIN_DIR)"
+	$(STRIP) "$(APP_BIN_DIR)/$(PROGRAM_PREFIX)strife"
 	./cp-with-libs $(TOPLEVEL)/src/$(PROGRAM_PREFIX)setup "$(APP_BIN_DIR)"
 	$(STRIP) "$(APP_BIN_DIR)/$(PROGRAM_PREFIX)setup"

diff --git a/pkg/osx/IWADController.h b/pkg/osx/IWADController.h
index fef28918..8b201187 100644
--- a/pkg/osx/IWADController.h
+++ b/pkg/osx/IWADController.h
@@ -39,6 +39,7 @@

     id heretic;
     id hexen;
+    id strife;
 }

 - (void) closeConfigWindow: (id)sender;
diff --git a/pkg/osx/IWADController.m b/pkg/osx/IWADController.m
index 6cab7ff2..91c02c46 100644
--- a/pkg/osx/IWADController.m
+++ b/pkg/osx/IWADController.m
@@ -35,6 +35,7 @@ typedef enum
     IWAD_CHEX,
     IWAD_HERETIC,
     IWAD_HEXEN,
+    IWAD_STRIFE,
     NUM_IWAD_TYPES
 } IWAD;

@@ -46,7 +47,8 @@ static NSString *IWADLabels[NUM_IWAD_TYPES] =
     @"Final Doom: Plutonia Experiment",
     @"Chex Quest",
     @"Heretic",
-    @"Hexen"
+    @"Hexen",
+    @"Strife"
 };

 static NSString *IWADFilenames[NUM_IWAD_TYPES + 1] =
@@ -58,6 +60,7 @@ static NSString *IWADFilenames[NUM_IWAD_TYPES + 1] =
     @"chex.wad",
     @"heretic.wad",
     @"hexen.wad",
+    @"strife.wad",
     @"undefined"
 };

@@ -72,6 +75,7 @@ static NSString *IWADFilenames[NUM_IWAD_TYPES + 1] =
     iwadList[IWAD_CHEX] = self->chex;
     iwadList[IWAD_HERETIC] = self->heretic;
     iwadList[IWAD_HEXEN] = self->hexen;
+    iwadList[IWAD_STRIFE] = self->strife;
 }

 - (IWAD) getSelectedIWAD
@@ -126,6 +130,9 @@ static NSString *IWADFilenames[NUM_IWAD_TYPES + 1] =
         case IWAD_HEXEN:
             return "hexen";

+        case IWAD_STRIFE:
+            return "strife";
+
         default:
             return "doom";
     }
@@ -282,6 +289,7 @@ static NSString *IWADFilenames[NUM_IWAD_TYPES + 1] =
     // TODO: This is temporary:
     self->heretic = self->doom1;
     self->hexen = self->doom2;
+    self->strife = self->tnt;

     [self->configWindow center];