Author Topic: A thread for little questions  (Read 1318504 times)

Online Solarius Scorch

  • Global Moderator
  • Commander
  • *****
  • Posts: 11727
  • WE MUST DISSENT
    • View Profile
    • Nocturmal Productions modding studio website
Re: A thread for little questions
« Reply #165 on: April 27, 2017, 06:25:34 pm »
Is there something like a critical fail or something? Several times I took a 150 something % to shoot someone and the shot hits obstacle... ok, I can bite that.
But having 218% to hit with sniper and missing by 2 squares is kinda hard to swallow. Is there some other factors to be counted after I click to shoot when it shows such % to hit?

It's not part of the mechanics, it's an imperfection of the engine. It is a well known bug, at least among devs and such, but it's so complex to fix that we just have to live with it - at least for now.

Offline Meridian

  • Global Moderator
  • Commander
  • *****
  • Posts: 9094
    • View Profile
Re: A thread for little questions
« Reply #166 on: April 27, 2017, 07:19:31 pm »
Is there something like a critical fail or something? Several times I took a 150 something % to shoot someone and the shot hits obstacle... ok, I can bite that.
But having 218% to hit with sniper and missing by 2 squares is kinda hard to swallow. Is there some other factors to be counted after I click to shoot when it shows such % to hit?

There is only one thing that's wrong... and that is the percentage symbol.

What you see displayed as 150% or 218% is NOT a "chance to hit", it is your effective accuracy and should be displayed as a plain number, e.g. just 150 or 218.
The original game showed it with the % symbol and that is the only reason why OpenXcom also displays it like that... but it's a pure lie.

The game doesn't work with "chance to hit" at all, so please forget about that concept completely.

What the effective accuracy means is also not easy to explain, so I will just give you 3 examples with some background.

Example 1:
- you and your target are both on the same Z-level
- there is a line of fire between you and your target... and it is not obstructed by any objects (trees, bushes, fences, lamp posts, etc.) within 0.5 tiles from ideal trajectory (LoF) in all directions (up, down, left, right)
- in such conditions, effective accuracy of 110 is enough to have 100% chance to hit a reasonably big target (e.g. an alien) across the whole map

Example 2:
- some conditions from example 1 are not met, e.g. you are on different Z-levels... or there is LoF, but there are some obstacles very near to this ideal LoF (nearer than half a tile)
- in such conditions, even accuracy 110 is not a guarantee to hit... higher accuracy will help (i.e. 218 is better than 110), but increase comes with very diminishing results... in such scenarios you are likely to hit maybe 50% of your shots

Example 3:
- there is a LoF, but there are many obstacles very near to this ideal line
- in such a scenario, your chance to hit is very low (~5%) regardless of the effective accuracy, even if it is 250+

And as always, there are even more factors I haven't mentioned, like:
- how much of the target unit do you actually see (ideally you should always see the whole target, i.e. no partial cover)
- there is small discrepancy between checking LoF (from eye-level) and shooting (from shoulder-level)
- etc.

From all this, you should remember:
- the number you see is NOT a "chance to hit"
- 110 is very good, anything above will not give you much more benefits
- if the shot looks complicated (many obstacles around the ideal line; or target in partial cover)... you will most likely miss... don't push it and find a better place to shoot from

It's not part of the mechanics, it's an imperfection of the engine. It is a well known bug, at least among devs and such, but it's so complex to fix that we just have to live with it - at least for now.

From my perspective it's not a bug.
There are some very small things, which could be improved/fixed... but in general, it works as designed.

Again, the number you see does not represent a chance to hit... it's a much more technical and mysterious number, which should be taken as an indicator, not as a fact.

Offline Noir_CZ

  • Sergeant
  • **
  • Posts: 31
    • View Profile
Re: A thread for little questions
« Reply #167 on: April 27, 2017, 08:20:26 pm »
It's not part of the mechanics, it's an imperfection of the engine. It is a well known bug, at least among devs and such, but it's so complex to fix that we just have to live with it - at least for now.

There is only one thing that's wrong... and that is the percentage symbol.

What you see displayed as 150% or 218% is NOT a "chance to hit", it is your effective accuracy and should be displayed as a plain number, e.g. just 150 or 218.
The original game showed it with the % symbol and that is the only reason why OpenXcom also displays it like that... but it's a pure lie.

The game doesn't work with "chance to hit" at all, so please forget about that concept completely.

...
...
...

Again, the number you see does not represent a chance to hit... it's a much more technical and mysterious number, which should be taken as an indicator, not as a fact.

Sorry for trunctating it, don't want to spam the whole thing
In my case it was alien base, same Z level, long corridor, no obstacles, 218 to hit with eurosyndicate sniper laser and it whiffed by 2 squares. True we were not in perfect line but had one tile offset still... anyway, thanks to both of you.

Offline Meridian

  • Global Moderator
  • Commander
  • *****
  • Posts: 9094
    • View Profile
