mirror of
https://github.com/Melledy/Nebula.git
synced 2025-12-15 13:54:51 +01:00
Implement mass limit break
This commit is contained in:
@@ -7,15 +7,12 @@ import emu.nebula.GameConstants;
|
||||
import emu.nebula.proto.AnyOuterClass.Any;
|
||||
import emu.nebula.proto.Public.ChangeInfo;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
import us.hebi.quickbuf.ProtoMessage;
|
||||
|
||||
@Getter
|
||||
public class PlayerChangeInfo {
|
||||
private boolean success;
|
||||
private List<Any> list;
|
||||
|
||||
@Setter
|
||||
private Object extraData;
|
||||
|
||||
public PlayerChangeInfo() {
|
||||
@@ -30,6 +27,11 @@ public class PlayerChangeInfo {
|
||||
public boolean isEmpty() {
|
||||
return this.list == null || this.list.isEmpty();
|
||||
}
|
||||
|
||||
public PlayerChangeInfo setExtraData(Object extraData) {
|
||||
this.extraData = extraData;
|
||||
return this;
|
||||
}
|
||||
|
||||
public void add(ProtoMessage<?> proto) {
|
||||
var any = Any.newInstance()
|
||||
@@ -39,6 +41,10 @@ public class PlayerChangeInfo {
|
||||
this.list.add(any);
|
||||
}
|
||||
|
||||
public void add(PlayerChangeInfo otherChange) {
|
||||
this.getList().addAll(otherChange.getList());
|
||||
}
|
||||
|
||||
// Proto
|
||||
|
||||
public ChangeInfo toProto() {
|
||||
|
||||
Reference in New Issue
Block a user