Resources

[TUT]Getting Player Models InGame

Re: [TUT]Getting Player Models InGame

Postby Shilo » 03 Mar 2010 22:52

As far as I know, the camera doesn't have much to do with the actual model...

Do all the other models work fine when you use that camera?
User avatar
Shilo
Smoker
Smoker
 
Posts: 140
Joined: 07 Jun 2009 15:59
Location: Toronto, Ontario, Canada
Title: Legal Assassin
Steam ID: Shilo_Wallace
Favourite Survivor: Zoey
 

Re: [TUT]Getting Player Models InGame

Postby Nahka » 05 Mar 2010 04:29

All original models work fine, only my model has that camera problem. I've found some more problems that I think are somehow connected to this problem since I have no idea what could cause them:
- I can only play as Rochelle, I get about 1fps or at least microstuttering if I play as another character
- The first map runs fine, the second has same problems as if I plaed as another character
- In the end of the second map the saferoom door cannot be closed, the round just goes on even when it is closed
- If I play as another character, Rochelle can randomly die before the campaing intro. No fps drops or microstuttering until I save her.

All these problems occur in single player and only if I have Rochelle replaced. Now that I'm thinking of it, Any chance these could be caused by compiling the model for a wrong game? I compiled it for L4D because I haven't been able to get L4D2 compiler working.
Nahka
L4DMods Newbie
L4DMods Newbie
 
Posts: 12
Joined: 18 Jul 2009 07:44
Steam ID: Nahkamestari

Re: [TUT]Getting Player Models InGame

Postby Tsumetai » 05 Mar 2010 16:58

This is a great tutorial, and for the most part, seems to work fine in L4D2, but I have three problems that don't seem to be addressed here.
1: Gray eyes. This was mentioned way back on page 3, and I've seen custom models people have made with the eyes intact, but no one ever mentioned it again… How do I fix the gray eye syndrome?

2: He wont hold a melee weapon. Instead the melee weapon just sits upright in between his legs, at the model's origin. I'd imagine this was some kind of problem with a missing bone, but I'm at a loss as to what.

3: His right hand is messed up. Instead of gripping weapons, his hand "snakes" around them, also his upper arm seems to have some distortion, almost as if his whole arm gets twisted. The skinning looks fine in Max, and isn't any different than the left arm, which doesn't have these issues.
Tsumetai
L4DMods Newbie
L4DMods Newbie
 
Posts: 8
Joined: 05 Mar 2010 16:32

Re: [TUT]Getting Player Models InGame

Postby Shilo » 05 Mar 2010 18:01

Nahka wrote: Now that I'm thinking of it, Any chance these could be caused by compiling the model for a wrong game? I compiled it for L4D because I haven't been able to get L4D2 compiler working.


Shouldn't be a problem.. I don't have L4D2 but.. they are the same version of the engine (I believe) so I don't think it should be a problem.

