Login

russian armor

[Release] DeCoHde 2.0 (Snake Edition!) WIP [Help needed]

13 Apr 2020, 13:03 PM
#41
avatar of Vipper

Posts: 13496 | Subs: 1


...

Wull do some testing

Good work

Since cheat mod can measure the damage done to units I suspect that a decent moder could create a mod that also measures the ROF of units and thus the in game DPS.
13 Apr 2020, 16:37 PM
#42
avatar of Hannibal
Senior Moderator Badge

Posts: 3114 | Subs: 2

jump backJump back to quoted post13 Apr 2020, 13:03 PMVipper

Good work

Since cheat mod can measure the damage done to units I suspect that a decent moder could create a mod that also measures the ROF of units and thus the in game DPS.



See this:
https://www.coh2.org/topic/104909/rof-doesn-t-quite-work-as-we-thought-it-did
14 Apr 2020, 13:54 PM
#43
avatar of Hannibal
Senior Moderator Badge

Posts: 3114 | Subs: 2

The program has developed nicely so far. Tank combat is now fully simulated at a given distance and I plan to release a first version soon.

Below you can find a showcase of what it can do and how to use it (there is no pretty GUI, so you will have to do with the command window):

After start up:

The program has three functions: inspect, tank targeting simulation (what I showed in the opening post) and tank fight simulation. Just type in the number to use them. In the background you see the folder with the file in it.


[1] The inspector:

Currently there are only a hand full of units added which are printed to you in the list. Just type in the name. This allows you to check some stats if you are interested or to see if they are still up to date.


[2] Tank targeting simulation

This simulates one tank shooting at the other without the target firing back. DeCoHde asks you to choose the shooter, target, angle, distance and how many simulations to run. Make sure that the distance is within the range of the shooter, otherwise the program will not be able to finish calculation. DeCoHde writes two files: One summary where the most important data of each simulation is stored, and a detailed report where you can see what happened to each shot during the simulation.


[3] Tank fight simulation

DeCoHde's core and glory.
You need to enter two vehicles and their angles. You can also add a shot delay for the second vehicle, the number of simulations and a "retaliation shot time". This is the time after which the loosing vehicle is still allowed to fire after the killing shot has been fired. This value basically simulates the air time for the projectile, as well as "out of control" crits during which a dead vehicle can still fire in-game.

In the example, the following situation is simulated:
A Tiger sneaks around a shot blocker to flank the IS2 from and gets a 30° angle. This allows the Tiger to shoot the rear armor if it is lucky. The Tiger drove up frontally to the IS2, so the IS2 can only hit the frontal armor (0° angle of the Tiger). Since the IS2 got flanked, it still needs 2 more seconds to rotate its turret to shoot back at the Tiger. The fight takes place at 30 meters until one of the vehicles is killed.

The simulation generated this output file:

In simulation 46 you can see that there was a draw between both. The IS2 would have won, but the Tiger shot back within the retaliation time and dealt the killing blow to the low health IS2 as well. These draws occurred in 4 out of the 1000 simulations. Overall, the Tiger won in 2 out of 3 cases, the IS2 defended itself successfully in 1 our of 3 cases.
Otherwise you can also take a lot of data from the sheet, like how many shots were fired, the remaining health of the winner in the summary file.
14 Apr 2020, 14:00 PM
#44
avatar of Vipper

Posts: 13496 | Subs: 1

interesting work, maybe add double check result with 10+ in game fights?
14 Apr 2020, 14:26 PM
#45
avatar of Hannibal
Senior Moderator Badge

Posts: 3114 | Subs: 2

jump backJump back to quoted post14 Apr 2020, 14:00 PMVipper
interesting work, maybe add double check result with 10+ in game fights?

In-game:
Out of 30 frontal fights at range 20, Tiger won 16 (53%), IS2 won 13 (43%). One draw (3%).

Sim:
Out of 5000 simulations, Tiger won 3075 (61%), IS2 won 1923 (38%), 2 draws.

