Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
  • 2 commits
  • 21 files changed
  • 0 comments
  • 1 contributor
Dec 29, 2011
Cyp Allow projectiles to face the camera.
Looks better than making projectiles cross-shaped, and less triangles to render.

Camera-facing projectiles should have two connectors, the first is "R A 0", with R = 1 if the
projectile should roll to face the camera (for cylinders) or R = 1 if the projectile should
completely face the camera (for spheres). And A = 1 if the projectile should be rendered normally
or A = 2 if the projectile should be rendered additively. The second connector should be the
coordinates of the middle of the projectile. Twin MG should contain two levels, one for each MG
projectile.
82e00bf
Cyp Replace cross-shaped projectiles with flat projectiles that rotate to…
… face the camera.

Number of triangles reduced by 75%.

Also, laser beams are no longer opaque.
11cd718
59  data/base/effects/fxaalsh2.pie
... ...
@@ -1,39 +1,28 @@
1 1
 PIE 2
2 2
 TYPE 200
3 3
 TEXTURE 0 page-21-fx.png 256 256
4  
-LEVELS 1
  4
+LEVELS 2
5 5
 LEVEL 1
6  
-POINTS 16 
7  
-	5 3 -23 
8  
-	5 3 -42 
9  
-	5 5 -42 
10  
-	5 5 -23 
11  
-	4 4 -23 
12  
-	4 4 -42 
13  
-	7 4 -42 
14  
-	7 4 -23 
15  
-	-5 3 -23 
16  
-	-5 3 -42 
17  
-	-5 5 -42 
18  
-	-5 5 -23 
19  
-	-7 4 -23 
20  
-	-7 4 -42 
21  
-	-4 4 -42 
22  
-	-4 4 -23
23  
-POLYGONS 16
24  
-	200 3 0 1 2 211 73 211 55 207 55
25  
-	200 3 0 2 3 211 73 207 55 207 73
26  
-	200 3 3 2 1 207 73 207 55 211 55
27  
-	200 3 3 1 0 207 73 211 55 211 73
28  
-	200 3 4 5 6 211 73 211 55 207 55
29  
-	200 3 4 6 7 211 73 207 55 207 73
30  
-	200 3 7 6 5 207 73 207 55 211 55
31  
-	200 3 7 5 4 207 73 211 55 211 73
32  
-	200 3 8 9 10 211 73 211 55 207 55
33  
-	200 3 8 10 11 211 73 207 55 207 73
34  
-	200 3 11 10 9 207 73 207 55 211 55
35  
-	200 3 11 9 8 207 73 211 55 211 73
36  
-	200 3 12 13 14 211 73 211 55 207 55
37  
-	200 3 12 14 15 211 73 207 55 207 73
38  
-	200 3 15 14 13 207 73 207 55 211 55
39  
-	200 3 15 13 12 207 73 211 55 211 73
  6
+POINTS 4
  7
+	-8 0 13
  8
+	-8 0 -13
  9
+	-6 0 -13
  10
+	-6 0 13
  11
+POLYGONS 2
  12
+	200 3 3 2 1 207 72 207 55 210 55
  13
+	200 3 3 1 0 207 72 210 55 210 72
  14
+CONNECTORS 2
  15
+	1 1 0
  16
+	-7 0 0
  17
+LEVEL 2
  18
+POINTS 4
  19
+	6 0 13
  20
+	6 0 -13
  21
+	8 0 -13
  22
+	8 0 13
  23
+POLYGONS 2
  24
+	200 3 3 2 1 207 72 207 55 210 55
  25
+	200 3 3 1 0 207 72 210 55 210 72
  26
+CONNECTORS 2
  27
+	1 1 0
  28
+	7 0 0
115  data/base/effects/fxaalsht.pie
... ...
@@ -1,71 +1,52 @@
1 1
 PIE 2
2 2
 TYPE 200
3 3
 TEXTURE 0 page-21-fx.png 256 256
4  
-LEVELS 1
  4
+LEVELS 4
5 5
 LEVEL 1
