Implement simulated universe start screen

This commit is contained in:
Melledy
2023-10-19 08:51:53 -07:00
parent 4d55d4d816
commit 514b022008
21 changed files with 5795 additions and 1 deletions

View File

@@ -0,0 +1,362 @@
// Code generated by protocol buffer compiler. Do not edit!
package emu.lunarcore.proto;
import java.io.IOException;
import us.hebi.quickbuf.FieldName;
import us.hebi.quickbuf.InvalidProtocolBufferException;
import us.hebi.quickbuf.JsonSink;
import us.hebi.quickbuf.JsonSource;
import us.hebi.quickbuf.MessageFactory;
import us.hebi.quickbuf.ProtoMessage;
import us.hebi.quickbuf.ProtoSink;
import us.hebi.quickbuf.ProtoSource;
public final class GetRogueHandbookDataScRspOuterClass {
/**
* Protobuf type {@code GetRogueHandbookDataScRsp}
*/
public static final class GetRogueHandbookDataScRsp extends ProtoMessage<GetRogueHandbookDataScRsp> implements Cloneable {
private static final long serialVersionUID = 0L;
/**
* <code>optional uint32 retcode = 6;</code>
*/
private int retcode;
/**
* <code>optional .RogueHandbookData handbook_info = 11;</code>
*/
private final RogueHandbookDataOuterClass.RogueHandbookData handbookInfo = RogueHandbookDataOuterClass.RogueHandbookData.newInstance();
private GetRogueHandbookDataScRsp() {
}
/**
* @return a new empty instance of {@code GetRogueHandbookDataScRsp}
*/
public static GetRogueHandbookDataScRsp newInstance() {
return new GetRogueHandbookDataScRsp();
}
/**
* <code>optional uint32 retcode = 6;</code>
* @return whether the retcode field is set
*/
public boolean hasRetcode() {
return (bitField0_ & 0x00000001) != 0;
}
/**
* <code>optional uint32 retcode = 6;</code>
* @return this
*/
public GetRogueHandbookDataScRsp clearRetcode() {
bitField0_ &= ~0x00000001;
retcode = 0;
return this;
}
/**
* <code>optional uint32 retcode = 6;</code>
* @return the retcode
*/
public int getRetcode() {
return retcode;
}
/**
* <code>optional uint32 retcode = 6;</code>
* @param value the retcode to set
* @return this
*/
public GetRogueHandbookDataScRsp setRetcode(final int value) {
bitField0_ |= 0x00000001;
retcode = value;
return this;
}
/**
* <code>optional .RogueHandbookData handbook_info = 11;</code>
* @return whether the handbookInfo field is set
*/
public boolean hasHandbookInfo() {
return (bitField0_ & 0x00000002) != 0;
}
/**
* <code>optional .RogueHandbookData handbook_info = 11;</code>
* @return this
*/
public GetRogueHandbookDataScRsp clearHandbookInfo() {
bitField0_ &= ~0x00000002;
handbookInfo.clear();
return this;
}
/**
* <code>optional .RogueHandbookData handbook_info = 11;</code>
*
* This method returns the internal storage object without modifying any has state.
* The returned object should not be modified and be treated as read-only.
*
* Use {@link #getMutableHandbookInfo()} if you want to modify it.
*
* @return internal storage object for reading
*/
public RogueHandbookDataOuterClass.RogueHandbookData getHandbookInfo() {
return handbookInfo;
}
/**
* <code>optional .RogueHandbookData handbook_info = 11;</code>
*
* This method returns the internal storage object and sets the corresponding
* has state. The returned object will become part of this message and its
* contents may be modified as long as the has state is not cleared.
*
* @return internal storage object for modifications
*/
public RogueHandbookDataOuterClass.RogueHandbookData getMutableHandbookInfo() {
bitField0_ |= 0x00000002;
return handbookInfo;
}
/**
* <code>optional .RogueHandbookData handbook_info = 11;</code>
* @param value the handbookInfo to set
* @return this
*/
public GetRogueHandbookDataScRsp setHandbookInfo(
final RogueHandbookDataOuterClass.RogueHandbookData value) {
bitField0_ |= 0x00000002;
handbookInfo.copyFrom(value);
return this;
}
@Override
public GetRogueHandbookDataScRsp copyFrom(final GetRogueHandbookDataScRsp other) {
cachedSize = other.cachedSize;
if ((bitField0_ | other.bitField0_) != 0) {
bitField0_ = other.bitField0_;
retcode = other.retcode;
handbookInfo.copyFrom(other.handbookInfo);
}
return this;
}
@Override
public GetRogueHandbookDataScRsp mergeFrom(final GetRogueHandbookDataScRsp other) {
if (other.isEmpty()) {
return this;
}
cachedSize = -1;
if (other.hasRetcode()) {
setRetcode(other.retcode);
}
if (other.hasHandbookInfo()) {
getMutableHandbookInfo().mergeFrom(other.handbookInfo);
}
return this;
}
@Override
public GetRogueHandbookDataScRsp clear() {
if (isEmpty()) {
return this;
}
cachedSize = -1;
bitField0_ = 0;
retcode = 0;
handbookInfo.clear();
return this;
}
@Override
public GetRogueHandbookDataScRsp clearQuick() {
if (isEmpty()) {
return this;
}
cachedSize = -1;
bitField0_ = 0;
handbookInfo.clearQuick();
return this;
}
@Override
public boolean equals(Object o) {
if (o == this) {
return true;
}
if (!(o instanceof GetRogueHandbookDataScRsp)) {
return false;
}
GetRogueHandbookDataScRsp other = (GetRogueHandbookDataScRsp) o;
return bitField0_ == other.bitField0_
&& (!hasRetcode() || retcode == other.retcode)
&& (!hasHandbookInfo() || handbookInfo.equals(other.handbookInfo));
}
@Override
public void writeTo(final ProtoSink output) throws IOException {
if ((bitField0_ & 0x00000001) != 0) {
output.writeRawByte((byte) 48);
output.writeUInt32NoTag(retcode);
}
if ((bitField0_ & 0x00000002) != 0) {
output.writeRawByte((byte) 90);
output.writeMessageNoTag(handbookInfo);
}
}
@Override
protected int computeSerializedSize() {
int size = 0;
if ((bitField0_ & 0x00000001) != 0) {
size += 1 + ProtoSink.computeUInt32SizeNoTag(retcode);
}
if ((bitField0_ & 0x00000002) != 0) {
size += 1 + ProtoSink.computeMessageSizeNoTag(handbookInfo);
}
return size;
}
@Override
@SuppressWarnings("fallthrough")
public GetRogueHandbookDataScRsp mergeFrom(final ProtoSource input) throws IOException {
// Enabled Fall-Through Optimization (QuickBuffers)
int tag = input.readTag();
while (true) {
switch (tag) {
case 48: {
// retcode
retcode = input.readUInt32();
bitField0_ |= 0x00000001;
tag = input.readTag();
if (tag != 90) {
break;
}
}
case 90: {
// handbookInfo
input.readMessage(handbookInfo);
bitField0_ |= 0x00000002;
tag = input.readTag();
if (tag != 0) {
break;
}
}
case 0: {
return this;
}
default: {
if (!input.skipField(tag)) {
return this;
}
tag = input.readTag();
break;
}
}
}
}
@Override
public void writeTo(final JsonSink output) throws IOException {
output.beginObject();
if ((bitField0_ & 0x00000001) != 0) {
output.writeUInt32(FieldNames.retcode, retcode);
}
if ((bitField0_ & 0x00000002) != 0) {
output.writeMessage(FieldNames.handbookInfo, handbookInfo);
}
output.endObject();
}
@Override
public GetRogueHandbookDataScRsp mergeFrom(final JsonSource input) throws IOException {
if (!input.beginObject()) {
return this;
}
while (!input.isAtEnd()) {
switch (input.readFieldHash()) {
case 1097936398: {
if (input.isAtField(FieldNames.retcode)) {
if (!input.trySkipNullValue()) {
retcode = input.readUInt32();
bitField0_ |= 0x00000001;
}
} else {
input.skipUnknownField();
}
break;
}
case -460040026:
case -1356162891: {
if (input.isAtField(FieldNames.handbookInfo)) {
if (!input.trySkipNullValue()) {
input.readMessage(handbookInfo);
bitField0_ |= 0x00000002;
}
} else {
input.skipUnknownField();
}
break;
}
default: {
input.skipUnknownField();
break;
}
}
}
input.endObject();
return this;
}
@Override
public GetRogueHandbookDataScRsp clone() {
return new GetRogueHandbookDataScRsp().copyFrom(this);
}
@Override
public boolean isEmpty() {
return ((bitField0_) == 0);
}
public static GetRogueHandbookDataScRsp parseFrom(final byte[] data) throws
InvalidProtocolBufferException {
return ProtoMessage.mergeFrom(new GetRogueHandbookDataScRsp(), data).checkInitialized();
}
public static GetRogueHandbookDataScRsp parseFrom(final ProtoSource input) throws IOException {
return ProtoMessage.mergeFrom(new GetRogueHandbookDataScRsp(), input).checkInitialized();
}
public static GetRogueHandbookDataScRsp parseFrom(final JsonSource input) throws IOException {
return ProtoMessage.mergeFrom(new GetRogueHandbookDataScRsp(), input).checkInitialized();
}
/**
* @return factory for creating GetRogueHandbookDataScRsp messages
*/
public static MessageFactory<GetRogueHandbookDataScRsp> getFactory() {
return GetRogueHandbookDataScRspFactory.INSTANCE;
}
private enum GetRogueHandbookDataScRspFactory implements MessageFactory<GetRogueHandbookDataScRsp> {
INSTANCE;
@Override
public GetRogueHandbookDataScRsp create() {
return GetRogueHandbookDataScRsp.newInstance();
}
}
/**
* Contains name constants used for serializing JSON
*/
static class FieldNames {
static final FieldName retcode = FieldName.forField("retcode");
static final FieldName handbookInfo = FieldName.forField("handbookInfo", "handbook_info");
}
}
}

View File

