Maelstrom: Fixed a 10 year old bug: you get points from steel asteroids every time you hit them. (f092c)

https://github.com/libsdl-org/Maelstrom/commit/f092ccf4f0b3d27e336dc77772eacae421100e55

From f092ccf4f0b3d27e336dc77772eacae421100e55 Mon Sep 17 00:00:00 2001
From: Sam Lantinga <[EMAIL REDACTED]>
Date: Wed, 19 Jun 2013 01:20:02 -0700
Subject: [PATCH] Fixed a 10 year old bug: you get points from steel asteroids
 every time you hit them.

---
 netlogic/objects.h | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/netlogic/objects.h b/netlogic/objects.h
index 20e3c58e..cc7fb31d 100644
--- a/netlogic/objects.h
+++ b/netlogic/objects.h
@@ -500,6 +500,22 @@ class SteelRoid : public Object {
 	SteelRoid(int X, int Y, int xVel, int yVel);
 	~SteelRoid() { }
 
+	int BeenShot(Object *ship, Shot *shot) {
+        /* Every time we're hit, we grant points */
+        if ( (HitPoints - shot->damage) > 0 ) {
+            ship->IncrScore(Points);
+        }
+        return Object::BeenShot(ship, shot);
+    }
+
+	int BeenRunOver(Object *ship) {
+        /* Every time we're hit, we grant points */
+        if ( (HitPoints - 1) > 0 ) {
+            ship->IncrScore(Points);
+        }
+        return Object::BeenRunOver(ship);
+    }
+
 	int Explode(void) {
 		int newsprite;