Index: /code/branches/invaders/data/levels/templates/enemyInvader.oxt
===================================================================
--- /code/branches/invaders/data/levels/templates/enemyInvader.oxt	(revision 9853)
+++ /code/branches/invaders/data/levels/templates/enemyInvader.oxt	(revision 9854)
@@ -7,7 +7,7 @@
    explosionchunks        = 4
 
-   health            = 1
-   maxhealth         = 1
-   initialhealth     = 1
+   health            = 100
+   maxhealth         = 100
+   initialhealth     = 100
 
    shieldhealth        = 35
@@ -46,7 +46,11 @@
     </engines>
     <attached>
-      <Model position="0,0,0" yaw=90 pitch=0 roll=0 scale=8 mesh="escortShip.mesh" />
-      <Model position="0,0,0" yaw=180 pitch=90 roll=0 scale=8 mesh="escortWeapon.mesh" />
+      <Model position="0,0,0" yaw=180 pitch=270 roll=0 scale=2 mesh="swallow_mat.mesh" />
+      <Model position="0,0,0" yaw=180 pitch=270 roll=0 scale=2 mesh="escortWeapon.mesh" />
 <!--Model mesh="cube.mesh" mass=10 position="0,0,3" scale3D="10,4,8" />
+
+swallow_mat.mesh
+"ghost.mesh"
+
 <Model mesh="cube.mesh" mass=10 position="12.6,-2,3" scale3D="2.8,2.8,11" />
 <Model mesh="cube.mesh" mass=10 position="-12.6,-2,3" scale3D="2.8,2.8,11" />
Index: /code/branches/invaders/data/overlays/InvaderHUD.oxo
===================================================================
--- /code/branches/invaders/data/overlays/InvaderHUD.oxo	(revision 9853)
+++ /code/branches/invaders/data/overlays/InvaderHUD.oxo	(revision 9854)
@@ -68,4 +68,25 @@
      showpoints     = true
     />
+
+
+    <OverlayText
+     position  = "0.4, 0.1"
+     pickpoint = "0.0, 0.0"
+     font      = "ShareTechMono"
+     textsize  = 0.04
+     colour    = "1.0, 1.0, 1.0, 1.0"
+     align     = "left"
+     caption   = "X"
+    />
+    <InvaderHUDinfo
+     position  = "0.42, 0.1"
+     pickpoint = "0.0, 0.0"
+     font      = "ShareTechMono"
+     textsize  = 0.04
+     colour    = "1.0, 1.0, 1.0, 1.0"
+     align     = "left"
+
+     showMultiplier = true
+    />
   </OverlayGroup>
 </Template>
Index: /code/branches/invaders/src/modules/invader/Invader.cc
===================================================================
--- /code/branches/invaders/src/modules/invader/Invader.cc	(revision 9853)
+++ /code/branches/invaders/src/modules/invader/Invader.cc	(revision 9854)
@@ -87,9 +87,12 @@
             return;
 
-        for (int i = 0; i < level; i++)
+        srand(player->getPosition().x + player->getPosition().y);
+        for (int i = 0; i < level * 2; i++)
         {
-            SmartPtr<InvaderEnemy> newPawn = new InvaderEnemy(this->center_->getContext());
+            WeakPtr<InvaderEnemy> newPawn = new InvaderEnemy(this->center_->getContext());
             newPawn->addTemplate("enemyinvader");
-            newPawn->setPosition(player->getPosition() + Vector3(500 + 100 * i, 0, 0));
+            newPawn->setPlayer(player);
+            newPawn->level = level;
+            newPawn->setPosition(player->getPosition() + Vector3(500 + 100 * i, 0, float(rand())/RAND_MAX * 400 - 200));
         }
     }
Index: /code/branches/invaders/src/modules/invader/Invader.h
===================================================================
--- /code/branches/invaders/src/modules/invader/Invader.h	(revision 9853)
+++ /code/branches/invaders/src/modules/invader/Invader.h	(revision 9854)
@@ -66,4 +66,5 @@
             int getLevel(){return this->level;}
             int getPoints(){return this->point;}
+            int getMultiplier(){return this->multiplier;}
 
             void costLife(){lives--; if (lives <= 0) end();};