@@ -0,0 +1,361 @@
// Code generated by protocol buffer compiler. Do not edit!
package emu.lunarcore.proto;
import java.io.IOException;
import us.hebi.quickbuf.FieldName;
import us.hebi.quickbuf.InvalidProtocolBufferException;
import us.hebi.quickbuf.JsonSink;
import us.hebi.quickbuf.JsonSource;
import us.hebi.quickbuf.MessageFactory;
import us.hebi.quickbuf.ProtoMessage;
import us.hebi.quickbuf.ProtoSink;
import us.hebi.quickbuf.ProtoSource;
public final class GetRogueInfoScRspOuterClass {
/**
* Protobuf type {@code GetRogueInfoScRsp}
*/
public static final class GetRogueInfoScRsp extends ProtoMessage<GetRogueInfoScRsp> implements Cloneable {
private static final long serialVersionUID = 0L;
/**
* <code>optional uint32 retcode = 11;</code>
*/
private int retcode;
/**
* <code>optional .RogueInfo rogue_info = 3;</code>
*/
private final RogueInfoOuterClass.RogueInfo rogueInfo = RogueInfoOuterClass.RogueInfo.newInstance();
private GetRogueInfoScRsp() {
}
/**
* @return a new empty instance of {@code GetRogueInfoScRsp}
*/
public static GetRogueInfoScRsp newInstance() {
return new GetRogueInfoScRsp();
}
/**
* <code>optional uint32 retcode = 11;</code>
* @return whether the retcode field is set
*/
public boolean hasRetcode() {
return (bitField0_ & 0x00000001) != 0;
}
/**
* <code>optional uint32 retcode = 11;</code>
* @return this
*/
public GetRogueInfoScRsp clearRetcode() {
bitField0_ &= ~0x00000001;
retcode = 0;
return this;
}
/**
* <code>optional uint32 retcode = 11;</code>
* @return the retcode
*/
public int getRetcode() {
return retcode;
}
/**
* <code>optional uint32 retcode = 11;</code>
* @param value the retcode to set
* @return this
*/
public GetRogueInfoScRsp setRetcode(final int value) {
bitField0_ |= 0x00000001;
retcode = value;
return this;
}
/**
* <code>optional .RogueInfo rogue_info = 3;</code>
* @return whether the rogueInfo field is set
*/
public boolean hasRogueInfo() {
return (bitField0_ & 0x00000002) != 0;
}
/**
* <code>optional .RogueInfo rogue_info = 3;</code>
* @return this
*/
public GetRogueInfoScRsp clearRogueInfo() {
bitField0_ &= ~0x00000002;
rogueInfo.clear();
return this;
}
/**
* <code>optional .RogueInfo rogue_info = 3;</code>
*
* This method returns the internal storage object without modifying any has state.
* The returned object should not be modified and be treated as read-only.
*
* Use {@link #getMutableRogueInfo()} if you want to modify it.
*
* @return internal storage object for reading
*/
public RogueInfoOuterClass.RogueInfo getRogueInfo() {
return rogueInfo;
}
/**
* <code>optional .RogueInfo rogue_info = 3;</code>
*
* This method returns the internal storage object and sets the corresponding
* has state. The returned object will become part of this message and its
* contents may be modified as long as the has state is not cleared.
*
* @return internal storage object for modifications
*/
public RogueInfoOuterClass.RogueInfo getMutableRogueInfo() {
bitField0_ |= 0x00000002;
return rogueInfo;
}
/**
* <code>optional .RogueInfo rogue_info = 3;</code>
* @param value the rogueInfo to set
* @return this
*/
public GetRogueInfoScRsp setRogueInfo(final RogueInfoOuterClass.RogueInfo value) {
bitField0_ |= 0x00000002;
rogueInfo.copyFrom(value);
return this;
}
@Override
public GetRogueInfoScRsp copyFrom(final GetRogueInfoScRsp other) {
cachedSize = other.cachedSize;
if ((bitField0_ | other.bitField0_) != 0) {
bitField0_ = other.bitField0_;
retcode = other.retcode;
rogueInfo.copyFrom(other.rogueInfo);
}
return this;
}
@Override
public GetRogueInfoScRsp mergeFrom(final GetRogueInfoScRsp other) {
if (other.isEmpty()) {
return this;
}
cachedSize = -1;
if (other.hasRetcode()) {
setRetcode(other.retcode);
}
if (other.hasRogueInfo()) {
getMutableRogueInfo().mergeFrom(other.rogueInfo);
}
return this;
}
@Override
public GetRogueInfoScRsp clear() {
if (isEmpty()) {
return this;
}
cachedSize = -1;
bitField0_ = 0;
retcode = 0;
rogueInfo.clear();
return this;
}
@Override
public GetRogueInfoScRsp clearQuick() {
if (isEmpty()) {
return this;
}
cachedSize = -1;
bitField0_ = 0;
rogueInfo.clearQuick();
return this;
}
@Override
public boolean equals(Object o) {
if (o == this) {
return true;
}
if (!(o instanceof GetRogueInfoScRsp)) {
return false;
}
GetRogueInfoScRsp other = (GetRogueInfoScRsp) o;
return bitField0_ == other.bitField0_
&& (!hasRetcode() || retcode == other.retcode)
&& (!hasRogueInfo() || rogueInfo.equals(other.rogueInfo));
}
@Override
public void writeTo(final ProtoSink output) throws IOException {
if ((bitField0_ & 0x00000001) != 0) {
output.writeRawByte((byte) 88);
output.writeUInt32NoTag(retcode);
}
if ((bitField0_ & 0x00000002) != 0) {
output.writeRawByte((byte) 26);
output.writeMessageNoTag(rogueInfo);
}
}
@Override
protected int computeSerializedSize() {
int size = 0;
if ((bitField0_ & 0x00000001) != 0) {
size += 1 + ProtoSink.computeUInt32SizeNoTag(retcode);
}
if ((bitField0_ & 0x00000002) != 0) {
size += 1 + ProtoSink.computeMessageSizeNoTag(rogueInfo);
}
return size;
}
@Override
@SuppressWarnings("fallthrough")
public GetRogueInfoScRsp mergeFrom(final ProtoSource input) throws IOException {
// Enabled Fall-Through Optimization (QuickBuffers)
int tag = input.readTag();
while (true) {
switch (tag) {
case 88: {
// retcode
retcode = input.readUInt32();
bitField0_ |= 0x00000001;
tag = input.readTag();
if (tag != 26) {
break;
}
}
case 26: {
// rogueInfo
input.readMessage(rogueInfo);
bitField0_ |= 0x00000002;
tag = input.readTag();
if (tag != 0) {
break;
}
}
case 0: {
return this;
}
default: {
if (!input.skipField(tag)) {
return this;
}
tag = input.readTag();
break;
}
}
}
}
@Override
public void writeTo(final JsonSink output) throws IOException {
output.beginObject();
if ((bitField0_ & 0x00000001) != 0) {
output.writeUInt32(FieldNames.retcode, retcode);
}
if ((bitField0_ & 0x00000002) != 0) {
output.writeMessage(FieldNames.rogueInfo, rogueInfo);
}
output.endObject();
}
@Override
public GetRogueInfoScRsp mergeFrom(final JsonSource input) throws IOException {
if (!input.beginObject()) {
return this;
}
while (!input.isAtEnd()) {
switch (input.readFieldHash()) {
case 1097936398: {
if (input.isAtField(FieldNames.retcode)) {
if (!input.trySkipNullValue()) {
retcode = input.readUInt32();
bitField0_ |= 0x00000001;
}
} else {
input.skipUnknownField();
}
break;
}
case 655808936:
case -1124583437: {
if (input.isAtField(FieldNames.rogueInfo)) {
if (!input.trySkipNullValue()) {
input.readMessage(rogueInfo);
bitField0_ |= 0x00000002;
}
} else {
input.skipUnknownField();
}
break;
}
default: {
input.skipUnknownField();
break;
}
}
}
input.endObject();
return this;
}
@Override
public GetRogueInfoScRsp clone() {
return new GetRogueInfoScRsp().copyFrom(this);
}
@Override
public boolean isEmpty() {
return ((bitField0_) == 0);
}
public static GetRogueInfoScRsp parseFrom(final byte[] data) throws
InvalidProtocolBufferException {
return ProtoMessage.mergeFrom(new GetRogueInfoScRsp(), data).checkInitialized();
}
public static GetRogueInfoScRsp parseFrom(final ProtoSource input) throws IOException {
return ProtoMessage.mergeFrom(new GetRogueInfoScRsp(), input).checkInitialized();
}
public static GetRogueInfoScRsp parseFrom(final JsonSource input) throws IOException {
return ProtoMessage.mergeFrom(new GetRogueInfoScRsp(), input).checkInitialized();
}
/**
* @return factory for creating GetRogueInfoScRsp messages
*/
public static MessageFactory<GetRogueInfoScRsp> getFactory() {
return GetRogueInfoScRspFactory.INSTANCE;
}
private enum GetRogueInfoScRspFactory implements MessageFactory<GetRogueInfoScRsp> {
INSTANCE;
@Override
public GetRogueInfoScRsp create() {
return GetRogueInfoScRsp.newInstance();
}
}
/**
* Contains name constants used for serializing JSON
*/
static class FieldNames {
static final FieldName retcode = FieldName.forField("retcode");
static final FieldName rogueInfo = FieldName.forField("rogueInfo", "rogue_info");
}
}
}

View File

