Source SDK

Source SDK

Consilio Feb 3, 2019 @ 5:53am
Blender prop collision error!
So, I have created a doorframe along with the collision mesh. However, when I compile it through Crowbar the doorframe turns into a single solid box (which doesn't allow me to walk through it ingame). I have had so much trouble trying to figure this out by googling so many topics on this. This is my last resort. I am so desperate, help!
< >
Showing 1-13 of 13 comments
lorjason34 Feb 3, 2019 @ 6:00am 
Make sure you have this line in your qc file near physics:

$maxconvexpieces 3 (this tells crowbar that it will define 3 parts instead of one)

The reason why it does that is because it is optimizing the collisions so that the game can run better. I've bumped into it too, but I got it to work for a chair.
Last edited by lorjason34; Feb 3, 2019 @ 6:01am
Consilio Feb 3, 2019 @ 7:29am 
Originally posted by lorjason34:
Make sure you have this line in your qc file near physics:

$maxconvexpieces 3 (this tells crowbar that it will define 3 parts instead of one)

The reason why it does that is because it is optimizing the collisions so that the game can run better. I've bumped into it too, but I got it to work for a chair.
That didn't seem to work :/ This is my qc file:

$modelname "cwhallsupport_addon\hallsupport\cwhallsupport.mdl"

$scale 1

$body 1 "cwhallsupport.smd"

$cdmaterials "hallsupport\cwhallsupport\"

$surfaceprop "metal"

$contents "solid"

$sequence "idle" "anims\cwhallsupport_idle.smd" {
fps 1
}

$collisionmodel "cwhallsupport_phys.smd"
{
$automass
$inertia 1
$damping 0
$rotdamping 0
$concave
}
Last edited by Consilio; Feb 3, 2019 @ 7:34am
lorjason34 Feb 3, 2019 @ 7:44am 
You need to add it under the $collisionmodel for it to work.
My chair for example:

$collisionmodel "jlor_chair_gaming_physics.smd"
{
$mass 15
$inertia 1
$damping 0
$rotdamping 0
$rootbone "static_prop"
$concave
--> $maxconvexpieces 7

}

Don't forget to specify how many parts your collision model have. Make sure your physics model are separate parts, or else the mesh would merge as one for some weird reason.
Last edited by lorjason34; Feb 3, 2019 @ 7:46am
Consilio Feb 3, 2019 @ 8:15am 
I have four separate boxes that make out the frame but when I seperate them from being one model, only one of the boxes gets exported instead of all four?
lorjason34 Feb 3, 2019 @ 8:27am 
That's because the boxes are all independent entities. Separate them, but then have them joined by selecting all of them, and press ctrl+j. Then go to edit, and press l on one of them. That's what I mean.
lorjason34 Feb 3, 2019 @ 8:29am 
https://steamcommunity.com/sharedfiles/filedetails/?id=1644011826&fileuploadsuccess=1

Like this gaming chair physics, it's one, but has multiple separate vertices.
Consilio Feb 3, 2019 @ 8:53am 
After joining them, I entered edit mode but I wasnt able to select anything (other than the vertices/corners)

https://imgur.com/a/H8ZXsBV
Last edited by Consilio; Feb 3, 2019 @ 8:57am
lorjason34 Feb 3, 2019 @ 9:09am 
Switch to face mode for that. Since I've seen the picture, I can assume you can retry what you did previously, and use the $maxconvexpieces command under the collison model. Make sure you specify how many parts there are.
Last edited by lorjason34; Feb 3, 2019 @ 9:09am
Consilio Feb 3, 2019 @ 9:36am 
Didn't work :/ Sorry, I'm not trying to be difficult - I have been trying to figure this out for awhile. Here's the file for the collision mesh. Maybe you can see where I went wrong.

https://www.dropbox.com/s/4eb6e6a2dkyeyco/cwhallsupport_phys.blend?dl=0

Also, heres a screenshot of my crowbar before I compile: https://imgur.com/a/GJjsuNO
Last edited by Consilio; Feb 3, 2019 @ 10:11am
lorjason34 Feb 3, 2019 @ 10:14am 
That's helpful. I will see if I can get it to work on my side.
lorjason34 Feb 3, 2019 @ 10:35am 
I got it to work. Only problem for me was the physics model turns 90 degrees to the right every time I compile, so I rotated it 90 degrees to the other direction.
I think it's something to do with the qc file and the parenting of the collision model. I set up the collision line like this:
$collisionmodel "cwhallsupport_phys.smd"
{
$mass 15
$inertia 1
$damping 0
$rotdamping 0
$rootbone "static_prop"
$concave
$maxconvexpieces 4

}
I don't know what else will fix it, but add that whole line to your qc file and it should work.
Consilio Feb 3, 2019 @ 11:51am 
I have replaced the coding to what you have suppiled but still no success. I am so sorry for wasting your day. I would understand if you'd prefer to stop here.
Consilio Feb 3, 2019 @ 1:38pm 
Nevermind, I have done it!
Last edited by Consilio; Feb 4, 2019 @ 9:09am
< >
Showing 1-13 of 13 comments
Per page: 1530 50

Date Posted: Feb 3, 2019 @ 5:53am
Posts: 13