6  
-POINTS 32 
7  
-	-5 11 -16 
8  
-	-5 11 -36 
9  
-	-5 14 -36 
10  
-	-5 14 -16 
11  
-	-7 13 -16 
12  
-	-7 13 -36 
13  
-	-4 13 -36 
14  
-	-4 13 -16 
15  
-	5 11 -16 
16  
-	5 11 -36 
17  
-	5 14 -36 
18  
-	5 14 -16 
19  
-	4 13 -16 
20  
-	4 13 -36 
21  
-	7 13 -36 
22  
-	7 13 -16 
23  
-	5 3 -23 
24  
-	5 3 -42 
25  
-	5 5 -42 
26  
-	5 5 -23 
27  
-	4 4 -23 
28  
-	4 4 -42 
29  
-	7 4 -42 
30  
-	7 4 -23 
31  
-	-5 3 -23 
32  
-	-5 3 -42 
33  
-	-5 5 -42 
34  
-	-5 5 -23 
35  
-	-7 4 -23 
36  
-	-7 4 -42 
37  
-	-4 4 -42 
38  
-	-4 4 -23
39  
-POLYGONS 32
40  
-	200 3 0 1 2 211 73 211 55 207 55
41  
-	200 3 0 2 3 211 73 207 55 207 73
42  
-	200 3 3 2 1 207 73 207 55 211 55
43  
-	200 3 3 1 0 207 73 211 55 211 73
44  
-	200 3 4 5 6 211 73 211 55 207 55
45  
-	200 3 4 6 7 211 73 207 55 207 73
46  
-	200 3 7 6 5 207 73 207 55 211 55
47  
-	200 3 7 5 4 207 73 211 55 211 73
48  
-	200 3 8 9 10 211 73 211 55 207 55
49  
-	200 3 8 10 11 211 73 207 55 207 73
50  
-	200 3 11 10 9 207 73 207 55 211 55
51  
-	200 3 11 9 8 207 73 211 55 211 73
52  
-	200 3 12 13 14 211 73 211 55 207 55
53  
-	200 3 12 14 15 211 73 207 55 207 73
54  
-	200 3 15 14 13 207 73 207 55 211 55
55  
-	200 3 15 13 12 207 73 211 55 211 73
56  
-	200 3 16 17 18 211 73 211 55 207 55
57  
-	200 3 16 18 19 211 73 207 55 207 73
58  
-	200 3 19 18 17 207 73 207 55 211 55
59  
-	200 3 19 17 16 207 73 211 55 211 73
60  
-	200 3 20 21 22 211 73 211 55 207 55
61  
-	200 3 20 22 23 211 73 207 55 207 73
62  
-	200 3 23 22 21 207 73 207 55 211 55
63  
-	200 3 23 21 20 207 73 211 55 211 73
64  
-	200 3 24 25 26 211 73 211 55 207 55
65  
-	200 3 24 26 27 211 73 207 55 207 73
66  
-	200 3 27 26 25 207 73 207 55 211 55
67  
-	200 3 27 25 24 207 73 211 55 211 73
68  
-	200 3 28 29 30 211 73 211 55 207 55
69  
-	200 3 28 30 31 211 73 207 55 207 73
70  
-	200 3 31 30 29 207 73 207 55 211 55
71  
-	200 3 31 29 28 207 73 211 55 211 73
  6
+POINTS 4
  7
+	-6 -5 4
  8
+	-6 -5 -16
  9
+	-4 -5 -16
  10
+	-4 -5 4
  11
+POLYGONS 2
  12
+	200 3 3 2 1 207 72 207 55 210 55
  13
+	200 3 3 1 0 207 72 210 55 210 72
  14
+CONNECTORS 2
  15
+	1 1 0
  16
+	-5 -5 -6
  17
+LEVEL 2
  18
+POINTS 4
  19
+	4 -5 4
  20
+	4 -5 -16
  21
+	6 -5 -16
  22
+	6 -5 4
  23
+POLYGONS 2
  24
+	200 3 3 2 1 207 72 207 55 210 55
  25
+	200 3 3 1 0 207 72 210 55 210 72
  26
+CONNECTORS 2
  27
+	1 1 0
  28
+	5 -5 -6
  29
+LEVEL 3
  30
+POINTS 4
  31
+	-6 5 16
  32
+	-6 5 -4
  33
+	-4 5 -4
  34
+	-4 5 16
  35
+POLYGONS 2
  36
+	200 3 3 2 1 207 72 207 55 210 55
  37
+	200 3 3 1 0 207 72 210 55 210 72
  38
+CONNECTORS 2
  39
+	1 1 0
  40
+	-5 5 6
  41
+LEVEL 4
  42
+POINTS 4
  43
+	4 5 16
  44
+	4 5 -4
  45
+	6 5 -4
  46
+	6 5 16
  47
+POLYGONS 2
  48
+	200 3 3 2 1 207 72 207 55 210 55
  49
+	200 3 3 1 0 207 72 210 55 210 72
  50
+CONNECTORS 2
  51
+	1 1 0
  52
+	5 5 6
25  data/base/effects/fxcam20.pie
@@ -3,21 +3,14 @@ TYPE 200
3 3
 TEXTURE 0 page-21-fx.png 256 256
4 4
 LEVELS 1
5 5
 LEVEL 1
6  
-POINTS 8 
7  
-	0 1 -45 
8  
-	0 1 -54 
9  
-	0 7 -54 
10  
-	0 7 -45 
11  
-	-2 4 -45 
12  
-	-2 4 -54 
13  
-	2 4 -54 
14  
-	2 4 -45
15  
-POLYGONS 8
16  
-	200 3 0 1 2 203 69 203 54 192 54
17  
-	200 3 0 2 3 203 69 192 54 192 69
  6
+POINTS 4
  7
+	-2 0 5
  8
+	-2 0 -5
  9
+	2 0 -5
  10
+	2 0 5
  11
+POLYGONS 2
18 12
 	200 3 3 2 1 192 69 192 54 203 54
19 13
 	200 3 3 1 0 192 69 203 54 203 69
20  
-	200 3 4 5 6 203 69 203 54 192 54
21  
-	200 3 4 6 7 203 69 192 54 192 69
22  
-	200 3 7 6 5 192 69 192 54 203 54
23  
-	200 3 7 5 4 192 69 203 54 203 69
  14
+CONNECTORS 2
  15
+	1 1 0
  16
+	0 0 0
25  data/base/effects/fxcammo.pie
@@ -3,21 +3,14 @@ TYPE 200
3 3
 TEXTURE 0 page-21-fx.png 256 256
4 4
 LEVELS 1
5 5
 LEVEL 1
6  
-POINTS 8 
7  
-	0 2 -46 
8  
-	0 2 -52 
9  
-	0 6 -52 
10  
-	0 6 -46 
11  
-	-1 4 -46 
12  
-	-1 4 -52 
13  
-	1 4 -52 
14  
-	1 4 -46
15  
-POLYGONS 8
16  
-	200 3 0 1 2 203 69 203 54 192 54
17  
-	200 3 0 2 3 203 69 192 54 192 69
  6
