Merge branch 'master' of http://60.1.1.230/backend/jieling_server
commit
c332a9b8c3
|
@ -10,6 +10,24 @@ public final class Expedition {
|
|||
}
|
||||
public interface GetExpeditionRequestOrBuilder
|
||||
extends com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
// optional int32 leve = 1;
|
||||
/**
|
||||
* <code>optional int32 leve = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
*阶段id
|
||||
* </pre>
|
||||
*/
|
||||
boolean hasLeve();
|
||||
/**
|
||||
* <code>optional int32 leve = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
*阶段id
|
||||
* </pre>
|
||||
*/
|
||||
int getLeve();
|
||||
}
|
||||
/**
|
||||
* Protobuf type {@code com.ljsd.jieling.protocols.GetExpeditionRequest}
|
||||
|
@ -48,6 +66,7 @@ public final class Expedition {
|
|||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
initFields();
|
||||
int mutable_bitField0_ = 0;
|
||||
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
|
||||
com.google.protobuf.UnknownFieldSet.newBuilder();
|
||||
try {
|
||||
|
@ -65,6 +84,11 @@ public final class Expedition {
|
|||
}
|
||||
break;
|
||||
}
|
||||
case 8: {
|
||||
bitField0_ |= 0x00000001;
|
||||
leve_ = input.readInt32();
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
|
@ -104,7 +128,33 @@ public final class Expedition {
|
|||
return PARSER;
|
||||
}
|
||||
|
||||
private int bitField0_;
|
||||
// optional int32 leve = 1;
|
||||
public static final int LEVE_FIELD_NUMBER = 1;
|
||||
private int leve_;
|
||||
/**
|
||||
* <code>optional int32 leve = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
*阶段id
|
||||
* </pre>
|
||||
*/
|
||||
public boolean hasLeve() {
|
||||
return ((bitField0_ & 0x00000001) == 0x00000001);
|
||||
}
|
||||
/**
|
||||
* <code>optional int32 leve = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
*阶段id
|
||||
* </pre>
|
||||
*/
|
||||
public int getLeve() {
|
||||
return leve_;
|
||||
}
|
||||
|
||||
private void initFields() {
|
||||
leve_ = 0;
|
||||
}
|
||||
private byte memoizedIsInitialized = -1;
|
||||
public final boolean isInitialized() {
|
||||
|
@ -118,6 +168,9 @@ public final class Expedition {
|
|||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
||||
throws java.io.IOException {
|
||||
getSerializedSize();
|
||||
if (((bitField0_ & 0x00000001) == 0x00000001)) {
|
||||
output.writeInt32(1, leve_);
|
||||
}
|
||||
getUnknownFields().writeTo(output);
|
||||
}
|
||||
|
||||
|
@ -127,6 +180,10 @@ public final class Expedition {
|
|||
if (size != -1) return size;
|
||||
|
||||
size = 0;
|
||||
if (((bitField0_ & 0x00000001) == 0x00000001)) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeInt32Size(1, leve_);
|
||||
}
|
||||
size += getUnknownFields().getSerializedSize();
|
||||
memoizedSerializedSize = size;
|
||||
return size;
|
||||
|
@ -247,6 +304,8 @@ public final class Expedition {
|
|||
|
||||
public Builder clear() {
|
||||
super.clear();
|
||||
leve_ = 0;
|
||||
bitField0_ = (bitField0_ & ~0x00000001);
|
||||
return this;
|
||||
}
|
||||
|
||||
|
@ -273,6 +332,13 @@ public final class Expedition {
|
|||
|
||||
public com.ljsd.jieling.protocols.Expedition.GetExpeditionRequest buildPartial() {
|
||||
com.ljsd.jieling.protocols.Expedition.GetExpeditionRequest result = new com.ljsd.jieling.protocols.Expedition.GetExpeditionRequest(this);
|
||||
int from_bitField0_ = bitField0_;
|
||||
int to_bitField0_ = 0;
|
||||
if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
|
||||
to_bitField0_ |= 0x00000001;
|
||||
}
|
||||
result.leve_ = leve_;
|
||||
result.bitField0_ = to_bitField0_;
|
||||
onBuilt();
|
||||
return result;
|
||||
}
|
||||
|
@ -288,6 +354,9 @@ public final class Expedition {
|
|||
|
||||
public Builder mergeFrom(com.ljsd.jieling.protocols.Expedition.GetExpeditionRequest other) {
|
||||
if (other == com.ljsd.jieling.protocols.Expedition.GetExpeditionRequest.getDefaultInstance()) return this;
|
||||
if (other.hasLeve()) {
|
||||
setLeve(other.getLeve());
|
||||
}
|
||||
this.mergeUnknownFields(other.getUnknownFields());
|
||||
return this;
|
||||
}
|
||||
|
@ -313,6 +382,56 @@ public final class Expedition {
|
|||
}
|
||||
return this;
|
||||
}
|
||||
private int bitField0_;
|
||||
|
||||
// optional int32 leve = 1;
|
||||
private int leve_ ;
|
||||
/**
|
||||
* <code>optional int32 leve = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
*阶段id
|
||||
* </pre>
|
||||
*/
|
||||
public boolean hasLeve() {
|
||||
return ((bitField0_ & 0x00000001) == 0x00000001);
|
||||
}
|
||||
/**
|
||||
* <code>optional int32 leve = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
*阶段id
|
||||
* </pre>
|
||||
*/
|
||||
public int getLeve() {
|
||||
return leve_;
|
||||
}
|
||||
/**
|
||||
* <code>optional int32 leve = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
*阶段id
|
||||
* </pre>
|
||||
*/
|
||||
public Builder setLeve(int value) {
|
||||
bitField0_ |= 0x00000001;
|
||||
leve_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional int32 leve = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
*阶段id
|
||||
* </pre>
|
||||
*/
|
||||
public Builder clearLeve() {
|
||||
bitField0_ = (bitField0_ & ~0x00000001);
|
||||
leve_ = 0;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(builder_scope:com.ljsd.jieling.protocols.GetExpeditionRequest)
|
||||
}
|
||||
|
@ -2159,23 +2278,23 @@ public final class Expedition {
|
|||
public interface TakeExpeditionBoxRewardRequestOrBuilder
|
||||
extends com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
// optional int32 lay = 1;
|
||||
// optional int32 laycfg = 1;
|
||||
/**
|
||||
* <code>optional int32 lay = 1;</code>
|
||||
* <code>optional int32 laycfg = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
*层
|
||||
*层配置id
|
||||
* </pre>
|
||||
*/
|
||||
boolean hasLay();
|
||||
boolean hasLaycfg();
|
||||
/**
|
||||
* <code>optional int32 lay = 1;</code>
|
||||
* <code>optional int32 laycfg = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
*层
|
||||
*层配置id
|
||||
* </pre>
|
||||
*/
|
||||
int getLay();
|
||||
int getLaycfg();
|
||||
}
|
||||
/**
|
||||
* Protobuf type {@code com.ljsd.jieling.protocols.TakeExpeditionBoxRewardRequest}
|
||||
|
@ -2230,7 +2349,7 @@ public final class Expedition {
|
|||
}
|
||||
case 8: {
|
||||
bitField0_ |= 0x00000001;
|
||||
lay_ = input.readInt32();
|
||||
laycfg_ = input.readInt32();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
@ -2273,32 +2392,32 @@ public final class Expedition {
|
|||
}
|
||||
|
||||
private int bitField0_;
|
||||
// optional int32 lay = 1;
|
||||
public static final int LAY_FIELD_NUMBER = 1;
|
||||
private int lay_;
|
||||
// optional int32 laycfg = 1;
|
||||
public static final int LAYCFG_FIELD_NUMBER = 1;
|
||||
private int laycfg_;
|
||||
/**
|
||||
* <code>optional int32 lay = 1;</code>
|
||||
* <code>optional int32 laycfg = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
*层
|
||||
*层配置id
|
||||
* </pre>
|
||||
*/
|
||||
public boolean hasLay() {
|
||||
public boolean hasLaycfg() {
|
||||
return ((bitField0_ & 0x00000001) == 0x00000001);
|
||||
}
|
||||
/**
|
||||
* <code>optional int32 lay = 1;</code>
|
||||
* <code>optional int32 laycfg = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
*层
|
||||
*层配置id
|
||||
* </pre>
|
||||
*/
|
||||
public int getLay() {
|
||||
return lay_;
|
||||
public int getLaycfg() {
|
||||
return laycfg_;
|
||||
}
|
||||
|
||||
private void initFields() {
|
||||
lay_ = 0;
|
||||
laycfg_ = 0;
|
||||
}
|
||||
private byte memoizedIsInitialized = -1;
|
||||
public final boolean isInitialized() {
|
||||
|
@ -2313,7 +2432,7 @@ public final class Expedition {
|
|||
throws java.io.IOException {
|
||||
getSerializedSize();
|
||||
if (((bitField0_ & 0x00000001) == 0x00000001)) {
|
||||
output.writeInt32(1, lay_);
|
||||
output.writeInt32(1, laycfg_);
|
||||
}
|
||||
getUnknownFields().writeTo(output);
|
||||
}
|
||||
|
@ -2326,7 +2445,7 @@ public final class Expedition {
|
|||
size = 0;
|
||||
if (((bitField0_ & 0x00000001) == 0x00000001)) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeInt32Size(1, lay_);
|
||||
.computeInt32Size(1, laycfg_);
|
||||
}
|
||||
size += getUnknownFields().getSerializedSize();
|
||||
memoizedSerializedSize = size;
|
||||
|
@ -2444,7 +2563,7 @@ public final class Expedition {
|
|||
|
||||
public Builder clear() {
|
||||
super.clear();
|
||||
lay_ = 0;
|
||||
laycfg_ = 0;
|
||||
bitField0_ = (bitField0_ & ~0x00000001);
|
||||
return this;
|
||||
}
|
||||
|
@ -2477,7 +2596,7 @@ public final class Expedition {
|
|||
if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
|
||||
to_bitField0_ |= 0x00000001;
|
||||
}
|
||||
result.lay_ = lay_;
|
||||
result.laycfg_ = laycfg_;
|
||||
result.bitField0_ = to_bitField0_;
|
||||
onBuilt();
|
||||
return result;
|
||||
|
@ -2494,8 +2613,8 @@ public final class Expedition {
|
|||
|
||||
public Builder mergeFrom(com.ljsd.jieling.protocols.Expedition.TakeExpeditionBoxRewardRequest other) {
|
||||
if (other == com.ljsd.jieling.protocols.Expedition.TakeExpeditionBoxRewardRequest.getDefaultInstance()) return this;
|
||||
if (other.hasLay()) {
|
||||
setLay(other.getLay());
|
||||
if (other.hasLaycfg()) {
|
||||
setLaycfg(other.getLaycfg());
|
||||
}
|
||||
this.mergeUnknownFields(other.getUnknownFields());
|
||||
return this;
|
||||
|
@ -2524,51 +2643,51 @@ public final class Expedition {
|
|||
}
|
||||
private int bitField0_;
|
||||
|
||||
// optional int32 lay = 1;
|
||||
private int lay_ ;
|
||||
// optional int32 laycfg = 1;
|
||||
private int laycfg_ ;
|
||||
/**
|
||||
* <code>optional int32 lay = 1;</code>
|
||||
* <code>optional int32 laycfg = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
*层
|
||||
*层配置id
|
||||
* </pre>
|
||||
*/
|
||||
public boolean hasLay() {
|
||||
public boolean hasLaycfg() {
|
||||
return ((bitField0_ & 0x00000001) == 0x00000001);
|
||||
}
|
||||
/**
|
||||
* <code>optional int32 lay = 1;</code>
|
||||
* <code>optional int32 laycfg = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
*层
|
||||
*层配置id
|
||||
* </pre>
|
||||
*/
|
||||
public int getLay() {
|
||||
return lay_;
|
||||
public int getLaycfg() {
|
||||
return laycfg_;
|
||||
}
|
||||
/**
|
||||
* <code>optional int32 lay = 1;</code>
|
||||
* <code>optional int32 laycfg = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
*层
|
||||
*层配置id
|
||||
* </pre>
|
||||
*/
|
||||
public Builder setLay(int value) {
|
||||
public Builder setLaycfg(int value) {
|
||||
bitField0_ |= 0x00000001;
|
||||
lay_ = value;
|
||||
laycfg_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional int32 lay = 1;</code>
|
||||
* <code>optional int32 laycfg = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
*层
|
||||
*层配置id
|
||||
* </pre>
|
||||
*/
|
||||
public Builder clearLay() {
|
||||
public Builder clearLaycfg() {
|
||||
bitField0_ = (bitField0_ & ~0x00000001);
|
||||
lay_ = 0;
|
||||
laycfg_ = 0;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
@ -2600,6 +2719,32 @@ public final class Expedition {
|
|||
* <code>optional .com.ljsd.jieling.protocols.Drop drop = 1;</code>
|
||||
*/
|
||||
com.ljsd.jieling.protocols.CommonProto.DropOrBuilder getDropOrBuilder();
|
||||
|
||||
// repeated int32 leve = 2;
|
||||
/**
|
||||
* <code>repeated int32 leve = 2;</code>
|
||||
*
|
||||
* <pre>
|
||||
*阶段id 3层的时候有困难和普通两个
|
||||
* </pre>
|
||||
*/
|
||||
java.util.List<java.lang.Integer> getLeveList();
|
||||
/**
|
||||
* <code>repeated int32 leve = 2;</code>
|
||||
*
|
||||
* <pre>
|
||||
*阶段id 3层的时候有困难和普通两个
|
||||
* </pre>
|
||||
*/
|
||||
int getLeveCount();
|
||||
/**
|
||||
* <code>repeated int32 leve = 2;</code>
|
||||
*
|
||||
* <pre>
|
||||
*阶段id 3层的时候有困难和普通两个
|
||||
* </pre>
|
||||
*/
|
||||
int getLeve(int index);
|
||||
}
|
||||
/**
|
||||
* Protobuf type {@code com.ljsd.jieling.protocols.TakeExpeditionBoxRewardResponse}
|
||||
|
@ -2665,6 +2810,27 @@ public final class Expedition {
|
|||
bitField0_ |= 0x00000001;
|
||||
break;
|
||||
}
|
||||
case 16: {
|
||||
if (!((mutable_bitField0_ & 0x00000002) == 0x00000002)) {
|
||||
leve_ = new java.util.ArrayList<java.lang.Integer>();
|
||||
mutable_bitField0_ |= 0x00000002;
|
||||
}
|
||||
leve_.add(input.readInt32());
|
||||
break;
|
||||
}
|
||||
case 18: {
|
||||
int length = input.readRawVarint32();
|
||||
int limit = input.pushLimit(length);
|
||||
if (!((mutable_bitField0_ & 0x00000002) == 0x00000002) && input.getBytesUntilLimit() > 0) {
|
||||
leve_ = new java.util.ArrayList<java.lang.Integer>();
|
||||
mutable_bitField0_ |= 0x00000002;
|
||||
}
|
||||
while (input.getBytesUntilLimit() > 0) {
|
||||
leve_.add(input.readInt32());
|
||||
}
|
||||
input.popLimit(limit);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
|
@ -2673,6 +2839,9 @@ public final class Expedition {
|
|||
throw new com.google.protobuf.InvalidProtocolBufferException(
|
||||
e.getMessage()).setUnfinishedMessage(this);
|
||||
} finally {
|
||||
if (((mutable_bitField0_ & 0x00000002) == 0x00000002)) {
|
||||
leve_ = java.util.Collections.unmodifiableList(leve_);
|
||||
}
|
||||
this.unknownFields = unknownFields.build();
|
||||
makeExtensionsImmutable();
|
||||
}
|
||||
|
@ -2727,8 +2896,44 @@ public final class Expedition {
|
|||
return drop_;
|
||||
}
|
||||
|
||||
// repeated int32 leve = 2;
|
||||
public static final int LEVE_FIELD_NUMBER = 2;
|
||||
private java.util.List<java.lang.Integer> leve_;
|
||||
/**
|
||||
* <code>repeated int32 leve = 2;</code>
|
||||
*
|
||||
* <pre>
|
||||
*阶段id 3层的时候有困难和普通两个
|
||||
* </pre>
|
||||
*/
|
||||
public java.util.List<java.lang.Integer>
|
||||
getLeveList() {
|
||||
return leve_;
|
||||
}
|
||||
/**
|
||||
* <code>repeated int32 leve = 2;</code>
|
||||
*
|
||||
* <pre>
|
||||
*阶段id 3层的时候有困难和普通两个
|
||||
* </pre>
|
||||
*/
|
||||
public int getLeveCount() {
|
||||
return leve_.size();
|
||||
}
|
||||
/**
|
||||
* <code>repeated int32 leve = 2;</code>
|
||||
*
|
||||
* <pre>
|
||||
*阶段id 3层的时候有困难和普通两个
|
||||
* </pre>
|
||||
*/
|
||||
public int getLeve(int index) {
|
||||
return leve_.get(index);
|
||||
}
|
||||
|
||||
private void initFields() {
|
||||
drop_ = com.ljsd.jieling.protocols.CommonProto.Drop.getDefaultInstance();
|
||||
leve_ = java.util.Collections.emptyList();
|
||||
}
|
||||
private byte memoizedIsInitialized = -1;
|
||||
public final boolean isInitialized() {
|
||||
|
@ -2745,6 +2950,9 @@ public final class Expedition {
|
|||
if (((bitField0_ & 0x00000001) == 0x00000001)) {
|
||||
output.writeMessage(1, drop_);
|
||||
}
|
||||
for (int i = 0; i < leve_.size(); i++) {
|
||||
output.writeInt32(2, leve_.get(i));
|
||||
}
|
||||
getUnknownFields().writeTo(output);
|
||||
}
|
||||
|
||||
|
@ -2758,6 +2966,15 @@ public final class Expedition {
|
|||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeMessageSize(1, drop_);
|
||||
}
|
||||
{
|
||||
int dataSize = 0;
|
||||
for (int i = 0; i < leve_.size(); i++) {
|
||||
dataSize += com.google.protobuf.CodedOutputStream
|
||||
.computeInt32SizeNoTag(leve_.get(i));
|
||||
}
|
||||
size += dataSize;
|
||||
size += 1 * getLeveList().size();
|
||||
}
|
||||
size += getUnknownFields().getSerializedSize();
|
||||
memoizedSerializedSize = size;
|
||||
return size;
|
||||
|
@ -2881,6 +3098,8 @@ public final class Expedition {
|
|||
dropBuilder_.clear();
|
||||
}
|
||||
bitField0_ = (bitField0_ & ~0x00000001);
|
||||
leve_ = java.util.Collections.emptyList();
|
||||
bitField0_ = (bitField0_ & ~0x00000002);
|
||||
return this;
|
||||
}
|
||||
|
||||
|
@ -2917,6 +3136,11 @@ public final class Expedition {
|
|||
} else {
|
||||
result.drop_ = dropBuilder_.build();
|
||||
}
|
||||
if (((bitField0_ & 0x00000002) == 0x00000002)) {
|
||||
leve_ = java.util.Collections.unmodifiableList(leve_);
|
||||
bitField0_ = (bitField0_ & ~0x00000002);
|
||||
}
|
||||
result.leve_ = leve_;
|
||||
result.bitField0_ = to_bitField0_;
|
||||
onBuilt();
|
||||
return result;
|
||||
|
@ -2936,6 +3160,16 @@ public final class Expedition {
|
|||
if (other.hasDrop()) {
|
||||
mergeDrop(other.getDrop());
|
||||
}
|
||||
if (!other.leve_.isEmpty()) {
|
||||
if (leve_.isEmpty()) {
|
||||
leve_ = other.leve_;
|
||||
bitField0_ = (bitField0_ & ~0x00000002);
|
||||
} else {
|
||||
ensureLeveIsMutable();
|
||||
leve_.addAll(other.leve_);
|
||||
}
|
||||
onChanged();
|
||||
}
|
||||
this.mergeUnknownFields(other.getUnknownFields());
|
||||
return this;
|
||||
}
|
||||
|
@ -3080,6 +3314,100 @@ public final class Expedition {
|
|||
return dropBuilder_;
|
||||
}
|
||||
|
||||
// repeated int32 leve = 2;
|
||||
private java.util.List<java.lang.Integer> leve_ = java.util.Collections.emptyList();
|
||||
private void ensureLeveIsMutable() {
|
||||
if (!((bitField0_ & 0x00000002) == 0x00000002)) {
|
||||
leve_ = new java.util.ArrayList<java.lang.Integer>(leve_);
|
||||
bitField0_ |= 0x00000002;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <code>repeated int32 leve = 2;</code>
|
||||
*
|
||||
* <pre>
|
||||
*阶段id 3层的时候有困难和普通两个
|
||||
* </pre>
|
||||
*/
|
||||
public java.util.List<java.lang.Integer>
|
||||
getLeveList() {
|
||||
return java.util.Collections.unmodifiableList(leve_);
|
||||
}
|
||||
/**
|
||||
* <code>repeated int32 leve = 2;</code>
|
||||
*
|
||||
* <pre>
|
||||
*阶段id 3层的时候有困难和普通两个
|
||||
* </pre>
|
||||
*/
|
||||
public int getLeveCount() {
|
||||
return leve_.size();
|
||||
}
|
||||
/**
|
||||
* <code>repeated int32 leve = 2;</code>
|
||||
*
|
||||
* <pre>
|
||||
*阶段id 3层的时候有困难和普通两个
|
||||
* </pre>
|
||||
*/
|
||||
public int getLeve(int index) {
|
||||
return leve_.get(index);
|
||||
}
|
||||
/**
|
||||
* <code>repeated int32 leve = 2;</code>
|
||||
*
|
||||
* <pre>
|
||||
*阶段id 3层的时候有困难和普通两个
|
||||
* </pre>
|
||||
*/
|
||||
public Builder setLeve(
|
||||
int index, int value) {
|
||||
ensureLeveIsMutable();
|
||||
leve_.set(index, value);
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>repeated int32 leve = 2;</code>
|
||||
*
|
||||
* <pre>
|
||||
*阶段id 3层的时候有困难和普通两个
|
||||
* </pre>
|
||||
*/
|
||||
public Builder addLeve(int value) {
|
||||
ensureLeveIsMutable();
|
||||
leve_.add(value);
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>repeated int32 leve = 2;</code>
|
||||
*
|
||||
* <pre>
|
||||
*阶段id 3层的时候有困难和普通两个
|
||||
* </pre>
|
||||
*/
|
||||
public Builder addAllLeve(
|
||||
java.lang.Iterable<? extends java.lang.Integer> values) {
|
||||
ensureLeveIsMutable();
|
||||
super.addAll(values, leve_);
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>repeated int32 leve = 2;</code>
|
||||
*
|
||||
* <pre>
|
||||
*阶段id 3层的时候有困难和普通两个
|
||||
* </pre>
|
||||
*/
|
||||
public Builder clearLeve() {
|
||||
leve_ = java.util.Collections.emptyList();
|
||||
bitField0_ = (bitField0_ & ~0x00000002);
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(builder_scope:com.ljsd.jieling.protocols.TakeExpeditionBoxRewardResponse)
|
||||
}
|
||||
|
||||
|
@ -13066,49 +13394,50 @@ public final class Expedition {
|
|||
static {
|
||||
java.lang.String[] descriptorData = {
|
||||
"\n\020Expedition.proto\022\032com.ljsd.jieling.pro" +
|
||||
"tocols\032\021CommonProto.proto\"\026\n\024GetExpediti" +
|
||||
"onRequest\"\355\001\n\025GetExpeditionResponse\022@\n\010n" +
|
||||
"odeInfo\030\001 \003(\0132..com.ljsd.jieling.protoco" +
|
||||
"ls.ExpeditionNodeInfo\022F\n\010heroInfo\030\002 \003(\0132" +
|
||||
"4.com.ljsd.jieling.protocols.ExpeditionS" +
|
||||
"impleHeroInfo\022\013\n\003lay\030\003 \003(\005\022=\n\010equipIds\030\004" +
|
||||
" \003(\0132+.com.ljsd.jieling.protocols.Expedi" +
|
||||
"tionEquip\"-\n\036TakeExpeditionBoxRewardRequ" +
|
||||
"est\022\013\n\003lay\030\001 \001(\005\"Q\n\037TakeExpeditionBoxRew",
|
||||
"ardResponse\022.\n\004drop\030\001 \001(\0132 .com.ljsd.jie" +
|
||||
"ling.protocols.Drop\"=\n\033ReliveExpeditionH" +
|
||||
"eroRequest\022\016\n\006heroId\030\001 \001(\t\022\016\n\006nodeId\030\002 \001" +
|
||||
"(\005\"f\n\034ReliveExpeditionHeroResponse\022F\n\010he" +
|
||||
"roInfo\030\001 \001(\01324.com.ljsd.jieling.protocol" +
|
||||
"s.ExpeditionSimpleHeroInfo\".\n\034ReCoverExp" +
|
||||
"editionHeroRequest\022\016\n\006nodeId\030\001 \001(\005\"g\n\035Re" +
|
||||
"CoverExpeditionHeroResponse\022F\n\010heroInfo\030" +
|
||||
"\001 \003(\01324.com.ljsd.jieling.protocols.Exped" +
|
||||
"itionSimpleHeroInfo\">\n\034StartExpeditionBa",
|
||||
"ttleRequest\022\016\n\006nodeId\030\001 \001(\005\022\016\n\006teamId\030\002 " +
|
||||
"\001(\005\"Y\n\035StartExpeditionBattleResponse\0228\n\t" +
|
||||
"fightData\030\001 \001(\0132%.com.ljsd.jieling.proto" +
|
||||
"cols.FightData\"<\n\032EndExpeditionBattleReq" +
|
||||
"uest\022\016\n\006nodeId\030\001 \001(\005\022\016\n\006frames\030\002 \001(\t\"]\n\033" +
|
||||
"EndExpeditionBattleResponse\022\016\n\006result\030\001 " +
|
||||
"\001(\005\022.\n\004drop\030\002 \001(\0132 .com.ljsd.jieling.pro" +
|
||||
"tocols.Drop\"4\n\024TakeHolyEquipRequest\022\016\n\006n" +
|
||||
"odeId\030\001 \001(\005\022\014\n\004type\030\002 \001(\005\"(\n\025TakeHolyEqu" +
|
||||
"ipResponse\022\017\n\007equipId\030\001 \001(\t\"Z\n\031Expeditio",
|
||||
"nEquipIndication\022=\n\010equipIds\030\001 \003(\0132+.com" +
|
||||
".ljsd.jieling.protocols.ExpeditionEquip\"" +
|
||||
"\250\001\n\034ExpeditionNodeInfoIndication\022@\n\010node" +
|
||||
"Info\030\001 \003(\0132..com.ljsd.jieling.protocols." +
|
||||
"ExpeditionNodeInfo\022F\n\010heroInfo\030\002 \003(\01324.c" +
|
||||
"om.ljsd.jieling.protocols.ExpeditionSimp" +
|
||||
"leHeroInfo\"+\n\035ExpeditionTakeTreasureRequ" +
|
||||
"est\022\n\n\002id\030\001 \001(\005\"P\n\036ExpeditionTakeTreasur" +
|
||||
"eResponse\022.\n\004drop\030\001 \001(\0132 .com.ljsd.jieli" +
|
||||
"ng.protocols.Drop\"0\n\023TreasureRewardState",
|
||||
"\022\n\n\002id\030\001 \001(\005\022\r\n\005state\030\002 \001(\005\"u\n\026TreasureS" +
|
||||
"tateIndicaion\022\r\n\005score\030\001 \001(\005\022L\n\023treasure" +
|
||||
"RewardState\030\002 \003(\0132/.com.ljsd.jieling.pro" +
|
||||
"tocols.TreasureRewardStateB\002H\001"
|
||||
"tocols\032\021CommonProto.proto\"$\n\024GetExpediti" +
|
||||
"onRequest\022\014\n\004leve\030\001 \001(\005\"\355\001\n\025GetExpeditio" +
|
||||
"nResponse\022@\n\010nodeInfo\030\001 \003(\0132..com.ljsd.j" +
|
||||
"ieling.protocols.ExpeditionNodeInfo\022F\n\010h" +
|
||||
"eroInfo\030\002 \003(\01324.com.ljsd.jieling.protoco" +
|
||||
"ls.ExpeditionSimpleHeroInfo\022\013\n\003lay\030\003 \003(\005" +
|
||||
"\022=\n\010equipIds\030\004 \003(\0132+.com.ljsd.jieling.pr" +
|
||||
"otocols.ExpeditionEquip\"0\n\036TakeExpeditio" +
|
||||
"nBoxRewardRequest\022\016\n\006laycfg\030\001 \001(\005\"_\n\037Tak",
|
||||
"eExpeditionBoxRewardResponse\022.\n\004drop\030\001 \001" +
|
||||
"(\0132 .com.ljsd.jieling.protocols.Drop\022\014\n\004" +
|
||||
"leve\030\002 \003(\005\"=\n\033ReliveExpeditionHeroReques" +
|
||||
"t\022\016\n\006heroId\030\001 \001(\t\022\016\n\006nodeId\030\002 \001(\005\"f\n\034Rel" +
|
||||
"iveExpeditionHeroResponse\022F\n\010heroInfo\030\001 " +
|
||||
"\001(\01324.com.ljsd.jieling.protocols.Expedit" +
|
||||
"ionSimpleHeroInfo\".\n\034ReCoverExpeditionHe" +
|
||||
"roRequest\022\016\n\006nodeId\030\001 \001(\005\"g\n\035ReCoverExpe" +
|
||||
"ditionHeroResponse\022F\n\010heroInfo\030\001 \003(\01324.c" +
|
||||
"om.ljsd.jieling.protocols.ExpeditionSimp",
|
||||
"leHeroInfo\">\n\034StartExpeditionBattleReque" +
|
||||
"st\022\016\n\006nodeId\030\001 \001(\005\022\016\n\006teamId\030\002 \001(\005\"Y\n\035St" +
|
||||
"artExpeditionBattleResponse\0228\n\tfightData" +
|
||||
"\030\001 \001(\0132%.com.ljsd.jieling.protocols.Figh" +
|
||||
"tData\"<\n\032EndExpeditionBattleRequest\022\016\n\006n" +
|
||||
"odeId\030\001 \001(\005\022\016\n\006frames\030\002 \001(\t\"]\n\033EndExpedi" +
|
||||
"tionBattleResponse\022\016\n\006result\030\001 \001(\005\022.\n\004dr" +
|
||||
"op\030\002 \001(\0132 .com.ljsd.jieling.protocols.Dr" +
|
||||
"op\"4\n\024TakeHolyEquipRequest\022\016\n\006nodeId\030\001 \001" +
|
||||
"(\005\022\014\n\004type\030\002 \001(\005\"(\n\025TakeHolyEquipRespons",
|
||||
"e\022\017\n\007equipId\030\001 \001(\t\"Z\n\031ExpeditionEquipInd" +
|
||||
"ication\022=\n\010equipIds\030\001 \003(\0132+.com.ljsd.jie" +
|
||||
"ling.protocols.ExpeditionEquip\"\250\001\n\034Exped" +
|
||||
"itionNodeInfoIndication\022@\n\010nodeInfo\030\001 \003(" +
|
||||
"\0132..com.ljsd.jieling.protocols.Expeditio" +
|
||||
"nNodeInfo\022F\n\010heroInfo\030\002 \003(\01324.com.ljsd.j" +
|
||||
"ieling.protocols.ExpeditionSimpleHeroInf" +
|
||||
"o\"+\n\035ExpeditionTakeTreasureRequest\022\n\n\002id" +
|
||||
"\030\001 \001(\005\"P\n\036ExpeditionTakeTreasureResponse" +
|
||||
"\022.\n\004drop\030\001 \001(\0132 .com.ljsd.jieling.protoc",
|
||||
"ols.Drop\"0\n\023TreasureRewardState\022\n\n\002id\030\001 " +
|
||||
"\001(\005\022\r\n\005state\030\002 \001(\005\"u\n\026TreasureStateIndic" +
|
||||
"aion\022\r\n\005score\030\001 \001(\005\022L\n\023treasureRewardSta" +
|
||||
"te\030\002 \003(\0132/.com.ljsd.jieling.protocols.Tr" +
|
||||
"easureRewardStateB\002H\001"
|
||||
};
|
||||
com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner assigner =
|
||||
new com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner() {
|
||||
|
@ -13120,7 +13449,7 @@ public final class Expedition {
|
|||
internal_static_com_ljsd_jieling_protocols_GetExpeditionRequest_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable(
|
||||
internal_static_com_ljsd_jieling_protocols_GetExpeditionRequest_descriptor,
|
||||
new java.lang.String[] { });
|
||||
new java.lang.String[] { "Leve", });
|
||||
internal_static_com_ljsd_jieling_protocols_GetExpeditionResponse_descriptor =
|
||||
getDescriptor().getMessageTypes().get(1);
|
||||
internal_static_com_ljsd_jieling_protocols_GetExpeditionResponse_fieldAccessorTable = new
|
||||
|
@ -13132,13 +13461,13 @@ public final class Expedition {
|
|||
internal_static_com_ljsd_jieling_protocols_TakeExpeditionBoxRewardRequest_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable(
|
||||
internal_static_com_ljsd_jieling_protocols_TakeExpeditionBoxRewardRequest_descriptor,
|
||||
new java.lang.String[] { "Lay", });
|
||||
new java.lang.String[] { "Laycfg", });
|
||||
internal_static_com_ljsd_jieling_protocols_TakeExpeditionBoxRewardResponse_descriptor =
|
||||
getDescriptor().getMessageTypes().get(3);
|
||||
internal_static_com_ljsd_jieling_protocols_TakeExpeditionBoxRewardResponse_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable(
|
||||
internal_static_com_ljsd_jieling_protocols_TakeExpeditionBoxRewardResponse_descriptor,
|
||||
new java.lang.String[] { "Drop", });
|
||||
new java.lang.String[] { "Drop", "Leve", });
|
||||
internal_static_com_ljsd_jieling_protocols_ReliveExpeditionHeroRequest_descriptor =
|
||||
getDescriptor().getMessageTypes().get(4);
|
||||
internal_static_com_ljsd_jieling_protocols_ReliveExpeditionHeroRequest_fieldAccessorTable = new
|
||||
|
|
|
@ -32,7 +32,9 @@ public class CarDelayFunction implements FunctionManager {
|
|||
Set<String> guildSet = RedisUtil.getInstence().getZset(guildKey, 0, -1);
|
||||
guildSet.forEach(guildId->{
|
||||
GuildInfo guildInfo = GuilidManager.guildInfoMap.get(Integer.parseInt(guildId));
|
||||
guildInfo.clearCarFightSb();
|
||||
if(guildInfo != null){
|
||||
guildInfo.clearCarFightSb();
|
||||
}
|
||||
});
|
||||
MongoUtil.getLjsdMongoTemplate().lastUpdate();
|
||||
RedisUtil.getInstence().del(delKeys.toArray(new String[0]));
|
||||
|
@ -41,8 +43,8 @@ public class CarDelayFunction implements FunctionManager {
|
|||
@Override
|
||||
public void closeAction() throws Exception {
|
||||
Map<Integer, TreeMap<Integer, String>> rewardByTypeAndRankMap = SWorldBossRewardConfig.rewardByTypeAndRankMap;
|
||||
TreeMap<Integer, String> personRewardConfigTreeMap = rewardByTypeAndRankMap.get(1);
|
||||
TreeMap<Integer, String> guildRewardConfigTreeMap = rewardByTypeAndRankMap.get(2);
|
||||
TreeMap<Integer, String> personRewardConfigTreeMap = rewardByTypeAndRankMap.get(2);
|
||||
TreeMap<Integer, String> guildRewardConfigTreeMap = rewardByTypeAndRankMap.get(1);
|
||||
Set<ZSetOperations.TypedTuple<String>> personRangeWithScores = RedisUtil.getInstence().getZsetreverseRangeWithScores(RedisKey.CAR_DEALY_RANK, "", 0, -1);
|
||||
int rank=0;
|
||||
String personTitle = SErrorCodeEerverConfig.getI18NMessage("family_fight_rank_personreward_title");
|
||||
|
@ -63,12 +65,17 @@ public class CarDelayFunction implements FunctionManager {
|
|||
MongoUtil.getLjsdMongoTemplate().lastUpdate();
|
||||
String guildTitle = SErrorCodeEerverConfig.getI18NMessage("family_fight_rank_familyreward_title");
|
||||
Set<ZSetOperations.TypedTuple<String>> guildRangeWithScores = RedisUtil.getInstence().getZsetreverseRangeWithScores(RedisKey.CAR_DEALY_GUILD_RANK, "", 0, -1);
|
||||
rank=0;
|
||||
for(ZSetOperations.TypedTuple<String> item : guildRangeWithScores){
|
||||
rank++;
|
||||
|
||||
String value = item.getValue();
|
||||
int guildId = Integer.parseInt(value);
|
||||
String rewardByRank = guildRewardConfigTreeMap.floorEntry(rank).getValue();
|
||||
GuildInfo guildInfo = GuilidManager.guildInfoMap.get(guildId);
|
||||
if(guildInfo==null){
|
||||
continue;
|
||||
}
|
||||
rank++;
|
||||
Collection<Set<Integer>> values = guildInfo.getMembers().values();
|
||||
String guildContent = SErrorCodeEerverConfig.getI18NMessage("family_fight_rank_familyreward_txt",new Object[]{rank});
|
||||
for(Set<Integer> uids : values){
|
||||
|
|
|
@ -3,7 +3,6 @@ package com.ljsd.jieling.globals;
|
|||
public interface Global {
|
||||
int EXECUTION = 1;//行动力id
|
||||
int STAMINA = 2; // 体力id
|
||||
int DROP = 53;//水滴
|
||||
int HEROSTORY_TICKET = 28; //精英入场券
|
||||
int GENERALSTORY_TICKET = 27; //普通入场券
|
||||
int INVASIONBOSS_TICKET = 44; //外敌挑战券
|
||||
|
|
|
@ -10,6 +10,7 @@ import com.ljsd.jieling.logic.dao.root.User;
|
|||
import com.ljsd.jieling.logic.expedition.ExpeditionLogic;
|
||||
import com.ljsd.jieling.logic.fight.DefFightSnapData;
|
||||
import com.ljsd.jieling.logic.fight.FightUtil;
|
||||
import com.ljsd.jieling.logic.fight.specialparm.SpecialForTeamBuildEnum;
|
||||
import com.ljsd.jieling.logic.hero.HeroAttributeEnum;
|
||||
import com.ljsd.jieling.logic.hero.HeroLogic;
|
||||
import com.ljsd.jieling.network.session.ISession;
|
||||
|
@ -157,6 +158,7 @@ public class StartExpeditionBattleRequest extends BaseHandler<Expedition.StartEx
|
|||
.addAllFightUnitList(heroFightInfos)
|
||||
.setTeamSkillList(HeroLogic.getInstance().getPokenmonSkills(user,teamId))
|
||||
.setTeamPassiveList(pokenmonPassiveSkills+holySkill)
|
||||
.setSpecialPassive(SpecialForTeamBuildEnum.toParm(teamId,user))
|
||||
.build();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -28,6 +28,7 @@ import config.SErrorCodeEerverConfig;
|
|||
import config.SWorldBossConfig;
|
||||
import config.SWorldBossSetting;
|
||||
import manager.STableManager;
|
||||
import util.TimeUtils;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
@ -76,6 +77,7 @@ public class FastChallengeHandler extends BaseHandler<FightInfoProto.FastFightCh
|
|||
int challeageId = proto.getChalleageId();
|
||||
int battleRound = sWorldBossSetting.getBattleRound();
|
||||
CommonProto.FightData fightData= null;
|
||||
boolean isNew = guildInfo.addCarFightSb(uid);
|
||||
switch (type){
|
||||
case 1:{
|
||||
int monsterId = STableManager.getConfig(SWorldBossConfig.class).get(GuildFightLogic.carDelayProgressIndication.getBossIndexId()).getMonsterId();
|
||||
|
@ -84,7 +86,7 @@ public class FastChallengeHandler extends BaseHandler<FightInfoProto.FastFightCh
|
|||
hurt = fightResult.getCheckResult()[1];
|
||||
fightData = fightResult.getFightData();
|
||||
gainScore = (int) (hurt*(sWorldBossSetting.getScorePercent()/10000F));
|
||||
boolean isNew = guildInfo.addCarFightSb(uid);
|
||||
|
||||
RankEnum.toRank(RankEnum.CAR_DEALY_RANK.getType()).incrementRankScore(uid,"",gainScore);
|
||||
RankEnum.toRank(RankEnum.CAR_DEALY_GUILD_RANK.getType()).incrementRankScore(guildInfo.getId(),"",gainScore,isNew?1:0);
|
||||
|
||||
|
@ -100,19 +102,20 @@ public class FastChallengeHandler extends BaseHandler<FightInfoProto.FastFightCh
|
|||
String challengeContent = "";
|
||||
PlayerManager playerInfoManager = UserManager.getUser(challeageId).getPlayerInfoManager();
|
||||
String challengeName = playerInfoManager.getNickName();
|
||||
|
||||
if(fight == 1){
|
||||
int challenegScore = RedisUtil.getInstence().getZSetScore(RankEnum.CAR_DEALY_RANK.getRedisKey(), "", String.valueOf(challeageId)).intValue();
|
||||
if(challenegScore !=-1){
|
||||
gainScore = (int) (challenegScore*(sWorldBossSetting.getGrabPercent()/10000F));
|
||||
RankEnum.toRank(RankEnum.CAR_DEALY_RANK.getType()).incrementRankScore(uid,"",gainScore);
|
||||
RankEnum.toRank(RankEnum.CAR_DEALY_RANK.getType()).incrementRankScore(challeageId,"",-gainScore);
|
||||
RankEnum.toRank(RankEnum.CAR_DEALY_GUILD_RANK.getType()).incrementRankScore(guildInfo.getId(),"",gainScore,0);
|
||||
int chanllengeGuild = playerInfoManager.getGuildId();
|
||||
if(chanllengeGuild!=0){
|
||||
RankEnum.toRank(RankEnum.CAR_DEALY_GUILD_RANK.getType()).incrementRankScore(chanllengeGuild,"",-gainScore,0);
|
||||
if(gainScore!=0){
|
||||
RankEnum.toRank(RankEnum.CAR_DEALY_RANK.getType()).incrementRankScore(uid,"",gainScore);
|
||||
RankEnum.toRank(RankEnum.CAR_DEALY_RANK.getType()).incrementRankScore(challeageId,"",-gainScore);
|
||||
RankEnum.toRank(RankEnum.CAR_DEALY_GUILD_RANK.getType()).incrementRankScore(guildInfo.getId(),"",gainScore,isNew?1:0);
|
||||
int chanllengeGuild = playerInfoManager.getGuildId();
|
||||
if(chanllengeGuild!=0){
|
||||
RankEnum.toRank(RankEnum.CAR_DEALY_GUILD_RANK.getType()).incrementRankScore(chanllengeGuild,"",-gainScore,0);
|
||||
}
|
||||
}
|
||||
|
||||
//
|
||||
}
|
||||
content = SErrorCodeEerverConfig.getI18NMessage("worldboss_battle_win",new Object[]{challengeName,gainScore});
|
||||
challengeContent = SErrorCodeEerverConfig.getI18NMessage("worldboss_grab_win",new Object[]{user.getPlayerInfoManager().getNickName(),gainScore});
|
||||
|
@ -120,16 +123,17 @@ public class FastChallengeHandler extends BaseHandler<FightInfoProto.FastFightCh
|
|||
content = SErrorCodeEerverConfig.getI18NMessage("worldboss_battle_lose",new Object[]{challengeName,gainScore});
|
||||
challengeContent = SErrorCodeEerverConfig.getI18NMessage("worldboss_grab_lose",new Object[]{user.getPlayerInfoManager().getNickName(),gainScore});
|
||||
}
|
||||
hurt = fightResult.getCheckResult()[1];
|
||||
String key = RedisUtil.getInstence().getKey(RedisKey.CAR_CHALLENGE_RECORD, String.valueOf(uid));
|
||||
String challenegeKey = RedisUtil.getInstence().getKey(RedisKey.CAR_CHALLENGE_RECORD, String.valueOf(challeageId));
|
||||
RedisUtil.getInstence().zsetAddOne(key,content + "|" + challeageId,(int)(System.currentTimeMillis()/1000));
|
||||
RedisUtil.getInstence().zsetAddOne(challenegeKey,challengeContent + "|" + uid,(int)(System.currentTimeMillis()/1000));
|
||||
guildInfo.addCarFightSb(uid);
|
||||
}break;
|
||||
default:
|
||||
throw new ErrorCodeException(ErrorCode.SERVER_DEFINE);
|
||||
|
||||
}
|
||||
user.getGuildMyInfo().setCarPlayTime(TimeUtils.nowInt());
|
||||
FightInfoProto.FastFightChallengeResponse build = FightInfoProto.FastFightChallengeResponse.newBuilder().setHurt(hurt).setScore(gainScore).setFightData(fightData).build();
|
||||
MessageUtil.sendMessage(iSession,1, MessageTypeProto.MessageType.FAST_FIGHT_CHALLENGE_RESPONSE_VALUE,build,true);
|
||||
}
|
||||
|
|
|
@ -2262,22 +2262,12 @@ public class MapLogic {
|
|||
LOGGER.info("endFight() uid=>{} fightId=>{} SLevelDifficultyConfig == null", uid, fightId);
|
||||
throw new ErrorCodeException(ErrorCode.SERVER_SELF_DEFINE);
|
||||
}
|
||||
int[][] cost = new int[1][];
|
||||
int[] temp = new int[2];
|
||||
temp[0] = Global.DROP;
|
||||
temp[1] = 1;
|
||||
cost[0] = temp;
|
||||
boolean flag = ItemUtil.fightItemCost(user, cost);
|
||||
if (!flag) {
|
||||
throw new ErrorCodeException(ErrorCode.ITEM_NOT_ENOUGH);
|
||||
}
|
||||
List<TeamPosHeroInfo> teamPosHeroInfos = user.getTeamPosManager().getTeamPosForHero().get(teamId);
|
||||
if (teamPosHeroInfos == null || teamPosHeroInfos.size() == 0) {
|
||||
LOGGER.info("startLevelDifficultyFight==> uid={},fightId={},teamId={}", uid, fightId, teamId);
|
||||
throw new ErrorCodeException(ErrorCode.newDefineCode("阵容有误!!"));
|
||||
}
|
||||
|
||||
ItemUtil.itemCost(user,cost, BIReason.MONSTERATTACK_CONSUME, fightId);
|
||||
KtEventUtils.onKtEvent(user, ParamEventBean.UserGameType, KTGameType.CHALLENGE_MONSTERATTACK.getIndex(), fightId);
|
||||
user.getTeamPosManager().setCurTeamPosId(teamId);
|
||||
String fightInfo = fightId + "#" + teamId;
|
||||
|
@ -2334,10 +2324,6 @@ public class MapLogic {
|
|||
// String rankKey = RedisKey.getKey(RedisKey.MONSTER_ATTACK_RANK,"", false);
|
||||
// RedisUtil.getInstence().zsetAddOneOffsetByTime(rankKey, String.valueOf(user.getId()), checkFightId);
|
||||
RankContext.getRankEnum(RankEnum.MONSTER_ATTACK_RANK.getType()).addRank(uid,"",checkFightId);
|
||||
//归还水滴
|
||||
Map<Integer,Integer> itemMap = new HashMap<>(1);
|
||||
itemMap.put( Global.DROP,1);
|
||||
ItemUtil.addItem(user,itemMap,null,BIReason.MONSTERATTACK_BACK);
|
||||
CommonProto.Drop.Builder drop = ItemUtil.drop(user, sFloodConfig.getReward(), BIReason.MONSTERATTACK_REWARD);
|
||||
FightInfoProto.FightEndResponse.Builder fightEndResponse = FightInfoProto.FightEndResponse.newBuilder();
|
||||
fightEndResponse.setEnventDrop(drop);
|
||||
|
|
|
@ -2,6 +2,7 @@ package com.ljsd.jieling.handler.map.behavior;
|
|||
|
||||
import com.googlecode.protobuf.format.JsonFormat;
|
||||
import com.ljsd.fight.FightType;
|
||||
import com.ljsd.jieling.logic.fight.specialparm.SpecialForTeamBuildEnum;
|
||||
import com.ljsd.jieling.logic.hero.HeroAttributeEnum;
|
||||
import com.ljsd.jieling.util.CBean2Proto;
|
||||
import config.MapPointConfig;
|
||||
|
@ -282,6 +283,7 @@ public class BehaviorUtil {
|
|||
.addAllFightUnitList(heroFightInfos)
|
||||
.setTeamSkillList(HeroLogic.getInstance().getPokenmonSkills(user,teamId))
|
||||
.setTeamPassiveList(HeroLogic.getInstance().getPokenmonPassiveSkills(user,teamId))
|
||||
.setSpecialPassive(SpecialForTeamBuildEnum.toParm(teamId,user))
|
||||
.build();
|
||||
}
|
||||
|
||||
|
|
|
@ -72,15 +72,6 @@ public class QuickStartMonsterFighter extends BaseHandler<FightInfoProto.QuickSt
|
|||
LOGGER.info("endFight() uid=>{} fightId=>{} SLevelDifficultyConfig == null", uid, fightId);
|
||||
throw new ErrorCodeException(ErrorCode.CFG_NULL);
|
||||
}
|
||||
int[][] cost = new int[1][];
|
||||
int[] temp = new int[2];
|
||||
temp[0] = Global.DROP;
|
||||
temp[1] = 1;
|
||||
cost[0] = temp;
|
||||
boolean flag = ItemUtil.fightItemCost(user, cost);
|
||||
if (!flag) {
|
||||
throw new ErrorCodeException(ErrorCode.ITEM_NOT_ENOUGH);
|
||||
}
|
||||
List<TeamPosHeroInfo> teamPosHeroInfos = user.getTeamPosManager().getTeamPosForHero().get(teamId);
|
||||
if (teamPosHeroInfos == null || teamPosHeroInfos.size() == 0) {
|
||||
LOGGER.info("startLevelDifficultyFight==> uid={},fightId={},teamId={}", uid, fightId, teamId);
|
||||
|
@ -108,7 +99,6 @@ public class QuickStartMonsterFighter extends BaseHandler<FightInfoProto.QuickSt
|
|||
.build();
|
||||
|
||||
if (resultCode == 0) {
|
||||
ItemUtil.itemCost(user,cost, BIReason.MONSTERATTACK_CONSUME, fightId);
|
||||
CommonProto.Drop.Builder dropBuilder = CommonProto.Drop.newBuilder();
|
||||
FightInfoProto.QuickStartMonsterFightResponse builder = FightInfoProto.QuickStartMonsterFightResponse.newBuilder()
|
||||
.setResult(resultCode)
|
||||
|
|
|
@ -68,6 +68,9 @@ public class FightMainEventHandler implements IEventHandler{
|
|||
}
|
||||
}
|
||||
}
|
||||
if(sGlobalActivity.getType() == ActivityType.GrowthFund){
|
||||
ActivityTypeEnum.getActicityType(sGlobalActivity.getId()).update(user,user.getPlayerInfoManager().getLevel());
|
||||
}
|
||||
}
|
||||
List<SGlobalSystemConfig> sGlobalSystemConfigs = STableManager.getFigureConfig(CommonStaticConfig.class).getsGlobalSystemConfigMapByTypeAndConditionMap().get(1).get(fightId);
|
||||
if(sGlobalSystemConfigs == null){
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
package com.ljsd.jieling.logic.activity;
|
||||
|
||||
import com.ljsd.jieling.jbean.ActivityMission;
|
||||
import com.ljsd.jieling.jbean.ActivityProgressInfo;
|
||||
import com.ljsd.jieling.logic.dao.UserManager;
|
||||
import com.ljsd.jieling.logic.dao.root.User;
|
||||
|
@ -42,4 +43,9 @@ class GrowthFundActivity extends AbstractActivity {
|
|||
SGlobalActivity sGlobalActivity = SGlobalActivity.getsGlobalActivityMap().get(id);
|
||||
user.getPlayerInfoManager().getRechargeInfo().updateBuyGoodsTimes(sGlobalActivity.getCanBuyRechargeId(),0);
|
||||
}
|
||||
|
||||
@Override
|
||||
void updateProgress(ActivityMission activityMission, int count) {
|
||||
activityMission.setV(count);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -44,16 +44,13 @@ public class TreasureActivity extends AbstractActivity {
|
|||
if(user.getPlayerInfoManager().getHadBuyTreasure() == 1){
|
||||
LOGGER.info("戒灵秘宝初始化...reset buy");
|
||||
user.getPlayerInfoManager().setHadBuyTreasure(0);
|
||||
Map<Integer, Integer> buyGoodsTimes = user.getPlayerInfoManager().getRechargeInfo().getBuyGoodsTimes();
|
||||
int id=0;
|
||||
for(SRechargeCommodityConfig sRechargeCommodityConfig : SRechargeCommodityConfig.rechargeCommodityConfigMap.values()){
|
||||
if(sRechargeCommodityConfig.getType() == GiftGoodsType.SUN_LONG){
|
||||
id=sRechargeCommodityConfig.getId();
|
||||
}
|
||||
}
|
||||
buyGoodsTimes.put(id,0);
|
||||
user.getPlayerInfoManager().getRechargeInfo().setBuyGoodsTimes(buyGoodsTimes);
|
||||
user.getPlayerInfoManager().getRechargeInfo().clearCacheSendId();
|
||||
user.getPlayerInfoManager().getRechargeInfo().updateBuyGoodsTimes(id,0);
|
||||
}
|
||||
|
||||
SGlobalActivity sGlobalActivity = SGlobalActivity.getsGlobalActivityMap().get(id);
|
||||
|
|
|
@ -62,9 +62,15 @@ public class UserLevelEventHandler implements IEventHandler,IPrivilegeChange{
|
|||
activityMission.setActivityState(ActivityType.OPEN_STATE);
|
||||
ActivityLogic.getInstance().sendActivityInfo(user,sGlobalActivity.getId());
|
||||
Poster.getPoster().dispatchEvent(new ActivityStateChangeEvent(user.getId(),sGlobalActivity.getId(),ActivityType.OPEN_STATE));
|
||||
if(sGlobalActivity.getType() == ActivityType.GrowthFund){
|
||||
ActivityTypeEnum.getActicityType(sGlobalActivity.getId()).update(user,user.getPlayerInfoManager().getLevel());
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
ActivityLogic.getInstance().updateActivityMissionProgress(user, ActivityType.GrowthFund,level);
|
||||
if(sGlobalSystemConfigs == null){
|
||||
return;
|
||||
}
|
||||
|
|
|
@ -41,6 +41,8 @@ public class ActivityStateChangeHandler implements IEventHandler {
|
|||
if(sGlobalActivity.getCanBuyRechargeId()!=0){
|
||||
user.getPlayerInfoManager().getRechargeInfo().putDyGoodsCanBuyTimes(sGlobalActivity.getCanBuyRechargeId(),1);
|
||||
BuyGoodsLogic.sendGiftGooodsIndication(uid);
|
||||
System.out.println("----------------send buy for activity" + sGlobalActivity.getId());
|
||||
System.out.println("----------------send buy for goodsiD" + sGlobalActivity.getCanBuyRechargeId());
|
||||
}
|
||||
}else if(state == ActivityType.CLOSE_STATE){
|
||||
List<SGlobalActivity> sGlobalActivities = SGlobalActivity.sGlobalActivityMapByOpenRules.getOrDefault(3, new ArrayList<>(0));
|
||||
|
@ -49,7 +51,7 @@ public class ActivityStateChangeHandler implements IEventHandler {
|
|||
if(activityMissionWillOpen!=null && activityMissionWillOpen.getActivityState() == ActivityType.UNOPEN_STATE){
|
||||
AbstractActivity abstractActivity = ActivityTypeEnum.getActicityType(s.getId());
|
||||
abstractActivity.setOpenState(user,ActivityType.OPEN_STATE);
|
||||
Poster.getPoster().dispatchEvent(new ActivityStateChangeEvent(uid,s.getId(),ActivityType.OPEN_STATE));
|
||||
ActivityLogic.getInstance().sendActivityInfo(user,s.getId());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
|
|
@ -35,6 +35,8 @@ public class GuildMyInfo extends MongoBase {
|
|||
private boolean guildHelpReward;//公会奖励
|
||||
private long guildHelpSendTime;//公会求助信息时间 5分钟
|
||||
|
||||
private int carPlayTime; //车迟上次玩的时间
|
||||
|
||||
|
||||
|
||||
public void clearOfLevelGuild(){
|
||||
|
@ -256,4 +258,13 @@ public class GuildMyInfo extends MongoBase {
|
|||
this.guildHelpSendTime = guildHelpSendTime;
|
||||
updateString("guildHelpSendTime",guildHelpSendTime);
|
||||
}
|
||||
|
||||
public void setCarPlayTime(int carPlayTime) {
|
||||
this.carPlayTime = carPlayTime;
|
||||
updateString("carPlayTime",carPlayTime);
|
||||
}
|
||||
|
||||
public int getCarPlayTime() {
|
||||
return carPlayTime;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
package com.ljsd.jieling.logic.dao;
|
||||
|
||||
import com.ljsd.jieling.db.mongo.MongoUtil;
|
||||
import com.ljsd.jieling.db.redis.RedisKey;
|
||||
import com.ljsd.jieling.db.redis.RedisUtil;
|
||||
import com.ljsd.jieling.logic.dao.root.GuildApply;
|
||||
import com.ljsd.jieling.logic.dao.root.GuildInfo;
|
||||
|
@ -101,18 +102,20 @@ public class GuilidManager {
|
|||
needContinue=false;
|
||||
break;
|
||||
}
|
||||
String carGuildDelay = RedisUtil.getInstence().getKey(RedisKey.CAR_DEALY_GUILD_RANK,"");
|
||||
RedisUtil.getInstence().zsetRemoveOne(carGuildDelay,value);
|
||||
GuildInfo guildInfo = guildInfoMap.get(Integer.parseInt(value));
|
||||
if(guildInfo == null){
|
||||
RedisUtil.getInstence().zsetRemoveOne(key,value);
|
||||
continue;
|
||||
}
|
||||
|
||||
GuildLogic.releaseGuild(guildInfo);
|
||||
RedisUtil.getInstence().zsetRemoveOne(key,value);
|
||||
}
|
||||
round++;
|
||||
MongoUtil.getInstence().lastUpdate();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
public static Collection<GuildInfo> recommandGuild(User user) {
|
||||
|
|
|
@ -133,6 +133,7 @@ public class RechargeInfo extends MongoBase{
|
|||
public void updateBuyGoodsTimes(int goodsId,int times) {
|
||||
updateString("buyGoodsTimes."+goodsId,times);
|
||||
this.buyGoodsTimes.put(goodsId,times);
|
||||
cacheSendedIds.remove(goodsId);
|
||||
}
|
||||
|
||||
public void updateGoodsTypeDuration(int goodsId,int durTime) {
|
||||
|
@ -220,6 +221,7 @@ public class RechargeInfo extends MongoBase{
|
|||
|
||||
public void putDyGoodsCanBuyTimes(Integer type,Integer value) {
|
||||
this.dyGoodsCanBuyTimes.put(type,value );
|
||||
cacheSendedIds.remove(type);
|
||||
updateString("dyGoodsCanBuyTimes",dyGoodsCanBuyTimes);
|
||||
}
|
||||
public void removeDyGoodsCanBuyTimes(Integer type) {
|
||||
|
|
|
@ -58,8 +58,8 @@ public class UserManager {
|
|||
|
||||
private static User registerUser(int uid,String openId,String channel,int pid,int gid) throws Exception {
|
||||
User user = new User(uid);
|
||||
initPlayer(user,openId,channel,pid,gid);
|
||||
UserManager.addUser(user);
|
||||
initPlayer(user,openId,channel,pid,gid);
|
||||
MongoUtil.getInstence().getMyMongoTemplate().save(user);
|
||||
PlayerLogic.getInstance().sendTestWelfareMail(user,1,1);
|
||||
return user;
|
||||
|
|
|
@ -149,6 +149,7 @@ public class GuildLogic {
|
|||
}
|
||||
}
|
||||
builder.setCarDelayProgressIndication(GuildFightLogic.carDelayProgressIndication);
|
||||
builder.setCarPlayTime(user.getGuildMyInfo().getCarPlayTime());
|
||||
MessageUtil.sendMessage(session,1,msgId,builder.build(),true);
|
||||
}
|
||||
|
||||
|
|
|
@ -0,0 +1,56 @@
|
|||
package com.ljsd.jieling.logic.fight.specialparm;
|
||||
|
||||
import com.ljsd.jieling.logic.dao.ExpeditionItem;
|
||||
import com.ljsd.jieling.logic.dao.ExpeditionManager;
|
||||
import com.ljsd.jieling.logic.dao.root.User;
|
||||
import config.SExpeditionHolyConfig;
|
||||
import manager.STableManager;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
import java.util.Set;
|
||||
|
||||
/**
|
||||
* 猎妖之路特殊参数
|
||||
*
|
||||
* 1:表示夜明珠拥有数量
|
||||
* 2:层数
|
||||
* 3:获取紫色战力品
|
||||
* 4:获取橙色战力品
|
||||
* 5:神秘药水使用次数
|
||||
*/
|
||||
public class ExpetionSpecialProcessor implements SpecialBuildProcessor{
|
||||
@Override
|
||||
public String getSpecialParm(User user) {
|
||||
Map<Integer, SExpeditionHolyConfig> config = STableManager.getConfig(SExpeditionHolyConfig.class);
|
||||
StringBuilder result = new StringBuilder();
|
||||
Map<Integer,Integer> cache = new HashMap<>();
|
||||
ExpeditionManager expeditionManager = user.getExpeditionManager();
|
||||
Set<ExpeditionItem> propertyItems = user.getExpeditionManager().getPropertyItems();
|
||||
propertyItems.forEach(e->{
|
||||
int type = config.get(e.getEquipId()).gettype();
|
||||
//掉落战力品
|
||||
if( type == 2 || type == 3){
|
||||
cache.put(type,cache.getOrDefault(type,0) + 1);
|
||||
}
|
||||
//夜明珠
|
||||
if(e.getEquipId() == 10001){
|
||||
cache.put(e.getEquipId(),cache.getOrDefault(e.getEquipId(),0) + 1);
|
||||
}
|
||||
});
|
||||
result.append("1#");
|
||||
result.append(cache.getOrDefault(10001,10));
|
||||
result.append(expeditionManager.getLay());
|
||||
result.append("|2#");
|
||||
result.append(expeditionManager.getLay());
|
||||
result.append("|3#");
|
||||
result.append(cache.getOrDefault(2,0));
|
||||
result.append("|4#");
|
||||
result.append(cache.getOrDefault(3,0));
|
||||
result.append("|5#");
|
||||
//* 5:神秘药水使用次数
|
||||
result.append(expeditionManager.getLay());
|
||||
|
||||
return result.toString();
|
||||
}
|
||||
}
|
|
@ -0,0 +1,7 @@
|
|||
package com.ljsd.jieling.logic.fight.specialparm;
|
||||
|
||||
import com.ljsd.jieling.logic.dao.root.User;
|
||||
|
||||
public interface SpecialBuildProcessor {
|
||||
String getSpecialParm(User user);
|
||||
}
|
|
@ -0,0 +1,35 @@
|
|||
package com.ljsd.jieling.logic.fight.specialparm;
|
||||
|
||||
import com.ljsd.jieling.core.GlobalsDef;
|
||||
import com.ljsd.jieling.logic.dao.root.User;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
public enum SpecialForTeamBuildEnum {
|
||||
EXPEDITION_TEAM(GlobalsDef.EXPEDITION_TEAM, new ExpetionSpecialProcessor()),
|
||||
;
|
||||
|
||||
private static Map<Integer,SpecialForTeamBuildEnum> cache = new HashMap<>();
|
||||
static {
|
||||
SpecialForTeamBuildEnum[] values = SpecialForTeamBuildEnum.values();
|
||||
for(SpecialForTeamBuildEnum specialForTeamBuildEnum : values){
|
||||
cache.put(specialForTeamBuildEnum.teamId,specialForTeamBuildEnum);
|
||||
}
|
||||
}
|
||||
|
||||
private int teamId;
|
||||
private SpecialBuildProcessor specialBuildProcessor;
|
||||
|
||||
SpecialForTeamBuildEnum(int teamId, SpecialBuildProcessor specialBuildProcessor) {
|
||||
this.teamId = teamId;
|
||||
this.specialBuildProcessor = specialBuildProcessor;
|
||||
}
|
||||
|
||||
public static String toParm(int teamId,User user){
|
||||
if(cache.containsKey(teamId)){
|
||||
return cache.get(teamId).specialBuildProcessor.getSpecialParm(user);
|
||||
}
|
||||
return "";
|
||||
}
|
||||
}
|
|
@ -32,6 +32,9 @@ public class CarDealyGuildRank extends AbstractRank{
|
|||
String value = data.getValue();
|
||||
int guildId = Integer.parseInt(value);
|
||||
GuildInfo guildInfo = GuilidManager.guildInfoMap.get(guildId);
|
||||
if(guildInfo == null){
|
||||
return;
|
||||
}
|
||||
String familyName = guildInfo.getName();
|
||||
CommonProto.RankInfo.Builder everyRankInfo = CommonProto.RankInfo.newBuilder()
|
||||
.setRank(index)
|
||||
|
|
|
@ -2,6 +2,7 @@ package com.ljsd.jieling.logic.store;
|
|||
|
||||
import com.ljsd.jieling.config.clazzStaticCfg.CommonStaticConfig;
|
||||
import com.ljsd.jieling.core.GlobalsDef;
|
||||
import com.ljsd.jieling.core.HandlerLogicThread;
|
||||
import com.ljsd.jieling.core.VipPrivilegeType;
|
||||
import com.ljsd.jieling.db.mongo.MongoUtil;
|
||||
import com.ljsd.jieling.exception.ErrorCode;
|
||||
|
@ -240,8 +241,7 @@ public class BuyGoodsLogic {
|
|||
MessageUtil.sendIndicationMessage(session,1, MessageTypeProto.MessageType.REFRESH_RECHARGE_INDICATION_VALUE,builder.build(),true);
|
||||
}
|
||||
|
||||
buyGoodsTimes.put(goodsId,buyCount);
|
||||
rechargeInfo.setBuyGoodsTimes(buyGoodsTimes);
|
||||
rechargeInfo.updateBuyGoodsTimes(goodsId,buyCount);
|
||||
//直购礼包
|
||||
if(type == GiftGoodsType.DIRECTBAG){
|
||||
CommonProto.Drop.Builder drop = ItemUtil.drop(user, sRechargeCommodityConfig.getBaseReward(), BIReason.DIRECT_BUY);
|
||||
|
@ -296,6 +296,7 @@ public class BuyGoodsLogic {
|
|||
notifyPaySuccessFul(uid,goodsId,amount != -999);
|
||||
Poster.getPoster().dispatchEvent(new NewWelfareEvent(user, NewWelfareTypeEnum.RECHARGE_BUY.getType(),goodsId));
|
||||
MongoUtil.getLjsdMongoTemplate().lastUpdate();
|
||||
sendGiftGooodsIndication(uid);
|
||||
return resultRes;
|
||||
|
||||
}
|
||||
|
@ -406,7 +407,7 @@ public class BuyGoodsLogic {
|
|||
if(limit!=0){
|
||||
if(buyTimes>=limit){
|
||||
boolean isNew = rechargeInfo.addNewSendId(goodsId);
|
||||
if(!isNew){
|
||||
if(isNew){
|
||||
needChange = true;
|
||||
}
|
||||
continue;
|
||||
|
@ -531,7 +532,19 @@ public class BuyGoodsLogic {
|
|||
while (iterator.hasNext()){
|
||||
ISession value = iterator.next();
|
||||
if(value.getFiveReady() == 1){
|
||||
sendGiftGooodsIndication(value.getUid());
|
||||
User user = UserManager.getUser(value.getUid(), true);
|
||||
if(user == null){
|
||||
continue;
|
||||
}
|
||||
AyyncWorker ayyncWorker = new AyyncWorker(user, false,new AyncWorkerRunnable(){
|
||||
|
||||
@Override
|
||||
public void work(User user) throws Exception {
|
||||
sendGiftGooodsIndication(user.getId());
|
||||
}
|
||||
}) ;
|
||||
ProtocolsManager.getInstance().updateAyncWorker(ayyncWorker);
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -176,6 +176,7 @@ public class FightDataUtil {
|
|||
}
|
||||
playerData.set("teamSkill", getTeamSkill(heroTeam.getTeamSkillList()));
|
||||
playerData.set("teamPassive", getTeamPassive(heroTeam.getTeamPassiveList()));
|
||||
playerData.set("outData",heroTeam.getSpecialPassive());
|
||||
return playerData;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue