Index: /orxonox/trunk/src/util/object_manager.h
===================================================================
--- /orxonox/trunk/src/util/object_manager.h	(revision 4933)
+++ /orxonox/trunk/src/util/object_manager.h	(revision 4934)
@@ -63,4 +63,6 @@
 
   protected:
+    FastFactory (ClassID classID, const char* fastFactoryName = NULL);
+
     /** sets the Next factory in the list @param nextFactory the next factory */
     inline void setNext( FastFactory* nextFastFactory) { this->next = nextFastFactory; };
@@ -68,10 +70,10 @@
     FastFactory* getNext() const { return this->next; };
 
-    virtual BaseObject* fabricate(ClassID classID) = NULL;
-
-  private:
-    FastFactory (ClassID classID, const char* fastFactoryName = NULL);
+//    virtual BaseObject* fabricate(ClassID classID) = NULL;
+
+    static FastFactory* searchFastFactory(ClassID classID, const char* fastFactoryName = NULL);
+
+  private:
     static void registerFastFactory(FastFactory* fastFactory);
-    static FastFactory* searchFastFactory(ClassID classID, const char* fastFactoryName = NULL);
 
   protected:
@@ -92,5 +94,5 @@
 {
   public:
-    static FastFactory* getFastFactory(ClassID classID, const char* fastFactoryName = NULL);
+    static tFastFactory<T>* getFastFactory(ClassID classID, const char* fastFactoryName = NULL);
 
     void prepare(unsigned int count);
@@ -126,14 +128,14 @@
 
 template<class T>
-    FastFactory* tFastFactory<T>::getFastFactory(ClassID classID, const char* fastFactoryName)
+    tFastFactory<T>* tFastFactory<T>::getFastFactory(ClassID classID, const char* fastFactoryName)
 {
   tFastFactory<T>* tmpFac = NULL;
   if (FastFactory::getFirst() != NULL)
-    tmpFac = FastFactory::getFirst()->searchFastFactory(classID, fastFactoryName);
+    tmpFac = static_cast<tFastFactory<T>*>(FastFactory::getFirst()->searchFastFactory(classID, fastFactoryName));
 
   if (tmpFac != NULL)
     return tmpFac;
   else
-    return new tFastFactory<T>;
+    return new tFastFactory<T>(classID, fastFactoryName);
 }
 
@@ -142,5 +144,5 @@
     T* tFastFactory<T>::fabricate()
 {
-  FastObjectMember<T>* tmpFirstDead = this->deadList;
+  FastObjectMember<T>* tmpFirstDead = new FastObjectMember<T>;
   tmpFirstDead->objectPointer = new T();
   tmpFirstDead->next = this->deadList;
@@ -148,5 +150,5 @@
 
   this->deadList = tmpFirstDead;
-  return this->deadList;
+  return tmpFirstDead->objectPointer;
 }
 
@@ -154,9 +156,9 @@
     void tFastFactory<T>::prepare(unsigned int count)
 {
-  if (this->storedDeadObjects + this->storedLivingObjects >= count)
+/*  if (this->storedDeadObjects + this->storedLivingObjects >= count)
   {
     PRINTF(3)("not creating new Objects for class %s, because the requested count already exists\n", this->getClassName());
-  }
-  for (int i = this->storedDeadObjects + this->storedLivingObjects; i < count; i++)
+  }*/
+  for (int i = this->storedDeadObjects; i < count; i++)
   {
     this->fabricate();
@@ -167,4 +169,5 @@
     T* tFastFactory<T>::resurect()
 {
+  PRINTF(4)("Resurecting Object of type %s\n", this->getName());
   if (unlikely(this->deadList == NULL))
   {
@@ -179,7 +182,7 @@
 
     tmpC->next = this->unusedContainers;
-    this->unusedContainers->tmpC;
-
-    return tmpC;
+    this->unusedContainers = tmpC;
+
+    return tmpC->objectPointer;
   }
 }
Index: /orxonox/trunk/src/world_entities/weapons/test_gun.cc
===================================================================
--- /orxonox/trunk/src/world_entities/weapons/test_gun.cc	(revision 4933)
+++ /orxonox/trunk/src/world_entities/weapons/test_gun.cc	(revision 4934)
@@ -111,4 +111,7 @@
 
   this->setActionSound(WA_SHOOT, "sound/shot1.wav");
+
+  this->bulletFactory = tFastFactory<TestBullet>::getFastFactory(CL_TEST_BULLET, "TestBullet");
+  this->bulletFactory->prepare(100);
 }
 
@@ -155,5 +158,5 @@
 void TestGun::fire()
 {
-  Projectile* pj =  new TestBullet();//dynamic_cast<Projectile*>(ObjectManager::getInstance()->getFromDeadList(CL_TEST_BULLET & CL_MASK_LOWLEVEL_CLASS));
+  Projectile* pj =  this->bulletFactory->resurect();//new TestBullet();//dynamic_cast<Projectile*>(ObjectManager::getInstance()->getFromDeadList(CL_TEST_BULLET & CL_MASK_LOWLEVEL_CLASS));
 //  weaponSource->play();
 
Index: /orxonox/trunk/src/world_entities/weapons/test_gun.h
===================================================================
--- /orxonox/trunk/src/world_entities/weapons/test_gun.h	(revision 4933)
+++ /orxonox/trunk/src/world_entities/weapons/test_gun.h	(revision 4934)
@@ -30,8 +30,9 @@
 class Quaternion;
 class Animation3D;
+class TestBullet;
 
 
 class TestGun : public Weapon
-{
+  {
   public:
     TestGun (PNode* parent, const Vector& coordinate, const Quaternion& direction, int leftRight);
@@ -54,7 +55,8 @@
     int leftRight;   // this will become an enum
 
+    tFastFactory<TestBullet>*       bulletFactory;  //!< The factory for fast interaction with the TestBullet Class.
 
 
-};
 
+  };
 #endif /* _TEST_GUN_H */
Index: /orxonox/trunk/src/world_entities/weapons/weapon.cc
===================================================================
--- /orxonox/trunk/src/world_entities/weapons/weapon.cc	(revision 4933)
+++ /orxonox/trunk/src/world_entities/weapons/weapon.cc	(revision 4934)
@@ -398,5 +398,5 @@
 void Weapon::tickW(float dt)
 {
-  printf("%s ", stateToChar(this->currentState));
+  //printf("%s ", stateToChar(this->currentState));
 
   // setting up the timing properties
Index: /orxonox/trunk/src/world_entities/weapons/weapon.h
===================================================================
--- /orxonox/trunk/src/world_entities/weapons/weapon.h	(revision 4933)
+++ /orxonox/trunk/src/world_entities/weapons/weapon.h	(revision 4934)
@@ -26,4 +26,5 @@
 class Animation3D;
 class TiXmlElement;
+template<class T> class tFastFactory;
 
 //! An enumerator defining Actions a Weapon can take