I saw quite a variation though with the in-game. First 15 fights the IS2 won 8, second run they won 5. RNG god also had some fun and gave me 4 abandons while only 1-2 would be expected (this obviously has nothing to do with the rest).

Did not check the HP though. I will soon implement to check the time it needed to kill the other tank, this should give a decent hint if the sim is alright or not.
14 Apr 2020, 15:14 PM
#46
avatar of Vipper

Posts: 13496 | Subs: 1


In-game:
Out of 30 frontal fights at range 20, Tiger won 16 (53%), IS2 won 13 (43%). One draw (3%).

Sim:
Out of 5000 simulations, Tiger won 3075 (61%), IS2 won 1923 (38%), 2 draws.

I saw quite a variation though with the in-game. First 15 fights the IS2 won 8, second run they won 5. RNG god also had some fun and gave me 4 abandons while only 1-2 would be expected (this obviously has nothing to do with the rest).

Did not check the HP though. I will soon implement to check the time it needed to kill the other tank, this should give a decent hint if the sim is alright or not.

Interesting. They seem as a good indication.

For doing test you can probably create many vehicles save the game before fight do the fight and reload.
23 Apr 2020, 18:55 PM
#47
avatar of Hannibal
Senior Moderator Badge

Posts: 3114 | Subs: 2

RELEASE VERSION


Release version of DeCoHde - Snake Edition.


Download Python version here: Python version

Download executable version here: Executable version


By pressing the link, you will be redirected to download a .zip file from coh2.org. This zip file contains either a Python file or an executable, depending on what you downloaded.
For running the Python file, you will need a version of Python 3 (I am using 3.7 at the time of posting). If you have any security concerns you can also open the file with a standard text editor program and have a look at the code even if you do not have Python installed.
For running the executable, you do not need anything. However, you cannot look at the code as the whole thing is already compiled. It also runs slightly slower than the Python version, but does the same job.
To report the simulation outcomes, DeCoHde 2.0 will create up to three .txt files in its own directory if you chose the targeting or the tank combat sim (options 2 and 3, respectively).


If you want to have a detailed look at what this program can do, check out this post. In short, DeCoHde 2.0 can simulate a shootout between two tanks, as well as simulating one tank shooting at the other (without the target firing back). This can help you to analyse how long it takes to take out an enemy tank, how many shots will hit, bounce, penetrate etc. If you are interested in unit stats, you can also use the "inspect" mode to get them (plus some additional stats that are not used in-game, but needed for the program itself)

If you come across any outdated stats, please post here or write me a PM :)



This project still needs some help beyond release!
The biggest problem right now is that I do not know the in-game hit box sizes of the tanks. I took the real life size from Wikipedia instead. However, this could mean that scatter shots might not be 100% true to the in-game situation. If you know how to get the in-game hit box sizes, please let me know.


Finally a thanks especially to MMX for discussions and clearing up some stuff on the scatter model, as well as Vipper for providing a mod to prove the used model.



If you have any questions, feel free to ask!

Hannibal




EDIT: Note: Just saw that the Puma's stats are screwed up because I inserted one value at the wrong place.
23 Apr 2020, 19:12 PM
#48
avatar of Doomlord52

Posts: 960

Fantastic work; this will almost certainly be a valuable tool for the community.

The biggest problem right now is that I do not know the in-game hit box sizes of the tanks. I took the real life size from Wikipedia instead. However, this could mean that scatter shots might not be 100% true to the in-game situation.


This aspect won't be accurate; CoH2's vehicles are scaled a lot, and in completely arbitrary ways. For example, compare the 222 and the T34. In game, the T34 is only slightly larger, whereas in reality, the 222 is 4.8m long, compared to the T34s 6.7m.
23 Apr 2020, 20:31 PM
#49
avatar of Hannibal
Senior Moderator Badge

Posts: 3114 | Subs: 2

Fantastic work; this will almost certainly be a valuable tool for the community.



This aspect won't be accurate; CoH2's vehicles are scaled a lot, and in completely arbitrary ways. For example, compare the 222 and the T34. In game, the T34 is only slightly larger, whereas in reality, the 222 is 4.8m long, compared to the T34s 6.7m.