About the randomly dieing.. I think my Nathan model did that a few times, I loaded into a new game and he instantly turned into a puddle of blood with a scream =(. Can't quite recall what caused this.. perhaps the phymodel or ragdoll models aren't quite right? The saferoom door issue is also making me thing phymodel.. is the physics model really big? Go in your model viewer and check the option for the Physics Model in the Render tab to see what it looks like. It should shape closely around the model.

--------------------------------------------------

Tsumetai wrote:1: Gray eyes. This was mentioned way back on page 3, and I've seen custom models people have made with the eyes intact, but no one ever mentioned it again… How do I fix the gray eye syndrome?


I have yet to actually try this myself.. but since it is basically the same engine, it should work : http://veazie.org/Tutorials/XSIAddingEyes/HL2_Adding_Eyes.html
Just skip the script stuff and look at the mesh setup and qc stuff. I assume a "cluster" is like an object is in max.

Tsumetai wrote:2: He wont hold a melee weapon. Instead the melee weapon just sits upright in between his legs, at the model's origin. I'd imagine this was some kind of problem with a missing bone, but I'm at a loss as to what.


Get your mesh, reimport the original model's skeleton, make sure you get the weapon bones with it and don't delete them by mistake (I did that once). There are 3 that I can see with L4D2 models, ValveBiped.weapon_bone, weapon_bone_Clip and weapon_bone_extra. Re-rig it.. That is the only thing I can think of. Check in your model viewer to see if the bones are there. You should be able to see a list of them all in the Bones tab. If that's not it, check to make sure you have all the attachments still in the qc file. Does L4D2 has an attachment in there just for melee? Perhaps you didn't add it?

Tsumetai wrote:3: His right hand is messed up. Instead of gripping weapons, his hand "snakes" around them, also his upper arm seems to have some distortion, almost as if his whole arm gets twisted. The skinning looks fine in Max, and isn't any different than the left arm, which doesn't have these issues.


Hmm.. that is odd.. only thing I can say is study one of the original models skinning and make sure yours looks like that.. Did you move the bones at all by any chance in the reference model? That could cause problems if you did that, even mistakenly.
User avatar
Shilo
Smoker
Smoker
 
Posts: 140
Joined: 07 Jun 2009 15:59
Location: Toronto, Ontario, Canada
Title: Legal Assassin
Steam ID: Shilo_Wallace
Favourite Survivor: Zoey
 

Re: [TUT]Getting Player Models InGame

Postby Tsumetai » 05 Mar 2010 22:44

Shilo wrote:
Tsumetai wrote:1: Gray eyes. This was mentioned way back on page 3, and I've seen custom models people have made with the eyes intact, but no one ever mentioned it again… How do I fix the gray eye syndrome?


I have yet to actually try this myself.. but since it is basically the same engine, it should work : http://veazie.org/Tutorials/XSIAddingEyes/HL2_Adding_Eyes.html
Just skip the script stuff and look at the mesh setup and qc stuff. I assume a "cluster" is like an object is in max.
This doesn't work. It also doesn't make sense, the original models don't have the eyes as separate objects, or even separate sub-objects, just a different material index. I also didn't modify the head of this model in any way.

Also, in the qc file of the original models, the two "eyeball" lines that the tutorial talks about are commented out with "//-doesn't work", so I imagine eyes are handled a different way now.

Shilo wrote:
Tsumetai wrote:2: He wont hold a melee weapon. Instead the melee weapon just sits upright in between his legs, at the model's origin. I'd imagine this was some kind of problem with a missing bone, but I'm at a loss as to what.


Get your mesh, reimport the original model's skeleton, make sure you get the weapon bones with it and don't delete them by mistake (I did that once). There are 3 that I can see with L4D2 models, ValveBiped.weapon_bone, weapon_bone_Clip and weapon_bone_extra. Re-rig it.. That is the only thing I can think of. Check in your model viewer to see if the bones are there. You should be able to see a list of them all in the Bones tab. If that's not it, check to make sure you have all the attachments still in the qc file. Does L4D2 has an attachment in there just for melee? Perhaps you didn't add it?
There are no attachments that the other survivors have that my model doesn't. From what I can gather after further research is that the problem is weapon_bone_extra. It was in the model I imported into Max, it's in the smd file I exported from Max, but when I use studiomdl to create the compiled model files, that bone apparently disappears. It's clearly in the smd file before compiling, but after I compile and open up the model in model viewer, that bone is no longer there.

No idea why.

Tsumetai wrote:3: His right hand is messed up. Instead of gripping weapons, his hand "snakes" around them, also his upper arm seems to have some distortion, almost as if his whole arm gets twisted. The skinning looks fine in Max, and isn't any different than the left arm, which doesn't have these issues.


Shilo wrote:Hmm.. that is odd.. only thing I can say is study one of the original models skinning and make sure yours looks like that.. Did you move the bones at all by any chance in the reference model? That could cause problems if you did that, even mistakenly.
No I didn't. The hands and bones, as well as their locations, are copied from the original.
Tsumetai
L4DMods Newbie
L4DMods Newbie
 
Posts: 8
Joined: 05 Mar 2010 16:32

Re: [TUT]Getting Player Models InGame

Postby Nahka » 06 Mar 2010 07:57

Tsumetai wrote:This is a great tutorial, and for the most part, seems to work fine in L4D2, but I have three problems that don't seem to be addressed here.
1: Gray eyes. This was mentioned way back on page 3, and I've seen custom models people have made with the eyes intact, but no one ever mentioned it again… How do I fix the gray eye syndrome?

2: He wont hold a melee weapon. Instead the melee weapon just sits upright in between his legs, at the model's origin. I'd imagine this was some kind of problem with a missing bone, but I'm at a loss as to what.

3: His right hand is messed up. Instead of gripping weapons, his hand "snakes" around them, also his upper arm seems to have some distortion, almost as if his whole arm gets twisted. The skinning looks fine in Max, and isn't any different than the left arm, which doesn't have these issues.

I have problems 1 and 3 too, I think the hand problem is caused by rotated bone while decompiling. Bloocobalt had the same problem, never got it fixed. About the eyes, I messed around with the values in the qc, got one pupil visible but still way off from the correct position. I'd say the "//-doesn't work" code works, but the values are wrong.

Shilo wrote:Shouldn't be a problem.. I don't have L4D2 but.. they are the same version of the engine (I believe) so I don't think it should be a problem.

About the randomly dieing.. I think my Nathan model did that a few times, I loaded into a new game and he instantly turned into a puddle of blood with a scream =(. Can't quite recall what caused this.. perhaps the phymodel or ragdoll models aren't quite right? The saferoom door issue is also making me thing phymodel.. is the physics model really big? Go in your model viewer and check the option for the Physics Model in the Render tab to see what it looks like. It should shape closely around the model.

The phymodel is original, no problems there. I'm not sure about the ragdoll though, it might have some problems since the model is damn hard to spawn in Gmod. Anyway, I don't think that's the reason, first saferoom door works perfectly.
Nahka
L4DMods Newbie
L4DMods Newbie
 
Posts: 12
Joined: 18 Jul 2009 07:44
Steam ID: Nahkamestari

Re: [TUT]Getting Player Models InGame

Postby Shilo » 06 Mar 2010 20:25

Tsumetai wrote:This doesn't work. It also doesn't make sense, the original models don't have the eyes as separate objects, or even separate sub-objects, just a different material index. I also didn't modify the head of this model in any way.

Also, in the qc file of the original models, the two "eyeball" lines that the tutorial talks about are commented out with "//-doesn't work", so I imagine eyes are handled a different way now.


As Nahka wrote, it does work and it does make sense. I figured it out last night from that tutorial. If you open an smd you made yourself in notepad or something, you can see it will still list the separate objects. It's probably only the decompiler that groups them all together. When you are doing this, like the tutorial says, you have to create two new objects the same shape as the eyes, name one tex_eye_l and one tex_eye_r. Make sure you put separate textures on them named eyeball_l.tga and eyeball_r.tga respectively.

The values in the "eyeball" lines do have to be unique to your new model though.
For mine I used : (don't mind the Bone01, change that to your model's head bone)
Code: Select all
eyeball righteye "Bone01" -1.098 -2.312 64.65 "eyeball_r" 1.00 4 "grn_pupil_r" 0.5
   eyeball lefteye "Bone01" 1.098 -2.312 64.65 "eyeball_l" 1.00 -4 "grn_pupil_r" 0.5


The big thing I really had to change was :
Code: Select all
$attachment "eyes" "Bone01" 3.56 -2.83 0.01 rotate -90.00 0.00 0.00

I had to change the rotation to get it to show up right. And voila!

Image

There are no attachments that the other survivors have that my model doesn't. From what I can gather after further research is that the problem is weapon_bone_extra. It was in the model I imported into Max, it's in the smd file I exported from Max, but when I use studiomdl to create the compiled model files, that bone apparently disappears. It's clearly in the smd file before compiling, but after I compile and open up the model in model viewer, that bone is no longer there.

No idea why.


What smd exporter are you using? To test, try to skin just 1 vertex to that bone, that should keep it from disappearing when you compile. See if it stays and if it will carry a weapon then.

No I didn't. The hands and bones, as well as their locations, are copied from the original.


Well then.. without actually seeing it, I can only surmise that there is something wrong with the skinning job.. Again, as Nahka said, it sounds like a rotated bone, possibly the clavicle. If you made absolutely sure you didn't touch them while working on them, then what smd exporter are using again, and what model compiler? Maybe try alternate ones and see if it still happens?


---------------------------------------------

Nahka wrote:I have problems 1 and 3 too, I think the hand problem is caused by rotated bone while decompiling. Bloocobalt had the same problem, never got it fixed. About the eyes, I messed around with the values in the qc, got one pupil visible but still way off from the correct position. I'd say the "//-doesn't work" code works, but the values are wrong.


Like I wrote above, those eyes settings worked for me. If you are using an original model, try use the numbers that are there already in the eyeball lines, but change the rotations in the $attachment "eyes" line.

Again, as with the bone thing, all I can think of is try to re-rig again, try it with a different skeleton maybe, or a different decompiler or smd exporter.

The phymodel is original, no problems there. I'm not sure about the ragdoll though, it might have some problems since the model is damn hard to spawn in Gmod. Anyway, I don't think that's the reason, first saferoom door works perfectly.


Maybe try to compile using the guistudiomdl and see if you get any warnings? I would check on that ragdoll too. Hmm..
Last edited by Shilo on 08 Mar 2010 01:10, edited 1 time in total.
User avatar
Shilo
Smoker
Smoker
 
Posts: 140
Joined: 07 Jun 2009 15:59
Location: Toronto, Ontario, Canada
Title: Legal Assassin
Steam ID: Shilo_Wallace
Favourite Survivor: Zoey
 

Re: [TUT]Getting Player Models InGame

Postby Tsumetai » 07 Mar 2010 01:18

Eyes: The part that I said that doesn't make sense is the part where those lines of codes concerning the eyes are commented out in the original qc files, suggesting they're using another method. In any event, I did what you said, and got it so that the eyes work properly in model viewer. Unfortunately, they don't work properly in game! They start off looking forward when a game first starts, but then they start to wander freely, looking in any random direction, spending most of their time inside his head, but occasionally they come forward again.... needless to say, the effect is very creepy. Anyways, this is probably what they meant by "doesn't work".

Any ideas?

weapon_extra: I'm using the exporter from wunderboy.org for Max 9. Like I said, that bone IS in the .smd file exported from max, looking over the smd file, I see nothing wrong with it, in fact it parallels the nearby weapon_bone_Clip in terms of use, linkage, etc. It's when I use studiomdl to compile the mdl files that the bone seems to disappear. I manually added a hidden triangle into the smd, telling it to be fully influenced by that bone, and that seemed to work. Odd though, because weapon_bone_Clip doesn't influence anything at all, studiomdl must be configured to exempt that bone from being excluded, but weapon_bone_extra is not. Weird. Perhaps something wrong with my studiomdl?

HOWEVER. It didn't fix the melee weapon problem. >_< This is very frustrating. I did learn that this problem doesn't effect every melee weapon. For example, it effects the fire axe and the baseball bat, but not the guitar.... Looking at the list of bones in the default coach model and mine, I don't see any others that have gone missing. Now I'm really out of ideas on this one.



As for the problem with the right arm, I can reduce the effect with some careful skinning, but I don't know what the problem is in the first place. Like I said, I'm using the importer/exporter from wunderboy.org. There only seems to be one other smd importer in use out there, but it doesn't look like it was made for anything after max 7.
Tsumetai
L4DMods Newbie
L4DMods Newbie
 
Posts: 8
Joined: 05 Mar 2010 16:32

Re: [TUT]Getting Player Models InGame

Postby Nahka » 07 Mar 2010 14:03

Shilo wrote:As Nahka wrote, it does work and it does make sense. I figured it out last night from that tutorial. If you open an smd you made yourself in notepad or something, you can see it will still list the separate objects. It's probably only the decompiler that groups them all together. When you are doing this, like the tutorial says, you have to create two new objects the same shape as the eyes, name one tex_eye_l and one tex_eye_r. Make sure you put separate textures on them named eyeball_l.tga and eyeball_r.tga respectively.

The values in the "eyeball" lines do have to be unique to your new model though.
For mine I used : (don't mind the Bone01, change that to your model's head bone)
Code: Select all
eyeball righteye "Bone01" -1.098 -2.312 64.65 "eyeball_r" 1.00 4 "grn_pupil_r" 0.5
   eyeball lefteye "Bone01" 1.098 -2.312 64.65 "eyeball_l" 1.00 -4 "grn_pupil_r" 0.5


The big thing I really had to change was :
Code: Select all
$attachment "eyes" "Bone01" 3.56 -2.83 0.01 rotate -90.00 0.00 0.00

I had to change the rotation to get it to show up right. And voila!
Tsumetai wrote:Eyes: The part that I said that doesn't make sense is the part where those lines of codes concerning the eyes are commented out in the original qc files, suggesting they're using another method. In any event, I did what you said, and got it so that the eyes work properly in model viewer. Unfortunately, they don't work properly in game! They start off looking forward when a game first starts, but then they start to wander freely, looking in any random direction, spending most of their time inside his head, but occasionally they come forward again.... needless to say, the effect is very creepy. Anyways, this is probably what they meant by "doesn't work".

I've been trying to get the eyes work by changing the eyes -attachment but whatever I do, she stays crosseyed and pupils can only be seen from a very low angle. Could you guys give me a brief explanation which value changes what. I don't see any logic in how the pupils act when I change the values.
Nahka
L4DMods Newbie
L4DMods Newbie
 
Posts: 12
Joined: 18 Jul 2009 07:44
Steam ID: Nahkamestari

Re: [TUT]Getting Player Models InGame

Postby Shilo » 07 Mar 2010 22:18

Tsumetai wrote:In any event, I did what you said, and got it so that the eyes work properly in model viewer. Unfortunately, they don't work properly in game!

Nahka wrote:I've been trying to get the eyes work by changing the eyes -attachment but whatever I do, she stays crosseyed and pupils can only be seen from a very low angle. Could you guys give me a brief explanation which value changes what. I don't see any logic in how the pupils act when I change the values.


Ya, I had this problem too.. For both of you, I found this in the qc commands valve dev wiki..

"Default yaw offset from "forward" for iris. Humans are typically 2-4 degrees walleyed. Not setting this correctly will result in your either characters appearing cross-eyed, or if you’ve compensated by misplacing the ball of the eye, them not tracking side to side."

which is this part of the eyeball setting :

eyeball righteye "Bone01" -1.098 -2.312 64.65 "eyeball_r" 1.00 4 "grn_pupil_r" 0.5

http://developer.valvesoftware.com/wiki/.QC_Commands#New_.24model_Option
http://developer.valvesoftware.com/wiki/Eye_Position_Setup

Tsumetai wrote:weapon_extra: I'm using the exporter from wunderboy.org for Max 9


I recently had problems with that particular exporter actually.. I switched back to max5 for a halflife2 mod of mine because the max 9 one was losing polys on exporting. I didn't try to export with bones using it but if it had other problems...

It could be something wrong with your studiomdl.. maybe you should ask someone else to try to compile your smd and see what happens? I do know I helped someone else in the past, when they compiled, it came out completely different than when I compiled their exact same model. Couldn't hurt.
User avatar
Shilo
Smoker
Smoker
 
Posts: 140
Joined: 07 Jun 2009 15:59
Location: Toronto, Ontario, Canada
Title: Legal Assassin
Steam ID: Shilo_Wallace
Favourite Survivor: Zoey
 

Re: [TUT]Getting Player Models InGame

Postby kamenkewl » 08 Mar 2010 00:52

hey, sorry to be a bother, but i was still wondering if there was any way to get your custom repo man in game (L4D1)
i don't have the computer resources (or time ^^; ) to get modeling programs or to do all the coding this would require to do from scratch ^^;
anyway, again, sorry to be a pest, i'll just run off and get your decaf (plz don't shoot me in the face ^^; )
kamenkewl
L4DMods Newbie
L4DMods Newbie
 
Posts: 1
Joined: 06 Feb 2010 17:01

Re: [TUT]Getting Player Models InGame

Postby Shilo » 08 Mar 2010 01:05

No bother lol.
I had stopped working on it because I figured that everyone had moved on to l4d2, and since I didn't.. I didn't know if anyone was interested in it anymore. Since you have shown interest, I will be finishing off the higher quality one, though it's up to you if you want me to upload the lower quality one ( the one shown in the tutorial) for now. The lower quality one works well enough but doesn't have the most perfect rigging job. (I had just wanted to get it in there.)

Do you know if the custom vpk's support new models and skins yet?

And don't worry :D I am not Luigi!
User avatar
Shilo
Smoker
Smoker
 
Posts: 140
Joined: 07 Jun 2009 15:59
Location: Toronto, Ontario, Canada
Title: Legal Assassin
Steam ID: Shilo_Wallace
Favourite Survivor: Zoey
 

Re: [TUT]Getting Player Models InGame

Postby Nahka » 08 Mar 2010 01:37

Hey, I got the eyes working in model viewer. eyes -attachments was allright, eyeballs offset was way wrong. The eyeballs were positioned somewhere in the top part of the back of her head. Thanks for your help!
Nahka
L4DMods Newbie
L4DMods Newbie
 
Posts: 12
Joined: 18 Jul 2009 07:44
Steam ID: Nahkamestari

Re: [TUT]Getting Player Models InGame

Postby Shilo » 08 Mar 2010 01:45

No problem! Glad you got it working. Tell me if it works all right ingame or not though, because mine looks fine in modelviewer too but wonky ingame.
User avatar
Shilo
Smoker
Smoker
 
Posts: 140
Joined: 07 Jun 2009 15:59
Location: Toronto, Ontario, Canada
Title: Legal Assassin
Steam ID: Shilo_Wallace
Favourite Survivor: Zoey
 

Re: [TUT]Getting Player Models InGame

Postby Tsumetai » 08 Mar 2010 04:51

Nahka wrote:Hey, I got the eyes working in model viewer. eyes -attachments was allright, eyeballs offset was way wrong. The eyeballs were positioned somewhere in the top part of the back of her head. Thanks for your help!

But does it work in game? Like I said, I got the eyes working perfectly in the model viewer, but they don't work in game.


I read over that stuff you posted, but I never once had a problem with him being cross eyed. After reading that stuff, I made sure the numbers in the qc file were as accurate as I could get them, and as I said, it looks perfect in model viewer, but it doesn't work in game. The eyes wander about, sometimes they roll into his head, sometimes they roll off to the right then pop in on the left (or vice versa).

I've found that when I look at him from certain directions [i.e. with him directly north of me], the eyes are fine (more or less, sometimes they'll quickly fly off in one direction before fixing themselves), but when I move 90 degrees to his side [i.e. with him directly east or west of me], they disappear, I notice that as I move to the side, the eyes roll in the opposite direction they should. This suggests to me a problem with the rotations. I've tried playing with the numbers in the eye attachment under rotation, but I can't find anything that works. There are a number of permutations that work perfectly in model viewer, but none work in game.


