Turrets manned by the blind?

This forum is the ideal place for all discussion relating to X4. You will also find additional information from developers here.

Moderator: Moderators for English X Forum

apL
Posts: 26
Joined: Wed, 28. Jun 17, 06:22

Turrets manned by the blind?

Post by apL »

Am I doing something wrong? I bought a frigate in my playthrough, and the first engagement I get...the turrets are just spraying hopelessly in a general direction. It's as if they're trying to listen for the enemy ship and just shoot what they hear.

Do I need to hire better crew? Or put a specific setting on? Or buy a combat extension? Or is this a problem with turrets at the moment...(I haven't faced turrets yet so I don't know if the NPC is just as useless with them as my ship)
LameFox
Posts: 3644
Joined: Tue, 22. Oct 13, 15:26
x4

Re: Turrets manned by the blind?

Post by LameFox »

I haven't met an NPC who could aim yet, friendly or hostile. Even the Kha'ak with their beam guns shoot around me more than at me. Unlike their flying I don't think it's a bug so much as their default skill being way undertuned.
***modified***
Vidares
Posts: 22
Joined: Fri, 30. Nov 18, 14:09

Re: Turrets manned by the blind?

Post by Vidares »

Same here >.< my turret´s are shooting at the position of the ship 3 seconds ago. and even if the enemy stands still, they cant hit it :lol:

Maybe we need more service crew or the aiming software mk1 is bugged'????
Vidares
Posts: 22
Joined: Fri, 30. Nov 18, 14:09

Re: Turrets manned by the blind?

Post by Vidares »

More service crew doenst change a thing =(
Last edited by Vidares on Sat, 1. Dec 18, 14:38, edited 1 time in total.
Vidares
Posts: 22
Joined: Fri, 30. Nov 18, 14:09

Re: Turrets manned by the blind?

Post by Vidares »

More service crew doesnt change a thing =(
Imari
Posts: 171
Joined: Tue, 14. Jun 11, 13:43
x4

Re: Turrets manned by the blind?

Post by Imari »

Yea, seems turrets are manned by blind crew and AI. 1% hit rate regardless of loadout. At least for my frigate.

Not sure if higher crew ranks will significantly improve accuracy.
User avatar
Gazz
Posts: 13244
Joined: Fri, 13. Jan 06, 16:39
x4

Re: Turrets manned by the blind?

Post by Gazz »

Some things have not changed, I see. ;)
My complete script download page. . . . . . I AM THE LAW!
There is no sense crying over every mistake. You just keep on trying till you run out of cake.
Carl Sumner
Posts: 5145
Joined: Mon, 23. Feb 04, 01:28
x4

Re: Turrets manned by the blind?

Post by Carl Sumner »

Imari wrote: Sat, 1. Dec 18, 14:24 ... Not sure if higher crew ranks will significantly improve accuracy.
Probably will, if it is like the other games. In Rebirth it made a -big- difference.

And the other things mentioned, although I have not heard about a bug there, yet.
Tinker

"If engineers built buildings the way programmers write programs, the first woodpecker that came along would destroy civilization!"
Kaeltheras
Posts: 59
Joined: Tue, 9. Aug 11, 05:11
x4

Re: Turrets manned by the blind?

Post by Kaeltheras »

Don't know if there's maybe something to do w/ overall crew rating or software or maybe turret type, but on my Cerberus, I had the mk 1 laser turrets and they had no problems hitting S ships going 80-200 m/s
Revenant342
Posts: 225
Joined: Thu, 21. Nov 13, 03:22
x4

Re: Turrets manned by the blind?

Post by Revenant342 »

Enemies definitely suck. Took out four Ms and two Ps in a Discoverer earlier without my shields dropping below 75%.
Zippo342
Posts: 410
Joined: Fri, 31. Mar 06, 20:07
x3tc

Re: Turrets manned by the blind?

Post by Zippo342 »

Linear Algebra is hard, yo? I mean if they had someone good at it working there, both the autopilot and the turrets would be spot on.

I mean, it's not hard to plot a course through an asteroid belt if you know how to take the projection of an asteroid's vector on your vector. If you do, finding out the distance which you will close on the asteroid is as simple as:
v_a = vector of asteroid from you
v_s = ship's projected movement vector

v_a->s (Projection of A on S) = dot.product(v_s, v_a)/dot.product(v_s, v_s) * v_s

d_a = abs(v_s - v_a->s) (This is the closest distance you will get to this asteroid)

Then once you had the distance from the asteroid you would pass, you can then tell if you'll be too close if the distance is less than the radius of the asteroid, and you can plot around the asteroid by simply by doing this:
r_a = radius of asteroid

wp1 = v_a->s + (v_s - v_a->s) / d_a * r_a
wp2 = v_s - wp1

Something similar would be used for tracking turrets. The linear algebra behind it is pretty hard to understand, but once you do, you can easily even get the GPU to help by doing a whole sector at a time.
Streaming most nights 1800-0000ish at www.twitch.tv/chthonicone/
User avatar
Gazz
Posts: 13244
Joined: Fri, 13. Jan 06, 16:39
x4

Re: Turrets manned by the blind?

Post by Gazz »

It's not quite that simple.
Ships have the annoying habit of not flying in a straight line so all too often any calculation fails as soon as you begin it because the ship has already changed course again by the time the projectile could arrive.
Then there's the issue of what you do in hardcode, which parts you externalise and how fast all that is. It's complicated and that's just the rough design. ;)
My complete script download page. . . . . . I AM THE LAW!
There is no sense crying over every mistake. You just keep on trying till you run out of cake.
Zippo342
Posts: 410
Joined: Fri, 31. Mar 06, 20:07
x3tc

Re: Turrets manned by the blind?

Post by Zippo342 »

Gazz, I know you have experience in this, but those curves can also be simulated with a rotational matrix multiplication.

Theta = the angle and direction you wish to rotate it

[[cos^2(Theta) sin(Theta)cos(Theta)]
[-sin(Theta)cos(Theta) sin^2(Theta)]]

There are ways to even model the more complex modelings. It's not easy to understand how, but if you do, it is easy to implement with linear algebra.

Edit: I had to use this kind of stuff a lot for stuff like affine transformation of images in Computer Vision last year.
Streaming most nights 1800-0000ish at www.twitch.tv/chthonicone/
Zippo342
Posts: 410
Joined: Fri, 31. Mar 06, 20:07
x3tc

Re: Turrets manned by the blind?

Post by Zippo342 »

Gazz wrote: Sun, 2. Dec 18, 01:21 It's not quite that simple.
Ships have the annoying habit of not flying in a straight line so all too often any calculation fails as soon as you begin it because the ship has already changed course again by the time the projectile could arrive.
Then there's the issue of what you do in hardcode, which parts you externalise and how fast all that is. It's complicated and that's just the rough design. ;)
Also, I just wanted to say, Gazz, 12 years ago when I was in the military, I first played X3:R and then discovered your turret mods, I didn't have the appreciation then of the math you had to do that I do now that I'm graduating with my CS degree. You did a great job, but maybe I can help you do better in the future when trying to hit something moving "predictably not in a straight line"
Streaming most nights 1800-0000ish at www.twitch.tv/chthonicone/
User avatar
Gazz
Posts: 13244
Joined: Fri, 13. Jan 06, 16:39
x4

Re: Turrets manned by the blind?

Post by Gazz »

Yes, I know this can be done "properly" but in a game that's very often not an option.
You look for ways to cut corners and get a "good enough" solution with 2D or 2.5D math or completely unrelated but faster functions. ;)

