Gildor's Forums

Author Topic: Mortal Kombat X  (Read 58457 times)
howfie
Newbie
*
Posts: 33


View Profile
Re: Mortal Kombat X
« Reply #45 on: April 23, 2015, 15:18 »

Thanks gildor, figured it out he he he.

Works great now.
http://snag.gy/MscbB.jpg

It was really simple:

aaaaaaaa bbbbbbbb cccccccc dddddddd eeeeeeee

converts to

bbaaaaaaaa ccccbbbbbb00 ddddddcccc0000 eeeeeeeedd000000

Hope you and your family are well.
Logged
Gildor
Administrator
Hero Member
*****
Posts: 7973



View Profile WWW
Re: Mortal Kombat X
« Reply #46 on: April 23, 2015, 15:35 »

Insane. I think I will not support this game  Shocked
Logged
UncleFestor
Newbie
*
Posts: 22


View Profile
Re: Mortal Kombat X
« Reply #47 on: April 23, 2015, 16:34 »

Well we don't need support for models, just the textures.

All we really need is to be able to extract the images from the Texture2d Files {export as dds}
Logged
USF
Newbie
*
Posts: 16


View Profile
Re: Mortal Kombat X
« Reply #48 on: April 23, 2015, 16:35 »

Works great now.
http://snag.gy/MscbB.jpg
I do not understand how you did it, I unpacked the files but could not use them, how did you do it? is it possible to just shove in 3d max model? Shocked
Logged
howfie
Newbie
*
Posts: 33


View Profile
Re: Mortal Kombat X
« Reply #49 on: April 23, 2015, 17:13 »

Works great now.
http://snag.gy/MscbB.jpg
I do not understand how you did it, I unpacked the files but could not use them, how did you do it? is it possible to just shove in 3d max model? Shocked

I used C++ to extract a single model from the game. Hard-coding offsets, etc. I have no interest in doing all the models, as Gildor's the Unreal man. It takes someone with more patience than I have to deal with all the million or so serialized objects that make up Unreal data. That man is Gildor lol.

My code looks like:

Code:
 //
 // FIXED PROPERTIES
 //

 uint32 n_verts = 0x5DE8;

 uint64 name_offset1 = 0x0EA9; // CHAR_Kitana_A
 uint64 name_offset2 = 0x0FD4; // CHAR_Kitana_A

 uint64 mesh_info_offset1 = 0x1136; // not important
 uint64 mesh_info_offset2 = 0x1699; // not important
 uint64 mesh_info_offset3 = 0x2CF8; // important!!!

 uint64 ib_offset = 0x02DA5; // index buffer
 uint64 jm_offset = 0x379DF; // joint map

 uint64 vb1_offset = 0x43B9C; // points
 uint64 vb2_offset = 0xE8120; // UV
 uint64 vb3_offset = 0xB91D4; // blending

 // move to surface information
 ifile.seekg(mesh_info_offset3);
 if(ifile.fail()) return error("Seek failure.", __LINE__);

 // read number of surface
 uint32 n_surfaces = LE_read_uint32(ifile);
 if(ifile.fail()) return error("Read failure.", __LINE__);

 // read surfaces
 boost::shared_array<MKXMESH> meshlist(new MKXMESH[n_surfaces]);
 for(uint32 i = 0; i < n_surfaces; i++) {
     meshlist[i].id    = LE_read_uint16(ifile); // id
     meshlist[i].jm    = LE_read_uint16(ifile); // joint map index
     meshlist[i].start = LE_read_uint32(ifile); // index buffer start
     meshlist[i].n_tri = LE_read_uint32(ifile); // number of triangles
     meshlist[i].bflag = LE_read_uint08(ifile); // some kind of flag
     if(ifile.fail()) return error("Read failure.", __LINE__);
    }

If I want another model I open it up in a hex editor and change the offsets lmao.
Logged
USF
Newbie
*
Posts: 16


View Profile
Re: Mortal Kombat X
« Reply #50 on: April 23, 2015, 18:13 »

can you please extract the model some of the characters from MKX?I'm just not versed in C++
Logged
ccc93
Newbie
*
Posts: 3


View Profile
Re: Mortal Kombat X
« Reply #51 on: April 23, 2015, 18:23 »

Well we don't need support for models, just the textures.

All we really need is to be able to extract the images from the Texture2d Files {export as dds}

Well some of the others would like to even play with the models too.
Logged
UncleFestor
Newbie
*
Posts: 22


View Profile
Re: Mortal Kombat X
« Reply #52 on: April 23, 2015, 18:33 »

Well, I guess for fun, but you won't be able to import those into MKX.

