On scintillator detectors, neutron and gamma rays could generate signals. These signals are generated internally and cannot be shielded, and there are various complex circumstances during data collection, such as piled-up pulse at high count rates and overflowed pulse caused by detector range limits. It is challenging to screen these complex circumstances using conventional methods like charge comparison. Conventional methods have low accuracy and lack self adaptability, to address these problem, a neural network based on residual connection structure (ResNet) was proposed. On the basis of the collected real signal, the pulse waveforms under complex circumstances were simulated. After integrating these waveforms into a dataset, they were trained and validated by ResNet and compared with two neural network algorithms MLP and CNN. The false predictions number of ResNet is 60% and 73% lower than that of CNN and MLP. The macro average F1 score of ResNet was 0.9956, which was significantly higher than 0.9885 of CNN and 0.9855 of MLP. And in the ROC and AUC, ResNet is still the best performing method, furthermore the improvement of ResNet to CNN is higher than that of CNN to MLP. These results indicated that Proposed ResNet is more suitable for neutron-gamma events discrimination in complex situations.