Index: code/branches/main_reto/include/Bullet.h
===================================================================
--- code/branches/main_reto/include/Bullet.h	(revision 133)
+++ code/branches/main_reto/include/Bullet.h	(revision 133)
@@ -0,0 +1,23 @@
+#ifndef __Bullet__
+#define __Bullet__
+
+#include "Ogre.h"
+
+using namespace Ogre;
+
+class Bullet
+{
+public:
+	SceneNode *mNode;
+	Entity *mEntity;
+	Vector3 mSpeed;
+
+	Bullet(SceneNode*, Entity*, Vector3);
+	~Bullet();
+
+protected:
+
+};
+
+
+#endif
Index: code/branches/main_reto/include/OrxonoxShip.h
===================================================================
--- code/branches/main_reto/include/OrxonoxShip.h	(revision 132)
+++ code/branches/main_reto/include/OrxonoxShip.h	(revision 133)
@@ -3,4 +3,5 @@
 
 #include "Ogre.h"
+#include "Bullet.h"
 
 using namespace Ogre;
@@ -11,4 +12,5 @@
 	Vector3 speed;
 	float thrust, sideThrust, baseThrust;
+	Vector3 bulletSpeed;
 
 	OrxonoxShip(SceneManager*, SceneNode*);
@@ -25,4 +27,6 @@
 	Real getThrust();
 
+	Bullet* fire();
+
 	bool tick(unsigned long, float);
 
@@ -32,4 +36,6 @@
 	Entity *mShip;
 
+	int n;
+
 };
 
Index: code/branches/main_reto/include/RunManager.h
===================================================================
--- code/branches/main_reto/include/RunManager.h	(revision 132)
+++ code/branches/main_reto/include/RunManager.h	(revision 133)
@@ -60,4 +60,9 @@
 	OIS::JoyStick* mJoy;
 
+	bool leftButtonDown;
+	Bullet **mBullets;
+	int mBulletsSize;
+	int mBulletsPosition;
+
 	// previously elapsed render time
 	unsigned long mTime;
Index: code/branches/main_reto/src/Bullet.cpp
===================================================================
--- code/branches/main_reto/src/Bullet.cpp	(revision 133)
+++ code/branches/main_reto/src/Bullet.cpp	(revision 133)
@@ -0,0 +1,12 @@
+#include "Bullet.h"
+
+
+Bullet::Bullet(SceneNode *mNode, Entity *mEntity, Vector3 mSpeed) : mNode(mNode), mEntity(mEntity), mSpeed(mSpeed)
+{
+	mNode->attachObject(mEntity);
+}
+
+
+Bullet::~Bullet()
+{
+}
Index: code/branches/main_reto/src/OrxonoxShip.cpp
===================================================================
--- code/branches/main_reto/src/OrxonoxShip.cpp	(revision 132)
+++ code/branches/main_reto/src/OrxonoxShip.cpp	(revision 133)
@@ -3,5 +3,6 @@
 
 OrxonoxShip::OrxonoxShip(SceneManager *mSceneMgr, SceneNode *mNode)
-	: mSceneMgr(mSceneMgr), mRootNode(mNode), speed(Vector3(0, 0, 0)), baseThrust(100), thrust(0), sideThrust(0)
+	: mSceneMgr(mSceneMgr), mRootNode(mNode), speed(Vector3(0, 0, 0)), baseThrust(100), thrust(0), sideThrust(0), n(0),
+	bulletSpeed(400)
 {
 }
@@ -19,4 +20,5 @@
 
 	// create the "space ship" (currently a fish..)
+	// TODO: names must be unique!
 	mShip = mSceneMgr->createEntity("Ship", "fish.mesh");
 	SceneNode *fishNode = mRootNode->createChildSceneNode("fishNode");
@@ -59,4 +61,16 @@
 }
 