Thank you very much.

Yes, I know. This is why I need the in-game sizes. I am pretty sure that my scatter simulation is accurate, the only thing missing are the actual hit boxes to calculate scatter hits.
I have tried to measure a P4 by building sand bags around it, but this is a very weird thing to do. I assume it's pretty imprecise and also not feasible for that amount of vehicles. There must be a better way.
23 Apr 2020, 20:39 PM
#50
avatar of Vipper

Posts: 13496 | Subs: 1

I guess one could start a wold builder (with range map probably) and bring the vehicles as items then the hit boxes would become visible.
23 Apr 2020, 21:06 PM
#51
avatar of Hannibal
Senior Moderator Badge

Posts: 3114 | Subs: 2

jump backJump back to quoted post23 Apr 2020, 20:39 PMVipper
I guess one could start a wold builder (with range map probably) and bring the vehicles as items then the hit boxes would become visible.

Someone already suggested this when I posted the showcase. But I do not know my way around the world builder.
24 Apr 2020, 09:40 AM
#52
avatar of Vipper

Posts: 13496 | Subs: 1


Someone already suggested this when I posted the showcase. But I do not know my way around the world builder.

I would ask one of the map makers to create a map with grid add the vehicle and print screen while selected so that the hit box can be revealed and measured.
MMX
24 Apr 2020, 11:57 AM
#53
avatar of MMX

Posts: 999 | Subs: 1

awesome work, congratulations on the release! hope this will receive the attention it absolutely deserves.
MMX
12 Jun 2020, 10:24 AM
#54
avatar of MMX

Posts: 999 | Subs: 1

Just gave the tank targeting simulator another try to gather some data for the Tiger. While it worked like a charm for the Tiger vs Sherman matchup at 0° angle and 40 m distance, the program crashed for any other target I've tried (KV-2, Pershing, Sherman E8, Comet). Works fine for other shooters, though (Panther, Jagdtiger).

EDIT:

Seems to happen for some other tank vs tank combinations as well. For instance, OST_P4 vs Puma works fine, but bugs out against Comet and Sherman E8.
Using the .exe version btw.
12 Jun 2020, 11:03 AM
#55
avatar of Hannibal
Senior Moderator Badge

Posts: 3114 | Subs: 2

Did you use the exe file?
I encountered this issue too with some but not all units. The python file worked perfectly well.
However be aware that there is a code error that leads to accuracy not being calculated if one unit is firing between mid and short range.

Also someone once posted some ingame data of about 50 shots of a SU85 against (I can't remember) a Brummbär or something. Although not a huge dataset, I used it to check how far off the simulation is, and for this special setup it undrrestimated the hit chance by about 10%, most likely due to the hit boxes that are not the ones in game.

I might release at least the bug fix update together with the new data update this weekend, but in its current form I would highly advise against using the sim to get'hard data' for discussions. It can make some estimations and surely confirm larger differences, but I don't think it will really detect slight unit adjustments or be able to tell apart similar units where one might be slightly stronger than the other.
MMX
12 Jun 2020, 11:34 AM
#56
avatar of MMX

Posts: 999 | Subs: 1

ah, thanks for the heads-up. will try to play around with the python version for the time being then. looking forward to the next version for sure
1 user is browsing this thread: 1 guest

Ladders Top 10

  • #
    Steam Alias
    W
    L
    %
    Streak
Data provided by Relic Relic Entertainment

Replay highlight

VS
  • U.S. Forces flag cblanco ★
  • The British Forces flag 보드카 중대
  • Oberkommando West flag VonManteuffel
  • Ostheer flag Heartless Jäger
uploaded by XXxxHeartlessxxXX

Board Info

1110 users are online: 1 member and 1109 guests
Brick Top
1 post in the last 24h
9 posts in the last week
27 posts in the last month
Registered members: 50008
Welcome our newest member, Goynet40
Most online: 2043 users on 29 Oct 2023, 01:04 AM