+POINTS 4
  7
+	-2 0 7
  8
+	-2 0 -7
  9
+	2 0 -7
  10
+	2 0 7
  11
+POLYGONS 2
18 12
 	200 3 3 2 1 192 69 192 54 203 54
19 13
 	200 3 3 1 0 192 69 203 54 203 69
20  
-	200 3 4 5 6 203 69 203 54 192 54
21  
-	200 3 4 6 7 203 69 192 54 192 69
22  
-	200 3 7 6 5 192 69 192 54 203 54
23  
-	200 3 7 5 4 192 69 203 54 203 69
  14
+CONNECTORS 2
  15
+	1 1 0
  16
+	0 0 0
27  data/base/effects/fxgammo.pie
@@ -3,21 +3,14 @@ TYPE 200
3 3
 TEXTURE 0 page-18-fx.png 256 256
4 4
 LEVELS 1
5 5
 LEVEL 1
6  
-POINTS 8 
7  
-	0 4 41 
8  
-	0 4 -41 
9  
-	0 -3 -41 
10  
-	0 -3 41 
11  
-	-3 0 41 
12  
-	-3 0 -41 
13  
-	3 0 -41 
  6
+POINTS 4
  7
+	-3 0 41
  8
+	-3 0 -41
  9
+	3 0 -41
14 10
 	3 0 41
15  
-POLYGONS 8
16  
-	200 3 0 1 2 88 128 0 128 0 135
17  
-	200 3 0 2 3 88 128 0 135 88 135
18  
-	200 3 3 2 1 88 135 0 135 0 128
19  
-	200 3 3 1 0 88 135 0 128 88 128
20  
-	200 3 4 5 6 88 128 0 128 0 135
21  
-	200 3 4 6 7 88 128 0 135 88 135
22  
-	200 3 7 6 5 88 135 0 135 0 128
23  
-	200 3 7 5 4 88 135 0 128 88 128
  11
+POLYGONS 2
  12
+	200 3 3 2 1 74 134 1 134 1 127
  13
+	200 3 3 1 0 74 134 1 127 74 127
  14
+CONNECTORS 2
  15
+	1 1 0
  16
+	0 0 0
27  data/base/effects/fxgammoh.pie
@@ -3,21 +3,14 @@ TYPE 200
3 3
 TEXTURE 0 page-18-fx.png 256 256
4 4
 LEVELS 1
5 5
 LEVEL 1
6  
-POINTS 8 
7  
-	0 5 12 
8  
-	0 5 -12 
9  
-	0 -5 -12 
10  
-	0 -5 12 
11  
-	-5 0 12 
12  
-	-5 0 -12 
13  
-	5 0 -12 
  6
+POINTS 4
  7
+	-5 0 12
  8
+	-5 0 -12
  9
+	5 0 -12
14 10
 	5 0 12
15  
-POLYGONS 8
16  
-	200 3 0 1 2 29 138 0 138 0 151
17  
-	200 3 0 2 3 29 138 0 151 29 151
18  
-	200 3 3 2 1 29 151 0 151 0 138
19  
-	200 3 3 1 0 29 151 0 138 29 138
20  
-	200 3 4 5 6 29 138 0 138 0 151
21  
-	200 3 4 6 7 29 138 0 151 29 151
22  
-	200 3 7 6 5 29 151 0 151 0 138
23  
-	200 3 7 5 4 29 151 0 138 29 138
  11
+POLYGONS 2
  12
+	200 3 3 2 1 28 137 -1 137 -1 150
  13
+	200 3 3 1 0 28 137 -1 150 28 150
  14
+CONNECTORS 2
  15
+	1 1 0
  16
+	0 0 0
27  data/base/effects/fxgammom.pie
@@ -3,21 +3,14 @@ TYPE 200
3 3
 TEXTURE 0 page-18-fx.png 256 256
4 4
 LEVELS 1
5 5
 LEVEL 1
6  
-POINTS 8 
7  
-	0 4 52 
8  
-	0 4 -52 
9  
-	0 -4 -52 
10  
-	0 -4 52 
11  
-	-4 0 52 
12  
-	-4 0 -52 
13  
-	4 0 -52 
  6
+POINTS 4
  7
+	-4 0 52
  8
+	-4 0 -52
  9
+	4 0 -52
14 10
 	4 0 52
15  
-POLYGONS 8
16  
-	200 3 0 1 2 88 128 0 128 0 135
17  
-	200 3 0 2 3 88 128 0 135 88 135
18  
-	200 3 3 2 1 88 135 0 135 0 128
19  
-	200 3 3 1 0 88 135 0 128 88 128
20  
-	200 3 4 5 6 88 128 0 128 0 135
21  
-	200 3 4 6 7 88 128 0 135 88 135
22  
-	200 3 7 6 5 88 135 0 135 0 128
23  
-	200 3 7 5 4 88 135 0 128 88 128
  11
+POLYGONS 2
  12
+	200 3 3 2 1 74 134 1 134 1 127
  13
+	200 3 3 1 0 74 134 1 127 74 127
  14
+CONNECTORS 2
  15
+	1 1 0
  16
+	0 0 0
27  data/base/effects/fxhplme.pie
@@ -3,21 +3,14 @@ TYPE 200
3 3
 TEXTURE 0 page-23-fx.png 256 256
4 4
 LEVELS 1
5 5
 LEVEL 1
6  
-POINTS 8 
7  
-	0 -12 39 
8  
-	0 12 39 
9  
-	0 12 -39 
10  
-	0 -12 -39 
11  
-	-12 0 39 
12  
-	12 0 39 
13  
-	12 0 -39 
  6
