aliens

Author Topic: Strange behaviour when craft weapon has 1 ammo...  (Read 5177 times)

Offline Amiga

  • Colonel
  • ****
  • Posts: 128
  • Amiga4ever....
    • View Profile
    • White Wolf Untold Story PL (my rpg game based on Witcher saga)
Strange behaviour when craft weapon has 1 ammo...
« on: March 17, 2018, 12:06:51 am »
So I've created Nuclear Missile Craft Weapon. Ammo Max 1...the problem is when I set during fight Caution or Standard Attack weapon is launched and my plane is retreat on save distance straight away and weapon is unable to hit the target. Only aggresive attack works...
Is is a bug that first shoot never hit when weapon has max 1 ammo?
The only solution I've found is to set ammo max 2 insted of 1....
« Last Edit: March 17, 2018, 12:18:13 am by Amiga »

Offline Meridian

  • Global Moderator
  • Commander
  • *****
  • Posts: 8616
    • View Profile
Re: Strange behaviour when craft weapon has 1 ammo...
« Reply #1 on: March 17, 2018, 12:42:46 am »
Setting ammo to 2 will not help... the same will happen to the 2nd missile.
Basically when last missile is fired, the craft automatically retreats to safe distance... unless you're in aggressive mode.

It's not technically a bug... it's the same behavior as the original game had.

But it's not convenient... I admit.

Offline Amiga

  • Colonel
  • ****
  • Posts: 128
  • Amiga4ever....
    • View Profile
    • White Wolf Untold Story PL (my rpg game based on Witcher saga)
Re: Strange behaviour when craft weapon has 1 ammo...
« Reply #2 on: March 17, 2018, 12:44:24 am »
No. With ammox2  is fine..both missiles hitting target so it's solution.

Offline Meridian

  • Global Moderator
  • Commander
  • *****
  • Posts: 8616
    • View Profile
Re: Strange behaviour when craft weapon has 1 ammo...
« Reply #3 on: March 17, 2018, 01:25:48 am »
It has happened to me countless times over the last 20 years.
I have read the source code and I see it works that way.
I have just tried it on the original game too, extra for you.

But sure, don't believe me... I have only been developing this game for the last couple of years... what do I know...

Offline Amiga

  • Colonel
  • ****
  • Posts: 128
  • Amiga4ever....
    • View Profile
    • White Wolf Untold Story PL (my rpg game based on Witcher saga)
Re: Strange behaviour when craft weapon has 1 ammo...
« Reply #4 on: March 17, 2018, 01:43:07 am »
I know it's exist in original game:) I thought it can be fixed in some way...
I've just checked again with my weapon maxAmmo: 2 and both salves hit target..no retreat
here's YT video :)
ammo: 1
https://www.youtube.com/watch?v=CDQM86dTpE0&feature=youtu.be

ammo: 2
https://www.youtube.com/watch?v=KNo0sc9d0iM&feature=youtu.be
« Last Edit: March 17, 2018, 01:52:00 am by Amiga »

Offline Meridian

  • Global Moderator
  • Commander
  • *****
  • Posts: 8616
    • View Profile
Re: Strange behaviour when craft weapon has 1 ammo...
« Reply #5 on: March 17, 2018, 01:54:11 am »
Here's a video with an interceptor with 2 missiles.
First shot, hit.
Second shot, disengage and miss. Each time.

« Last Edit: March 17, 2018, 01:58:08 am by Meridian »

Offline Amiga

  • Colonel
  • ****
  • Posts: 128
  • Amiga4ever....
    • View Profile
    • White Wolf Untold Story PL (my rpg game based on Witcher saga)
Re: Strange behaviour when craft weapon has 1 ammo...
« Reply #6 on: March 17, 2018, 02:16:51 am »

Two variants:

..I think I know how to solve it. If missile is still flying then second missile will hit but if missile hit the target before reload then craft retreat from battle after second shoot. It happens on low range weapons


the key is to set proper range and reload time....




Offline Meridian

  • Global Moderator
  • Commander
  • *****
  • Posts: 8616
    • View Profile
Re: Strange behaviour when craft weapon has 1 ammo...
« Reply #7 on: March 17, 2018, 02:35:41 am »
Yes, if the previous missile is still flying while the last missile is fired, this will not happen.

But in vanilla (and in most mods) reload times and weapon ranges are set so that only one missile is flying at a time... you can change it, but it has also disadvantages... for example, if the first missile destroys the target, the second (already fired) missile is wasted.

Offline Amiga

  • Colonel
  • ****
  • Posts: 128
  • Amiga4ever....
    • View Profile
    • White Wolf Untold Story PL (my rpg game based on Witcher saga)
Re: Strange behaviour when craft weapon has 1 ammo...
« Reply #8 on: March 17, 2018, 10:43:47 am »
Yes, if the previous missile is still flying while the last missile is fired, this will not happen.

But in vanilla (and in most mods) reload times and weapon
ranges are set so that only one missile is flying at a time... you can change it, but it has also disadvantages... for example, if the first missile destroys the target, the second (already fired) missile is wasted.

In both case there is a chance that missile is wasted..
« Last Edit: March 17, 2018, 10:45:26 am by Amiga »

Offline Meridian

  • Global Moderator
  • Commander
  • *****
  • Posts: 8616
    • View Profile
Re: Strange behaviour when craft weapon has 1 ammo...
« Reply #9 on: March 17, 2018, 10:49:26 am »
But in one of the cases you can prevent wasting by shortly switching to aggressive.
In the other case, it is always wasted.

Pretty big difference for me.

Offline Amiga

  • Colonel
  • ****
  • Posts: 128
  • Amiga4ever....
    • View Profile
    • White Wolf Untold Story PL (my rpg game based on Witcher saga)
Re: Strange behaviour when craft weapon has 1 ammo...
« Reply #10 on: March 17, 2018, 11:26:39 am »
But in one of the cases you can prevent wasting by shortly switching to aggressive.
In the other case, it is always wasted.
Pretty big difference for me.

Yes I was going to write about it ;)
« Last Edit: March 17, 2018, 12:00:30 pm by Amiga »

Offline Warboy1982

  • Administrator
  • Commander
  • *****
  • Posts: 2333
  • Developer
    • View Profile
Re: Strange behaviour when craft weapon has 1 ammo...
« Reply #11 on: March 18, 2018, 11:05:31 am »
This long standing bug has been resolved.

Offline Amiga

  • Colonel
  • ****
  • Posts: 128
  • Amiga4ever....
    • View Profile
    • White Wolf Untold Story PL (my rpg game based on Witcher saga)
Re: Strange behaviour when craft weapon has 1 ammo...
« Reply #12 on: March 18, 2018, 06:26:29 pm »
This long standing bug has been resolved.

what do you mean Warboy? l;atest nightly has fix already?? Awesome!

Quote
warboy1982, Sun Mar 18 01:12:29 2018
fix dogfight "last bullet" bug

- checked - working flawless..after 24 yrs
 ;D ;D ;D ;D
« Last Edit: March 18, 2018, 06:40:18 pm by Amiga »

Offline The Reaver of Darkness

  • Commander
  • *****
  • Posts: 1510
    • View Profile
Re: Strange behaviour when craft weapon has 1 ammo...
« Reply #13 on: March 19, 2018, 08:37:08 pm »
This long standing bug has been resolved.
This is amazing! I thought it was never going to be fixed!