yeelp / Distinct-Damage-Descriptions

Adding physical D&D-style damage types to Minecraft to deepen the combat
MIT License
9 stars 4 forks source link

Fix nullptr when shooting TiC arrows #81

Closed kappa-maintainer closed 2 years ago

kappa-maintainer commented 2 years ago

The EntityProjectileBase.tinkerProjectile can be null when applying distributions, a null check can fix this Btw, this mod really needs more advertise. Maybe make a post on /r/feedthebeast or something

yeelp commented 2 years ago

Also I should mention that a post on /r/feedthebeast is a great idea! I'll aim to post something sometime this week

kappa-maintainer commented 2 years ago

I figured out why the TiC update() will got called before initialization, it was called from https://github.com/yeelp/Distinct-Damage-Descriptions/blob/00e77f9eecaae4e800ecf7571d81c13bb1a18e46/src/main/java/yeelp/distinctdamagedescriptions/integration/tic/tinkers/capability/distributors/TinkerProjectileCapabilityDistributor.java#L26 I guess a null check is enough to fix this