Merge branch 'developer' into feature/gameplay
# Conflicts: # CrystalPoint.cpp
This commit is contained in:
@@ -5,8 +5,9 @@
|
||||
#include <iostream>
|
||||
|
||||
Enemy::Enemy(const std::string &fileName,
|
||||
const std::string &fileMusic,
|
||||
const Vec3f &position,
|
||||
Vec3f &rotation,
|
||||
const Vec3f &rotation,
|
||||
const float &scale)
|
||||
{
|
||||
model = Model::load(fileName);
|
||||
@@ -19,7 +20,7 @@ Enemy::Enemy(const std::string &fileName,
|
||||
radius = 10;
|
||||
xp = 10;
|
||||
hasTarget = false;
|
||||
hit_sound_id = CrystalPoint::GetSoundSystem().LoadSound("WAVE/enemy.wav", false);
|
||||
hit_sound_id = CrystalPoint::GetSoundSystem().LoadSound(fileMusic.c_str(), false);
|
||||
music = CrystalPoint::GetSoundSystem().GetSound(hit_sound_id);
|
||||
attack = false;
|
||||
}
|
||||
@@ -30,6 +31,8 @@ Enemy::~Enemy()
|
||||
|
||||
if (model)
|
||||
Model::unload(model);
|
||||
|
||||
delete music;
|
||||
}
|
||||
|
||||
void Enemy::draw()
|
||||
|
||||
Reference in New Issue
Block a user