mirror of
https://github.com/scp-fs2open/fs2open.github.com.git
synced 2026-11-12 02:01:29 -10:00
Added "$nocollide_this_only" and "$collide_invisible" submodel flags. The first one is like $no_collisions, but not recursive on submodels. The second one allows weapon impacts on the special "invisible" texture (normally only ship collisions are allowed). These two flags can be combined to implement invisible collision meshes, which can save a lot of FPS for complex models.
This commit is contained in:
1 parent
c9631721c5
commit
fe87aed445
3 files changed
+16
-1
No files matched your search
@@ -1279,6 +1279,16 @@ int read_model_file(polymodel * pm, char *filename, int n_subsystems, model_subs
|
||||
else
|
||||
pm->submodel[n].no_collisions = false;
|
||||
|
||||
if (strstr(props, "$nocollide_this_only") != NULL )
|
||||
pm->submodel[n].nocollide_this_only = true;
|
||||
else
|
||||
pm->submodel[n].nocollide_this_only = false;
|
||||
|
||||
if (strstr(props, "$collide_invisible") != NULL )
|
||||
pm->submodel[n].collide_invisible = true;
|
||||
else
|
||||
pm->submodel[n].collide_invisible = false;
|
||||
|
||||
if ( (p = strstr(props, "$gun_rotation:")) == NULL )
|
||||
pm->submodel[n].gun_rotation = true;
|
||||
else
|
||||
|
||||
Reference in new issue
Block a user