+POINTS 4
  7
+	-12 0 39
14 8
 	-12 0 -39
15  
-POLYGONS 8
16  
-	200 3 0 1 2 228 195 228 181 203 181
17  
-	200 3 0 2 3 228 195 203 181 203 195
18  
-	200 3 3 2 1 203 195 203 181 228 181
19  
-	200 3 3 1 0 203 195 228 181 228 195
20  
-	200 3 4 5 6 228 195 228 181 203 181
21  
-	200 3 4 6 7 228 195 203 181 203 195
22  
-	200 3 7 6 5 203 195 203 181 228 181
23  
-	200 3 7 5 4 203 195 228 181 228 195
  9
+	12 0 -39
  10
+	12 0 39
  11
+POLYGONS 2
  12
+	200 3 3 2 1 227 194 202 194 202 181
  13
+	200 3 3 1 0 227 194 202 181 227 181
  14
+CONNECTORS 2
  15
+	1 2 0
  16
+	0 0 0
27  data/base/effects/fxlflsh.pie
@@ -3,21 +3,14 @@ TYPE 200
3 3
 TEXTURE 0 page-18-fx.png 256 256
4 4
 LEVELS 1
5 5
 LEVEL 1
6  
-POINTS 8 
7  
-	0 3 21 
8  
-	0 3 -21 
9  
-	0 -3 -21 
10  
-	0 -3 21 
11  
-	-3 0 21 
12  
-	-3 0 -21 
13  
-	3 0 -21 
  6
+POINTS 4
  7
+	-3 0 21
  8
+	-3 0 -21
  9
+	3 0 -21
14 10
 	3 0 21
15  
-POLYGONS 8
16  
-	200 3 0 1 2 19 153 0 153 0 160
17  
-	200 3 0 2 3 19 153 0 160 19 160
18  
-	200 3 3 2 1 19 160 0 160 0 153
19  
-	200 3 3 1 0 19 160 0 153 19 153
20  
-	200 3 4 5 6 19 153 0 153 0 160
21  
-	200 3 4 6 7 19 153 0 160 19 160
22  
-	200 3 7 6 5 19 160 0 160 0 153
23  
-	200 3 7 5 4 19 160 0 153 19 153
  11
+POLYGONS 2
  12
+	200 3 3 2 1 19 159 0 159 0 152
  13
+	200 3 3 1 0 19 159 0 152 19 152
  14
+CONNECTORS 2
  15
+	1 2 0
  16
+	0 0 0
37  data/base/effects/fxmflare.pie
@@ -3,29 +3,14 @@ TYPE 200
3 3
 TEXTURE 0 page-23-fx.png 256 256
4 4
 LEVELS 1
5 5
 LEVEL 1
6  
-POINTS 12 
7  
-	24 -24 0 
8  
-	24 25 0 
9  
-	-24 25 0 
10  
-	-24 -24 0 
11  
-	24 0 25 
12  
-	24 0 -24 
13  
-	-24 0 -24 
14  
-	-24 0 25 
15  
-	0 -24 24 
16  
-	0 25 24 
17  
-	0 25 -24 
18  
-	0 -24 -24
19  
-POLYGONS 12
20  
-	200 3 0 1 2 186 255 186 227 157 227
21  
-	200 3 0 2 3 186 255 157 227 157 255
22  
-	200 3 3 2 1 157 255 157 227 186 227
23  
-	200 3 3 1 0 157 255 186 227 186 255
24  
-	200 3 4 5 6 186 255 186 227 157 227
25  
-	200 3 4 6 7 186 255 157 227 157 255
26  
-	200 3 7 6 5 157 255 157 227 186 227
27  
-	200 3 7 5 4 157 255 186 227 186 255
28  
-	200 3 8 9 10 186 255 186 227 157 227
29  
-	200 3 8 10 11 186 255 157 227 157 255
30  
-	200 3 11 10 9 157 255 157 227 186 227
31  
-	200 3 11 9 8 157 255 186 227 186 255
  6
+POINTS 4
  7
+	-24 0 24
  8
+	-24 0 -24
  9
+	24 0 -24
  10
+	24 0 24
  11
+POLYGONS 2
  12
+	200 3 3 2 1 157 253 157 226 184 226
  13
+	200 3 3 1 0 157 253 184 226 184 253
  14
+CONNECTORS 2
  15
+	2 2 0
  16
+	0 0 0
27  data/base/effects/fxmplme.pie
@@ -3,21 +3,14 @@ TYPE 200
3 3
 TEXTURE 0 page-23-fx.png 256 256
4 4
 LEVELS 1
5 5
 LEVEL 1
6  
-POINTS 8 
7  
-	0 -9 29 
8  
-	0 9 29 
9  
-	0 9 -29 
10  
-	0 -9 -29 
11  
-	-9 0 29 
12  
-	9 0 29 
13  
-	9 0 -29 
  6
+POINTS 4
  7
+	-9 0 29
14 8
 	-9 0 -29
15  
-POLYGONS 8
16  
-	200 3 0 1 2 228 195 228 181 203 181
17  
-	200 3 0 2 3 228 195 203 181 203 195
18  
-	200 3 3 2 1 203 195 203 181 228 181
19  
-	200 3 3 1 0 203 195 228 181 228 195
20  
-	200 3 4 5 6 228 195 228 181 203 181
21  
-	200 3 4 6 7 228 195 203 181 203 195
22  
-	200 3 7 6 5 203 195 203 181 228 181
23  
-	200 3 7 5 4 203 195 228 181 228 195
  9
