Server crashes on barrett kill
DerScherenmann opened this issue ยท 1 comments
To Reproduce
Steps to reproduce the crash:
- Get two clients on a server with FlansMod running
- Give Player 1 a Barrett
- Shoot Player 2 with it
- Server crashes
Temporary Fix
comment out this paragraph in com/flansmod/common/guns/ShotHandler,java
// Check teams
if (optionalPlayer.isPresent())
{
EntityPlayerMP player = optionalPlayer.get();
if(FlansModClient.teamInfo != null)
{
Team shooterTeam = FlansModClient.teamInfo.getTeam(player);
Team victimTeam = FlansModClient.teamInfo.getTeam(playerHit.hitbox.player);
if(shooterTeam == null || shooterTeam != victimTeam)
{
FlansMod.getPacketHandler().sendTo(new PacketHitMarker(), player);
}
}
else // No teams mod, just add marker
{
FlansMod.getPacketHandler().sendTo(new PacketHitMarker(), player);
}
}
Screenshots
Versions (please complete the following information):
- Forge: 1.12.2-forge1.12.2-14.23.5.2768
- Flan's Mod: latest git clone 23/07/2019
Additional context
https://gist.github.com/broesel233/074c937c53071fca82785de9e47b9308
@Liruxo looks like this may be an issue spouting from your PR, I haven't double checked yet though.