I don't think there's a problem with the exporter. Like I said, I checked the smd file myself, all the bones that are supposed to be in there are in fact there. And I have no idea how I'm supposed to get a hold of someone elses studiomdl.exe just to see if it works.
Tsumetai
L4DMods Newbie
L4DMods Newbie
 
Posts: 8
Joined: 05 Mar 2010 16:32

Re: [TUT]Getting Player Models InGame

Postby Nahka » 08 Mar 2010 08:22

Ok, I tested ingame, didn't have time to do that before, and I noticed that I have the same problem as you do. Her eyes go around wildly, spending a lot of time inside her head. I guess the attachment still has some problems.

EDIT: Ok, some more info. I tested it in Gmod and I noticed that eye poser doesn't work on her. It seems that her eyes have lost the ability to track things ot something.
Nahka
L4DMods Newbie
L4DMods Newbie
 
Posts: 12
Joined: 18 Jul 2009 07:44
Steam ID: Nahkamestari

Re: [TUT]Getting Player Models InGame

Postby Shilo » 09 Mar 2010 19:48

Tsumetai wrote:I don't think there's a problem with the exporter. Like I said, I checked the smd file myself, all the bones that are supposed to be in there are in fact there. And I have no idea how I'm supposed to get a hold of someone elses studiomdl.exe just to see if it works.