+	9 0 -29
  10
+	9 0 29
  11
+POLYGONS 2
  12
+	200 3 3 2 1 227 194 202 194 202 181
  13
+	200 3 3 1 0 227 194 202 181 227 181
  14
+CONNECTORS 2
  15
+	1 2 0
  16
+	0 0 0
27  data/base/effects/fxplammo.pie
@@ -3,21 +3,14 @@ TYPE 200
3 3
 TEXTURE 0 page-18-fx.png 256 256
4 4
 LEVELS 1
5 5
 LEVEL 1
6  
-POINTS 8 
7  
-	0 3 88 
8  
-	0 3 -88 
9  
-	0 -3 -88 
10  
-	0 -3 88 
11  
-	-3 0 88 
12  
-	-3 0 -88 
13  
-	3 0 -88 
  6
+POINTS 4
  7
+	-3 0 88
  8
+	-3 0 -88
  9
+	3 0 -88
14 10
 	3 0 88
15  
-POLYGONS 8
16  
-	200 3 0 1 2 61 153 41 153 41 160
17  
-	200 3 0 2 3 61 153 41 160 61 160
18  
-	200 3 3 2 1 61 160 41 160 41 153
19  
-	200 3 3 1 0 61 160 41 153 61 153
20  
-	200 3 4 5 6 61 153 41 153 41 160
21  
-	200 3 4 6 7 61 153 41 160 61 160
22  
-	200 3 7 6 5 61 160 41 160 41 153
23  
-	200 3 7 5 4 61 160 41 153 61 153
  11
+POLYGONS 2
  12
+	200 3 3 2 1 59 159 40 159 40 152
  13
+	200 3 3 1 0 59 159 40 152 59 152
  14
+CONNECTORS 2
  15
+	1 2 0
  16
+	0 0 0
27  data/base/effects/fxsplme.pie
@@ -3,21 +3,14 @@ TYPE 200
3 3
 TEXTURE 0 page-23-fx.png 256 256
4 4
 LEVELS 1
5 5
 LEVEL 1
6  
-POINTS 8 
7  
-	0 -6 20 
8  
-	0 6 20 
9  
-	0 6 -20 
10  
-	0 -6 -20 
11  
-	-6 0 20 
12  
-	6 0 20 
13  
-	6 0 -20 
  6
+POINTS 4
  7
+	-6 0 20
14 8
 	-6 0 -20
15  
-POLYGONS 8
16  
-	200 3 0 1 2 254 195 254 181 230 181
17  
-	200 3 0 2 3 254 195 230 181 230 195
18  
-	200 3 3 2 1 230 195 230 181 254 181
19  
-	200 3 3 1 0 230 195 254 181 254 195
20  
-	200 3 4 5 6 254 195 254 181 230 181
21  
-	200 3 4 6 7 254 195 230 181 230 195
22  
-	200 3 7 6 5 230 195 230 181 254 181
23  
-	200 3 7 5 4 230 195 254 181 254 195
  9
+	6 0 -20
  10
+	6 0 20
  11
+POLYGONS 2
  12
+	200 3 3 2 1 254 194 229 194 229 181
  13
+	200 3 3 1 0 254 194 229 181 254 181
  14
+CONNECTORS 2
  15
+	1 2 0
  16
+	0 0 0
17  data/base/effects/fxtracer.pie
@@ -3,21 +3,14 @@ TYPE 200
3 3
 TEXTURE 0 page-21-fx.png 256 256
4 4
 LEVELS 1
5 5
 LEVEL 1
6  
-POINTS 8
7  
-	0 -2 7
8  
-	0 -2 -7
9  
-	0 2 -7
10  
-	0 2 7
  6
+POINTS 4
11 7
 	-2 0 7
12 8
 	-2 0 -7
13 9
 	2 0 -7
14 10
 	2 0 7
15  
-POLYGONS 8
16  
-	200 3 0 1 2 206 65 206 54 203 54
17  
-	200 3 0 2 3 206 65 203 54 203 65
  11
+POLYGONS 2
18 12
 	200 3 3 2 1 203 65 203 54 206 54
19 13
 	200 3 3 1 0 203 65 206 54 206 65
20  
-	200 3 4 5 6 206 65 206 54 203 54
21  
-	200 3 4 6 7 206 65 203 54 203 65
22  
-	200 3 7 6 5 203 65 203 54 206 54
23  
-	200 3 7 5 4 203 65 206 54 206 65
  14
+CONNECTORS 2
  15
+	1 1 0
  16
+	0 0 0
39  data/base/effects/fxtracer_twin.pie
... ...
@@ -1,39 +1,28 @@
1 1
 PIE 2
2 2
 TYPE 200
3 3
 TEXTURE 0 page-21-fx.png 256 256
4  
-LEVELS 1
  4
+LEVELS 2
5 5
 LEVEL 1
6  
-POINTS 16
7  
-	-9 -2 7
8  
-	-9 -2 -7
9  
-	-9 2 -7
10  
-	-9 2 7
  6
+POINTS 4
11 7
 	-11 0 7
12 8
 	-11 0 -7
13 9
 	-7 0 -7
14 10
 	-7 0 7
15  
-	9 -2 7
16  
-	9 -2 -7
17  
-	9 2 -7
18  
-	9 2 7
  11
+POLYGONS 2
  12
+	200 3 3 2 1 203 65 203 54 206 54
  13
+	200 3 3 1 0 203 65 206 54 206 65
  14
+CONNECTORS 2
  15
+	1 1 0
  16
+	-9 0 0
  17
+LEVEL 2
  18