MKX uses an extremely modified version of UE3. The only program that can export a model into the correct format for the game to use is UDK. But you need the exact version that was used for MKX for the game to be able to read the models.

This is the exact reason why modding on MK9/MKKE wasn't as diverse as it was for SFxT or SFIV.

In MK9/MKKE even if you didn't change any vertices & all you did was export model, import to 3DSMax, export/import into UDK & save. Then inject into xxx package game would crash.

*EDIT*

However, most of the models are fairly basic. The game {MK9/MKKE/Injustice} utilizes the normal Maps extremely well & using Material swapping techniques & creating custom Norms, you can achieve really good results through just the textures. So as a starting point for a game like MKX which uses an even more modified version of UE3, focusing on extracting textures is the best starting point, imo, because it's usable for actual modding.
« Last Edit: April 23, 2015, 18:39 by UncleFestor » Logged
Gildor
Administrator
Hero Member
*****
Posts: 7973



View Profile WWW
Re: Mortal Kombat X
« Reply #53 on: April 23, 2015, 18:36 »

The only program that can export a model into the correct format for the game to use is UDK.
This game uses completely own skeletal and static mesh formats. Think of this like these developers obtained UE3 source code, dropped all mesh staff and wrote their own code. I think that's because basic UE3 has optimizations for complex scenes, but this game requires display of just 2 skeletal meshes (players) and probably 1 static mesh (scene). So they simplified everything, perhaps to save resources for something else (it works with PS3 and XBox360, not just with modern hardware).

That's why I can't find enough time to continue supporting this game.
« Last Edit: April 23, 2015, 18:39 by Gildor » Logged
UncleFestor
Newbie
*
Posts: 22


View Profile
Re: Mortal Kombat X
« Reply #54 on: April 23, 2015, 18:41 »

The only program that can export a model into the correct format for the game to use is UDK.
This game uses completely own skeletal and static mesh formats. Think of this like these developers obtained UE3 source code, dropped all mesh staff and wrote their own code. I think that's because basic UE3 has optimizations for complex scenes, but this game requires display of just 2 skeletal meshes (players) and probably 1 static mesh (scene). So they simplified everything, perhaps to save resources for something else (it works with PS3 and XBox360, not just with modern hardware).

That's why I can't find enough time to continue supporting this game.

And that's why I was recommending to just add support for texture exporting.


*EDIT*

All we really need is the ability to extract textures from Texture2D files.
« Last Edit: April 23, 2015, 18:43 by UncleFestor » Logged
Gildor
Administrator
Hero Member
*****
Posts: 7973



View Profile WWW
Re: Mortal Kombat X
« Reply #55 on: April 23, 2015, 18:44 »

And that's why I was recommending to just add support for texture exporting.
I'd glad to save my time and to switch to something else, but definitely some UModel users will not agree with that Smiley
By the way, I'll try to support meshes, and probably at some point I'll decide that this is too hard and I'll stop.
Logged
UncleFestor
Newbie
*
Posts: 22


View Profile
Re: Mortal Kombat X
« Reply #56 on: April 23, 2015, 18:52 »

Yeah, that's true. But I'm trying to view it from your perspective. It seems like an awful lot of work you would have to go through & an awful lot of time that you just don't have, to support models.

So, with that in mind, if our choices are textures only {maybe meshes down the line} or nothing. I would prefer textures. At least that way we can create costumes for characters.

The way I see it is, this is your hobby. You do it in your spare time & it's impossible to please everyone. Don't break your back for anyone. Whatever you're able to accomplish, people should understand that it isn't easy & appreciate what you provide regardless Smiley
Logged
Gildor
Administrator
Hero Member
*****
Posts: 7973



View Profile WWW
Re: Mortal Kombat X
« Reply #57 on: April 23, 2015, 18:54 »

Smiley
Logged
max_shift
Newbie
*
Posts: 4


View Profile
Re: Mortal Kombat X
« Reply #58 on: April 23, 2015, 19:49 »

hey howfie! could you please explain what exactly you did with those bone id's xDD
Logged
Straight Edge
Newbie
*
Posts: 13


View Profile
Re: Mortal Kombat X
« Reply #59 on: April 23, 2015, 19:53 »

Well we don't need support for models, just the textures.

All we really need is to be able to extract the images from the Texture2d Files {export as dds}
There is a very large community of people that would disagree with that. They rely on the models to create their own works of art or mods in other games.

But if you're truly unable to crack this game, gildor, then I thank you very much for your efforts in trying--that's what counts.
Logged
Jump to:  

Powered by SMF | SMF © 2006-2009, Simple Machines LLC
Leviathan design by Bloc | XHTML | CSS