DerekRies / arkpy

Work in Progress. Reverse Engineering the file formats for Ark: Survival Evolved. Read/Write with python.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Game won't load generated files

DerekRies opened this issue · comments

Reading and writing of files is working, BUT the SinglePlayer game isn't loading these files correctly. I'm not sure exactly what the problem is because even after deleting both LocalPlayer.arkprofile and LocalPlayer.profilebak, the game still ends up loading an older character. It's like if the game can't find a file or the file isn't valid (and the generated files aren't valid somehow), then the game looks in some hidden cache, the world file, or some other location to pull out a character.

Specifically this is for .arkprofile files and the Singleplayer game/directories. Game properly loads preset files, and I haven't tried generating/editing steamid.arkprofile files on a server.

Looks like when the game is started, the .arkprofile file is copied into the .profilebak file. Then on exit, the .arkprofile is saved, but the .profilebak isn't. Editing the .arkprofile in hex and leaving the .profilebak alone is working.

Part of the problem was removing the .profilebak file and generating an entirely new .arkprofile file. If changes are just made to an existing character it seems to be working. However, when I added experience and levels, the game refused to set the characters experience and level to these new values except the total engram points was now updated to the experience value I set. This leads me to believe the game stores levels and experience elsewhere, but at load-time the game read in the new experience value and updated the engram points before reading the actual experience values elsewhere and reverting the .arkprofile file to those values.

Stats Allocations also seem to be read-only from the .arkprofile. Any changes to them aren't respected by the game and must be stored elsewhere (cache or world file) Going to mark this as closed, and update the file-format specifications/docs with Read-Only flags where applicable.

Apparently it was working all along (apart from a few hiccups). The problem was all the duplicated data stored on the instance of your character in the world file is loaded first. All the data in the .arkprofile files isn't used until you respawn your character. Here's an example of a characters body color set to blue (beyond what you can choose in the character creator window)

arkbluemangroup