+POINTS 4
19 19
 	7 0 7
20 20
 	7 0 -7
21 21
 	11 0 -7
22 22
 	11 0 7
23  
-POLYGONS 16
24  
-	200 3 0 1 2 206 65 206 54 203 54
25  
-	200 3 0 2 3 206 65 203 54 203 65
  23
+POLYGONS 2
26 24
 	200 3 3 2 1 203 65 203 54 206 54
27 25
 	200 3 3 1 0 203 65 206 54 206 65
28  
-	200 3 4 5 6 206 65 206 54 203 54
29  
-	200 3 4 6 7 206 65 203 54 203 65
30  
-	200 3 7 6 5 203 65 203 54 206 54
31  
-	200 3 7 5 4 203 65 206 54 206 65
32  
-	200 3 8 9 10 206 65 206 54 203 54
33  
-	200 3 8 10 11 206 65 203 54 203 65
34  
-	200 3 11 10 9 203 65 203 54 206 54
35  
-	200 3 11 9 8 203 65 206 54 206 65
36  
-	200 3 12 13 14 206 65 206 54 203 54
37  
-	200 3 12 14 15 206 65 203 54 203 65
38  
-	200 3 15 14 13 203 65 203 54 206 54
39  
-	200 3 15 13 12 203 65 206 54 206 65
  26
+CONNECTORS 2
  27
+	1 1 0
  28
+	9 0 0
17  data/base/effects/fxtracerh.pie
@@ -3,21 +3,14 @@ TYPE 200
3 3
 TEXTURE 0 page-21-fx.png 256 256
4 4
 LEVELS 1
5 5
 LEVEL 1
6  
-POINTS 8
7  
-	0 -2 14
8  
-	0 -2 -14
9  
-	0 2 -14
10  
-	0 2 14
  6
+POINTS 4
11 7
 	-2 0 14
12 8
 	-2 0 -14
13 9
 	2 0 -14
14 10
 	2 0 14
15  
-POLYGONS 8
16  
-	200 3 0 1 2 206 65 206 54 203 54
17  
-	200 3 0 2 3 206 65 203 54 203 65
  11
+POLYGONS 2
18 12
 	200 3 3 2 1 203 65 203 54 206 54
19 13
 	200 3 3 1 0 203 65 206 54 206 65
20  
-	200 3 4 5 6 206 65 206 54 203 54
21  
-	200 3 4 6 7 206 65 203 54 203 65
22  
-	200 3 7 6 5 203 65 203 54 206 54
23  
-	200 3 7 5 4 203 65 206 54 206 65
  14
+CONNECTORS 2
  15
+	1 1 0
  16
+	0 0 0
39  data/base/effects/fxtracr2.pie
... ...
@@ -1,39 +1,28 @@
1 1
 PIE 2
2 2
 TYPE 200
3 3
 TEXTURE 0 page-21-fx.png 256 256
4  
-LEVELS 1
  4
+LEVELS 2
5 5
 LEVEL 1
6  
-POINTS 16
7  
-	-9 -2 14
8  
-	-9 -2 -14
9  
-	-9 2 -14
10  
-	-9 2 14
  6
+POINTS 4
11 7
 	-11 0 14
12 8
 	-11 0 -14
13 9
 	-7 0 -14
14 10
 	-7 0 14
15  
-	9 -2 14
16  
-	9 -2 -14
17  
-	9 2 -14
18  
-	9 2 14
  11
+POLYGONS 2
  12
+	200 3 3 2 1 203 65 203 54 206 54
  13
+	200 3 3 1 0 203 65 206 54 206 65
  14
+CONNECTORS 2
  15
+	1 1 0
  16
+	-9 0 0
  17
+LEVEL 2
  18
+POINTS 4
19 19
 	7 0 14
20 20
 	7 0 -14
21 21
 	11 0 -14
22 22
 	11 0 14
23  
-POLYGONS 16
24  
-	200 3 0 1 2 206 65 206 54 203 54
25  
-	200 3 0 2 3 206 65 203 54 203 65
  23
+POLYGONS 2
26 24
 	200 3 3 2 1 203 65 203 54 206 54
27 25
 	200 3 3 1 0 203 65 206 54 206 65
28  
-	200 3 4 5 6 206 65 206 54 203 54
29  
-	200 3 4 6 7 206 65 203 54 203 65
30  
-	200 3 7 6 5 203 65 203 54 206 54
31  
-	200 3 7 5 4 203 65 206 54 206 65
32  
-	200 3 8 9 10 206 65 206 54 203 54
33  
-	200 3 8 10 11 206 65 203 54 203 65
34  
-	200 3 11 10 9 203 65 203 54 206 54
35  
-	200 3 11 9 8 203 65 206 54 206 65
36  
-	200 3 12 13 14 206 65 206 54 203 54
37  
-	200 3 12 14 15 206 65 203 54 203 65
38  
-	200 3 15 14 13 203 65 203 54 206 54
39  
-	200 3 15 13 12 203 65 206 54 206 65
  26
+CONNECTORS 2
  27
+	1 1 0
  28
+	9 0 0
23  data/mp/effects/fxshcana.pie
@@ -3,21 +3,14 @@ TYPE 200
3 3
 TEXTURE 0 page-21-fx.png 256 256
4 4
 LEVELS 1
5 5
 LEVEL 1
6  
-POINTS 8 
7  
-	0 -7 17 
8  
-	0 -7 -17 
9  
-	0 7 -17 
10  
-	0 7 17 
11  
-	-7 0 17 
12  
-	-7 0 -17 
13  
-	7 0 -17 
  6
