Monday, December 27, 2010

How to teach Imp to dance

A new video showing how to import Characolle dancing animation to SBZ figure, then export it to BioVision (bvh) file and then apply to Doom 3 Imp model (md5).


To be precise, the merged animation cannot be saved yet, expect more to come...

Wednesday, December 22, 2010

Importing Sexy Beach Zero figures

Current windows build of Khayyam can be downloaded from Floyd Sourceforge page.


Here is quick tutorial how to import SBZ figures. The similar procedure can be used for other multi-part meshes (SB3, School Mate etc) - but not all collection formats have working autodetection for textures, bones and so on.
From main menu select: Objects -> Import -> Import Xpp Mesh



Click "Choose directory..." and select the "data" subdirectory in installed game location.
At the right-left is the list of all collection files (.pp) in chosen location. For SBZ, the bodies are in file sb03_00.pp. The game format should be autodetected from file name, but if it fails, select "Sexy Beach Zero" manually from game dropdown list. After selecting correct collection file the contents of it should appear in lower-left list.
Female bodies are named cw_body_??_??.xx.
Keep "Hide extras" and "External textures" checked for now - these make oiling/massage guide mesh invisible and replace plain skin materials from predefined textures.
Select proper body model and the preview should appear at right. The common camera controls (middle and right drag) work similar way to the main window.
Click "Import". The import options dialog should appear.



If you are importing the first object, the only available option is "Import as standalone mesh". Keep "Create skeleton" checked if you want to pose the figure later. Click "Import".
Imported body appears in main window. But as there is no proper lighting, it looks plain.
Select "Object->Add->Directional Light" to make it better.



Select body by moving mouse over it (yellow highlight box should appear) and clicking. Selection is marked by orange wireframe around the body.
Now you are ready to import head. Again chose "Object->Import->Import Xpp mesh..."
From the collection list select the same collection, chose any of the head files (cw_head_??_??.xx) and click import.



The proper import options should be preselected. You have to import it as "Skin of selected mesh" so it will be controlled by the same skeleton. "Parent bone" and "Anchor bone" determine, which bones will be merged between existing body and new head skeletons. Click "Import" and voila - body has now head.
Repeat the same procedure with hair (the name of mesh is cw_hair_??_??.xx).



The next step is applying a texture to swimwear. For this we use builtin DOM editor - the most powerful tool of Khayyam.
Choose "Dialogs->Document Tree".
Expand "Scene" and then "Figure" nodes from left-hand tree view. Figure is a poseable object, that can have multiple skins (body, head, clothes) controlled by the single skeleton and additional poseable objects (like items at hand). The imported SBZ meshes are "GeometryXX" nodes. Select the first one of them (the body mesh).



At the right side there are tabs for the selected node and its parent classes. At moment we are interested in the Xpp geometry node itself (GeometryXX). You can see the list of all used internal materials, with visiblity checkboxes and optional external material ids. Importer autodetection should have made oiling guides invisible already. The body materials should have external textures attached (materialDNS_6 and materialDNS_5).
Select bra material mn_mizugi_00_00. From dropdown box below select "Create new" and click "Apply". This creates new texture override node for bra and opens material editor to define texture for it.
Texture editor looks like similar to Xpp mesh importer. First click "Choose directory" at top left and navigate to "data" directory under the installed game.  From "Show files" dropdown list chose "Collections". Select the collection with swimwear textures (sb06_00.pp). From Type dropdown list select "Sexy Beach Zero" (it is not autodetected at moment).



At lower left list are all available textures from that collection. Select the one you like and click "Apply".
The selected material is now updated with chosen texture. As a next step, apply the same texture to panties and inner sides of swimwear.
Select "mn_mizugi_01_00" from material list. From dropdown list below select the new material created for bra (materialDNS_2) and click "Apply". repeat the same procedure from the inside of swimwear (mn_mizugi_00_01 and mn_mizugi_01_01).



And thats all. You have just imported Sexy Beach Zero girl with swimwear.

For posing there is skeleton mode (the small button with figure and blue bones in toolbar).
Before proceeding further it is good idea to familiarize yourself with document tree editor a bit - for example hiding bones without skin and extra bones you may not want to edit.
Importing scene is similar to importing figure - just make sure, that you import it as standalone object.

And last thing - save often. Khayyam is still alpha, so it has a bad habit to crash frequently.

Monday, December 13, 2010

Sexy Beach Zero

SBZ is the latest hentai game from Illusion (look at ontopic Hongfire forum if you want to know more and do not mind erotic content). Like other Sexy Beach games, it's gameplay is quite unfun - woo girls, talk, date, and massage them, change swimwear and have sex - but it has upgraded rendering engine (although not very good) and, most importantly, semi-realistic (but still pretty) models. So I have spent the last days in trying to get Khayyam to read, render and pose those as well as possible.

To make character customization possible, models are composed of three separate parts - body, head and hair. Also - because the game allows you to "tan" girls - neither body nor head texture is embedded in mesh, but instead has to be loaded separately. Same with swimwear textures. Body also has extra "envelope" layer, that is used to guide hand and oil during oiling/massage scenes.

The skeleton has become even more complex, compared to previous models. One reason for this seems to be, that ingame body customization is now done with adjusting hidden bones.

Full skeleton of a SBZ model
The item and clothing collection is very uninteresting, like one can expect from Sexy Beach series. Maps are of better quality than in previous games, but there are only few of them.
Ai in jungle (rendered with POV-Ray)
And a render for you. It has too much focal blur, but I am too lazy at moment to make better one ;) The girl is Ai, who first appeared in Real Girlfriend, background is daytime jungle map from SBZ. Lighting consists of one area light (daylight) plus 2 greenish spotlights to illuminate shadows.