Announcement

Collapse
No announcement yet.

(Interheart) Custom AiDroid (かすたむアイドロイド)

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • [Mod Discussion] (Interheart) Custom AiDroid (かすたむアイドロイド)

    This thread is for technical mod discussion.

    Posting Rules
    - This is not a mod support thread. Post questions in the discussion thread.

    Tools
    SB3UGS by Alamar and enimaroah
    GokuakuExtract v0.5 (.fpk unpacker/packer) by ScumSuckingPig
    ItazuraRealKG (.KG unpacker/packer) provided by JamesHowlett
    XRip (replace components, like e.g. a mesh, in binary .x files) by ScumSuckingPig
    Mosaic remover (and uncensor texture info) by ScumSuckingPig

    Links
    Mod Release Thread
    Discussion thread
    The Texturing Discussion Thread
    The 3D Modeling Discussion Thread
    Last edited by Inquisitor; 04-17-2014, 08:50 AM.

  • #31
    Originally posted by Akikojam View Post
    Not sure if there's any thread for
    The first post will always tell you what a thread is and isn't for. This isn't a request thread.

    But somewhat related to technical; I saw some screens of the Jiburiru outfit on a vendor site, can't remember which one, and the wings included were more fairy-like. If we can get past the password for it, it may not require any modding at all.
    Brevity is the soul of...

    My Gallery Since 2008

    Comment


    • #32
      CAID in SB3U

      There is still some work to do, but with the first fix the FBX exports produced by REmRod can be imported without error. The warnings at the bottom are normal.

      As you can see mesh and skeleton are rotated when compared with Illusion models. The bone matrices seem to suffer under another incompatibilty, but the same problem I solved earlier in REmRod.

      Hope to finish a usable version this weekend.
      Attached Files

      Comment


      • #33
        Great progress there.

        I made a tiny tool that did some scaling and translation on pussy's UV coordinates. I moved them to the right side of UV space and set BODY11/BODY20's material to be the same as whole body. I fixed some textures to get seamless results without painting them by hand (thanks to texture projection between two UV channels in Blender and OBJ produced by Remrod). Its just empty skintone and tanline masks and still needs real pussy painting with mask editing to enable ingame pussy coloring, like nipples have.

        I treat it more like a proof of concept but it is possible to use this as a base for real uncensor if someone is interested. By looking at the UV space occupied by pussy its obvious that its in low resolution, especialy in TexL that requires 512x512 textures, and bigger one produces some nasty color leaking all over the body.

        Body part textures used by REAL are saved as TexL: 512x512(DXT5 compression), TexM: 1024x1024(DXT5), TexH: 1024x1024(no compression). As lower resolution in TexL is required that compression isn't mandatory I think. Tanline coloring is being done by mask's alpha channel, and mask's color is pure blue (0,0,255) almost everywhere but some tiny spots on breasts that make some specular highlight in game. Mask's color seams to also have some influence on body's skin tone and coloring.

        I will try other uncensor possibilities if i have more time, for example tan and coloring with tweaked material that uses MOSAIC texture. That would give texture with higher resolution. But still the best way would be having useable REM editor/exporter, and possibility to add new textures to .fpk files.

        BTW: By writing that files differs after back and forth conversion I meant that file size was smaller by few hundred kb's.
        Attached Files
        Last edited by arrival; 11-25-2011, 12:37 PM.

        Comment


        • #34
          Of course, using OBJ drops the skin completely as this format cant store it. It's text - have a look

          My attempts to install new meshes failed. May be due to too much geometry or the unknowns.

          Currently I'm searching for errors in the bone matrix handling between SB3U and REmRod. And even the frames in the hierarchy could be wrong in REmRod.

          Great to see you progressing!

          Comment


          • #35
            Oh, I forgot to ask. What is the data in REM file that sits right after each bone name in SKIO section? Name should be 256 chars but it ends earlier with null char, and then some really weird data pops up to fill this 256 block of data. REmRod seams to be ignoring it? After that comes vertex count, 4x4 matrix, vertex indices and weights.

            Code:
            ---------------------------------------------------------
            Skin section: SKIC,	length: 234456,	count: 26
            ---------------------------------------------------------
            	Skin: SKIO,	 length: 7824,	 mesh: body02,	 bones: 13
            		Bone: CH01HS_Head     ÔOçyĐ- ˜Oçyň0ëyÜĎ- Đ- Őçyň0ëyÜĎ-     Đ- şçy   čî/ hĐ- IMçyřě˘	`že    ő1ëyhĐ-  2ëy52ëy¸ápBđě˘	čî/ ěĆ„	    đě˘	    čî/                        čÚyŘÇ„	   4Đ- %ďy@Č„	dÇ„	&%ďy   ĚĂ„	   \Ç„	    ź:y   `   ŘÇ„	\Ç„	ĽĐ-    \Ç„	ěĆ„	ëăHy,
            			Vertex count: 22,
            			Matrix: [-0.000000, -0.000001, 1.000000, 0.000000]
            				[-0.103955, -0.994582, -0.000001, 0.000000]
            				[0.994582, -0.103955, 0.000000, 0.000000]
            				[-133.253555, 17.375204, -0.000032, 1.000000]
            			Verts: [65, 0, 71, 75, 77, 78, 81, 79, 74, 76, 80, 83, 143, 146, 149, 150, 151, 153, 152, 154, 155, 156]
            			Weights: [0.00251437, 2.2847e-05, 0.00026208, 0.00555364, 0.015811, 0.0317686, 0.0692852, 0.219516, 0.000998033, 0.0121712, 0.248921, 2.27491e-05, 0.00250591, 0.000260789, 0.000997424, 0.00552632, 0.012157, 0.0157449, 0.0316693, 0.219449, 0.248577, 0.0692432]
            About the OBJ: true, didn't think about that. Oh and I cant import anything with collada (.dae) file format in Blender: "Errors found during parsing COLLADA document".
            Last edited by arrival; 11-25-2011, 01:40 PM.

            Comment


            • #36
              When I learned the REM structure I also wondered, but finally found out that all identifiers are 256 bytes long. The generating process of the REM files dumps a piece of memory which is holding older data. It can be safely ignored. At least I think so. If anyone can find a meaning it would surprise me, because then the structure for the identifiers in that section would differ from the rest. And that is unlikely.

              The only chance for blender is to write a python script and convert either the REMs directly or use their textual representation from REM-U. If you want to use the output of REM-U, I will change the output of the faces.

              When I started I tried many formats and failed with all of them. And I found the concept of first having to define an Armature then Vertex Groups a bit strange.

              Edit:

              REmRod 0.4.2 released

              Changes:
              • It doesn't mirror the root frames anymore. This leads to bones and meshes being wrong sided.
              • The produced FBX can be imported by Maya and SB3Utility_v0.9.18_src_XA_minSDist_ATE_W02. REM meshes have not the same orientation as meshes in XX units.


              Sb3U can not handle DDS textures. These need to be converted manually to BMP or TGA.
              Last edited by enimaroah; 11-29-2011, 03:46 AM. Reason: last posts joined

              Comment


              • #37
                Mosaic Removal Tutorial

                The big free tour covers the extraction of mesh data, importing and exporting in Sb3U, editing in Metasequoia. Finally all the way back into the game. I included some extra info in the spoilers which is not required to successfully end the tutorial. The info therein is not as detailed as the outer descriptions.

                Tools used for this tutorial:
                AidriodExtract, REmRod, Sb3U, Metasequoia


                Getting a mesh out of the game

                1. Copy AidriodExtract.exe and REmRod.exe into your game folder.
                2. Open a command prompt: pushd {your game folder}
                3. AidriodExtract.exe KG\BODY\pt_BODY.fpk
                4. REmRod.exe "-m={your game folder}\KG\BODY\pt_BODY(v2)\zlc-BODY0000_00_00 (10892).REM"
                  REmRod needs an absolute path!


                Now we have a FBX and a UNK file, but for SB3U we need a special container. Any pp file will do, but if you dont have any you can take the attached base.pp.


                Importing into Sb3U

                1. Drop the pp file into Sb3U and click on it in the top left corner. Double click an XX unit below, e.g. centerXX.
                2. Needed only if you use an older version of Sb3U than SB3Utility_v0.9.18_XA_minSDist_ATE_W04:
                  Copy from your TEXH\TexH(v2) : "zlc-ch01_BODY_0000_01 (14919).dds", "zlc-ch01_BODY_0000_02 (14936).dds", "zlc-ch01_BODY_0000_03 (14953).dds", "zlc-ch01_MOSAIC_0000_01 (17844).dds", "zlc-PC_penis (5645).dds" into "{your game folder}\KG\BODY\pt_BODY(v2)"
                3. Drop the FBX file into Sb3U. 3D gets active, click on the file. A workspace window opens, click Add/Replace. Close or minimize the workspace window.
                  [ATTACH]213722[/ATTACH]
                  Spoiler
                  Workspace windows have a tendency to vanish behind the editor or the renderer. Either CTRL-Tab them to the front or choose the 3D tab at the top left corner. Click into the unused space, then on the name of the fbx. This will bring the workspace window to the front (even if it is minimized!!!)


                Change to the Mesh tab (right next to the Object Tree). Click on body01, shift click mosaicSphere. Click and hold anywhere in the renderer and pull up. Right click and hold to move the scene. The wheel scrolls in and out:

                [ATTACH]213492[/ATTACH]

                1. Select body11 in Mesh (Name is empty, click body11 again) then Goto Frame.
                2. Change the Name to body115 and Apply. This makes sure that the game will not find it (for applying the mosaic).
                3. The name needs also to be changed in the UNK file. It is a simple text file.



                Exporting a mesh for editing in Metasequoia

                Another way of selecting a mesh is to choose it from the hierarchy of the Object Tree:
                1. The plus before + mosaicSphere/Frame reveals 1 mesh object.
                2. Selecting this 1 mesh object shows nothing, but an empty Bounds box.
                  Spoiler
                  • This displacement is caused by skeletal animation. You'd have to remove all bones and set the mesh frame to the Identity matrix to see it in the box.
                  • If you play around with the bone matrices and mess it up : Remove the bone or the mesh completely. Then Uncheck All Nodes in the workspace and import the mosaicSphere alone. Messed up bone matrices are NOT replaced! Their removal is required in order to import the matrix again.

                3. Select Metasequoia as Export Options/Format and Export. Relative to your base.pp you'll find base\centerXX\meshes0.mqo.



                Editing in Metasequoia

                1. Drop the meshes0.mqo into Metasequoia and choose Open.
                  Spoiler
                  Insert will keep all objects already present. Open will clear the scene and takes the filename. You dont have to specify when saving later.
                2. Activate Command Panel in the Panel menu if it is not already visible.
                3. Select Select and in the Select window Normal.
                4. Click, hold and pull open a rectangle over a big part of the sphere. (The Edit Option Rc must be enabled. Disable Basic Mode in the File menu if this option is not visible.)

                  [ATTACH]213493[/ATTACH]

                5. Press Delete. Make sure that you have at least one triangle left in the mesh object. Press CTRL-Z to undo.
                6. Save with CTRL-S.



                The way back into the game

                1. Drop the meshes0.mqo into Sb3U, click on the file in the 3D tab and choose Add/Replace.
                2. Select all meshes which should be included in the export from body01 to mosaicSphere.
                3. Change the Export Options/Format to FBX 2011.3, then Export.
                4. Copy base\centerXX\meshes0.fbx to "{your game folder}\KG\BODY\pt_BODY(v2)\zlc-BODY0000_00_00 (10892).fbx"
                5. Delete "{your game folder}\KG\BODY\pt_BODY(v2)\zlc-BODY0000_00_00 (10892).REM"
                6. REmRod.exe "-i={your game folder}\KG\BODY\pt_BODY(v2)\zlc-BODY0000_00_00 (10892).fbx"
                7. Delete FBX and UNK file.
                8. AidriodExtract.exe "KG\BODY\pt_BODY(v2)"


                [ATTACH]213494[/ATTACH]

                I wasn't carefully enough when selecting in Meta. So you can see some triangles of the sphere remaining.
                Attached Files
                Last edited by enimaroah; 12-07-2011, 06:55 AM. Reason: because Sb3U now finds the textures without copying

                Comment


                • #38
                  The next tour introduces texturing and requires an understanding of the steps of the first tutorial. You will need a texture as replacement. I took a screenshot from another game, cutted, rescaled and converted it. It is attached, but far from being nice.

                  Tools used for this tutorial:
                  AidriodExtract, AidriodUnitJuggler, REmRod, Sb3U, Metasequoia*

                  *) the UV editor is not included in the LE version.

                  What we will do here is to change the uv mapping of a mesh. Use Sb3U to export body115 as MQO and drop it into Meta.


                  Positioning in Metasequoia

                  1. Enable Fr for backface culling.
                  2. Hold CTRL and right mouse button. Pull to the middle of the screen to turn the mesh 180 degrees (bottom up).
                  3. Release CTRL and press the right mouse button. Rotate horizontally 180 degrees until you see the frontside of the mesh.
                  4. Scroll in with the wheel. Move the scene with the middle mouse button.



                  Texturing in Metasequoia

                  1. Select UV in the Command Panel.
                    [ATTACH]213559[/ATTACH]
                  2. Double click Material__621. Correct the Texture/Ref by changing the path to the BMP texture. OK
                  3. Make sure that Unwrap, Object and Repeat are active.
                    Spoiler
                    Textures in CAid have a negative V coordinate. So the texture-wireframe is displayed above the normal address space (0..1).
                  4. Use middle mouse button and right mouse button/wheel for positioning. Watch the difference when the mouse is located over the mesh!
                  5. In the UV Edit window click Move.
                  6. Select all points of the texture-wireframe: click and hold in one corner, pull to the other, then release. (The Edit Option Rc must be enabled.)
                    [ATTACH]213560[/ATTACH]
                  7. Click and hold on a selected point of the texture-wireframe to move the whole net. Watch the mesh!
                    Spoiler
                    The U coordinates are mirrored. You need only half of the texture space.
                  8. Position the cluster of points for the anus.
                    [ATTACH]213562[/ATTACH]
                  9. Select Scale in the UV Edit window.
                  10. Click and hold in the center of the anus. It doesn't matter if you are over a point or not. But the position where you start the scaling matters! Then move upwards until the highest point is near the border of the texture and release.
                    [ATTACH]213563[/ATTACH]


                  Replace the body115 mesh with your work using Sb3U. Then use REmRod to generate a new REM file.


                  Replacing the texture in the game

                  1. Unpack the textures in the command prompt:
                    AidriodUnitJuggler.exe TEXH\TexH.fpk
                  2. Delete "TEXH\zlc-ch01_MOSAIC_0000_01 (17844).dds.comp"
                  3. Copy your texture to "TEXH\zlc-ch01_MOSAIC_0000_01 (17844).dds"
                  4. Delete "TEXH\zlc-ch01_MOSAIC_0000_01_mask01 (30829).dds.comp" and "TEXH\zlc-ch01_MOSAIC_0000_01_shade (29513).dds.comp"
                    Spoiler
                    These two should be specially prepared graphics. If you know how to make them please write a tutorial
                  5. Repack the fpk:
                    AidriodUnitJuggler.exe "TexH(v2)"


                  [ATTACH]213558[/ATTACH]
                  Attached Files

                  Comment


                  • #39
                    Great job on the tools and tutorials, enimaroah! It'll be interesting to see if what comes out of this...

                    Comment


                    • #40
                      Thanks alot Inquisitor!

                      The last update revealed another convenience for us. The hash code doesn't need to be broken. We simply put files where they should lie with their correct filename. This works even for already existing files. Here as example the TEXH\texh.fpk. Unpack the fpk with AidriodExtract. Move all files from TexH(v2) to their parent folder. Rename or delete the texh.fpk and strip the extra characters of each filename with the two batch files I attached. (Place them in the game folder and apply them in order.) Now the game takes all textures directly. It will speed up the loading process a bit because they are uncompressed

                      Edit:
                      • The Mosaic Removal tutorial had a "bug". Sb3U doesn't consider relative filenames in the fbx. See point 2 in "Importing into Sb3U" for a workaround. I apologize for any inconvenience.
                      • The next version of REmRod will consider meshes with several mesh objects. Works fine with Maya, but not with Sb3U. Still searching...
                      Attached Files
                      Last edited by enimaroah; 12-05-2011, 04:16 PM.

                      Comment


                      • #41
                        REmRod 0.5.0 released

                        • Meshes with multiple mesh objects are supported.
                        • Textures are also found in uncompressed form.


                        Be aware that Sb3U rotates the meshes compared to Maya. The current version of Sb3U requires the textures where the fbx is! Copy them manually.

                        Comment


                        • #42
                          Well I tried creating a texture for the original Mosaic material and I failed. Changing material properties (ambient, specular etc.) didn't helped a bit. I was unable to get seamless result this way. I dont know why using the same texture and material as I posted earlier works but not when I use two of them. Head is attached seamlessly and is using another material so why pussy isn't seamless?

                          Here is a quick overview of texture projecting technique I used while creating diffuse and mask textures: pdf.

                          I will probably publish body textures with pussy wraped somewhere in the unused space soon, as I'm going to create them for myself (along with tweaked rem file). Low res but still...

                          Comment


                          • #43
                            I see two problems with that way:
                            1. You loose the advantage to use a high res texture for the groin area alone. Wouldn't it be better to near the colours of the two textures with a paint program? The body texture as frame and colour source for the groin area. But I am not familiar with texture making.
                            2. The obj format can not be converted directly into a REM file, because you'd loose the skin. You have to use a temporary container : the XX unit. As long as you dont add or remove vertices you can use CopyNear or CopyOrder for applying when importing the obj file. Then export as FBX and finally convert that to REM. If you plan to make a 3d uncensor, I would highly recommend to find a way to edit FBX files directly.


                            What I couldn't see in your document was if you are aware of REAL's automatic use of several textures per material or not. Most of the textures have additional ones : *_mask01.dds, *_mask02.dds. These are related and would have to be painted also. Although I dont know how they are made.

                            Comment


                            • #44
                              Ad1. It would be better to use two textures but materials do not match, even if both color and masks do (attached image). And I do know about all those masks that REAL's using. Actualy color/diffuse is actualy preaty useless, its all about masks. In the pdf I was just using color map as an example, and I actualy did matched all other masks too. And both, with one texture for pussy and body (as in pdf file) and with two textures and materials (using mosaic file from .fpk). The second one do not work regardless perfectly matched textures and mask (attached image).

                              Ad2. Sorry but I dont get it. Dont know what are XX units and CopyNear or CopyOrder. Is it Maya or SB3U specific terminology? I realy am not interested in 3d uncensor. I just want to make textures for the existing meshes so I realy dont need to export any mesh. In the pdf file I was using directly edited REM file with some uv's translated and fliped in x axis to match it in unusead space, but in attached image you can see that I tried to make mosaic texture look seamlees with the original uv/material setup. And textures and masks do match seamlessly but somehow material is rendered differently inside the game.
                              Attached Files

                              Comment


                              • #45
                                Material attributes could be aligned in Sb3U. So you are producing a texture using projection. I though into a wrong way and assumed you were changing uv coordinates.

                                XX units are Illusion's containers for skinned meshes. If you would like to change an aspekt of the mesh and have to use the obj format for transport then you can use Sb3U.

                                1. use REmRod to produce an fbx
                                2. follow the steps of my Mosaic tut 'importing into sb3u'. Open pp file and xx unit.
                                3. put that fbx into sb3u and apply it to the xx unit. (storing the skin)
                                4. export any skinned mesh as obj (loosing the skin)
                                5. work with that obj file (dont add new vertices or delete any)
                                6. import the obj into sb3u
                                7. and apply it onto the mesh with Copy Near or Copy Order as the method for bone replacement.
                                8. export as fbx with sb3u
                                9. and with REmRod to REM


                                This way you can edit e.g. uv coordinates in blender and retain the skin.

                                Comment

                                Working...
                                X