@@ -0,0 +1,364 @@
// Code generated by protocol buffer compiler. Do not edit!
package emu.lunarcore.proto;
import java.io.IOException;
import us.hebi.quickbuf.FieldName;
import us.hebi.quickbuf.InvalidProtocolBufferException;
import us.hebi.quickbuf.JsonSink;
import us.hebi.quickbuf.JsonSource;
import us.hebi.quickbuf.MessageFactory;
import us.hebi.quickbuf.ProtoMessage;
import us.hebi.quickbuf.ProtoSink;
import us.hebi.quickbuf.ProtoSource;
public final class GetRogueScoreRewardInfoScRspOuterClass {
/**
* Protobuf type {@code GetRogueScoreRewardInfoScRsp}
*/
public static final class GetRogueScoreRewardInfoScRsp extends ProtoMessage<GetRogueScoreRewardInfoScRsp> implements Cloneable {
private static final long serialVersionUID = 0L;
/**
* <code>optional uint32 retcode = 2;</code>
*/
private int retcode;
/**
* <code>optional .RogueScoreRewardInfo score_reward_info = 13;</code>
*/
private final RogueScoreRewardInfoOuterClass.RogueScoreRewardInfo scoreRewardInfo = RogueScoreRewardInfoOuterClass.RogueScoreRewardInfo.newInstance();
private GetRogueScoreRewardInfoScRsp() {
}
/**
* @return a new empty instance of {@code GetRogueScoreRewardInfoScRsp}
*/
public static GetRogueScoreRewardInfoScRsp newInstance() {
return new GetRogueScoreRewardInfoScRsp();
}
/**
* <code>optional uint32 retcode = 2;</code>
* @return whether the retcode field is set
*/
public boolean hasRetcode() {
return (bitField0_ & 0x00000001) != 0;
}
/**
* <code>optional uint32 retcode = 2;</code>
* @return this
*/
public GetRogueScoreRewardInfoScRsp clearRetcode() {
bitField0_ &= ~0x00000001;
retcode = 0;
return this;
}
/**
* <code>optional uint32 retcode = 2;</code>
* @return the retcode
*/
public int getRetcode() {
return retcode;
}
/**
* <code>optional uint32 retcode = 2;</code>
* @param value the retcode to set
* @return this
*/
public GetRogueScoreRewardInfoScRsp setRetcode(final int value) {
bitField0_ |= 0x00000001;
retcode = value;
return this;
}
/**
* <code>optional .RogueScoreRewardInfo score_reward_info = 13;</code>
* @return whether the scoreRewardInfo field is set
*/
public boolean hasScoreRewardInfo() {
return (bitField0_ & 0x00000002) != 0;
}
/**
* <code>optional .RogueScoreRewardInfo score_reward_info = 13;</code>
* @return this
*/
public GetRogueScoreRewardInfoScRsp clearScoreRewardInfo() {
bitField0_ &= ~0x00000002;
scoreRewardInfo.clear();
return this;
}
/**
* <code>optional .RogueScoreRewardInfo score_reward_info = 13;</code>
*
* This method returns the internal storage object without modifying any has state.
* The returned object should not be modified and be treated as read-only.
*
* Use {@link #getMutableScoreRewardInfo()} if you want to modify it.
*
* @return internal storage object for reading
*/
public RogueScoreRewardInfoOuterClass.RogueScoreRewardInfo getScoreRewardInfo() {
return scoreRewardInfo;
}
/**
* <code>optional .RogueScoreRewardInfo score_reward_info = 13;</code>
*
* This method returns the internal storage object and sets the corresponding
* has state. The returned object will become part of this message and its
* contents may be modified as long as the has state is not cleared.
*
* @return internal storage object for modifications
*/
public RogueScoreRewardInfoOuterClass.RogueScoreRewardInfo getMutableScoreRewardInfo() {
bitField0_ |= 0x00000002;
return scoreRewardInfo;
}
/**
* <code>optional .RogueScoreRewardInfo score_reward_info = 13;</code>
* @param value the scoreRewardInfo to set
* @return this
*/
public GetRogueScoreRewardInfoScRsp setScoreRewardInfo(
final RogueScoreRewardInfoOuterClass.RogueScoreRewardInfo value) {
bitField0_ |= 0x00000002;
scoreRewardInfo.copyFrom(value);
return this;
}
@Override
public GetRogueScoreRewardInfoScRsp copyFrom(final GetRogueScoreRewardInfoScRsp other) {
cachedSize = other.cachedSize;
if ((bitField0_ | other.bitField0_) != 0) {
bitField0_ = other.bitField0_;
retcode = other.retcode;
scoreRewardInfo.copyFrom(other.scoreRewardInfo);
}
return this;
}
@Override
public GetRogueScoreRewardInfoScRsp mergeFrom(final GetRogueScoreRewardInfoScRsp other) {
if (other.isEmpty()) {
return this;
}
cachedSize = -1;
if (other.hasRetcode()) {
setRetcode(other.retcode);
}
if (other.hasScoreRewardInfo()) {
getMutableScoreRewardInfo().mergeFrom(other.scoreRewardInfo);
}
return this;
}
@Override
public GetRogueScoreRewardInfoScRsp clear() {
if (isEmpty()) {
return this;
}
cachedSize = -1;
bitField0_ = 0;
retcode = 0;
scoreRewardInfo.clear();
return this;
}
@Override
public GetRogueScoreRewardInfoScRsp clearQuick() {
if (isEmpty()) {
return this;
}
cachedSize = -1;
bitField0_ = 0;
scoreRewardInfo.clearQuick();
return this;
}
@Override
public boolean equals(Object o) {
if (o == this) {
return true;
}
if (!(o instanceof GetRogueScoreRewardInfoScRsp)) {
return false;
}
GetRogueScoreRewardInfoScRsp other = (GetRogueScoreRewardInfoScRsp) o;
return bitField0_ == other.bitField0_
&& (!hasRetcode() || retcode == other.retcode)
&& (!hasScoreRewardInfo() || scoreRewardInfo.equals(other.scoreRewardInfo));
}
@Override
public void writeTo(final ProtoSink output) throws IOException {
if ((bitField0_ & 0x00000001) != 0) {
output.writeRawByte((byte) 16);
output.writeUInt32NoTag(retcode);
}
if ((bitField0_ & 0x00000002) != 0) {
output.writeRawByte((byte) 106);
output.writeMessageNoTag(scoreRewardInfo);
}
}
@Override
protected int computeSerializedSize() {
int size = 0;
if ((bitField0_ & 0x00000001) != 0) {
size += 1 + ProtoSink.computeUInt32SizeNoTag(retcode);
}
if ((bitField0_ & 0x00000002) != 0) {
size += 1 + ProtoSink.computeMessageSizeNoTag(scoreRewardInfo);
}
return size;
}
@Override
@SuppressWarnings("fallthrough")
public GetRogueScoreRewardInfoScRsp mergeFrom(final ProtoSource input) throws IOException {
// Enabled Fall-Through Optimization (QuickBuffers)
int tag = input.readTag();
while (true) {
switch (tag) {
case 16: {
// retcode
retcode = input.readUInt32();
bitField0_ |= 0x00000001;
tag = input.readTag();
if (tag != 106) {
break;
}
}
case 106: {
// scoreRewardInfo
input.readMessage(scoreRewardInfo);
bitField0_ |= 0x00000002;
tag = input.readTag();
if (tag != 0) {
break;
}
}
case 0: {
return this;
}
default: {
if (!input.skipField(tag)) {
return this;
}
tag = input.readTag();
break;
}
}
}
}
@Override
public void writeTo(final JsonSink output) throws IOException {
output.beginObject();
if ((bitField0_ & 0x00000001) != 0) {
output.writeUInt32(FieldNames.retcode, retcode);
}
if ((bitField0_ & 0x00000002) != 0) {
output.writeMessage(FieldNames.scoreRewardInfo, scoreRewardInfo);
}
output.endObject();
}
@Override
public GetRogueScoreRewardInfoScRsp mergeFrom(final JsonSource input) throws IOException {
if (!input.beginObject()) {
return this;
}
while (!input.isAtEnd()) {
switch (input.readFieldHash()) {
case 1097936398: {
if (input.isAtField(FieldNames.retcode)) {
if (!input.trySkipNullValue()) {
retcode = input.readUInt32();
bitField0_ |= 0x00000001;
}
} else {
input.skipUnknownField();
}
break;
}
case 672564399:
case 751191441: {
if (input.isAtField(FieldNames.scoreRewardInfo)) {
if (!input.trySkipNullValue()) {
input.readMessage(scoreRewardInfo);
bitField0_ |= 0x00000002;
}
} else {
input.skipUnknownField();
}
break;
}
default: {
input.skipUnknownField();
break;
}
}
}
input.endObject();
return this;
}
@Override
public GetRogueScoreRewardInfoScRsp clone() {
return new GetRogueScoreRewardInfoScRsp().copyFrom(this);
}
@Override
public boolean isEmpty() {
return ((bitField0_) == 0);
}
public static GetRogueScoreRewardInfoScRsp parseFrom(final byte[] data) throws
InvalidProtocolBufferException {
return ProtoMessage.mergeFrom(new GetRogueScoreRewardInfoScRsp(), data).checkInitialized();
}
public static GetRogueScoreRewardInfoScRsp parseFrom(final ProtoSource input) throws
IOException {
return ProtoMessage.mergeFrom(new GetRogueScoreRewardInfoScRsp(), input).checkInitialized();
}
public static GetRogueScoreRewardInfoScRsp parseFrom(final JsonSource input) throws
IOException {
return ProtoMessage.mergeFrom(new GetRogueScoreRewardInfoScRsp(), input).checkInitialized();
}
/**
* @return factory for creating GetRogueScoreRewardInfoScRsp messages
*/
public static MessageFactory<GetRogueScoreRewardInfoScRsp> getFactory() {
return GetRogueScoreRewardInfoScRspFactory.INSTANCE;
}
private enum GetRogueScoreRewardInfoScRspFactory implements MessageFactory<GetRogueScoreRewardInfoScRsp> {
INSTANCE;
@Override
public GetRogueScoreRewardInfoScRsp create() {
return GetRogueScoreRewardInfoScRsp.newInstance();
}
}
/**
* Contains name constants used for serializing JSON
*/
static class FieldNames {
static final FieldName retcode = FieldName.forField("retcode");
static final FieldName scoreRewardInfo = FieldName.forField("scoreRewardInfo", "score_reward_info");
}
}
}

View File

