1 | /********************************************************************** <BR>
|
---|
2 | This file is part of Crack dot Com's free source code release of
|
---|
3 | Golgotha. <a href="http://www.crack.com/golgotha_release"> <BR> for
|
---|
4 | information about compiling & licensing issues visit this URL</a>
|
---|
5 | <PRE> If that doesn't help, contact Jonathan Clark at
|
---|
6 | golgotha_source@usa.net (Subject should have "GOLG" in it)
|
---|
7 | ***********************************************************************/
|
---|
8 |
|
---|
9 | #include "g1_tint.hh"
|
---|
10 | #include "lisp/lisp.hh"
|
---|
11 | #include "lisp/li_init.hh"
|
---|
12 |
|
---|
13 | r1_color_tint_handle g1_player_tint_handles[G1_MAX_PLAYERS];
|
---|
14 |
|
---|
15 | g1_tint_struct g1_player_tint_data[G1_MAX_PLAYERS] =
|
---|
16 | {
|
---|
17 | { 1.0, 1.0, 1.0 }, // no tint (this entry is not actually used)
|
---|
18 | { 0.2, 1.0, 0.2 }, // green
|
---|
19 | { 1.0, 0.2, 0.2 }, // red
|
---|
20 | { 0.2, 0.2, 1.0 }, // blue
|
---|
21 | { 1.0, 1.0, 0.2 } // yellow
|
---|
22 | };
|
---|
23 |
|
---|
24 | g1_tint_struct g1_hurt_tint_data[G1_NUM_HURT_TINTS] =
|
---|
25 | {
|
---|
26 | { 1.0, 1.0, 1.0 },
|
---|
27 | { 1.0, 0.7, 0.7 },
|
---|
28 | { 1.0, 0.5, 0.5 },
|
---|
29 | { 1.0, 0.2, 0.2 },
|
---|
30 | { 1.0, 0.0, 0.0 }
|
---|
31 | };
|
---|
32 | r1_color_tint_handle g1_hurt_tint_handles[G1_NUM_HURT_TINTS];
|
---|
33 |
|
---|
34 | void g1_init_color_tints(r1_render_api_class *api)
|
---|
35 | {
|
---|
36 | int i;
|
---|
37 |
|
---|
38 | g1_player_tint_handles[0] = 0;
|
---|
39 | for (i=1; i<G1_MAX_PLAYERS; i++)
|
---|
40 | g1_player_tint_handles[i] = api->register_color_tint(g1_player_tint_data[i].r,
|
---|
41 | g1_player_tint_data[i].g,
|
---|
42 | g1_player_tint_data[i].b);
|
---|
43 |
|
---|
44 | g1_hurt_tint_handles[0] = 0;
|
---|
45 | for (i=1; i<G1_NUM_HURT_TINTS; i++)
|
---|
46 | g1_hurt_tint_handles[i] = api->register_color_tint(g1_hurt_tint_data[i].r,
|
---|
47 | g1_hurt_tint_data[i].g,
|
---|
48 | g1_hurt_tint_data[i].b);
|
---|
49 | }
|
---|
50 |
|
---|
51 | int g1_hurt_tint=0;
|
---|
52 | g1_tint_type g1_tint=G1_TINT_POLYS;
|
---|