Re: A thread for little questions
« Reply #168 on: April 27, 2017, 08:38:11 pm »
In my case it was alien base, same Z level, long corridor, no obstacles, 218 to hit with eurosyndicate sniper laser and it whiffed by 2 squares. True we were not in perfect line but had one tile offset still... anyway, thanks to both of you.

This does indeed sound wrong.

If something similar happens to you again (a clear shot with good accuracy misses by 1 tile or more), save immediately and post the save here... we'll look at what could have gone wrong.

Offline RSSwizard

  • Commander
  • *****
  • Posts: 793
    • View Profile
Re: A thread for little questions
« Reply #169 on: April 28, 2017, 12:12:07 am »
Is there something like a critical fail or something? Several times I took a 150 something % to shoot someone and the shot hits obstacle... ok, I can bite that.

Put simply this is like the concept of MOA accuracy when it comes to sharpshooting.

This is your chance to hit a man-sized target at a certain distance, that certain distance being roughly medium range (20-40 tiles) and obviously without any objects to get clipped by the shot.

Its not so much that your soldiers cant shoot straight, its that most of what you're shooting at (live targets) are actually moving just like in an FPS game (all those TUs they chewed through last turn). So your soldiers are Leading Targets with their aim and some confusion and over-reacting can ensue with that. Firing accuracy isnt just marksmanship accuracy, its also the ability to actually shoot an enemy in combat.

So you might say someone with a rifle ought to be able to bullseye someone at 200 yards (tiles) easily. Maybe. But the point and balance of the game is that they're not just standing still like deer. Turn based movement gives the impression of static nature but if that unit moved at all in the previous turn, or moves at all in the following turn, realistically speaking they were "moving" when you tried to shoot them.

# Hitler demanded a higher fire rate for the machineguns the germans were using because the shots from maxims with 500 rounds per minute cyclic could often be dodged by a charging soldier out in the field. So thats why the MG42 was raised to something like 1100-1300 rpm because its spitting out 20 per second and that raised the chances high enough that at least one would hit you even if you were making a mad dash. Hitler wanted to discourage these tactics among the allies.

# Even modern police only have about a 4% chance to hit someone with their pistol if the person is running.

# Just goes to show you how much of an effect simple movement has on shooting chances.

Also SNAP shots are literally pointing the gun in the general direction of the target and firing. You don't even line up the sights, its only one step better than a shot in the dark.

AIMED shots are when you line up the sights and POW, no extended aiming, no sniper-level adjusting for windage or anything like that. You only give it enough time to make sure the front dot is somewhere close to the middle of the reticle.

Each turn is about 3 seconds long, so an Aimed shot taking 60% TU to pull off is literally about 1 second of aiming and 1 second of firing/recoil recovery.

(you beat a map in 10 turns? excellent response time, it only took your hands 30 seconds to spread out and clear the battlefield)

Offline Starving Poet

  • Colonel
  • ****
  • Posts: 265
    • View Profile
Re: A thread for little questions
« Reply #170 on: April 28, 2017, 12:54:38 am »
The only thing I want to add to Meridian's post is that the magical number for listed accuracy is 130(%).  Ignoring everything else, that's the number where natural shot deviation is at its minimum.  Any number above 130, unless it's been changed in OXCE(+), does nothing for increasing the precision of a shot.  After that it's what Meridian said - natural shot deviation + obstacles, partial cover, bad angles, etc.

Offline Dioxine

  • Commander
  • *****
  • Posts: 5455
  • punk not dead
    • View Profile
    • Nocturnal Productions
Re: A thread for little questions
« Reply #171 on: April 28, 2017, 02:31:11 pm »
Put simply this is like the concept of MOA accuracy when it comes to sharpshooting.