+POINTS 4
  7
+	-7 0 17
  8
+	-7 0 -17
  9
+	7 0 -17
14 10
 	7 0 17
15  
-POLYGONS 8
16  
-	200 3 0 1 2 203 74 203 54 192 54
17  
-	200 3 0 2 3 203 74 192 54 192 74
  11
+POLYGONS 2
18 12
 	200 3 3 2 1 192 74 192 54 203 54
19 13
 	200 3 3 1 0 192 74 203 54 203 74
20  
-	200 3 4 5 6 203 74 203 54 192 54
21  
-	200 3 4 6 7 203 74 192 54 192 74
22  
-	200 3 7 6 5 192 74 192 54 203 54
23  
-	200 3 7 5 4 192 74 203 54 203 74
  14
+CONNECTORS 2
  15
+	1 1 0
  16
+	0 0 0
27  data/mp/effects/fxshgssa.pie
@@ -3,21 +3,14 @@ TYPE 200
3 3
 TEXTURE 0 page-18-fx.png 256 256
4 4
 LEVELS 1
5 5
 LEVEL 1
6  
-POINTS 8 
7  
-	0 7 17 
8  
-	0 7 -17 
9  
-	0 -7 -17 
10  
-	0 -7 17 
11  
-	-7 0 17 
12  
-	-7 0 -17 
13  
-	7 0 -17 
  6
+POINTS 4
  7
+	-7 0 17
  8
+	-7 0 -17
  9
+	7 0 -17
14 10
 	7 0 17
15  
-POLYGONS 8
16  
-	200 3 0 1 2 29 138 0 138 0 151
17  
-	200 3 0 2 3 29 138 0 151 29 151
18  
-	200 3 3 2 1 29 151 0 151 0 138
19  
-	200 3 3 1 0 29 151 0 138 29 138
20  
-	200 3 4 5 6 29 138 0 138 0 151
21  
-	200 3 4 6 7 29 138 0 151 29 151
22  
-	200 3 7 6 5 29 151 0 151 0 138
23  
-	200 3 7 5 4 29 151 0 138 29 138
  11
+POLYGONS 2
  12
+	200 3 3 2 1 28 137 -1 137 -1 150
  13
+	200 3 3 1 0 28 137 -1 150 28 150
  14
+CONNECTORS 2
  15
+	1 1 0
  16
+	0 0 0
86  src/display3d.cpp
@@ -135,6 +135,12 @@ void NotifyUserOfError(char *msg);
135 135
 /********************  Variables  ********************/
136 136
 // Should be cleaned up properly and be put in structures.
137 137
 
  138
+// Initialised at start of drawTiles().
  139
+// In model coordinates where x is east, y is up and z is north, rather than world coordinates where x is east, y is south and z is up.
  140
+// To get the real camera position, still need to add Vector3i(player.p.x, 0, player.p.z).
  141
+static Vector3i actualCameraPosition;
  142
+
  143
+
138 144
 bool	bRender3DOnly;
139 145
 static bool	bRangeDisplay = false;
140 146
 static SDWORD	rangeCenterX,rangeCenterY,rangeRadius;
@@ -308,6 +314,16 @@ static const int BLUEPRINT_OPACITY=120;
308 314
 
309 315
 /********************  Functions  ********************/
310 316
 
  317
+static inline void rotateSomething(int &x, int &y, uint16_t angle)
  318
+{
  319
+	int64_t cra = iCos(angle), sra = iSin(angle);
  320
+	int newX = (x*cra - y*sra)>>16;
  321
+	int newY = (x*sra + y*cra)>>16;
  322
+	x = newX;
  323
+	y = newY;
  324
+}
  325
+
  326
+
311 327
 void NotifyUserOfError(char *msg)
