MCPcopy Create free account
hub / github.com/DescentDevelopers/Descent3 / MakeWeaponStick

Function MakeWeaponStick

physics/collide.cpp:2147–2154  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2145}
2146
2147void MakeWeaponStick(object *weapon, object *parent, fvi_info *hit_info) {
2148 weapon->mtype.obj_link_info.parent_handle = parent->handle;
2149 weapon->mtype.obj_link_info.fvec = hit_info->hit_subobj_fvec;
2150 weapon->mtype.obj_link_info.uvec = hit_info->hit_subobj_uvec;
2151 weapon->mtype.obj_link_info.pos = hit_info->hit_subobj_pos;
2152 weapon->mtype.obj_link_info.sobj_index = hit_info->hit_subobject[0];
2153 weapon->movement_type = MT_OBJ_LINKED;
2154}
2155
2156void collide_generic_and_weapon(object *robotobj, object *weapon, vector *collision_point, vector *collision_normal,
2157 bool f_reverse_normal, fvi_info *hit_info) {

Callers 2

Calls

no outgoing calls

Tested by

no test coverage detected