Misc. Improvements

Turrets lead their projectiles
Double click to equip/unequip/move
Minimum weapon convergence distance
This commit is contained in:
Reinier Vens 2021-01-27 16:14:41 +00:00
commit 922c8ea460
18 changed files with 240 additions and 69 deletions

View file

@ -660,7 +660,7 @@ public class SectorRenderer : MonoBehaviour
if (entity.Key.Target.Value != null && !EntityInstances.ContainsKey(entity.Key.Target.Value))
entity.Key.Target.Value = null;
entity.Value.LookAtPoint.position = entity.Value.Transform.position + (Vector3) entity.Key.LookDirection * (entity.Key.Target.Value != null
? (EntityInstances[entity.Key.Target.Value].Transform.position - entity.Value.Transform.position).magnitude : 10000);
? max((EntityInstances[entity.Key.Target.Value].Transform.position - entity.Value.Transform.position).magnitude,Settings.GameplaySettings.ConvergenceMinimumDistance) : 10000);
entity.Value.Transform.position = entity.Key.Position;
}
foreach(var e in hitList)