patches/assaultcube-02-conflict.diff
author drdoug007
Tue, 05 Jun 2007 13:48:08 +0000
changeset 301 cd39a210da5a
child 2142 2b7259204db3
permissions -rw-r--r--
2007-06-05 Doug Scott <[email protected]> * SFEassaultcube.spec: Added AssaultCube game Engine * patches/assaultcube-01-solaris.diff: patch for Solaris * patches/assaultcube-02-conflict.diff: patch for Solaris * patches/assaultcube-03-cmds.diff: patch for Solaris
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
301
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
     1
--- AssaultCube/source/src/renderhud.cpp.orig	2007-06-05 19:58:47.757027557 +0700
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
     2
+++ AssaultCube/source/src/renderhud.cpp	2007-06-05 19:59:21.560872172 +0700
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
     3
@@ -4,7 +4,7 @@
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
     4
 
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
     5
 void drawicon(Texture *tex, float x, float y, float s, int col, int row, float ts)
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
     6
 {
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
     7
-    if(tex && tex->xs == tex->ys) quad(tex->id, x, y, s, ts*col, ts*row, ts);
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
     8
+    if(tex && tex->xs == tex->ys) a_quad(tex->id, x, y, s, ts*col, ts*row, ts);
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
     9
 }
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    10
 
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    11
 void drawequipicon(float x, float y, int col, int row, float blend)
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    12
@@ -177,7 +177,7 @@
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    13
     if(showmap) 
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    14
     {
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    15
         glBlendFunc(GL_ONE, GL_ONE_MINUS_SRC_COLOR);
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    16
-        quad(minimaptex, 0, 0, radarviewsize, (centerpos.x-res/2)/worldsize, (centerpos.y-res/2)/worldsize, res/worldsize);
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    17
+        a_quad(minimaptex, 0, 0, radarviewsize, (centerpos.x-res/2)/worldsize, (centerpos.y-res/2)/worldsize, res/worldsize);
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    18
         glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    19
         glDisable(GL_BLEND);
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    20
     }
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    21
@@ -225,7 +225,7 @@
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    22
         glColor3f(1, 1, 1);
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    23
         static Texture *overlaytex = NULL;
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    24
         if(!overlaytex) overlaytex = textureload("packages/misc/radaroverlays.png", 3);
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    25
-        quad(overlaytex->id, VIRTW-overlaysize-10, 10, overlaysize, m_teammode ? 0.5f*team_int(player1->team) : 0, m_teammode ? 0 : 0.5f, 0.5f, 0.5f); 
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    26
+        a_quad(overlaytex->id, VIRTW-overlaysize-10, 10, overlaysize, m_teammode ? 0.5f*team_int(player1->team) : 0, m_teammode ? 0 : 0.5f, 0.5f, 0.5f); 
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    27
         glEnable(GL_CULL_FACE);
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    28
     }
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    29
 }
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    30
@@ -237,7 +237,7 @@
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    31
     glColor3f(1, 1, 1);
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    32
     static Texture *icons = NULL;
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    33
     if(!icons) icons = textureload("packages/misc/teamicons.png");
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    34
-    quad(icons->id, VIRTW-VIRTH/12-10, 10, VIRTH/12, team_int(player1->team) ? 0.5f : 0, 0, 0.5f, 0.5f);
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    35
+    a_quad(icons->id, VIRTW-VIRTH/12-10, 10, VIRTH/12, team_int(player1->team) ? 0.5f : 0, 0, 0.5f, 0.5f);
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    36
     glEnable(GL_CULL_FACE);
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    37
 }
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    38
 
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    39
@@ -410,7 +410,7 @@
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    40
     loopi(fmt ? 1 : 2)
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    41
     {
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    42
         glClear(GL_COLOR_BUFFER_BIT);
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    43
-        quad(logo->id, (VIRTW-VIRTH)/2, 0, VIRTH, 0, 0, 1);
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    44
+        a_quad(logo->id, (VIRTW-VIRTH)/2, 0, VIRTH, 0, 0, 1);
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    45
         if(fmt)
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    46
         {
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    47
             glEnable(GL_BLEND);
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    48
--- AssaultCube/source/src/protos.h.orig	2007-06-05 19:58:15.342674093 +0700
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    49
+++ AssaultCube/source/src/protos.h	2007-06-05 19:58:17.823304475 +0700
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    50
@@ -61,7 +61,7 @@
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    51
 extern void dot(int x, int y, float z);
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    52
 extern void linestyle(float width, int r, int g, int b);
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    53
 extern void blendbox(int x1, int y1, int x2, int y2, bool border, int tex = -1);
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    54
-extern void quad(GLuint tex, float x, float y, float s, float tx, float ty, float tsx, float tsy = 0);
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    55
+extern void a_quad(GLuint tex, float x, float y, float s, float tx, float ty, float tsx, float tsy = 0);
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    56
 extern void circle(GLuint tex, float x, float y, float r, float tx, float ty, float tr, int subdiv = 32);
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    57
 extern void gl_drawframe(int w, int h, float changelod, float curfps);
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    58
 extern void clearminimap();
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    59
--- AssaultCube/source/src/rendergl.cpp.orig	2007-06-05 19:58:03.463233585 +0700
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    60
+++ AssaultCube/source/src/rendergl.cpp	2007-06-05 19:58:17.822921121 +0700
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    61
@@ -108,7 +108,7 @@
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    62
     xtraverts += 4;
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    63
 }   
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    64
 
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    65
-void quad(GLuint tex, float x, float y, float s, float tx, float ty, float tsx, float tsy)
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    66
+void a_quad(GLuint tex, float x, float y, float s, float tx, float ty, float tsx, float tsy)
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    67
 {
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    68
     if(!tsy) tsy = tsx;
cd39a210da5a 2007-06-05 Doug Scott <[email protected]>
drdoug007
parents:
diff changeset
    69
     glBindTexture(GL_TEXTURE_2D, tex);