CapturePointSystem fix, DamageIndicatorSystem fix

This commit is contained in:
verysecrethero
2016-02-23 17:29:33 +01:00
parent 2c18068059
commit e2831c5593
5 changed files with 144 additions and 64 deletions
+2 -3
View File
@@ -33,9 +33,8 @@ void PlayerDeathSystem::createDeathEffect(EntityWrapper player)
EntityWrapper deathEffectEW = EntityWrapper(m_World, deathEffectID);
//components that we need from player
auto playerCamera = player.FirstChildByName("Camera");
auto playerModel = player.FirstChildByName("PlayerModel");
if (!playerCamera.Valid() || !playerModel.Valid()) {
if (!playerModel.Valid()) {
return;
}
if (!playerModel.HasComponent("Model") || !playerModel.HasComponent("Animation")) {
@@ -44,7 +43,7 @@ void PlayerDeathSystem::createDeathEffect(EntityWrapper player)
auto playerEntityModel = playerModel["Model"];
auto playerEntityAnimation = playerModel["Animation"];
//copy the data from player to explisioneffectmodel
//copy the data from player to explosioneffectmodel
playerEntityModel.Copy(deathEffectEW["Model"]);
playerEntityAnimation.Copy(deathEffectEW["Animation"]);
//freeze the animation