Kantai Collection/Vita/Decompilation

From Bibliotheca Anonoma
Revision as of 16:32, 20 January 2017 by Antonizoon (talk | contribs)

The Kancolle Vita game provides the entire engine and logic of Kantai Collection in full, but in Unity. This makes decompilation and even a possible port to PC easy.

Unity uses one of two languages (C# and UnityScript), both of which use Microsoft's .NET framework. The .NET framework is cross-platform since it uses a unified bytecode format: Common Intermediate Language (CIL) which then runs on the portable Common Language Runtime (CLR). Like Java bytecode, CIL is designed for an idealized computer that is emulated by the CLR, so the bytecode is easier to decompile.

Move to PC Unity

It may be possible that the same binaries, which are cross platform, will work on a PC Unity project. I'm not familiar with using it but I can learn.

Decompiling Unity DLLs

Use ILSpy or dotPeek to open three files, Assembly-CSharp.dll, Assembly-CSharp-firstpass.dll, and Assembly-UnityScript.dll.

  • C#
  • UnityScript (JavaScript basically)

http://stackoverflow.com/a/5188580

http://www.alanzucconi.com/2015/09/02/a-practical-tutorial-to-hack-and-protect-unity-games

This is a starter guide to direct CIL editing:

http://resources.infosecinstitute.com/net-reverse-engineering-1cil-programming/#gref

Change strings within DLLs

An easy test case to prove that we can edit to strings is to do a simple test case:

  1. Server_Models/Mst_ship.cs Change なし to None
  2. Change all instances of なし to None in mst_ships.xml

If the modified Assembly-CSharp.dll works, this proves that DLLs can have their CIL code strings modified.

Decompiling Unity Assets

We do this all the time with the translation project, it's easy.

Recompiled/Reverse Engineered Replacement

After decompilation, the next step is to produce a completely reverse engineered version.

Engine

The first step is to simply extract the crucial game elements, and reimplement them in another form. This

UI and Visuals

The UI and Visuals must be implemented in Unity, since that's where the assets come from. This is a bit harder and can be more of a grey area. Maybe we could pitch this as providing Vita style visuals for the browser game.