I was just thinking, check in your skin modifier and make sure the bones that go missing are actually listed in the skin modifier bone list. Perhaps that exports the bones with a different setting which doesn't compile them properly? Just a wild guess....



And about the eyes.. still trying to figure it out.. I've tried settings from qc's from 3 different Source games now..(vampire the masquerade : bloodlines, halflife2 and left4dead) none work yet... Going to still work on it and I will update you all if I figure it out. If anyone else figures it out, please tell the rest of us! =P
User avatar
Shilo
Smoker
Smoker
 
Posts: 140
Joined: 07 Jun 2009 15:59
Location: Toronto, Ontario, Canada
Title: Legal Assassin
Steam ID: Shilo_Wallace
Favourite Survivor: Zoey
 

Re: [TUT]Getting Player Models InGame

Postby Tsumetai » 09 Mar 2010 20:24

1: As I've stated, the only missing bone was weapon-extra, and it wasn't disappearing between max and the smd, it was disappearing between the smd and the mdl. There are other bones in the skeleton that aren't skinned to anything, but they don't disappear. But like I said, I've managed to trick studiomdl into keeping that bone by skinning it to something, so now there are no bones that appear missing from the model, but that didn't fix the melee weapon problem.

2: I'm working on the eye problem too. I'm going to experiment with going whole-hog with the facial flex thing. I'll let you know how that works out.