Index: /code/branches/invaders/src/modules/invader/InvaderEnemy.cc
===================================================================
--- /code/branches/invaders/src/modules/invader/InvaderEnemy.cc	(revision 9853)
+++ /code/branches/invaders/src/modules/invader/InvaderEnemy.cc	(revision 9854)
@@ -44,9 +44,23 @@
         RegisterObject(InvaderEnemy);
         enableCollisionCallback();
+        lifetime = 0;
     }
 
     void InvaderEnemy::tick(float dt)
     {
-        setVelocity(Vector3(500 ,0, 0));
+        lifetime += dt;
+        if (lifetime > 5000)
+        {
+            removeHealth(2000);
+        }
+        if (player != NULL)
+        {
+            float newZ = player->getPosition().z - getPosition().z;
+            if (newZ < 0)
+                newZ = (-100 < newZ)?-100:newZ;
+            else
+                newZ = (100 > newZ)?100:newZ;
+            setVelocity(Vector3(1000 - level * 100 , 0, newZ));
+        }
         SUPER(InvaderEnemy, tick, dt);
     }
@@ -54,5 +68,5 @@
     inline bool InvaderEnemy::collidesAgainst(WorldEntity* otherObject, btManifoldPoint& contactPoint)
     {
-        setVelocity(Vector3(900,0,0));
+        setVelocity(Vector3(1000,0,0));
         removeHealth(2000);
         return false;
Index: /code/branches/invaders/src/modules/invader/InvaderEnemy.h
===================================================================
--- /code/branches/invaders/src/modules/invader/InvaderEnemy.h	(revision 9853)
+++ /code/branches/invaders/src/modules/invader/InvaderEnemy.h	(revision 9854)
@@ -50,12 +50,16 @@
             virtual bool collidesAgainst(WorldEntity* otherObject, btManifoldPoint& contactPoint);
             virtual void damage(float damage, float healthdamage, float shielddamage, Pawn* originator);
+            virtual void setPlayer(WeakPtr<InvaderShip> player){this->player = player;}
 
+            int level;
         private:
             WeakPtr<Invader> getGame();
             WeakPtr<Invader> game;
+            WeakPtr<InvaderShip> player;
             Camera* camera;
             bool isFireing;
             float speed, damping;
             float lastTimeFront, lastTimeLeft;
+            float lifetime;
             struct Velocity
             {
Index: /code/branches/invaders/src/modules/invader/InvaderHUDinfo.cc
===================================================================
--- /code/branches/invaders/src/modules/invader/InvaderHUDinfo.cc	(revision 9853)
+++ /code/branches/invaders/src/modules/invader/InvaderHUDinfo.cc	(revision 9854)
@@ -44,4 +44,5 @@
         this->bShowLevel_ = false;
         this->bShowPoints_ = false;
+        this->bShowMultiplier_ = false;
     }
 
@@ -57,4 +58,5 @@
         XMLPortParam(InvaderHUDinfo, "showPoints",     setShowPoints,     getShowPoints,     xmlelement, mode).defaultValues(false);
         XMLPortParam(InvaderHUDinfo, "showLevel",     setShowLevel,     getShowLevel,     xmlelement, mode).defaultValues(false);
+        XMLPortParam(InvaderHUDinfo, "showMultiplier",     setShowMultiplier,     getShowMultiplier,     xmlelement, mode).defaultValues(false);
     }
 
@@ -80,4 +82,9 @@
                 this->setCaption(points);
             }
+            else if(this->bShowMultiplier_)
+            {
+                const std::string& Multiplier = multi_cast<std::string>(this->InvaderGame->getMultiplier());
+                this->setCaption(Multiplier);
+            }
         }
     }
Index: /code/branches/invaders/src/modules/invader/InvaderHUDinfo.h
===================================================================
--- /code/branches/invaders/src/modules/invader/InvaderHUDinfo.h	(revision 9853)
+++ /code/branches/invaders/src/modules/invader/InvaderHUDinfo.h	(revision 9854)
@@ -60,4 +60,10 @@
                 { return this->bShowPoints_; }
 
+            inline void setShowMultiplier(bool value)
+                { this->bShowMultiplier_ = value; }
+            inline bool getShowMultiplier() const
+                { return this->bShowMultiplier_; }
+
+
         private:
             Invader* InvaderGame;
@@ -65,4 +71,5 @@
             bool bShowLevel_;
             bool bShowPoints_;
+            bool bShowMultiplier_;
     };
 }