@@ -0,0 +1,730 @@
// Code generated by protocol buffer compiler. Do not edit!
package emu.lunarcore.proto;
import java.io.IOException;
import us.hebi.quickbuf.FieldName;
import us.hebi.quickbuf.InvalidProtocolBufferException;
import us.hebi.quickbuf.JsonSink;
import us.hebi.quickbuf.JsonSource;
import us.hebi.quickbuf.MessageFactory;
import us.hebi.quickbuf.ProtoMessage;
import us.hebi.quickbuf.ProtoSink;
import us.hebi.quickbuf.ProtoSource;
public final class RogueAreaOuterClass {
/**
* Protobuf type {@code RogueArea}
*/
public static final class RogueArea extends ProtoMessage<RogueArea> implements Cloneable {
private static final long serialVersionUID = 0L;
/**
* <code>optional uint32 area_id = 4;</code>
*/
private int areaId;
/**
* <code>optional uint32 cur_reach_room_num = 10;</code>
*/
private int curReachRoomNum;
/**
* <code>optional uint32 map_id = 13;</code>
*/
private int mapId;
/**
* <code>optional .RogueAreaStatus rogue_area_status = 6;</code>
*/
private int rogueAreaStatus;
/**
* <code>optional .RogueStatus rogue_status = 9;</code>
*/
private int rogueStatus;
/**
* <code>optional bool is_reward_taken = 7;</code>
*/
private boolean isRewardTaken;
private RogueArea() {
}
/**
* @return a new empty instance of {@code RogueArea}
*/
public static RogueArea newInstance() {
return new RogueArea();
}
/**
* <code>optional uint32 area_id = 4;</code>
* @return whether the areaId field is set
*/
public boolean hasAreaId() {
return (bitField0_ & 0x00000001) != 0;
}
/**
* <code>optional uint32 area_id = 4;</code>
* @return this
*/
public RogueArea clearAreaId() {
bitField0_ &= ~0x00000001;
areaId = 0;
return this;
}
/**
* <code>optional uint32 area_id = 4;</code>
* @return the areaId
*/
public int getAreaId() {
return areaId;
}
/**
* <code>optional uint32 area_id = 4;</code>
* @param value the areaId to set
* @return this
*/
public RogueArea setAreaId(final int value) {
bitField0_ |= 0x00000001;
areaId = value;
return this;
}
/**
* <code>optional uint32 cur_reach_room_num = 10;</code>
* @return whether the curReachRoomNum field is set
*/
public boolean hasCurReachRoomNum() {
return (bitField0_ & 0x00000002) != 0;
}
/**
* <code>optional uint32 cur_reach_room_num = 10;</code>
* @return this
*/
public RogueArea clearCurReachRoomNum() {
bitField0_ &= ~0x00000002;
curReachRoomNum = 0;
return this;
}
/**
* <code>optional uint32 cur_reach_room_num = 10;</code>
* @return the curReachRoomNum
*/
public int getCurReachRoomNum() {
return curReachRoomNum;
}
/**
* <code>optional uint32 cur_reach_room_num = 10;</code>
* @param value the curReachRoomNum to set
* @return this
*/
public RogueArea setCurReachRoomNum(final int value) {
bitField0_ |= 0x00000002;
curReachRoomNum = value;
return this;
}
/**
* <code>optional uint32 map_id = 13;</code>
* @return whether the mapId field is set
*/
public boolean hasMapId() {
return (bitField0_ & 0x00000004) != 0;
}
/**
* <code>optional uint32 map_id = 13;</code>
* @return this
*/
public RogueArea clearMapId() {
bitField0_ &= ~0x00000004;
mapId = 0;
return this;
}
/**
* <code>optional uint32 map_id = 13;</code>
* @return the mapId
*/
public int getMapId() {
return mapId;
}
/**
* <code>optional uint32 map_id = 13;</code>
* @param value the mapId to set
* @return this
*/
public RogueArea setMapId(final int value) {
bitField0_ |= 0x00000004;
mapId = value;
return this;
}
/**
* <code>optional .RogueAreaStatus rogue_area_status = 6;</code>
* @return whether the rogueAreaStatus field is set
*/
public boolean hasRogueAreaStatus() {
return (bitField0_ & 0x00000008) != 0;
}
/**
* <code>optional .RogueAreaStatus rogue_area_status = 6;</code>
* @return this
*/
public RogueArea clearRogueAreaStatus() {
bitField0_ &= ~0x00000008;
rogueAreaStatus = 0;
return this;
}
/**
* <code>optional .RogueAreaStatus rogue_area_status = 6;</code>
* @return the rogueAreaStatus
*/
public RogueAreaStatusOuterClass.RogueAreaStatus getRogueAreaStatus() {
return RogueAreaStatusOuterClass.RogueAreaStatus.forNumber(rogueAreaStatus);
}
/**
* Gets the value of the internal enum store. The result is
* equivalent to {@link RogueArea#getRogueAreaStatus()}.getNumber().
*
* @return numeric wire representation
*/
public int getRogueAreaStatusValue() {
return rogueAreaStatus;
}
/**
* Sets the value of the internal enum store. This does not
* do any validity checks, so be sure to use appropriate value
* constants from {@link RogueAreaStatusOuterClass.RogueAreaStatus}. Setting an invalid value
* can cause {@link RogueArea#getRogueAreaStatus()} to return null
*
* @param value the numeric wire value to set
* @return this
*/
public RogueArea setRogueAreaStatusValue(final int value) {
bitField0_ |= 0x00000008;
rogueAreaStatus = value;
return this;
}
/**
* <code>optional .RogueAreaStatus rogue_area_status = 6;</code>
* @param value the rogueAreaStatus to set
* @return this
*/
public RogueArea setRogueAreaStatus(final RogueAreaStatusOuterClass.RogueAreaStatus value) {
bitField0_ |= 0x00000008;
rogueAreaStatus = value.getNumber();
return this;
}
/**
* <code>optional .RogueStatus rogue_status = 9;</code>
* @return whether the rogueStatus field is set
*/
public boolean hasRogueStatus() {
return (bitField0_ & 0x00000010) != 0;
}
/**
* <code>optional .RogueStatus rogue_status = 9;</code>
* @return this
*/
public RogueArea clearRogueStatus() {
bitField0_ &= ~0x00000010;
rogueStatus = 0;
return this;
}
/**
* <code>optional .RogueStatus rogue_status = 9;</code>
* @return the rogueStatus
*/
public RogueStatusOuterClass.RogueStatus getRogueStatus() {
return RogueStatusOuterClass.RogueStatus.forNumber(rogueStatus);
}
/**
* Gets the value of the internal enum store. The result is
* equivalent to {@link RogueArea#getRogueStatus()}.getNumber().
*
* @return numeric wire representation
*/
public int getRogueStatusValue() {
return rogueStatus;
}
/**
* Sets the value of the internal enum store. This does not
* do any validity checks, so be sure to use appropriate value
* constants from {@link RogueStatusOuterClass.RogueStatus}. Setting an invalid value
* can cause {@link RogueArea#getRogueStatus()} to return null
*
* @param value the numeric wire value to set
* @return this
*/
public RogueArea setRogueStatusValue(final int value) {
bitField0_ |= 0x00000010;
rogueStatus = value;
return this;
}
/**
* <code>optional .RogueStatus rogue_status = 9;</code>
* @param value the rogueStatus to set
* @return this
*/
public RogueArea setRogueStatus(final RogueStatusOuterClass.RogueStatus value) {
bitField0_ |= 0x00000010;
rogueStatus = value.getNumber();
return this;
}
/**
* <code>optional bool is_reward_taken = 7;</code>
* @return whether the isRewardTaken field is set
*/
public boolean hasIsRewardTaken() {
return (bitField0_ & 0x00000020) != 0;
}
/**
* <code>optional bool is_reward_taken = 7;</code>
* @return this
*/
public RogueArea clearIsRewardTaken() {
bitField0_ &= ~0x00000020;
isRewardTaken = false;
return this;
}
/**
* <code>optional bool is_reward_taken = 7;</code>
* @return the isRewardTaken
*/
public boolean getIsRewardTaken() {
return isRewardTaken;
}
/**
* <code>optional bool is_reward_taken = 7;</code>
* @param value the isRewardTaken to set
* @return this
*/
public RogueArea setIsRewardTaken(final boolean value) {
bitField0_ |= 0x00000020;
isRewardTaken = value;
return this;
}
@Override
public RogueArea copyFrom(final RogueArea other) {
cachedSize = other.cachedSize;
if ((bitField0_ | other.bitField0_) != 0) {
bitField0_ = other.bitField0_;
areaId = other.areaId;
curReachRoomNum = other.curReachRoomNum;
mapId = other.mapId;
rogueAreaStatus = other.rogueAreaStatus;
rogueStatus = other.rogueStatus;
isRewardTaken = other.isRewardTaken;
}
return this;
}
@Override
public RogueArea mergeFrom(final RogueArea other) {
if (other.isEmpty()) {
return this;
}
cachedSize = -1;
if (other.hasAreaId()) {
setAreaId(other.areaId);
}
if (other.hasCurReachRoomNum()) {
setCurReachRoomNum(other.curReachRoomNum);
}
if (other.hasMapId()) {
setMapId(other.mapId);
}
if (other.hasRogueAreaStatus()) {
setRogueAreaStatusValue(other.rogueAreaStatus);
}
if (other.hasRogueStatus()) {
setRogueStatusValue(other.rogueStatus);
}
if (other.hasIsRewardTaken()) {
setIsRewardTaken(other.isRewardTaken);
}
return this;
}
@Override
public RogueArea clear() {
if (isEmpty()) {
return this;
}
cachedSize = -1;
bitField0_ = 0;
areaId = 0;
curReachRoomNum = 0;
mapId = 0;
rogueAreaStatus = 0;
rogueStatus = 0;
isRewardTaken = false;
return this;
}
@Override
public RogueArea clearQuick() {
if (isEmpty()) {
return this;
}
cachedSize = -1;
bitField0_ = 0;
return this;
}
@Override
public boolean equals(Object o) {
if (o == this) {
return true;
}
if (!(o instanceof RogueArea)) {
return false;
}
RogueArea other = (RogueArea) o;
return bitField0_ == other.bitField0_
&& (!hasAreaId() || areaId == other.areaId)
&& (!hasCurReachRoomNum() || curReachRoomNum == other.curReachRoomNum)
&& (!hasMapId() || mapId == other.mapId)
&& (!hasRogueAreaStatus() || rogueAreaStatus == other.rogueAreaStatus)
&& (!hasRogueStatus() || rogueStatus == other.rogueStatus)
&& (!hasIsRewardTaken() || isRewardTaken == other.isRewardTaken);
}
@Override
public void writeTo(final ProtoSink output) throws IOException {
if ((bitField0_ & 0x00000001) != 0) {
output.writeRawByte((byte) 32);
output.writeUInt32NoTag(areaId);
}
if ((bitField0_ & 0x00000002) != 0) {
output.writeRawByte((byte) 80);
output.writeUInt32NoTag(curReachRoomNum);
}
if ((bitField0_ & 0x00000004) != 0) {
output.writeRawByte((byte) 104);
output.writeUInt32NoTag(mapId);
}
if ((bitField0_ & 0x00000008) != 0) {
output.writeRawByte((byte) 48);
output.writeEnumNoTag(rogueAreaStatus);
}
if ((bitField0_ & 0x00000010) != 0) {
output.writeRawByte((byte) 72);
output.writeEnumNoTag(rogueStatus);
}
if ((bitField0_ & 0x00000020) != 0) {
output.writeRawByte((byte) 56);
output.writeBoolNoTag(isRewardTaken);
}
}
@Override
protected int computeSerializedSize() {
int size = 0;
if ((bitField0_ & 0x00000001) != 0) {
size += 1 + ProtoSink.computeUInt32SizeNoTag(areaId);
}
if ((bitField0_ & 0x00000002) != 0) {
size += 1 + ProtoSink.computeUInt32SizeNoTag(curReachRoomNum);
}
if ((bitField0_ & 0x00000004) != 0) {
size += 1 + ProtoSink.computeUInt32SizeNoTag(mapId);
}
if ((bitField0_ & 0x00000008) != 0) {
size += 1 + ProtoSink.computeEnumSizeNoTag(rogueAreaStatus);
}
if ((bitField0_ & 0x00000010) != 0) {
size += 1 + ProtoSink.computeEnumSizeNoTag(rogueStatus);
}
if ((bitField0_ & 0x00000020) != 0) {
size += 2;
}
return size;
}
@Override
@SuppressWarnings("fallthrough")
public RogueArea mergeFrom(final ProtoSource input) throws IOException {
// Enabled Fall-Through Optimization (QuickBuffers)
int tag = input.readTag();
while (true) {
switch (tag) {
case 32: {
// areaId
areaId = input.readUInt32();
bitField0_ |= 0x00000001;
tag = input.readTag();
if (tag != 80) {
break;
}
}
case 80: {
// curReachRoomNum
curReachRoomNum = input.readUInt32();
bitField0_ |= 0x00000002;
tag = input.readTag();
if (tag != 104) {
break;
}
}
case 104: {
// mapId
mapId = input.readUInt32();
bitField0_ |= 0x00000004;
tag = input.readTag();
if (tag != 48) {
break;
}
}
case 48: {
// rogueAreaStatus
final int value = input.readInt32();
if (RogueAreaStatusOuterClass.RogueAreaStatus.forNumber(value) != null) {
rogueAreaStatus = value;
bitField0_ |= 0x00000008;
}
tag = input.readTag();
if (tag != 72) {
break;
}
}
case 72: {
// rogueStatus
final int value = input.readInt32();
if (RogueStatusOuterClass.RogueStatus.forNumber(value) != null) {
rogueStatus = value;
bitField0_ |= 0x00000010;
}
tag = input.readTag();
if (tag != 56) {
break;
}
}
case 56: {
// isRewardTaken
isRewardTaken = input.readBool();
bitField0_ |= 0x00000020;
tag = input.readTag();
if (tag != 0) {
break;
}
}
case 0: {
return this;
}
default: {
if (!input.skipField(tag)) {
return this;
}
tag = input.readTag();
break;
}
}
}
}
@Override
public void writeTo(final JsonSink output) throws IOException {
output.beginObject();
if ((bitField0_ & 0x00000001) != 0) {
output.writeUInt32(FieldNames.areaId, areaId);
}
if ((bitField0_ & 0x00000002) != 0) {
output.writeUInt32(FieldNames.curReachRoomNum, curReachRoomNum);
}
if ((bitField0_ & 0x00000004) != 0) {
output.writeUInt32(FieldNames.mapId, mapId);
}
if ((bitField0_ & 0x00000008) != 0) {
output.writeEnum(FieldNames.rogueAreaStatus, rogueAreaStatus, RogueAreaStatusOuterClass.RogueAreaStatus.converter());
}
if ((bitField0_ & 0x00000010) != 0) {
output.writeEnum(FieldNames.rogueStatus, rogueStatus, RogueStatusOuterClass.RogueStatus.converter());
}
if ((bitField0_ & 0x00000020) != 0) {
output.writeBool(FieldNames.isRewardTaken, isRewardTaken);
}
output.endObject();
}
@Override
public RogueArea mergeFrom(final JsonSource input) throws IOException {
if (!input.beginObject()) {
return this;
}
while (!input.isAtEnd()) {
switch (input.readFieldHash()) {
case -1409553784:
case -746472947: {
if (input.isAtField(FieldNames.areaId)) {
if (!input.trySkipNullValue()) {
areaId = input.readUInt32();
bitField0_ |= 0x00000001;
}
} else {
input.skipUnknownField();
}
break;
}
case 888045080:
case 328196941: {
if (input.isAtField(FieldNames.curReachRoomNum)) {
if (!input.trySkipNullValue()) {
curReachRoomNum = input.readUInt32();
bitField0_ |= 0x00000002;
}
} else {
input.skipUnknownField();
}
break;
}
case 103663511:
case -1081377058: {
if (input.isAtField(FieldNames.mapId)) {
if (!input.trySkipNullValue()) {
mapId = input.readUInt32();
bitField0_ |= 0x00000004;
}
} else {
input.skipUnknownField();
}
break;
}
case -731414439:
case -1961715457: {
if (input.isAtField(FieldNames.rogueAreaStatus)) {
if (!input.trySkipNullValue()) {
final RogueAreaStatusOuterClass.RogueAreaStatus value = input.readEnum(RogueAreaStatusOuterClass.RogueAreaStatus.converter());
if (value != null) {
rogueAreaStatus = value.getNumber();
bitField0_ |= 0x00000008;
} else {
input.skipUnknownEnumValue();
}
}
} else {
input.skipUnknownField();
}
break;
}
case -836112788:
case 1898767863: {
if (input.isAtField(FieldNames.rogueStatus)) {
if (!input.trySkipNullValue()) {
final RogueStatusOuterClass.RogueStatus value = input.readEnum(RogueStatusOuterClass.RogueStatus.converter());
if (value != null) {
rogueStatus = value.getNumber();
bitField0_ |= 0x00000010;
} else {
input.skipUnknownEnumValue();
}
}
} else {
input.skipUnknownField();
}
break;
}
case -522199218:
case 1351172268: {
if (input.isAtField(FieldNames.isRewardTaken)) {
if (!input.trySkipNullValue()) {
isRewardTaken = input.readBool();
bitField0_ |= 0x00000020;
}
} else {
input.skipUnknownField();
}
break;
}
default: {
input.skipUnknownField();
break;
}
}
}
input.endObject();
return this;
}
@Override
public RogueArea clone() {
return new RogueArea().copyFrom(this);
}
@Override
public boolean isEmpty() {
return ((bitField0_) == 0);
}
public static RogueArea parseFrom(final byte[] data) throws InvalidProtocolBufferException {
return ProtoMessage.mergeFrom(new RogueArea(), data).checkInitialized();
}
public static RogueArea parseFrom(final ProtoSource input) throws IOException {
return ProtoMessage.mergeFrom(new RogueArea(), input).checkInitialized();
}
public static RogueArea parseFrom(final JsonSource input) throws IOException {
return ProtoMessage.mergeFrom(new RogueArea(), input).checkInitialized();
}
/**
* @return factory for creating RogueArea messages
*/
public static MessageFactory<RogueArea> getFactory() {
return RogueAreaFactory.INSTANCE;
}
private enum RogueAreaFactory implements MessageFactory<RogueArea> {
INSTANCE;
@Override
public RogueArea create() {
return RogueArea.newInstance();
}
}
/**
* Contains name constants used for serializing JSON
*/
static class FieldNames {
static final FieldName areaId = FieldName.forField("areaId", "area_id");
static final FieldName curReachRoomNum = FieldName.forField("curReachRoomNum", "cur_reach_room_num");
static final FieldName mapId = FieldName.forField("mapId", "map_id");
static final FieldName rogueAreaStatus = FieldName.forField("rogueAreaStatus", "rogue_area_status");
static final FieldName rogueStatus = FieldName.forField("rogueStatus", "rogue_status");
static final FieldName isRewardTaken = FieldName.forField("isRewardTaken", "is_reward_taken");
}
}
}

