setsize vs setobjectcollisionbox Created 11 years ago2012-07-06 23:06:07 UTC by tschumann tschumann

Created 11 years ago2012-07-06 23:06:07 UTC by tschumann tschumann

Posted 11 years ago2012-07-06 23:06:07 UTC Post #307663
Just to prefix this, I'm trying to make a model-based door in a mod I'm working on, so if anyone know of any open source mods with a model-based door entity, let me know.

Anyway, does anyone know the difference between UTIL_SetSize and SetObjectCollisionBox (what each one should be used for and which ones affect collision and so on)? I've tinkered with both of them and haven't reached any conclusions. The examples in the default code don't make things any clearer either.
Posted 11 years ago2012-07-07 02:28:59 UTC Post #307664
ur making a model based door that opens and closes? Couldn't u just use func_wall_toggles and two env renders for two monster generics?
Posted 11 years ago2012-07-07 04:10:44 UTC Post #307665
That'd only work if you wanted them to open instantaneously. It'd be ever so slightly unrealisistic.
Jessie JessieTrans Rights <3
Posted 11 years ago2012-07-07 04:56:38 UTC Post #307666
maybe the generic can run a scripted sequence
Posted 11 years ago2012-07-08 04:04:18 UTC Post #307682
I want to make rotating door once I've done the sliding door, so I don't know if that will work.
Anyway, it looks like SetObjectCollisionBox is responsible for collisions (as long as the entity has a touch function and the right solid flag set (I think)). I still don't know what UTIL_SetSize is for though.
Posted 11 years ago2012-07-17 23:26:34 UTC Post #307987
Okay, I've sort of got this working now.
I'm rotating the bounding/collision box so that it aligns with the model, but the problem is that if the door is oriented at an angle either >90 and <180 degrees or >270 and <360 degrees the bounding box is invalid (and the map won't load) because one of the components of mins will be greater than one of the components of maxs.
Anyone know any way around this?
Posted 11 years ago2012-07-18 06:06:03 UTC Post #308000
a func_wall_toggle where the door would be at those angles?
Posted 11 years ago2012-07-18 08:18:00 UTC Post #308002
I want it to be a model though. Something to do with the lighting being affected by a brush-based door.
You must be logged in to post a response.