EDIT:
SUCCESS! Once the flex system was fully implemented and working, the eyes started working properly. The down side is that I had to use the hl2 flex system (the only one we have, it would seem), which is probably fine for all older source games, but L4D2 apparently uses new (more) flex animations and controllers, so some are missing. Although, this isn't really noticeable in-game.

Remaining mysteries:
The twisted hand bone. I'm at a loss as to what causes this. I can't use the other smd exporter as I don't have an older version of Max, nor with this computer run an older version of Max. I tried once, it doesn't like it. To further the mystery, this problem only exists on the right hand, even though both hands are rigged and skinned identically.

Melée weapon problem. No idea what causes this. There are no bone or attachments missing that I'm aware of.

New mystery: My character's mouth is black when he speaks. I pretty sure this highlights the importance of setting up the mouth in the qc file, except I don't know how. The tutorials mention a separate texture, but there are no mouth textures, nor mouth vmt's in anywhere in L4D2. The mouth textures are part of the character's heads, so I don't know how to set those up.
Tsumetai
L4DMods Newbie
L4DMods Newbie
 
Posts: 8
Joined: 05 Mar 2010 16:32

Re: [TUT]Getting Player Models InGame

Postby Shilo » 12 Mar 2010 18:43

Thanks for the info on the eyes! I figured it was probably that, that was the next step I was going to try but just never got around to it lol.