View File

@@ -0,0 +1,154 @@
// Code generated by protocol buffer compiler. Do not edit!
package emu.lunarcore.proto;
import us.hebi.quickbuf.ProtoEnum;
import us.hebi.quickbuf.ProtoUtil;
public final class RogueAreaStatusOuterClass {
/**
* Protobuf enum {@code RogueAreaStatus}
*/
public enum RogueAreaStatus implements ProtoEnum<RogueAreaStatus> {
/**
* <code>ROGUE_AREA_STATUS_LOCK = 0;</code>
*/
ROGUE_AREA_STATUS_LOCK("ROGUE_AREA_STATUS_LOCK", 0),
/**
* <code>ROGUE_AREA_STATUS_UNLOCK = 1;</code>
*/
ROGUE_AREA_STATUS_UNLOCK("ROGUE_AREA_STATUS_UNLOCK", 1),
/**
* <code>ROGUE_AREA_STATUS_FIRST_PASS = 2;</code>
*/
ROGUE_AREA_STATUS_FIRST_PASS("ROGUE_AREA_STATUS_FIRST_PASS", 2),
/**
* <code>ROGUE_AREA_STATUS_CLOSE = 3;</code>
*/
ROGUE_AREA_STATUS_CLOSE("ROGUE_AREA_STATUS_CLOSE", 3);
/**
* <code>ROGUE_AREA_STATUS_LOCK = 0;</code>
*/
public static final int ROGUE_AREA_STATUS_LOCK_VALUE = 0;
/**
* <code>ROGUE_AREA_STATUS_UNLOCK = 1;</code>
*/
public static final int ROGUE_AREA_STATUS_UNLOCK_VALUE = 1;
/**
* <code>ROGUE_AREA_STATUS_FIRST_PASS = 2;</code>
*/
public static final int ROGUE_AREA_STATUS_FIRST_PASS_VALUE = 2;
/**
* <code>ROGUE_AREA_STATUS_CLOSE = 3;</code>
*/
public static final int ROGUE_AREA_STATUS_CLOSE_VALUE = 3;
private final String name;
private final int number;
private RogueAreaStatus(String name, int number) {
this.name = name;
this.number = number;
}
/**
* @return the string representation of enum entry
*/
@Override
public String getName() {
return name;
}
/**
* @return the numeric wire value of this enum entry
*/
@Override
public int getNumber() {
return number;
}
/**
* @return a converter that maps between this enum's numeric and text representations
*/
public static ProtoEnum.EnumConverter<RogueAreaStatus> converter() {
return RogueAreaStatusConverter.INSTANCE;
}
/**
* @param value The numeric wire value of the corresponding enum entry.
* @return The enum associated with the given numeric wire value, or null if unknown.
*/
public static RogueAreaStatus forNumber(int value) {
return RogueAreaStatusConverter.INSTANCE.forNumber(value);
}
/**
* @param value The numeric wire value of the corresponding enum entry.
* @param other Fallback value in case the value is not known.
* @return The enum associated with the given numeric wire value, or the fallback value if unknown.
*/
public static RogueAreaStatus forNumberOr(int number, RogueAreaStatus other) {
RogueAreaStatus value = forNumber(number);
return value == null ? other : value;
}
enum RogueAreaStatusConverter implements ProtoEnum.EnumConverter<RogueAreaStatus> {
INSTANCE;
private static final RogueAreaStatus[] lookup = new RogueAreaStatus[4];
static {
lookup[0] = ROGUE_AREA_STATUS_LOCK;
lookup[1] = ROGUE_AREA_STATUS_UNLOCK;
lookup[2] = ROGUE_AREA_STATUS_FIRST_PASS;
lookup[3] = ROGUE_AREA_STATUS_CLOSE;
}
@Override
public final RogueAreaStatus forNumber(final int value) {
if (value >= 0 && value < lookup.length) {
return lookup[value];
}
return null;
}
@Override
public final RogueAreaStatus forName(final CharSequence value) {
switch (value.length()) {
case 22: {
if (ProtoUtil.isEqual("ROGUE_AREA_STATUS_LOCK", value)) {
return ROGUE_AREA_STATUS_LOCK;
}
break;
}
case 23: {
if (ProtoUtil.isEqual("ROGUE_AREA_STATUS_CLOSE", value)) {
return ROGUE_AREA_STATUS_CLOSE;
}
break;
}
case 24: {
if (ProtoUtil.isEqual("ROGUE_AREA_STATUS_UNLOCK", value)) {
return ROGUE_AREA_STATUS_UNLOCK;
}
break;
}
case 28: {
if (ProtoUtil.isEqual("ROGUE_AREA_STATUS_FIRST_PASS", value)) {
return ROGUE_AREA_STATUS_FIRST_PASS;
}
break;
}
}
return null;
}
}
}
}

View File

@@ -0,0 +1,341 @@
// Code generated by protocol buffer compiler. Do not edit!
package emu.lunarcore.proto;
import java.io.IOException;
import us.hebi.quickbuf.FieldName;
import us.hebi.quickbuf.InvalidProtocolBufferException;
import us.hebi.quickbuf.JsonSink;
import us.hebi.quickbuf.JsonSource;
import us.hebi.quickbuf.MessageFactory;
import us.hebi.quickbuf.ProtoMessage;
import us.hebi.quickbuf.ProtoSink;
import us.hebi.quickbuf.ProtoSource;
public final class RogueHandbookDataOuterClass {
/**
* Protobuf type {@code RogueHandbookData}
*/
public static final class RogueHandbookData extends ProtoMessage<RogueHandbookData> implements Cloneable {
private static final long serialVersionUID = 0L;
/**
* <code>optional uint32 rogue_current_version = 6;</code>
*/
private int rogueCurrentVersion;
/**
* <code>optional bool is_miracle_unlock = 12;</code>
*/
private boolean isMiracleUnlock;
private RogueHandbookData() {
}
/**
* @return a new empty instance of {@code RogueHandbookData}
*/
public static RogueHandbookData newInstance() {
return new RogueHandbookData();
}
/**
* <code>optional uint32 rogue_current_version = 6;</code>
* @return whether the rogueCurrentVersion field is set
*/
public boolean hasRogueCurrentVersion() {
return (bitField0_ & 0x00000001) != 0;
}
/**
* <code>optional uint32 rogue_current_version = 6;</code>
* @return this
*/
public RogueHandbookData clearRogueCurrentVersion() {
bitField0_ &= ~0x00000001;
rogueCurrentVersion = 0;
return this;
}
/**
* <code>optional uint32 rogue_current_version = 6;</code>
* @return the rogueCurrentVersion
*/
public int getRogueCurrentVersion() {
return rogueCurrentVersion;
}
/**
* <code>optional uint32 rogue_current_version = 6;</code>
* @param value the rogueCurrentVersion to set
* @return this
*/
public RogueHandbookData setRogueCurrentVersion(final int value) {
bitField0_ |= 0x00000001;
rogueCurrentVersion = value;
return this;
}
/**
* <code>optional bool is_miracle_unlock = 12;</code>
* @return whether the isMiracleUnlock field is set
*/
public boolean hasIsMiracleUnlock() {
return (bitField0_ & 0x00000002) != 0;
}
/**
* <code>optional bool is_miracle_unlock = 12;</code>
* @return this
*/
public RogueHandbookData clearIsMiracleUnlock() {
bitField0_ &= ~0x00000002;
isMiracleUnlock = false;
return this;
}
/**
* <code>optional bool is_miracle_unlock = 12;</code>
* @return the isMiracleUnlock
*/
public boolean getIsMiracleUnlock() {
return isMiracleUnlock;
}
/**
* <code>optional bool is_miracle_unlock = 12;</code>
* @param value the isMiracleUnlock to set
* @return this
*/
public RogueHandbookData setIsMiracleUnlock(final boolean value) {
bitField0_ |= 0x00000002;
isMiracleUnlock = value;
return this;
}
@Override
public RogueHandbookData copyFrom(final RogueHandbookData other) {
cachedSize = other.cachedSize;
if ((bitField0_ | other.bitField0_) != 0) {
bitField0_ = other.bitField0_;
rogueCurrentVersion = other.rogueCurrentVersion;
isMiracleUnlock = other.isMiracleUnlock;
}
return this;
}
@Override
public RogueHandbookData mergeFrom(final RogueHandbookData other) {
if (other.isEmpty()) {
return this;
}
cachedSize = -1;
if (other.hasRogueCurrentVersion()) {
setRogueCurrentVersion(other.rogueCurrentVersion);
}
if (other.hasIsMiracleUnlock()) {
setIsMiracleUnlock(other.isMiracleUnlock);
}
return this;
}
@Override
public RogueHandbookData clear() {
if (isEmpty()) {
return this;
}
cachedSize = -1;
bitField0_ = 0;
rogueCurrentVersion = 0;
isMiracleUnlock = false;
return this;
}
@Override
public RogueHandbookData clearQuick() {
if (isEmpty()) {
return this;
}
cachedSize = -1;
bitField0_ = 0;
return this;
}
@Override
public boolean equals(Object o) {
if (o == this) {
return true;
}
if (!(o instanceof RogueHandbookData)) {
return false;
}
RogueHandbookData other = (RogueHandbookData) o;
return bitField0_ == other.bitField0_
&& (!hasRogueCurrentVersion() || rogueCurrentVersion == other.rogueCurrentVersion)
&& (!hasIsMiracleUnlock() || isMiracleUnlock == other.isMiracleUnlock);
}
@Override
public void writeTo(final ProtoSink output) throws IOException {
if ((bitField0_ & 0x00000001) != 0) {
output.writeRawByte((byte) 48);
output.writeUInt32NoTag(rogueCurrentVersion);
}
if ((bitField0_ & 0x00000002) != 0) {
output.writeRawByte((byte) 96);
output.writeBoolNoTag(isMiracleUnlock);
}
}
@Override
protected int computeSerializedSize() {
int size = 0;
if ((bitField0_ & 0x00000001) != 0) {
size += 1 + ProtoSink.computeUInt32SizeNoTag(rogueCurrentVersion);
}
if ((bitField0_ & 0x00000002) != 0) {
size += 2;
}
return size;
}
@Override
@SuppressWarnings("fallthrough")
public RogueHandbookData mergeFrom(final ProtoSource input) throws IOException {
// Enabled Fall-Through Optimization (QuickBuffers)
int tag = input.readTag();
while (true) {
switch (tag) {
case 48: {
// rogueCurrentVersion
rogueCurrentVersion = input.readUInt32();
bitField0_ |= 0x00000001;
tag = input.readTag();
if (tag != 96) {
break;
}
}
case 96: {
// isMiracleUnlock
isMiracleUnlock = input.readBool();
bitField0_ |= 0x00000002;
tag = input.readTag();
if (tag != 0) {
break;
}
}
case 0: {
return this;
}
default: {
if (!input.skipField(tag)) {
return this;
}
tag = input.readTag();
break;
}
}
}
}
@Override
public void writeTo(final JsonSink output) throws IOException {
output.beginObject();
if ((bitField0_ & 0x00000001) != 0) {
output.writeUInt32(FieldNames.rogueCurrentVersion, rogueCurrentVersion);
}
if ((bitField0_ & 0x00000002) != 0) {
output.writeBool(FieldNames.isMiracleUnlock, isMiracleUnlock);
}
output.endObject();
}
@Override
public RogueHandbookData mergeFrom(final JsonSource input) throws IOException {
if (!input.beginObject()) {
return this;
}
while (!input.isAtEnd()) {
switch (input.readFieldHash()) {
case 1261212057:
case 1302648749: {
if (input.isAtField(FieldNames.rogueCurrentVersion)) {
if (!input.trySkipNullValue()) {
rogueCurrentVersion = input.readUInt32();
bitField0_ |= 0x00000001;
}
} else {
input.skipUnknownField();
}
break;
}
case -1272353269:
case 167980679: {
if (input.isAtField(FieldNames.isMiracleUnlock)) {
if (!input.trySkipNullValue()) {
isMiracleUnlock = input.readBool();
bitField0_ |= 0x00000002;
}
} else {
input.skipUnknownField();
}
break;
}
default: {
input.skipUnknownField();
break;
}
}
}
input.endObject();
return this;
}
@Override
public RogueHandbookData clone() {
return new RogueHandbookData().copyFrom(this);
}
@Override
public boolean isEmpty() {
return ((bitField0_) == 0);
}
public static RogueHandbookData parseFrom(final byte[] data) throws
InvalidProtocolBufferException {
return ProtoMessage.mergeFrom(new RogueHandbookData(), data).checkInitialized();
}
public static RogueHandbookData parseFrom(final ProtoSource input) throws IOException {
return ProtoMessage.mergeFrom(new RogueHandbookData(), input).checkInitialized();
}
public static RogueHandbookData parseFrom(final JsonSource input) throws IOException {
return ProtoMessage.mergeFrom(new RogueHandbookData(), input).checkInitialized();
}
/**
* @return factory for creating RogueHandbookData messages
*/
public static MessageFactory<RogueHandbookData> getFactory() {
return RogueHandbookDataFactory.INSTANCE;
}
private enum RogueHandbookDataFactory implements MessageFactory<RogueHandbookData> {
INSTANCE;
@Override
public RogueHandbookData create() {
return RogueHandbookData.newInstance();
}
}
/**
* Contains name constants used for serializing JSON
*/
static class FieldNames {
static final FieldName rogueCurrentVersion = FieldName.forField("rogueCurrentVersion", "rogue_current_version");
static final FieldName isMiracleUnlock = FieldName.forField("isMiracleUnlock", "is_miracle_unlock");
}
}
}

