diff options
author | Phillip <pacardon@u.washington.edu> | 2011-03-15 23:29:59 +0000 |
---|---|---|
committer | Phillip <pacardon@u.washington.edu> | 2011-03-15 23:29:59 +0000 |
commit | 65812af57a86bef6bfc82bf538a7a2de27eecfc5 (patch) | |
tree | 520cb13eeebe1ac6813b0f5cc8b25bbbccfba38b /src/common/CollidableObject.java | |
parent | ce4cfb6670eaba20e27f8c5f499980be59bf0853 (diff) |
Added failsafe remove in CollidableObject and World classes.
Increased the mass of the tank in TankMenuItem
ModifyableParticle now spawns 20 DyingParticles when it collides with something.
New Class DyingParticle, particle with a duration of 6 ticks.
Diffstat (limited to 'src/common/CollidableObject.java')
-rw-r--r-- | src/common/CollidableObject.java | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/common/CollidableObject.java b/src/common/CollidableObject.java index 0549335..2174e15 100644 --- a/src/common/CollidableObject.java +++ b/src/common/CollidableObject.java @@ -15,6 +15,7 @@ import com.sun.j3d.utils.geometry.Primitive; public abstract class CollidableObject implements Serializable {
private static final long serialVersionUID = 3667108226485766929L;
protected float inverseMass;
+ protected boolean detachMe = false;
// The center of mass in the local coordinate system
protected Vector3f centerOfMass;
protected Vector3f position, previousPosition;
@@ -110,6 +111,7 @@ public abstract class CollidableObject implements Serializable { public void detach() {
BG.detach();
+ detachMe = true;
}
public void updateState(float duration) {
@@ -596,4 +598,9 @@ public abstract class CollidableObject implements Serializable { }
return appearance;
}
+
+ public boolean removeMe() {
+ // TODO Auto-generated method stub
+ return detachMe;
+ }
}
|