About the mouth.. in Vampire the Masquerade, they link to separate mouth textures.. and that tutorial is for hl2 so they are both the oldest versions of the Source engine, maybe that's why they require a mouth texture.

You have both "mouth 0 "mouth" ValveBiped.Bip01_Head1 0.000 1.000 0.000" and "$attachment "mouth" "ValveBiped.Bip01_Head1" 0.80 -5.80 -0.15 rotate 0.00 -80.00 -90.00" in there and it's rotated and positioned correctly?

Oh.. the texture for the mouth is in the head file for the particular character so just put the head texture on to the mouth object.

Still trying to figure out the other bone thing..
User avatar
Shilo
Smoker
Smoker
 
Posts: 140
Joined: 07 Jun 2009 15:59
Location: Toronto, Ontario, Canada
Title: Legal Assassin
Steam ID: Shilo_Wallace
Favourite Survivor: Zoey
 

Re: [TUT]Getting Player Models InGame

Postby Nahka » 13 Mar 2010 07:33

Tsumetai wrote: SUCCESS! Once the flex system was fully implemented and working, the eyes started working properly. The down side is that I had to use the hl2 flex system (the only one we have, it would seem), which is probably fine for all older source games, but L4D2 apparently uses new (more) flex animations and controllers, so some are missing. Although, this isn't really noticeable in-game.