It is not. It most definitely should be, but it isn't. Size of the target in OXCom has little to no meaning beyond range of 10 tiles. The problem is with pathing. The game first traces an ideal trajectory. If you roll a 'hit' on that % dice, you're very likely to hit even if the target is 1 pixel. Meridian also mentions small deviation, it is there, but activates at random to make 100%+ shot only 99.5% accurate (I think it is removed completely for 120%+ shots.

What Meridian wrote is accurate, but downplays the most common cause of bug:
- many objects in the path, especially if target is cut by half, so eg. only head and legs are visible
- perfect trajectory is calced
- bullet is released along it
- it hits an obstacle, because the trajectory was calc'd wrongly.

From Meridian's words, one could think that repeating shot will change anything. It won't. Repeated 120% acc shots, no matter how many, will always hit that obstacle. That wrong calculation is what I'm considering a bug; especially since the OG didn't have that problem.

Offline EricPhail

  • Sergeant
  • **
  • Posts: 22
    • View Profile
Re: A thread for little questions
« Reply #172 on: April 28, 2017, 10:33:16 pm »
Will incorrect trajectory calculations always result in hitting an obstacle, or can they miss outright? I've seen consecutive 250+ shots make the same miss (perfectly hit the same spot slightly wide of and behind the target) albiet these were high to low against a partially obscured target.

Offline Ragshak

  • Colonel
  • ****
  • Posts: 136
    • View Profile
Re: A thread for little questions
« Reply #173 on: April 29, 2017, 10:15:32 am »
Does difficulty level progression in Piratez is the same as in vanila?

https://www.ufopaedia.org/index.php/Difficulty_Levels

From my experience - example Sciencecific Experiment mission - Superhuman gives two drone enemies and pack of Osirons/Reaserchers. Blackbeard gives one drone enemy and for lower difficulties there is no drone at all for this mission.

Would like to see enemy stats at 100% and their numbres like for for  4-5 tier difficulty level. Which file should I edit to achive this goal?

Next one:
How to use Jellyfish craft inbuild weapon? Is there any? Description says something about it but I dont see an option to use it. One of my gals is locked on last floor but have no special items in hands to use new weapon? I dont have Voodoo yet - if thats the case.
« Last Edit: April 29, 2017, 02:58:52 pm by Ragshak »

Offline legionof1

  • Moderator
  • Commander
  • ***
  • Posts: 1900
  • Bullets go that way. Money comes this way.
    • View Profile
Re: A thread for little questions
« Reply #174 on: April 29, 2017, 03:01:23 pm »
snip
How to use Jellyfish craft inbuild weapon? Is there any? Description says something about it but I dont see an option to use it. One of my gals is locked on last floor but have no special items in hands to use new weapon? I dont have Voodoo yet - if thats the case.

There is an object on the ground under the gal "stuck" in the top floor. Pick it up on the inventory screen of that gal and equip. At present it is impossible to force something into a unit inventory based on position in a given craft. Not that it ever should, cause ugh so many conflicts/crashes possible.
« Last Edit: April 29, 2017, 03:53:30 pm by legionof1 »

Offline juff

  • Sergeant
  • **
  • Posts: 45
    • View Profile
Re: A thread for little questions
« Reply #175 on: April 29, 2017, 05:22:28 pm »

Would like to see enemy stats at 100% and their numbres like for for  4-5 tier difficulty level. Which file should I edit to achive this goal?
it's in piratez_factions.rul under aliendeployments, but the numbers are not easy to read because they're split by rank and inventory. lowqty shows for difficulty 1&2, high qty for 5, and average of the two for 3&4. dqty is a random amount of enemies that can be added for any difficulty.

Offline khade

  • Commander
  • *****
  • Posts: 509
    • View Profile
Re: A thread for little questions
« Reply #176 on: April 30, 2017, 02:39:11 am »
So this accuracy thing is why the musket, with around 40ish accuracy, is still pretty good?

Offline legionof1

  • Moderator
  • Commander
  • ***
  • Posts: 1900
  • Bullets go that way. Money comes this way.
    • View Profile
Re: A thread for little questions
« Reply #177 on: April 30, 2017, 02:56:24 am »
Yes, the musket while the most inaccurate rifle weapon in the mod, due to the nature of accuracy in the engine still ends up reasonably close to the target.

Deviation from a true line of fire path is cone shaped(like real shooting) so inside of a certain distance it's rather likely to still hit the target on a "miss". The lower your accuracy the greater the angle of the cone. 

Offline khade

  • Commander
  • *****
  • Posts: 509
    • View Profile
Re: A thread for little questions
« Reply #178 on: April 30, 2017, 03:32:11 am »
So with this information, why is the spraygun still unable to hit the broad side of a barn from inside the barn?

Offline legionof1

  • Moderator
  • Commander
  • ***
  • Posts: 1900
  • Bullets go that way. Money comes this way.
    • View Profile
Re: A thread for little questions
« Reply #179 on: April 30, 2017, 04:36:27 am »
The cone is determined by the accuracy value attributed to attempting to fire at a given target at x distance. Every weapon has a range after which you start losing accuracy rapidly(normally 2% per tile). Aimed>snap>auto. Also Sniper>rifle>smg>pistol.  Within accurate range with aimed shot(20 tiles) you get .6 times gal firing skill. So at most 72 within 20 tiles.

Snap range is not exposed on the spraygun so lets assume 15. Making the same 20 tile shot as before you get .5 of skill or max 60. Then apply the 2% per tile beyond 15. -10% on top of max 60 leaves 54.

Auto accurate range is normally 11 tiles, but again not exposed so assumption made. Same shot, .35 of skill or max 42. 9 tiles of accuracy penalties is -18%. Net result ~34.

Given that 20 aimed range is a reasonable reduction over baseline it's not unreasonable to assume the other ranges are reduced as well. Also the 2% per tile is not fixed either. Until someone goes ruleset diving we dont know for sure. We could be dealing with 20,10,5 and a 5% modifier for all we know. Potential extra bad modifiers on already bottom 1/4 in accuracy what do you expect?