]> git.pld-linux.org Git - packages/War3D.git/commitdiff
- NEW
authorsparky <sparky@pld-linux.org>
Sun, 11 Sep 2005 01:13:58 +0000 (01:13 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    War3D-homeconfig.patch -> 1.1
    War3D.desktop -> 1.1
    War3D.sh -> 1.1

War3D-homeconfig.patch [new file with mode: 0644]
War3D.desktop [new file with mode: 0644]
War3D.sh [new file with mode: 0644]

diff --git a/War3D-homeconfig.patch b/War3D-homeconfig.patch
new file mode 100644 (file)
index 0000000..4b8f27b
--- /dev/null
@@ -0,0 +1,27 @@
+--- War3DSource/Main.cpp.orig  2005-09-11 01:12:53.000000000 +0200
++++ War3DSource/Main.cpp       2005-09-11 01:33:17.000000000 +0200
+@@ -27,6 +27,8 @@
+ #include <math.h>
+ #include <stdio.h>
++#include <pwd.h>
++
+ #ifdef _WIN32 // Windows
+@@ -106,7 +108,14 @@
+   glutInit(&argc, argv);
+-  configuracion::leerConfig ("War3D.conf");
++  std::string confname;
++  struct passwd *pwent = getpwuid(getuid());
++  if ( pwent && pwent->pw_dir ) {
++        confname = std::string(pwent->pw_dir) + "/.War3D.conf";
++  } else {
++        confname = "War3D.conf";
++  }
++  configuracion::leerConfig (confname);
+   SetupGL();
+   SetupRC(); //Inicia la iluminacion y algunas otras cosas
diff --git a/War3D.desktop b/War3D.desktop
new file mode 100644 (file)
index 0000000..69c4322
--- /dev/null
@@ -0,0 +1,9 @@
+[Desktop Entry]
+Name=War3D
+Comment=Multiplayer 3D War Game
+Exec=war3d
+Terminal=false
+Type=Application
+Encoding=UTF-8
+Categories=Game;StrategyGame;
+# vi: encoding=utf-8
diff --git a/War3D.sh b/War3D.sh
new file mode 100644 (file)
index 0000000..38890ee
--- /dev/null
+++ b/War3D.sh
@@ -0,0 +1,9 @@
+#!/bin/sh
+
+CONF="$HOME/.War3D.conf"
+
+cd /usr/share/War3D
+
+[ -r "$CONF" ] || cp -f War3D.conf $CONF
+
+exec war3d.bin
This page took 0.083442 seconds and 4 git commands to generate.