1 #include "simulation/ElementCommon.h"
2 
3 int Element_VIRS_update(UPDATE_FUNC_ARGS);
4 static int graphics(GRAPHICS_FUNC_ARGS);
5 
Element_VRSG()6 void Element::Element_VRSG()
7 {
8 	Identifier = "DEFAULT_PT_VRSG";
9 	Name = "VRSG";
10 	Colour = PIXPACK(0xFE68FE);
11 	MenuVisible = 0;
12 	MenuSection = SC_GAS;
13 	Enabled = 1;
14 
15 	Advection = 1.0f;
16 	AirDrag = 0.01f * CFDS;
17 	AirLoss = 0.99f;
18 	Loss = 0.30f;
19 	Collision = -0.1f;
20 	Gravity = 0.0f;
21 	Diffusion = 0.75f;
22 	HotAir = 0.000f	* CFDS;
23 	Falldown = 0;
24 
25 	Flammable = 500;
26 	Explosive = 0;
27 	Meltable = 0;
28 	Hardness = 0;
29 
30 	Weight = 1;
31 
32 	DefaultProperties.temp = 522.0f + 273.15f;
33 	HeatConduct = 251;
34 	Description = "Gas Virus. Turns everything it touches into virus.";
35 
36 	Properties = TYPE_GAS|PROP_DEADLY;
37 
38 	LowPressure = IPL;
39 	LowPressureTransition = NT;
40 	HighPressure = IPH;
41 	HighPressureTransition = NT;
42 	LowTemperature = 673.0f;
43 	LowTemperatureTransition = PT_VIRS;
44 	HighTemperature = ITH;
45 	HighTemperatureTransition = NT;
46 
47 	DefaultProperties.pavg[1] = 250;
48 
49 	Update = &Element_VIRS_update;
50 	Graphics = &graphics;
51 }
52 
graphics(GRAPHICS_FUNC_ARGS)53 static int graphics(GRAPHICS_FUNC_ARGS)
54 {
55 	*pixel_mode &= ~PMODE;
56 	*pixel_mode |= FIRE_BLEND;
57 	*firer = *colr/2;
58 	*fireg = *colg/2;
59 	*fireb = *colb/2;
60 	*firea = 125;
61 	*pixel_mode |= NO_DECO;
62 	return 1;
63 }
64