You don't have to get it to work once. You have to get it working at a high frequency for hundreds of entities. Math is great and useful but not always the right answer. ;)
My complete script download page. . . . . . I AM THE LAW!
There is no sense crying over every mistake. You just keep on trying till you run out of cake.
User avatar
FalconGrey
Posts: 440
Joined: Thu, 22. Apr 04, 01:53
x4

Re: Turrets manned by the blind?

Post by FalconGrey »

-Munches his popcorn watching the back and forth as he remembers the X3:R years and before mods.... then jumps back into his X4 cockpit- :lol:
It's not if we win or lose that matters, it's that we stood and faced it.
Chris0132
Posts: 1463
Joined: Sun, 22. Jun 08, 01:25
xr

Re: Turrets manned by the blind?

Post by Chris0132 »

I found that the turrets on my ship actually weren't tracking things. They would aim at something, then fire for a few seconds without updating their aim point, then aim back at it and do the same thing. Basically meant they wouldn't hit anything.
aristos_achaion
Posts: 6
Joined: Sat, 1. Dec 18, 06:30
x4

Re: Turrets manned by the blind?

Post by aristos_achaion »

Chris0132 wrote: Sun, 2. Dec 18, 03:11 I found that the turrets on my ship actually weren't tracking things. They would aim at something, then fire for a few seconds without updating their aim point, then aim back at it and do the same thing. Basically meant they wouldn't hit anything.
Have you tried leaving the sector while combat is going on? It's been a long time, but IIRC in X3 out-of-sector combat was rather different from in-sector combat, and the AIs tended to less awful at OOS combat.
User avatar
PDS001Sniper
Posts: 41
Joined: Mon, 3. Nov 08, 02:37
x4

Re: Turrets manned by the blind?

Post by PDS001Sniper »

Same here. Turrets on my Cerberus can't hit a thing... I was lucky that I had 2 defence drones and 1 S class fighter on board.
# CPU: Intel Core i9-14900K
# VGA: ASUS TUF RTX 4090 OC
# MOBO: ROG STRIX Z790-E GAMING WIFI II
# RAM: Team Group T-Force Xtreem DDR5 48GB 8000Mhz CL38
# SSD: Samsung 980 Pro M.2
# PSU: ASUS 1000W TUF Gaming
# OS: Windows 11 Pro 64-Bit
Darlandra
Posts: 49
Joined: Wed, 22. Oct 08, 02:51
x4

Re: Turrets manned by the blind?

Post by Darlandra »

Same here. I just brought my cerberus to the anomoly point to escort the transport ship, and 5 s fighters showed up, and even sitting still they never hit anything. It was obvious watching the guns movement that they wearn't really tracking anything, they would aim, shoot for a second, re-aim, shoot, re-aim etc etc. They don't re-adjust moment by moment

Return to “X4: Foundations”