New mystery: My character's mouth is black when he speaks. I pretty sure this highlights the importance of setting up the mouth in the qc file, except I don't know how. The tutorials mention a separate texture, but there are no mouth textures, nor mouth vmt's in anywhere in L4D2. The mouth textures are part of the character's heads, so I don't know how to set those up.

Looks like I have to learn how to make face flexes. Can you recommend any tool or tutorials, I have been searching a while but I haven't found anything useful.

About that mouth-problem, try setting the head texture as mouth texture. I've been playeing around with some models and in Chells case there are no separate pupils, they are in the face texture and in the qc the head texture is set as pupil texture. Might be a long shot, but if the mouth-attachments values are not the problem, this just might work.
Nahka
L4DMods Newbie
L4DMods Newbie
 
Posts: 12
Joined: 18 Jul 2009 07:44
Steam ID: Nahkamestari

Re: [TUT]Getting Player Models InGame

Postby Tsumetai » 13 Mar 2010 19:52

Note, the mouth problem was a false alarm. Turned out just to be a problem with the uv coordinate that were imported when the original mdl was imported.

Only problems that remain are the hand issue and the melee weapon issue.

Also, I used this tutorial to learn facial animations.
Tsumetai
L4DMods Newbie
L4DMods Newbie
 
Posts: 8
Joined: 05 Mar 2010 16:32

Re: [TUT]Getting Player Models InGame

Postby Nahka » 16 Mar 2010 16:17

Thanks Tsumetai, but I'm using XSI Mod tool. I just found a good tutorial though, we'll see what I can do.

About the performance problems and buggy saferoom doors, I got some more info. They seem to occur only in some campaings and as far as I've tested, only in official campaings. I need to test more to see if this is the case, maybe that narrows the options down a bit.
Nahka
L4DMods Newbie
L4DMods Newbie
 
Posts: 12
Joined: 18 Jul 2009 07:44
Steam ID: Nahkamestari

Re: [TUT]Getting Player Models InGame

Postby Master Vezon » 17 Mar 2010 08:35

When I try to open the 'zoey_reference_wrinkle.dmx.smd' file that came in the .zip, the demo of Autodesk 3ds Max 2010 claims 'file open failed'.
My target animation is 82x125, but ingame, it's very low-res due to the automatic 'inflation' to 256x256. Any suggestions?
User avatar
Master Vezon
Smoker
Smoker
 
Posts: 102
Joined: 06 Feb 2010 13:18
Location: DON'T YOU KNOW ANYTHING ABOUT SCIENCE?!
Steam ID: ValeDecem
Favourite Survivor: Zoey
 

Re: [TUT]Getting Player Models InGame

Postby Shilo » 17 Mar 2010 16:26

What SMD importer are you using?
Are you just trying to open it with 3ds max or are you actually choosing Import?
User avatar
Shilo
Smoker
Smoker
 
