spawning 1 shield on server and one on client

This commit is contained in:
viktorljung
2016-03-14 16:46:03 +01:00
parent f269caafed
commit bdbf864934
2 changed files with 10 additions and 20 deletions
+2 -20
View File
@@ -31,17 +31,8 @@
<Components>
<c:Animation>
<AnimationName>ActivateShieldU</AnimationName>
<Loop>false</Loop>
</c:Animation>
<c:Transform/>
</Components>
<Children/>
</Entity>
<Entity name="Idle">
<Components>
<c:Animation>
<AnimationName>ShieldFrontU</AnimationName>
<Play>true</Play>
<Loop>false</Loop>
</c:Animation>
<c:Transform/>
</Components>
@@ -74,16 +65,7 @@
<Components>
<c:Animation>
<AnimationName>ActivateShieldU</AnimationName>
<Loop>false</Loop>
</c:Animation>
<c:Transform/>
</Components>
<Children/>
</Entity>
<Entity name="Idle">
<Components>
<c:Animation>
<AnimationName>ShieldFrontU</AnimationName>
<Play>true</Play>
<Loop>false</Loop>
</c:Animation>
<c:Transform/>
@@ -162,6 +162,7 @@ bool DefenderWeaponBehaviour::OnInputCommand(ComponentWrapper cWeapon, WeaponInf
SpawnerSystem::Spawn(attachment, attachment);
/*
EntityWrapper backAttachment = attachment.FirstChildByName("Back");
if (backAttachment.Valid()) {
@@ -171,7 +172,11 @@ bool DefenderWeaponBehaviour::OnInputCommand(ComponentWrapper cWeapon, WeaponInf
eDeployShieldAttachement.Restart = true;
eDeployShieldAttachement.Start = true;
m_EventBroker->Publish(eDeployShieldAttachement);
} else {
LOG_ERROR("back shield invalid");
}
EntityWrapper frontAttachment = attachment.FirstChildByName("Front");
if (frontAttachment.Valid()) {
Events::AutoAnimationBlend eDeployShieldAttachement;
@@ -181,7 +186,10 @@ bool DefenderWeaponBehaviour::OnInputCommand(ComponentWrapper cWeapon, WeaponInf
eDeployShieldAttachement.Start = true;
m_EventBroker->Publish(eDeployShieldAttachement);
} else {
LOG_ERROR("front shield invalid");
}
*/
if (IsClient) {
EntityWrapper root = wi.FirstPersonEntity;