Many systems are subjected to random shocks from internal or external factors such as high voltage, over loads, etc., and they often experience a dependent competing-risk process including natural degradation and random shocks. Some systems have the ability to resist the damage of shocks due to its material, structure, and/or special designed affiliated devices. Motivated by the actual engineering problem of reliability modeling for the biodegradable magnesium alloy vascular stent, a new competing risks model is developed considering the time-varying resistance of the system. Hard failure may occur due to a fatal shock, while soft failure happens when the comprehensive effects, including the natural degradation amount and cumulative damage of nonfatal shocks, exceed the predefined threshold. The resistance of the system can influence the damage of nonfatal shocks, and its resistance to shocks will also deteriorate as the system degrades, which is depicted by a time-varying function related to the health state or the service time. In addition, the thresholds to classify shocks into nonfatal shocks (i.e., safety shocks and damage shocks) and fatal shocks, can also be affected by the resistance. A closed-form reliability function is obtained under specific conditions and a simulated algorithm is also provided. Two illustrative examples are conducted to demonstrate the proposed model.