示例#1
0
        public static float ShotDistanceSq(DynamicTransform2 shooter, GunData gun, DynamicPosition2 target)
        {
            Vector2          shotPosition           = shooter.Position;
            Vector2          shotVelocity           = gun.ShotSpeed * shooter.Orientation.Facing + shooter.Velocity;
            DynamicPosition2 initialProjectileState = new DynamicPosition2(shotPosition, shotVelocity);

            return(ShotDistanceSq(initialProjectileState, target));
        }
示例#2
0
 public GunMount(GunData gunData, Vector2[] offsets)
 {
     MountedGun        = gunData;
     LocalMountOffsets = offsets;
 }