mirror of
https://github.com/Sollace/Unicopia.git
synced 2025-02-01 11:36:43 +01:00
Fixed crash when reading a projectile spawn packet from earlier versions
This commit is contained in:
parent
22c295f1d6
commit
33b3eec4cb
1 changed files with 1 additions and 1 deletions
|
@ -22,7 +22,7 @@ public class MsgSpawnProjectile extends EntitySpawnS2CPacket implements Channel.
|
||||||
|
|
||||||
@SuppressWarnings("unchecked")
|
@SuppressWarnings("unchecked")
|
||||||
public MsgSpawnProjectile(Entity e) {
|
public MsgSpawnProjectile(Entity e) {
|
||||||
super(e, Optional.of(e instanceof Owned ? ((Owned<Entity>)e).getMaster() : null).map(Entity::getEntityId).orElse(0));
|
super(e, Optional.ofNullable(e instanceof Owned ? ((Owned<Entity>)e).getMaster() : null).map(Entity::getEntityId).orElse(0));
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
Loading…
Reference in a new issue