summaryrefslogtreecommitdiffstats
path: root/src/Mobs
diff options
context:
space:
mode:
Diffstat (limited to 'src/Mobs')
-rw-r--r--src/Mobs/Components/AttackComponent.cpp5
-rw-r--r--src/Mobs/Components/CMakeLists.txt18
-rw-r--r--src/Mobs/Components/EnvironmentComponent.cpp5
-rw-r--r--src/Mobs/Components/MovementComponent.cpp5
-rw-r--r--src/Mobs/Monster.h4
5 files changed, 30 insertions, 7 deletions
diff --git a/src/Mobs/Components/AttackComponent.cpp b/src/Mobs/Components/AttackComponent.cpp
index e69de29bb..ae721f00b 100644
--- a/src/Mobs/Components/AttackComponent.cpp
+++ b/src/Mobs/Components/AttackComponent.cpp
@@ -0,0 +1,5 @@
+#include "Globals.h"
+#include "AttackComponent.h"
+#include "../Monster.h"
+
+cAttackComponent::cAttackComponent(cMonster * a_Entity) : m_Self(a_Entity){}
diff --git a/src/Mobs/Components/CMakeLists.txt b/src/Mobs/Components/CMakeLists.txt
index 187384d7f..0c6a96c07 100644
--- a/src/Mobs/Components/CMakeLists.txt
+++ b/src/Mobs/Components/CMakeLists.txt
@@ -3,10 +3,18 @@ project (MCServer)
include_directories ("${PROJECT_SOURCE_DIR}/../")
-file(GLOB SOURCE
- "*.cpp"
- "*.h"
-)
+SET (SRCS
+ AIComponent.cpp
+ AttackComponent.cpp
+ EnvironmentComponent.cpp
+ MovementComponent.cpp)
+
+SET (HDRS
+ AIComponent.h
+ AttackComponent.h
+ EnvironmentComponent.h
+ MovementComponent.h)
+
if(NOT MSVC)
- add_library(Components ${SOURCE})
+ add_library(Components ${SRCS} ${HDRS})
endif() \ No newline at end of file
diff --git a/src/Mobs/Components/EnvironmentComponent.cpp b/src/Mobs/Components/EnvironmentComponent.cpp
index e69de29bb..f8cfc37ee 100644
--- a/src/Mobs/Components/EnvironmentComponent.cpp
+++ b/src/Mobs/Components/EnvironmentComponent.cpp
@@ -0,0 +1,5 @@
+#include "Globals.h"
+#include "EnvironmentComponent.h"
+#include "../Monster.h"
+
+cEnvironmentComponent::cEnvironmentComponent(cMonster * a_Entity) : m_Self(a_Entity){}
diff --git a/src/Mobs/Components/MovementComponent.cpp b/src/Mobs/Components/MovementComponent.cpp
index e69de29bb..6e92928d4 100644
--- a/src/Mobs/Components/MovementComponent.cpp
+++ b/src/Mobs/Components/MovementComponent.cpp
@@ -0,0 +1,5 @@
+#include "Globals.h"
+#include "MovementComponent.h"
+#include "../Monster.h"
+
+cMovementComponent::cMovementComponent(cMonster * a_Entity) : m_Self(a_Entity){}
diff --git a/src/Mobs/Monster.h b/src/Mobs/Monster.h
index 530ec76dd..a3febc568 100644
--- a/src/Mobs/Monster.h
+++ b/src/Mobs/Monster.h
@@ -87,10 +87,10 @@ public:
float GetDropChanceChestplate() { return m_DropChanceChestplate; }
float GetDropChanceLeggings() { return m_DropChanceLeggings; }
float GetDropChanceWeapon() { return m_DropChanceWeapon; }
- // tolua_begin
+
eType GetMobType() const { return m_MobType; }
eFamily GetMobFamily() { return mfPassive; }
- // tolua_end
+
// Set Functions - Temporary
void SetDropChanceBoots(float a_Chance) { m_DropChanceBoots = a_Chance; }