View File

@@ -0,0 +1,383 @@
// Code generated by protocol buffer compiler. Do not edit!
package emu.lunarcore.proto;
import java.io.IOException;
import us.hebi.quickbuf.FieldName;
import us.hebi.quickbuf.InvalidProtocolBufferException;
import us.hebi.quickbuf.JsonSink;
import us.hebi.quickbuf.JsonSource;
import us.hebi.quickbuf.MessageFactory;
import us.hebi.quickbuf.ProtoMessage;
import us.hebi.quickbuf.ProtoSink;
import us.hebi.quickbuf.ProtoSource;
public final class RogueInfoDataOuterClass {
/**
* Protobuf type {@code RogueInfoData}
*/
public static final class RogueInfoData extends ProtoMessage<RogueInfoData> implements Cloneable {
private static final long serialVersionUID = 0L;
/**
* <code>optional .RogueSeasonInfo rogue_season_info = 3;</code>
*/
private final RogueSeasonInfoOuterClass.RogueSeasonInfo rogueSeasonInfo = RogueSeasonInfoOuterClass.RogueSeasonInfo.newInstance();
/**
* <code>optional .RogueScoreRewardInfo rogue_score_info = 6;</code>
*/
private final RogueScoreRewardInfoOuterClass.RogueScoreRewardInfo rogueScoreInfo = RogueScoreRewardInfoOuterClass.RogueScoreRewardInfo.newInstance();
private RogueInfoData() {
}
/**
* @return a new empty instance of {@code RogueInfoData}
*/
public static RogueInfoData newInstance() {
return new RogueInfoData();
}
/**
* <code>optional .RogueSeasonInfo rogue_season_info = 3;</code>
* @return whether the rogueSeasonInfo field is set
*/
public boolean hasRogueSeasonInfo() {
return (bitField0_ & 0x00000001) != 0;
}
/**
* <code>optional .RogueSeasonInfo rogue_season_info = 3;</code>
* @return this
*/
public RogueInfoData clearRogueSeasonInfo() {
bitField0_ &= ~0x00000001;
rogueSeasonInfo.clear();
return this;
}
/**
* <code>optional .RogueSeasonInfo rogue_season_info = 3;</code>
*
* This method returns the internal storage object without modifying any has state.
* The returned object should not be modified and be treated as read-only.
*
* Use {@link #getMutableRogueSeasonInfo()} if you want to modify it.
*
* @return internal storage object for reading
*/
public RogueSeasonInfoOuterClass.RogueSeasonInfo getRogueSeasonInfo() {
return rogueSeasonInfo;
}
/**
* <code>optional .RogueSeasonInfo rogue_season_info = 3;</code>
*
* This method returns the internal storage object and sets the corresponding
* has state. The returned object will become part of this message and its
* contents may be modified as long as the has state is not cleared.
*
* @return internal storage object for modifications
*/
public RogueSeasonInfoOuterClass.RogueSeasonInfo getMutableRogueSeasonInfo() {
bitField0_ |= 0x00000001;
return rogueSeasonInfo;
}
/**
* <code>optional .RogueSeasonInfo rogue_season_info = 3;</code>
* @param value the rogueSeasonInfo to set
* @return this
*/
public RogueInfoData setRogueSeasonInfo(final RogueSeasonInfoOuterClass.RogueSeasonInfo value) {
bitField0_ |= 0x00000001;
rogueSeasonInfo.copyFrom(value);
return this;
}
/**
* <code>optional .RogueScoreRewardInfo rogue_score_info = 6;</code>
* @return whether the rogueScoreInfo field is set
*/
public boolean hasRogueScoreInfo() {
return (bitField0_ & 0x00000002) != 0;
}
/**
* <code>optional .RogueScoreRewardInfo rogue_score_info = 6;</code>
* @return this
*/
public RogueInfoData clearRogueScoreInfo() {
bitField0_ &= ~0x00000002;
rogueScoreInfo.clear();
return this;
}
/**
* <code>optional .RogueScoreRewardInfo rogue_score_info = 6;</code>
*
* This method returns the internal storage object without modifying any has state.
* The returned object should not be modified and be treated as read-only.
*
* Use {@link #getMutableRogueScoreInfo()} if you want to modify it.
*
* @return internal storage object for reading
*/
public RogueScoreRewardInfoOuterClass.RogueScoreRewardInfo getRogueScoreInfo() {
return rogueScoreInfo;
}
/**
* <code>optional .RogueScoreRewardInfo rogue_score_info = 6;</code>
*
* This method returns the internal storage object and sets the corresponding
* has state. The returned object will become part of this message and its
* contents may be modified as long as the has state is not cleared.
*
* @return internal storage object for modifications
*/
public RogueScoreRewardInfoOuterClass.RogueScoreRewardInfo getMutableRogueScoreInfo() {
bitField0_ |= 0x00000002;
return rogueScoreInfo;
}
/**
* <code>optional .RogueScoreRewardInfo rogue_score_info = 6;</code>
* @param value the rogueScoreInfo to set
* @return this
*/
public RogueInfoData setRogueScoreInfo(
final RogueScoreRewardInfoOuterClass.RogueScoreRewardInfo value) {
bitField0_ |= 0x00000002;
rogueScoreInfo.copyFrom(value);
return this;
}
@Override
public RogueInfoData copyFrom(final RogueInfoData other) {
cachedSize = other.cachedSize;
if ((bitField0_ | other.bitField0_) != 0) {
bitField0_ = other.bitField0_;
rogueSeasonInfo.copyFrom(other.rogueSeasonInfo);
rogueScoreInfo.copyFrom(other.rogueScoreInfo);
}
return this;
}
@Override
public RogueInfoData mergeFrom(final RogueInfoData other) {
if (other.isEmpty()) {
return this;
}
cachedSize = -1;
if (other.hasRogueSeasonInfo()) {
getMutableRogueSeasonInfo().mergeFrom(other.rogueSeasonInfo);
}
if (other.hasRogueScoreInfo()) {
getMutableRogueScoreInfo().mergeFrom(other.rogueScoreInfo);
}
return this;
}
@Override
public RogueInfoData clear() {
if (isEmpty()) {
return this;
}
cachedSize = -1;
bitField0_ = 0;
rogueSeasonInfo.clear();
rogueScoreInfo.clear();
return this;
}
@Override
public RogueInfoData clearQuick() {
if (isEmpty()) {
return this;
}
cachedSize = -1;
bitField0_ = 0;
rogueSeasonInfo.clearQuick();
rogueScoreInfo.clearQuick();
return this;
}
@Override
public boolean equals(Object o) {
if (o == this) {
return true;
}
if (!(o instanceof RogueInfoData)) {
return false;
}
RogueInfoData other = (RogueInfoData) o;
return bitField0_ == other.bitField0_
&& (!hasRogueSeasonInfo() || rogueSeasonInfo.equals(other.rogueSeasonInfo))
&& (!hasRogueScoreInfo() || rogueScoreInfo.equals(other.rogueScoreInfo));
}
@Override
public void writeTo(final ProtoSink output) throws IOException {
if ((bitField0_ & 0x00000001) != 0) {
output.writeRawByte((byte) 26);
output.writeMessageNoTag(rogueSeasonInfo);
}
if ((bitField0_ & 0x00000002) != 0) {
output.writeRawByte((byte) 50);
output.writeMessageNoTag(rogueScoreInfo);
}
}
@Override
protected int computeSerializedSize() {
int size = 0;
if ((bitField0_ & 0x00000001) != 0) {
size += 1 + ProtoSink.computeMessageSizeNoTag(rogueSeasonInfo);
}
if ((bitField0_ & 0x00000002) != 0) {
size += 1 + ProtoSink.computeMessageSizeNoTag(rogueScoreInfo);
}
return size;
}
@Override
@SuppressWarnings("fallthrough")
public RogueInfoData mergeFrom(final ProtoSource input) throws IOException {
// Enabled Fall-Through Optimization (QuickBuffers)
int tag = input.readTag();
while (true) {
switch (tag) {
case 26: {
// rogueSeasonInfo
input.readMessage(rogueSeasonInfo);
bitField0_ |= 0x00000001;
tag = input.readTag();
if (tag != 50) {
break;
}
}
case 50: {
// rogueScoreInfo
input.readMessage(rogueScoreInfo);
bitField0_ |= 0x00000002;
tag = input.readTag();
if (tag != 0) {
break;
}
}
case 0: {
return this;
}
default: {
if (!input.skipField(tag)) {
return this;
}
tag = input.readTag();
break;
}
}
}
}
@Override
public void writeTo(final JsonSink output) throws IOException {
output.beginObject();
if ((bitField0_ & 0x00000001) != 0) {
output.writeMessage(FieldNames.rogueSeasonInfo, rogueSeasonInfo);
}
if ((bitField0_ & 0x00000002) != 0) {
output.writeMessage(FieldNames.rogueScoreInfo, rogueScoreInfo);
}
output.endObject();
}
@Override
public RogueInfoData mergeFrom(final JsonSource input) throws IOException {
if (!input.beginObject()) {
return this;
}
while (!input.isAtEnd()) {
switch (input.readFieldHash()) {
case -1037341781:
case -588845659: {
if (input.isAtField(FieldNames.rogueSeasonInfo)) {
if (!input.trySkipNullValue()) {
input.readMessage(rogueSeasonInfo);
bitField0_ |= 0x00000001;
}
} else {
input.skipUnknownField();
}
break;
}
case 2078217638:
case -208816704: {
if (input.isAtField(FieldNames.rogueScoreInfo)) {
if (!input.trySkipNullValue()) {
input.readMessage(rogueScoreInfo);
bitField0_ |= 0x00000002;
}
} else {
input.skipUnknownField();
}
break;
}
default: {
input.skipUnknownField();
break;
}
}
}
input.endObject();
return this;
}
@Override
public RogueInfoData clone() {
return new RogueInfoData().copyFrom(this);
}
@Override
public boolean isEmpty() {
return ((bitField0_) == 0);
}
public static RogueInfoData parseFrom(final byte[] data) throws InvalidProtocolBufferException {
return ProtoMessage.mergeFrom(new RogueInfoData(), data).checkInitialized();
}
public static RogueInfoData parseFrom(final ProtoSource input) throws IOException {
return ProtoMessage.mergeFrom(new RogueInfoData(), input).checkInitialized();
}
public static RogueInfoData parseFrom(final JsonSource input) throws IOException {
return ProtoMessage.mergeFrom(new RogueInfoData(), input).checkInitialized();
}
/**
* @return factory for creating RogueInfoData messages
*/
public static MessageFactory<RogueInfoData> getFactory() {
return RogueInfoDataFactory.INSTANCE;
}
private enum RogueInfoDataFactory implements MessageFactory<RogueInfoData> {
INSTANCE;
@Override
public RogueInfoData create() {
return RogueInfoData.newInstance();
}
}
/**
* Contains name constants used for serializing JSON
*/
static class FieldNames {
static final FieldName rogueSeasonInfo = FieldName.forField("rogueSeasonInfo", "rogue_season_info");
static final FieldName rogueScoreInfo = FieldName.forField("rogueScoreInfo", "rogue_score_info");
}
}
}

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,422 @@
// Code generated by protocol buffer compiler. Do not edit!
package emu.lunarcore.proto;
import java.io.IOException;
import us.hebi.quickbuf.FieldName;
import us.hebi.quickbuf.InvalidProtocolBufferException;
import us.hebi.quickbuf.JsonSink;
import us.hebi.quickbuf.JsonSource;
import us.hebi.quickbuf.MessageFactory;
import us.hebi.quickbuf.ProtoMessage;
import us.hebi.quickbuf.ProtoSink;
import us.hebi.quickbuf.ProtoSource;
public final class RogueSeasonInfoOuterClass {
/**
* Protobuf type {@code RogueSeasonInfo}
*/
public static final class RogueSeasonInfo extends ProtoMessage<RogueSeasonInfo> implements Cloneable {
private static final long serialVersionUID = 0L;
/**
* <code>optional int64 end_time = 3;</code>
*/
private long endTime;
/**
* <code>optional int64 begin_time = 10;</code>
*/
private long beginTime;
/**
* <code>optional uint32 rogue_season_id = 7;</code>
*/
private int rogueSeasonId;
private RogueSeasonInfo() {
}
/**
* @return a new empty instance of {@code RogueSeasonInfo}
*/
public static RogueSeasonInfo newInstance() {
return new RogueSeasonInfo();
}
/**
* <code>optional int64 end_time = 3;</code>
* @return whether the endTime field is set
*/
public boolean hasEndTime() {
return (bitField0_ & 0x00000001) != 0;
}
/**
* <code>optional int64 end_time = 3;</code>
* @return this
*/
public RogueSeasonInfo clearEndTime() {
bitField0_ &= ~0x00000001;
endTime = 0L;
return this;
}
/**
* <code>optional int64 end_time = 3;</code>
* @return the endTime
*/
public long getEndTime() {
return endTime;
}
/**
* <code>optional int64 end_time = 3;</code>
* @param value the endTime to set
* @return this
*/
public RogueSeasonInfo setEndTime(final long value) {
bitField0_ |= 0x00000001;
endTime = value;
return this;
}
/**
* <code>optional int64 begin_time = 10;</code>
* @return whether the beginTime field is set
*/
public boolean hasBeginTime() {
return (bitField0_ & 0x00000002) != 0;
}
/**
* <code>optional int64 begin_time = 10;</code>
* @return this
*/
public RogueSeasonInfo clearBeginTime() {
bitField0_ &= ~0x00000002;
beginTime = 0L;
return this;
}
/**
* <code>optional int64 begin_time = 10;</code>
* @return the beginTime
*/
public long getBeginTime() {
return beginTime;
}
/**
* <code>optional int64 begin_time = 10;</code>
* @param value the beginTime to set
* @return this
*/
public RogueSeasonInfo setBeginTime(final long value) {
bitField0_ |= 0x00000002;
beginTime = value;
return this;
}
/**
* <code>optional uint32 rogue_season_id = 7;</code>
* @return whether the rogueSeasonId field is set
*/
public boolean hasRogueSeasonId() {
return (bitField0_ & 0x00000004) != 0;
}
/**
* <code>optional uint32 rogue_season_id = 7;</code>
* @return this
*/
public RogueSeasonInfo clearRogueSeasonId() {
bitField0_ &= ~0x00000004;
rogueSeasonId = 0;
return this;
}
/**
* <code>optional uint32 rogue_season_id = 7;</code>
* @return the rogueSeasonId
*/
public int getRogueSeasonId() {
return rogueSeasonId;
}
/**
* <code>optional uint32 rogue_season_id = 7;</code>
* @param value the rogueSeasonId to set
* @return this
*/
public RogueSeasonInfo setRogueSeasonId(final int value) {
bitField0_ |= 0x00000004;
rogueSeasonId = value;
return this;
}
@Override
public RogueSeasonInfo copyFrom(final RogueSeasonInfo other) {
cachedSize = other.cachedSize;
if ((bitField0_ | other.bitField0_) != 0) {
bitField0_ = other.bitField0_;
endTime = other.endTime;
beginTime = other.beginTime;
rogueSeasonId = other.rogueSeasonId;
}
return this;
}
@Override
public RogueSeasonInfo mergeFrom(final RogueSeasonInfo other) {
if (other.isEmpty()) {
return this;
}
cachedSize = -1;
if (other.hasEndTime()) {
setEndTime(other.endTime);
}
if (other.hasBeginTime()) {
setBeginTime(other.beginTime);
}
if (other.hasRogueSeasonId()) {
setRogueSeasonId(other.rogueSeasonId);
}
return this;
}
@Override
public RogueSeasonInfo clear() {
if (isEmpty()) {
return this;
}
cachedSize = -1;
bitField0_ = 0;
endTime = 0L;
beginTime = 0L;
rogueSeasonId = 0;
return this;
}
@Override
public RogueSeasonInfo clearQuick() {
if (isEmpty()) {
return this;
}
cachedSize = -1;
bitField0_ = 0;
return this;
}
@Override
public boolean equals(Object o) {
if (o == this) {
return true;
}
if (!(o instanceof RogueSeasonInfo)) {
return false;
}
RogueSeasonInfo other = (RogueSeasonInfo) o;
return bitField0_ == other.bitField0_
&& (!hasEndTime() || endTime == other.endTime)
&& (!hasBeginTime() || beginTime == other.beginTime)
&& (!hasRogueSeasonId() || rogueSeasonId == other.rogueSeasonId);
}
@Override
public void writeTo(final ProtoSink output) throws IOException {
if ((bitField0_ & 0x00000001) != 0) {
output.writeRawByte((byte) 24);
output.writeInt64NoTag(endTime);
}
if ((bitField0_ & 0x00000002) != 0) {
output.writeRawByte((byte) 80);
output.writeInt64NoTag(beginTime);
}
if ((bitField0_ & 0x00000004) != 0) {
output.writeRawByte((byte) 56);
output.writeUInt32NoTag(rogueSeasonId);
}
}
@Override
protected int computeSerializedSize() {
int size = 0;
if ((bitField0_ & 0x00000001) != 0) {
size += 1 + ProtoSink.computeInt64SizeNoTag(endTime);
}
if ((bitField0_ & 0x00000002) != 0) {
size += 1 + ProtoSink.computeInt64SizeNoTag(beginTime);
}
if ((bitField0_ & 0x00000004) != 0) {
size += 1 + ProtoSink.computeUInt32SizeNoTag(rogueSeasonId);
}
return size;
}
@Override
@SuppressWarnings("fallthrough")
public RogueSeasonInfo mergeFrom(final ProtoSource input) throws IOException {
// Enabled Fall-Through Optimization (QuickBuffers)
int tag = input.readTag();
while (true) {
switch (tag) {
case 24: {
// endTime
endTime = input.readInt64();
bitField0_ |= 0x00000001;
tag = input.readTag();
if (tag != 80) {
break;
}
}
case 80: {
// beginTime
beginTime = input.readInt64();
bitField0_ |= 0x00000002;
tag = input.readTag();
if (tag != 56) {
break;
}
}
case 56: {
// rogueSeasonId
rogueSeasonId = input.readUInt32();
bitField0_ |= 0x00000004;
tag = input.readTag();
if (tag != 0) {
break;
}
}
case 0: {
return this;
}
default: {
if (!input.skipField(tag)) {
return this;
}
tag = input.readTag();
break;
}
}
}
}
@Override
public void writeTo(final JsonSink output) throws IOException {
output.beginObject();
if ((bitField0_ & 0x00000001) != 0) {
output.writeInt64(FieldNames.endTime, endTime);
}
if ((bitField0_ & 0x00000002) != 0) {
output.writeInt64(FieldNames.beginTime, beginTime);
}
if ((bitField0_ & 0x00000004) != 0) {
output.writeUInt32(FieldNames.rogueSeasonId, rogueSeasonId);
}
output.endObject();
}
@Override
public RogueSeasonInfo mergeFrom(final JsonSource input) throws IOException {
if (!input.beginObject()) {
return this;
}
while (!input.isAtEnd()) {
switch (input.readFieldHash()) {
case -1607243192:
case 1725551537: {
if (input.isAtField(FieldNames.endTime)) {
if (!input.trySkipNullValue()) {
endTime = input.readInt64();
bitField0_ |= 0x00000001;
}
} else {
input.skipUnknownField();
}
break;
}
case -1072839914:
case 1112183971: {
if (input.isAtField(FieldNames.beginTime)) {
if (!input.trySkipNullValue()) {
beginTime = input.readInt64();
bitField0_ |= 0x00000002;
}
} else {
input.skipUnknownField();
}
break;
}
case -774262952:
case 1067542482: {
if (input.isAtField(FieldNames.rogueSeasonId)) {
if (!input.trySkipNullValue()) {
rogueSeasonId = input.readUInt32();
bitField0_ |= 0x00000004;
}
} else {
input.skipUnknownField();
}
break;
}
default: {
input.skipUnknownField();
break;
}
}
}
input.endObject();
return this;
}
@Override
public RogueSeasonInfo clone() {
return new RogueSeasonInfo().copyFrom(this);
}
@Override
public boolean isEmpty() {
return ((bitField0_) == 0);
}
public static RogueSeasonInfo parseFrom(final byte[] data) throws
InvalidProtocolBufferException {
return ProtoMessage.mergeFrom(new RogueSeasonInfo(), data).checkInitialized();
}
public static RogueSeasonInfo parseFrom(final ProtoSource input) throws IOException {
return ProtoMessage.mergeFrom(new RogueSeasonInfo(), input).checkInitialized();
}
public static RogueSeasonInfo parseFrom(final JsonSource input) throws IOException {
return ProtoMessage.mergeFrom(new RogueSeasonInfo(), input).checkInitialized();
}
/**
* @return factory for creating RogueSeasonInfo messages
*/
public static MessageFactory<RogueSeasonInfo> getFactory() {
return RogueSeasonInfoFactory.INSTANCE;
}
private enum RogueSeasonInfoFactory implements MessageFactory<RogueSeasonInfo> {
INSTANCE;
@Override
public RogueSeasonInfo create() {
return RogueSeasonInfo.newInstance();
}
}
/**
* Contains name constants used for serializing JSON
*/
static class FieldNames {
static final FieldName endTime = FieldName.forField("endTime", "end_time");
static final FieldName beginTime = FieldName.forField("beginTime", "begin_time");
static final FieldName rogueSeasonId = FieldName.forField("rogueSeasonId", "rogue_season_id");
}
}
}

