Login

russian armor

Building a .dat file

6 Sep 2013, 14:56 PM
#1
avatar of RageWithTheMachine

Posts: 8

One of the things that made Dyxtra's program so amazing, was the separation of
data into a .dat file, which can be maintained by non programmers when the game
is updated.

It is possible to start mapping COH2 codes now. I uploaded a console program
(C2A.EXE) that chews replay files and produces stats according to the codes in a
data file (C2A.DAT) which you can edit with Notepad. It has many of the codes
for COH2 version 3.0.0.10416, but some stuff is missing.

Because of a techincal issue, it is currently only accurate for 1v1 games.

The text output of the program mixes known things with unknown codes, sorted by
timestamp. You can play a game, make notes of what you did and when, and easily
update the .dat file with the appropriate codes.

It would be (much) easier to do if Janne252's CheatCommands Mod was working.

Ideally, anyone who makes a mod for COH2 should only have to write their own
.dat file, and the replay analyzer should work with your mod. With any luck,
that might become true. This program tries to be generic. Any codes you discover
are specific to the game version, not to my program.

There are codes for
  • units
  • buildings
  • abilities
  • upgrades
  • doctrines
  • doctrinal abilities


The output includes counts of units produced, Commands Per Minute (CPM), number
of retreats, reinforcements, stuff like that.


'Console program' means that you have to open up a 'command prompt' and actually
type. It may also be convenient for use in web scripts. The way I see it, making
a GUI frontend is a separate project, and it could be done in any programming
language and possibly by someone else.

Put C2A.EXE and C2A.DAT in the same directory, and add that directory to
your PATH. Or, just put them in the same directory where your replays are, which
is normally C:\Users\YOURNAME\Documents\My Games\Company of Heroes 2\playback.



List basic info for all replays in the current directory:
Code
C2A.EXE *.rec


List the full command log:
Code
C2A.EXE -a replay.rec


List stats and bulletins for the players:
Code
C2A.EXE -s -b replay.rec



TIP: Piping. If you type "C2A.EXE -a replay.rec > output.txt" you get your log in a text file.
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

577 users are online: 577 guests
0 post in the last 24h
2 posts in the last week
28 posts in the last month
Registered members: 49389
Welcome our newest member, Haruta446
Most online: 2043 users on 29 Oct 2023, 01:04 AM