this very simple tutorial tells you how you can make any ValveBiped work as the player in Portal
Here I will show you how to make any player model work in Portal.
Step 1: extracting the model.
you will need GFCsrape. you will need this to get the already compiled model, say from GMod, CS:S, DOD:S, HL2DM, ect, out of it's VPK archive.
Step 2: Decompiling.
you will need Crowbar. You will need this do decompile the model into it's raw Text data.
Step 3: Editing.
I recommend Notepad++ for this, but it's not a requirement. Now that they are decompiled into raw text, edit the "(modelname).qc" file and where you see "$includemodel" pay attention to all of those names, you will need to copy them to your Portal custom folder. now, put a new line, and then put "$includemodel player/(male/female)_anims.mdl"
Step 4: Compiling the model.
you will need GUIStudioMDL for that (or use Crowbar again). Now that you have edited the model to have that extra line of text, compile it. It doesn't matter what game you chose, just copy the compiled model from it's install and move it to a custom folder in your Portal install.
Step 5: Setting it up to work in game.
Now that it's compiled, it SHOULD work. all you have to do is this:
- copy every thing that is listed in "$includemodel" in the SAME spot into your Portal custom folder.
- Download the animations for this and put it in the portal custom folder.
- Rename the model and it's parts you compiled to be called "chell.(whatever)"
Set 6: Try it out.
Test it in-game to see if it worked.
NOTE: sometimes the textures bug the fuck out when recompiling.
Could you add in some extra animations to get this to be compatible with Portal 2? Those animations would be: portalgun_airwalk portalgun_jump_float_tbeam portalgun_jump_float nogun_airwalk portalgun_tractorbeam_float portalgun_speedrun portalgun_jumpfloat portalgun_jump_spring noGun_jump_float portalgun_thrash_fall portalgun_speedpaint_run portalgun_standing_point portalgun_drown portalgun_somersault
> **Posted by 5magmacubes**
> what's the difference between male_anims and female_anims?
In the old version of the animations, it was only the bone length. In the final version (released yesterday), the male and female files use different idle animations, to remedy the weird snap in the old idle animation, and to fix the way the female animations made the characters hold their arms out.
The attachments for the most part aren't necessary. Attachments like forward, eyes, mouth and chest are required for facial animations. The portal gun model is attached via bonemerging, however, and not with model attachments. The modified w_portalgun.mdl included with the animations has both the Portal and ValveBiped hand bones, so it can merge to both types of models. Also, the textures screwing up upon recompile is most likely a product of the decompiler moving the uvmap down. Both MDLDecompiler and Crowbar do this. To fix it, you can either open the model in some form of editor and fix the UV map or disable "Clamp V Coordinates" on the vtf.