mirror of
https://github.com/Grasscutters/Grasscutter.git
synced 2026-06-12 23:33:43 +08:00
Run IntelliJ IDEA code formatter
This commit is contained in:
@@ -8,58 +8,60 @@ import emu.grasscutter.net.proto.LifeStateChangeNotifyOuterClass.LifeStateChange
|
||||
import emu.grasscutter.net.proto.PlayerDieTypeOuterClass.PlayerDieType;
|
||||
|
||||
public class PacketLifeStateChangeNotify extends BasePacket {
|
||||
public PacketLifeStateChangeNotify(GameEntity target, LifeState lifeState) {
|
||||
super(PacketOpcodes.LifeStateChangeNotify);
|
||||
public PacketLifeStateChangeNotify(GameEntity target, LifeState lifeState) {
|
||||
super(PacketOpcodes.LifeStateChangeNotify);
|
||||
|
||||
LifeStateChangeNotify proto = LifeStateChangeNotify.newBuilder()
|
||||
.setEntityId(target.getId())
|
||||
.setLifeState(lifeState.getValue())
|
||||
.build();
|
||||
LifeStateChangeNotify proto = LifeStateChangeNotify.newBuilder()
|
||||
.setEntityId(target.getId())
|
||||
.setLifeState(lifeState.getValue())
|
||||
.build();
|
||||
|
||||
this.setData(proto);
|
||||
}
|
||||
public PacketLifeStateChangeNotify(GameEntity attacker, GameEntity target, LifeState lifeState) {
|
||||
super(PacketOpcodes.LifeStateChangeNotify);
|
||||
this.setData(proto);
|
||||
}
|
||||
|
||||
LifeStateChangeNotify proto = LifeStateChangeNotify.newBuilder()
|
||||
.setEntityId(target.getId())
|
||||
.setLifeState(lifeState.getValue())
|
||||
.setSourceEntityId(attacker.getId())
|
||||
.build();
|
||||
|
||||
this.setData(proto);
|
||||
}
|
||||
public PacketLifeStateChangeNotify(int attackerId, GameEntity target, LifeState lifeState) {
|
||||
super(PacketOpcodes.LifeStateChangeNotify);
|
||||
public PacketLifeStateChangeNotify(GameEntity attacker, GameEntity target, LifeState lifeState) {
|
||||
super(PacketOpcodes.LifeStateChangeNotify);
|
||||
|
||||
LifeStateChangeNotify proto = LifeStateChangeNotify.newBuilder()
|
||||
.setEntityId(target.getId())
|
||||
.setLifeState(lifeState.getValue())
|
||||
.setSourceEntityId(attackerId)
|
||||
.build();
|
||||
LifeStateChangeNotify proto = LifeStateChangeNotify.newBuilder()
|
||||
.setEntityId(target.getId())
|
||||
.setLifeState(lifeState.getValue())
|
||||
.setSourceEntityId(attacker.getId())
|
||||
.build();
|
||||
|
||||
this.setData(proto);
|
||||
}
|
||||
this.setData(proto);
|
||||
}
|
||||
|
||||
public PacketLifeStateChangeNotify(GameEntity entity, LifeState lifeState, PlayerDieType dieType) {
|
||||
this(entity, lifeState, null, "", dieType);
|
||||
}
|
||||
public PacketLifeStateChangeNotify(int attackerId, GameEntity target, LifeState lifeState) {
|
||||
super(PacketOpcodes.LifeStateChangeNotify);
|
||||
|
||||
public PacketLifeStateChangeNotify(GameEntity entity, LifeState lifeState, GameEntity sourceEntity,
|
||||
String attackTag, PlayerDieType dieType) {
|
||||
super(PacketOpcodes.LifeStateChangeNotify);
|
||||
LifeStateChangeNotify proto = LifeStateChangeNotify.newBuilder()
|
||||
.setEntityId(target.getId())
|
||||
.setLifeState(lifeState.getValue())
|
||||
.setSourceEntityId(attackerId)
|
||||
.build();
|
||||
|
||||
LifeStateChangeNotify.Builder proto = LifeStateChangeNotify.newBuilder();
|
||||
this.setData(proto);
|
||||
}
|
||||
|
||||
public PacketLifeStateChangeNotify(GameEntity entity, LifeState lifeState, PlayerDieType dieType) {
|
||||
this(entity, lifeState, null, "", dieType);
|
||||
}
|
||||
|
||||
public PacketLifeStateChangeNotify(GameEntity entity, LifeState lifeState, GameEntity sourceEntity,
|
||||
String attackTag, PlayerDieType dieType) {
|
||||
super(PacketOpcodes.LifeStateChangeNotify);
|
||||
|
||||
LifeStateChangeNotify.Builder proto = LifeStateChangeNotify.newBuilder();
|
||||
|
||||
|
||||
proto.setEntityId(entity.getId());
|
||||
proto.setLifeState(lifeState.getValue());
|
||||
if (sourceEntity != null) {
|
||||
proto.setSourceEntityId(sourceEntity.getId());
|
||||
}
|
||||
proto.setAttackTag(attackTag);
|
||||
proto.setDieType(dieType);
|
||||
proto.setEntityId(entity.getId());
|
||||
proto.setLifeState(lifeState.getValue());
|
||||
if (sourceEntity != null) {
|
||||
proto.setSourceEntityId(sourceEntity.getId());
|
||||
}
|
||||
proto.setAttackTag(attackTag);
|
||||
proto.setDieType(dieType);
|
||||
|
||||
this.setData(proto.build());
|
||||
}
|
||||
this.setData(proto.build());
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user