312 328
 {
313 329
 	errorWaiting = true;
@@ -950,20 +966,35 @@ static void drawTiles(iView *player)
950 966
 	/* Push identity matrix onto stack */
951 967
 	pie_MatBegin();
952 968
 
  969
+	actualCameraPosition = Vector3i(0, 0, 0);
  970
+
953 971
 	/* Set the camera position */
954 972
 	pie_TRANSLATE(0, 0, distance);
955 973
 
  974
+	actualCameraPosition.z -= distance;
  975
+
956 976
 	// Now, scale the world according to what resolution we're running in
957 977
 	pie_MatScale(pie_GetResScalingFactor() / 100.f);
958 978
 
  979
+	actualCameraPosition.z /= pie_GetResScalingFactor() / 100.f;
  980
+
959 981
 	/* Rotate for the player */
960 982
 	pie_MatRotZ(player->r.z);
961 983
 	pie_MatRotX(player->r.x);
962 984
 	pie_MatRotY(player->r.y);
963 985
 
  986
+	rotateSomething(actualCameraPosition.x, actualCameraPosition.y, -player->r.z);
  987
+	rotateSomething(actualCameraPosition.y, actualCameraPosition.z, -player->r.x);
  988
+	rotateSomething(actualCameraPosition.z, actualCameraPosition.x, -player->r.y);
  989
+
964 990
 	/* Translate */
965 991
 	pie_TRANSLATE(0, -player->p.y, 0);
966 992
 
  993
+	actualCameraPosition.y -= -player->p.y;
  994
+
  995
+	// Not sure if should do this here or whenever using, since this transform seems to be done all over the place.
  996
+	//actualCameraPosition -= Vector3i(-player->p.x, 0, player->p.z);
  997
+
967 998
 	// this also detemines the length of the shadows
968 999
 	theSun = getTheSun();
969 1000
 	pie_BeginLighting(&theSun, getDrawShadows());
@@ -1238,9 +1269,29 @@ void	renderProjectile(PROJECTILE *psCurr)
1238 1269
 	/*Need to draw the graphic depending on what the projectile is doing - hitting target,
1239 1270
 	missing target, in flight etc - JUST DO IN FLIGHT FOR NOW! */
1240 1271
 	pIMD = psStats->pInFlightGraphic;
  1272
+	//unsigned faceInFlight = psStats->faceInFlight;
1241 1273
 
1242 1274
 	if (clipXY(st.pos.x, st.pos.y))
  1275
+		for (; pIMD != NULL; pIMD = pIMD->next)
1243 1276
 	{
  1277
+		bool rollToCamera = false;
  1278
+		bool pitchToCamera = false;
  1279
+		bool additive = psStats->weaponSubClass == WSC_ROCKET || psStats->weaponSubClass == WSC_MISSILE || psStats->weaponSubClass == WSC_SLOWROCKET || psStats->weaponSubClass == WSC_SLOWMISSILE;
  1280
+
  1281
+		if (pIMD->nconnectors >= 2)
  1282
+		{
  1283
+			switch (pIMD->connectors[0].x)
  1284
+			{
  1285
+				case 1: rollToCamera = true; break;
  1286
+				case 2: rollToCamera = true; pitchToCamera = true; break;
  1287
+			}
  1288
+			switch (pIMD->connectors[0].y)
  1289
+			{
  1290
+				case 1: additive = false; break;
  1291
+				case 2: additive = true; break;
  1292
+			}
  1293
+		}
  1294
+
1244 1295
 		/* Get bullet's x coord */
1245 1296
 		dv.x = st.pos.x - player.p.x;
1246 1297
 
@@ -1251,20 +1302,51 @@ void	renderProjectile(PROJECTILE *psCurr)
1251 1302
 		dv.y = st.pos.z;
1252 1303
 		/* Set up the matrix */
1253 1304
 		pie_MatBegin();
  1305
+		Vector3i camera = actualCameraPosition;
1254 1306
 
1255 1307
 		/* Translate to the correct position */
1256 1308
 		pie_TRANSLATE(dv.x,dv.y,dv.z);
  1309
+		camera -= Vector3i(dv.x, dv.y, dv.z);
1257 1310
 
1258 1311
 		/* Rotate it to the direction it's facing */
1259 1312
 		imdRot2.y = st.rot.direction;
1260 1313
 		pie_MatRotY(-imdRot2.y);
  1314
+		rotateSomething(camera.z, camera.x, -(-imdRot2.y));
1261 1315
 
1262 1316
 		/* pitch it */
1263 1317
 		imdRot2.x = st.rot.pitch;
1264 1318
 		pie_MatRotX(imdRot2.x);
  1319
+		rotateSomething(camera.y, camera.z, -imdRot2.x);
  1320
+
  1321
+		if (pitchToCamera || rollToCamera)
  1322
+		{
  1323
+			// Centre on projectile (relevant for twin projectiles).
  1324
+			pie_TRANSLATE(pIMD->connectors[1].x, pIMD->connectors[1].y, pIMD->connectors[1].z);
  1325
+			camera -= Vector3i(pIMD->connectors[1].x, pIMD->connectors[1].y, pIMD->connectors[1].z);
  1326
+		}
  1327
+
  1328
+		if (pitchToCamera)
  1329
+		{
  1330
+			imdRot2.x = iAtan2(camera.z, camera.y);
  1331
+			pie_MatRotX(imdRot2.x);
  1332
+			rotateSomething(camera.y, camera.z, -imdRot2.x);
  1333
+		}
  1334
+
  1335
+		if (rollToCamera)
  1336
+		{
  1337
+			imdRot2.z = -iAtan2(camera.x, camera.y);
  1338
+			pie_MatRotZ(imdRot2.z);
  1339
+			rotateSomething(camera.x, camera.y, -imdRot2.z);
  1340
+		}
  1341
+
  1342
+		if (pitchToCamera || rollToCamera)
  1343
+		{
  1344
+			// Undo centre on projectile (relevant for twin projectiles).
  1345
+			pie_TRANSLATE(-pIMD->connectors[1].x, -pIMD->connectors[1].y, -pIMD->connectors[1].z);
  1346
+			camera -= Vector3i(-pIMD->connectors[1].x, -pIMD->connectors[1].y, -pIMD->connectors[1].z);
  1347
+		}
1265 1348
 
1266  
-		if (psStats->weaponSubClass == WSC_ROCKET || psStats->weaponSubClass == WSC_MISSILE
1267  
-		    || psStats->weaponSubClass == WSC_SLOWROCKET || psStats->weaponSubClass == WSC_SLOWMISSILE)
  1349
+		if (additive)
1268 1350
 		{
1269 1351
 			pie_Draw3DShape(pIMD, 0, 0, WZCOL_WHITE, pie_ADDITIVE, 164);
1270 1352
 		}
1  src/effects.cpp
@@ -1720,6 +1720,7 @@ static void renderExplosionEffect(const EFFECT *psEffect)
1720 1720
 	if(TEST_FACING(psEffect))
1721 1721
 	{
1722 1722
 		/* Always face the viewer! */
  1723
+		// TODO This only faces towards the viewer, if the effect is in the middle of the screen... It draws the effect parallel with the screens near/far planes.
1723 1724
 		pie_MatRotY(-player.r.y);
1724 1725
 		pie_MatRotX(-player.r.x);
1725 1726
 	}

No commit comments for this range

Something went wrong with that request. Please try again.