View File

@@ -0,0 +1,168 @@
// Code generated by protocol buffer compiler. Do not edit!
package emu.lunarcore.proto;
import us.hebi.quickbuf.ProtoEnum;
import us.hebi.quickbuf.ProtoUtil;
public final class RogueStatusOuterClass {
/**
* Protobuf enum {@code RogueStatus}
*/
public enum RogueStatus implements ProtoEnum<RogueStatus> {
/**
* <code>ROGUE_STATUS_NONE = 0;</code>
*/
ROGUE_STATUS_NONE("ROGUE_STATUS_NONE", 0),
/**
* <code>ROGUE_STATUS_DOING = 1;</code>
*/
ROGUE_STATUS_DOING("ROGUE_STATUS_DOING", 1),
/**
* <code>ROGUE_STATUS_PENDING = 2;</code>
*/
ROGUE_STATUS_PENDING("ROGUE_STATUS_PENDING", 2),
/**
* <code>ROGUE_STATUS_ENDLESS = 3;</code>
*/
ROGUE_STATUS_ENDLESS("ROGUE_STATUS_ENDLESS", 3),
/**
* <code>ROGUE_STATUS_FINISH = 4;</code>
*/
ROGUE_STATUS_FINISH("ROGUE_STATUS_FINISH", 4);
/**
* <code>ROGUE_STATUS_NONE = 0;</code>
*/
public static final int ROGUE_STATUS_NONE_VALUE = 0;
/**
* <code>ROGUE_STATUS_DOING = 1;</code>
*/
public static final int ROGUE_STATUS_DOING_VALUE = 1;
/**
* <code>ROGUE_STATUS_PENDING = 2;</code>
*/
public static final int ROGUE_STATUS_PENDING_VALUE = 2;
/**
* <code>ROGUE_STATUS_ENDLESS = 3;</code>
*/
public static final int ROGUE_STATUS_ENDLESS_VALUE = 3;
/**
* <code>ROGUE_STATUS_FINISH = 4;</code>
*/
public static final int ROGUE_STATUS_FINISH_VALUE = 4;
private final String name;
private final int number;
private RogueStatus(String name, int number) {
this.name = name;
this.number = number;
}
/**
* @return the string representation of enum entry
*/
@Override
public String getName() {
return name;
}
/**
* @return the numeric wire value of this enum entry
*/
@Override
public int getNumber() {
return number;
}
/**
* @return a converter that maps between this enum's numeric and text representations
*/
public static ProtoEnum.EnumConverter<RogueStatus> converter() {
return RogueStatusConverter.INSTANCE;
}
/**
* @param value The numeric wire value of the corresponding enum entry.
* @return The enum associated with the given numeric wire value, or null if unknown.
*/
public static RogueStatus forNumber(int value) {
return RogueStatusConverter.INSTANCE.forNumber(value);
}
/**
* @param value The numeric wire value of the corresponding enum entry.
* @param other Fallback value in case the value is not known.
* @return The enum associated with the given numeric wire value, or the fallback value if unknown.
*/
public static RogueStatus forNumberOr(int number, RogueStatus other) {
RogueStatus value = forNumber(number);
return value == null ? other : value;
}
enum RogueStatusConverter implements ProtoEnum.EnumConverter<RogueStatus> {
INSTANCE;
private static final RogueStatus[] lookup = new RogueStatus[5];
static {
lookup[0] = ROGUE_STATUS_NONE;
lookup[1] = ROGUE_STATUS_DOING;
lookup[2] = ROGUE_STATUS_PENDING;
lookup[3] = ROGUE_STATUS_ENDLESS;
lookup[4] = ROGUE_STATUS_FINISH;
}
@Override
public final RogueStatus forNumber(final int value) {
if (value >= 0 && value < lookup.length) {
return lookup[value];
}
return null;
}
@Override
public final RogueStatus forName(final CharSequence value) {
switch (value.length()) {
case 17: {
if (ProtoUtil.isEqual("ROGUE_STATUS_NONE", value)) {
return ROGUE_STATUS_NONE;
}
break;
}
case 18: {
if (ProtoUtil.isEqual("ROGUE_STATUS_DOING", value)) {
return ROGUE_STATUS_DOING;
}
break;
}
case 19: {
if (ProtoUtil.isEqual("ROGUE_STATUS_FINISH", value)) {
return ROGUE_STATUS_FINISH;
}
break;
}
case 20: {
if (ProtoUtil.isEqual("ROGUE_STATUS_PENDING", value)) {
return ROGUE_STATUS_PENDING;
}
if (ProtoUtil.isEqual("ROGUE_STATUS_ENDLESS", value)) {
return ROGUE_STATUS_ENDLESS;
}
break;
}
}
return null;
}
}
}
}

