From 160f65a15bdd7ae968eed506da6ee58324b76690 Mon Sep 17 00:00:00 2001 From: Steve Date: Sun, 13 Mar 2016 10:50:32 +0000 Subject: [PATCH] Added EF_NO_KILL_INC to prevent kill count increment. --- data/capitalShips/csnCorvette01.json | 38 ++++++++++++------------- data/capitalShips/csnCorvette02.json | 38 ++++++++++++------------- data/capitalShips/infCorvette01.json | 34 +++++++++++----------- data/capitalShips/infCorvette02.json | 40 +++++++++++++------------- data/capitalShips/unfCorvette01.json | 42 ++++++++++++++-------------- data/capitalShips/unfCorvette02.json | 40 +++++++++++++------------- src/battle/bullets.c | 2 +- src/battle/fighters.c | 7 +++-- src/defs.h | 1 + 9 files changed, 123 insertions(+), 119 deletions(-) diff --git a/data/capitalShips/csnCorvette01.json b/data/capitalShips/csnCorvette01.json index fe36e4c..afc1ee4 100644 --- a/data/capitalShips/csnCorvette01.json +++ b/data/capitalShips/csnCorvette01.json @@ -10,56 +10,56 @@ "texture" : "gfx/capitalShips/csnCorvette01/core.png", "x" : 0, "y" : -140, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 100, "texture" : "gfx/capitalShips/csnCorvette01/component1.png", "x" : 0, "y" : -200, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 100, "texture" : "gfx/capitalShips/csnCorvette01/component2.png", "x" : -34, "y" : 25, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 100, "texture" : "gfx/capitalShips/csnCorvette01/component2.png", "x" : 34, "y" : 25, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 100, "texture" : "gfx/capitalShips/csnCorvette01/component2.png", "x" : -16, "y" : 25, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 100, "texture" : "gfx/capitalShips/csnCorvette01/component2.png", "x" : 16, "y" : 25, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 100, "texture" : "gfx/capitalShips/csnCorvette01/component3.png", "x" : -23, "y" : 242, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 100, "texture" : "gfx/capitalShips/csnCorvette01/component3.png", "x" : 23, "y" : 242, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" } ], "engines" : [ @@ -68,35 +68,35 @@ "texture" : "gfx/capitalShips/csnCorvette01/engine1.png", "x" : -150, "y" : 293, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/csnCorvette01/engine1.png", "x" : 150, "y" : 293, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/csnCorvette01/engine1.png", "x" : -90, "y" : 293, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/csnCorvette01/engine1.png", "x" : 90, "y" : 293, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/csnCorvette01/engine1.png", "x" : 0, "y" : 296, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" } ], "guns" : [ @@ -107,7 +107,7 @@ "y" : 200, "reloadTime" : 10, "type" : "BT_PLASMA", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE", "missiles" : 9999 }, @@ -118,7 +118,7 @@ "y" : 200, "reloadTime" : 10, "type" : "BT_PLASMA", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE", "missiles" : 9999 }, @@ -129,7 +129,7 @@ "y" : 100, "reloadTime" : 10, "type" : "BT_PLASMA", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE", "missiles" : 9999 }, @@ -140,7 +140,7 @@ "y" : 100, "reloadTime" : 10, "type" : "BT_PLASMA", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE", "missiles" : 9999 }, @@ -151,7 +151,7 @@ "y" : -50, "reloadTime" : 40, "type" : "BT_ROCKET", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE", "missiles" : 9999 }, @@ -162,7 +162,7 @@ "y" : 175, "reloadTime" : 40, "type" : "BT_ROCKET", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE", "missiles" : 9999 } diff --git a/data/capitalShips/csnCorvette02.json b/data/capitalShips/csnCorvette02.json index f19b6e1..96fe100 100644 --- a/data/capitalShips/csnCorvette02.json +++ b/data/capitalShips/csnCorvette02.json @@ -10,49 +10,49 @@ "texture" : "gfx/capitalShips/csnCorvette02/core.png", "x" : 0, "y" : -140, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 100, "texture" : "gfx/capitalShips/csnCorvette02/component1.png", "x" : -105, "y" : 195, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 100, "texture" : "gfx/capitalShips/csnCorvette02/component1.png", "x" : 105, "y" : 195, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 100, "texture" : "gfx/capitalShips/csnCorvette02/component2.png", "x" : -25, "y" : 18, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 100, "texture" : "gfx/capitalShips/csnCorvette02/component3.png", "x" : 25, "y" : 18, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 100, "texture" : "gfx/capitalShips/csnCorvette02/component4.png", "x" : -67, "y" : -117, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 100, "texture" : "gfx/capitalShips/csnCorvette02/component5.png", "x" : 67, "y" : -117, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" } ], "engines" : [ @@ -61,28 +61,28 @@ "texture" : "gfx/capitalShips/csnCorvette02/engine1.png", "x" : -70, "y" : 253, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/csnCorvette02/engine2.png", "x" : -25, "y" : 247, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/csnCorvette02/engine2.png", "x" : 25, "y" : 247, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/csnCorvette02/engine1.png", "x" : 70, "y" : 253, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" } ], "guns" : [ @@ -93,7 +93,7 @@ "y" : -225, "reloadTime" : 40, "type" : "BT_ROCKET", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE", "missiles" : 9999 }, @@ -104,7 +104,7 @@ "y" : -60, "reloadTime" : 40, "type" : "BT_ROCKET", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE", "missiles" : 9999 }, @@ -115,7 +115,7 @@ "y" : -60, "reloadTime" : 40, "type" : "BT_ROCKET", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE", "missiles" : 9999 }, @@ -126,7 +126,7 @@ "y" : 70, "reloadTime" : 10, "type" : "BT_PLASMA", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE", "missiles" : 9999 }, @@ -137,7 +137,7 @@ "y" : 110, "reloadTime" : 10, "type" : "BT_PLASMA", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE", "missiles" : 9999 }, @@ -148,7 +148,7 @@ "y" : 110, "reloadTime" : 10, "type" : "BT_PLASMA", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE", "missiles" : 9999 }, @@ -159,7 +159,7 @@ "y" : 240, "reloadTime" : 10, "type" : "BT_PLASMA", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE", "missiles" : 9999 }, @@ -170,7 +170,7 @@ "y" : 240, "reloadTime" : 10, "type" : "BT_PLASMA", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE", "missiles" : 9999 } diff --git a/data/capitalShips/infCorvette01.json b/data/capitalShips/infCorvette01.json index dcc575e..3076e2a 100644 --- a/data/capitalShips/infCorvette01.json +++ b/data/capitalShips/infCorvette01.json @@ -10,56 +10,56 @@ "texture" : "gfx/capitalShips/infCorvette01/component1.png", "x" : -27, "y" : 100, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/infCorvette01/component2.png", "x" : 27, "y" : 100, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/infCorvette01/component3.png", "x" : 20, "y" : -17, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/infCorvette01/component3.png", "x" : -20, "y" : -17, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/infCorvette01/component4.png", "x" : -21, "y" : -64, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/infCorvette01/component5.png", "x" : 21, "y" : -64, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/infCorvette01/component6.png", "x" : -22, "y" : -243, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/infCorvette01/component6.png", "x" : 22, "y" : -243, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" } ], "engines" : [ @@ -68,21 +68,21 @@ "texture" : "gfx/capitalShips/infCorvette01/engine1.png", "x" : -50, "y" : 285, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/infCorvette01/engine1.png", "x" : 50, "y" : 285, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/infCorvette01/engine2.png", "x" : 0, "y" : 280, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" } ], "guns" : [ @@ -93,7 +93,7 @@ "y" : 170, "reloadTime" : 10, "type" : "BT_PLASMA", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE", "missiles" : 9999 }, @@ -104,7 +104,7 @@ "y" : -150, "reloadTime" : 10, "type" : "BT_PLASMA", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE", "missiles" : 9999 }, @@ -115,7 +115,7 @@ "y" : 50, "reloadTime" : 10, "type" : "BT_PLASMA", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE" }, { @@ -125,7 +125,7 @@ "y" : 50, "reloadTime" : 10, "type" : "BT_PLASMA", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE" }, { @@ -135,7 +135,7 @@ "y" : -60, "reloadTime" : 40, "type" : "BT_ROCKET", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE" }, { @@ -145,7 +145,7 @@ "y" : -60, "reloadTime" : 40, "type" : "BT_ROCKET", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE" } ] diff --git a/data/capitalShips/infCorvette02.json b/data/capitalShips/infCorvette02.json index da38ba1..b240440 100644 --- a/data/capitalShips/infCorvette02.json +++ b/data/capitalShips/infCorvette02.json @@ -10,63 +10,63 @@ "texture" : "gfx/capitalShips/infCorvette02/core.png", "x" : 0, "y" : -80, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/infCorvette02/component1.png", "x" : -32, "y" : -75, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/infCorvette02/component1.png", "x" : 32, "y" : -75, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/infCorvette02/component2.png", "x" : -95, "y" : 195, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/infCorvette02/component2.png", "x" : 95, "y" : 195, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/infCorvette02/component3.png", "x" : -30, "y" : 210, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/infCorvette02/component3.png", "x" : 30, "y" : 210, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/infCorvette02/component4.png", "x" : -24, "y" : -20, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/infCorvette02/component4.png", "x" : 24, "y" : -20, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" } ], "guns" : [ @@ -77,7 +77,7 @@ "y" : 200, "reloadTime" : 10, "type" : "BT_PLASMA", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE", "missiles" : 9999 }, @@ -88,7 +88,7 @@ "y" : 200, "reloadTime" : 10, "type" : "BT_PLASMA", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE", "missiles" : 9999 }, @@ -99,7 +99,7 @@ "y" : 200, "reloadTime" : 10, "type" : "BT_PLASMA", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE", "missiles" : 9999 }, @@ -110,7 +110,7 @@ "y" : 0, "reloadTime" : 10, "type" : "BT_PLASMA", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE", "missiles" : 9999 }, @@ -121,7 +121,7 @@ "y" : 100, "reloadTime" : 10, "type" : "BT_PLASMA", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE", "missiles" : 9999 }, @@ -132,7 +132,7 @@ "y" : -125, "reloadTime" : 40, "type" : "BT_ROCKET", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE", "missiles" : 9999 }, @@ -143,7 +143,7 @@ "y" : -125, "reloadTime" : 40, "type" : "BT_ROCKET", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE", "missiles" : 9999 } @@ -154,28 +154,28 @@ "texture" : "gfx/capitalShips/infCorvette02/engine1.png", "x" : -75, "y" : 275, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/infCorvette02/engine2.png", "x" : -20, "y" : 275, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/infCorvette02/engine3.png", "x" : 20, "y" : 275, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/infCorvette02/engine4.png", "x" : 75, "y" : 275, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" } ] } diff --git a/data/capitalShips/unfCorvette01.json b/data/capitalShips/unfCorvette01.json index bf5eb3d..f5f6011 100644 --- a/data/capitalShips/unfCorvette01.json +++ b/data/capitalShips/unfCorvette01.json @@ -10,63 +10,63 @@ "texture" : "gfx/capitalShips/unfCorvette01/core.png", "x" : 0, "y" : -100, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 50, "texture" : "gfx/capitalShips/unfCorvette01/component1.png", "x" : -42, "y" : -36, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 50, "texture" : "gfx/capitalShips/unfCorvette01/component1.png", "x" : 42, "y" : -36, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 50, "texture" : "gfx/capitalShips/unfCorvette01/component2.png", "x" : -40, "y" : -8, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 50, "texture" : "gfx/capitalShips/unfCorvette01/component2.png", "x" : 40, "y" : -8, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 50, "texture" : "gfx/capitalShips/unfCorvette01/component3.png", "x" : -40, "y" : 68, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 50, "texture" : "gfx/capitalShips/unfCorvette01/component4.png", "x" : 40, "y" : 68, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 50, "texture" : "gfx/capitalShips/unfCorvette01/component5.png", "x" : -40, "y" : 128, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 50, "texture" : "gfx/capitalShips/unfCorvette01/component5.png", "x" : 40, "y" : 128, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" } ], "engines" : [ @@ -75,28 +75,28 @@ "texture" : "gfx/capitalShips/unfCorvette01/engine1.png", "x" : -112, "y" : 281, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/unfCorvette01/engine1.png", "x" : 112, "y" : 281, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/unfCorvette01/engine2.png", "x" : -34, "y" : 268, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/unfCorvette01/engine2.png", "x" : 34, "y" : 268, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" } ], "guns" : [ @@ -107,7 +107,7 @@ "y" : -250, "reloadTime" : 40, "type" : "BT_ROCKET", - "flags" : "EF_TAKES_DAMAGE+EF_STATIC+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE", "missiles" : 9999 }, @@ -118,7 +118,7 @@ "y" : -250, "reloadTime" : 40, "type" : "BT_ROCKET", - "flags" : "EF_TAKES_DAMAGE+EF_STATIC+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE", "missiles" : 9999 }, @@ -129,7 +129,7 @@ "y" : 20, "reloadTime" : 10, "type" : "BT_PLASMA", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE" }, { @@ -139,7 +139,7 @@ "y" : 20, "reloadTime" : 10, "type" : "BT_PLASMA", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE" }, { @@ -149,7 +149,7 @@ "y" : 100, "reloadTime" : 10, "type" : "BT_PLASMA", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE", "missiles" : 9999 }, @@ -160,7 +160,7 @@ "y" : 100, "reloadTime" : 10, "type" : "BT_PLASMA", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE", "missiles" : 9999 }, @@ -171,7 +171,7 @@ "y" : 180, "reloadTime" : 10, "type" : "BT_PLASMA", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE" }, { @@ -181,7 +181,7 @@ "y" : 180, "reloadTime" : 10, "type" : "BT_PLASMA", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE" } ] diff --git a/data/capitalShips/unfCorvette02.json b/data/capitalShips/unfCorvette02.json index 911a837..5ce4d6e 100644 --- a/data/capitalShips/unfCorvette02.json +++ b/data/capitalShips/unfCorvette02.json @@ -10,49 +10,49 @@ "texture" : "gfx/capitalShips/unfCorvette01/core.png", "x" : 0, "y" : -100, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 50, "texture" : "gfx/capitalShips/unfCorvette02/component1.png", "x" : -22, "y" : -24, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 50, "texture" : "gfx/capitalShips/unfCorvette02/component1.png", "x" : 22, "y" : -24, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 50, "texture" : "gfx/capitalShips/unfCorvette02/component2.png", "x" : -86, "y" : 188, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 50, "texture" : "gfx/capitalShips/unfCorvette02/component2.png", "x" : 86, "y" : 188, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 50, "texture" : "gfx/capitalShips/unfCorvette02/component3.png", "x" : -43, "y" : 151, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 50, "texture" : "gfx/capitalShips/unfCorvette02/component3.png", "x" : 43, "y" : 151, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" } ], "engines" : [ @@ -61,28 +61,28 @@ "texture" : "gfx/capitalShips/unfCorvette02/engine1.png", "x" : -100, "y" : 286, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/unfCorvette02/engine1.png", "x" : 100, "y" : 286, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/unfCorvette02/engine2.png", "x" : -35, "y" : 289, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" }, { "health" : 150, "texture" : "gfx/capitalShips/unfCorvette02/engine2.png", "x" : 35, "y" : 289, - "flags" : "EF_TAKES_DAMAGE+EF_STATIC" + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC" } ], "guns" : [ @@ -93,7 +93,7 @@ "y" : -250, "reloadTime" : 40, "type" : "BT_ROCKET", - "flags" : "EF_TAKES_DAMAGE+EF_STATIC+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE", "missiles" : 9999 }, @@ -104,7 +104,7 @@ "y" : 30, "reloadTime" : 40, "type" : "BT_ROCKET", - "flags" : "EF_TAKES_DAMAGE+EF_STATIC+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE", "missiles" : 9999 }, @@ -115,7 +115,7 @@ "y" : 30, "reloadTime" : 40, "type" : "BT_ROCKET", - "flags" : "EF_TAKES_DAMAGE+EF_STATIC+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_STATIC+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE", "missiles" : 9999 }, @@ -126,7 +126,7 @@ "y" : 30, "reloadTime" : 10, "type" : "BT_PLASMA", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE" }, { @@ -136,7 +136,7 @@ "y" : -70, "reloadTime" : 10, "type" : "BT_PLASMA", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE" }, { @@ -146,7 +146,7 @@ "y" : -70, "reloadTime" : 10, "type" : "BT_PLASMA", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE" }, { @@ -156,7 +156,7 @@ "y" : 170, "reloadTime" : 10, "type" : "BT_PLASMA", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE" }, { @@ -166,7 +166,7 @@ "y" : 210, "reloadTime" : 10, "type" : "BT_PLASMA", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE" }, { @@ -176,7 +176,7 @@ "y" : 210, "reloadTime" : 10, "type" : "BT_PLASMA", - "flags" : "EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", + "flags" : "EF_NO_KILL_INC+EF_TAKES_DAMAGE+EF_SECONDARY_TARGET", "aiFlags" : "AIF_AGGRESSIVE+AIF_LONG_RANGE_FIRE" } ] diff --git a/src/battle/bullets.c b/src/battle/bullets.c index d7e233f..ef11737 100644 --- a/src/battle/bullets.c +++ b/src/battle/bullets.c @@ -203,7 +203,7 @@ static void checkCollisions(Bullet *b) } /* assuming that health <= 0 will always mean killed */ - if (e->health <= 0 && b->owner == player) + if (e->health <= 0 && b->owner == player && (!(e->flags & EF_NO_KILL_INC))) { battle.stats[STAT_ENEMIES_KILLED_PLAYER]++; battle.stats[STAT_EPIC_KILL_STREAK]++; diff --git a/src/battle/fighters.c b/src/battle/fighters.c index 7c8ec45..01fb800 100644 --- a/src/battle/fighters.c +++ b/src/battle/fighters.c @@ -321,9 +321,12 @@ void doFighter(void) { if (self->side != SIDE_ALLIES) { - battle.stats[STAT_ENEMIES_KILLED]++; + if (!(self->flags & EF_NO_KILL_INC)) + { + battle.stats[STAT_ENEMIES_KILLED]++; - runScriptFunction("ENEMIES_KILLED %d", battle.stats[STAT_ENEMIES_KILLED]); + runScriptFunction("ENEMIES_KILLED %d", battle.stats[STAT_ENEMIES_KILLED]); + } } else { diff --git a/src/defs.h b/src/defs.h index eed8c23..0006108 100644 --- a/src/defs.h +++ b/src/defs.h @@ -96,6 +96,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #define EF_AI_TARGET (2 << 13) #define EF_AI_LEADER (2 << 14) #define EF_ROPED_ATTACHED (2 << 15) +#define EF_NO_KILL_INC (2 << 16) #define AIF_NONE 0 #define AIF_FOLLOWS_PLAYER (2 << 0)