From 6d465b207de473a75855faeddd7181f902ab0a9d Mon Sep 17 00:00:00 2001 From: Catelite Date: Tue, 5 Jun 2012 16:47:29 -0400 Subject: [PATCH] omg EXOT element, made from BREL element sparked repeatedly while under >10 pressure. Not at all finished, but looks cool :D --- includes/powder.h | 4 ++++ src/elementdata.c | 8 ++++---- src/powder.c | 3 +++ 3 files changed, 11 insertions(+), 4 deletions(-) diff --git a/includes/powder.h b/includes/powder.h index 5a663408a..1ba63d5e5 100644 --- a/includes/powder.h +++ b/includes/powder.h @@ -220,6 +220,7 @@ #define PT_GEL 142 #define PT_TRON 143 #define PT_TTAN 144 +#define PT_EXOT 145 #define OLD_PT_WIND 147 #define PT_H2 148 @@ -350,6 +351,7 @@ int graphics_DCEL(GRAPHICS_FUNC_ARGS); int graphics_GEL(GRAPHICS_FUNC_ARGS); int graphics_TRON(GRAPHICS_FUNC_ARGS); int graphics_SOAP(GRAPHICS_FUNC_ARGS); +int graphics_EXOT(GRAPHICS_FUNC_ARGS); int graphics_stickmen(GRAPHICS_FUNC_ARGS); void TRON_init_graphics(); @@ -471,6 +473,8 @@ int update_FRAY(UPDATE_FUNC_ARGS); int update_REPL(UPDATE_FUNC_ARGS); int update_TRON(UPDATE_FUNC_ARGS); int update_TTAN(UPDATE_FUNC_ARGS); +int update_BREL(UPDATE_FUNC_ARGS); +int update_EXOT(UPDATE_FUNC_ARGS); int update_MISC(UPDATE_FUNC_ARGS); int update_legacy_PYRO(UPDATE_FUNC_ARGS); diff --git a/src/elementdata.c b/src/elementdata.c index cf2538728..0d6890068 100644 --- a/src/elementdata.c +++ b/src/elementdata.c @@ -166,7 +166,7 @@ part_type ptypes[PT_NUM] = {"QRTZ", PIXPACK(0xAADDDD), 0.0f, 0.00f * CFDS, 0.90f, 0.00f, 0.0f, 0.0f, 0.00f, 0.000f * CFDS, 0, 0, 0, 0, 0, 1, 1, 100, SC_SOLIDS, R_TEMP+0.0f +273.15f, 3, "Quartz, breakable mineral. Conducts but becomes brittle at lower temperatures.", ST_SOLID, TYPE_SOLID|PROP_HOT_GLOW|PROP_LIFE_DEC, &update_QRTZ, &graphics_QRTZ}, {"PQRT", PIXPACK(0x88BBBB), 0.4f, 0.04f * CFDS, 0.94f, 0.95f, -0.1f, 0.27f, 0.00f, 0.000f * CFDS, 1, 0, 0, 0, 0, 1, 1, 90, SC_POWDERS, R_TEMP+0.0f +273.15f, 3, "Broken quartz.", ST_SOLID, TYPE_PART| PROP_HOT_GLOW, &update_QRTZ, &graphics_QRTZ}, {"EMP", PIXPACK(0x66AAFF), 0.0f, 0.00f * CFDS, 0.90f, 0.00f, 0.0f, 0.0f, 0.0f, 0.0f * CFDS, 0, 0, 0, 0, 3, 1, 1, 100, SC_ELEC, R_TEMP+0.0f +273.15f, 121, "Breaks activated electronics.", ST_SOLID, TYPE_SOLID|PROP_LIFE_DEC, &update_EMP, &graphics_EMP}, - {"BREL", PIXPACK(0x707060), 0.4f, 0.04f * CFDS, 0.94f, 0.95f, -0.1f, 0.18f, 0.00f, 0.000f * CFDS, 1, 0, 0, 2, 2, 1, 1, 90, SC_POWDERS, R_TEMP+0.0f +273.15f, 211, "Broken electronics", ST_SOLID, TYPE_PART|PROP_CONDUCTS|PROP_LIFE_DEC|PROP_HOT_GLOW, NULL, NULL}, + {"BREL", PIXPACK(0x707060), 0.4f, 0.04f * CFDS, 0.94f, 0.95f, -0.1f, 0.18f, 0.00f, 0.000f * CFDS, 1, 0, 0, 2, 2, 1, 1, 90, SC_POWDERS, R_TEMP+0.0f +273.15f, 211, "Broken electronics", ST_SOLID, TYPE_PART|PROP_CONDUCTS|PROP_LIFE_DEC|PROP_HOT_GLOW, &update_BREL, NULL}, {"ELEC", PIXPACK(0xDFEFFF), 0.0f, 0.00f * CFDS, 1.00f, 1.00f, -0.99f, 0.0f, 0.00f, 0.000f * CFDS, 0, 0, 0, 0, 0, 1, 1, -1, SC_NUCLEAR, R_TEMP+200.0f+273.15f, 251, "Electrons", ST_GAS, TYPE_ENERGY|PROP_LIFE_DEC|PROP_LIFE_KILL_DEC, &update_ELEC, &graphics_ELEC}, {"ACEL", PIXPACK(0x0099CC), 0.0f, 0.00f * CFDS, 0.90f, 0.00f, 0.0f, 0.0f, 0.00f, 0.000f * CFDS, 0, 0, 0, 0, 1, 1, 1, 100, SC_FORCE, R_TEMP+0.0f +273.15f, 251, "Accelerator", ST_NONE, TYPE_SOLID, &update_ACEL, &graphics_ACEL}, {"DCEL", PIXPACK(0x99CC00), 0.0f, 0.00f * CFDS, 0.90f, 0.00f, 0.0f, 0.0f, 0.00f, 0.000f * CFDS, 0, 0, 0, 0, 1, 1, 1, 100, SC_FORCE, R_TEMP+0.0f +273.15f, 251, "Decelerator", ST_NONE, TYPE_SOLID, &update_DCEL, &graphics_DCEL}, @@ -176,7 +176,7 @@ part_type ptypes[PT_NUM] = {"GEL", PIXPACK(0xFF9900), 0.6f, 0.01f * CFDS, 0.98f, 0.95f, 0.0f, 0.1f, 0.00f, 0.000f * CFDS, 2, 0, 0, 0, 20, 1, 1, 35, SC_LIQUID, R_TEMP-2.0f +273.15f, 29, "Gel. A liquid with variable viscosity and heat conductivity", ST_LIQUID, TYPE_LIQUID|PROP_LIFE_DEC|PROP_NEUTPENETRATE, &update_GEL, &graphics_GEL}, {"TRON", PIXPACK(0x000000), 0.0f, 0.00f * CFDS, 0.90f, 0.00f, 0.0f, 0.0f, 0.00f, 0.000f * CFDS, 0, 0, 0, 0, 0, 1, 1, 100, SC_SPECIAL, 0.0f, 40, "Smart particles, Travels in straight lines and avoids obstacles. Grows with time.", ST_NONE, TYPE_SOLID|PROP_LIFE_DEC|PROP_LIFE_KILL, &update_TRON, &graphics_TRON}, {"TTAN", PIXPACK(0x909090), 0.0f, 0.00f * CFDS, 0.90f, 0.00f, 0.0f, 0.0f, 0.00f, 0.000f * CFDS, 0, 0, 0, 1, 50, 1, 1, 100, SC_SOLIDS, R_TEMP+0.0f +273.15f, 251, "Titanium, Higher melting temperature than other metals, blocks all air pressure", ST_SOLID, TYPE_SOLID|PROP_CONDUCTS|PROP_HOT_GLOW|PROP_LIFE_DEC, &update_TTAN, NULL}, - /*FREE*/{"FROG", PIXPACK(0x00AA00), 0.0f, 0.00f * CFDS, 0.90f, 0.00f, 0.0f, 0.0f, 0.00f, 0.000f * CFDS, 0, 0, 0, 0, 0, 0, 0, 100, SC_LIFE, 9000.0f, 40, "Frogs S12/B34/3", ST_NONE, TYPE_SOLID|PROP_LIFE, NULL, NULL}, + {"EXOT", PIXPACK(0x808080), 0.3f, 0.02f * CFDS, 0.95f, 0.80f, 0.0f, 0.15f, 0.00f, 0.0003f * CFDS, 2, 0, 0, 0, 2, 1, 1, 45, SC_NUCLEAR, R_TEMP-2.0f +273.15f, 29, "Radioactive liquid", ST_LIQUID, TYPE_LIQUID|PROP_NEUTPENETRATE, &update_EXOT, &graphics_EXOT}, /*FREE*/{"BRAN", PIXPACK(0xCCCC00), 0.0f, 0.00f * CFDS, 0.90f, 0.00f, 0.0f, 0.0f, 0.00f, 0.000f * CFDS, 0, 0, 0, 0, 0, 0, 0, 100, SC_LIFE, 9000.0f, 40, "Brian 6 S6/B246/3", ST_NONE, TYPE_SOLID|PROP_LIFE, NULL, NULL}, /*FREE*/{"WIND", PIXPACK(0x101010), 0.0f, 0.00f * CFDS, 0.90f, 0.00f, 0.0f, 0.0f, 0.00f, 0.000f * CFDS, 0, 0, 0, 0, 0, 0, 0, 100, SC_SPECIAL, 0.0f, 40, "", ST_NONE, ST_NONE, NULL, NULL}, {"HYGN", PIXPACK(0x5070FF), 2.0f, 0.00f * CFDS, 0.99f, 0.30f, -0.10f, 0.00f, 3.00f, 0.000f * CFDS, 0, 0, 0, 0, 0, 1, 1, 1, SC_GAS, R_TEMP+0.0f +273.15f, 251, "Combines with O2 to make WATR", ST_GAS, TYPE_GAS, &update_H2, NULL}, @@ -352,7 +352,7 @@ part_transition ptransitions[PT_NUM] = /* GEL */ {IPL, NT, IPH, NT, ITL, NT, ITH, NT}, /* TRON */ {IPL, NT, IPH, NT, ITL, NT, ITH, NT}, /* TTAN */ {IPL, NT, IPH, NT, ITL, NT, 1941.0f,PT_LAVA}, - /*FREE*//* GOL */ {IPL, NT, IPH, NT, ITL, NT, ITH, NT}, + /* EXOT */ {IPL, NT, IPH, NT, ITL, NT, ITH, NT}, /*FREE*//* GOL */ {IPL, NT, IPH, NT, ITL, NT, ITH, NT}, /* WIND */ {IPL, NT, IPH, NT, ITL, NT, ITH, NT}, /* H2 */ {IPL, NT, IPH, NT, ITL, NT, ITH, NT}, @@ -517,7 +517,7 @@ unsigned int platent[PT_NUM] = /* IGNP */ 0, /* BOYL */ 0, /* GEL */ 0, - /* FREE */ 0, + /* EXOT */ 0, /* FREE */ 0, /* FREE */ 0, /* FREE */ 0, diff --git a/src/powder.c b/src/powder.c index c054d9341..f9545255c 100644 --- a/src/powder.c +++ b/src/powder.c @@ -1022,6 +1022,9 @@ inline int create_part(int p, int x, int y, int tv)//the function for creating a case PT_MORT: parts[i].vx = 2; break; + case PT_EXOT: + parts[i].life = 250; + break; case PT_STKM: if (player.spwn==0) {