View File

@@ -29,6 +29,7 @@ public class GameData {
@Getter private static Int2ObjectMap<HeroExcel> heroExcelMap = new Int2ObjectOpenHashMap<>();
@Getter private static Int2ObjectMap<ChallengeExcel> challengeExcelMap = new Int2ObjectOpenHashMap<>();
@Getter private static Int2ObjectMap<ChallengeTargetExcel> challengeTargetExcelMap = new Int2ObjectOpenHashMap<>();
@Getter private static Int2ObjectMap<RogueAreaExcel> rogueAreaExcelMap = new Int2ObjectOpenHashMap<>();
@Getter private static Int2ObjectMap<ShopExcel> shopExcelMap = new Int2ObjectOpenHashMap<>();
private static Int2ObjectMap<AvatarPromotionExcel> avatarPromotionExcelMap = new Int2ObjectOpenHashMap<>();

View File

@@ -0,0 +1,19 @@
package emu.lunarcore.data.excel;
import emu.lunarcore.data.GameResource;
import emu.lunarcore.data.ResourceType;
import lombok.Getter;
@Getter
@ResourceType(name = {"RogueAreaConfig.json"})
public class RogueAreaExcel extends GameResource {
private int RogueAreaID;
private int AreaProgress;
private int Difficulty;
@Override
public int getId() {
return RogueAreaID;
}
}

View File

@@ -0,0 +1,17 @@
package emu.lunarcore.server.packet.recv;
import emu.lunarcore.server.game.GameSession;
import emu.lunarcore.server.packet.CmdId;
import emu.lunarcore.server.packet.Opcodes;
import emu.lunarcore.server.packet.PacketHandler;
import emu.lunarcore.server.packet.send.PacketGetRogueHandbookDataScRsp;
@Opcodes(CmdId.GetRogueHandbookDataCsReq)
public class HandlerGetRogueHandbookDataCsReq extends PacketHandler {
@Override
public void handle(GameSession session, byte[] header, byte[] data) throws Exception {
session.send(new PacketGetRogueHandbookDataScRsp());
}
}

View File

@@ -4,13 +4,14 @@ import emu.lunarcore.server.game.GameSession;
import emu.lunarcore.server.packet.CmdId;
import emu.lunarcore.server.packet.Opcodes;
import emu.lunarcore.server.packet.PacketHandler;
import emu.lunarcore.server.packet.send.PacketGetRogueInfoScRsp;
@Opcodes(CmdId.GetRogueInfoCsReq)
public class HandlerGetRogueInfoCsReq extends PacketHandler {
@Override
public void handle(GameSession session, byte[] header, byte[] data) throws Exception {
session.send(CmdId.GetRogueInfoScRsp);
session.send(new PacketGetRogueInfoScRsp());
}
}

View File

@@ -0,0 +1,17 @@
package emu.lunarcore.server.packet.recv;
import emu.lunarcore.server.game.GameSession;
import emu.lunarcore.server.packet.CmdId;
import emu.lunarcore.server.packet.Opcodes;
import emu.lunarcore.server.packet.PacketHandler;
import emu.lunarcore.server.packet.send.PacketGetRogueScoreRewardInfoScRsp;
@Opcodes(CmdId.GetRogueScoreRewardInfoCsReq)
public class HandlerGetRogueScoreRewardInfoCsReq extends PacketHandler {
@Override
public void handle(GameSession session, byte[] header, byte[] data) throws Exception {
session.send(new PacketGetRogueScoreRewardInfoScRsp());
}
}

View File

@@ -0,0 +1,16 @@
package emu.lunarcore.server.packet.recv;
import emu.lunarcore.server.game.GameSession;
import emu.lunarcore.server.packet.CmdId;
import emu.lunarcore.server.packet.Opcodes;
import emu.lunarcore.server.packet.PacketHandler;
@Opcodes(CmdId.GetRogueTalentInfoCsReq)
public class HandlerGetRogueTalentInfoCsReq extends PacketHandler {
@Override
public void handle(GameSession session, byte[] header, byte[] data) throws Exception {
session.send(CmdId.GetRogueTalentInfoScRsp);
}
}

View File

@@ -0,0 +1,16 @@
package emu.lunarcore.server.packet.recv;
import emu.lunarcore.server.game.GameSession;
import emu.lunarcore.server.packet.CmdId;
import emu.lunarcore.server.packet.Opcodes;
import emu.lunarcore.server.packet.PacketHandler;
@Opcodes(CmdId.StartRogueCsReq)
public class HandlerStartRogueCsReq extends PacketHandler {
@Override
public void handle(GameSession session, byte[] header, byte[] data) throws Exception {
session.send(CmdId.StartRogueScRsp);
}
}

View File

@@ -0,0 +1,22 @@
package emu.lunarcore.server.packet.send;
import emu.lunarcore.proto.GetRogueHandbookDataScRspOuterClass.GetRogueHandbookDataScRsp;
import emu.lunarcore.proto.RogueHandbookDataOuterClass.RogueHandbookData;
import emu.lunarcore.server.packet.BasePacket;
import emu.lunarcore.server.packet.CmdId;
public class PacketGetRogueHandbookDataScRsp extends BasePacket {
public PacketGetRogueHandbookDataScRsp() {
super(CmdId.GetRogueHandbookDataScRsp);
var handbook = RogueHandbookData.newInstance()
.setRogueCurrentVersion(1)
.setIsMiracleUnlock(true);
var data = GetRogueHandbookDataScRsp.newInstance()
.setHandbookInfo(handbook);
this.setData(data);
}
}

View File

@@ -0,0 +1,59 @@
package emu.lunarcore.server.packet.send;
import java.util.concurrent.TimeUnit;
import emu.lunarcore.data.GameData;
import emu.lunarcore.proto.GetRogueInfoScRspOuterClass.GetRogueInfoScRsp;
import emu.lunarcore.proto.RogueAreaOuterClass.RogueArea;
import emu.lunarcore.proto.RogueAreaStatusOuterClass.RogueAreaStatus;
import emu.lunarcore.proto.RogueInfoDataOuterClass.RogueInfoData;
import emu.lunarcore.proto.RogueInfoOuterClass.RogueInfo;
import emu.lunarcore.proto.RogueScoreRewardInfoOuterClass.RogueScoreRewardInfo;
import emu.lunarcore.proto.RogueSeasonInfoOuterClass.RogueSeasonInfo;
import emu.lunarcore.server.packet.BasePacket;
import emu.lunarcore.server.packet.CmdId;
public class PacketGetRogueInfoScRsp extends BasePacket {
public PacketGetRogueInfoScRsp() {
super(CmdId.GetRogueInfoScRsp);
int seasonId = 67; // TODO un hardcode
long beginTime = (System.currentTimeMillis() / 1000) - TimeUnit.DAYS.toSeconds(1);
long endTime = beginTime + TimeUnit.DAYS.toSeconds(8);
var score = RogueScoreRewardInfo.newInstance()
.setPoolId(seasonId)
.setPoolRefreshed(true)
.setHasTakenInitialScore(true);
var season = RogueSeasonInfo.newInstance()
.setBeginTime(beginTime)
.setRogueSeasonId(seasonId)
.setEndTime(endTime);
var data = RogueInfoData.newInstance()
.setRogueScoreInfo(score)
.setRogueSeasonInfo(season);
// Main proto
var proto = GetRogueInfoScRsp.newInstance();
RogueInfo info = proto.getMutableRogueInfo()
.setRogueScoreInfo(score)
.setRogueData(data)
.setRogueSeasonId(seasonId)
.setBeginTime(beginTime)
.setEndTime(endTime);
for (var excel : GameData.getRogueAreaExcelMap().values()) {
var area = RogueArea.newInstance()
.setAreaId(excel.getRogueAreaID())
.setRogueAreaStatus(RogueAreaStatus.ROGUE_AREA_STATUS_FIRST_PASS);
info.addRogueAreaList(area);
}
this.setData(proto);
}
}

View File

@@ -0,0 +1,21 @@
package emu.lunarcore.server.packet.send;
import emu.lunarcore.proto.GetRogueScoreRewardInfoScRspOuterClass.GetRogueScoreRewardInfoScRsp;
import emu.lunarcore.server.packet.BasePacket;
import emu.lunarcore.server.packet.CmdId;
public class PacketGetRogueScoreRewardInfoScRsp extends BasePacket {
public PacketGetRogueScoreRewardInfoScRsp() {
super(CmdId.GetRogueScoreRewardInfoScRsp);
var data = GetRogueScoreRewardInfoScRsp.newInstance();
data.getMutableScoreRewardInfo()
.setPoolId(1) // TODO un hardcode
.setPoolRefreshed(true)
.setHasTakenInitialScore(true);
this.setData(data);
}
}