+Bullet* OrxonoxShip::fire()
+{
+	// TODO: Names must be unique!
+	SceneNode *temp = mRootNode->getParentSceneNode()->createChildSceneNode("BulletNode" + StringConverter::toString(n));
+	temp->setOrientation(mRootNode->getOrientation());
+	temp->setPosition(mRootNode->getPosition());
+	temp->setScale(Vector3(1, 1, 1) * 10);
+	temp->yaw(Degree(-90));
+	return new Bullet(temp,
+		mSceneMgr->createEntity("bullet" + StringConverter::toString(n++), "Barrel.mesh"),
+		speed + (mRootNode->getLocalAxes() * Vector3(0, 0, -1)).normalisedCopy() * bulletSpeed);
+}
 
 bool OrxonoxShip::tick(unsigned long time, float deltaTime)
Index: code/branches/main_reto/src/RunManager.cpp
===================================================================
--- code/branches/main_reto/src/RunManager.cpp	(revision 132)
+++ code/branches/main_reto/src/RunManager.cpp	(revision 133)
@@ -5,5 +5,5 @@
 RunManager::RunManager(OgreControl * mOgre, bool bufferedKeys, bool bufferedMouse,
 					   bool bufferedJoy ) :
-mOgre(mOgre), mWindow(mOgre->getRenderWindow()),
+mOgre(mOgre), mWindow(mOgre->getRenderWindow()), leftButtonDown(false),
 mStatsOn(true), mNumScreenShots(0),
 mTimeUntilNextToggle(0), mFiltering(TFO_BILINEAR),
@@ -35,4 +35,9 @@
 	// Set default mipmap level (NB some APIs ignore this)
 	TextureManager::getSingleton().setDefaultNumMipmaps(5);
+
+	// initialise bullets list
+	mBullets = new Bullet*[10];
+	mBulletsPosition = 0;
+	mBulletsSize = 10;
 
 	using namespace OIS;
@@ -79,4 +84,8 @@
 	if (mScene)
 		delete mScene;
+
+	for (int i = 0; i < mBulletsPosition; i++)
+		delete mBullets[i];
+	delete mBullets;
 }
 
@@ -91,4 +100,12 @@
 	mScene->tick(time, deltaTime);
 	mShip->tick(time, deltaTime);
+
+	// update the bullet positions
+	for (int i = 0; i < mBulletsPosition; i++)
+	{
+		mBullets[i]->mNode->translate(mBullets[i]->mSpeed*deltaTime);
+		mBullets[i]->mNode->yaw(Degree(deltaTime*100));
+		mBullets[i]->mNode->roll(Degree(deltaTime*300));
+	}
 
 	using namespace OIS;
@@ -257,4 +274,25 @@
 	const MouseState &ms = mMouse->getMouseState();
 
+	if (ms.buttonDown(MB_Left) && !leftButtonDown)
+	{
+		leftButtonDown = true;
+		// fire
+		Bullet *mTempBullet = mShip->fire();
+		if (mBulletsPosition >= mBulletsSize)
+		{
+			// redimension the array
+			Bullet **mTempArray = new Bullet*[2*mBulletsSize];
+			for (int i = 0; i < mBulletsSize; i++)
+				mTempArray[i] = mBullets[i];
+			mBulletsSize *= 2;
+			delete mBullets;
+			mBullets = mTempArray;
+		}
+		mBullets[mBulletsPosition++] = mTempBullet;
+
+	}
+	else if (!ms.buttons)
+		leftButtonDown = false;
+
 	mShip->setYaw(Degree(-ms.X.rel * 0.13));
 	mShip->setPitch(Degree(-ms.Y.rel * 0.13));
Index: code/branches/main_reto/weapon_framework/weapon_framework.vcproj
===================================================================
--- code/branches/main_reto/weapon_framework/weapon_framework.vcproj	(revision 132)
+++ code/branches/main_reto/weapon_framework/weapon_framework.vcproj	(revision 133)
@@ -184,4 +184,8 @@
 			>
 			<File
+				RelativePath="..\src\Bullet.cpp"
+				>
+			</File>
+			<File
 				RelativePath="..\src\CameraManager.cpp"
 				>
@@ -218,4 +222,8 @@
 			>
 			<File
+				RelativePath="..\include\Bullet.h"
+				>
+			</File>
+			<File
 				RelativePath="..\include\CameraManager.h"
 				>