Posts: 140
Joined: 07 Jun 2009 15:59
Location: Toronto, Ontario, Canada
Title: Legal Assassin
Steam ID: Shilo_Wallace
Favourite Survivor: Zoey
 

Re: [TUT]Getting Player Models InGame

Postby Master Vezon » 17 Mar 2010 16:29

It pops up the same message both ways.
My target animation is 82x125, but ingame, it's very low-res due to the automatic 'inflation' to 256x256. Any suggestions?
User avatar
Master Vezon
Smoker
Smoker
 
Posts: 102
Joined: 06 Feb 2010 13:18
Location: DON'T YOU KNOW ANYTHING ABOUT SCIENCE?!
Steam ID: ValeDecem
Favourite Survivor: Zoey
 

Re: [TUT]Getting Player Models InGame

Postby Shilo » 17 Mar 2010 16:51

Do any of the other reference models import properly or is it just Zoey?
And again, what SMD importer are you using?

It could be the fact that it's max 2010 (does anyone else know if this version works?) or it could be the fact that it is the demo.. or could just be a bad importer.
User avatar
Shilo
Smoker
Smoker
 
Posts: 140
Joined: 07 Jun 2009 15:59
Location: Toronto, Ontario, Canada
Title: Legal Assassin
Steam ID: Shilo_Wallace
Favourite Survivor: Zoey
 

Re: [TUT]Getting Player Models InGame

Postby Master Vezon » 17 Mar 2010 17:10

I tried MilkShape 3D (dunno if that's even an option, really).
I haven't tried the others yet.
My target animation is 82x125, but ingame, it's very low-res due to the automatic 'inflation' to 256x256. Any suggestions?
User avatar
Master Vezon
Smoker
Smoker
 
Posts: 102
Joined: 06 Feb 2010 13:18
Location: DON'T YOU KNOW ANYTHING ABOUT SCIENCE?!
Steam ID: ValeDecem
Favourite Survivor: Zoey
 

Re: [TUT]Getting Player Models InGame

Postby Shilo » 17 Mar 2010 21:10

Um, Milkshape is a separate modeling program, not a SMD importer for 3ds max.
You probably should be using this importer for max 2010 :
http://www.wunderboy.org/apps/smdimport.php
User avatar
Shilo
Smoker
Smoker
 
Posts: 140
Joined: 07 Jun 2009 15:59
Location: Toronto, Ontario, Canada
Title: Legal Assassin
Steam ID: Shilo_Wallace
Favourite Survivor: Zoey
 

Re: [TUT]Getting Player Models InGame

Postby Master Vezon » 18 Mar 2010 08:28

It works! Oddly enough, I had a similar file in my plugins folder already, except it was .dle instead of .dli.
Now my only problem is getting it to open whichever of the following has the textures/model: 'sf4_cmy_00_Zero.dx80.vtx' 'sf4_cmy_00_Zero.dx90.vtx' 'sf4_cmy_00_zero.mdl' 'sf4_cmy_00_Zero.phy' 'sf4_cmy_00_Zero.sw.vtx' 'sf4_cmy_00_zero.vvd'.
...I get the feeling I should quit while I'm ahead. I have little to no idea what to do with these models.
My target animation is 82x125, but ingame, it's very low-res due to the automatic 'inflation' to 256x256. Any suggestions?
User avatar
Master Vezon
Smoker
Smoker
 
Posts: 102
Joined: 06 Feb 2010 13:18
Location: DON'T YOU KNOW ANYTHING ABOUT SCIENCE?!
Steam ID: ValeDecem
Favourite Survivor: Zoey
 

Re: [TUT]Getting Player Models InGame

Postby Shilo » 18 Mar 2010 16:12

None of those hold textures, they are all only model related files. You will want to look for a VTF file somewhere else.

The MDL is the actual model file. You will need to decompile it to get the SMD which then can be opened in max.
User avatar
Shilo
Smoker
Smoker
 
Posts: 140
Joined: 07 Jun 2009 15:59
Location: Toronto, Ontario, Canada
Title: Legal Assassin
Steam ID: Shilo_Wallace
Favourite Survivor: Zoey
 

PreviousNext

Return to Resources

Who is online

Users browsing this forum: MSNbot Media, Shilo and 1 guest

In total there are 3 users online :: 2 registered, 0 hidden and 1 guest (based on users active over the past 60 minutes)
Most users ever online was 1910 on 05 Oct 2009 11:28

Users browsing this forum: MSNbot Media, Shilo and 1 guest