static void draw_local_3d_object (entity *en, float range) { routed_vehicle *raw; raw = (routed_vehicle *) get_local_entity_data (en); // // update viewpoint // raw->vh.inst3d->vp.position = raw->vh.mob.position; memcpy (&raw->vh.inst3d->vp.attitude, &raw->vh.mob.attitude, sizeof (matrix3x3)); // // animate // animate_routed_vehicle_wheels (en); animate_vehicle_loading_doors (en); animate_vehicle_radar (en); animate_vehicle_weapon_system_ready (en); // // draw // animate_and_draw_entity_muzzle_flash_effect (en); insert_object_into_3d_scene (OBJECT_3D_DRAW_TYPE_OBJECT, raw->vh.inst3d); }
static void draw_local_3d_object (entity *en, float range) { ship_vehicle *raw; day_segment_types day_segment_type; raw = get_local_entity_data (en); // // update viewpoint // raw->vh.inst3d->vp.position = raw->vh.mob.position; memcpy (&raw->vh.inst3d->vp.attitude, &raw->vh.mob.attitude, sizeof (matrix3x3)); // // animate // animate_ship_rotors (en); animate_vehicle_loading_doors (en); animate_vehicle_radar (en); animate_vehicle_weapon_system_ready (en); day_segment_type = get_local_entity_int_value (get_session_entity (), INT_TYPE_DAY_SEGMENT_TYPE); raw->vh.inst3d->object_internal_lighting = ((day_segment_type == DAY_SEGMENT_TYPE_NIGHT) || (day_segment_type == DAY_SEGMENT_TYPE_DUSK)); raw->vh.inst3d->object_sprite_lights = raw->vh.inst3d->object_internal_lighting; // // draw // animate_and_draw_entity_muzzle_flash_effect (en); raw->vh.inst3d->object_has_shadow = FALSE; insert_object_into_3d_scene (OBJECT_3D_DRAW_TYPE_OBJECT, raw->vh.inst3d); }